@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20241223.0 → 0.0.0-nightly-20241225.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) hide show
  1. package/build/revision-history.js +1 -1
  2. package/dist/index.js +6 -6
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/bg.js +1 -1
  12. package/dist/translations/bg.umd.js +1 -1
  13. package/dist/translations/bn.js +1 -1
  14. package/dist/translations/bn.umd.js +1 -1
  15. package/dist/translations/bs.js +1 -1
  16. package/dist/translations/bs.umd.js +1 -1
  17. package/dist/translations/ca.js +1 -1
  18. package/dist/translations/ca.umd.js +1 -1
  19. package/dist/translations/cs.js +1 -1
  20. package/dist/translations/cs.umd.js +1 -1
  21. package/dist/translations/da.js +1 -1
  22. package/dist/translations/da.umd.js +1 -1
  23. package/dist/translations/de-ch.js +1 -1
  24. package/dist/translations/de-ch.umd.js +1 -1
  25. package/dist/translations/de.js +1 -1
  26. package/dist/translations/de.umd.js +1 -1
  27. package/dist/translations/el.js +1 -1
  28. package/dist/translations/el.umd.js +1 -1
  29. package/dist/translations/en-au.js +1 -1
  30. package/dist/translations/en-au.umd.js +1 -1
  31. package/dist/translations/en-gb.js +1 -1
  32. package/dist/translations/en-gb.umd.js +1 -1
  33. package/dist/translations/en.js +1 -1
  34. package/dist/translations/en.umd.js +1 -1
  35. package/dist/translations/eo.js +1 -1
  36. package/dist/translations/eo.umd.js +1 -1
  37. package/dist/translations/es-co.js +1 -1
  38. package/dist/translations/es-co.umd.js +1 -1
  39. package/dist/translations/es.js +1 -1
  40. package/dist/translations/es.umd.js +1 -1
  41. package/dist/translations/et.js +1 -1
  42. package/dist/translations/et.umd.js +1 -1
  43. package/dist/translations/eu.js +1 -1
  44. package/dist/translations/eu.umd.js +1 -1
  45. package/dist/translations/fa.js +1 -1
  46. package/dist/translations/fa.umd.js +1 -1
  47. package/dist/translations/fi.js +1 -1
  48. package/dist/translations/fi.umd.js +1 -1
  49. package/dist/translations/fr.js +1 -1
  50. package/dist/translations/fr.umd.js +1 -1
  51. package/dist/translations/gl.js +1 -1
  52. package/dist/translations/gl.umd.js +1 -1
  53. package/dist/translations/gu.js +1 -1
  54. package/dist/translations/gu.umd.js +1 -1
  55. package/dist/translations/he.js +1 -1
  56. package/dist/translations/he.umd.js +1 -1
  57. package/dist/translations/hi.js +1 -1
  58. package/dist/translations/hi.umd.js +1 -1
  59. package/dist/translations/hr.js +1 -1
  60. package/dist/translations/hr.umd.js +1 -1
  61. package/dist/translations/hu.js +1 -1
  62. package/dist/translations/hu.umd.js +1 -1
  63. package/dist/translations/hy.js +1 -1
  64. package/dist/translations/hy.umd.js +1 -1
  65. package/dist/translations/id.js +1 -1
  66. package/dist/translations/id.umd.js +1 -1
  67. package/dist/translations/it.js +1 -1
  68. package/dist/translations/it.umd.js +1 -1
  69. package/dist/translations/ja.js +1 -1
  70. package/dist/translations/ja.umd.js +1 -1
  71. package/dist/translations/jv.js +1 -1
  72. package/dist/translations/jv.umd.js +1 -1
  73. package/dist/translations/kk.js +1 -1
  74. package/dist/translations/kk.umd.js +1 -1
  75. package/dist/translations/km.js +1 -1
  76. package/dist/translations/km.umd.js +1 -1
  77. package/dist/translations/kn.js +1 -1
  78. package/dist/translations/kn.umd.js +1 -1
  79. package/dist/translations/ko.js +1 -1
  80. package/dist/translations/ko.umd.js +1 -1
  81. package/dist/translations/ku.js +1 -1
  82. package/dist/translations/ku.umd.js +1 -1
  83. package/dist/translations/lt.js +1 -1
  84. package/dist/translations/lt.umd.js +1 -1
  85. package/dist/translations/lv.js +1 -1
  86. package/dist/translations/lv.umd.js +1 -1
  87. package/dist/translations/ms.js +1 -1
  88. package/dist/translations/ms.umd.js +1 -1
  89. package/dist/translations/nb.js +1 -1
  90. package/dist/translations/nb.umd.js +1 -1
  91. package/dist/translations/ne.js +1 -1
  92. package/dist/translations/ne.umd.js +1 -1
  93. package/dist/translations/nl.js +1 -1
  94. package/dist/translations/nl.umd.js +1 -1
  95. package/dist/translations/no.js +1 -1
  96. package/dist/translations/no.umd.js +1 -1
  97. package/dist/translations/oc.js +1 -1
  98. package/dist/translations/oc.umd.js +1 -1
  99. package/dist/translations/pl.js +1 -1
  100. package/dist/translations/pl.umd.js +1 -1
  101. package/dist/translations/pt-br.js +1 -1
  102. package/dist/translations/pt-br.umd.js +1 -1
  103. package/dist/translations/pt.js +1 -1
  104. package/dist/translations/pt.umd.js +1 -1
  105. package/dist/translations/ro.js +1 -1
  106. package/dist/translations/ro.umd.js +1 -1
  107. package/dist/translations/ru.js +1 -1
  108. package/dist/translations/ru.umd.js +1 -1
  109. package/dist/translations/si.js +1 -1
  110. package/dist/translations/si.umd.js +1 -1
  111. package/dist/translations/sk.js +1 -1
  112. package/dist/translations/sk.umd.js +1 -1
  113. package/dist/translations/sl.js +1 -1
  114. package/dist/translations/sl.umd.js +1 -1
  115. package/dist/translations/sq.js +1 -1
  116. package/dist/translations/sq.umd.js +1 -1
  117. package/dist/translations/sr-latn.js +1 -1
  118. package/dist/translations/sr-latn.umd.js +1 -1
  119. package/dist/translations/sr.js +1 -1
  120. package/dist/translations/sr.umd.js +1 -1
  121. package/dist/translations/sv.js +1 -1
  122. package/dist/translations/sv.umd.js +1 -1
  123. package/dist/translations/th.js +1 -1
  124. package/dist/translations/th.umd.js +1 -1
  125. package/dist/translations/ti.js +1 -1
  126. package/dist/translations/ti.umd.js +1 -1
  127. package/dist/translations/tk.js +1 -1
  128. package/dist/translations/tk.umd.js +1 -1
  129. package/dist/translations/tr.js +1 -1
  130. package/dist/translations/tr.umd.js +1 -1
  131. package/dist/translations/tt.js +1 -1
  132. package/dist/translations/tt.umd.js +1 -1
  133. package/dist/translations/ug.js +1 -1
  134. package/dist/translations/ug.umd.js +1 -1
  135. package/dist/translations/uk.js +1 -1
  136. package/dist/translations/uk.umd.js +1 -1
  137. package/dist/translations/ur.js +1 -1
  138. package/dist/translations/ur.umd.js +1 -1
  139. package/dist/translations/uz.js +1 -1
  140. package/dist/translations/uz.umd.js +1 -1
  141. package/dist/translations/vi.js +1 -1
  142. package/dist/translations/vi.umd.js +1 -1
  143. package/dist/translations/zh-cn.js +1 -1
  144. package/dist/translations/zh-cn.umd.js +1 -1
  145. package/dist/translations/zh.js +1 -1
  146. package/dist/translations/zh.umd.js +1 -1
  147. package/package.json +8 -8
  148. package/src/changeitem.js +2 -2
  149. package/src/editor/revisionviewereditor.js +2 -2
  150. package/src/editor/revisionviewereditorui.js +1 -1
  151. package/src/editor/revisionviewereditoruiview.js +1 -1
  152. package/src/index.js +1 -1
  153. package/src/revision.js +2 -2
  154. package/src/revisiondiff.js +1 -1
  155. package/src/revisionhistory.js +1 -1
  156. package/src/revisionsrepository.js +1 -1
  157. package/src/revisiontracker.js +1 -1
  158. package/src/revisionviewer.js +1 -1
  159. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  160. package/src/ui/revision/revisionauthorview.js +1 -1
  161. package/src/ui/revision/revisionnameview.js +1 -1
  162. package/src/ui/revision/revisionview.js +2 -2
  163. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  164. package/src/ui/revision/subrevisionview.js +1 -1
  165. package/src/ui/revision/utils.js +1 -1
  166. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  167. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  168. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  169. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  170. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  172. package/src/ui/revisionssidebar/utils.js +1 -1
  173. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  174. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  175. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  176. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  177. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0xaf4875,uid as _0x5168c7,Collection as _0x1ffe77,logWarning as _0x4648e4,FocusTracker as _0x325c49,KeystrokeHandler as _0x3f50e3,scrollViewportToShowTarget as _0x24b293,ResizeObserver as at,ElementReplacer as ct,CKEditorError as _0x3fa815}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x10dfce,set as _0x1b0c74,unset as _0x25300e,isEqual as _0x525435}from'lodash-es';import{Plugin as _0x5951b8,PendingActions as _0x422bcb,icons as _0x10c6a8,Command as _0x5da42d,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0xf71a07,getMarkerDomElement as _0x408031,ConfirmMixin as _0x17991f,sanitizeEditorConfig as _0x19230e}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x52f59f,ViewText as _0x176147,ViewElement as _0x241c33,Element as ft,Range as vt,Position as gt,DocumentFragment as mt,ViewContainerElement as _0x3c99dc,ViewAttributeElement as _0x1830f5,ViewEmptyElement as _0x4028f0,ViewRawElement as _0xba7a0d,ViewUIElement as _0x5bc111,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x37329d,submitHandler as _0x43fe95,LabeledFieldView as _0x354fa9,createLabeledInputText as _0x1a2f3e,createDropdown as _0x3b3239,ListView as _0x49de68,ListItemView as _0xb8fceb,ButtonView as te,MenuBarMenuView as _0x5b4880,MenuBarMenuListView as _0x40a26d,MenuBarMenuListItemView as _0x257cab,MenuBarMenuListItemButtonView as _0x3c210a,ContextualBalloon as _0x4588f0,ToolbarSeparatorView as _0x17a559,IconView as _0x48ee11,addListToDropdown as to,ViewModel as _0x16cba2,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x4efa5}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
- _0xaf4875(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x3b2aad){super(),this['id']=_0x3b2aad['id']||_0x5168c7(),this['creator']=_0x3b2aad['creator']||null,this['authors']=_0x3b2aad['authors']||[],this['diffData']=_0x3b2aad['diffData']||null,this['toVersion']=_0x3b2aad['toVersion']||0x0,this['fromVersion']=_0x3b2aad['fromVersion']||0x0,this['set']('name',_0x3b2aad['name']||''),this['set']('createdAt',_0x3b2aad['createdAt']||new Date()),this['set']('attributes',_0x3b2aad['attributes']||{});}['setName'](_0x391e2c){this['_update']({'name':_0x391e2c});}['setAttribute'](_0x48042b,_0x209119){const _0x131827=_0x10dfce(this['attributes']);_0x1b0c74(_0x131827,_0x48042b,_0x209119),this['_update']({'attributes':_0x131827});}['removeAttribute'](_0x2465d1){const _0x4ff96b=_0x10dfce(this['attributes']);_0x25300e(_0x4ff96b,_0x2465d1),this['_update']({'attributes':_0x4ff96b});}['_update'](_0x213d4e,_0x13a453=!0x1){let _0x9e0894=!0x1;const _0x3412ba={'id':this['id']},_0x2a6285=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x238107 of _0x2a6285){const _0x5b59eb=_0x213d4e[_0x238107];void 0x0!==_0x5b59eb&&_0x5b59eb!==this[_0x238107]&&(this[_0x238107]=_0x5b59eb,_0x3412ba[_0x238107]=_0x5b59eb,_0x9e0894=!0x0);}_0x9e0894&&(_0x3412ba['authors']&&(_0x3412ba['authorsIds']=_0x3412ba['authors']['map'](_0xde6a19=>_0xde6a19['id']),delete _0x3412ba['authors']),this['fire']('_update',_0x3412ba,_0x13a453));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x49ae29=>_0x49ae29['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x5951b8{['_revisions'];static get['requires'](){return[_0xf71a07];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x29c795){super(_0x29c795),this['_revisions']=new _0x1ffe77();}['afterInit'](){!async function(_0x47c208){const _0x42bcf6=_0x1479c5([0x34,0x58,0x36,0x66,0x37,0x54,0x52,0x39,0x75,0x55,0x78,0x43,0x35,0x65,0x4b,0x5a,0x33,0x64,0x73,0x70,0x30,0x41,0x6f,0x31,0x62,0x76,0x47,0x50,0x4e,0x71,0x72,0x49,0x69,0x6a,0x45,0x79,0x48,0x6d,0x56,0x51,0x4d,0x4a,0x6b,0x57,0x42,0x38,0x74,0x6c,0x53,0x4c,0x46,0x59,0x77,0x61,0x32,0x68,0x7a,0x44,0x67,0x63,0x6e,0x4f]),_0x5d96c9=0xeb829,_0xd0be81=0x6b1a05fc,_0x54b42c=0x6b1d5f7c^_0xd0be81,_0x2752bc=window[_0x1479c5([0x44,0x61,0x74,0x65])][_0x1479c5([0x6e,0x6f,0x77])](),_0x2bdacb=_0x47c208[_0x1479c5([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x44e49c=new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2dd80f=>{_0x2bdacb[_0x1479c5([0x6f,0x6e,0x63,0x65])](_0x1479c5([0x72,0x65,0x61,0x64,0x79]),_0x2dd80f);}),_0x32c366={[_0x1479c5([0x6b,0x74,0x79])]:_0x1479c5([0x45,0x43]),[_0x1479c5([0x75,0x73,0x65])]:_0x1479c5([0x73,0x69,0x67]),[_0x1479c5([0x63,0x72,0x76])]:_0x1479c5([0x50,0x2d,0x32,0x35,0x36]),[_0x1479c5([0x78])]:_0x1479c5([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]),[_0x1479c5([0x79])]:_0x1479c5([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]),[_0x1479c5([0x61,0x6c,0x67])]:_0x1479c5([0x45,0x53,0x32,0x35,0x36])},_0x2eb55c=_0x2bdacb[_0x1479c5([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1479c5([0x67,0x65,0x74])](_0x1479c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x258425(){let _0x8f8319,_0x190bd6=null,_0x1b76cc=null;try{if(_0x2eb55c==_0x1479c5([0x47,0x50,0x4c]))return _0x1479c5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x8f8319=_0x4be7e3(),!_0x8f8319)return _0x1479c5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x8f8319[_0x1479c5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1b76cc=_0x1d4e08(_0x8f8319[_0x1479c5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x8f8319[_0x1479c5([0x6a,0x74,0x69])])),await _0x381008()?_0xf2f80f()?_0x38774f()?_0x1479c5([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x59d270()?(_0x8f8319[_0x1479c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1479c5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x190bd6=_0x2fa0f3(_0x1479c5([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x8f8319[_0x1479c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1479c5([0x74,0x72,0x69,0x61,0x6c])&&(_0x190bd6=_0x2fa0f3(_0x1479c5([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x8f8319[_0x1479c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1479c5([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x190bd6=_0x2fa0f3(_0x1479c5([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x572d7a()):_0x1479c5([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1479c5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1479c5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x193305){return _0x1479c5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x38774f(){const _0x3bef85=[_0x1479c5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1479c5([0x74,0x72,0x69,0x61,0x6c])][_0x1479c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x8f8319[_0x1479c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2752bc/0x3e8:0xe10*_0x54b42c;return _0x8f8319[_0x1479c5([0x65,0x78,0x70])]<_0x3bef85;}function _0xf2f80f(){const _0x5aed02=_0x8f8319[_0x1479c5([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5aed02)return!0x1;if(_0x5aed02[_0x1479c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1479c5([0x2a])))return!0x0;if(_0x5aed02[_0x1479c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1479c5([0x52,0x48])))return!0x0;if(_0x5aed02[_0x1479c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1479c5([0x52,0x52,0x48]))){if(_0x57faa6())return!0x0;if(_0x26fa52()||_0x437da1())return!0x0;}return!0x1;}function _0x59d270(){const _0x36967e=_0x8f8319[_0x1479c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x36967e||0x0==_0x36967e[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x436374}=new URL(window[_0x1479c5([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x36967e[_0x1479c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x436374))return!0x0;const _0x43aa8e=_0x436374[_0x1479c5([0x73,0x70,0x6c,0x69,0x74])](_0x1479c5([0x2e]));return _0x36967e[_0x1479c5([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4fd1fd=>_0x4fd1fd[_0x1479c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1479c5([0x2a])))[_0x1479c5([0x6d,0x61,0x70])](_0x354026=>_0x354026[_0x1479c5([0x73,0x70,0x6c,0x69,0x74])](_0x1479c5([0x2e])))[_0x1479c5([0x73,0x6f,0x6d,0x65])](_0x1830d4=>_0x43aa8e[_0x1479c5([0x65,0x76,0x65,0x72,0x79])]((_0x26c6e1,_0x25f6bc)=>_0x1830d4[_0x25f6bc]===_0x26c6e1||_0x1830d4[_0x25f6bc]===_0x1479c5([0x2a])));}function _0x572d7a(){return _0x190bd6&&_0x1b76cc?new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x362e82,_0x311a19)=>{_0x190bd6[_0x1479c5([0x74,0x68,0x65,0x6e])](_0x362e82,_0x311a19),_0x1b76cc[_0x1479c5([0x74,0x68,0x65,0x6e])](_0x10a06a=>{_0x10a06a!=_0x1479c5([0x56,0x61,0x6c,0x69,0x64])&&_0x362e82(_0x10a06a);},_0x311a19);}):_0x190bd6||_0x1b76cc||_0x1479c5([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1d4e08(_0x5b5fbd,_0x282c6a){return new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x39bec6=>{if(_0x460200())return _0x39bec6(_0x1479c5([0x56,0x61,0x6c,0x69,0x64]));_0x24f8cf(),_0x2bdacb[_0x1479c5([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1479c5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1b98c5=!0x1;const _0x561e7d=_0x5168c7();function _0x5f4e21(_0x336c1d){return!!_0x336c1d&&(typeof _0x336c1d===_0x1479c5([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x336c1d===_0x1479c5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x336c1d[_0x1479c5([0x74,0x68,0x65,0x6e])]===_0x1479c5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x336c1d[_0x1479c5([0x63,0x61,0x74,0x63,0x68])]===_0x1479c5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x353e3c(_0xc53dd6){_0x2b93ac(_0xc53dd6)[_0x1479c5([0x74,0x68,0x65,0x6e])](_0x2db104=>{if(!_0x2db104||_0x2db104[_0x1479c5([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1479c5([0x6f,0x6b]))return _0x1479c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2f6337(_0x3d79dc(_0x561e7d+_0x282c6a))!=_0x2db104[_0x1479c5([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1479c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1479c5([0x56,0x61,0x6c,0x69,0x64]);})[_0x1479c5([0x74,0x68,0x65,0x6e])](_0x490d8e=>(_0x13282b(),_0x490d8e),()=>{const _0x391f8b=_0x17d979();return null==_0x391f8b?(_0x13282b(),_0x1479c5([0x56,0x61,0x6c,0x69,0x64])):_0x1479c5(_0x2752bc-_0x391f8b>(0x4f1681fc^_0xd0be81)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1479c5([0x74,0x68,0x65,0x6e])](_0x39bec6)[_0x1479c5([0x63,0x61,0x74,0x63,0x68])](()=>{_0x39bec6(_0x1479c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x39d9a2=0x6b2ceb7c^_0xd0be81;function _0x13282b(){const _0x34990c=_0x1479c5([0x6c,0x6c,0x63,0x74,0x2d])+_0x2f6337(_0x3d79dc(_0x5b5fbd)),_0x3613df=_0x40a198(_0x2f6337(window[_0x1479c5([0x4d,0x61,0x74,0x68])][_0x1479c5([0x63,0x65,0x69,0x6c])](_0x2752bc/_0x39d9a2)));window[_0x1479c5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1479c5([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x34990c,_0x3613df);}function _0x17d979(){const _0x2c7952=_0x1479c5([0x6c,0x6c,0x63,0x74,0x2d])+_0x2f6337(_0x3d79dc(_0x5b5fbd)),_0x693cb2=window[_0x1479c5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1479c5([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2c7952);return _0x693cb2?window[_0x1479c5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x40a198(_0x693cb2),0x10)*_0x39d9a2:null;}function _0x2b93ac(_0x543a95){return new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x22f857,_0x1555f5)=>{_0x543a95[_0x1479c5([0x74,0x68,0x65,0x6e])](_0x22f857,_0x1555f5),window[_0x1479c5([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1555f5,0x6b1bd13c^_0xd0be81);});}}_0x2bdacb[_0x1479c5([0x6f,0x6e])](_0x1479c5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x41096a,_0x22d0f5)=>{if(_0x22d0f5[0x0]!=_0x5b5fbd)return _0x39bec6(_0x1479c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x22d0f5[0x1]={..._0x22d0f5[0x1],[_0x1479c5([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x561e7d};},{[_0x1479c5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1479c5([0x68,0x69,0x67,0x68])}),_0x2bdacb[_0x1479c5([0x6f,0x6e])](_0x1479c5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1fc92d=>{_0x5f4e21(_0x1fc92d[_0x1479c5([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1b98c5=!0x0,_0x353e3c(_0x1fc92d[_0x1479c5([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1479c5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1479c5([0x6c,0x6f,0x77])}),_0x44e49c[_0x1479c5([0x74,0x68,0x65,0x6e])](()=>{_0x1b98c5||_0x39bec6(_0x1479c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x460200(){return _0x2bdacb[_0x1479c5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1479c5([0x76,0x69,0x65,0x77])][_0x1479c5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1479c5([0x61,0x75,0x74,0x6f]);}function _0x24f8cf(){_0x2bdacb[_0x1479c5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1479c5([0x76,0x69,0x65,0x77])][_0x1479c5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1479c5([0x61,0x75,0x74,0x6f]);}}function _0x2fa0f3(_0x4e7898){const _0x3b8385=[new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4e1731=>setTimeout(_0x4e1731,0x6b133b30^_0xd0be81)),_0x44e49c[_0x1479c5([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x55cda5=>{const _0x1526ee=0x6b1a05fb^_0xd0be81,_0x47562b=_0x47c208[_0x1479c5([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x30520b(){_0x47562b[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1526ee&&_0x55cda5();}_0x30520b(),_0x47562b[_0x1479c5([0x6f,0x6e])](_0x1479c5([0x61,0x64,0x64]),_0x30520b);})),new window[(_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x472a65=>{function _0x1ab5e7(){for(const _0x4e1794 in window)if(window[_0x1479c5([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x1479c5([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4e1794))&&window[_0x4e1794]==_0x5d96c9)return _0x472a65();_0x2bdacb[_0x1479c5([0x73,0x74,0x61,0x74,0x65])]!=_0x1479c5([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x1479c5([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1ab5e7,0x6b1a1674^_0xd0be81);}_0x4f3a8a(_0x1479c5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x1ab5e7();})];return window[_0x1479c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1479c5([0x72,0x61,0x63,0x65])](_0x3b8385)[_0x1479c5([0x74,0x68,0x65,0x6e])](()=>_0x4e7898);}async function _0x55f793(){if(await _0x44e49c,_0x4f3a8a(_0x1479c5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x514044=_0x47c208[_0x1479c5([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x38c93c=_0x47c208[_0x1479c5([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])](_0x514044[_0x1479c5([0x69,0x64])]),_0x43eb7d=_0x1b9f2d(_0x1479c5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x43eb7d[_0x1479c5([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x514044['id'],_0x38c93c?_0x38c93c['id']:null,!0x0),_0x43eb7d[_0x1479c5([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1479c5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x43eb7d[_0x1479c5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x43eb7d[_0x1479c5([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x75febb,void(_0x43eb7d[_0x1479c5([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x75febb);}if(_0x4f3a8a(_0x1479c5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x131972=_0x1b9f2d(_0x1479c5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x131972[_0x1479c5([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1479c5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x131972[_0x1479c5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x131972[_0x1479c5([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x75febb,_0x131972[_0x1479c5([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x75febb;}_0x2bdacb[_0x1479c5([0x6d,0x6f,0x64,0x65,0x6c])][_0x1479c5([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x75febb,_0x2bdacb[_0x1479c5([0x6d,0x6f,0x64,0x65,0x6c])][_0x1479c5([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x75febb,_0x2bdacb[_0x1479c5([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1479c5([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x57faa6(){return _0x4f3a8a(_0x1479c5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1b9f2d(_0x1479c5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1479c5([0x73,0x74,0x61,0x74,0x65])]==_0x1479c5([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x26fa52(){return _0x4f3a8a(_0x1479c5([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 _0x437da1(){return _0x4f3a8a(_0x1479c5([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x112421(_0x39495a){const _0x916c3a=_0x2b1931();_0x2bdacb[_0x916c3a]=_0x1479c5([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])+_0x39495a,_0x39495a[_0x1479c5([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x1479c5([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2b1931()]=_0x5d96c9),_0x39495a!=_0x1479c5([0x56,0x61,0x6c,0x69,0x64])&&_0x55f793();}function _0x2b1931(){const _0x44d432=window[_0x1479c5([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1479c5([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1479c5([0x6e,0x6f,0x77])]())[_0x1479c5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1479c5([0x2e]),'');let _0x2b969c=_0x1479c5([0x58]);for(let _0xf84275=0x0;_0xf84275<_0x44d432[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xf84275+=0x2){let _0x2afaee=window[_0x1479c5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x44d432[_0x1479c5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xf84275,_0xf84275+0x2));_0x2afaee>=_0x42bcf6[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2afaee-=_0x42bcf6[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2b969c+=_0x42bcf6[_0x2afaee];}return _0x2b969c;}function _0x4be7e3(){const _0x7159de=_0x2eb55c[_0x1479c5([0x73,0x70,0x6c,0x69,0x74])](_0x1479c5([0x2e]));if(0x3!=_0x7159de[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x16e02a(_0x7159de[0x1]);function _0x16e02a(_0x23421c){const _0x1ad1d8=_0x289198(_0x23421c);return _0x1ad1d8&&_0x3586ad()?_0x1ad1d8:null;function _0x3586ad(){const _0x17914f=_0x1ad1d8[_0x1479c5([0x6a,0x74,0x69])],_0x5a0e94=window[_0x1479c5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x17914f[_0x1479c5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x17914f[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1dcca8={..._0x1ad1d8,[_0x1479c5([0x6a,0x74,0x69])]:_0x17914f[_0x1479c5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x17914f[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1dcca8[_0x1479c5([0x76,0x63])],_0x3d79dc(_0x1dcca8)==_0x5a0e94;}}}async function _0x381008(){let _0x121464=!0x0;try{const _0x428034=_0x2eb55c[_0x1479c5([0x73,0x70,0x6c,0x69,0x74])](_0x1479c5([0x2e])),[_0x454bcb,_0x15ca0a,_0x9f2ec3]=_0x428034;return _0x423fd8(_0x454bcb),await _0x4e0b2f(_0x454bcb,_0x15ca0a,_0x9f2ec3),_0x121464;}catch(_0x181d38){return!0x1;}function _0x423fd8(_0x514236){const _0xf1657d=_0x289198(_0x514236);_0xf1657d&&_0xf1657d[_0x1479c5([0x61,0x6c,0x67])]==_0x1479c5([0x45,0x53,0x32,0x35,0x36])||(_0x121464=!0x1);}async function _0x4e0b2f(_0x678818,_0x5b77e7,_0x26ecfa){const _0x2dbb7e=window[_0x1479c5([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1479c5([0x66,0x72,0x6f,0x6d])](_0x488408(_0x26ecfa),_0x2cc26a=>_0x2cc26a[_0x1479c5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4da72f=new window[(_0x1479c5([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1479c5([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x678818+_0x1479c5([0x2e])+_0x5b77e7),_0x92ad01=window[_0x1479c5([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1479c5([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x92ad01)return;const _0x3a7a80=await _0x92ad01[_0x1479c5([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1479c5([0x6a,0x77,0x6b]),_0x32c366,{[_0x1479c5([0x6e,0x61,0x6d,0x65])]:_0x1479c5([0x45,0x43,0x44,0x53,0x41]),[_0x1479c5([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1479c5([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1479c5([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x92ad01[_0x1479c5([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1479c5([0x6e,0x61,0x6d,0x65])]:_0x1479c5([0x45,0x43,0x44,0x53,0x41]),[_0x1479c5([0x68,0x61,0x73,0x68])]:{[_0x1479c5([0x6e,0x61,0x6d,0x65])]:_0x1479c5([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3a7a80,_0x2dbb7e,_0x4da72f)||(_0x121464=!0x1);}}function _0x289198(_0x23a5fc){return _0x23a5fc[_0x1479c5([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1479c5([0x65,0x79]))?JSON[_0x1479c5([0x70,0x61,0x72,0x73,0x65])](_0x488408(_0x23a5fc)):null;}function _0x488408(_0x158e50){return window[_0x1479c5([0x61,0x74,0x6f,0x62])](_0x158e50[_0x1479c5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1479c5([0x2b]))[_0x1479c5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1479c5([0x2f])));}function _0x3d79dc(_0x3b1261){let _0x45a0f1=0x1505;function _0x589f04(_0xf6c6ff){for(let _0x532494=0x0;_0x532494<_0xf6c6ff[_0x1479c5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x532494++){const _0x42d292=_0xf6c6ff[_0x1479c5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x532494);_0x45a0f1=(_0x45a0f1<<0x5)+_0x45a0f1+_0x42d292,_0x45a0f1&=_0x45a0f1;}}function _0x4fb44f(_0x1c24f9){Array[_0x1479c5([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1c24f9)?_0x1c24f9[_0x1479c5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4fb44f):_0x1c24f9&&typeof _0x1c24f9==_0x1479c5([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1479c5([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1c24f9)[_0x1479c5([0x73,0x6f,0x72,0x74])]()[_0x1479c5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x459431,_0x4545e9])=>{_0x589f04(_0x459431),_0x4fb44f(_0x4545e9);}):_0x589f04(window[_0x1479c5([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1c24f9));}return _0x4fb44f(_0x3b1261),_0x45a0f1>>>0x0;}function _0x2f6337(_0x450b6d){return _0x450b6d[_0x1479c5([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1479c5([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1479c5([0x30]));}function _0x40a198(_0x219b10){return _0x219b10[_0x1479c5([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1479c5([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1479c5([0x6a,0x6f,0x69,0x6e])]('');}function _0x4f3a8a(_0x259f9c){return _0x2bdacb[_0x1479c5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1479c5([0x68,0x61,0x73])](_0x259f9c);}function _0x1b9f2d(_0x24c943){return _0x2bdacb[_0x1479c5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1479c5([0x67,0x65,0x74])](_0x24c943);}function _0x75febb(){}function _0x1479c5(_0x3faeb3){return _0x3faeb3['map'](_0x3ad57c=>String['fromCharCode'](_0x3ad57c))['join']('');}_0x112421(await _0x258425());}(this);}['createRevision'](_0x540650){const _0x5cb997=this['editor']['plugins']['get']('Users');return new a({'id':_0x540650['id'],'name':_0x540650['name'],'creator':_0x540650['creatorId']?_0x5cb997['getUser'](_0x540650['creatorId']):null,'diffData':_0x540650['diffData']||_0x540650['data'],'authors':_0x540650['authorsIds']['map'](_0x1bc7e0=>_0x5cb997['getUser'](_0x1bc7e0)),'createdAt':new Date(_0x540650['createdAt']),'attributes':_0x540650['attributes'],'fromVersion':_0x540650['fromVersion'],'toVersion':_0x540650['toVersion']});}['addRevision'](_0xdf60a0,_0x344ef8=0x0){this['_revisions']['add'](_0xdf60a0,_0x344ef8);}['getRevision'](_0x59cf96){return this['_revisions']['get'](_0x59cf96);}['getRevisions'](_0x264bf4={'toJSON':!0x1}){const _0x325dea=Array['from'](this['_revisions']);return _0x325dea['reverse'](),_0x264bf4['toJSON']?_0x325dea['map'](_0xacaada=>_0xacaada['toJSON']()):_0x325dea;}['getIndex'](_0x467978){return this['_revisions']['getIndex'](_0x467978);}['getEarlierVisibleRevision'](_0x3a1885){const [,_0x5d5691]=this['getRevisionsIterator'](_0x3a1885,{'direction':'earlier'});return _0x5d5691;}['getLaterVisibleRevision'](_0x3ba928){const [,_0x54467]=this['getRevisionsIterator'](_0x3ba928,{'direction':'later'});return _0x54467;}['getRevisionsInDiff'](_0x367d57){const _0x188f3d=[];for(const _0x3d1652 of this['getRevisionsIterator'](_0x367d57['newRevisionId']))if(_0x188f3d['push'](_0x3d1652),_0x3d1652['id']===_0x367d57['oldRevisionId'])break;return _0x188f3d;}*['getRevisionsIterator'](_0x1eeb4a,{direction:_0x5535f2='earlier',filter:_0x30b18c=()=>!0x0}={}){const _0x5eae49='earlier'===_0x5535f2?0x1:-0x1;let _0x52635f=this['_revisions']['get'](_0x1eeb4a),_0x296ced=this['getIndex'](_0x52635f);for(yield _0x52635f;_0x52635f;){if(_0x296ced+=_0x5eae49,_0x52635f=this['getRevision'](_0x296ced),!_0x52635f)return;_0x30b18c(_0x52635f)&&(yield _0x52635f);}}}function R(_0x478e4f,_0x1feb38,_0x1715d8){const t=_0x478e4f['t'];switch(_0x1feb38){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'},_0x1715d8);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1715d8);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 C={'c':_0x3c99dc,'a':_0x1830f5,'e':_0x4028f0,'r':_0xba7a0d,'u':_0x5bc111};class l extends _0x5951b8{['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[_0xf71a07,j,_0x422bcb];}constructor(_0x511e25){super(_0x511e25),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x4703a5=_0x5168c7();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x4703a5},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 _0x1b27d8=this['repository']['getRevision'](0x0),_0x1bf277=_0x1b27d8&&null===_0x1b27d8['creator']?_0x1b27d8:null;if(this['_continueCurrentRevision']=!!_0x1bf277&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x2a80b8=this['_source']['getCurrentRevisionId'](),_0x5adf31=this['repository']['getRevision'](_0x2a80b8);if(_0x5adf31)this['_startingVersion']=_0x5adf31['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5ca7ce=this['_source']['history']['_operations']['find'](_0x45ca0b=>!_0x45ca0b['_isInit']),_0x5326fb=_0x5ca7ce?_0x5ca7ce['baseVersion']:this['_source']['history']['version'];_0x1b27d8?(_0x1b27d8['toVersion']<_0x5326fb&&_0x1b27d8['_update']({'toVersion':_0x5326fb}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x1bf277['id'],this['_startingVersion']=_0x1bf277['fromVersion']):(this['_startingVersion']=_0x1b27d8['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5326fb,this['_continueCurrentRevision']=!0x1);}}else _0x1bf277&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x1bf277['toVersion'],this['editor']['model']['document']['history']['version']),_0x1bf277['fromVersion']===_0x1bf277['toVersion']?(0x0!==_0x1bf277['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x1bf277['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x1bf277['id'],this['_startingVersion']=_0x1bf277['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',_0x591b90=>!_0x591b90),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xc387d3=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4d78ec;for(const _0x3da115 in _0xc387d3){const _0x462660=_0x3da115,_0x2a8eb8=_0xc387d3[_0x462660];if('revisionHistoryLicenseKeyValid'==_0x2a8eb8||'revisionHistoryLicenseKeyInvalid'==_0x2a8eb8||'revisionHistoryLicenseKeyExpired'==_0x2a8eb8||'revisionHistoryLicenseKeyDomainLimit'==_0x2a8eb8||'revisionHistoryLicenseKeyNotAllowed'==_0x2a8eb8||'revisionHistoryLicenseKeyEvaluationLimit'==_0x2a8eb8||'revisionHistoryLicenseKeyTrialLimit'==_0x2a8eb8||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x2a8eb8||'revisionHistoryLicenseKeyUsageLimit'==_0x2a8eb8){delete _0xc387d3[_0x462660],_0x4d78ec=_0x2a8eb8,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4d78ec&&_0xc387d3['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4d78ec&&_0xc387d3['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4d78ec&&_0xc387d3['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4d78ec&&_0xc387d3['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4d78ec&&_0xc387d3['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x4d78ec&&_0xc387d3['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x4d78ec&&_0xc387d3['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4d78ec&&_0xc387d3['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0xcfe83f=this['repository']['getRevision'](0x0),_0x55573e=await this['getRevisionDocumentData'](_0xcfe83f),_0x1598e0=await this['getRevisionRootsAttributes'](_0xcfe83f);this['_replaceEditorDataWithRevisionData'](_0x55573e,_0x1598e0);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x9d14f8){this['_source']=_0x9d14f8;}async['update'](){const _0x1c0481=await this['_source']['getLatestVersion']();if(_0x1c0481>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1ec9ad=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1c0481});_0x1ec9ad['authors']=_0x1ec9ad['authorsIds']['map'](_0x3f6647=>this['editor']['plugins']['get']('Users')['getUser'](_0x3f6647)),this['currentRevision']['_update'](_0x1ec9ad);}}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'](_0x5feac2={},_0x1ac75a=null){const _0x45e0f7=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x1ac75a>this['currentRevision']['toVersion']&&(_0x1ac75a=null),null===_0x1ac75a&&(_0x1ac75a=await this['_source']['getLatestVersion']());const _0x227a2b=this['_getFromVersion'](_0x1ac75a),_0xc22164=this['buildRevisionData']({'from':_0x227a2b,'to':_0x1ac75a});if(this['currentRevision']['toVersion']<_0x1ac75a){const _0xe96add=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x1ac75a,'to':_0x1ac75a});_0xe96add['authors']=[],_0xe96add['authorsIds']=[],_0xe96add['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0xe96add,!0x0),delete _0xe96add['authors'],_0x45e0f7['push'](_0xe96add);}_0x5feac2['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5feac2['name']=_0x5feac2['name']||null,_0x5feac2['id']=_0x5feac2['id']||_0x5168c7(),_0x5feac2={..._0x5feac2,..._0xc22164};const _0x2b77e5=this['addRevisionData'](_0x5feac2);_0x45e0f7['push'](_0x5feac2);const _0x43762b=this['repository']['getIndex'](_0x2b77e5);if(0x0!==_0x43762b){const _0x648ce4=this['repository']['getRevision'](_0x43762b-0x1);if(_0x648ce4['fromVersion']!==_0x1ac75a){const _0x23ac0c=this['_revisionDataBuilder']['getData'](_0x1ac75a,_0x648ce4['toVersion']),_0xd0f3d8={'id':_0x648ce4['id'],'diffData':_0x23ac0c['diffData'],'authorsIds':_0x23ac0c['authorsIds'],'authors':_0x23ac0c['authorsIds']['map'](_0x4fc6a5=>this['editor']['plugins']['get']('Users')['getUser'](_0x4fc6a5)),'fromVersion':_0x1ac75a};_0x648ce4===this['currentRevision']&&(_0xd0f3d8['createdAt']=new Date(_0x5feac2['createdAt']['getTime']()+0xa)),_0x648ce4['_update'](_0xd0f3d8,!0x0),delete _0xd0f3d8['authors'],_0x45e0f7['push'](_0xd0f3d8);}}if(this['adapter']){for(const _0x4cbfae of _0x45e0f7)this['_bufferUpdate'](_0x4cbfae['id'],_0x4cbfae,!0x0);this['sendBufferedUpdates']();}return _0x2b77e5;}['addRevisionData'](_0x3d0f16){const _0x37bf21=this['repository']['createRevision'](_0x3d0f16);return this['adapter']&&_0x37bf21['on']('_update',(_0x176810,_0x479dcc,_0x703480)=>{_0x703480||(this['_bufferUpdate'](_0x479dcc['id'],_0x479dcc,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x37bf21,this['_findInsertionIndex'](_0x37bf21)),_0x37bf21;}async['getRevisionDocumentData'](_0xfef448){await this['_loadRevisionData'](_0xfef448);const _0x28df1e={};for(const _0xa271a3 in _0xfef448['diffData']){if(_0xfef448['diffData'][_0xa271a3]['attachChange']&&!_0xfef448['diffData'][_0xa271a3]['attachChange']['isAttached'])continue;const _0x4c5e5b=this['_removeRevisionMarkers'](JSON['parse'](_0xfef448['diffData'][_0xa271a3]['insertions'])),_0x380192=this['editor']['editing']['view']['document'],_0x4bef6=new _0x52f59f(_0x380192,_0x4c5e5b['map'](_0x5ec4e0=>V(_0x5ec4e0,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x28df1e[_0xa271a3]=this['editor']['data']['processor']['toData'](_0x4bef6),this['editor']['data']['processor']['useFillerType']('default');}return _0x28df1e;}async['getRevisionRootsAttributes'](_0xe18f38){await this['_loadRevisionData'](_0xe18f38);const _0xee8d0b={};for(const _0x43f1f9 in _0xe18f38['diffData'])_0xe18f38['diffData'][_0x43f1f9]['attachChange']&&!_0xe18f38['diffData'][_0x43f1f9]['attachChange']['isAttached']||(_0xee8d0b[_0x43f1f9]=_0xe18f38['diffData'][_0x43f1f9]['attributesAfter']||{});return _0xee8d0b;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x497d3c=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1ec99b=0x0;_0x1ec99b<_0x497d3c['length'];_0x1ec99b++){const _0x32c80f=_0x497d3c[_0x1ec99b];let _0x3dca64=!0x1;for(const _0x5015ac of Object['keys'](_0x32c80f))void 0x0===_0x32c80f[_0x5015ac]?delete _0x32c80f[_0x5015ac]:'id'!==_0x5015ac&&(_0x3dca64=!0x0);_0x3dca64||(_0x497d3c[_0x1ec99b]=null);}if(_0x497d3c=_0x497d3c['filter'](_0x2c5c4d=>null!==_0x2c5c4d),!_0x497d3c['length'])return;for(let _0x51555c=0x0;_0x51555c<_0x497d3c['length'];_0x51555c++){const _0x45ff35=_0x497d3c[_0x51555c];void 0x0!==_0x45ff35['fromVersion']&&void 0x0===_0x45ff35['toVersion']&&(_0x45ff35['toVersion']=this['repository']['getRevision'](_0x45ff35['id'])['toVersion']),void 0x0!==_0x45ff35['toVersion']&&void 0x0===_0x45ff35['fromVersion']&&(_0x45ff35['fromVersion']=this['repository']['getRevision'](_0x45ff35['id'])['fromVersion']);}const _0x25c8d2=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x497d3c,_0x25c8d2)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2688f0=>{if(_0x2688f0){for(const _0x455334 of _0x2688f0)this['setRevisionData']({'id':_0x455334['id'],'createdAt':_0x455334['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x43dd46,_0x20facb){let _0x42fb20=this['editor']['config']['get']('initialData'),_0x2ccd8a=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x42fb20){_0x42fb20={};for(const _0xb98c49 of this['editor']['model']['document']['getRootNames']())_0x42fb20[_0xb98c49]='';}if('string'==typeof _0x42fb20&&(_0x42fb20={'main':_0x42fb20}),void 0x0===_0x2ccd8a){_0x2ccd8a={};for(const _0x18e37e of this['editor']['model']['document']['getRootNames']())_0x2ccd8a[_0x18e37e]={};}let _0x1241c1=!0x1;const _0x3a42a1=Object['keys'](_0x42fb20),_0x5d4051=Object['keys'](_0x43dd46);for(const _0x1d230a of _0x3a42a1){if(_0x42fb20[_0x1d230a]!==_0x43dd46[_0x1d230a]&&''!==_0x42fb20[_0x1d230a]['trim']()){_0x1241c1=!0x0;break;}if(!_0x525435(_0x2ccd8a[_0x1d230a],_0x20facb[_0x1d230a])&&Object['keys'](_0x2ccd8a[_0x1d230a])['length']>0x0){_0x1241c1=!0x0;break;}}_0x1241c1||(_0x1241c1=_0x5d4051['some'](_0x2ed981=>!this['editor']['model']['document']['getRoot'](_0x2ed981))),_0x1241c1&&_0x4648e4('editor-initial-data-replaced-with-revision-data',{'editorData':_0x42fb20,'editorRootsAttributes':_0x2ccd8a,'revisionData':_0x43dd46,'revisionRootsAttributes':_0x20facb}),this['editor']['config']['set']('initialData',_0x43dd46),this['editor']['config']['set']('rootsAttributes',_0x20facb);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x20ed25=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x20ed25['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0xe596d5){const _0x2fc441=this['repository']['getRevisions']();_0x2fc441['reverse']();let _0xb082fe=0x0;for(;_0xb082fe<_0x2fc441['length'];){const _0x3b25b4=_0x2fc441[_0xb082fe];if(_0x3b25b4===this['currentRevision']){_0xb082fe++;continue;}if(_0x3b25b4['id']===this['_initialRevisionId'])break;const _0x569f92=_0xe596d5['toVersion']-_0x3b25b4['toVersion']||_0xe596d5['fromVersion']-_0x3b25b4['fromVersion'];if(_0x569f92>0x0)break;if(_0x569f92<0x0)_0xb082fe++;else{if(!_0xe596d5['creator']&&_0x3b25b4['creator'])break;if(_0x3b25b4['creator']||!_0xe596d5['creator']){if(_0xe596d5['createdAt']>_0x3b25b4['createdAt'])break;_0xb082fe++;}else _0xb082fe++;}}return _0xb082fe;}['setRevisionData'](_0x3cbcb8){const _0x894636=this['repository']['getRevision'](_0x3cbcb8['id']);if(_0x3cbcb8['createdAt']&&(_0x3cbcb8['createdAt']=new Date(_0x3cbcb8['createdAt'])),_0x3cbcb8['authorsIds']){const _0x7d2682=this['editor']['plugins']['get']('Users');_0x3cbcb8['authors']=_0x3cbcb8['authorsIds']['map'](_0x106c0d=>_0x7d2682['getUser'](_0x106c0d));}_0x894636['_update'](_0x3cbcb8,!0x0);}['buildRevisionData']({revision:_0x3f86fc=null,from:_0x4d3254=null,to:_0x40369c=null}){_0x4d3254=null!==_0x4d3254?_0x4d3254:_0x3f86fc['fromVersion'],_0x40369c=null!==_0x40369c?_0x40369c:_0x3f86fc['toVersion'];const _0xd7c19c=this['_revisionDataBuilder']['getData'](_0x4d3254,_0x40369c),_0x38042f={'diffData':_0xd7c19c['diffData'],'authorsIds':_0xd7c19c['authorsIds'],'fromVersion':_0x4d3254,'toVersion':_0x40369c};if(!_0x3f86fc||_0x40369c!==_0x3f86fc['toVersion']){const _0xbae43b=_0x40369c-0x1,_0x537132=this['_source']['history']['getOperation'](_0xbae43b);_0x38042f['createdAt']=_0x537132&&_0x537132['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4d3254===this['_loadedStateData']['fromVersion']){for(const _0x5d8883 of this['_loadedStateData']['authors'])_0x38042f['authorsIds']['includes'](_0x5d8883['id'])||_0x38042f['authorsIds']['push'](_0x5d8883['id']);}return _0x38042f;}['_loadRevisionData'](_0x3b2328){if(!_0x3b2328||_0x3b2328['diffData'])return Promise['resolve']();{const _0x3453f9=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x3453f9,'revisionId':_0x3b2328['id']})['then'](_0x58d390=>{_0x3b2328['diffData']=_0x58d390['diffData'];});}}['_bufferUpdate'](_0x9b2a4b,_0x1500f3,_0xbdb3e3){if(this['_bufferedUpdates']['has'](_0x9b2a4b)){const _0x45a56e=this['_bufferedUpdates']['get'](_0x9b2a4b);_0x1500f3=_0xbdb3e3?{..._0x45a56e,..._0x1500f3}:{..._0x1500f3,..._0x45a56e};}this['_bufferedUpdates']['set'](_0x9b2a4b,_0x1500f3);}['_getFromVersion'](_0x5d24b7){const _0x2ffad5=this['repository']['getRevisions']();_0x2ffad5['reverse'](),_0x2ffad5['shift']();const _0x17761b=_0x2ffad5['find'](_0x21cae7=>_0x21cae7['toVersion']<=_0x5d24b7)['toVersion'];return _0x17761b<this['_startingVersion']?this['_startingVersion']:_0x17761b;}['_createInitialRevision'](_0xefb685){const _0x41636c=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x41636c)this['_initialRevisionId']=_0x41636c['id'];else{const _0x47237b=!this['editor']['model']['document']['roots']['find'](_0x5566b1=>this['editor']['model']['hasContent'](_0x5566b1)),_0x29b780=this['editor']['plugins']['get']('Users')['me']['id'],_0x37c37a=R(this['editor']['locale'],_0x47237b?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0xefb685,'to':_0xefb685,'id':this['_initialRevisionId'],'name':_0x37c37a,'creatorId':_0x29b780});}}['_createCurrentRevision'](_0x1c4f76){const _0x2d203d=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2d203d),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1c4f76,'to':_0x1c4f76,'id':_0x2d203d,'name':'','creatorId':null}));}['_makeRevision']({name:_0x11718f,from:_0x57f35f,to:_0x3368c6,creatorId:_0x526f0d,id:_0x35ecd8}){const _0x489888=this['buildRevisionData']({'from':_0x57f35f,'to':_0x3368c6});_0x489888['name']=_0x11718f,_0x489888['creatorId']=_0x526f0d,_0x489888['id']=_0x35ecd8;const _0x3e56ae=this['addRevisionData'](_0x489888);return this['adapter']&&this['_bufferUpdate'](_0x489888['id'],_0x489888,!0x0),_0x3e56ae;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x3edab9){return(_0x3edab9=_0x3edab9['filter'](_0xc7a9b2=>!_0xc7a9b2['name']||'revision-start'!==_0xc7a9b2['name']&&'revision-end'!==_0xc7a9b2['name']))['forEach'](_0x46ede0=>{'string'!=typeof _0x46ede0&&(_0x46ede0['children']=this['_removeRevisionMarkers'](_0x46ede0['children']),_0x46ede0['attributes']=_0x46ede0['attributes']['filter'](_0x2a0019=>!_0x2a0019[0x0]['startsWith']('data-revision-')));}),_0x3edab9;}}function V(_0xa5b0b6,_0x1a9e5a){const _0x5ef8d8=_0x1a9e5a['editing']['view']['document'];if('string'==typeof _0xa5b0b6)return new _0x176147(_0x5ef8d8,_0xa5b0b6);{const _0x3bb56b=_0xa5b0b6['children']['map'](_0x3866f1=>V(_0x3866f1,_0x1a9e5a));return new(C[_0xa5b0b6['type']]||_0x241c33)(_0x5ef8d8,_0xa5b0b6['name'],_0xa5b0b6['attributes'],_0x3bb56b);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x58b21f){this['editor']=_0x58b21f,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'](_0x328775){this['source']=_0x328775;const _0x1b6f16=new Map(),_0x195287=new Map(),_0x5c87b5=this['editor']['model']['document']['roots']['map'](_0x34a7a4=>_0x34a7a4['rootName']);for(const _0x3547d3 of _0x5c87b5){const _0x47d7cc=this['editor']['model']['document']['getRoot'](_0x3547d3),_0x585ee1=F(_0x47d7cc);_0x1b6f16['set'](_0x3547d3,_0x585ee1),_0x195287['set'](_0x3547d3,Object['fromEntries'](_0x47d7cc['getAttributes']()));}const _0x480769=Array['from'](this['editor']['model']['markers'])['map'](_0x33d256=>[_0x33d256['name'],_0x33d256['getRange']()]),_0x187fa5=this['source']['version'];this['_saveMetaData'](_0x187fa5,_0x1b6f16,_0x480769,_0x195287),this['_startingRevisionId']=this['_revisionId'];const _0x60b657=new Map(),_0x3f154b=new Map();for(const _0x29fe1b of _0x5c87b5){const _0x48433a=B(_0x29fe1b);_0x60b657['set'](_0x29fe1b,_0x48433a),_0x3f154b['set'](_0x29fe1b,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x60b657,[],_0x3f154b);}['getData'](_0x340278,_0x238ac4){if(this['_lastFrom']===_0x340278&&this['_lastTo']<=_0x238ac4)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x238ac4,!0x0);else{if(!this['_savedMetaData']['has'](_0x340278)){const _0xb9a1f7=this['_getPreviousFrom'](_0x340278);this['_calculateMetaData'](_0xb9a1f7,_0x340278,!0x1);}this['_calculateMetaData'](_0x340278,_0x238ac4,!0x0);}return this['_lastFrom']=_0x340278,this['_lastTo']=_0x238ac4,this['_getState']();}['loadState'](_0x1abe3f){this['_reset'](),this['_lastFrom']=_0x1abe3f['fromVersion'],this['_lastTo']=_0x1abe3f['toVersion'];for(const _0x153ce2 in _0x1abe3f['diffData']){const _0x594a07=_0x1abe3f['diffData'][_0x153ce2]['attachChange'],_0x294fcb=_0x10dfce(_0x1abe3f['diffData'][_0x153ce2]['attributesBefore'])||{},_0x5a886d=this['_makeModelFromViewString'](_0x1abe3f['diffData'][_0x153ce2]['deletions']);_0x5a886d['rootName']=_0x153ce2,_0x5a886d['_isAttached']=!_0x594a07||!_0x594a07['isAttached'],_0x5a886d['isAttached']=()=>_0x5a886d['_isAttached'],this['_baseRoots']['set'](_0x153ce2,_0x5a886d),this['_baseRootsAttributes']['set'](_0x153ce2,_0x294fcb),_0x594a07&&this['_touchedRoots']['set'](_0x153ce2,_0x594a07);const _0x597f93=this['_makeIdsRoot'](_0x5a886d);this['_baseIdsRoots']['set'](_0x153ce2,_0x597f93);for(const [_0x8cc16a,_0xdd4bed]of _0x5a886d['markers']){if(!_0x8cc16a['startsWith']('revision:'))continue;const _0x12a6e8=_0x8cc16a['split'](':')[0x2];for(const _0x25a41f of _0xdd4bed['getWalker']({'singleCharacters':!0x0})){const _0x17817b=this['_getVidAttributeName'](_0x25a41f),_0x11cb60='elementEnd'==_0x25a41f['type']?_0x25a41f['previousPosition']['path']['slice'](0x0,-0x1):_0x25a41f['previousPosition']['path'],_0x15f74e=_0x597f93['getNodeByPath'](_0x11cb60)['getAttribute'](_0x17817b);this['_touched']['set'](_0x15f74e,{'userId':_0x12a6e8});}}}this['_startingRevisionId']=this['_revisionId'];const _0x3400bb=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x3421d3=>!this['_touched']['has'](_0x3421d3));let _0x48c492=0x0;const _0x200d2a=new Map();for(const _0xed30d2 in _0x1abe3f['diffData']){const _0x4c02e7=_0x1abe3f['diffData'][_0xed30d2]['attachChange'],_0x25ee1d=_0x10dfce(_0x1abe3f['diffData'][_0xed30d2]['attributesAfter'])||{},_0x22b16d=this['_makeModelFromViewString'](_0x1abe3f['diffData'][_0xed30d2]['insertions']);_0x22b16d['rootName']=_0xed30d2,_0x22b16d['_isAttached']=!_0x4c02e7||_0x4c02e7['isAttached'],_0x22b16d['isAttached']=()=>_0x22b16d['_isAttached'],this['_diffRoots']['set'](_0xed30d2,_0x22b16d),this['_diffRootsAttributes']['set'](_0xed30d2,_0x25ee1d);const _0x24c4b7=this['_makeIdsRoot'](_0x22b16d,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0xed30d2,_0x24c4b7),_0x200d2a['set'](_0xed30d2,_0x22b16d['isAttached']()?_0x25ee1d:{});for(const [_0x2797db,_0x5086b8]of _0x22b16d['markers']){if(!_0x2797db['startsWith']('revision:'))continue;const _0x17827e=_0x2797db['split'](':')[0x2];for(const _0x1e5fc4 of _0x5086b8['getWalker']({'singleCharacters':!0x0})){const _0x25f1cf=this['_getVidAttributeName'](_0x1e5fc4),_0x9b1db6=this['_revisionId']++,_0x5f227c='elementEnd'==_0x1e5fc4['type']?_0x1e5fc4['previousPosition']['path']['slice'](0x0,-0x1):_0x1e5fc4['previousPosition']['path'];_0x24c4b7['getNodeByPath'](_0x5f227c)['_setAttribute'](_0x25f1cf,_0x9b1db6),this['_touched']['set'](_0x9b1db6,{'userId':_0x17827e});}}for(const _0x2e5821 of this['editor']['model']['createRangeIn'](_0x22b16d)['getWalker']({'singleCharacters':!0x0})){const _0x4fd575=this['_getVidAttributeName'](_0x2e5821),_0xadd13f='elementEnd'==_0x2e5821['type']?_0x2e5821['previousPosition']['path']['slice'](0x0,-0x1):_0x2e5821['previousPosition']['path'],_0x1ea0a6=_0x24c4b7['getNodeByPath'](_0xadd13f);_0x1ea0a6['getAttribute'](_0x4fd575)>0x0||_0x1ea0a6['_setAttribute'](_0x4fd575,_0x3400bb[_0x48c492++]);}for(const [_0x586561,_0x46055d]of _0x22b16d['markers'])_0x586561['startsWith']('revision:')||this['_markers']['set'](_0x586561,_0x46055d);}const _0x1f09d7=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x1f09d7),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1f09d7,0x1));const _0x2498c2=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2498c2),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2498c2,0x1));const _0x49c4d8=Array['from'](this['_diffRoots'])['map'](([_0x55b846,_0x1cbbec])=>[_0x55b846,F(_0x1cbbec)]);this['_saveMetaData'](this['_lastTo'],_0x49c4d8,this['_markers'],_0x200d2a);}['_makeModelFromViewString'](_0x4a26d6){const _0x23f442=JSON['parse'](_0x4a26d6),_0x11c770=this['editor']['editing']['view']['document'],_0x1e3867=new _0x52f59f(_0x11c770,_0x23f442['map'](_0x5d10c7=>V(_0x5d10c7,this['editor'])));return this['editor']['data']['toModel'](_0x1e3867);}['_saveMetaData'](_0x2ec5ee,_0x4f2275,_0x9fe5f,_0x4b3674){const _0x128930=new Map(_0x4f2275),_0x1e5f71=new Map(_0x10dfce(_0x4b3674)),_0x42eab7=new Map();for(const [_0x27e86d,_0x19decd]of _0x9fe5f)_0x42eab7['set'](_0x27e86d,{'start':_0x19decd['start']['clone'](),'end':_0x19decd['end']['clone'](),'rootName':_0x19decd['root']['rootName']});this['_savedMetaData']['set'](_0x2ec5ee,{'roots':_0x128930,'markers':_0x42eab7,'rootsAttributes':_0x1e5f71});}['_removeMetaData'](_0x1b8f9f){this['_savedMetaData']['delete'](_0x1b8f9f);}['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'](_0x347d28,_0x2c58dc=null){let _0x111efd=null;_0x347d28['is']('documentFragment')||(_0x111efd=new ft(_0x347d28['name'],{'vid_start':null===_0x2c58dc?this['_revisionId']++:_0x2c58dc++}));const _0x49ff06=[];for(const _0x228ee0 of _0x347d28['getChildren']())if(_0x228ee0['is']('element')){_0x49ff06['push'](this['_makeIdsRoot'](_0x228ee0,_0x2c58dc));const _0x2363da=_0x49ff06[_0x49ff06['length']-0x1];null!==_0x2c58dc&&(_0x2c58dc=_0x2363da['is']('element','$text')?_0x2363da['getAttribute']('vid')+0x1:_0x2363da['getAttribute']('vid_end')+0x1);}else{for(let _0x7b21db=0x0;_0x7b21db<_0x228ee0['offsetSize'];_0x7b21db++)_0x49ff06['push'](new ft('$text',{'vid':null===_0x2c58dc?this['_revisionId']++:_0x2c58dc++}));}if(_0x347d28['is']('documentFragment')){const _0x14d2e4=B(_0x347d28['rootName']);return _0x14d2e4['_insertChild'](0x0,_0x49ff06),_0x14d2e4;}return _0x111efd['_setAttribute']('vid_end',null===_0x2c58dc?this['_revisionId']++:_0x2c58dc++),_0x111efd['_insertChild'](0x0,_0x49ff06),_0x111efd;}['_calculateMetaData'](_0x20b00c,_0x5d44ba,_0x4e1002){this['_reset']();const {roots:_0x394beb,markers:_0x7a24e5,rootsAttributes:_0x319ab5}=this['_savedMetaData']['get'](_0x20b00c);this['_baseRoots']=new Map(_0x394beb),this['_baseRootsAttributes']=new Map(_0x10dfce(_0x319ab5));for(const [_0x5937ed,_0x24ddf7]of this['_baseRoots'])if('$graveyard'!==_0x5937ed&&(this['_diffRoots']['set'](_0x5937ed,F(_0x24ddf7)),this['_diffRootsAttributes']=new Map(_0x10dfce(_0x319ab5)),_0x4e1002)){const _0x220cae=this['_revisionId'];this['_idsRoots']['set'](_0x5937ed,this['_makeIdsRoot'](_0x24ddf7)),this['_baseIdsRoots']['set'](_0x5937ed,this['_makeIdsRoot'](_0x24ddf7,_0x220cae));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x4e1002&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x32986d,_0x1930b7]of _0x7a24e5){const _0x142c70=this['_baseRoots']['get'](_0x1930b7['rootName']),_0x23f7e3=this['_diffRoots']['get'](_0x1930b7['rootName']),_0x50550c=new vt(this['_fixPosition'](_0x1930b7['start'],_0x142c70),this['_fixPosition'](_0x1930b7['end'],_0x142c70)),_0x5efad8=this['_fixRange'](_0x50550c,_0x23f7e3);_0x142c70['markers']['set'](_0x32986d,_0x50550c),this['_markers']['set'](_0x32986d,_0x5efad8);}this['_applyOperations'](_0x20b00c,_0x5d44ba,_0x4e1002);}['_applyOperations'](_0x217137,_0x375abf,_0x524260){for(const _0x6da9ff of this['source']['getOperations'](_0x217137,_0x375abf))this['_handleOperation'](_0x6da9ff,_0x524260);for(const _0x215127 of this['_diffRoots']['values']())_0x215127['markers']['clear']();for(const [_0x1c6062,_0x454759]of this['_markers']){this['_diffRoots']['get'](_0x454759['root']['rootName'])['markers']['set'](_0x1c6062,_0x454759['clone']());}const _0x67ba49=new Map(),_0x544056=new Map();for(const [_0x534290,_0x43ca4d]of this['_diffRoots'])_0x67ba49['set'](_0x534290,F(_0x43ca4d)),_0x544056['set'](_0x534290,this['_diffRootsAttributes']['get'](_0x534290));this['_saveMetaData'](_0x375abf,_0x67ba49,this['_markers'],_0x544056);}['_getPreviousFrom'](_0x4bc492){const _0x4a2269=Array['from'](this['_savedMetaData']['keys']());_0x4a2269['sort']((_0x285a3c,_0x35fa11)=>_0x285a3c-_0x35fa11),_0x4a2269['reverse']();for(const _0x4ebf42 of _0x4a2269)if(_0x4ebf42<_0x4bc492)return _0x4ebf42;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x21375b,_0x1d6407){const _0x5068fc=Array['from'](_0x1d6407['markers'])['map'](([_0x26ed2c,_0x33edac])=>[_0x26ed2c,this['_fixRange'](_0x33edac,_0x21375b)]);_0x21375b['markers']=new Map(_0x5068fc);}['_transformMarkers'](_0x561ea0){for(const _0x36dd26 of this['_markers']['values']()){const _0x3e73d7=_0x36dd26['getTransformedByOperation'](_0x561ea0),_0x54a53a=vt['_createFromRanges'](_0x3e73d7);_0x36dd26['start']=_0x54a53a['start'],_0x36dd26['end']=_0x54a53a['end'];}}['_handleOperation'](_0x37a3cb,_0x517758){if('addRoot'!=_0x37a3cb['type']&&'detachRoot'!=_0x37a3cb['type']){if('insert'==_0x37a3cb['type']){const _0x43111b=_0x37a3cb['position']['root']['rootName'];this['_diffRoots']['has'](_0x43111b)||(this['_diffRoots']['set'](_0x43111b,B(_0x43111b,!0x0)),this['_diffRootsAttributes']['set'](_0x43111b,{}),_0x517758&&this['_idsRoots']['set'](_0x43111b,B(_0x43111b,!0x0)));}else{if('addRootAttribute'==_0x37a3cb['type']||'removeRootAttribute'==_0x37a3cb['type']||'changeRootAttribute'==_0x37a3cb['type'])return void this['_handleRootAttributeOperation'](_0x37a3cb);'marker'==_0x37a3cb['type']&&this['_handleMarkerOperation'](_0x37a3cb);}if('marker'!==_0x37a3cb['type']){const _0x2f8152=this['_cloneOperation'](_0x37a3cb,this['_diffRoots']);_0x2f8152['_execute'](),this['_transformMarkers'](_0x2f8152);}if(_0x517758)switch(_0x37a3cb['type']){case'insert':this['_handleInsertOperation'](_0x37a3cb);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x37a3cb);break;case'merge':this['_handleMergeOperation'](_0x37a3cb);break;case'split':this['_handleSplitOperation'](_0x37a3cb);}}else this['_handleRootOperation'](_0x37a3cb,_0x517758);}['_cloneOperation'](_0x14d1fa,_0x3963aa){const _0x386c7e=_0x14d1fa['clone']();return _0x386c7e['_authorId']=_0x14d1fa['_authorId'],this['_fixOperation'](_0x386c7e,_0x3963aa),_0x386c7e;}['_getBaseVids'](_0x4537f1){return _0x4537f1['map'](_0x1db4e6=>{const _0x6c757e=this['_getVidAttributeName'](_0x1db4e6);return Number(_0x1db4e6['item']['getAttribute'](_0x6c757e));});}['_generateTape'](_0x17a8b0,_0x7d5b5a){if(_0x17a8b0['is']('element','$text'))_0x7d5b5a['push']({'item':_0x17a8b0,'type':'text'});else{_0x17a8b0['is']('element')&&_0x7d5b5a['push']({'item':_0x17a8b0,'type':'elementStart'});for(const _0x2626e8 of _0x17a8b0['getChildren']())this['_generateTape'](_0x2626e8,_0x7d5b5a);_0x17a8b0['is']('element')&&_0x7d5b5a['push']({'item':_0x17a8b0,'type':'elementEnd'});}return _0x7d5b5a;}['_getState'](){const _0x26e1b9=new Map(this['_touched']),_0x280be6=new Map(_0x26e1b9),_0x283ce6=new Map(),_0x40fcca={'insertions':{},'deletions':{}},_0x4b3561={'insertions':{},'deletions':{}},_0x346a69=new Map(),_0x3c5d5e=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3c5d5e['delete']('$graveyard');for(const _0x3abe89 of _0x3c5d5e){const _0x3c6daf=this['_diffRoots']['get'](_0x3abe89)||B(_0x3abe89,!0x1),_0x1d7f66=this['_baseRoots']['get'](_0x3abe89)||B(_0x3abe89,!0x1);_0x3c6daf['isAttached']()||_0x1d7f66['isAttached']()?(_0x40fcca['insertions'][_0x3abe89]=F(_0x3c6daf),_0x40fcca['deletions'][_0x3abe89]=F(_0x1d7f66),this['_copyMarkers'](_0x40fcca['deletions'][_0x3abe89],_0x1d7f66),this['_copyMarkers'](_0x40fcca['insertions'][_0x3abe89],_0x3c6daf),_0x4b3561['insertions'][_0x3abe89]=this['_generateTape'](this['_idsRoots']['get'](_0x3abe89),[]),_0x4b3561['deletions'][_0x3abe89]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3abe89)||B(_0x3abe89,!0x1),[])):_0x3c5d5e['delete'](_0x3abe89);}for(const _0x2b24aa of _0x3c5d5e){const _0x4e4ed0=_0x4b3561['insertions'][_0x2b24aa];for(const _0x4ca30a of _0x4e4ed0){const _0x111f66=this['_getVidAttributeName'](_0x4ca30a),_0x4faaab=_0x4ca30a['item']['getAttribute'](_0x111f66);_0x280be6['delete'](_0x4faaab),_0x4faaab>=this['_startingRevisionId']&&_0x283ce6['set'](_0x4faaab,_0x26e1b9['get'](_0x4faaab));}}for(const _0x1f1e4c of _0x3c5d5e){const _0x379b10=_0x4b3561['insertions'][_0x1f1e4c],_0x2a94f0=this['_getBaseVids'](_0x4b3561['deletions'][_0x1f1e4c]);let _0x1b39c9=0x0;for(const _0x58a143 of _0x379b10){const _0x1b46e6=this['_getVidAttributeName'](_0x58a143),_0x4949a9=_0x58a143['item']['getAttribute'](_0x1b46e6);if(!_0x283ce6['has'](_0x4949a9)&&!_0x346a69['has'](_0x4949a9)){if(_0x280be6['has'](_0x4949a9))_0x1b39c9++;else{if(_0x4949a9!=_0x2a94f0[_0x1b39c9]){const _0x2bc431=_0x26e1b9['get'](_0x4949a9)||_0x26e1b9['get'](_0x2a94f0[_0x1b39c9]);for(;_0x4949a9!=_0x2a94f0[_0x1b39c9];)_0x280be6['has'](_0x2a94f0[_0x1b39c9])||(_0x346a69['set'](_0x2a94f0[_0x1b39c9],_0x2bc431),_0x26e1b9['set'](_0x2a94f0[_0x1b39c9],_0x2bc431)),_0x1b39c9++;}_0x1b39c9++;}}}}for(const _0x50d93a of _0x3c5d5e){const _0x21dc6c=_0x4b3561['insertions'][_0x50d93a];for(const _0x4966b8 of _0x21dc6c){const _0x2f2c2e=this['_getVidAttributeName'](_0x4966b8),_0x1dbe84=_0x4966b8['item']['getAttribute'](_0x2f2c2e);if(_0x346a69['has'](_0x1dbe84)){const _0xf07e34=_0x346a69['get'](_0x1dbe84);_0x280be6['has'](_0x1dbe84)||_0x280be6['set'](_0x1dbe84,{..._0xf07e34}),_0x283ce6['set'](_0x1dbe84,{..._0xf07e34});}}}for(const _0x43c4ad of _0x280be6['keys']())_0x43c4ad>=this['_startingRevisionId']&&_0x280be6['delete'](_0x43c4ad);const _0x58e4f=new Map();for(const _0xc49b6c of _0x3c5d5e){let _0x4c2811=_0x4b3561['insertions'][_0xc49b6c];for(const _0x50da53 of _0x4c2811)if(_0x50da53['item']['is']('element','tableCell')){const _0x4de974=this['_getVidAttributeName'](_0x50da53),_0x1a0b7d=_0x50da53['item']['getAttribute'](_0x4de974);if(_0x283ce6['has'](_0x1a0b7d)){const _0xdefe54=_0x50da53['item']['parent']['parent']['getAttribute']('vid_start'),_0x1266bc=_0x58e4f['get'](_0xdefe54)||new Set();_0x1266bc['add'](_0x283ce6['get'](_0x1a0b7d)['userId']),_0x58e4f['set'](_0xdefe54,_0x1266bc);}}_0x4c2811=_0x4b3561['deletions'][_0xc49b6c];for(const _0x1a881e of _0x4c2811)if(_0x1a881e['item']['is']('element','tableCell')){const _0x21277c=this['_getVidAttributeName'](_0x1a881e),_0x115a09=_0x1a881e['item']['getAttribute'](_0x21277c);if(_0x280be6['has'](_0x115a09)){const _0x109ace=_0x1a881e['item']['parent']['parent']['getAttribute']('vid_start'),_0x5d1d60=_0x58e4f['get'](_0x109ace)||new Set();_0x5d1d60['add'](_0x280be6['get'](_0x115a09)['userId']),_0x58e4f['set'](_0x109ace,_0x5d1d60);}}for(const _0x31e2db of _0x58e4f['keys']())(_0x283ce6['has'](_0x31e2db)||_0x280be6['has'](_0x31e2db))&&_0x58e4f['delete'](_0x31e2db);}for(const _0x1adeee of _0x3c5d5e){const _0x1dc9c8=_0x4b3561['insertions'][_0x1adeee];let _0x31ec82=null,_0x3e5830=null;for(const _0x1d921c of _0x1dc9c8){const _0x14eba3=this['_getVidAttributeName'](_0x1d921c),_0xf679d=_0x1d921c['item']['getAttribute'](_0x14eba3),_0xd015c9=_0x58e4f['get'](_0xf679d);_0xd015c9&&'elementStart'==_0x1d921c['type']&&(_0x31ec82=Array['from'](_0xd015c9)[0x0],_0x3e5830=_0x1d921c['item']['getAttribute']('vid_end')),_0x31ec82&&(_0x280be6['set'](_0xf679d,{'userId':_0x31ec82}),_0x283ce6['set'](_0xf679d,{'userId':_0x31ec82})),_0xf679d==_0x3e5830&&(_0x31ec82=null,_0x3e5830=null);}}const _0x5254e8={},_0x1dec19=new Set();for(const _0x529be3 of _0x3c5d5e){const _0x2c49ed=_0x40fcca['deletions'][_0x529be3],_0x460433=_0x40fcca['insertions'][_0x529be3];for(const {userId:_0x201654}of this['_touchedMarkers']['values']())null!==_0x201654&&_0x1dec19['add'](_0x201654);for(const {userId:_0x12f567}of this['_touchedRoots']['values']())null!==_0x12f567&&_0x1dec19['add'](_0x12f567);this['_markChanges'](_0x460433,_0x4b3561['insertions'][_0x529be3],_0x283ce6,'insertion',_0x1dec19),this['_markChanges'](_0x2c49ed,_0x4b3561['deletions'][_0x529be3],_0x280be6,'deletion',_0x1dec19),_0x5254e8[_0x529be3]={'insertions':this['_prepareViewToSave'](_0x460433),'deletions':this['_prepareViewToSave'](_0x2c49ed),'attachChange':this['_touchedRoots']['get'](_0x529be3)||null,'attributesBefore':_0x10dfce(this['_baseRootsAttributes']['get'](_0x529be3))||{},'attributesAfter':_0x10dfce(this['_diffRootsAttributes']['get'](_0x529be3))};}return{'diffData':_0x5254e8,'authorsIds':Array['from'](_0x1dec19)};}['_processRootBeforeSave'](_0x3e6775){for(const [,_0x4cd08d]of _0x3e6775['markers']){const _0x47dd96=_0x4cd08d['start']['getAncestors']()['filter'](_0x3dac5d=>'tableCell'==_0x3dac5d['name']);for(const _0x5699b7 of _0x47dd96)0x1==_0x5699b7['childCount']&&_0x5699b7['getChild'](0x0)['is']('element','paragraph')&&_0x5699b7['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x19ff17){this['_processRootBeforeSave'](_0x19ff17);const _0x1c54b0=this['editor']['data']['toView'](_0x19ff17,{}),_0x55768a=Array['from'](_0x1c54b0['getChildren']())['map'](_0x535c81=>this['_getViewJson'](_0x535c81));return JSON['stringify'](_0x55768a);}['_getViewJson'](_0x10b596){if(_0x10b596['is']('$text'))return _0x10b596['data'];{const _0x1f4c70=_0x10b596;return{'type':Object['keys'](C)['find'](_0x47385a=>_0x10b596 instanceof C[_0x47385a]),'name':_0x1f4c70['name'],'attributes':Array['from'](_0x1f4c70['getAttributes']()),'children':Array['from'](_0x1f4c70['getChildren']())['map'](_0x5d7341=>this['_getViewJson'](_0x5d7341))};}}['_markChanges'](_0x2f8fac,_0x3ccac4,_0x3d914e,_0x4ccafd,_0x5cfe09){let _0x334bd4=null,_0x2f66ab=null,_0x3ddc01=0x0;const _0x259cbd=this['editor']['model'];for(let _0x5b629f=0x0;_0x5b629f<_0x3ccac4['length'];_0x5b629f++){const _0xa2297d=this['_getVidAttributeName'](_0x3ccac4[_0x5b629f]),_0x41943b=_0x3ccac4[_0x5b629f]['item']['getAttribute'](_0xa2297d),_0x125e91=_0x3d914e['get'](_0x41943b),_0x3789cb=_0x5b629f==_0x3ccac4['length']-0x1;(!_0x334bd4&&_0x125e91&&(_0x334bd4=_0x125e91,_0x2f66ab=_0x3ccac4[_0x5b629f]),_0x334bd4&&(!_0x125e91||_0x125e91['userId']!=_0x334bd4['userId']))&&(_0x4a200f(_0x125e91,J(_0x2f66ab,_0x2f8fac,_0x259cbd),J(_0x3ccac4[_0x5b629f],_0x2f8fac,_0x259cbd)),_0x334bd4=_0x125e91||null,_0x2f66ab=_0x125e91?_0x3ccac4[_0x5b629f]:null),_0x334bd4&&_0x3789cb&&_0x4a200f(_0x125e91,J(_0x2f66ab,_0x2f8fac,_0x259cbd),q(_0x3ccac4[_0x5b629f],_0x2f8fac,_0x259cbd));}function _0x4a200f(_0x31cc82,_0x23a42c,_0x52a8d8){const _0x48474b=_0x334bd4['userId'],_0x592999='revision:'+_0x4ccafd+':'+_0x48474b+':'+_0x3ddc01++,_0x16ebe4=_0x259cbd['createRange'](_0x23a42c,_0x52a8d8);_0x2f8fac['markers']['set'](_0x592999,_0x16ebe4),null!==_0x48474b&&_0x5cfe09['add'](_0x48474b);}}['_getVidAttributeName'](_0x2245ea){switch(_0x2245ea['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x59a81f,_0x50fd04){_0x59a81f['baseVersion']=null;for(const _0x4b683e in _0x59a81f){const _0x1739c8=_0x59a81f[_0x4b683e];if(_0x1739c8 instanceof gt){const _0x5a53f9=_0x50fd04['get'](_0x1739c8['root']['rootName']);_0x59a81f[_0x4b683e]=this['_fixPosition'](_0x1739c8,_0x5a53f9);}if(_0x1739c8 instanceof vt){const _0x335b95=_0x50fd04['get'](_0x1739c8['root']['rootName']);_0x59a81f[_0x4b683e]=this['_fixRange'](_0x1739c8,_0x335b95);}'root'===_0x4b683e&&(_0x59a81f['root']=_0x50fd04['get'](_0x59a81f['root']['rootName']));}}['_fixRange'](_0x4d1e91,_0xeaa74f){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4d1e91['start'],_0xeaa74f),this['_fixPosition'](_0x4d1e91['end'],_0xeaa74f));}['_fixPosition'](_0x5f322d,_0x45cf01){return this['editor']['model']['createPositionFromPath'](_0x45cf01,_0x5f322d['path'],_0x5f322d['stickiness']);}['_handleInsertOperation'](_0x1db5b3){const _0x734216=this['_idsRoots']['get'](_0x1db5b3['position']['root']['rootName']),_0x2c3c36=this['_fixPosition'](_0x1db5b3['position'],_0x734216),_0x5e5608=null===_0x1db5b3['_authorId']?null:_0x1db5b3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x421f65=_0x2c3c36['parent'],_0x480d94=this['_revisionId'],_0x138b1d=[];for(const _0x2922ed of _0x1db5b3['nodes'])if(_0x2922ed['is']('element'))_0x138b1d['push'](this['_makeIdsRoot'](_0x2922ed));else{for(let _0x5928e0=0x0;_0x5928e0<_0x2922ed['offsetSize'];_0x5928e0++)_0x138b1d['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x55bbd8=this['_revisionId'];for(let _0x55fe7c=_0x480d94;_0x55fe7c<_0x55bbd8;_0x55fe7c++)this['_touched']['set'](_0x55fe7c,{'userId':_0x5e5608});_0x421f65['_insertChild'](_0x2c3c36['offset'],_0x138b1d);}['_handleMoveOperation'](_0x7fbd94){(_0x7fbd94=this['_cloneOperation'](_0x7fbd94,this['_idsRoots']))['_execute']();const _0x4d7b94=null===_0x7fbd94['_authorId']?null:_0x7fbd94['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1ed199=_0x7fbd94['getMovedRangeStart'](),_0x1bb435=_0x1ed199['parent'],_0xdc9739=_0x1ed199['offset'];!function _0x396e81(_0x49b838,_0xb26760,_0x4aa655,_0x51e20c){for(let _0x31c175=_0x4aa655;_0x31c175<_0x51e20c;_0x31c175++){const _0x37b86d=_0xb26760['getChild'](_0x31c175);_0x37b86d['is']('element','$text')?_0x49b838['set'](_0x37b86d['getAttribute']('vid'),{'userId':_0x4d7b94}):(_0x49b838['set'](_0x37b86d['getAttribute']('vid_start'),{'userId':_0x4d7b94}),_0x396e81(_0x49b838,_0x37b86d,0x0,_0x37b86d['childCount']),_0x49b838['set'](_0x37b86d['getAttribute']('vid_end'),{'userId':_0x4d7b94}));}}(this['_touched'],_0x1bb435,_0xdc9739,_0xdc9739+_0x7fbd94['howMany']);}['_handleMergeOperation'](_0x324a40){const _0x39b1d8=null===(_0x324a40=this['_cloneOperation'](_0x324a40,this['_idsRoots']))['_authorId']?null:_0x324a40['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2081a9=_0x324a40['targetPosition']['parent'],_0x3bdfa1=_0x324a40['sourcePosition']['parent'],_0x4c9eca=_0x2081a9['getAttribute']('vid_end'),_0x4c5209=_0x3bdfa1['getAttribute']('vid_start');_0x2081a9['_setAttribute']('vid_end',_0x3bdfa1['getAttribute']('vid_end')),_0x3bdfa1['_setAttribute']('vid_end',_0x4c9eca),this['_touched']['set'](_0x4c5209,{'userId':_0x39b1d8}),this['_touched']['set'](_0x4c9eca,{'userId':_0x39b1d8}),_0x324a40['_execute']();}['_handleSplitOperation'](_0xb011a4){const _0xd89696=null===(_0xb011a4=this['_cloneOperation'](_0xb011a4,this['_idsRoots']))['_authorId']?null:_0xb011a4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x361e6e=_0xb011a4['graveyardPosition'],_0x10c7c3=_0xb011a4['splitPosition']['parent'];_0xb011a4['_execute']();const _0x33d315=_0x10c7c3['getAttribute']('vid_end'),_0x6c8dbe=_0xb011a4['insertionPosition']['nodeAfter'];if(_0x361e6e){const _0x1d39db=_0x6c8dbe['getAttribute']('vid_end'),_0x38f2fa=_0x10c7c3['getAttribute']('vid_end');_0x10c7c3['_setAttribute']('vid_end',_0x1d39db),_0x6c8dbe['_setAttribute']('vid_end',_0x38f2fa),this['_touched']['set'](_0x10c7c3['getAttribute']('vid_end'),{'userId':_0xd89696}),this['_touched']['set'](_0x6c8dbe['getAttribute']('vid_start'),{'userId':_0xd89696});}else{const _0x5adc7=this['_revisionId']++,_0x3f9f34=this['_revisionId']++;_0x10c7c3['_setAttribute']('vid_end',_0x5adc7),_0x6c8dbe['_setAttribute']('vid_start',_0x3f9f34),_0x6c8dbe['_setAttribute']('vid_end',_0x33d315),this['_touched']['set'](_0x5adc7,{'userId':_0xd89696}),this['_touched']['set'](_0x3f9f34,{'userId':_0xd89696});}}['_handleMarkerOperation'](_0x2927e6){if(!_0x2927e6['affectsData'])return;const _0x101ba0=(_0x2927e6=this['_cloneOperation'](_0x2927e6,this['_diffRoots']))['oldRange']?_0x2927e6['oldRange']['root']:null,_0x42c50b=_0x2927e6['newRange']?_0x2927e6['newRange']['root']:null;_0x101ba0&&this['_markers']['delete'](_0x2927e6['name']),_0x42c50b&&this['_markers']['set'](_0x2927e6['name'],_0x2927e6['newRange']['clone']());const _0x10f8a5=null===_0x2927e6['_authorId']?null:_0x2927e6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xd55275=_0x2927e6['name'];if(!this['_touchedMarkers']['has'](_0xd55275))return void this['_touchedMarkers']['set'](_0xd55275,{'range':_0x2927e6['oldRange'],'userId':_0x10f8a5});const _0x228dfe=this['_touchedMarkers']['get'](_0xd55275),_0x1c4b37=_0x228dfe['range'],_0x66bd94=_0x2927e6['newRange'];null==_0x1c4b37&&null==_0x66bd94||_0x1c4b37&&_0x66bd94&&_0x1c4b37['isEqual'](_0x66bd94)?this['_touchedMarkers']['delete'](_0x2927e6['name']):_0x228dfe['userId']=_0x10f8a5;}['_handleRootOperation'](_0x3ad4bd,_0x5497d6){this['_diffRoots']['has'](_0x3ad4bd['rootName'])?this['_diffRoots']['get'](_0x3ad4bd['rootName'])['_isAttached']=_0x3ad4bd['isAdd']:(this['_diffRoots']['set'](_0x3ad4bd['rootName'],B(_0x3ad4bd['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x3ad4bd['rootName'],{}),_0x5497d6&&this['_idsRoots']['set'](_0x3ad4bd['rootName'],B(_0x3ad4bd['rootName'],!0x0)));const _0x35b263=null===_0x3ad4bd['_authorId']?null:_0x3ad4bd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2bcc06=this['_touchedRoots']['get'](_0x3ad4bd['rootName']);_0x2bcc06&&_0x2bcc06['userId']===_0x35b263?this['_touchedRoots']['delete'](_0x3ad4bd['rootName']):this['_touchedRoots']['set'](_0x3ad4bd['rootName'],{'userId':_0x35b263,'isAttached':_0x3ad4bd['isAdd']});}['_handleRootAttributeOperation'](_0x3900b3){const _0x482eb7=this['_diffRootsAttributes']['get'](_0x3900b3['root']['rootName']);null===_0x3900b3['newValue']?delete _0x482eb7[_0x3900b3['key']]:_0x482eb7[_0x3900b3['key']]=_0x3900b3['newValue'];}}function F(_0x13b5b0){const _0x56a7b8=B(_0x13b5b0['rootName'],_0x13b5b0['isAttached']());for(const _0x3e963b of _0x13b5b0['getChildren']()){const _0x55c615=_0x3e963b['_clone'](!0x0);_0x56a7b8['_appendChild'](_0x55c615);}return _0x56a7b8;}function B(_0x2f70a1,_0x4a1b45=!0x0){const _0x862951=new mt();return _0x862951['rootName']=_0x2f70a1,_0x862951['_isAttached']=_0x4a1b45,_0x862951['isAttached']=()=>_0x862951['_isAttached'],_0x862951;}function J(_0x699c1c,_0x21601a,_0x53991d){const _0x3216ee='elementEnd'==_0x699c1c['type']?_0x53991d['createPositionAt'](_0x699c1c['item'],'end'):_0x53991d['createPositionBefore'](_0x699c1c['item']);return _0x53991d['createPositionFromPath'](_0x21601a,_0x3216ee['path'],_0x3216ee['stickiness']);}function q(_0x2b60d4,_0x44dfc6,_0x3e0faa){const _0x435983='elementStart'==_0x2b60d4['type']?_0x3e0faa['createPositionAt'](_0x2b60d4['item'],0x0):_0x3e0faa['createPositionAfter'](_0x2b60d4['item']);return _0x3e0faa['createPositionFromPath'](_0x44dfc6,_0x435983['path'],_0x435983['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x9e9f08,_0x39df0d){super(_0x9e9f08),this['focusTracker']=new _0x325c49(),this['keystrokes']=new _0x3f50e3(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x39df0d),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x37329d(this);}['render'](){super['render'](),_0x43fe95({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5713fc=_0x3d7da7=>_0x3d7da7['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5713fc),this['keystrokes']['set']('arrowleft',_0x5713fc),this['keystrokes']['set']('arrowup',_0x5713fc),this['keystrokes']['set']('arrowdown',_0x5713fc);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x47b3e9){this['revisionNameInputView']['fieldView']['element']['value']=_0x47b3e9['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x2c036a){const _0xc036bd=new _0x354fa9(this['locale'],_0x1a2f3e),_0x3ed7a5=_0xc036bd['fieldView'];_0x3ed7a5['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x387117=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x2c036a&&(_0x387117+='\x20('+R(this['locale'],'optional')+')'),(_0xc036bd['label']=_0x387117,_0x3ed7a5['on']('input',()=>{this['revisionNameInputValue']=_0x3ed7a5['element']['value']['trim']();}),_0xc036bd);}}class u extends _0x5951b8{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x45053f=this['editor'],_0x2077db=_0x45053f['plugins']['get']('RevisionTracker');_0x45053f['ui']['componentFactory']['add']('revisionHistory',_0x33ed21=>{const _0x46c8e9=_0x3b3239(_0x33ed21),_0x53888d=_0x46c8e9['panelView']['children'],_0x56a6e0=new _0x49de68(_0x33ed21),_0x1e579b=new _0xb8fceb(_0x33ed21),_0x1a70db=new te(_0x33ed21),_0x3943e3=new _0xb8fceb(_0x33ed21),_0x114ee7=new te(_0x33ed21);return _0x46c8e9['bind']('isEnabled')['to'](_0x2077db,'isReady',_0x2077db,'isEnabled',_0x45053f,'isReadOnly',(_0x58c479,_0x23b475,_0xc0cb45)=>_0x58c479&&_0x23b475&&!_0xc0cb45),_0x46c8e9['buttonView']['set']({'icon':_0x10c6a8['history'],'label':R(_0x33ed21,'Revision\x20history'),'tooltip':!0x0}),_0x1a70db['set']({'label':R(_0x33ed21,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x1a70db['bind']('isEnabled')['to'](_0x2077db,'isReady',_0x2077db,'isEnabled',_0x45053f,'isReadOnly',(_0x1e1508,_0x3c01e7,_0x4d4323)=>_0x1e1508&&_0x3c01e7&&!_0x4d4323),_0x1a70db['on']('execute',()=>this['_showDialog']()),_0x114ee7['set']({'label':R(_0x33ed21,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x114ee7['bind']('isEnabled')['to'](_0x2077db,'isReady',_0x45053f,'isReadOnly',(_0x1652f0,_0x4a1643)=>_0x1652f0&&!_0x4a1643),_0x114ee7['on']('execute',()=>{_0x45053f['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x46c8e9['isOpen']=!0x1,_0x45053f['editing']['view']['focus']();}),_0x1e579b['children']['add'](_0x1a70db),_0x3943e3['children']['add'](_0x114ee7),_0x56a6e0['role']='menu',_0x56a6e0['items']['addMany']([_0x1e579b,_0x3943e3]),_0x53888d['add'](_0x56a6e0),_0x46c8e9;}),_0x45053f['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x5d7aab=this['editor'],_0x184235=_0x5d7aab['locale'],_0x4a34ac=new _0x5b4880(_0x184235),_0x31dc1c=new _0x40a26d(_0x184235);_0x4a34ac['buttonView']['set']({'icon':_0x10c6a8['history'],'label':R(_0x184235,'Revision\x20history')});const _0x4a8822=new _0x257cab(_0x184235,_0x4a34ac),_0x55886d=new _0x3c210a(_0x184235);_0x55886d['set']({'label':R(_0x184235,'Save\x20current\x20revision')}),_0x55886d['delegate']('execute')['to'](_0x4a34ac),_0x55886d['on']('execute',()=>{this['_showDialog']();}),_0x4a8822['children']['add'](_0x55886d),_0x31dc1c['items']['add'](_0x4a8822);const _0x4d6707=new _0x257cab(_0x184235,_0x4a34ac),_0x4afc9=new _0x3c210a(_0x184235);return _0x4afc9['set']({'label':R(_0x184235,'Open\x20revision\x20history')}),_0x4afc9['delegate']('execute')['to'](_0x4a34ac),_0x4afc9['on']('execute',()=>{_0x5d7aab['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x4d6707['children']['add'](_0x4afc9),_0x31dc1c['items']['add'](_0x4d6707),_0x4a34ac['panelView']['children']['add'](_0x31dc1c),_0x4a34ac;}['_showDialog'](){const _0x3f6274=this['editor'],_0x35316b=_0x3f6274['locale'],_0x4468c3=_0x3f6274['plugins']['get']('Dialog'),_0x53fda0=_0x3f6274['plugins']['get']('RevisionTracker');function _0x925f12(_0xc47061){_0x3f6274['config']['get']('revisionHistory.requireRevisionName')&&''===_0xc47061['revisionName']?_0xc47061['revisionNameInputView']['errorText']=R(_0x35316b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3f6274['plugins']['get'](l)['saveRevision']({'name':_0xc47061['revisionName']}),_0x4468c3['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x925f12(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x4468c3['show']({'id':'revisionSave','title':R(_0x35316b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x3f6274['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x4468c3['hide']()},{'label':R(_0x3f6274['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x1bf509){_0x1bf509['bind']('isEnabled')['to'](_0x53fda0,'isReady',_0x53fda0,'isEnabled',_0x3f6274,'isReadOnly',(_0x1ac10d,_0x2774fc,_0x347322)=>_0x1ac10d&&_0x2774fc&&!_0x347322);},'onExecute':()=>_0x925f12(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x16318b=this['editor'],_0x12af28=_0x16318b['locale'];this['_saveRevisionFormView']=new hs(_0x12af28,_0x16318b['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends ts{['changeId'];['_model'];constructor(_0x4635b9,_0x3713c0){super(_0x4635b9),this['_model']=_0x3713c0,this['changeId']=_0x3713c0['id'];const _0x123f84=this['bindTemplate'],_0x23b2b4=R(_0x4635b9,_0x3713c0['data']['isSuggestion']?'Suggested\x20by':'add'==_0x3713c0['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x3713c0['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x123f84['to']('type',_0x21656a=>'ck-revision-change__'+_0x21656a)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x23b2b4}]},{'text':'\x20'+_0x3713c0['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0xaf4875(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x254bcd){super(),this['id']=_0x254bcd['id']||_0x5168c7(),this['author']=_0x254bcd['author'],this['type']=_0x254bcd['type'],this['data']=_0x254bcd['data']||{},this['rootName']=_0x254bcd['rootName'],this['set']('createdAt',_0x254bcd['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(_0x3e4bda,_0x21f34e){this['newRevisionId']=_0x3e4bda,this['oldRevisionId']=_0x21f34e,this['changes']=new _0x1ffe77();}['_setChanges'](_0x52a45b){for(const _0x41ccdb of _0x52a45b)this['changes']['add'](_0x41ccdb);}}const Z={'c':_0x3c99dc,'a':_0x1830f5,'e':_0x4028f0,'r':_0xba7a0d,'u':_0x5bc111};class d extends _0x5951b8{['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[_0xf71a07,_0x4588f0,j];}constructor(_0x456f50){super(_0x456f50),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',(_0x52a2e8,_0x1115aa,_0x4b731d)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x43ace0=>{for(const _0x322203 of this['editor']['editing']['view']['document']['roots'])_0x4b731d?_0x43ace0['removeClass']('ck-editor__editable__overlay',_0x322203):_0x43ace0['addClass']('ck-editor__editable__overlay',_0x322203);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5e3770=>null!==_0x5e3770),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x59a479,_0x33681,_0x4667e1)=>_0x59a479&&_0x4667e1?_0x33681['changes']['getIndex'](_0x4667e1):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1395be,_0x255944)=>_0x1395be?_0x255944['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x4588f0);}['init'](){const _0x4d4597=this['editor'],_0x14f6f1=new yt(_0x4d4597,{'direction':'backward'}),_0x51380c=new yt(_0x4d4597,{'direction':'forward'});(_0x4d4597['commands']['add']('showPreviousChange',_0x14f6f1),_0x4d4597['commands']['add']('showNextChange',_0x51380c),_0x4d4597['commands']['add']('restoreRevision',new _t(_0x4d4597)),this['on']('change:numberOfChanges',()=>{_0x14f6f1['refresh'](),_0x51380c['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4d4597['enableReadOnlyMode']('revision-viewer'),_0x4d4597['plugins']['has']('WidgetToolbarRepository'))&&_0x4d4597['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x15ec32){await this['loadRevisionData'](_0x15ec32);const _0xa9ee6e={};for(const _0x422a39 in _0x15ec32['diffData']){if(_0x15ec32['diffData'][_0x422a39]['attachChange']&&!_0x15ec32['diffData'][_0x422a39]['attachChange']['isAttached'])continue;const _0x5ae908=this['_removeRevisionMarkers'](JSON['parse'](_0x15ec32['diffData'][_0x422a39]['insertions'])),_0x10f6d0=this['editor']['editing']['view']['document'],_0xc4e190=new _0x52f59f(_0x10f6d0,_0x5ae908['map'](_0x500fa=>this['_getViewObj'](_0x500fa)));this['editor']['data']['processor']['useFillerType']('marked'),_0xa9ee6e[_0x422a39]=this['editor']['data']['processor']['toData'](_0xc4e190),this['editor']['data']['processor']['useFillerType']('default');}return _0xa9ee6e;}async['getRevisionRootsAttributes'](_0x4c8ff1){await this['loadRevisionData'](_0x4c8ff1);const _0x369a54={};for(const _0x2c1b51 in _0x4c8ff1['diffData'])_0x4c8ff1['diffData'][_0x2c1b51]['attachChange']&&!_0x4c8ff1['diffData'][_0x2c1b51]['attachChange']['isAttached']||(_0x369a54[_0x2c1b51]=_0x4c8ff1['diffData'][_0x2c1b51]['attributesAfter']||{});return _0x369a54;}['_removeRevisionMarkers'](_0x2fc921){return(_0x2fc921=_0x2fc921['filter'](_0x3eb421=>!_0x3eb421['name']||'revision-start'!==_0x3eb421['name']&&'revision-end'!==_0x3eb421['name']))['forEach'](_0x2069d4=>{'string'!=typeof _0x2069d4&&(_0x2069d4['children']=this['_removeRevisionMarkers'](_0x2069d4['children']),_0x2069d4['attributes']=_0x2069d4['attributes']['filter'](_0x18e172=>!_0x18e172[0x0]['startsWith']('data-revision-')));}),_0x2fc921;}async['compare'](_0x15f0c5,_0x14d75d,_0x39d806=!0x1){if(!this['isEnabled'])return;const _0x2c6b58=this['diff'],_0x158fc3=this['repository'],_0x3b905e='string'==typeof _0x15f0c5?_0x158fc3['getRevision'](_0x15f0c5):_0x15f0c5,_0x2d66a8='string'==typeof _0x14d75d?_0x158fc3['getRevision'](_0x14d75d):_0x14d75d,_0x404f53=_0x3b905e['id'],_0x390806=_0x2d66a8?_0x2d66a8['id']:null;if(!_0x39d806&&this['diff']&&this['diff']['newRevisionId']===_0x404f53&&this['diff']['oldRevisionId']===_0x390806)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x404f53,_0x390806);const _0x24fec0=this['_getRevisionsRange'](_0x3b905e,_0x2d66a8,!0x0)['map'](_0x2db76a=>this['loadRevisionData'](_0x2db76a));return _0x24fec0['push'](new Promise(_0x49cd9f=>{setTimeout(_0x49cd9f,0x14);})),Promise['all'](_0x24fec0)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x602c4f=this['_getDiff'](_0x404f53,_0x390806);for(const _0x1f8a49 of _0x602c4f['changes'])this['_changeIdToChange']['set'](_0x1f8a49['id'],_0x1f8a49);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3fa4a4=>{for(const _0x257aea of this['editor']['model']['document']['getRootNames']())_0x3fa4a4['detachRoot'](_0x257aea);for(const _0x1f131b of Object['keys'](_0x602c4f['model'])){const _0x315898=_0x3fa4a4['addRoot'](_0x1f131b);for(const _0x1e5c5f of Object['keys'](_0x602c4f['attributes'][_0x1f131b]))_0x3fa4a4['setAttribute'](_0x1e5c5f,_0x602c4f['attributes'][_0x1f131b][_0x1e5c5f],_0x315898);_0x3fa4a4['insert'](_0x602c4f['model'][_0x1f131b],_0x315898,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x602c4f['changes'])),this['isReady']=!0x0;})['catch'](_0x43c80e=>{console['error'](_0x43c80e),this['_cleanUp'](),_0x2c6b58&&(this['diff']=_0x2c6b58),this['isReady']=!0x0;});}['addRevisionData'](_0x546a75,_0x4b9ba0){const _0x411f4c=this['repository']['createRevision'](_0x546a75);return _0x411f4c['on']('_update',(_0x304bc8,_0x136937,_0x5d76d0)=>_0x4b9ba0(_0x136937,_0x5d76d0,_0x411f4c)),this['repository']['addRevision'](_0x411f4c),_0x411f4c;}['loadRevisionData'](_0x5c2d70){if(!_0x5c2d70||_0x5c2d70['diffData'])return Promise['resolve']();{const _0x929845=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x929845,'revisionId':_0x5c2d70['id']})['then'](_0x2a31a3=>{_0x5c2d70['_update']({'diffData':_0x2a31a3['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},_0x1c064f=>{for(const _0x4c7403 of this['editor']['model']['document']['getRootNames']())_0x1c064f['detachRoot'](_0x4c7403);});}['_sortAndFilterDiffChanges'](_0x5808d2){const _0x3c10e7=[],_0x3e2a5c=new Map();for(const _0x3b8657 of this['editor']['model']['document']['getRootNames']()){const _0x360d83=this['editor']['editing']['view']['getDomRoot'](_0x3b8657);if(!_0x360d83)continue;const _0xbe38d8=_0x360d83['getClientRects']()['item'](0x0);_0xbe38d8&&(_0x3c10e7['push'](_0x3b8657),_0x3e2a5c['set'](_0x3b8657,_0xbe38d8));}return _0x3c10e7['sort']((_0x3e6c04,_0xe14b0d)=>{const _0x517c07=_0x3e2a5c['get'](_0x3e6c04),_0x590d51=_0x3e2a5c['get'](_0xe14b0d);return _0x517c07['y']-_0x590d51['y']||_0x517c07['x']-_0x590d51['x'];}),(_0x5808d2=_0x5808d2['filter'](_0x2fbf9b=>_0x3c10e7['includes'](_0x2fbf9b['rootName'])))['sort']((_0x301cf8,_0x284396)=>_0x3c10e7['indexOf'](_0x301cf8['rootName'])-_0x3c10e7['indexOf'](_0x284396['rootName'])),_0x5808d2;}['_makeTape'](_0x568359){const _0x49250d=Array['from'](_0x568359['markers'])['filter'](([_0x3b0a55,_0x1850b0])=>_0x3b0a55['startsWith']('revision:')&&!_0x1850b0['isCollapsed']),_0x43ec34=Array['from'](this['editor']['model']['createRangeIn'](_0x568359)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x49250d['length'])for(const _0x5277de of _0x43ec34){const [_0x14e76c,_0x1c5cbb]=_0x49250d[0x0],[,_0x5a7c9e,_0x513bc1]=_0x14e76c['split'](':');if(_0x1c5cbb['end']['isEqual'](_0x5277de['nextPosition'])&&_0x49250d['shift'](),(_0x5277de['previousPosition']['isEqual'](_0x1c5cbb['start'])||_0x5277de['previousPosition']['isAfter'](_0x1c5cbb['start']))&&('insertion'==_0x5a7c9e?_0x5277de['isAdded']={'userId':_0x513bc1}:'deletion'==_0x5a7c9e&&(_0x5277de['isRemoved']={'userId':_0x513bc1})),0x0==_0x49250d['length'])break;}return _0x43ec34;}['_refreshStartEndIndex'](_0x273852){const _0x5d408b=new Map();for(let _0x3d01be=0x0;_0x3d01be<_0x273852['length'];_0x3d01be++)'text'===_0x273852[_0x3d01be]['type']?(_0x273852[_0x3d01be]['item']['startIndex']=_0x3d01be,_0x273852[_0x3d01be]['item']['endIndex']=_0x3d01be):('elementStart'===_0x273852[_0x3d01be]['type']?_0x273852[_0x3d01be]['item']['startIndex']=_0x3d01be:'elementEnd'===_0x273852[_0x3d01be]['type']&&(_0x273852[_0x3d01be]['item']['endIndex']=_0x3d01be),_0x5d408b['set'](_0x273852[_0x3d01be]['id'],_0x3d01be));for(const _0x1f3efa of _0x5d408b['values']())'elementStart'===_0x273852[_0x1f3efa]['type']?_0x273852[_0x1f3efa]['item']['endIndex']=_0x5d408b['get'](_0x273852[_0x1f3efa]['pairId']):'elementEnd'===_0x273852[_0x1f3efa]['type']&&(_0x273852[_0x1f3efa]['item']['startIndex']=_0x5d408b['get'](_0x273852[_0x1f3efa]['pairId']));}['_processTape'](_0x545f43){for(let _0x10e3e3=0x0;_0x10e3e3<_0x545f43['length'];_0x10e3e3++){if('elementStart'===_0x545f43[_0x10e3e3]['type'])_0x545f43[_0x10e3e3]['item']['startIndex']=_0x10e3e3;else{if('elementEnd'===_0x545f43[_0x10e3e3]['type']){_0x545f43[_0x10e3e3]['item']['endIndex']=_0x10e3e3;const _0x2e2688=_0x545f43[_0x10e3e3]['item']['startIndex'];_0x545f43[_0x2e2688]['pairId']=_0x545f43[_0x10e3e3]['id'],_0x545f43[_0x10e3e3]['pairId']=_0x545f43[_0x2e2688]['id'];}else _0x545f43[_0x10e3e3]['item']['startIndex']=_0x10e3e3,_0x545f43[_0x10e3e3]['item']['endIndex']=_0x10e3e3,_0x545f43[_0x10e3e3]['pairId']=null;}_0x545f43[_0x10e3e3]['markersStart']||(_0x545f43[_0x10e3e3]['markersStart']=[],_0x545f43[_0x10e3e3]['markersEnd']=[]);}}['_markInsertions'](_0x18b358,_0x5e1ecf){const _0x5b03c1=_0x18b358['filter'](_0x4723fb=>!_0x4723fb['isAdded']);for(let _0x50dc96=0x0;_0x50dc96<_0x5e1ecf['length'];_0x50dc96++)_0x5e1ecf[_0x50dc96]['isAdded']&&(_0x5b03c1[_0x50dc96]['isAdded']=_0x5e1ecf[_0x50dc96]['isAdded']);}['_makeModelFromViewString'](_0xbbecd7){const _0x22963d=JSON['parse'](_0xbbecd7),_0x304db9=this['editor']['editing']['view']['document'],_0x218e38=new _0x52f59f(_0x304db9,_0x22963d['map'](_0x147988=>this['_getViewObj'](_0x147988)));return this['editor']['data']['toModel'](_0x218e38);}['_getViewObj'](_0x38ea08){const _0x2336c4=this['editor']['editing']['view']['document'];if('string'==typeof _0x38ea08)return new _0x176147(_0x2336c4,_0x38ea08);{const _0x488112=_0x38ea08['children']['map'](_0x99ee30=>this['_getViewObj'](_0x99ee30));return new(Z[_0x38ea08['type']]||_0x241c33)(_0x2336c4,_0x38ea08['name'],_0x38ea08['attributes'],_0x488112);}}['_getDiff'](_0x264050,_0xa7c743=null){const _0xf5b807=this['repository']['getRevision'](_0x264050),_0xa08c20=_0xa7c743?this['repository']['getRevision'](_0xa7c743):null,_0xdb7f99=this['_getRevisionsRange'](_0xf5b807,_0xa08c20),_0x3c35c9=_0xdb7f99[_0xdb7f99['length']-0x1],_0x19ce9b=new Map(),_0x300280={'model':{},'attributes':{},'changes':[]},_0x516d69=new Set(),_0x9c64b7=new Map();for(let _0x1f1b46=_0xdb7f99['length']-0x1;_0x1f1b46>=0x0;_0x1f1b46--){const _0x4f053a=_0xdb7f99[_0x1f1b46];for(const _0x1ad9cd of Object['keys'](_0x4f053a['diffData']))if(_0x4f053a['diffData'][_0x1ad9cd]['attachChange']){const _0x32d7a9=_0x4f053a['diffData'][_0x1ad9cd]['attachChange'];_0x32d7a9['isAttached']?(_0x516d69['add'](_0x1ad9cd),_0x9c64b7['has'](_0x1ad9cd)&&_0x9c64b7['get'](_0x1ad9cd)['userId']==_0x32d7a9['userId']?_0x9c64b7['delete'](_0x1ad9cd):_0x9c64b7['set'](_0x1ad9cd,_0x32d7a9)):_0x9c64b7['has'](_0x1ad9cd)?(_0x516d69['delete'](_0x1ad9cd),_0x9c64b7['delete'](_0x1ad9cd)):(_0x516d69['add'](_0x1ad9cd),_0x9c64b7['set'](_0x1ad9cd,_0x32d7a9));}else _0x516d69['add'](_0x1ad9cd);}for(const _0x26134c of _0x516d69){const _0x55a8fd=_0x9c64b7['has'](_0x26134c)&&!_0x9c64b7['get'](_0x26134c)['isAttached'];let _0x3d7697=_0x55a8fd?_0xdb7f99['length']-0x1:0x0;const _0x20b382=_0x55a8fd?-0x1:0x1;for(;_0xdb7f99[_0x3d7697];){const _0x2ab6dc=_0xdb7f99[_0x3d7697];if(_0x2ab6dc['diffData'][_0x26134c]){const _0x403df7=_0x55a8fd?_0x2ab6dc['diffData'][_0x26134c]['attributesBefore']:_0x2ab6dc['diffData'][_0x26134c]['attributesAfter'];_0x300280['attributes'][_0x26134c]=_0x403df7?_0x10dfce(_0x403df7):{};break;}_0x3d7697+=_0x20b382;}}for(const _0x296f62 of _0xdb7f99){_0x296f62['model']={};for(const _0x5cf087 of _0x296f62['authors'])_0x19ce9b['set'](_0x5cf087['id'],_0x5cf087);for(const _0x49ec0d of _0x516d69){const _0x11c742=_0x296f62['diffData'][_0x49ec0d]?_0x296f62['diffData'][_0x49ec0d]['insertions']:'[]',_0x4fb0f5=_0x296f62['diffData'][_0x49ec0d]?_0x296f62['diffData'][_0x49ec0d]['deletions']:'[]';_0x296f62['model'][_0x49ec0d]={'insertions':this['_makeModelFromViewString'](_0x11c742),'deletions':this['_makeModelFromViewString'](_0x4fb0f5)};}}for(const _0x20ffbc of _0x516d69){let _0x28abb8=null,_0x4f98ff=0x0;const _0x5a3514=new Map(Array['from'](_0xf5b807['model'][_0x20ffbc]['insertions']['markers'])['filter'](([_0x1c285c])=>!_0x1c285c['startsWith']('revision:')));let _0x17803c=0x0;for(const _0x54cc91 of _0xdb7f99){const _0x556b6c=this['_makeTape'](_0x54cc91['model'][_0x20ffbc]['insertions']);_0x54cc91==_0xf5b807?(_0x28abb8=_0x556b6c,_0x4f98ff=_0x28abb8['length'],_0x28abb8['forEach'](_0x37055e=>{_0x37055e['id']=_0x17803c++;}),this['_processTape'](_0x28abb8)):this['_markInsertions'](_0x28abb8,_0x556b6c);const _0x47021d=_0x28abb8['filter'](_0x2dcafa=>!_0x2dcafa['isAdded'])['map'](_0x14d4ba=>_0x14d4ba['id']);let _0x2affb0=0x0;const _0x473329=this['_makeTape'](_0x54cc91['model'][_0x20ffbc]['deletions']);_0x473329['forEach'](_0x2d9a3a=>{_0x2d9a3a['isRemoved']?_0x2d9a3a['id']=_0x4f98ff++:_0x2d9a3a['id']=_0x47021d[_0x2affb0++];}),this['_processTape'](_0x473329),this['_setDistance'](_0x28abb8,'isAdded'),this['_setDistance'](_0x473329,'isRemoved'),_0x54cc91==_0xf5b807&&this['_markMarkers'](_0x28abb8,_0x5a3514),_0x28abb8=this['_joinTapes'](_0x28abb8,_0x473329),this['_refreshStartEndIndex'](_0x28abb8),this['_setDistance'](_0x28abb8,'isRemoved');}_0x28abb8=_0x28abb8['filter'](_0x129e95=>!(_0x129e95['isAdded']&&_0x129e95['isRemoved']));const _0x523668=new Map(_0x3c35c9['model'][_0x20ffbc]['deletions']['markers']),_0x21b753=new Set(_0x5a3514['keys']());for(const _0x5cac20 of _0x523668['keys']())_0x21b753['delete'](_0x5cac20);this['_markSuggestions'](_0x28abb8,_0x21b753),this['_fixObsoleteTags'](_0x28abb8),_0x28abb8=this['_removeMissingPairs'](_0x28abb8),_0x28abb8=this['_markMismatchedRemovedTags'](_0x28abb8),_0x28abb8=this['_removeUnsupportedChanges'](_0x28abb8);const {root:_0x13348d,changes:_0x9fe1b7}=this['_makeModelFromTape'](_0x28abb8,_0x19ce9b,_0x20ffbc);_0x300280['model'][_0x20ffbc]=_0x13348d;const _0x3255c3=_0x9c64b7['get'](_0x20ffbc);if(_0x3255c3){const _0x3bad68=_0x19ce9b['get'](_0x3255c3['userId']),_0x25d60a=new r({'author':_0x3bad68,'type':_0x3255c3['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x20ffbc});_0x9fe1b7['unshift'](_0x25d60a),_0x300280['attributes'][_0x20ffbc]['revisionHistoryAttachChange']=_0x25d60a['id'];}_0x300280['changes']=_0x300280['changes']['concat'](_0x9fe1b7);}return _0x300280;}['_markMarkers'](_0x4d8689,_0x3db3f0){for(let _0x39bf4b=0x0;_0x39bf4b<_0x4d8689['length'];_0x39bf4b++)for(const [_0x128cb7,_0x4f7b56]of _0x3db3f0)_0x4f7b56['start']['isEqual'](_0x4d8689[_0x39bf4b]['previousPosition'])&&_0x4d8689[_0x39bf4b]['markersStart']['push'](_0x128cb7),_0x4f7b56['end']['isEqual'](_0x4d8689[_0x39bf4b]['nextPosition'])&&_0x4d8689[_0x39bf4b]['markersEnd']['push'](_0x128cb7);}['_joinTapes'](_0x385997,_0x4d38c7){let _0xdf1ca6=[],_0x5767bf=0x0,_0x17315e=0x0;for(;_0x5767bf<_0x385997['length']||_0x17315e<_0x4d38c7['length'];){const _0xe6c2db=_0x385997[_0x5767bf]||{},_0x28fbcf=_0x4d38c7[_0x17315e]||{};if(_0xe6c2db['id']==_0x28fbcf['id'])_0x5767bf++,_0x17315e++,_0xdf1ca6['push'](_0xe6c2db);else{if(_0x28fbcf['isRemoved']&&_0xe6c2db['isAdded']){const {commonTape:_0x4451ac,iEnd:_0x330823,jEnd:_0x3d66f1}=this['_threeWayMerge'](_0x385997,_0x5767bf,_0x4d38c7,_0x17315e);_0xdf1ca6=_0xdf1ca6['concat'](_0x4451ac),_0x5767bf=_0x330823,_0x17315e=_0x3d66f1;}else _0x28fbcf['isRemoved']?(_0x17315e++,_0xdf1ca6['push'](_0x28fbcf)):(_0x5767bf++,_0xdf1ca6['push'](_0xe6c2db));}}return _0xdf1ca6;}['_markSuggestions'](_0x3f8d59,_0x3a4841){const _0x1e7c3c=[];for(let _0xce9405=0x0;_0xce9405<_0x3f8d59['length'];_0xce9405++){for(let _0xd9286c=0x0;_0xd9286c<_0x3f8d59[_0xce9405]['markersStart']['length'];_0xd9286c++){const _0x2fcd96=_0x3f8d59[_0xce9405]['markersStart'][_0xd9286c];if(!_0x3a4841['has'](_0x2fcd96))continue;const {group:_0x5021d,type:_0x3d3dd4,authorId:_0x467eb5}=_0x4bfcc7(_0x2fcd96);'revision-suggestion'!=_0x5021d||'insertion'!=_0x3d3dd4&&'deletion'!=_0x3d3dd4||(_0x1e7c3c['unshift']({'type':_0x3d3dd4,'name':_0x2fcd96,'userId':_0x467eb5}),_0x3f8d59[_0xce9405]['markersStart']['splice'](_0xd9286c,0x1),_0xd9286c--);}_0x746d31(_0x3f8d59[_0xce9405]);for(let _0x1af521=0x0;_0x1af521<_0x3f8d59[_0xce9405]['markersEnd']['length'];_0x1af521++){const _0x3f7d20=_0x3f8d59[_0xce9405]['markersEnd'][_0x1af521];if(!_0x3a4841['has'](_0x3f7d20))continue;const {group:_0x2a2bd5,type:_0x39d316}=_0x4bfcc7(_0x3f7d20);if('revision-suggestion'!=_0x2a2bd5||'insertion'!=_0x39d316&&'deletion'!=_0x39d316)continue;_0x3f8d59[_0xce9405]['markersEnd']['splice'](_0x1af521,0x1),_0x1af521--;const _0x2a3340=_0x1e7c3c['findIndex'](_0xcfb1bb=>_0xcfb1bb['name']==_0x3f7d20);_0x2a3340>-0x1&&_0x1e7c3c['splice'](_0x2a3340,0x1);}}function _0x4bfcc7(_0x22e755){const _0x327d71=_0x22e755['split'](':');return{'group':_0x327d71[0x0],'type':_0x327d71[0x1],'subType':_0x327d71['length']>=0x5?_0x327d71[0x2]:null,'id':_0x327d71['length']<0x5?_0x327d71[0x2]:_0x327d71[0x3],'authorId':_0x327d71['length']<0x5?_0x327d71[0x3]:_0x327d71[0x4],'markerCount':0x6==_0x327d71['length']?_0x327d71[0x5]:null};}function _0x746d31(_0x34e0ae){for(let _0x2d2706=0x0;_0x2d2706<_0x1e7c3c['length'];_0x2d2706++){if(_0x34e0ae['isAdded']&&'insertion'==_0x1e7c3c[_0x2d2706]['type'])return _0x34e0ae['isAddSuggestion']=_0x1e7c3c[_0x2d2706],void delete _0x34e0ae['isAdded'];if(!_0x34e0ae['isAdded']&&!_0x34e0ae['isRemoved']&&'deletion'==_0x1e7c3c[_0x2d2706]['type'])return void(_0x34e0ae['isRemoveSuggestion']=_0x1e7c3c[_0x2d2706]);}}}['_setDistance'](_0x5de110,_0x3ace56){let _0x4d316c=0x0,_0x58ee46=!0x1;const _0x4bf90f=new Map();for(const _0x5ecec0 of _0x5de110)_0x5ecec0[_0x3ace56]?_0x58ee46&&(_0x4d316c++,_0x58ee46=!0x1):(_0x4d316c++,_0x58ee46=!0x0),_0x4bf90f['set'](_0x5ecec0['id'],_0x4d316c);for(let _0x272e97=0x0;_0x272e97<_0x5de110['length'];_0x272e97++){if('isRemoved'==_0x3ace56&&_0x5de110[_0x272e97]['isAdded']||'isAdded'==_0x3ace56&&_0x5de110[_0x272e97]['isRemoved'])continue;if('text'==_0x5de110[_0x272e97]['type']){_0x5de110[_0x272e97]['distance']=0x0;continue;}const _0x4d5f10=_0x4bf90f['get'](_0x5de110[_0x272e97]['pairId']),_0x33ca5c=_0x4bf90f['get'](_0x5de110[_0x272e97]['id']);_0x5de110[_0x272e97]['distance']=_0x4d5f10-_0x33ca5c;}}['_getRevisionsRange'](_0x4532a4,_0x5f456d,_0x5b61af=!0x1){const _0x445927=[];let _0x5b3202=this['repository']['getIndex'](_0x4532a4),_0x101a96=this['repository']['getIndex'](_0x5f456d);for(-0x1==_0x101a96&&(_0x101a96=this['repository']['_revisions']['length'],_0x5b61af=!0x1);_0x5b3202<_0x101a96;)_0x445927['push'](this['repository']['getRevision'](_0x5b3202)),_0x5b3202++;return _0x5b61af&&_0x445927['push'](this['repository']['getRevision'](_0x5b3202)),_0x445927;}['_threeWayMerge'](_0x22cb1a,_0xb32747,_0x4e3874,_0x39c7f7){const _0x5dcf72=this['editor']['model']['schema'];let _0x2c9bcf=_0xb32747;for(;_0x22cb1a[_0x2c9bcf]&&_0x22cb1a[_0x2c9bcf]['isAdded'];)_0x2c9bcf++;let _0x558888=_0x39c7f7;for(;_0x4e3874[_0x558888]&&_0x4e3874[_0x558888]['isRemoved'];)_0x558888++;_0x3851cd(_0x22cb1a,_0xb32747,_0x2c9bcf),_0x3851cd(_0x4e3874,_0x39c7f7,_0x558888);const _0x1d3b11=_0x4e3874['slice'](_0x39c7f7,_0x558888)['concat'](_0x22cb1a['slice'](_0xb32747,_0x2c9bcf));return _0x1d3b11['sort']((_0x2a7dba,_0x377711)=>_0x2a7dba['side']!=_0x377711['side']?_0x2a7dba['side']-_0x377711['side']:_0x2a7dba['level']!=_0x377711['level']?_0x2a7dba['level']-_0x377711['level']:_0x2a7dba['distance']!=_0x377711['distance']?_0x377711['distance']-_0x2a7dba['distance']:!!_0x2a7dba['isAdded']!=!!_0x377711['isAdded']?-0x1==_0x2a7dba['side']||0x0==_0x2a7dba['side']?_0x2a7dba['isAdded']?-0x1:0x1:_0x2a7dba['isAdded']?0x1:-0x1:_0x2a7dba['index']-_0x377711['index']),{'commonTape':_0x1d3b11,'iEnd':_0x2c9bcf,'jEnd':_0x558888};function _0x3851cd(_0x3e6c24,_0x4635ad,_0x5a5ba8){let _0x3b393d=-0x1,_0x3992b0=Number['POSITIVE_INFINITY'],_0xa9bf82=!0x0;for(let _0x57c2a8=_0x4635ad;_0x57c2a8<_0x5a5ba8;_0x57c2a8++)if(_0x5dcf72['isInline'](_0x3e6c24[_0x57c2a8]['item'])||(_0xa9bf82=!0x1),_0x3e6c24[_0x57c2a8]['item']['startIndex']<_0x4635ad&&(_0x3b393d=_0x57c2a8),_0x3e6c24[_0x57c2a8]['item']['endIndex']>=_0x5a5ba8){_0x3992b0=_0x57c2a8;break;}_0xa9bf82&&(_0x3b393d=_0x5a5ba8-0x1);for(let _0x4180ab=_0x4635ad;_0x4180ab<_0x5a5ba8;_0x4180ab++)_0x3e6c24[_0x4180ab]['side']=_0x4180ab<=_0x3b393d?-0x1:_0x4180ab<_0x3992b0?0x0:0x1,_0x3e6c24[_0x4180ab]['index']=_0x4180ab;let _0x5a57e8=0x0;for(let _0x30d641=_0x4635ad;_0x30d641<=_0x3b393d;_0x30d641++)0x0==_0x3e6c24[_0x30d641]['distance']?_0x3e6c24[_0x30d641]['level']=_0x5a57e8:(_0x5a57e8++,_0x3e6c24[_0x30d641]['level']=_0x5a57e8,_0x5a57e8++);for(let _0x23d7c7=_0x4635ad;_0x23d7c7<_0x5a5ba8;_0x23d7c7++)0x0==_0x3e6c24[_0x23d7c7]['side']&&(_0x3e6c24[_0x23d7c7]['level']=_0x5a57e8);_0x5a57e8=0x0;for(let _0x4a2246=_0x5a5ba8-0x1;_0x4a2246>=_0x3992b0;_0x4a2246--)0x0==_0x3e6c24[_0x4a2246]['distance']?_0x3e6c24[_0x4a2246]['level']=_0x5a57e8:(_0x5a57e8--,_0x3e6c24[_0x4a2246]['level']=_0x5a57e8,_0x5a57e8--);}}['_fixObsoleteTags'](_0x344272){const _0x2d4617=new Map(),_0x1f1fd0=this['editor']['model']['schema'];for(let _0x5dd7a2=0x1;_0x5dd7a2<_0x344272['length'];_0x5dd7a2++){let _0x1492bc,_0x1db905,_0x2559ce;const _0x450b0c=_0x344272[_0x5dd7a2],_0x228769=_0x344272[_0x5dd7a2-0x1];if('text'==_0x450b0c['type'])continue;if(_0x450b0c['type']!=_0x228769['type'])continue;if(!_0x1f1fd0['isBlock'](_0x228769['item'])||_0x1f1fd0['isLimit'](_0x228769['item']))continue;if(!_0x1f1fd0['isBlock'](_0x450b0c['item'])||_0x1f1fd0['isLimit'](_0x450b0c['item']))continue;if((_0x344272[_0x5dd7a2]['isAdded']||_0x344272[_0x5dd7a2]['isAddSuggestion'])&&_0x344272[_0x5dd7a2-0x1]['isRemoved'])_0x1492bc=_0x344272[_0x5dd7a2],_0x1db905=_0x344272[_0x5dd7a2-0x1],_0x2559ce=_0x5dd7a2-0x1;else{if(!_0x344272[_0x5dd7a2]['isRemoved']||!_0x344272[_0x5dd7a2-0x1]['isAdded']&&!_0x344272[_0x5dd7a2-0x1]['isAddSuggestion'])continue;_0x1492bc=_0x344272[_0x5dd7a2-0x1],_0x1db905=_0x344272[_0x5dd7a2],_0x2559ce=_0x5dd7a2;}const _0x56c403=_0x1492bc['level']==_0x1db905['level'],_0x237554=Math['abs'](_0x1492bc['level'])<Math['abs'](_0x1db905['level'])&&0x0==_0x1db905['distance'];(_0x56c403||_0x237554)&&(_0x2d4617['set'](_0x1db905['id'],_0x1492bc['id']),_0x344272['splice'](_0x2559ce,0x1),_0x5dd7a2--,_0x1492bc['isAdded']=!0x1);}for(let _0x49ce23=0x0;_0x49ce23<_0x344272['length'];_0x49ce23++)_0x2d4617['has'](_0x344272[_0x49ce23]['pairId'])&&(_0x344272[_0x49ce23]['pairId']=_0x2d4617['get'](_0x344272[_0x49ce23]['pairId']));}['_removeMissingPairs'](_0x379c68){const _0x5a68ad=new Set(_0x379c68['map'](_0x2ac6c4=>_0x2ac6c4['id']));for(let _0x5e5c91=0x0;_0x5e5c91<_0x379c68['length'];_0x5e5c91++)_0x5a68ad['has'](_0x379c68[_0x5e5c91]['pairId'])||0x0==_0x379c68[_0x5e5c91]['distance']||(_0x379c68[_0x5e5c91]['isIncorrect']=!0x0);return _0x379c68['filter'](_0x31de3b=>!_0x31de3b['isIncorrect']);}['_markMismatchedRemovedTags'](_0x41fbab){const _0x5f4c52=new Set();for(let _0x5d3c5e=0x0;_0x5d3c5e<_0x41fbab['length'];_0x5d3c5e++){if(_0x5f4c52['has'](_0x41fbab[_0x5d3c5e]['id'])&&_0x41fbab[_0x5d3c5e]['isRemoved']&&(_0x41fbab[_0x5d3c5e]['isIncorrect']=!0x0),_0x41fbab[_0x5d3c5e]['isIncorrect'])continue;if(0x0==_0x41fbab[_0x5d3c5e]['distance'])continue;if('elementStart'!=_0x41fbab[_0x5d3c5e]['type'])continue;if(null==_0x41fbab[_0x5d3c5e]['pairId'])continue;let _0x2aac6f=_0x5d3c5e+0x1,_0x177e2a=0x0;for(;_0x41fbab[_0x2aac6f]['id']!=_0x41fbab[_0x5d3c5e]['pairId'];)'elementStart'==_0x41fbab[_0x2aac6f]['type']?_0x177e2a++:'elementEnd'==_0x41fbab[_0x2aac6f]['type']&&_0x177e2a--,_0x2aac6f++;if(0x0!=_0x177e2a){if(_0x41fbab[_0x5d3c5e]['isRemoved'])_0x41fbab[_0x5d3c5e]['isIncorrect']=!0x0;else{for(;_0x2aac6f!=_0x5d3c5e;)_0x41fbab[_0x2aac6f]['isRemoved']&&0x0!=_0x41fbab[_0x2aac6f]['distance']&&(_0x41fbab[_0x2aac6f]['isIncorrect']=!0x0,_0x5f4c52['add'](_0x41fbab[_0x2aac6f]['pairId'])),_0x2aac6f--;}}}return _0x41fbab['filter'](_0x316a7e=>!_0x316a7e['isIncorrect']);}['_removeUnsupportedChanges'](_0x48c09e){const _0x3e8e43=this['editor']['model']['schema'];for(let _0xd2b3df=0x0;_0xd2b3df<_0x48c09e['length'];_0xd2b3df++){if(!(_0x48c09e[_0xd2b3df]['isAdded']||_0x48c09e[_0xd2b3df]['isAddSuggestion']||_0x48c09e[_0xd2b3df]['isRemoved']||_0x48c09e[_0xd2b3df]['isRemoveSuggestion']))continue;if(0x0==_0x48c09e[_0xd2b3df]['distance'])continue;const _0xe4a62a=_0x48c09e[_0xd2b3df]['item'];_0x3e8e43['isBlock'](_0xe4a62a)||_0x3e8e43['isLimit'](_0xe4a62a)||(_0x48c09e[_0xd2b3df]['isAdded']&&delete _0x48c09e[_0xd2b3df]['isAdded'],_0x48c09e[_0xd2b3df]['isAddSuggestion']&&delete _0x48c09e[_0xd2b3df]['isAddSuggestion'],_0x48c09e[_0xd2b3df]['isRemoveSuggestion']&&delete _0x48c09e[_0xd2b3df]['isRemoveSuggestion'],_0x48c09e[_0xd2b3df]['isRemoved']&&(_0x48c09e[_0xd2b3df]['isIncorrect']=!0x0));}return _0x48c09e['filter'](_0x28b7d0=>!_0x28b7d0['isIncorrect']);}['_makeModelFromTape'](_0x5a6f25,_0x434e39,_0x412ee3){const _0x3f1e24=new mt(),_0x47bbcf=[],_0x571ea2=new Map(),_0x2b145f=this['editor']['model'],_0x4eedb0=_0x2b145f['schema'],_0x42697e=[_0x3f1e24],_0x359611={},_0x43c74c={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x270ef9=null;const _0x3acd9c=[0x0];for(let _0x4b6adc=0x0;_0x4b6adc<_0x5a6f25['length'];_0x4b6adc++)if('elementStart'===_0x5a6f25[_0x4b6adc]['type']){_0x5a6f25[_0x4b6adc]['previousPosition']=_0x2b145f['createPositionFromPath'](_0x3f1e24,_0x3acd9c);const _0x104e43=new ft(_0x5a6f25[_0x4b6adc]['item']['name'],_0x5a6f25[_0x4b6adc]['item']['getAttributes']());_0x42697e[0x0]['_appendChild'](_0x104e43),_0x3acd9c['push'](0x0),_0x42697e['unshift'](_0x104e43),_0x5a6f25[_0x4b6adc]['nextPosition']=_0x2b145f['createPositionFromPath'](_0x3f1e24,_0x3acd9c);}else'elementEnd'===_0x5a6f25[_0x4b6adc]['type']?(_0x42697e['shift'](),_0x5a6f25[_0x4b6adc]['previousPosition']=_0x2b145f['createPositionFromPath'](_0x3f1e24,_0x3acd9c),_0x3acd9c['pop'](),_0x3acd9c[_0x3acd9c['length']-0x1]++,_0x5a6f25[_0x4b6adc]['nextPosition']=_0x2b145f['createPositionFromPath'](_0x3f1e24,_0x3acd9c)):(_0x5a6f25[_0x4b6adc]['previousPosition']=_0x2b145f['createPositionFromPath'](_0x3f1e24,_0x3acd9c),_0x270ef9?_0x270ef9['_data']+=_0x5a6f25[_0x4b6adc]['item']['data']:_0x270ef9=new wt(_0x5a6f25[_0x4b6adc]['item']['data'],_0x5a6f25[_0x4b6adc]['item']['getAttributes']()),_0x5a6f25[_0x4b6adc+0x1]&&'text'===_0x5a6f25[_0x4b6adc+0x1]['type']&&_0x5cd341(_0x270ef9,_0x5a6f25[_0x4b6adc+0x1]['item'])||(_0x42697e[0x0]['_appendChild'](_0x270ef9),_0x270ef9=null),_0x3acd9c[_0x3acd9c['length']-0x1]+=_0x5a6f25[_0x4b6adc]['item']['offsetSize'],_0x5a6f25[_0x4b6adc]['nextPosition']=_0x2b145f['createPositionFromPath'](_0x3f1e24,_0x3acd9c));for(let _0x23db68=0x0;_0x23db68<_0x5a6f25['length'];_0x23db68++){const _0x1e8fa2=_0x5a6f25[_0x23db68]['previousPosition'],_0x1a0ffa=_0x5a6f25[_0x23db68]['nextPosition'];for(const _0x56b420 of _0x5a6f25[_0x23db68]['markersStart'])_0x571ea2['set'](_0x56b420,{'start':_0x1e8fa2,'end':null});_0x54a8e7('isRemoveSuggestion',_0x23db68,_0x1e8fa2,_0x1a0ffa),_0x54a8e7('isAddSuggestion',_0x23db68,_0x1e8fa2,_0x1a0ffa),_0x54a8e7('isRemoved',_0x23db68,_0x1e8fa2,_0x1a0ffa),_0x54a8e7('isAdded',_0x23db68,_0x1e8fa2,_0x1a0ffa);for(const _0x27e37d of _0x5a6f25[_0x23db68]['markersEnd']){_0x571ea2['get'](_0x27e37d)['end']=_0x1a0ffa;}}for(const [_0x2256b4,_0x3c339a]of _0x571ea2){const _0x33c03e=this['editor']['model']['createRange'](_0x3c339a['start'],_0x3c339a['end']);_0x3f1e24['markers']['set'](_0x2256b4,_0x33c03e);}return _0x47bbcf['sort']((_0x4bdb70,_0x1fa0b7)=>{const _0xa70e28=_0x3f1e24['markers']['get']('revision:'+_0x4bdb70['id']),_0x473a4c=_0x3f1e24['markers']['get']('revision:'+_0x1fa0b7['id']);return _0xa70e28['start']['isBefore'](_0x473a4c['start'])?-0x1:_0xa70e28['start']['isAfter'](_0x473a4c['start'])?0x1:_0xa70e28['end']['isBefore'](_0x473a4c['end'])?-0x1:_0xa70e28['end']['isAfter'](_0x473a4c['end'])?0x1:'add'===_0x4bdb70['type']?-0x1:0x1;}),{'root':_0x3f1e24,'changes':_0x47bbcf};function _0x54a8e7(_0x2c4ab8,_0x3721b4,_0x114177,_0x258152){const _0x246395=!!_0x5a6f25[_0x3721b4][_0x2c4ab8],_0x40bf90=_0x246395?_0x5a6f25[_0x3721b4][_0x2c4ab8]['userId']:null,_0x4ae41f=_0x3721b4===_0x5a6f25['length']-0x1,_0x2cab7b=_0x43c74c[_0x2c4ab8][0x0],_0x5e79b2=_0x4eedb0['isObject'](_0x5a6f25[_0x3721b4]['item']);!_0x359611[_0x2c4ab8]&&_0x246395?_0x359611[_0x2c4ab8]={'start':_0x114177,'tapeItem':_0x5a6f25[_0x3721b4],'userId':_0x40bf90,'type':_0x2c4ab8}:_0x359611[_0x2c4ab8]&&!_0x246395?(_0x359611[_0x2c4ab8]['end']=_0x114177,_0x3a86f0(_0x359611[_0x2c4ab8]),_0x359611[_0x2c4ab8]=null):_0x359611[_0x2c4ab8]&&_0x246395&&_0x359611[_0x2c4ab8]['userId']!==_0x40bf90&&(_0x359611[_0x2c4ab8]['end']=_0x114177,_0x2cab7b&&_0x2cab7b['userId']===_0x359611[_0x2c4ab8]['userId']||_0x3a86f0(_0x359611[_0x2c4ab8]),_0x359611[_0x2c4ab8]={'start':_0x114177,'tapeItem':_0x5a6f25[_0x3721b4],'userId':_0x40bf90,'type':_0x2c4ab8}),_0x359611[_0x2c4ab8]&&_0x5e79b2&&('elementStart'!==_0x5a6f25[_0x3721b4]['type']||_0x2cab7b&&_0x2cab7b['userId']===_0x40bf90||_0x43c74c[_0x2c4ab8]['unshift']({'userId':_0x40bf90,'object':_0x5a6f25[_0x3721b4]['item'],'change':_0x359611[_0x2c4ab8]}),'elementEnd'===_0x5a6f25[_0x3721b4]['type']&&_0x2cab7b&&_0x2cab7b['object']===_0x5a6f25[_0x3721b4]['item']&&(_0x43c74c[_0x2c4ab8]['shift'](),_0x359611[_0x2c4ab8]=_0x2cab7b['change'])),_0x359611[_0x2c4ab8]&&_0x4ae41f&&(_0x359611[_0x2c4ab8]['end']=_0x258152,_0x3a86f0(_0x359611[_0x2c4ab8]),_0x359611[_0x2c4ab8]=null);}function _0x3a86f0({start:_0x2bfbc3,end:_0x5e6af0,tapeItem:_0x1261a8,userId:_0x365746,type:_0x45f7fc}){const _0x337679=_0x1261a8['item'],_0x53a040=_0x2b145f['schema']['isBlock'](_0x337679)&&!_0x2b145f['schema']['isLimit'](_0x337679),_0x485dfb=_0x2bfbc3['nodeAfter']==_0x5e6af0['parent']&&_0x5e6af0['isAtStart'];if(_0x53a040&&_0x485dfb)return;const _0x417d49=_0x2b145f['createRange'](_0x2bfbc3,_0x5e6af0),_0x59da26=_0x434e39['get'](_0x365746),_0x6832b5=new r({'author':_0x59da26,'type':'isAdded'==_0x45f7fc||'isAddSuggestion'==_0x45f7fc?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x45f7fc||'isRemoveSuggestion'==_0x45f7fc},'createdAt':new Date(),'rootName':_0x412ee3});_0x47bbcf['push'](_0x6832b5),_0x3f1e24['markers']['set']('revision:'+_0x6832b5['id'],_0x417d49);}function _0x5cd341(_0x1e641a,_0x2a0f3f){const _0xb5abdf=_0x1e641a['getAttributes'](),_0x5ce6b9=_0x2a0f3f['getAttributes']();for(const _0x4e9ea9 of _0xb5abdf){if(_0x4e9ea9[0x1]!==_0x2a0f3f['getAttribute'](_0x4e9ea9[0x0]))return!0x1;_0x5ce6b9['next']();}return _0x5ce6b9['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x5b0131=>{const _0x2c2263=_0x5b0131['markerName']['split'](':')[0x1],_0x4aa26f=this['_getChangeFromId'](_0x2c2263);if(!_0x4aa26f)return null;const _0x555a14='add'==_0x4aa26f['type']?'insertion':'deletion',_0x122670=['ck-suggestion-marker','ck-suggestion-marker-'+_0x555a14];return _0x4aa26f['data']['isSuggestion']&&_0x122670['push']('ck-suggestion-marker-'+_0x555a14+'-new'),this['activeChange']==_0x4aa26f&&_0x122670['push']('ck-suggestion-marker--active'),{'classes':_0x122670,'attributes':{'data-change-id':_0x2c2263}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xd306ce=>{_0xd306ce['on']('element:pre',(_0x5cb43c,_0x14b72f,_0x3355e2)=>{const _0x22da96=_0x14b72f['viewItem']['getChild'](0x0);if(!_0x22da96||!_0x22da96['is']('element','code'))return;if(!_0x3355e2['consumable']['consume'](_0x22da96,{'attributes':['vid_start','vid_end']}))return;const _0x504db5=_0x14b72f['modelRange']['start']['nodeAfter'];_0x3355e2['writer']['setAttribute']('vid_start',_0x22da96['getAttribute']('vid_start'),_0x504db5),_0x3355e2['writer']['setAttribute']('vid_end',_0x22da96['getAttribute']('vid_end'),_0x504db5);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x1aa46b=>{_0x1aa46b['on']('element',(_0x2e8a33,_0x5b9e23,_0x5505a9)=>{if(!_0x5505a9['consumable']['consume'](_0x5b9e23['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5b9e23['modelRange']['isCollapsed'])return;const _0x4da84b=_0x5b9e23['modelRange']['start']['nodeAfter'];_0x4da84b['hasAttribute']('vid_start')||_0x4da84b['hasAttribute']('vid')||(_0x5505a9['writer']['setAttribute']('vid_start',_0x5b9e23['viewItem']['getAttribute']('vid_start'),_0x4da84b),_0x5505a9['writer']['setAttribute']('vid_end',_0x5b9e23['viewItem']['getAttribute']('vid_end'),_0x4da84b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x5e9380=>_0x5e9380['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x3d40a8,[,_0x53bb5e])=>{['vid_start','vid_end','vid']['includes'](_0x53bb5e)&&(_0x3d40a8['return']=!0x0,_0x3d40a8['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x157784=>{_0x157784['on']('attribute:vid',(_0x5601b9,_0x2fdaf5,_0x2c7c41)=>{if('\x20'!=_0x2fdaf5['item']['data']||_0x2fdaf5['item']['parent']['maxOffset']>0x1)return;if(!_0x2c7c41['consumable']['consume'](_0x2fdaf5['item'],_0x5601b9['name']))return;const _0x1c9867=_0x2c7c41['writer'],_0x2aca60=_0x2c7c41['mapper']['toViewRange'](_0x2fdaf5['range']);_0x1c9867['wrap'](_0x2aca60,_0x1c9867['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4c23c8){const _0x23a02a=_0x4c23c8['plugins']['get']('RevisionViewer');return(_0x2ddbf5,_0x4f5c60,_0x304321)=>{const _0x5357c4=_0x4f5c60['markerName']['split'](':')[0x1],_0x56fc8d=_0x23a02a['_getChangeFromId'](_0x5357c4);if(!_0x56fc8d)return null;const _0x1b5964='add'==_0x56fc8d['type']?'split':'merge';if(!_0x304321['consumable']['test'](_0x4f5c60['markerRange'],_0x2ddbf5['name']))return;const _0x1a445a=_0x4f5c60['markerRange']['getWalker'](),_0x126f1c=_0x4f5c60['markerRange']['start'],_0x295902=_0x4c23c8['model']['schema'];let _0x31aa54=null,_0xa577cd=null,_0x4979ce=!0x1,_0x533cff=!0x1;for(const _0x3d1dc2 of _0x1a445a){const _0x575bcf=_0x3d1dc2['item'];_0x4979ce=_0x4979ce||_0x295902['isContent'](_0x575bcf);const _0xbee36b=_0x304321['mapper']['toViewElement'](_0x575bcf);if(_0xbee36b&&_0xbee36b['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3d1dc2['type']&&(_0x295902['isBlock'](_0x575bcf)&&!_0x295902['isLimit'](_0x575bcf)&&(_0x575bcf['nextSibling']||_0x126f1c['isAtEnd']?_0x31aa54&&_0x31aa54['parent']==_0x575bcf||(_0x31aa54=_0x575bcf,_0x2bc639(_0x3d1dc2['previousPosition']),_0x533cff=!0x0):_0xa577cd=_0xa577cd||_0x3d1dc2['previousPosition']));}function _0x2bc639(_0x128fa4){const _0x398764=_0x304321['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1b5964}),_0x44c91c=_0x304321['mapper']['toViewPosition'](_0x128fa4);_0x56fc8d['data']['isSuggestion']&&_0x304321['writer']['addClass']('ck-suggestion-marker-'+_0x1b5964+'-new',_0x398764),_0x23a02a['activeChange']==_0x56fc8d&&_0x304321['writer']['addClass']('ck-suggestion-marker--active',_0x398764),_0x304321['writer']['insert'](_0x44c91c,_0x398764),_0x304321['mapper']['bindElementToMarker'](_0x398764,_0x4f5c60['markerName']);}_0x4979ce||_0x533cff||!_0xa577cd||_0x2bc639(_0xa577cd);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x5426fb,_0x188fa1,_0x2f3362)=>{const _0x4859e5=_0x2f3362['mapper']['markerNameToElements'](_0x188fa1['markerName']);if(_0x4859e5){for(const _0x132730 of _0x4859e5)(_0x132730['hasClass']('ck-suggestion-marker-split')||_0x132730['hasClass']('ck-suggestion-marker-merge'))&&(_0x2f3362['mapper']['unbindElementFromMarkerName'](_0x132730,_0x188fa1['markerName']),_0x2f3362['writer']['remove'](_0x132730));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x14d1f0,_0x3c5d80,_0x51172a)=>{const _0x359930=_0x3c5d80['markerName']['split'](':')[0x1],_0x5f2eb5=this['_getChangeFromId'](_0x359930);if(!_0x5f2eb5)return null;const _0x596275='add'==_0x5f2eb5['type']?'split':'merge';if(_0x51172a['consumable']['test'](_0x3c5d80['markerRange'],_0x14d1f0['name']))for(const _0x2c904e of _0x3c5d80['markerRange']['getItems']()){if(!_0x2c904e['is']('element','softBreak'))continue;const _0x2b862e=_0x51172a['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x596275}),_0x38ef64=_0x51172a['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2c904e));_0x5f2eb5['data']['isSuggestion']&&_0x51172a['writer']['addClass']('ck-suggestion-marker-'+_0x596275+'-new',_0x2b862e),this['activeChange']==_0x5f2eb5&&_0x51172a['writer']['addClass']('ck-suggestion-marker--active',_0x2b862e),_0x51172a['writer']['insert'](_0x38ef64,_0x2b862e),_0x51172a['mapper']['bindElementToMarker'](_0x2b862e,_0x3c5d80['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2f6a80=>{for(const _0x209084 of this['editor']['model']['document']['getRootNames']()){const _0x2a2847=this['editor']['model']['document']['getRoot'](_0x209084),_0x115c14=this['editor']['editing']['view']['document']['getRoot'](_0x209084);if(_0x115c14){const _0x1d89b8=_0x2a2847['getAttribute']('revisionHistoryAttachChange');if(_0x2f6a80['removeAttribute']('data-change-id',_0x115c14),_0x2f6a80['removeClass']('ck-revision-history-root-add',_0x115c14),_0x2f6a80['removeClass']('ck-revision-history-root-remove',_0x115c14),_0x2f6a80['removeClass']('ck-revision-history-root--active',_0x115c14),_0x1d89b8){const _0x4ee80f=this['_getChangeFromId'](_0x1d89b8);if(!_0x4ee80f)return null;_0x2f6a80['setAttribute']('data-change-id',_0x1d89b8,_0x115c14),_0x2f6a80['addClass']('ck-revision-history-root-'+_0x4ee80f['type'],_0x115c14),this['activeChange']==_0x4ee80f&&_0x2f6a80['addClass']('ck-revision-history-root--active',_0x115c14);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1c87c0=>'revision-comment:'+_0x1c87c0,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3b1e3f=>'revision-suggestion:'+_0x3b1e3f,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x477824=>({'name':'suggestion:'+_0x477824,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x1a2951=>{const _0x31dcce=_0x1a2951['markerName']['split'](':')[0x1];return'insertion'!=_0x31dcce&&'deletion'!=_0x31dcce?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x31dcce]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x22d6e3,_0x224f35,_0x4ce82e)=>{const _0x1e8669=_0x4ce82e['mapper']['markerNameToElements'](_0x224f35['markerName']);if(_0x1e8669){for(const _0x20b01e of _0x1e8669)_0x20b01e['is']('uiElement')&&(_0x4ce82e['mapper']['unbindElementFromMarkerName'](_0x20b01e,_0x224f35['markerName']),_0x4ce82e['writer']['remove'](_0x20b01e));}},{'priority':'high'});}['_getChangeFromId'](_0x1178b4){return this['_changeIdToChange']['get'](_0x1178b4);}['_getViewForChange'](_0x2bfc80){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x2bfc80),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x322f63,_0x12d657,_0x3cf0de,_0x13014b)=>{_0x13014b&&this['_balloon']['remove'](_0x13014b),_0x3cf0de&&(this['_balloon']['add']({'view':_0x3cf0de,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4cf31c=this['editor']['editing'],_0x8d83ce=this['_getChangeFromId'](_0x3cf0de['changeId']);let _0x293d12;if(_0x8d83ce['data']['isOnRoot']){const _0x31a921=_0x4cf31c['view']['getDomRoot'](_0x8d83ce['rootName']);_0x293d12=Array['from'](_0x31a921['getClientRects']());}else{const _0x37194d=this['editor']['model']['markers']['get']('revision:'+_0x3cf0de['changeId']);_0x293d12=Array['from'](_0x4cf31c['mapper']['markerNameToElements'](_0x37194d['name']))['map'](_0x484c29=>_0x4cf31c['view']['domConverter']['mapViewToDom'](_0x484c29))['map'](_0x51476c=>Array['from'](_0x51476c['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x293d12[0x0];return _0x293d12['find'](_0x21d909=>_0x21d909['top']-0x3<=this['_activeViewTarget']['y']&&_0x21d909['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x21d909['left']-0x3<=this['_activeViewTarget']['x']&&_0x21d909['right']+0x3>=this['_activeViewTarget']['x'])||_0x293d12[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x5eb6a2,_0x3c837b,_0x2d7522,_0x34a36e)=>{this['activeView']=_0x2d7522?this['_getViewForChange'](_0x2d7522):null,this['editor']['model']['change'](()=>{const _0x4e0809=this['editor']['editing'];_0x34a36e&&(_0x34a36e['data']['isOnRoot']?_0x4e0809['view']['change'](_0x17c7d6=>{_0x17c7d6['removeClass']('ck-revision-history-root--active',_0x4e0809['view']['document']['getRoot'](_0x34a36e['rootName']));}):_0x4e0809['reconvertMarker']('revision:'+_0x34a36e['id'])),_0x2d7522&&(_0x2d7522['data']['isOnRoot']?_0x4e0809['view']['change'](_0x12430f=>{_0x12430f['addClass']('ck-revision-history-root--active',_0x4e0809['view']['document']['getRoot'](_0x2d7522['rootName']));}):_0x4e0809['reconvertMarker']('revision:'+_0x2d7522['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x10356f,_0xd742b3)=>{if(this['activeChange'])return;const _0x3a1487=this['_findChangeIdFromDomTarget'](_0xd742b3['target']),_0x575b3b=this['_changeIdToChange']['get'](_0x3a1487);_0x575b3b?(this['_activeViewTarget']={'x':_0xd742b3['domEvent']['x'],'y':_0xd742b3['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x575b3b)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x164153,_0x46eeac)=>{const _0x2d1729=this['_findChangeIdFromDomTarget'](_0x46eeac['target']),_0x4a65dd=this['_changeIdToChange']['get'](_0x2d1729);_0x4a65dd?(this['_activeViewTarget']={'x':_0x46eeac['domEvent']['x'],'y':_0x46eeac['domEvent']['y']},_0x4a65dd===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4a65dd):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x9e9f0e){do{const _0x1dfcb7=_0x9e9f0e['getAttribute']('data-change-id');if(_0x1dfcb7)return _0x1dfcb7;_0x9e9f0e=_0x9e9f0e['parent'];}while(_0x9e9f0e);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x471baf=>{for(const _0x1b7f1c of this['editor']['model']['markers'])_0x471baf['removeMarker'](_0x1b7f1c);});}}function tt(_0x29cb60,_0x5a0f8b){return(_0x10a856,_0x3050d8,_0x519aec)=>{if(!_0x519aec['consumable']['test'](_0x3050d8['markerRange'],_0x10a856['name']))return;const _0x23e4a2=_0x3050d8['markerRange']['getWalker'](),_0x5621d7=_0x3050d8['markerRange']['start'],_0x25876c=_0x29cb60['model']['schema'];let _0x4d75a5=null,_0x374784=null,_0x34c3e7=!0x1,_0x36a48b=!0x1;for(const _0x12d0d4 of _0x23e4a2){const _0x54ed74=_0x12d0d4['item'];_0x34c3e7=_0x34c3e7||_0x25876c['isContent'](_0x54ed74);const _0x5e3db1=_0x519aec['mapper']['toViewElement'](_0x54ed74);if(_0x5e3db1&&_0x5e3db1['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x12d0d4['type']&&(_0x25876c['isBlock'](_0x54ed74)&&!_0x25876c['isLimit'](_0x54ed74)&&(_0x54ed74['nextSibling']||_0x5621d7['isAtEnd']?_0x4d75a5&&_0x4d75a5['parent']==_0x54ed74||(_0x4d75a5=_0x54ed74,_0x5c72f7(_0x12d0d4['previousPosition']),_0x36a48b=!0x0):_0x374784=_0x374784||_0x12d0d4['previousPosition']));}function _0x5c72f7(_0xda77c6){const _0x3c93c3=_0x519aec['mapper']['toViewPosition'](_0xda77c6),_0xf5189e=_0x519aec['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x5a0f8b});_0x519aec['writer']['insert'](_0x3c93c3,_0xf5189e),_0x519aec['mapper']['bindElementToMarker'](_0xf5189e,_0x3050d8['markerName']);}_0x34c3e7||_0x36a48b||!_0x374784||_0x5c72f7(_0x374784);};}class _t extends _0x5da42d{constructor(_0xe79c41){super(_0xe79c41);const _0x7ca246=_0xe79c41['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x7ca246,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x7ca246,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4595cd=this['editor'],_0x4a84fc=_0x4595cd['plugins']['get'](d),_0x3d4d7a=_0x4a84fc['isReady']?_0x4a84fc['diff']['newRevisionId']:null;_0x4595cd['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3d4d7a);}['refresh'](){const {isReady:_0x2c400a,isEnabled:_0x43f2f9,repository:_0x5e96da,diff:_0x4ffa43}=this['editor']['plugins']['get'](d),_0x1794d5=_0x4ffa43&&_0x5e96da['getLaterVisibleRevision'](_0x4ffa43['newRevisionId']);this['isEnabled']=_0x2c400a&&_0x43f2f9&&Boolean(_0x1794d5);}}class yt extends _0x5da42d{['_step'];constructor(_0x44448d,{direction:_0x4d8452}){super(_0x44448d);const _0x367392=_0x44448d['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x4d8452?0x1:-0x1,this['listenTo'](_0x367392,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x367392,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x367392,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x3ed066=this['editor'],_0x562240=_0x3ed066['plugins']['get'](d),{isNavigationMode:_0x2563d4,currentChangeNumber:_0x2ca5cf}=_0x562240;let _0x265569;if(_0x562240['activeChange']=_0x2563d4?_0x562240['diff']['changes']['get'](_0x2ca5cf+this['_step']):_0x562240['diff']['changes']['first'],_0x562240['activeChange']['data']['isOnRoot'])_0x265569=_0x3ed066['editing']['view']['getDomRoot'](_0x562240['activeChange']['rootName']);else{const _0x494c1e=_0x3ed066['model']['markers']['get']('revision:'+_0x562240['activeChange']['id']);_0x265569=_0x408031(_0x3ed066['editing'],_0x494c1e);}_0x24b293({'target':_0x265569,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x528480,currentChangeNumber:_0x410ae9,numberOfChanges:_0xdb3125,isReady:_0x2d36ef,isEnabled:_0x3f55e7}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x3f55e7&&_0x2d36ef&&_0xdb3125)&&(!_0x528480||(0x1===this['_step']?_0x410ae9<_0xdb3125-0x1:_0x410ae9>0x0));}}class ei extends ts{constructor(_0x268195){super(_0x268195);const _0x11d74c=this['bindTemplate'],_0x104160=new te(_0x268195),_0x55a904=new te(_0x268195);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',(_0x2721f2,_0x58a0ca)=>_0x2721f2&&_0x58a0ca>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x1263ee,_0x45b3e7,_0x1f3b1c,_0x3b0478)=>{if(!_0x1263ee)return R(_0x268195,'Loading...');if(!_0x1f3b1c)return R(_0x268195,'No\x20changes');const _0x28180c=R(_0x268195,'NUMBER_OF_CHANGES',_0x1f3b1c);return _0x3b0478?R(_0x268195,'X_OF_Y_CHANGES',[_0x45b3e7+0x1,_0x1f3b1c]):_0x28180c;}),_0x104160['set']({'label':R(_0x268195,'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'}),_0x55a904['set']({'label':R(_0x268195,'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'}),_0x104160['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x55a904['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x104160['on']('execute',()=>this['fire']('execute','backward')),_0x55a904['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',_0x11d74c['if']('_isStatusLabelVisible','ck-hidden',_0xb7c06=>!_0xb7c06)]},'children':[{'text':_0x11d74c['to']('isNavigationMode',_0x4f972a=>_0x4f972a?R(_0x268195,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x268195,'Total')+':\x20')}]},{'text':_0x11d74c['to']('_statusText')}]},new _0x17a559(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x104160,_0x55a904]}]});}}const le='ck-editor__editable__loading-overlay';class de extends _0x5951b8{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x492478=this['editor']['editing']['view'];_0x492478['change'](_0xb7b575=>{for(const _0x26f952 of _0x492478['document']['roots'])_0xb7b575['addClass'](le,_0x26f952);});}['hide'](){const _0x18d2f1=this['editor']['editing']['view'];_0x18d2f1['change'](_0x4fcd20=>{for(const _0x50713b of _0x18d2f1['document']['roots'])_0x4fcd20['removeClass'](le,_0x50713b);});}}class m extends _0x5951b8{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,de];}['init'](){const _0x54d5c4=this['editor'],_0x14f586=_0x54d5c4['plugins']['get'](d),_0x2ab765=_0x54d5c4['plugins']['get'](de);_0x54d5c4['ui']['componentFactory']['add']('exitToEditing',_0x204777=>{const _0x426ea4=new te(_0x204777);return _0x426ea4['set']({'label':R(_0x204777,'Back\x20to\x20editing'),'icon':_0x10c6a8['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x426ea4,'execute',()=>{_0x54d5c4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x426ea4;}),_0x54d5c4['ui']['componentFactory']['add']('restoreRevision',_0x3429e2=>{const _0x218b93=new te(_0x3429e2);return _0x218b93['set']({'label':R(_0x3429e2,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x218b93['bind']('isEnabled')['to'](_0x54d5c4['commands']['get']('restoreRevision')),this['listenTo'](_0x218b93,'execute',()=>_0x54d5c4['execute']('restoreRevision')),_0x218b93;}),_0x54d5c4['ui']['componentFactory']['add']('changesNavigation',_0x34aed8=>{const _0x36e922=new ei(_0x34aed8),_0x2ff23b=_0x54d5c4['commands']['get']('showPreviousChange'),_0x4a347d=_0x54d5c4['commands']['get']('showNextChange');return _0x36e922['bind']('isBackwardNavigationEnabled')['to'](_0x2ff23b,'isEnabled'),_0x36e922['bind']('isForwardNavigationEnabled')['to'](_0x4a347d,'isEnabled'),_0x36e922['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x14f586),this['listenTo'](_0x36e922,'execute',(_0x195fe5,_0xfec516)=>{_0x54d5c4['execute']('forward'===_0xfec516?'showNextChange':'showPreviousChange');}),_0x36e922;}),_0x2ab765['show'](),_0x14f586['on']('change:isReady',(_0x2ed856,_0x3bf0cd,_0x4fe4d3)=>{_0x4fe4d3?_0x2ab765['hide']():_0x2ab765['show']();});}}class pt extends _0x354fa9{['_resizeObserver']=null;constructor(_0x210fac,_0x40aa3c){super(_0x210fac,_0x40aa3c);const _0x2bea37=this['bindTemplate'];this['set']({'label':R(_0x210fac,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x210fac,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2bea37['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 _0x2d4e6c=this['fieldView']['element'];this['_tooltipString']=_0x2d4e6c['scrollWidth']>_0x2d4e6c['clientWidth']&&_0x2d4e6c['value']||'';}}class ai extends ts{constructor(_0x1c5098,_0x3e4919,_0x398135){super(_0x1c5098);const _0xaf83b6=new _0x48ee11();_0xaf83b6['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 _0x81e1fa=['ck','ck-revision-history-sidebar__revision-author'];_0x398135&&_0x81e1fa['push']('ck-revision-history-sidebar__revision-author_creator');const _0x373da5=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1c5098,_0x398135?'Revision\x20creator':'Revision\x20author')},'children':[_0xaf83b6,_0x3e4919['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x81e1fa},'children':_0x373da5});}}function _i(_0x57e20c,_0xcb915c){const _0x32f846=_0x57e20c['bindTemplate'],_0x3b5cd7=_0x57e20c['locale'],_0xb092f9=_0x3b3239(_0x3b5cd7);_0xb092f9['panelPosition']='sw';const _0xb0dae2=function(_0x3b7348,_0x18947d){const _0x1b18b7=function(_0x1e07ce,_0x8fc6fb){const _0x5aea89=_0x1e07ce['locale'],_0x285dd1={'Compare\x20against\x20selected':R(_0x5aea89,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x5aea89,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x5aea89,'Restore\x20this\x20revision')};return _0x8fc6fb['map'](_0x38764f=>{const _0x50c39c=_0x285dd1[_0x38764f['name']];return _0x50c39c&&_0x50c39c!==_0x38764f['name']&&(_0x38764f['name']=_0x50c39c),_0x38764f;});}(_0x3b7348,_0x18947d),_0x50ad14=new _0x1ffe77();for(const _0x261788 of _0x1b18b7){const _0x5614f9={'type':'button','model':new _0x16cba2({'label':_0x261788['name'],'class':_0x261788['class'],'withText':!0x0,'role':'menuitem','_action':_0x261788['action']})};_0x5614f9['model']['bind']('isEnabled')['to'](_0x3b7348,'isActionsDropdownOpen',_0xac31b4=>'function'!=typeof _0x261788['isEnabled']||(!_0xac31b4||_0x261788['isEnabled'](_0x3b7348))),_0x50ad14['add'](_0x5614f9);}return _0x50ad14;}(_0x57e20c,_0xcb915c);return _0x57e20c['bind']('isActionsDropdownOpen')['to'](_0xb092f9,'isOpen'),_0xb092f9['buttonView']['set']({'label':R(_0x3b5cd7,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x10c6a8['threeVerticalDots']}),_0xb092f9['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x32f846['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x32f846['to'](_0x56724=>_0x56724['stopPropagation']())}}),_0xb092f9['on']('execute',_0x1e387a=>{_0x57e20c['isReady']&&'function'==typeof _0x1e387a['source']['_action']&&_0x1e387a['source']['_action'](_0x57e20c);}),to(_0xb092f9,_0xb0dae2,{'role':'menu'}),_0xb092f9['listenTo'](_0x57e20c,'change:isActionsDropdownOpen',(_0x49cf9a,_0x5b0f79,_0x18e4c7)=>{if(_0x18e4c7)for(const _0xc9c65e of _0xb092f9['listView']['items']){const _0x3817ab=_0xc9c65e['children']['first'],_0x4164d5=_0xcb915c['find'](_0x2b1857=>_0x2b1857['action']===_0x3817ab['_action'])['isVisible'];_0xc9c65e['isVisible']=void 0x0===_0x4164d5||_0x4164d5(_0x57e20c);}}),_0xb092f9;}class ri extends/* #__PURE__ -- @preserve */
26
- _0x17991f(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5ecd3b,_0x4ec68c,_0x2145e6,_0x3429d1){super(_0x5ecd3b);const _0x2aa1c3=this['bindTemplate'],_0x4c4262=function(_0x3443c5,_0x2ba6a0){const _0x3da2c1=Array['from'](_0x2ba6a0['authors'])['filter'](_0x10bd72=>_0x10bd72!=_0x2ba6a0['creator']);return _0x2ba6a0['creator']&&_0x3da2c1['unshift'](_0x2ba6a0['creator']),_0x3da2c1['map'](_0x14433b=>new ai(_0x3443c5,_0x14433b,_0x14433b==_0x2ba6a0['creator']));}(_0x5ecd3b,_0x4ec68c);this['id']=_0x4ec68c['id'],this['_revision']=_0x4ec68c,this['_requireRevisionName']=_0x3429d1,this['bind']('name','createdAt')['to'](_0x4ec68c),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x5f01d3=>{return _0x44545d=_0x5ecd3b['uiLanguage'],(_0x5a4370=_0x5f01d3)['toLocaleDateString'](_0x44545d,{'month':'long','day':'numeric'})+',\x20'+_0x5a4370['toLocaleTimeString'](_0x44545d,{'hour':'numeric','minute':'numeric'});var _0x44545d,_0x5a4370;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x5ecd3b,_0x1a2f3e),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x504ba4=>_0x504ba4||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x28ccbe,_0x3c1916)=>_0x28ccbe&&_0x3c1916),this['revisionActionsView']=_0x2145e6&&_0x2145e6['length']?_i(this,_0x2145e6):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x2aa1c3['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x2aa1c3['if']('isEnabled','ck-disabled',_0x5a34e6=>!_0x5a34e6),_0x2aa1c3['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x2aa1c3['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x2aa1c3['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':_0x2aa1c3['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':_0x4c4262}]},this['revisionActionsView']],'on':{'click':_0x2aa1c3['to'](_0x35f691=>{_0x35f691['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4f3a89=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4f3a89,'change',()=>{this['_requireRevisionName']&&!_0x4f3a89['value']||this['fire']('setName',{'id':this['id'],'name':_0x4f3a89['value']}),_0x4f3a89['value']||(_0x4f3a89['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function oi(_0x121290,_0x492f94){const _0xcaf7eb=_0x4efa5['fromJSDate'](_0x121290)['setLocale'](_0x492f94),_0x4c647b=_0x4efa5['local'](),_0x5b9946=_0x4c647b['minus']({'days':0x1})['startOf']('day');let _0x1a22be,_0x16d8cc;return _0xcaf7eb['hasSame'](_0x4c647b,'day')?(_0x1a22be=_0xcaf7eb['startOf']('day')['toJSDate'](),_0x16d8cc=_0xcaf7eb['toRelativeCalendar']()):_0xcaf7eb['hasSame'](_0x5b9946,'day')?(_0x1a22be=_0x5b9946['toJSDate'](),_0x16d8cc=_0xcaf7eb['toRelativeCalendar']()):_0xcaf7eb['hasSame'](_0x4c647b,'week')?(_0x1a22be=_0xcaf7eb['startOf']('week')['toJSDate'](),_0x16d8cc=_0xcaf7eb['weekdayLong']||''):_0xcaf7eb['hasSame'](_0x4c647b,'year')?(_0x1a22be=_0xcaf7eb['startOf']('month')['toJSDate'](),_0x16d8cc=_0xcaf7eb['monthLong']||''):(_0x1a22be=_0xcaf7eb['startOf']('year')['toJSDate'](),_0x16d8cc=String(_0xcaf7eb['year'])),{'startDate':_0x1a22be,'localizedPeriodName':_0x16d8cc};}class hi extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x349c06,_0x5e7523,_0x43d14d,_0x1ded09){super(_0x349c06);const _0x526aa7=oi(_0x5e7523,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x5e7523,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x43d14d,this['_requireRevisionName']=_0x1ded09,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':_0x526aa7}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x41b7eb){const _0x540cdc=new ri(this['locale'],_0x41b7eb,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x540cdc);}['removeRevision'](_0x438fad){const _0x291f73=this['revisionViews']['find'](_0x43cc16=>_0x43cc16['id']===_0x438fad['id']);this['revisionViews']['remove'](_0x291f73);}}class cs extends ts{constructor(_0x9b4e34){super(_0x9b4e34);const _0x4df92a=new _0x48ee11();_0x4df92a['content']=_0x10c6a8['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x4df92a,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x9b4e34,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x405811,_0x1fa3b2,_0x451579,_0x26fe6b){super(_0x405811);const _0x3ea8ec=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x1fa3b2,this['_revisionActions']=_0x451579,this['_requireRevisionName']=_0x26fe6b,this['on']('select',(_0x1d8786,_0x1a662d)=>{this['fire']('revisionSelected',_0x1a662d);}),this['on']('setName',(_0x1b0b35,_0x24d4c1)=>{this['fire']('revisionSetName',_0x24d4c1);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new cs(_0x405811),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x3ea8ec['if']('isEnabled','ck-disabled',_0x70e1d2=>!_0x70e1d2)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0xbd02f6 of this['_revisions'])this['_addRevision'](_0xbd02f6);this['_revisions']['on']('add',(_0x28d995,_0x58afbe)=>{this['_addRevision'](_0x58afbe);}),this['_revisions']['on']('remove',(_0x250af9,_0x529cd7)=>{this['_removeRevision'](_0x529cd7);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0xdbcf2d=>_0xdbcf2d['revisionViews']['map'](_0x128d42=>_0x128d42))['flat']();}['selectRevision'](_0xcb1bec){for(const _0x15db1b of this['revisionViews'])_0xcb1bec&&_0xcb1bec['id']===_0x15db1b['id']?_0x15db1b['select']():_0x15db1b['deselect']();}['highlightRevisions'](_0x5cd02f){for(const _0x3e7786 of this['revisionViews'])_0x5cd02f['some'](({id:_0x34b431})=>_0x34b431===_0x3e7786['id'])?_0x3e7786['highlight']():_0x3e7786['unhighlight']();}['_addRevision'](_0x4e7d69){const _0x3e0c6f=oi(_0x4e7d69['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1d64ed=this['timePeriodViews']['get'](0x0);_0x1d64ed&&_0x1d64ed['startDate']['getTime']()===_0x3e0c6f['getTime']()||(_0x1d64ed=new hi(this['locale'],_0x3e0c6f,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1d64ed)),_0x1d64ed['addRevision'](_0x4e7d69);}['_removeRevision'](_0x1882b4){const _0x3dbadb=oi(_0x1882b4['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x3dbadb)['removeRevision'](_0x1882b4);}['_getTimePeriodViewByStartDate'](_0x54bfe0){return this['timePeriodViews']['find'](_0x466399=>_0x466399['startDate']['getTime']()===_0x54bfe0['getTime']());}}class g extends _0x5951b8{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x1230b1,uid as _0x1c3ee2,Collection as _0x53bf0e,logWarning as _0x1be885,FocusTracker as _0x2e0c4d,KeystrokeHandler as _0x4b93df,scrollViewportToShowTarget as _0x11b89e,ResizeObserver as at,ElementReplacer as ct,CKEditorError as _0x51a18f}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5f0f2b,set as _0x50f429,unset as _0x172232,isEqual as _0x290338}from'lodash-es';import{Plugin as _0x49e1b4,PendingActions as _0x4a4333,icons as _0x4e4052,Command as _0xb9095c,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x57add3,getMarkerDomElement as _0x38b134,ConfirmMixin as ti,sanitizeEditorConfig as _0x368ecc}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x22eced,ViewText as _0x253de4,ViewElement as _0x4085ba,Element as ft,Range as vt,Position as gt,DocumentFragment as mt,ViewContainerElement as _0x39be7f,ViewAttributeElement as _0x2124c2,ViewEmptyElement as _0x324ff6,ViewRawElement as _0xb02490,ViewUIElement as _0x264acd,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x541811,submitHandler as _0x804b05,LabeledFieldView as _0x2dd0c6,createLabeledInputText as _0x1df99b,createDropdown as _0x10f4d8,ListView as _0x490cb1,ListItemView as _0x4b50ba,ButtonView as te,MenuBarMenuView as _0x3058d9,MenuBarMenuListView as _0x5bf8a9,MenuBarMenuListItemView as _0x505bc2,MenuBarMenuListItemButtonView as _0x1f5186,ContextualBalloon as _0x6d7678,ToolbarSeparatorView as _0xfdf3f0,IconView as _0x4cf3df,addListToDropdown as to,ViewModel as _0x563314,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x1dd358}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
+ _0x1230b1(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1cb193){super(),this['id']=_0x1cb193['id']||_0x1c3ee2(),this['creator']=_0x1cb193['creator']||null,this['authors']=_0x1cb193['authors']||[],this['diffData']=_0x1cb193['diffData']||null,this['toVersion']=_0x1cb193['toVersion']||0x0,this['fromVersion']=_0x1cb193['fromVersion']||0x0,this['set']('name',_0x1cb193['name']||''),this['set']('createdAt',_0x1cb193['createdAt']||new Date()),this['set']('attributes',_0x1cb193['attributes']||{});}['setName'](_0x1c5fc7){this['_update']({'name':_0x1c5fc7});}['setAttribute'](_0x278589,_0x517065){const _0x398df4=_0x5f0f2b(this['attributes']);_0x50f429(_0x398df4,_0x278589,_0x517065),this['_update']({'attributes':_0x398df4});}['removeAttribute'](_0x99b816){const _0x3036fc=_0x5f0f2b(this['attributes']);_0x172232(_0x3036fc,_0x99b816),this['_update']({'attributes':_0x3036fc});}['_update'](_0x34fc18,_0x3ae9f1=!0x1){let _0x3ac091=!0x1;const _0x487916={'id':this['id']},_0x229412=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x781be8 of _0x229412){const _0xebeb43=_0x34fc18[_0x781be8];void 0x0!==_0xebeb43&&_0xebeb43!==this[_0x781be8]&&(this[_0x781be8]=_0xebeb43,_0x487916[_0x781be8]=_0xebeb43,_0x3ac091=!0x0);}_0x3ac091&&(_0x487916['authors']&&(_0x487916['authorsIds']=_0x487916['authors']['map'](_0x2b0fff=>_0x2b0fff['id']),delete _0x487916['authors']),this['fire']('_update',_0x487916,_0x3ae9f1));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1d6208=>_0x1d6208['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x49e1b4{['_revisions'];static get['requires'](){return[_0x57add3];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5803fb){super(_0x5803fb),this['_revisions']=new _0x53bf0e();}['afterInit'](){!async function(_0x3aab5f){const _0x2393b0=_0x4b24e6([0x66,0x47,0x5a,0x42,0x6e,0x53,0x35,0x4f,0x34,0x4b,0x45,0x4d,0x78,0x74,0x63,0x52,0x36,0x75,0x50,0x7a,0x33,0x67,0x76,0x62,0x71,0x4e,0x57,0x73,0x68,0x6a,0x69,0x37,0x51,0x70,0x55,0x61,0x48,0x6d,0x58,0x4a,0x43,0x77,0x54,0x59,0x46,0x30,0x49,0x6f,0x79,0x72,0x44,0x38,0x4c,0x65,0x39,0x6b,0x6c,0x41,0x32,0x64,0x56,0x31]),_0x57bf2b=0xeb829,_0x1ac2a2=0x1ff44478,_0x81c3f1=0x1ff31ec8^_0x1ac2a2,_0x5f0100=window[_0x4b24e6([0x44,0x61,0x74,0x65])][_0x4b24e6([0x6e,0x6f,0x77])](),_0x54dd04=_0x3aab5f[_0x4b24e6([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xad72c=new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x15286e=>{_0x54dd04[_0x4b24e6([0x6f,0x6e,0x63,0x65])](_0x4b24e6([0x72,0x65,0x61,0x64,0x79]),_0x15286e);}),_0x177bf5={[_0x4b24e6([0x6b,0x74,0x79])]:_0x4b24e6([0x45,0x43]),[_0x4b24e6([0x75,0x73,0x65])]:_0x4b24e6([0x73,0x69,0x67]),[_0x4b24e6([0x63,0x72,0x76])]:_0x4b24e6([0x50,0x2d,0x32,0x35,0x36]),[_0x4b24e6([0x78])]:_0x4b24e6([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]),[_0x4b24e6([0x79])]:_0x4b24e6([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]),[_0x4b24e6([0x61,0x6c,0x67])]:_0x4b24e6([0x45,0x53,0x32,0x35,0x36])},_0x2d75a1=_0x54dd04[_0x4b24e6([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4b24e6([0x67,0x65,0x74])](_0x4b24e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x47d7ff(){let _0x11be20,_0x20c7b3=null,_0x5cb074=null;try{if(_0x2d75a1==_0x4b24e6([0x47,0x50,0x4c]))return _0x4b24e6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x11be20=_0x290d58(),!_0x11be20)return _0x4b24e6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x11be20[_0x4b24e6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5cb074=_0x3f08c7(_0x11be20[_0x4b24e6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x11be20[_0x4b24e6([0x6a,0x74,0x69])])),await _0x29c6d1()?_0x526372()?_0x2e4547()?_0x4b24e6([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1b2c8e()?(_0x11be20[_0x4b24e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4b24e6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x20c7b3=_0x13602d(_0x4b24e6([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x11be20[_0x4b24e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4b24e6([0x74,0x72,0x69,0x61,0x6c])&&(_0x20c7b3=_0x13602d(_0x4b24e6([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x11be20[_0x4b24e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4b24e6([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x20c7b3=_0x13602d(_0x4b24e6([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x53d725()):_0x4b24e6([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4b24e6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4b24e6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x4dc20a){return _0x4b24e6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2e4547(){const _0x4e419c=[_0x4b24e6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4b24e6([0x74,0x72,0x69,0x61,0x6c])][_0x4b24e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x11be20[_0x4b24e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x5f0100/0x3e8:0xe10*_0x81c3f1;return _0x11be20[_0x4b24e6([0x65,0x78,0x70])]<_0x4e419c;}function _0x526372(){const _0x1a0d5d=_0x11be20[_0x4b24e6([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1a0d5d)return!0x1;if(_0x1a0d5d[_0x4b24e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4b24e6([0x2a])))return!0x0;if(_0x1a0d5d[_0x4b24e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4b24e6([0x52,0x48])))return!0x0;if(_0x1a0d5d[_0x4b24e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4b24e6([0x52,0x52,0x48]))){if(_0x16f687())return!0x0;if(_0x49d702()||_0x5965d4())return!0x0;}return!0x1;}function _0x1b2c8e(){const _0x1ed382=_0x11be20[_0x4b24e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x1ed382||0x0==_0x1ed382[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4c27ad}=new URL(window[_0x4b24e6([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x1ed382[_0x4b24e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c27ad))return!0x0;const _0x321940=_0x4c27ad[_0x4b24e6([0x73,0x70,0x6c,0x69,0x74])](_0x4b24e6([0x2e]));return _0x1ed382[_0x4b24e6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5ae0c2=>_0x5ae0c2[_0x4b24e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4b24e6([0x2a])))[_0x4b24e6([0x6d,0x61,0x70])](_0x1ca13b=>_0x1ca13b[_0x4b24e6([0x73,0x70,0x6c,0x69,0x74])](_0x4b24e6([0x2e])))[_0x4b24e6([0x73,0x6f,0x6d,0x65])](_0x29af94=>_0x321940[_0x4b24e6([0x65,0x76,0x65,0x72,0x79])]((_0x2b0b42,_0x9543a7)=>_0x29af94[_0x9543a7]===_0x2b0b42||_0x29af94[_0x9543a7]===_0x4b24e6([0x2a])));}function _0x53d725(){return _0x20c7b3&&_0x5cb074?new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x99d56b,_0x5cd396)=>{_0x20c7b3[_0x4b24e6([0x74,0x68,0x65,0x6e])](_0x99d56b,_0x5cd396),_0x5cb074[_0x4b24e6([0x74,0x68,0x65,0x6e])](_0x294244=>{_0x294244!=_0x4b24e6([0x56,0x61,0x6c,0x69,0x64])&&_0x99d56b(_0x294244);},_0x5cd396);}):_0x20c7b3||_0x5cb074||_0x4b24e6([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3f08c7(_0x199b78,_0x3ff982){return new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x512199=>{if(_0x1a65b2())return _0x512199(_0x4b24e6([0x56,0x61,0x6c,0x69,0x64]));_0x4c283e(),_0x54dd04[_0x4b24e6([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4b24e6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3f16a5=!0x1;const _0x1640b2=_0x1c3ee2();function _0x6dd9c4(_0x3b028c){return!!_0x3b028c&&(typeof _0x3b028c===_0x4b24e6([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3b028c===_0x4b24e6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3b028c[_0x4b24e6([0x74,0x68,0x65,0x6e])]===_0x4b24e6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3b028c[_0x4b24e6([0x63,0x61,0x74,0x63,0x68])]===_0x4b24e6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x43d62d(_0x1359d6){_0x31221a(_0x1359d6)[_0x4b24e6([0x74,0x68,0x65,0x6e])](_0x1f3301=>{if(!_0x1f3301||_0x1f3301[_0x4b24e6([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4b24e6([0x6f,0x6b]))return _0x4b24e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x62240e(_0x6c9a4e(_0x1640b2+_0x3ff982))!=_0x1f3301[_0x4b24e6([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4b24e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4b24e6([0x56,0x61,0x6c,0x69,0x64]);})[_0x4b24e6([0x74,0x68,0x65,0x6e])](_0xe4e10d=>(_0x245221(),_0xe4e10d),()=>{const _0x23734a=_0x35ee9c();return null==_0x23734a?(_0x245221(),_0x4b24e6([0x56,0x61,0x6c,0x69,0x64])):_0x4b24e6(_0x5f0100-_0x23734a>(0x3bf8c078^_0x1ac2a2)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4b24e6([0x74,0x68,0x65,0x6e])](_0x512199)[_0x4b24e6([0x63,0x61,0x74,0x63,0x68])](()=>{_0x512199(_0x4b24e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x492e57=0x1fc2aaf8^_0x1ac2a2;function _0x245221(){const _0x372865=_0x4b24e6([0x6c,0x6c,0x63,0x74,0x2d])+_0x62240e(_0x6c9a4e(_0x199b78)),_0xcd31e1=_0x21a38d(_0x62240e(window[_0x4b24e6([0x4d,0x61,0x74,0x68])][_0x4b24e6([0x63,0x65,0x69,0x6c])](_0x5f0100/_0x492e57)));window[_0x4b24e6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4b24e6([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x372865,_0xcd31e1);}function _0x35ee9c(){const _0x1959e9=_0x4b24e6([0x6c,0x6c,0x63,0x74,0x2d])+_0x62240e(_0x6c9a4e(_0x199b78)),_0x3920bf=window[_0x4b24e6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4b24e6([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1959e9);return _0x3920bf?window[_0x4b24e6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x21a38d(_0x3920bf),0x10)*_0x492e57:null;}function _0x31221a(_0x28d5d9){return new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x26c235,_0x55a8fb)=>{_0x28d5d9[_0x4b24e6([0x74,0x68,0x65,0x6e])](_0x26c235,_0x55a8fb),window[_0x4b24e6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x55a8fb,0x1ff590b8^_0x1ac2a2);});}}_0x54dd04[_0x4b24e6([0x6f,0x6e])](_0x4b24e6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x39d941,_0x52b6ac)=>{if(_0x52b6ac[0x0]!=_0x199b78)return _0x512199(_0x4b24e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x52b6ac[0x1]={..._0x52b6ac[0x1],[_0x4b24e6([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1640b2};},{[_0x4b24e6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4b24e6([0x68,0x69,0x67,0x68])}),_0x54dd04[_0x4b24e6([0x6f,0x6e])](_0x4b24e6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4ca52e=>{_0x6dd9c4(_0x4ca52e[_0x4b24e6([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3f16a5=!0x0,_0x43d62d(_0x4ca52e[_0x4b24e6([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4b24e6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4b24e6([0x6c,0x6f,0x77])}),_0xad72c[_0x4b24e6([0x74,0x68,0x65,0x6e])](()=>{_0x3f16a5||_0x512199(_0x4b24e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1a65b2(){return _0x54dd04[_0x4b24e6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4b24e6([0x76,0x69,0x65,0x77])][_0x4b24e6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4b24e6([0x61,0x75,0x74,0x6f]);}function _0x4c283e(){_0x54dd04[_0x4b24e6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4b24e6([0x76,0x69,0x65,0x77])][_0x4b24e6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4b24e6([0x61,0x75,0x74,0x6f]);}}function _0x13602d(_0x508461){const _0x588a46=[new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x248ad3=>setTimeout(_0x248ad3,0x1ffd7ab4^_0x1ac2a2)),_0xad72c[_0x4b24e6([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1d7697=>{const _0xd8024c=0x1ff4447f^_0x1ac2a2,_0x596e18=_0x3aab5f[_0x4b24e6([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3787a3(){_0x596e18[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xd8024c&&_0x1d7697();}_0x3787a3(),_0x596e18[_0x4b24e6([0x6f,0x6e])](_0x4b24e6([0x61,0x64,0x64]),_0x3787a3);})),new window[(_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x533ce4=>{function _0x587eda(){for(const _0x385fce in window)if(window[_0x4b24e6([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4b24e6([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x385fce))&&window[_0x385fce]==_0x57bf2b)return _0x533ce4();_0x54dd04[_0x4b24e6([0x73,0x74,0x61,0x74,0x65])]!=_0x4b24e6([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4b24e6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x587eda,0x1ff457f0^_0x1ac2a2);}_0x518a1b(_0x4b24e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x587eda();})];return window[_0x4b24e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4b24e6([0x72,0x61,0x63,0x65])](_0x588a46)[_0x4b24e6([0x74,0x68,0x65,0x6e])](()=>_0x508461);}async function _0x46e6f1(){if(await _0xad72c,_0x518a1b(_0x4b24e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x11ae0a=_0x3aab5f[_0x4b24e6([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4f6e49=_0x3aab5f[_0x4b24e6([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])](_0x11ae0a[_0x4b24e6([0x69,0x64])]),_0x516853=_0x44eaf9(_0x4b24e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x516853[_0x4b24e6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x11ae0a['id'],_0x4f6e49?_0x4f6e49['id']:null,!0x0),_0x516853[_0x4b24e6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4b24e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x516853[_0x4b24e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x516853[_0x4b24e6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x674f95,void(_0x516853[_0x4b24e6([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x674f95);}if(_0x518a1b(_0x4b24e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x315857=_0x44eaf9(_0x4b24e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x315857[_0x4b24e6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4b24e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x315857[_0x4b24e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x315857[_0x4b24e6([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x674f95,_0x315857[_0x4b24e6([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x674f95;}_0x54dd04[_0x4b24e6([0x6d,0x6f,0x64,0x65,0x6c])][_0x4b24e6([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x674f95,_0x54dd04[_0x4b24e6([0x6d,0x6f,0x64,0x65,0x6c])][_0x4b24e6([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x674f95,_0x54dd04[_0x4b24e6([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4b24e6([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x16f687(){return _0x518a1b(_0x4b24e6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x44eaf9(_0x4b24e6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4b24e6([0x73,0x74,0x61,0x74,0x65])]==_0x4b24e6([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x49d702(){return _0x518a1b(_0x4b24e6([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 _0x5965d4(){return _0x518a1b(_0x4b24e6([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3f9e8b(_0x1ea82d){const _0x374922=_0x215452();_0x54dd04[_0x374922]=_0x4b24e6([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])+_0x1ea82d,_0x1ea82d[_0x4b24e6([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4b24e6([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x215452()]=_0x57bf2b),_0x1ea82d!=_0x4b24e6([0x56,0x61,0x6c,0x69,0x64])&&_0x46e6f1();}function _0x215452(){const _0x1aefc2=window[_0x4b24e6([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4b24e6([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4b24e6([0x6e,0x6f,0x77])]())[_0x4b24e6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4b24e6([0x2e]),'');let _0x52cd3a=_0x4b24e6([0x66]);for(let _0x5c0dc8=0x0;_0x5c0dc8<_0x1aefc2[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5c0dc8+=0x2){let _0x305fd1=window[_0x4b24e6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1aefc2[_0x4b24e6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5c0dc8,_0x5c0dc8+0x2));_0x305fd1>=_0x2393b0[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x305fd1-=_0x2393b0[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x52cd3a+=_0x2393b0[_0x305fd1];}return _0x52cd3a;}function _0x290d58(){const _0x5ab2e6=_0x2d75a1[_0x4b24e6([0x73,0x70,0x6c,0x69,0x74])](_0x4b24e6([0x2e]));if(0x3!=_0x5ab2e6[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1eae29(_0x5ab2e6[0x1]);function _0x1eae29(_0x135ea0){const _0x4c48a1=_0x353144(_0x135ea0);return _0x4c48a1&&_0x166f44()?_0x4c48a1:null;function _0x166f44(){const _0x2181be=_0x4c48a1[_0x4b24e6([0x6a,0x74,0x69])],_0x203ed7=window[_0x4b24e6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2181be[_0x4b24e6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2181be[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5d07a0={..._0x4c48a1,[_0x4b24e6([0x6a,0x74,0x69])]:_0x2181be[_0x4b24e6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x2181be[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5d07a0[_0x4b24e6([0x76,0x63])],_0x6c9a4e(_0x5d07a0)==_0x203ed7;}}}async function _0x29c6d1(){let _0x59299f=!0x0;try{const _0x28e81e=_0x2d75a1[_0x4b24e6([0x73,0x70,0x6c,0x69,0x74])](_0x4b24e6([0x2e])),[_0x2733cc,_0x36a841,_0xf814af]=_0x28e81e;return _0x8bda75(_0x2733cc),await _0x70c74(_0x2733cc,_0x36a841,_0xf814af),_0x59299f;}catch(_0x32250f){return!0x1;}function _0x8bda75(_0x3d5f88){const _0x54615b=_0x353144(_0x3d5f88);_0x54615b&&_0x54615b[_0x4b24e6([0x61,0x6c,0x67])]==_0x4b24e6([0x45,0x53,0x32,0x35,0x36])||(_0x59299f=!0x1);}async function _0x70c74(_0x493b2b,_0x5d7975,_0x2ab0ea){const _0x5383af=window[_0x4b24e6([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4b24e6([0x66,0x72,0x6f,0x6d])](_0x4bfb5b(_0x2ab0ea),_0x21ccb6=>_0x21ccb6[_0x4b24e6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4c452a=new window[(_0x4b24e6([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4b24e6([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x493b2b+_0x4b24e6([0x2e])+_0x5d7975),_0x54c4b6=window[_0x4b24e6([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4b24e6([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x54c4b6)return;const _0x4cc994=await _0x54c4b6[_0x4b24e6([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4b24e6([0x6a,0x77,0x6b]),_0x177bf5,{[_0x4b24e6([0x6e,0x61,0x6d,0x65])]:_0x4b24e6([0x45,0x43,0x44,0x53,0x41]),[_0x4b24e6([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4b24e6([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4b24e6([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x54c4b6[_0x4b24e6([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4b24e6([0x6e,0x61,0x6d,0x65])]:_0x4b24e6([0x45,0x43,0x44,0x53,0x41]),[_0x4b24e6([0x68,0x61,0x73,0x68])]:{[_0x4b24e6([0x6e,0x61,0x6d,0x65])]:_0x4b24e6([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4cc994,_0x5383af,_0x4c452a)||(_0x59299f=!0x1);}}function _0x353144(_0x1d5ea2){return _0x1d5ea2[_0x4b24e6([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4b24e6([0x65,0x79]))?JSON[_0x4b24e6([0x70,0x61,0x72,0x73,0x65])](_0x4bfb5b(_0x1d5ea2)):null;}function _0x4bfb5b(_0x479eb0){return window[_0x4b24e6([0x61,0x74,0x6f,0x62])](_0x479eb0[_0x4b24e6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4b24e6([0x2b]))[_0x4b24e6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4b24e6([0x2f])));}function _0x6c9a4e(_0x42c875){let _0xf4df11=0x1505;function _0x4d69aa(_0x4dd71c){for(let _0x4f2d6f=0x0;_0x4f2d6f<_0x4dd71c[_0x4b24e6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4f2d6f++){const _0x5ac6d8=_0x4dd71c[_0x4b24e6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4f2d6f);_0xf4df11=(_0xf4df11<<0x5)+_0xf4df11+_0x5ac6d8,_0xf4df11&=_0xf4df11;}}function _0x57adb0(_0x338917){Array[_0x4b24e6([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x338917)?_0x338917[_0x4b24e6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x57adb0):_0x338917&&typeof _0x338917==_0x4b24e6([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4b24e6([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x338917)[_0x4b24e6([0x73,0x6f,0x72,0x74])]()[_0x4b24e6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5d2603,_0x32e939])=>{_0x4d69aa(_0x5d2603),_0x57adb0(_0x32e939);}):_0x4d69aa(window[_0x4b24e6([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x338917));}return _0x57adb0(_0x42c875),_0xf4df11>>>0x0;}function _0x62240e(_0x41e9fb){return _0x41e9fb[_0x4b24e6([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4b24e6([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4b24e6([0x30]));}function _0x21a38d(_0x49e263){return _0x49e263[_0x4b24e6([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4b24e6([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4b24e6([0x6a,0x6f,0x69,0x6e])]('');}function _0x518a1b(_0x335ea5){return _0x54dd04[_0x4b24e6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4b24e6([0x68,0x61,0x73])](_0x335ea5);}function _0x44eaf9(_0x2bb2b8){return _0x54dd04[_0x4b24e6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4b24e6([0x67,0x65,0x74])](_0x2bb2b8);}function _0x674f95(){}function _0x4b24e6(_0x2b7ee4){return _0x2b7ee4['map'](_0x4dbbee=>String['fromCharCode'](_0x4dbbee))['join']('');}_0x3f9e8b(await _0x47d7ff());}(this);}['createRevision'](_0x48bf56){const _0x4e6d5c=this['editor']['plugins']['get']('Users');return new a({'id':_0x48bf56['id'],'name':_0x48bf56['name'],'creator':_0x48bf56['creatorId']?_0x4e6d5c['getUser'](_0x48bf56['creatorId']):null,'diffData':_0x48bf56['diffData']||_0x48bf56['data'],'authors':_0x48bf56['authorsIds']['map'](_0x303344=>_0x4e6d5c['getUser'](_0x303344)),'createdAt':new Date(_0x48bf56['createdAt']),'attributes':_0x48bf56['attributes'],'fromVersion':_0x48bf56['fromVersion'],'toVersion':_0x48bf56['toVersion']});}['addRevision'](_0x531051,_0x768182=0x0){this['_revisions']['add'](_0x531051,_0x768182);}['getRevision'](_0x317b1d){return this['_revisions']['get'](_0x317b1d);}['getRevisions'](_0x143cb2={'toJSON':!0x1}){const _0x2bedd2=Array['from'](this['_revisions']);return _0x2bedd2['reverse'](),_0x143cb2['toJSON']?_0x2bedd2['map'](_0x171012=>_0x171012['toJSON']()):_0x2bedd2;}['getIndex'](_0x5ad0b5){return this['_revisions']['getIndex'](_0x5ad0b5);}['getEarlierVisibleRevision'](_0x2ed6d0){const [,_0xc10f36]=this['getRevisionsIterator'](_0x2ed6d0,{'direction':'earlier'});return _0xc10f36;}['getLaterVisibleRevision'](_0x32c5e1){const [,_0x615792]=this['getRevisionsIterator'](_0x32c5e1,{'direction':'later'});return _0x615792;}['getRevisionsInDiff'](_0x80cd75){const _0x2a4201=[];for(const _0x46ba03 of this['getRevisionsIterator'](_0x80cd75['newRevisionId']))if(_0x2a4201['push'](_0x46ba03),_0x46ba03['id']===_0x80cd75['oldRevisionId'])break;return _0x2a4201;}*['getRevisionsIterator'](_0x32a781,{direction:_0xecc70d='earlier',filter:_0x522d9=()=>!0x0}={}){const _0x5c4380='earlier'===_0xecc70d?0x1:-0x1;let _0x4e8ec0=this['_revisions']['get'](_0x32a781),_0x1848fd=this['getIndex'](_0x4e8ec0);for(yield _0x4e8ec0;_0x4e8ec0;){if(_0x1848fd+=_0x5c4380,_0x4e8ec0=this['getRevision'](_0x1848fd),!_0x4e8ec0)return;_0x522d9(_0x4e8ec0)&&(yield _0x4e8ec0);}}}function R(_0x130418,_0x139bad,_0x30dccd){const t=_0x130418['t'];switch(_0x139bad){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'},_0x30dccd);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x30dccd);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 C={'c':_0x39be7f,'a':_0x2124c2,'e':_0x324ff6,'r':_0xb02490,'u':_0x264acd};class l extends _0x49e1b4{['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[_0x57add3,j,_0x4a4333];}constructor(_0x35f0af){super(_0x35f0af),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x5b4a9c=_0x1c3ee2();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x5b4a9c},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 _0x968c49=this['repository']['getRevision'](0x0),_0x580654=_0x968c49&&null===_0x968c49['creator']?_0x968c49:null;if(this['_continueCurrentRevision']=!!_0x580654&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0xa710fc=this['_source']['getCurrentRevisionId'](),_0x4ad14d=this['repository']['getRevision'](_0xa710fc);if(_0x4ad14d)this['_startingVersion']=_0x4ad14d['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2b0bb1=this['_source']['history']['_operations']['find'](_0x340e7a=>!_0x340e7a['_isInit']),_0x4cb218=_0x2b0bb1?_0x2b0bb1['baseVersion']:this['_source']['history']['version'];_0x968c49?(_0x968c49['toVersion']<_0x4cb218&&_0x968c49['_update']({'toVersion':_0x4cb218}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x580654['id'],this['_startingVersion']=_0x580654['fromVersion']):(this['_startingVersion']=_0x968c49['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4cb218,this['_continueCurrentRevision']=!0x1);}}else _0x580654&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x580654['toVersion'],this['editor']['model']['document']['history']['version']),_0x580654['fromVersion']===_0x580654['toVersion']?(0x0!==_0x580654['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x580654['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x580654['id'],this['_startingVersion']=_0x580654['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',_0x5d0efc=>!_0x5d0efc),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xc9f333=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x47de60;for(const _0x5b1817 in _0xc9f333){const _0x4c32a4=_0x5b1817,_0x32bdbc=_0xc9f333[_0x4c32a4];if('revisionHistoryLicenseKeyValid'==_0x32bdbc||'revisionHistoryLicenseKeyInvalid'==_0x32bdbc||'revisionHistoryLicenseKeyExpired'==_0x32bdbc||'revisionHistoryLicenseKeyDomainLimit'==_0x32bdbc||'revisionHistoryLicenseKeyNotAllowed'==_0x32bdbc||'revisionHistoryLicenseKeyEvaluationLimit'==_0x32bdbc||'revisionHistoryLicenseKeyTrialLimit'==_0x32bdbc||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x32bdbc||'revisionHistoryLicenseKeyUsageLimit'==_0x32bdbc){delete _0xc9f333[_0x4c32a4],_0x47de60=_0x32bdbc,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x47de60&&_0xc9f333['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x47de60&&_0xc9f333['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x47de60&&_0xc9f333['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x47de60&&_0xc9f333['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x47de60&&_0xc9f333['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x47de60&&_0xc9f333['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x47de60&&_0xc9f333['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x47de60&&_0xc9f333['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1139d6=this['repository']['getRevision'](0x0),_0x50d5ed=await this['getRevisionDocumentData'](_0x1139d6),_0xb6d002=await this['getRevisionRootsAttributes'](_0x1139d6);this['_replaceEditorDataWithRevisionData'](_0x50d5ed,_0xb6d002);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4509cb){this['_source']=_0x4509cb;}async['update'](){const _0x4d5e6c=await this['_source']['getLatestVersion']();if(_0x4d5e6c>this['currentRevision']['toVersion']){await this['_loadState']();const _0x495782=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x4d5e6c});_0x495782['authors']=_0x495782['authorsIds']['map'](_0x11b22d=>this['editor']['plugins']['get']('Users')['getUser'](_0x11b22d)),this['currentRevision']['_update'](_0x495782);}}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'](_0x5c8a48={},_0x5c8834=null){const _0x529e0b=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5c8834>this['currentRevision']['toVersion']&&(_0x5c8834=null),null===_0x5c8834&&(_0x5c8834=await this['_source']['getLatestVersion']());const _0x1a5f71=this['_getFromVersion'](_0x5c8834),_0xa9bbec=this['buildRevisionData']({'from':_0x1a5f71,'to':_0x5c8834});if(this['currentRevision']['toVersion']<_0x5c8834){const _0x416feb=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5c8834,'to':_0x5c8834});_0x416feb['authors']=[],_0x416feb['authorsIds']=[],_0x416feb['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x416feb,!0x0),delete _0x416feb['authors'],_0x529e0b['push'](_0x416feb);}_0x5c8a48['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5c8a48['name']=_0x5c8a48['name']||null,_0x5c8a48['id']=_0x5c8a48['id']||_0x1c3ee2(),_0x5c8a48={..._0x5c8a48,..._0xa9bbec};const _0x15b837=this['addRevisionData'](_0x5c8a48);_0x529e0b['push'](_0x5c8a48);const _0x181d14=this['repository']['getIndex'](_0x15b837);if(0x0!==_0x181d14){const _0x204beb=this['repository']['getRevision'](_0x181d14-0x1);if(_0x204beb['fromVersion']!==_0x5c8834){const _0x71a966=this['_revisionDataBuilder']['getData'](_0x5c8834,_0x204beb['toVersion']),_0x2581d1={'id':_0x204beb['id'],'diffData':_0x71a966['diffData'],'authorsIds':_0x71a966['authorsIds'],'authors':_0x71a966['authorsIds']['map'](_0x1c6965=>this['editor']['plugins']['get']('Users')['getUser'](_0x1c6965)),'fromVersion':_0x5c8834};_0x204beb===this['currentRevision']&&(_0x2581d1['createdAt']=new Date(_0x5c8a48['createdAt']['getTime']()+0xa)),_0x204beb['_update'](_0x2581d1,!0x0),delete _0x2581d1['authors'],_0x529e0b['push'](_0x2581d1);}}if(this['adapter']){for(const _0x3cfb27 of _0x529e0b)this['_bufferUpdate'](_0x3cfb27['id'],_0x3cfb27,!0x0);this['sendBufferedUpdates']();}return _0x15b837;}['addRevisionData'](_0x2ede06){const _0x7286ab=this['repository']['createRevision'](_0x2ede06);return this['adapter']&&_0x7286ab['on']('_update',(_0x1736ce,_0x3b0f4c,_0x5ac3a5)=>{_0x5ac3a5||(this['_bufferUpdate'](_0x3b0f4c['id'],_0x3b0f4c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x7286ab,this['_findInsertionIndex'](_0x7286ab)),_0x7286ab;}async['getRevisionDocumentData'](_0x52e7c5){await this['_loadRevisionData'](_0x52e7c5);const _0x1302e8={};for(const _0x12abf5 in _0x52e7c5['diffData']){if(_0x52e7c5['diffData'][_0x12abf5]['attachChange']&&!_0x52e7c5['diffData'][_0x12abf5]['attachChange']['isAttached'])continue;const _0x5f0273=this['_removeRevisionMarkers'](JSON['parse'](_0x52e7c5['diffData'][_0x12abf5]['insertions'])),_0x44257b=this['editor']['editing']['view']['document'],_0x12f3a1=new _0x22eced(_0x44257b,_0x5f0273['map'](_0x1be56f=>V(_0x1be56f,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x1302e8[_0x12abf5]=this['editor']['data']['processor']['toData'](_0x12f3a1),this['editor']['data']['processor']['useFillerType']('default');}return _0x1302e8;}async['getRevisionRootsAttributes'](_0x24c8c2){await this['_loadRevisionData'](_0x24c8c2);const _0x4f8f4b={};for(const _0x26e8b2 in _0x24c8c2['diffData'])_0x24c8c2['diffData'][_0x26e8b2]['attachChange']&&!_0x24c8c2['diffData'][_0x26e8b2]['attachChange']['isAttached']||(_0x4f8f4b[_0x26e8b2]=_0x24c8c2['diffData'][_0x26e8b2]['attributesAfter']||{});return _0x4f8f4b;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x404e68=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x20a974=0x0;_0x20a974<_0x404e68['length'];_0x20a974++){const _0x53cab9=_0x404e68[_0x20a974];let _0x8baa90=!0x1;for(const _0x1b59a0 of Object['keys'](_0x53cab9))void 0x0===_0x53cab9[_0x1b59a0]?delete _0x53cab9[_0x1b59a0]:'id'!==_0x1b59a0&&(_0x8baa90=!0x0);_0x8baa90||(_0x404e68[_0x20a974]=null);}if(_0x404e68=_0x404e68['filter'](_0x586d8b=>null!==_0x586d8b),!_0x404e68['length'])return;for(let _0x1e0975=0x0;_0x1e0975<_0x404e68['length'];_0x1e0975++){const _0x9745b7=_0x404e68[_0x1e0975];void 0x0!==_0x9745b7['fromVersion']&&void 0x0===_0x9745b7['toVersion']&&(_0x9745b7['toVersion']=this['repository']['getRevision'](_0x9745b7['id'])['toVersion']),void 0x0!==_0x9745b7['toVersion']&&void 0x0===_0x9745b7['fromVersion']&&(_0x9745b7['fromVersion']=this['repository']['getRevision'](_0x9745b7['id'])['fromVersion']);}const _0x4e9363=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x404e68,_0x4e9363)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x27dc2a=>{if(_0x27dc2a){for(const _0x141791 of _0x27dc2a)this['setRevisionData']({'id':_0x141791['id'],'createdAt':_0x141791['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x17156e,_0x7c0374){let _0x55553a=this['editor']['config']['get']('initialData'),_0x1afc1d=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x55553a){_0x55553a={};for(const _0x51e4e9 of this['editor']['model']['document']['getRootNames']())_0x55553a[_0x51e4e9]='';}if('string'==typeof _0x55553a&&(_0x55553a={'main':_0x55553a}),void 0x0===_0x1afc1d){_0x1afc1d={};for(const _0x280425 of this['editor']['model']['document']['getRootNames']())_0x1afc1d[_0x280425]={};}let _0x2c678a=!0x1;const _0x18fdfc=Object['keys'](_0x55553a),_0x5b708a=Object['keys'](_0x17156e);for(const _0xb29378 of _0x18fdfc){if(_0x55553a[_0xb29378]!==_0x17156e[_0xb29378]&&''!==_0x55553a[_0xb29378]['trim']()){_0x2c678a=!0x0;break;}if(!_0x290338(_0x1afc1d[_0xb29378],_0x7c0374[_0xb29378])&&Object['keys'](_0x1afc1d[_0xb29378])['length']>0x0){_0x2c678a=!0x0;break;}}_0x2c678a||(_0x2c678a=_0x5b708a['some'](_0x3774d6=>!this['editor']['model']['document']['getRoot'](_0x3774d6))),_0x2c678a&&_0x1be885('editor-initial-data-replaced-with-revision-data',{'editorData':_0x55553a,'editorRootsAttributes':_0x1afc1d,'revisionData':_0x17156e,'revisionRootsAttributes':_0x7c0374}),this['editor']['config']['set']('initialData',_0x17156e),this['editor']['config']['set']('rootsAttributes',_0x7c0374);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x16758c=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x16758c['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4444de){const _0x12fa32=this['repository']['getRevisions']();_0x12fa32['reverse']();let _0x20e718=0x0;for(;_0x20e718<_0x12fa32['length'];){const _0x2919b7=_0x12fa32[_0x20e718];if(_0x2919b7===this['currentRevision']){_0x20e718++;continue;}if(_0x2919b7['id']===this['_initialRevisionId'])break;const _0x5433ff=_0x4444de['toVersion']-_0x2919b7['toVersion']||_0x4444de['fromVersion']-_0x2919b7['fromVersion'];if(_0x5433ff>0x0)break;if(_0x5433ff<0x0)_0x20e718++;else{if(!_0x4444de['creator']&&_0x2919b7['creator'])break;if(_0x2919b7['creator']||!_0x4444de['creator']){if(_0x4444de['createdAt']>_0x2919b7['createdAt'])break;_0x20e718++;}else _0x20e718++;}}return _0x20e718;}['setRevisionData'](_0x48d31a){const _0x1ae6ae=this['repository']['getRevision'](_0x48d31a['id']);if(_0x48d31a['createdAt']&&(_0x48d31a['createdAt']=new Date(_0x48d31a['createdAt'])),_0x48d31a['authorsIds']){const _0x1fb1ac=this['editor']['plugins']['get']('Users');_0x48d31a['authors']=_0x48d31a['authorsIds']['map'](_0x5eac10=>_0x1fb1ac['getUser'](_0x5eac10));}_0x1ae6ae['_update'](_0x48d31a,!0x0);}['buildRevisionData']({revision:_0xe3eaf7=null,from:_0x28f783=null,to:_0x76eced=null}){_0x28f783=null!==_0x28f783?_0x28f783:_0xe3eaf7['fromVersion'],_0x76eced=null!==_0x76eced?_0x76eced:_0xe3eaf7['toVersion'];const _0x46b560=this['_revisionDataBuilder']['getData'](_0x28f783,_0x76eced),_0x3d805c={'diffData':_0x46b560['diffData'],'authorsIds':_0x46b560['authorsIds'],'fromVersion':_0x28f783,'toVersion':_0x76eced};if(!_0xe3eaf7||_0x76eced!==_0xe3eaf7['toVersion']){const _0x583085=_0x76eced-0x1,_0x382fe1=this['_source']['history']['getOperation'](_0x583085);_0x3d805c['createdAt']=_0x382fe1&&_0x382fe1['createdAt']||new Date();}if(this['_loadedStateData']&&_0x28f783===this['_loadedStateData']['fromVersion']){for(const _0x39d55f of this['_loadedStateData']['authors'])_0x3d805c['authorsIds']['includes'](_0x39d55f['id'])||_0x3d805c['authorsIds']['push'](_0x39d55f['id']);}return _0x3d805c;}['_loadRevisionData'](_0x2db7b8){if(!_0x2db7b8||_0x2db7b8['diffData'])return Promise['resolve']();{const _0x358cf6=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x358cf6,'revisionId':_0x2db7b8['id']})['then'](_0x3710a2=>{_0x2db7b8['diffData']=_0x3710a2['diffData'];});}}['_bufferUpdate'](_0x36ce5c,_0x59d71d,_0x585337){if(this['_bufferedUpdates']['has'](_0x36ce5c)){const _0x952c72=this['_bufferedUpdates']['get'](_0x36ce5c);_0x59d71d=_0x585337?{..._0x952c72,..._0x59d71d}:{..._0x59d71d,..._0x952c72};}this['_bufferedUpdates']['set'](_0x36ce5c,_0x59d71d);}['_getFromVersion'](_0x2c200d){const _0x170388=this['repository']['getRevisions']();_0x170388['reverse'](),_0x170388['shift']();const _0x15eb2f=_0x170388['find'](_0x116ce4=>_0x116ce4['toVersion']<=_0x2c200d)['toVersion'];return _0x15eb2f<this['_startingVersion']?this['_startingVersion']:_0x15eb2f;}['_createInitialRevision'](_0x611c23){const _0xdd2d=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0xdd2d)this['_initialRevisionId']=_0xdd2d['id'];else{const _0x54a37a=!this['editor']['model']['document']['roots']['find'](_0x3dacc0=>this['editor']['model']['hasContent'](_0x3dacc0)),_0x3aa686=this['editor']['plugins']['get']('Users')['me']['id'],_0x49f11b=R(this['editor']['locale'],_0x54a37a?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x611c23,'to':_0x611c23,'id':this['_initialRevisionId'],'name':_0x49f11b,'creatorId':_0x3aa686});}}['_createCurrentRevision'](_0x11d04f){const _0x597794=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x597794),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x11d04f,'to':_0x11d04f,'id':_0x597794,'name':'','creatorId':null}));}['_makeRevision']({name:_0x2d1344,from:_0x49da21,to:_0x2c15ce,creatorId:_0x4af506,id:_0x351ead}){const _0x3073c0=this['buildRevisionData']({'from':_0x49da21,'to':_0x2c15ce});_0x3073c0['name']=_0x2d1344,_0x3073c0['creatorId']=_0x4af506,_0x3073c0['id']=_0x351ead;const _0x5a9c89=this['addRevisionData'](_0x3073c0);return this['adapter']&&this['_bufferUpdate'](_0x3073c0['id'],_0x3073c0,!0x0),_0x5a9c89;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x32dfd4){return(_0x32dfd4=_0x32dfd4['filter'](_0x5022f3=>!_0x5022f3['name']||'revision-start'!==_0x5022f3['name']&&'revision-end'!==_0x5022f3['name']))['forEach'](_0x2c138c=>{'string'!=typeof _0x2c138c&&(_0x2c138c['children']=this['_removeRevisionMarkers'](_0x2c138c['children']),_0x2c138c['attributes']=_0x2c138c['attributes']['filter'](_0x4b1b99=>!_0x4b1b99[0x0]['startsWith']('data-revision-')));}),_0x32dfd4;}}function V(_0x196437,_0x56177d){const _0x566eff=_0x56177d['editing']['view']['document'];if('string'==typeof _0x196437)return new _0x253de4(_0x566eff,_0x196437);{const _0x5531c3=_0x196437['children']['map'](_0xb7a45d=>V(_0xb7a45d,_0x56177d));return new(C[_0x196437['type']]||_0x4085ba)(_0x566eff,_0x196437['name'],_0x196437['attributes'],_0x5531c3);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x55637e){this['editor']=_0x55637e,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'](_0x34fc6d){this['source']=_0x34fc6d;const _0x1a4433=new Map(),_0x474acb=new Map(),_0x4c5080=this['editor']['model']['document']['roots']['map'](_0x3b14b7=>_0x3b14b7['rootName']);for(const _0x1e773a of _0x4c5080){const _0x43282b=this['editor']['model']['document']['getRoot'](_0x1e773a),_0x5a8e58=F(_0x43282b);_0x1a4433['set'](_0x1e773a,_0x5a8e58),_0x474acb['set'](_0x1e773a,Object['fromEntries'](_0x43282b['getAttributes']()));}const _0x8e2643=Array['from'](this['editor']['model']['markers'])['map'](_0x30dacc=>[_0x30dacc['name'],_0x30dacc['getRange']()]),_0x247aa5=this['source']['version'];this['_saveMetaData'](_0x247aa5,_0x1a4433,_0x8e2643,_0x474acb),this['_startingRevisionId']=this['_revisionId'];const _0x426d6d=new Map(),_0x49f8c8=new Map();for(const _0x4ce877 of _0x4c5080){const _0x1b9416=B(_0x4ce877);_0x426d6d['set'](_0x4ce877,_0x1b9416),_0x49f8c8['set'](_0x4ce877,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x426d6d,[],_0x49f8c8);}['getData'](_0x2ebbfe,_0x397049){if(this['_lastFrom']===_0x2ebbfe&&this['_lastTo']<=_0x397049)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x397049,!0x0);else{if(!this['_savedMetaData']['has'](_0x2ebbfe)){const _0x2cb67b=this['_getPreviousFrom'](_0x2ebbfe);this['_calculateMetaData'](_0x2cb67b,_0x2ebbfe,!0x1);}this['_calculateMetaData'](_0x2ebbfe,_0x397049,!0x0);}return this['_lastFrom']=_0x2ebbfe,this['_lastTo']=_0x397049,this['_getState']();}['loadState'](_0x14f0da){this['_reset'](),this['_lastFrom']=_0x14f0da['fromVersion'],this['_lastTo']=_0x14f0da['toVersion'];for(const _0x191f05 in _0x14f0da['diffData']){const _0x12602c=_0x14f0da['diffData'][_0x191f05]['attachChange'],_0x5d5438=_0x5f0f2b(_0x14f0da['diffData'][_0x191f05]['attributesBefore'])||{},_0x49cf9b=this['_makeModelFromViewString'](_0x14f0da['diffData'][_0x191f05]['deletions']);_0x49cf9b['rootName']=_0x191f05,_0x49cf9b['_isAttached']=!_0x12602c||!_0x12602c['isAttached'],_0x49cf9b['isAttached']=()=>_0x49cf9b['_isAttached'],this['_baseRoots']['set'](_0x191f05,_0x49cf9b),this['_baseRootsAttributes']['set'](_0x191f05,_0x5d5438),_0x12602c&&this['_touchedRoots']['set'](_0x191f05,_0x12602c);const _0x657ccc=this['_makeIdsRoot'](_0x49cf9b);this['_baseIdsRoots']['set'](_0x191f05,_0x657ccc);for(const [_0x15b6be,_0x1c9b21]of _0x49cf9b['markers']){if(!_0x15b6be['startsWith']('revision:'))continue;const _0x618832=_0x15b6be['split'](':')[0x2];for(const _0x36adf9 of _0x1c9b21['getWalker']({'singleCharacters':!0x0})){const _0x33e9e5=this['_getVidAttributeName'](_0x36adf9),_0x50813e='elementEnd'==_0x36adf9['type']?_0x36adf9['previousPosition']['path']['slice'](0x0,-0x1):_0x36adf9['previousPosition']['path'],_0x492b0d=_0x657ccc['getNodeByPath'](_0x50813e)['getAttribute'](_0x33e9e5);this['_touched']['set'](_0x492b0d,{'userId':_0x618832});}}}this['_startingRevisionId']=this['_revisionId'];const _0x5ede8a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x3a7053=>!this['_touched']['has'](_0x3a7053));let _0xd78587=0x0;const _0x53b7bf=new Map();for(const _0x20e9b5 in _0x14f0da['diffData']){const _0x2c77c2=_0x14f0da['diffData'][_0x20e9b5]['attachChange'],_0xa6a79d=_0x5f0f2b(_0x14f0da['diffData'][_0x20e9b5]['attributesAfter'])||{},_0x49f530=this['_makeModelFromViewString'](_0x14f0da['diffData'][_0x20e9b5]['insertions']);_0x49f530['rootName']=_0x20e9b5,_0x49f530['_isAttached']=!_0x2c77c2||_0x2c77c2['isAttached'],_0x49f530['isAttached']=()=>_0x49f530['_isAttached'],this['_diffRoots']['set'](_0x20e9b5,_0x49f530),this['_diffRootsAttributes']['set'](_0x20e9b5,_0xa6a79d);const _0x11f36d=this['_makeIdsRoot'](_0x49f530,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x20e9b5,_0x11f36d),_0x53b7bf['set'](_0x20e9b5,_0x49f530['isAttached']()?_0xa6a79d:{});for(const [_0x2d53ed,_0x692f46]of _0x49f530['markers']){if(!_0x2d53ed['startsWith']('revision:'))continue;const _0x4cea90=_0x2d53ed['split'](':')[0x2];for(const _0xe04404 of _0x692f46['getWalker']({'singleCharacters':!0x0})){const _0x37120f=this['_getVidAttributeName'](_0xe04404),_0x271965=this['_revisionId']++,_0x7c24d0='elementEnd'==_0xe04404['type']?_0xe04404['previousPosition']['path']['slice'](0x0,-0x1):_0xe04404['previousPosition']['path'];_0x11f36d['getNodeByPath'](_0x7c24d0)['_setAttribute'](_0x37120f,_0x271965),this['_touched']['set'](_0x271965,{'userId':_0x4cea90});}}for(const _0x5c0e45 of this['editor']['model']['createRangeIn'](_0x49f530)['getWalker']({'singleCharacters':!0x0})){const _0x3d851b=this['_getVidAttributeName'](_0x5c0e45),_0x4c410f='elementEnd'==_0x5c0e45['type']?_0x5c0e45['previousPosition']['path']['slice'](0x0,-0x1):_0x5c0e45['previousPosition']['path'],_0x2fc5cd=_0x11f36d['getNodeByPath'](_0x4c410f);_0x2fc5cd['getAttribute'](_0x3d851b)>0x0||_0x2fc5cd['_setAttribute'](_0x3d851b,_0x5ede8a[_0xd78587++]);}for(const [_0x52d3c6,_0x4337c9]of _0x49f530['markers'])_0x52d3c6['startsWith']('revision:')||this['_markers']['set'](_0x52d3c6,_0x4337c9);}const _0xa6e025=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0xa6e025),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xa6e025,0x1));const _0x470146=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x470146),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x470146,0x1));const _0x532bcd=Array['from'](this['_diffRoots'])['map'](([_0x37a49b,_0x51ed00])=>[_0x37a49b,F(_0x51ed00)]);this['_saveMetaData'](this['_lastTo'],_0x532bcd,this['_markers'],_0x53b7bf);}['_makeModelFromViewString'](_0x5b87e3){const _0x34853a=JSON['parse'](_0x5b87e3),_0x52e239=this['editor']['editing']['view']['document'],_0x13027a=new _0x22eced(_0x52e239,_0x34853a['map'](_0x39556f=>V(_0x39556f,this['editor'])));return this['editor']['data']['toModel'](_0x13027a);}['_saveMetaData'](_0x3a7dbf,_0x475f48,_0x39bc58,_0x28fd43){const _0x4fab90=new Map(_0x475f48),_0x437a55=new Map(_0x5f0f2b(_0x28fd43)),_0x756b07=new Map();for(const [_0x4f59a3,_0x2ad195]of _0x39bc58)_0x756b07['set'](_0x4f59a3,{'start':_0x2ad195['start']['clone'](),'end':_0x2ad195['end']['clone'](),'rootName':_0x2ad195['root']['rootName']});this['_savedMetaData']['set'](_0x3a7dbf,{'roots':_0x4fab90,'markers':_0x756b07,'rootsAttributes':_0x437a55});}['_removeMetaData'](_0x392f41){this['_savedMetaData']['delete'](_0x392f41);}['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'](_0x26ff6b,_0x30d8af=null){let _0x4f9a93=null;_0x26ff6b['is']('documentFragment')||(_0x4f9a93=new ft(_0x26ff6b['name'],{'vid_start':null===_0x30d8af?this['_revisionId']++:_0x30d8af++}));const _0x103640=[];for(const _0x161c26 of _0x26ff6b['getChildren']())if(_0x161c26['is']('element')){_0x103640['push'](this['_makeIdsRoot'](_0x161c26,_0x30d8af));const _0x4a66f0=_0x103640[_0x103640['length']-0x1];null!==_0x30d8af&&(_0x30d8af=_0x4a66f0['is']('element','$text')?_0x4a66f0['getAttribute']('vid')+0x1:_0x4a66f0['getAttribute']('vid_end')+0x1);}else{for(let _0x17c854=0x0;_0x17c854<_0x161c26['offsetSize'];_0x17c854++)_0x103640['push'](new ft('$text',{'vid':null===_0x30d8af?this['_revisionId']++:_0x30d8af++}));}if(_0x26ff6b['is']('documentFragment')){const _0x3751b4=B(_0x26ff6b['rootName']);return _0x3751b4['_insertChild'](0x0,_0x103640),_0x3751b4;}return _0x4f9a93['_setAttribute']('vid_end',null===_0x30d8af?this['_revisionId']++:_0x30d8af++),_0x4f9a93['_insertChild'](0x0,_0x103640),_0x4f9a93;}['_calculateMetaData'](_0xde2813,_0x5b957d,_0x20a018){this['_reset']();const {roots:_0x476ef4,markers:_0x3ea82b,rootsAttributes:_0x5e8247}=this['_savedMetaData']['get'](_0xde2813);this['_baseRoots']=new Map(_0x476ef4),this['_baseRootsAttributes']=new Map(_0x5f0f2b(_0x5e8247));for(const [_0x3a11dc,_0x2b20aa]of this['_baseRoots'])if('$graveyard'!==_0x3a11dc&&(this['_diffRoots']['set'](_0x3a11dc,F(_0x2b20aa)),this['_diffRootsAttributes']=new Map(_0x5f0f2b(_0x5e8247)),_0x20a018)){const _0x22d3ea=this['_revisionId'];this['_idsRoots']['set'](_0x3a11dc,this['_makeIdsRoot'](_0x2b20aa)),this['_baseIdsRoots']['set'](_0x3a11dc,this['_makeIdsRoot'](_0x2b20aa,_0x22d3ea));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x20a018&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x178856,_0x3ed66e]of _0x3ea82b){const _0x380cab=this['_baseRoots']['get'](_0x3ed66e['rootName']),_0x54dcbf=this['_diffRoots']['get'](_0x3ed66e['rootName']),_0x33a5c0=new vt(this['_fixPosition'](_0x3ed66e['start'],_0x380cab),this['_fixPosition'](_0x3ed66e['end'],_0x380cab)),_0x3e4b79=this['_fixRange'](_0x33a5c0,_0x54dcbf);_0x380cab['markers']['set'](_0x178856,_0x33a5c0),this['_markers']['set'](_0x178856,_0x3e4b79);}this['_applyOperations'](_0xde2813,_0x5b957d,_0x20a018);}['_applyOperations'](_0x17b048,_0x10835f,_0x2377fb){for(const _0x3bfb3f of this['source']['getOperations'](_0x17b048,_0x10835f))this['_handleOperation'](_0x3bfb3f,_0x2377fb);for(const _0x51f0c8 of this['_diffRoots']['values']())_0x51f0c8['markers']['clear']();for(const [_0x528e0d,_0x2d81bf]of this['_markers']){this['_diffRoots']['get'](_0x2d81bf['root']['rootName'])['markers']['set'](_0x528e0d,_0x2d81bf['clone']());}const _0xcd18cc=new Map(),_0x1a662f=new Map();for(const [_0x523328,_0x5356d6]of this['_diffRoots'])_0xcd18cc['set'](_0x523328,F(_0x5356d6)),_0x1a662f['set'](_0x523328,this['_diffRootsAttributes']['get'](_0x523328));this['_saveMetaData'](_0x10835f,_0xcd18cc,this['_markers'],_0x1a662f);}['_getPreviousFrom'](_0x4d58c5){const _0x5501a9=Array['from'](this['_savedMetaData']['keys']());_0x5501a9['sort']((_0x8b9153,_0x3a2f4a)=>_0x8b9153-_0x3a2f4a),_0x5501a9['reverse']();for(const _0x209a0d of _0x5501a9)if(_0x209a0d<_0x4d58c5)return _0x209a0d;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3741f0,_0x31ae34){const _0x3e9c41=Array['from'](_0x31ae34['markers'])['map'](([_0x139b27,_0x5bbe9c])=>[_0x139b27,this['_fixRange'](_0x5bbe9c,_0x3741f0)]);_0x3741f0['markers']=new Map(_0x3e9c41);}['_transformMarkers'](_0x1ef311){for(const _0xd2b63a of this['_markers']['values']()){const _0x4638d6=_0xd2b63a['getTransformedByOperation'](_0x1ef311),_0x4dace7=vt['_createFromRanges'](_0x4638d6);_0xd2b63a['start']=_0x4dace7['start'],_0xd2b63a['end']=_0x4dace7['end'];}}['_handleOperation'](_0x5cfd5f,_0x3d0c6d){if('addRoot'!=_0x5cfd5f['type']&&'detachRoot'!=_0x5cfd5f['type']){if('insert'==_0x5cfd5f['type']){const _0x53b75f=_0x5cfd5f['position']['root']['rootName'];this['_diffRoots']['has'](_0x53b75f)||(this['_diffRoots']['set'](_0x53b75f,B(_0x53b75f,!0x0)),this['_diffRootsAttributes']['set'](_0x53b75f,{}),_0x3d0c6d&&this['_idsRoots']['set'](_0x53b75f,B(_0x53b75f,!0x0)));}else{if('addRootAttribute'==_0x5cfd5f['type']||'removeRootAttribute'==_0x5cfd5f['type']||'changeRootAttribute'==_0x5cfd5f['type'])return void this['_handleRootAttributeOperation'](_0x5cfd5f);'marker'==_0x5cfd5f['type']&&this['_handleMarkerOperation'](_0x5cfd5f);}if('marker'!==_0x5cfd5f['type']){const _0x3103c0=this['_cloneOperation'](_0x5cfd5f,this['_diffRoots']);_0x3103c0['_execute'](),this['_transformMarkers'](_0x3103c0);}if(_0x3d0c6d)switch(_0x5cfd5f['type']){case'insert':this['_handleInsertOperation'](_0x5cfd5f);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5cfd5f);break;case'merge':this['_handleMergeOperation'](_0x5cfd5f);break;case'split':this['_handleSplitOperation'](_0x5cfd5f);}}else this['_handleRootOperation'](_0x5cfd5f,_0x3d0c6d);}['_cloneOperation'](_0x109a41,_0x483bfd){const _0x1d7780=_0x109a41['clone']();return _0x1d7780['_authorId']=_0x109a41['_authorId'],this['_fixOperation'](_0x1d7780,_0x483bfd),_0x1d7780;}['_getBaseVids'](_0x3d8b61){return _0x3d8b61['map'](_0x28ff41=>{const _0x2db715=this['_getVidAttributeName'](_0x28ff41);return Number(_0x28ff41['item']['getAttribute'](_0x2db715));});}['_generateTape'](_0x5e2517,_0x2a763e){if(_0x5e2517['is']('element','$text'))_0x2a763e['push']({'item':_0x5e2517,'type':'text'});else{_0x5e2517['is']('element')&&_0x2a763e['push']({'item':_0x5e2517,'type':'elementStart'});for(const _0x3bd8e1 of _0x5e2517['getChildren']())this['_generateTape'](_0x3bd8e1,_0x2a763e);_0x5e2517['is']('element')&&_0x2a763e['push']({'item':_0x5e2517,'type':'elementEnd'});}return _0x2a763e;}['_getState'](){const _0xf16df8=new Map(this['_touched']),_0x4e5a11=new Map(_0xf16df8),_0x1141cd=new Map(),_0x463621={'insertions':{},'deletions':{}},_0x48159f={'insertions':{},'deletions':{}},_0x3f87aa=new Map(),_0x40e9af=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x40e9af['delete']('$graveyard');for(const _0x75b751 of _0x40e9af){const _0x4dba44=this['_diffRoots']['get'](_0x75b751)||B(_0x75b751,!0x1),_0x27a650=this['_baseRoots']['get'](_0x75b751)||B(_0x75b751,!0x1);_0x4dba44['isAttached']()||_0x27a650['isAttached']()?(_0x463621['insertions'][_0x75b751]=F(_0x4dba44),_0x463621['deletions'][_0x75b751]=F(_0x27a650),this['_copyMarkers'](_0x463621['deletions'][_0x75b751],_0x27a650),this['_copyMarkers'](_0x463621['insertions'][_0x75b751],_0x4dba44),_0x48159f['insertions'][_0x75b751]=this['_generateTape'](this['_idsRoots']['get'](_0x75b751),[]),_0x48159f['deletions'][_0x75b751]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x75b751)||B(_0x75b751,!0x1),[])):_0x40e9af['delete'](_0x75b751);}for(const _0x41a5bf of _0x40e9af){const _0x4df427=_0x48159f['insertions'][_0x41a5bf];for(const _0x5a7826 of _0x4df427){const _0x240fe4=this['_getVidAttributeName'](_0x5a7826),_0x30721a=_0x5a7826['item']['getAttribute'](_0x240fe4);_0x4e5a11['delete'](_0x30721a),_0x30721a>=this['_startingRevisionId']&&_0x1141cd['set'](_0x30721a,_0xf16df8['get'](_0x30721a));}}for(const _0x775eb6 of _0x40e9af){const _0x13915f=_0x48159f['insertions'][_0x775eb6],_0x489f37=this['_getBaseVids'](_0x48159f['deletions'][_0x775eb6]);let _0x34345b=0x0;for(const _0x1d8f7b of _0x13915f){const _0x32e40f=this['_getVidAttributeName'](_0x1d8f7b),_0x4e8791=_0x1d8f7b['item']['getAttribute'](_0x32e40f);if(!_0x1141cd['has'](_0x4e8791)&&!_0x3f87aa['has'](_0x4e8791)){if(_0x4e5a11['has'](_0x4e8791))_0x34345b++;else{if(_0x4e8791!=_0x489f37[_0x34345b]){const _0x5eba70=_0xf16df8['get'](_0x4e8791)||_0xf16df8['get'](_0x489f37[_0x34345b]);for(;_0x4e8791!=_0x489f37[_0x34345b];)_0x4e5a11['has'](_0x489f37[_0x34345b])||(_0x3f87aa['set'](_0x489f37[_0x34345b],_0x5eba70),_0xf16df8['set'](_0x489f37[_0x34345b],_0x5eba70)),_0x34345b++;}_0x34345b++;}}}}for(const _0xf9d4e3 of _0x40e9af){const _0x3119fb=_0x48159f['insertions'][_0xf9d4e3];for(const _0x11a518 of _0x3119fb){const _0x5b99d2=this['_getVidAttributeName'](_0x11a518),_0x1a9fbc=_0x11a518['item']['getAttribute'](_0x5b99d2);if(_0x3f87aa['has'](_0x1a9fbc)){const _0x4f5e74=_0x3f87aa['get'](_0x1a9fbc);_0x4e5a11['has'](_0x1a9fbc)||_0x4e5a11['set'](_0x1a9fbc,{..._0x4f5e74}),_0x1141cd['set'](_0x1a9fbc,{..._0x4f5e74});}}}for(const _0x3c4def of _0x4e5a11['keys']())_0x3c4def>=this['_startingRevisionId']&&_0x4e5a11['delete'](_0x3c4def);const _0x265987=new Map();for(const _0x1ac466 of _0x40e9af){let _0x4e5651=_0x48159f['insertions'][_0x1ac466];for(const _0x3ad3a3 of _0x4e5651)if(_0x3ad3a3['item']['is']('element','tableCell')){const _0x7dcb5e=this['_getVidAttributeName'](_0x3ad3a3),_0x396cf3=_0x3ad3a3['item']['getAttribute'](_0x7dcb5e);if(_0x1141cd['has'](_0x396cf3)){const _0xb86411=_0x3ad3a3['item']['parent']['parent']['getAttribute']('vid_start'),_0x13a4a6=_0x265987['get'](_0xb86411)||new Set();_0x13a4a6['add'](_0x1141cd['get'](_0x396cf3)['userId']),_0x265987['set'](_0xb86411,_0x13a4a6);}}_0x4e5651=_0x48159f['deletions'][_0x1ac466];for(const _0x380d6e of _0x4e5651)if(_0x380d6e['item']['is']('element','tableCell')){const _0x5ddc4b=this['_getVidAttributeName'](_0x380d6e),_0xbcb471=_0x380d6e['item']['getAttribute'](_0x5ddc4b);if(_0x4e5a11['has'](_0xbcb471)){const _0x1ebf8c=_0x380d6e['item']['parent']['parent']['getAttribute']('vid_start'),_0x4322de=_0x265987['get'](_0x1ebf8c)||new Set();_0x4322de['add'](_0x4e5a11['get'](_0xbcb471)['userId']),_0x265987['set'](_0x1ebf8c,_0x4322de);}}for(const _0xdbc68d of _0x265987['keys']())(_0x1141cd['has'](_0xdbc68d)||_0x4e5a11['has'](_0xdbc68d))&&_0x265987['delete'](_0xdbc68d);}for(const _0x7cccd of _0x40e9af){const _0x3ecff3=_0x48159f['insertions'][_0x7cccd];let _0xcebeba=null,_0x36eca8=null;for(const _0x5835e7 of _0x3ecff3){const _0x46c6ee=this['_getVidAttributeName'](_0x5835e7),_0x5a8b5e=_0x5835e7['item']['getAttribute'](_0x46c6ee),_0x5e0b8a=_0x265987['get'](_0x5a8b5e);_0x5e0b8a&&'elementStart'==_0x5835e7['type']&&(_0xcebeba=Array['from'](_0x5e0b8a)[0x0],_0x36eca8=_0x5835e7['item']['getAttribute']('vid_end')),_0xcebeba&&(_0x4e5a11['set'](_0x5a8b5e,{'userId':_0xcebeba}),_0x1141cd['set'](_0x5a8b5e,{'userId':_0xcebeba})),_0x5a8b5e==_0x36eca8&&(_0xcebeba=null,_0x36eca8=null);}}const _0x1ce740={},_0x1f9e24=new Set();for(const _0x2a97fe of _0x40e9af){const _0x28dca6=_0x463621['deletions'][_0x2a97fe],_0x2a8f1a=_0x463621['insertions'][_0x2a97fe];for(const {userId:_0x1a4648}of this['_touchedMarkers']['values']())null!==_0x1a4648&&_0x1f9e24['add'](_0x1a4648);for(const {userId:_0x1028dc}of this['_touchedRoots']['values']())null!==_0x1028dc&&_0x1f9e24['add'](_0x1028dc);this['_markChanges'](_0x2a8f1a,_0x48159f['insertions'][_0x2a97fe],_0x1141cd,'insertion',_0x1f9e24),this['_markChanges'](_0x28dca6,_0x48159f['deletions'][_0x2a97fe],_0x4e5a11,'deletion',_0x1f9e24),_0x1ce740[_0x2a97fe]={'insertions':this['_prepareViewToSave'](_0x2a8f1a),'deletions':this['_prepareViewToSave'](_0x28dca6),'attachChange':this['_touchedRoots']['get'](_0x2a97fe)||null,'attributesBefore':_0x5f0f2b(this['_baseRootsAttributes']['get'](_0x2a97fe))||{},'attributesAfter':_0x5f0f2b(this['_diffRootsAttributes']['get'](_0x2a97fe))};}return{'diffData':_0x1ce740,'authorsIds':Array['from'](_0x1f9e24)};}['_processRootBeforeSave'](_0x17390c){for(const [,_0x526600]of _0x17390c['markers']){const _0x3d2e30=_0x526600['start']['getAncestors']()['filter'](_0x37e541=>'tableCell'==_0x37e541['name']);for(const _0x318c07 of _0x3d2e30)0x1==_0x318c07['childCount']&&_0x318c07['getChild'](0x0)['is']('element','paragraph')&&_0x318c07['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x84d106){this['_processRootBeforeSave'](_0x84d106);const _0x2f3b5a=this['editor']['data']['toView'](_0x84d106,{}),_0x681924=Array['from'](_0x2f3b5a['getChildren']())['map'](_0x1f4ed9=>this['_getViewJson'](_0x1f4ed9));return JSON['stringify'](_0x681924);}['_getViewJson'](_0x4069c){if(_0x4069c['is']('$text'))return _0x4069c['data'];{const _0x4efe6d=_0x4069c;return{'type':Object['keys'](C)['find'](_0x243551=>_0x4069c instanceof C[_0x243551]),'name':_0x4efe6d['name'],'attributes':Array['from'](_0x4efe6d['getAttributes']()),'children':Array['from'](_0x4efe6d['getChildren']())['map'](_0x4b40db=>this['_getViewJson'](_0x4b40db))};}}['_markChanges'](_0x5e4e94,_0x3e5289,_0x1a0ae1,_0x2550ca,_0x35a72b){let _0x315f0b=null,_0x2c7d6b=null,_0x41a305=0x0;const _0x57717a=this['editor']['model'];for(let _0x1e4499=0x0;_0x1e4499<_0x3e5289['length'];_0x1e4499++){const _0x5918f7=this['_getVidAttributeName'](_0x3e5289[_0x1e4499]),_0x4ca511=_0x3e5289[_0x1e4499]['item']['getAttribute'](_0x5918f7),_0x3ecd99=_0x1a0ae1['get'](_0x4ca511),_0x3c12fa=_0x1e4499==_0x3e5289['length']-0x1;(!_0x315f0b&&_0x3ecd99&&(_0x315f0b=_0x3ecd99,_0x2c7d6b=_0x3e5289[_0x1e4499]),_0x315f0b&&(!_0x3ecd99||_0x3ecd99['userId']!=_0x315f0b['userId']))&&(_0x52c88b(_0x3ecd99,J(_0x2c7d6b,_0x5e4e94,_0x57717a),J(_0x3e5289[_0x1e4499],_0x5e4e94,_0x57717a)),_0x315f0b=_0x3ecd99||null,_0x2c7d6b=_0x3ecd99?_0x3e5289[_0x1e4499]:null),_0x315f0b&&_0x3c12fa&&_0x52c88b(_0x3ecd99,J(_0x2c7d6b,_0x5e4e94,_0x57717a),q(_0x3e5289[_0x1e4499],_0x5e4e94,_0x57717a));}function _0x52c88b(_0x1152f4,_0x3e4305,_0x5aad7e){const _0x16a6c4=_0x315f0b['userId'],_0x201c9e='revision:'+_0x2550ca+':'+_0x16a6c4+':'+_0x41a305++,_0x41b593=_0x57717a['createRange'](_0x3e4305,_0x5aad7e);_0x5e4e94['markers']['set'](_0x201c9e,_0x41b593),null!==_0x16a6c4&&_0x35a72b['add'](_0x16a6c4);}}['_getVidAttributeName'](_0x14a48c){switch(_0x14a48c['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x539973,_0x4f762c){_0x539973['baseVersion']=null;for(const _0x1bf2dc in _0x539973){const _0x3e3484=_0x539973[_0x1bf2dc];if(_0x3e3484 instanceof gt){const _0x4c09ba=_0x4f762c['get'](_0x3e3484['root']['rootName']);_0x539973[_0x1bf2dc]=this['_fixPosition'](_0x3e3484,_0x4c09ba);}if(_0x3e3484 instanceof vt){const _0x225e26=_0x4f762c['get'](_0x3e3484['root']['rootName']);_0x539973[_0x1bf2dc]=this['_fixRange'](_0x3e3484,_0x225e26);}'root'===_0x1bf2dc&&(_0x539973['root']=_0x4f762c['get'](_0x539973['root']['rootName']));}}['_fixRange'](_0x1f7e14,_0x51c714){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1f7e14['start'],_0x51c714),this['_fixPosition'](_0x1f7e14['end'],_0x51c714));}['_fixPosition'](_0x43d886,_0x418990){return this['editor']['model']['createPositionFromPath'](_0x418990,_0x43d886['path'],_0x43d886['stickiness']);}['_handleInsertOperation'](_0x30fd73){const _0x18ae8f=this['_idsRoots']['get'](_0x30fd73['position']['root']['rootName']),_0x2463cf=this['_fixPosition'](_0x30fd73['position'],_0x18ae8f),_0x3382b5=null===_0x30fd73['_authorId']?null:_0x30fd73['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x59e5e0=_0x2463cf['parent'],_0x20647b=this['_revisionId'],_0x4bb07a=[];for(const _0x3bd6c1 of _0x30fd73['nodes'])if(_0x3bd6c1['is']('element'))_0x4bb07a['push'](this['_makeIdsRoot'](_0x3bd6c1));else{for(let _0x2ab0e9=0x0;_0x2ab0e9<_0x3bd6c1['offsetSize'];_0x2ab0e9++)_0x4bb07a['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x2db57b=this['_revisionId'];for(let _0xa7c4ff=_0x20647b;_0xa7c4ff<_0x2db57b;_0xa7c4ff++)this['_touched']['set'](_0xa7c4ff,{'userId':_0x3382b5});_0x59e5e0['_insertChild'](_0x2463cf['offset'],_0x4bb07a);}['_handleMoveOperation'](_0xe155ac){(_0xe155ac=this['_cloneOperation'](_0xe155ac,this['_idsRoots']))['_execute']();const _0x44c857=null===_0xe155ac['_authorId']?null:_0xe155ac['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x40d9f9=_0xe155ac['getMovedRangeStart'](),_0x5eaffc=_0x40d9f9['parent'],_0x1633f9=_0x40d9f9['offset'];!function _0x4418e5(_0x498011,_0x12a5c4,_0x5f08f3,_0x25772c){for(let _0x4ea24a=_0x5f08f3;_0x4ea24a<_0x25772c;_0x4ea24a++){const _0x5484e7=_0x12a5c4['getChild'](_0x4ea24a);_0x5484e7['is']('element','$text')?_0x498011['set'](_0x5484e7['getAttribute']('vid'),{'userId':_0x44c857}):(_0x498011['set'](_0x5484e7['getAttribute']('vid_start'),{'userId':_0x44c857}),_0x4418e5(_0x498011,_0x5484e7,0x0,_0x5484e7['childCount']),_0x498011['set'](_0x5484e7['getAttribute']('vid_end'),{'userId':_0x44c857}));}}(this['_touched'],_0x5eaffc,_0x1633f9,_0x1633f9+_0xe155ac['howMany']);}['_handleMergeOperation'](_0x361c2b){const _0x57bac8=null===(_0x361c2b=this['_cloneOperation'](_0x361c2b,this['_idsRoots']))['_authorId']?null:_0x361c2b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3a74b7=_0x361c2b['targetPosition']['parent'],_0xdc783f=_0x361c2b['sourcePosition']['parent'],_0x14870d=_0x3a74b7['getAttribute']('vid_end'),_0x297c18=_0xdc783f['getAttribute']('vid_start');_0x3a74b7['_setAttribute']('vid_end',_0xdc783f['getAttribute']('vid_end')),_0xdc783f['_setAttribute']('vid_end',_0x14870d),this['_touched']['set'](_0x297c18,{'userId':_0x57bac8}),this['_touched']['set'](_0x14870d,{'userId':_0x57bac8}),_0x361c2b['_execute']();}['_handleSplitOperation'](_0x55e136){const _0x4029fb=null===(_0x55e136=this['_cloneOperation'](_0x55e136,this['_idsRoots']))['_authorId']?null:_0x55e136['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x8da9f5=_0x55e136['graveyardPosition'],_0x210dae=_0x55e136['splitPosition']['parent'];_0x55e136['_execute']();const _0x2457ab=_0x210dae['getAttribute']('vid_end'),_0x2f3ca7=_0x55e136['insertionPosition']['nodeAfter'];if(_0x8da9f5){const _0x32a942=_0x2f3ca7['getAttribute']('vid_end'),_0x538956=_0x210dae['getAttribute']('vid_end');_0x210dae['_setAttribute']('vid_end',_0x32a942),_0x2f3ca7['_setAttribute']('vid_end',_0x538956),this['_touched']['set'](_0x210dae['getAttribute']('vid_end'),{'userId':_0x4029fb}),this['_touched']['set'](_0x2f3ca7['getAttribute']('vid_start'),{'userId':_0x4029fb});}else{const _0x4cc952=this['_revisionId']++,_0x1edf30=this['_revisionId']++;_0x210dae['_setAttribute']('vid_end',_0x4cc952),_0x2f3ca7['_setAttribute']('vid_start',_0x1edf30),_0x2f3ca7['_setAttribute']('vid_end',_0x2457ab),this['_touched']['set'](_0x4cc952,{'userId':_0x4029fb}),this['_touched']['set'](_0x1edf30,{'userId':_0x4029fb});}}['_handleMarkerOperation'](_0x41abe0){if(!_0x41abe0['affectsData'])return;const _0x5d603f=(_0x41abe0=this['_cloneOperation'](_0x41abe0,this['_diffRoots']))['oldRange']?_0x41abe0['oldRange']['root']:null,_0x31091a=_0x41abe0['newRange']?_0x41abe0['newRange']['root']:null;_0x5d603f&&this['_markers']['delete'](_0x41abe0['name']),_0x31091a&&this['_markers']['set'](_0x41abe0['name'],_0x41abe0['newRange']['clone']());const _0x4d140c=null===_0x41abe0['_authorId']?null:_0x41abe0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3361aa=_0x41abe0['name'];if(!this['_touchedMarkers']['has'](_0x3361aa))return void this['_touchedMarkers']['set'](_0x3361aa,{'range':_0x41abe0['oldRange'],'userId':_0x4d140c});const _0x9fc98=this['_touchedMarkers']['get'](_0x3361aa),_0xff7e31=_0x9fc98['range'],_0xb660bc=_0x41abe0['newRange'];null==_0xff7e31&&null==_0xb660bc||_0xff7e31&&_0xb660bc&&_0xff7e31['isEqual'](_0xb660bc)?this['_touchedMarkers']['delete'](_0x41abe0['name']):_0x9fc98['userId']=_0x4d140c;}['_handleRootOperation'](_0xac9bf,_0x47aa68){this['_diffRoots']['has'](_0xac9bf['rootName'])?this['_diffRoots']['get'](_0xac9bf['rootName'])['_isAttached']=_0xac9bf['isAdd']:(this['_diffRoots']['set'](_0xac9bf['rootName'],B(_0xac9bf['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0xac9bf['rootName'],{}),_0x47aa68&&this['_idsRoots']['set'](_0xac9bf['rootName'],B(_0xac9bf['rootName'],!0x0)));const _0x290c8c=null===_0xac9bf['_authorId']?null:_0xac9bf['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x368fa8=this['_touchedRoots']['get'](_0xac9bf['rootName']);_0x368fa8&&_0x368fa8['userId']===_0x290c8c?this['_touchedRoots']['delete'](_0xac9bf['rootName']):this['_touchedRoots']['set'](_0xac9bf['rootName'],{'userId':_0x290c8c,'isAttached':_0xac9bf['isAdd']});}['_handleRootAttributeOperation'](_0x118d2a){const _0x502fa1=this['_diffRootsAttributes']['get'](_0x118d2a['root']['rootName']);null===_0x118d2a['newValue']?delete _0x502fa1[_0x118d2a['key']]:_0x502fa1[_0x118d2a['key']]=_0x118d2a['newValue'];}}function F(_0x1b5e12){const _0x33cff1=B(_0x1b5e12['rootName'],_0x1b5e12['isAttached']());for(const _0x32d7f2 of _0x1b5e12['getChildren']()){const _0xa9b271=_0x32d7f2['_clone'](!0x0);_0x33cff1['_appendChild'](_0xa9b271);}return _0x33cff1;}function B(_0x3d86b9,_0x19d54a=!0x0){const _0x128ce3=new mt();return _0x128ce3['rootName']=_0x3d86b9,_0x128ce3['_isAttached']=_0x19d54a,_0x128ce3['isAttached']=()=>_0x128ce3['_isAttached'],_0x128ce3;}function J(_0x11cb8d,_0x4cb793,_0x15bfed){const _0x4f5403='elementEnd'==_0x11cb8d['type']?_0x15bfed['createPositionAt'](_0x11cb8d['item'],'end'):_0x15bfed['createPositionBefore'](_0x11cb8d['item']);return _0x15bfed['createPositionFromPath'](_0x4cb793,_0x4f5403['path'],_0x4f5403['stickiness']);}function q(_0x40cf55,_0x5ee822,_0x15f082){const _0x609f5f='elementStart'==_0x40cf55['type']?_0x15f082['createPositionAt'](_0x40cf55['item'],0x0):_0x15f082['createPositionAfter'](_0x40cf55['item']);return _0x15f082['createPositionFromPath'](_0x5ee822,_0x609f5f['path'],_0x609f5f['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x2719a3,_0x498359){super(_0x2719a3),this['focusTracker']=new _0x2e0c4d(),this['keystrokes']=new _0x4b93df(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x498359),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x541811(this);}['render'](){super['render'](),_0x804b05({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xd7569c=_0x3b3008=>_0x3b3008['stopPropagation']();this['keystrokes']['set']('arrowright',_0xd7569c),this['keystrokes']['set']('arrowleft',_0xd7569c),this['keystrokes']['set']('arrowup',_0xd7569c),this['keystrokes']['set']('arrowdown',_0xd7569c);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x43f613){this['revisionNameInputView']['fieldView']['element']['value']=_0x43f613['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x2229e2){const _0x2c9ac4=new _0x2dd0c6(this['locale'],_0x1df99b),_0x4b90a6=_0x2c9ac4['fieldView'];_0x4b90a6['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x19de87=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x2229e2&&(_0x19de87+='\x20('+R(this['locale'],'optional')+')'),(_0x2c9ac4['label']=_0x19de87,_0x4b90a6['on']('input',()=>{this['revisionNameInputValue']=_0x4b90a6['element']['value']['trim']();}),_0x2c9ac4);}}class u extends _0x49e1b4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x3248a3=this['editor'],_0x59280f=_0x3248a3['plugins']['get']('RevisionTracker');_0x3248a3['ui']['componentFactory']['add']('revisionHistory',_0xed4a9=>{const _0x23fbde=_0x10f4d8(_0xed4a9),_0x58d333=_0x23fbde['panelView']['children'],_0x29ded4=new _0x490cb1(_0xed4a9),_0x330625=new _0x4b50ba(_0xed4a9),_0x3971eb=new te(_0xed4a9),_0x230262=new _0x4b50ba(_0xed4a9),_0x947f87=new te(_0xed4a9);return _0x23fbde['bind']('isEnabled')['to'](_0x59280f,'isReady',_0x59280f,'isEnabled',_0x3248a3,'isReadOnly',(_0x31ac26,_0x3eb83a,_0x25314e)=>_0x31ac26&&_0x3eb83a&&!_0x25314e),_0x23fbde['buttonView']['set']({'icon':_0x4e4052['history'],'label':R(_0xed4a9,'Revision\x20history'),'tooltip':!0x0}),_0x3971eb['set']({'label':R(_0xed4a9,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x3971eb['bind']('isEnabled')['to'](_0x59280f,'isReady',_0x59280f,'isEnabled',_0x3248a3,'isReadOnly',(_0x18c8a7,_0x223fe6,_0x3b008b)=>_0x18c8a7&&_0x223fe6&&!_0x3b008b),_0x3971eb['on']('execute',()=>this['_showDialog']()),_0x947f87['set']({'label':R(_0xed4a9,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x947f87['bind']('isEnabled')['to'](_0x59280f,'isReady',_0x3248a3,'isReadOnly',(_0x5c5777,_0x3d3565)=>_0x5c5777&&!_0x3d3565),_0x947f87['on']('execute',()=>{_0x3248a3['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x23fbde['isOpen']=!0x1,_0x3248a3['editing']['view']['focus']();}),_0x330625['children']['add'](_0x3971eb),_0x230262['children']['add'](_0x947f87),_0x29ded4['role']='menu',_0x29ded4['items']['addMany']([_0x330625,_0x230262]),_0x58d333['add'](_0x29ded4),_0x23fbde;}),_0x3248a3['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x450f18=this['editor'],_0x3a7009=_0x450f18['locale'],_0x4ca0fa=new _0x3058d9(_0x3a7009),_0x294520=new _0x5bf8a9(_0x3a7009);_0x4ca0fa['buttonView']['set']({'icon':_0x4e4052['history'],'label':R(_0x3a7009,'Revision\x20history')});const _0x5100f2=new _0x505bc2(_0x3a7009,_0x4ca0fa),_0x29ed80=new _0x1f5186(_0x3a7009);_0x29ed80['set']({'label':R(_0x3a7009,'Save\x20current\x20revision')}),_0x29ed80['delegate']('execute')['to'](_0x4ca0fa),_0x29ed80['on']('execute',()=>{this['_showDialog']();}),_0x5100f2['children']['add'](_0x29ed80),_0x294520['items']['add'](_0x5100f2);const _0x2f9a0d=new _0x505bc2(_0x3a7009,_0x4ca0fa),_0x505477=new _0x1f5186(_0x3a7009);return _0x505477['set']({'label':R(_0x3a7009,'Open\x20revision\x20history')}),_0x505477['delegate']('execute')['to'](_0x4ca0fa),_0x505477['on']('execute',()=>{_0x450f18['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x2f9a0d['children']['add'](_0x505477),_0x294520['items']['add'](_0x2f9a0d),_0x4ca0fa['panelView']['children']['add'](_0x294520),_0x4ca0fa;}['_showDialog'](){const _0x230030=this['editor'],_0x57cd77=_0x230030['locale'],_0x1c8f5f=_0x230030['plugins']['get']('Dialog'),_0x35b0af=_0x230030['plugins']['get']('RevisionTracker');function _0x5e9d44(_0x338d9a){_0x230030['config']['get']('revisionHistory.requireRevisionName')&&''===_0x338d9a['revisionName']?_0x338d9a['revisionNameInputView']['errorText']=R(_0x57cd77,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x230030['plugins']['get'](l)['saveRevision']({'name':_0x338d9a['revisionName']}),_0x1c8f5f['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x5e9d44(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1c8f5f['show']({'id':'revisionSave','title':R(_0x57cd77,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x230030['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1c8f5f['hide']()},{'label':R(_0x230030['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x573a64){_0x573a64['bind']('isEnabled')['to'](_0x35b0af,'isReady',_0x35b0af,'isEnabled',_0x230030,'isReadOnly',(_0x21fbac,_0xd131c2,_0x45339b)=>_0x21fbac&&_0xd131c2&&!_0x45339b);},'onExecute':()=>_0x5e9d44(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x180168=this['editor'],_0x22a66f=_0x180168['locale'];this['_saveRevisionFormView']=new hs(_0x22a66f,_0x180168['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends ts{['changeId'];['_model'];constructor(_0x503977,_0x48aea7){super(_0x503977),this['_model']=_0x48aea7,this['changeId']=_0x48aea7['id'];const _0x1f48c6=this['bindTemplate'],_0x589f2c=R(_0x503977,_0x48aea7['data']['isSuggestion']?'Suggested\x20by':'add'==_0x48aea7['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x48aea7['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x1f48c6['to']('type',_0x35a622=>'ck-revision-change__'+_0x35a622)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x589f2c}]},{'text':'\x20'+_0x48aea7['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x1230b1(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x5a275b){super(),this['id']=_0x5a275b['id']||_0x1c3ee2(),this['author']=_0x5a275b['author'],this['type']=_0x5a275b['type'],this['data']=_0x5a275b['data']||{},this['rootName']=_0x5a275b['rootName'],this['set']('createdAt',_0x5a275b['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(_0x53feac,_0x1e163e){this['newRevisionId']=_0x53feac,this['oldRevisionId']=_0x1e163e,this['changes']=new _0x53bf0e();}['_setChanges'](_0x11b922){for(const _0x393854 of _0x11b922)this['changes']['add'](_0x393854);}}const Z={'c':_0x39be7f,'a':_0x2124c2,'e':_0x324ff6,'r':_0xb02490,'u':_0x264acd};class d extends _0x49e1b4{['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[_0x57add3,_0x6d7678,j];}constructor(_0x4aa1bd){super(_0x4aa1bd),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',(_0x2a8e3a,_0x5eb648,_0x200e81)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x415865=>{for(const _0x1f2a8a of this['editor']['editing']['view']['document']['roots'])_0x200e81?_0x415865['removeClass']('ck-editor__editable__overlay',_0x1f2a8a):_0x415865['addClass']('ck-editor__editable__overlay',_0x1f2a8a);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x104bbd=>null!==_0x104bbd),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5076af,_0x4a8518,_0x41cc8f)=>_0x5076af&&_0x41cc8f?_0x4a8518['changes']['getIndex'](_0x41cc8f):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x373da6,_0x2be278)=>_0x373da6?_0x2be278['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x6d7678);}['init'](){const _0x48ffdb=this['editor'],_0x3b1a0a=new yt(_0x48ffdb,{'direction':'backward'}),_0xbc5ff4=new yt(_0x48ffdb,{'direction':'forward'});(_0x48ffdb['commands']['add']('showPreviousChange',_0x3b1a0a),_0x48ffdb['commands']['add']('showNextChange',_0xbc5ff4),_0x48ffdb['commands']['add']('restoreRevision',new _t(_0x48ffdb)),this['on']('change:numberOfChanges',()=>{_0x3b1a0a['refresh'](),_0xbc5ff4['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x48ffdb['enableReadOnlyMode']('revision-viewer'),_0x48ffdb['plugins']['has']('WidgetToolbarRepository'))&&_0x48ffdb['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x389a31){await this['loadRevisionData'](_0x389a31);const _0x4698b8={};for(const _0x2aa885 in _0x389a31['diffData']){if(_0x389a31['diffData'][_0x2aa885]['attachChange']&&!_0x389a31['diffData'][_0x2aa885]['attachChange']['isAttached'])continue;const _0x2786af=this['_removeRevisionMarkers'](JSON['parse'](_0x389a31['diffData'][_0x2aa885]['insertions'])),_0x2f97f7=this['editor']['editing']['view']['document'],_0x4b373b=new _0x22eced(_0x2f97f7,_0x2786af['map'](_0x1a89d1=>this['_getViewObj'](_0x1a89d1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4698b8[_0x2aa885]=this['editor']['data']['processor']['toData'](_0x4b373b),this['editor']['data']['processor']['useFillerType']('default');}return _0x4698b8;}async['getRevisionRootsAttributes'](_0x337987){await this['loadRevisionData'](_0x337987);const _0x5614c4={};for(const _0x3ed910 in _0x337987['diffData'])_0x337987['diffData'][_0x3ed910]['attachChange']&&!_0x337987['diffData'][_0x3ed910]['attachChange']['isAttached']||(_0x5614c4[_0x3ed910]=_0x337987['diffData'][_0x3ed910]['attributesAfter']||{});return _0x5614c4;}['_removeRevisionMarkers'](_0x5b3b7a){return(_0x5b3b7a=_0x5b3b7a['filter'](_0x198807=>!_0x198807['name']||'revision-start'!==_0x198807['name']&&'revision-end'!==_0x198807['name']))['forEach'](_0xf3ab76=>{'string'!=typeof _0xf3ab76&&(_0xf3ab76['children']=this['_removeRevisionMarkers'](_0xf3ab76['children']),_0xf3ab76['attributes']=_0xf3ab76['attributes']['filter'](_0x378434=>!_0x378434[0x0]['startsWith']('data-revision-')));}),_0x5b3b7a;}async['compare'](_0x4a222b,_0x483d68,_0x1d7a59=!0x1){if(!this['isEnabled'])return;const _0xa6ce6d=this['diff'],_0x4825b9=this['repository'],_0x456f89='string'==typeof _0x4a222b?_0x4825b9['getRevision'](_0x4a222b):_0x4a222b,_0x596b92='string'==typeof _0x483d68?_0x4825b9['getRevision'](_0x483d68):_0x483d68,_0x4104b0=_0x456f89['id'],_0x473bb4=_0x596b92?_0x596b92['id']:null;if(!_0x1d7a59&&this['diff']&&this['diff']['newRevisionId']===_0x4104b0&&this['diff']['oldRevisionId']===_0x473bb4)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x4104b0,_0x473bb4);const _0x49ed0e=this['_getRevisionsRange'](_0x456f89,_0x596b92,!0x0)['map'](_0x2c76f4=>this['loadRevisionData'](_0x2c76f4));return _0x49ed0e['push'](new Promise(_0x20f47f=>{setTimeout(_0x20f47f,0x14);})),Promise['all'](_0x49ed0e)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x17966e=this['_getDiff'](_0x4104b0,_0x473bb4);for(const _0x68861f of _0x17966e['changes'])this['_changeIdToChange']['set'](_0x68861f['id'],_0x68861f);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2781fb=>{for(const _0x447a7b of this['editor']['model']['document']['getRootNames']())_0x2781fb['detachRoot'](_0x447a7b);for(const _0x139986 of Object['keys'](_0x17966e['model'])){const _0x205ff9=_0x2781fb['addRoot'](_0x139986);for(const _0x4b5321 of Object['keys'](_0x17966e['attributes'][_0x139986]))_0x2781fb['setAttribute'](_0x4b5321,_0x17966e['attributes'][_0x139986][_0x4b5321],_0x205ff9);_0x2781fb['insert'](_0x17966e['model'][_0x139986],_0x205ff9,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x17966e['changes'])),this['isReady']=!0x0;})['catch'](_0x4dbfb7=>{console['error'](_0x4dbfb7),this['_cleanUp'](),_0xa6ce6d&&(this['diff']=_0xa6ce6d),this['isReady']=!0x0;});}['addRevisionData'](_0x7a1adf,_0x51a1d2){const _0x45c210=this['repository']['createRevision'](_0x7a1adf);return _0x45c210['on']('_update',(_0x42a94d,_0x23c6f8,_0x134c72)=>_0x51a1d2(_0x23c6f8,_0x134c72,_0x45c210)),this['repository']['addRevision'](_0x45c210),_0x45c210;}['loadRevisionData'](_0xbe7827){if(!_0xbe7827||_0xbe7827['diffData'])return Promise['resolve']();{const _0x461786=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x461786,'revisionId':_0xbe7827['id']})['then'](_0x1b843e=>{_0xbe7827['_update']({'diffData':_0x1b843e['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},_0x2c71a4=>{for(const _0x4e0553 of this['editor']['model']['document']['getRootNames']())_0x2c71a4['detachRoot'](_0x4e0553);});}['_sortAndFilterDiffChanges'](_0x16bb7c){const _0x3f1285=[],_0xe583ee=new Map();for(const _0x15f2c4 of this['editor']['model']['document']['getRootNames']()){const _0x110b2b=this['editor']['editing']['view']['getDomRoot'](_0x15f2c4);if(!_0x110b2b)continue;const _0xccd940=_0x110b2b['getClientRects']()['item'](0x0);_0xccd940&&(_0x3f1285['push'](_0x15f2c4),_0xe583ee['set'](_0x15f2c4,_0xccd940));}return _0x3f1285['sort']((_0x35c957,_0xf27275)=>{const _0x7debb4=_0xe583ee['get'](_0x35c957),_0x1611ec=_0xe583ee['get'](_0xf27275);return _0x7debb4['y']-_0x1611ec['y']||_0x7debb4['x']-_0x1611ec['x'];}),(_0x16bb7c=_0x16bb7c['filter'](_0x3331fb=>_0x3f1285['includes'](_0x3331fb['rootName'])))['sort']((_0x210a49,_0x73d3de)=>_0x3f1285['indexOf'](_0x210a49['rootName'])-_0x3f1285['indexOf'](_0x73d3de['rootName'])),_0x16bb7c;}['_makeTape'](_0x128457){const _0x5e56a5=Array['from'](_0x128457['markers'])['filter'](([_0x46a4e6,_0x44ef38])=>_0x46a4e6['startsWith']('revision:')&&!_0x44ef38['isCollapsed']),_0x2e6528=Array['from'](this['editor']['model']['createRangeIn'](_0x128457)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5e56a5['length'])for(const _0x1c9ed0 of _0x2e6528){const [_0x2a1164,_0x23eec0]=_0x5e56a5[0x0],[,_0x14c78a,_0x5b2ee3]=_0x2a1164['split'](':');if(_0x23eec0['end']['isEqual'](_0x1c9ed0['nextPosition'])&&_0x5e56a5['shift'](),(_0x1c9ed0['previousPosition']['isEqual'](_0x23eec0['start'])||_0x1c9ed0['previousPosition']['isAfter'](_0x23eec0['start']))&&('insertion'==_0x14c78a?_0x1c9ed0['isAdded']={'userId':_0x5b2ee3}:'deletion'==_0x14c78a&&(_0x1c9ed0['isRemoved']={'userId':_0x5b2ee3})),0x0==_0x5e56a5['length'])break;}return _0x2e6528;}['_refreshStartEndIndex'](_0x316493){const _0x31ab91=new Map();for(let _0x381eaf=0x0;_0x381eaf<_0x316493['length'];_0x381eaf++)'text'===_0x316493[_0x381eaf]['type']?(_0x316493[_0x381eaf]['item']['startIndex']=_0x381eaf,_0x316493[_0x381eaf]['item']['endIndex']=_0x381eaf):('elementStart'===_0x316493[_0x381eaf]['type']?_0x316493[_0x381eaf]['item']['startIndex']=_0x381eaf:'elementEnd'===_0x316493[_0x381eaf]['type']&&(_0x316493[_0x381eaf]['item']['endIndex']=_0x381eaf),_0x31ab91['set'](_0x316493[_0x381eaf]['id'],_0x381eaf));for(const _0x3c920f of _0x31ab91['values']())'elementStart'===_0x316493[_0x3c920f]['type']?_0x316493[_0x3c920f]['item']['endIndex']=_0x31ab91['get'](_0x316493[_0x3c920f]['pairId']):'elementEnd'===_0x316493[_0x3c920f]['type']&&(_0x316493[_0x3c920f]['item']['startIndex']=_0x31ab91['get'](_0x316493[_0x3c920f]['pairId']));}['_processTape'](_0x46b49b){for(let _0x348089=0x0;_0x348089<_0x46b49b['length'];_0x348089++){if('elementStart'===_0x46b49b[_0x348089]['type'])_0x46b49b[_0x348089]['item']['startIndex']=_0x348089;else{if('elementEnd'===_0x46b49b[_0x348089]['type']){_0x46b49b[_0x348089]['item']['endIndex']=_0x348089;const _0x14f60d=_0x46b49b[_0x348089]['item']['startIndex'];_0x46b49b[_0x14f60d]['pairId']=_0x46b49b[_0x348089]['id'],_0x46b49b[_0x348089]['pairId']=_0x46b49b[_0x14f60d]['id'];}else _0x46b49b[_0x348089]['item']['startIndex']=_0x348089,_0x46b49b[_0x348089]['item']['endIndex']=_0x348089,_0x46b49b[_0x348089]['pairId']=null;}_0x46b49b[_0x348089]['markersStart']||(_0x46b49b[_0x348089]['markersStart']=[],_0x46b49b[_0x348089]['markersEnd']=[]);}}['_markInsertions'](_0x5c2313,_0x54dce8){const _0x3dd1c3=_0x5c2313['filter'](_0x2b3477=>!_0x2b3477['isAdded']);for(let _0x49a92d=0x0;_0x49a92d<_0x54dce8['length'];_0x49a92d++)_0x54dce8[_0x49a92d]['isAdded']&&(_0x3dd1c3[_0x49a92d]['isAdded']=_0x54dce8[_0x49a92d]['isAdded']);}['_makeModelFromViewString'](_0x47ead3){const _0x5aa70c=JSON['parse'](_0x47ead3),_0x414756=this['editor']['editing']['view']['document'],_0x5bd5fa=new _0x22eced(_0x414756,_0x5aa70c['map'](_0x9f8414=>this['_getViewObj'](_0x9f8414)));return this['editor']['data']['toModel'](_0x5bd5fa);}['_getViewObj'](_0x2d759f){const _0x5b56d3=this['editor']['editing']['view']['document'];if('string'==typeof _0x2d759f)return new _0x253de4(_0x5b56d3,_0x2d759f);{const _0x11e99f=_0x2d759f['children']['map'](_0x5bc32f=>this['_getViewObj'](_0x5bc32f));return new(Z[_0x2d759f['type']]||_0x4085ba)(_0x5b56d3,_0x2d759f['name'],_0x2d759f['attributes'],_0x11e99f);}}['_getDiff'](_0x3a95ff,_0x26702c=null){const _0x221fe6=this['repository']['getRevision'](_0x3a95ff),_0x352429=_0x26702c?this['repository']['getRevision'](_0x26702c):null,_0x1fce62=this['_getRevisionsRange'](_0x221fe6,_0x352429),_0x534377=_0x1fce62[_0x1fce62['length']-0x1],_0x25a83d=new Map(),_0x2d9814={'model':{},'attributes':{},'changes':[]},_0x244913=new Set(),_0x31e8cd=new Map();for(let _0x169534=_0x1fce62['length']-0x1;_0x169534>=0x0;_0x169534--){const _0x4918cf=_0x1fce62[_0x169534];for(const _0x939cc7 of Object['keys'](_0x4918cf['diffData']))if(_0x4918cf['diffData'][_0x939cc7]['attachChange']){const _0x3bb781=_0x4918cf['diffData'][_0x939cc7]['attachChange'];_0x3bb781['isAttached']?(_0x244913['add'](_0x939cc7),_0x31e8cd['has'](_0x939cc7)&&_0x31e8cd['get'](_0x939cc7)['userId']==_0x3bb781['userId']?_0x31e8cd['delete'](_0x939cc7):_0x31e8cd['set'](_0x939cc7,_0x3bb781)):_0x31e8cd['has'](_0x939cc7)?(_0x244913['delete'](_0x939cc7),_0x31e8cd['delete'](_0x939cc7)):(_0x244913['add'](_0x939cc7),_0x31e8cd['set'](_0x939cc7,_0x3bb781));}else _0x244913['add'](_0x939cc7);}for(const _0x55dc02 of _0x244913){const _0x3b68aa=_0x31e8cd['has'](_0x55dc02)&&!_0x31e8cd['get'](_0x55dc02)['isAttached'];let _0x42db99=_0x3b68aa?_0x1fce62['length']-0x1:0x0;const _0x2ed7d3=_0x3b68aa?-0x1:0x1;for(;_0x1fce62[_0x42db99];){const _0x3ad192=_0x1fce62[_0x42db99];if(_0x3ad192['diffData'][_0x55dc02]){const _0x51993e=_0x3b68aa?_0x3ad192['diffData'][_0x55dc02]['attributesBefore']:_0x3ad192['diffData'][_0x55dc02]['attributesAfter'];_0x2d9814['attributes'][_0x55dc02]=_0x51993e?_0x5f0f2b(_0x51993e):{};break;}_0x42db99+=_0x2ed7d3;}}for(const _0x2867e2 of _0x1fce62){_0x2867e2['model']={};for(const _0x1be6d8 of _0x2867e2['authors'])_0x25a83d['set'](_0x1be6d8['id'],_0x1be6d8);for(const _0x1896e9 of _0x244913){const _0x2ca5bd=_0x2867e2['diffData'][_0x1896e9]?_0x2867e2['diffData'][_0x1896e9]['insertions']:'[]',_0x2494f9=_0x2867e2['diffData'][_0x1896e9]?_0x2867e2['diffData'][_0x1896e9]['deletions']:'[]';_0x2867e2['model'][_0x1896e9]={'insertions':this['_makeModelFromViewString'](_0x2ca5bd),'deletions':this['_makeModelFromViewString'](_0x2494f9)};}}for(const _0x22d1bb of _0x244913){let _0xe4e812=null,_0x267172=0x0;const _0x4fc188=new Map(Array['from'](_0x221fe6['model'][_0x22d1bb]['insertions']['markers'])['filter'](([_0x37e5db])=>!_0x37e5db['startsWith']('revision:')));let _0x407ffb=0x0;for(const _0x49bd96 of _0x1fce62){const _0x404c74=this['_makeTape'](_0x49bd96['model'][_0x22d1bb]['insertions']);_0x49bd96==_0x221fe6?(_0xe4e812=_0x404c74,_0x267172=_0xe4e812['length'],_0xe4e812['forEach'](_0xcbc41d=>{_0xcbc41d['id']=_0x407ffb++;}),this['_processTape'](_0xe4e812)):this['_markInsertions'](_0xe4e812,_0x404c74);const _0x29048e=_0xe4e812['filter'](_0x13acc9=>!_0x13acc9['isAdded'])['map'](_0x72aaa2=>_0x72aaa2['id']);let _0x3ceb25=0x0;const _0x3001d1=this['_makeTape'](_0x49bd96['model'][_0x22d1bb]['deletions']);_0x3001d1['forEach'](_0x3149a6=>{_0x3149a6['isRemoved']?_0x3149a6['id']=_0x267172++:_0x3149a6['id']=_0x29048e[_0x3ceb25++];}),this['_processTape'](_0x3001d1),this['_setDistance'](_0xe4e812,'isAdded'),this['_setDistance'](_0x3001d1,'isRemoved'),_0x49bd96==_0x221fe6&&this['_markMarkers'](_0xe4e812,_0x4fc188),_0xe4e812=this['_joinTapes'](_0xe4e812,_0x3001d1),this['_refreshStartEndIndex'](_0xe4e812),this['_setDistance'](_0xe4e812,'isRemoved');}_0xe4e812=_0xe4e812['filter'](_0x316bd2=>!(_0x316bd2['isAdded']&&_0x316bd2['isRemoved']));const _0x5b6ba8=new Map(_0x534377['model'][_0x22d1bb]['deletions']['markers']),_0x587d12=new Set(_0x4fc188['keys']());for(const _0xae0cb2 of _0x5b6ba8['keys']())_0x587d12['delete'](_0xae0cb2);this['_markSuggestions'](_0xe4e812,_0x587d12),this['_fixObsoleteTags'](_0xe4e812),_0xe4e812=this['_removeMissingPairs'](_0xe4e812),_0xe4e812=this['_markMismatchedRemovedTags'](_0xe4e812),_0xe4e812=this['_removeUnsupportedChanges'](_0xe4e812);const {root:_0x36ba02,changes:_0x1d7bb6}=this['_makeModelFromTape'](_0xe4e812,_0x25a83d,_0x22d1bb);_0x2d9814['model'][_0x22d1bb]=_0x36ba02;const _0x3f88b3=_0x31e8cd['get'](_0x22d1bb);if(_0x3f88b3){const _0x1c7e85=_0x25a83d['get'](_0x3f88b3['userId']),_0x512954=new r({'author':_0x1c7e85,'type':_0x3f88b3['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x22d1bb});_0x1d7bb6['unshift'](_0x512954),_0x2d9814['attributes'][_0x22d1bb]['revisionHistoryAttachChange']=_0x512954['id'];}_0x2d9814['changes']=_0x2d9814['changes']['concat'](_0x1d7bb6);}return _0x2d9814;}['_markMarkers'](_0x1cf43b,_0x48442b){for(let _0x4211e3=0x0;_0x4211e3<_0x1cf43b['length'];_0x4211e3++)for(const [_0x3271d0,_0x16e703]of _0x48442b)_0x16e703['start']['isEqual'](_0x1cf43b[_0x4211e3]['previousPosition'])&&_0x1cf43b[_0x4211e3]['markersStart']['push'](_0x3271d0),_0x16e703['end']['isEqual'](_0x1cf43b[_0x4211e3]['nextPosition'])&&_0x1cf43b[_0x4211e3]['markersEnd']['push'](_0x3271d0);}['_joinTapes'](_0x1bedef,_0x4b9150){let _0x24ec20=[],_0x47c754=0x0,_0x5b33f2=0x0;for(;_0x47c754<_0x1bedef['length']||_0x5b33f2<_0x4b9150['length'];){const _0x3381ab=_0x1bedef[_0x47c754]||{},_0x1742bb=_0x4b9150[_0x5b33f2]||{};if(_0x3381ab['id']==_0x1742bb['id'])_0x47c754++,_0x5b33f2++,_0x24ec20['push'](_0x3381ab);else{if(_0x1742bb['isRemoved']&&_0x3381ab['isAdded']){const {commonTape:_0x62d6f6,iEnd:_0x48f858,jEnd:_0x2b9119}=this['_threeWayMerge'](_0x1bedef,_0x47c754,_0x4b9150,_0x5b33f2);_0x24ec20=_0x24ec20['concat'](_0x62d6f6),_0x47c754=_0x48f858,_0x5b33f2=_0x2b9119;}else _0x1742bb['isRemoved']?(_0x5b33f2++,_0x24ec20['push'](_0x1742bb)):(_0x47c754++,_0x24ec20['push'](_0x3381ab));}}return _0x24ec20;}['_markSuggestions'](_0x2104d3,_0x1895bc){const _0x5c9eef=[];for(let _0x4af1a8=0x0;_0x4af1a8<_0x2104d3['length'];_0x4af1a8++){for(let _0x29d06e=0x0;_0x29d06e<_0x2104d3[_0x4af1a8]['markersStart']['length'];_0x29d06e++){const _0x52d25d=_0x2104d3[_0x4af1a8]['markersStart'][_0x29d06e];if(!_0x1895bc['has'](_0x52d25d))continue;const {group:_0x18a026,type:_0x4a7d78,authorId:_0x5d076b}=_0x1e869e(_0x52d25d);'revision-suggestion'!=_0x18a026||'insertion'!=_0x4a7d78&&'deletion'!=_0x4a7d78||(_0x5c9eef['unshift']({'type':_0x4a7d78,'name':_0x52d25d,'userId':_0x5d076b}),_0x2104d3[_0x4af1a8]['markersStart']['splice'](_0x29d06e,0x1),_0x29d06e--);}_0x416d2b(_0x2104d3[_0x4af1a8]);for(let _0x347c06=0x0;_0x347c06<_0x2104d3[_0x4af1a8]['markersEnd']['length'];_0x347c06++){const _0x4f966=_0x2104d3[_0x4af1a8]['markersEnd'][_0x347c06];if(!_0x1895bc['has'](_0x4f966))continue;const {group:_0x41b8c0,type:_0x3b31ea}=_0x1e869e(_0x4f966);if('revision-suggestion'!=_0x41b8c0||'insertion'!=_0x3b31ea&&'deletion'!=_0x3b31ea)continue;_0x2104d3[_0x4af1a8]['markersEnd']['splice'](_0x347c06,0x1),_0x347c06--;const _0x1075f3=_0x5c9eef['findIndex'](_0x4a73d0=>_0x4a73d0['name']==_0x4f966);_0x1075f3>-0x1&&_0x5c9eef['splice'](_0x1075f3,0x1);}}function _0x1e869e(_0x58e8f0){const _0x1ea7d0=_0x58e8f0['split'](':');return{'group':_0x1ea7d0[0x0],'type':_0x1ea7d0[0x1],'subType':_0x1ea7d0['length']>=0x5?_0x1ea7d0[0x2]:null,'id':_0x1ea7d0['length']<0x5?_0x1ea7d0[0x2]:_0x1ea7d0[0x3],'authorId':_0x1ea7d0['length']<0x5?_0x1ea7d0[0x3]:_0x1ea7d0[0x4],'markerCount':0x6==_0x1ea7d0['length']?_0x1ea7d0[0x5]:null};}function _0x416d2b(_0x794bda){for(let _0xb4169=0x0;_0xb4169<_0x5c9eef['length'];_0xb4169++){if(_0x794bda['isAdded']&&'insertion'==_0x5c9eef[_0xb4169]['type'])return _0x794bda['isAddSuggestion']=_0x5c9eef[_0xb4169],void delete _0x794bda['isAdded'];if(!_0x794bda['isAdded']&&!_0x794bda['isRemoved']&&'deletion'==_0x5c9eef[_0xb4169]['type'])return void(_0x794bda['isRemoveSuggestion']=_0x5c9eef[_0xb4169]);}}}['_setDistance'](_0xb1c4f8,_0x49db37){let _0x16a46f=0x0,_0x505d21=!0x1;const _0x323a9b=new Map();for(const _0x110e17 of _0xb1c4f8)_0x110e17[_0x49db37]?_0x505d21&&(_0x16a46f++,_0x505d21=!0x1):(_0x16a46f++,_0x505d21=!0x0),_0x323a9b['set'](_0x110e17['id'],_0x16a46f);for(let _0x20180d=0x0;_0x20180d<_0xb1c4f8['length'];_0x20180d++){if('isRemoved'==_0x49db37&&_0xb1c4f8[_0x20180d]['isAdded']||'isAdded'==_0x49db37&&_0xb1c4f8[_0x20180d]['isRemoved'])continue;if('text'==_0xb1c4f8[_0x20180d]['type']){_0xb1c4f8[_0x20180d]['distance']=0x0;continue;}const _0xd1c52f=_0x323a9b['get'](_0xb1c4f8[_0x20180d]['pairId']),_0x17cf4c=_0x323a9b['get'](_0xb1c4f8[_0x20180d]['id']);_0xb1c4f8[_0x20180d]['distance']=_0xd1c52f-_0x17cf4c;}}['_getRevisionsRange'](_0xb3c634,_0x33a46c,_0x3a058f=!0x1){const _0x15808c=[];let _0x3ba12e=this['repository']['getIndex'](_0xb3c634),_0x3f8d0d=this['repository']['getIndex'](_0x33a46c);for(-0x1==_0x3f8d0d&&(_0x3f8d0d=this['repository']['_revisions']['length'],_0x3a058f=!0x1);_0x3ba12e<_0x3f8d0d;)_0x15808c['push'](this['repository']['getRevision'](_0x3ba12e)),_0x3ba12e++;return _0x3a058f&&_0x15808c['push'](this['repository']['getRevision'](_0x3ba12e)),_0x15808c;}['_threeWayMerge'](_0x96c8a5,_0x33baa1,_0x91cf6,_0x54d7f3){const _0x192e5b=this['editor']['model']['schema'];let _0x434b1b=_0x33baa1;for(;_0x96c8a5[_0x434b1b]&&_0x96c8a5[_0x434b1b]['isAdded'];)_0x434b1b++;let _0x30baf0=_0x54d7f3;for(;_0x91cf6[_0x30baf0]&&_0x91cf6[_0x30baf0]['isRemoved'];)_0x30baf0++;_0x318874(_0x96c8a5,_0x33baa1,_0x434b1b),_0x318874(_0x91cf6,_0x54d7f3,_0x30baf0);const _0x3bc04e=_0x91cf6['slice'](_0x54d7f3,_0x30baf0)['concat'](_0x96c8a5['slice'](_0x33baa1,_0x434b1b));return _0x3bc04e['sort']((_0x2e9328,_0x1e3a1b)=>_0x2e9328['side']!=_0x1e3a1b['side']?_0x2e9328['side']-_0x1e3a1b['side']:_0x2e9328['level']!=_0x1e3a1b['level']?_0x2e9328['level']-_0x1e3a1b['level']:_0x2e9328['distance']!=_0x1e3a1b['distance']?_0x1e3a1b['distance']-_0x2e9328['distance']:!!_0x2e9328['isAdded']!=!!_0x1e3a1b['isAdded']?-0x1==_0x2e9328['side']||0x0==_0x2e9328['side']?_0x2e9328['isAdded']?-0x1:0x1:_0x2e9328['isAdded']?0x1:-0x1:_0x2e9328['index']-_0x1e3a1b['index']),{'commonTape':_0x3bc04e,'iEnd':_0x434b1b,'jEnd':_0x30baf0};function _0x318874(_0x547fca,_0x19d158,_0x8df8d1){let _0x1941cf=-0x1,_0x2f6d86=Number['POSITIVE_INFINITY'],_0x56c1fb=!0x0;for(let _0xec684a=_0x19d158;_0xec684a<_0x8df8d1;_0xec684a++)if(_0x192e5b['isInline'](_0x547fca[_0xec684a]['item'])||(_0x56c1fb=!0x1),_0x547fca[_0xec684a]['item']['startIndex']<_0x19d158&&(_0x1941cf=_0xec684a),_0x547fca[_0xec684a]['item']['endIndex']>=_0x8df8d1){_0x2f6d86=_0xec684a;break;}_0x56c1fb&&(_0x1941cf=_0x8df8d1-0x1);for(let _0x5d275e=_0x19d158;_0x5d275e<_0x8df8d1;_0x5d275e++)_0x547fca[_0x5d275e]['side']=_0x5d275e<=_0x1941cf?-0x1:_0x5d275e<_0x2f6d86?0x0:0x1,_0x547fca[_0x5d275e]['index']=_0x5d275e;let _0x8f2625=0x0;for(let _0x4efa25=_0x19d158;_0x4efa25<=_0x1941cf;_0x4efa25++)0x0==_0x547fca[_0x4efa25]['distance']?_0x547fca[_0x4efa25]['level']=_0x8f2625:(_0x8f2625++,_0x547fca[_0x4efa25]['level']=_0x8f2625,_0x8f2625++);for(let _0x7eba7a=_0x19d158;_0x7eba7a<_0x8df8d1;_0x7eba7a++)0x0==_0x547fca[_0x7eba7a]['side']&&(_0x547fca[_0x7eba7a]['level']=_0x8f2625);_0x8f2625=0x0;for(let _0x32a525=_0x8df8d1-0x1;_0x32a525>=_0x2f6d86;_0x32a525--)0x0==_0x547fca[_0x32a525]['distance']?_0x547fca[_0x32a525]['level']=_0x8f2625:(_0x8f2625--,_0x547fca[_0x32a525]['level']=_0x8f2625,_0x8f2625--);}}['_fixObsoleteTags'](_0x3c8220){const _0x49990a=new Map(),_0x27d823=this['editor']['model']['schema'];for(let _0x2ecbfe=0x1;_0x2ecbfe<_0x3c8220['length'];_0x2ecbfe++){let _0x5226aa,_0x2f0982,_0x1cf779;const _0xc13a7a=_0x3c8220[_0x2ecbfe],_0x1e030d=_0x3c8220[_0x2ecbfe-0x1];if('text'==_0xc13a7a['type'])continue;if(_0xc13a7a['type']!=_0x1e030d['type'])continue;if(!_0x27d823['isBlock'](_0x1e030d['item'])||_0x27d823['isLimit'](_0x1e030d['item']))continue;if(!_0x27d823['isBlock'](_0xc13a7a['item'])||_0x27d823['isLimit'](_0xc13a7a['item']))continue;if((_0x3c8220[_0x2ecbfe]['isAdded']||_0x3c8220[_0x2ecbfe]['isAddSuggestion'])&&_0x3c8220[_0x2ecbfe-0x1]['isRemoved'])_0x5226aa=_0x3c8220[_0x2ecbfe],_0x2f0982=_0x3c8220[_0x2ecbfe-0x1],_0x1cf779=_0x2ecbfe-0x1;else{if(!_0x3c8220[_0x2ecbfe]['isRemoved']||!_0x3c8220[_0x2ecbfe-0x1]['isAdded']&&!_0x3c8220[_0x2ecbfe-0x1]['isAddSuggestion'])continue;_0x5226aa=_0x3c8220[_0x2ecbfe-0x1],_0x2f0982=_0x3c8220[_0x2ecbfe],_0x1cf779=_0x2ecbfe;}const _0x517068=_0x5226aa['level']==_0x2f0982['level'],_0x4e2085=Math['abs'](_0x5226aa['level'])<Math['abs'](_0x2f0982['level'])&&0x0==_0x2f0982['distance'];(_0x517068||_0x4e2085)&&(_0x49990a['set'](_0x2f0982['id'],_0x5226aa['id']),_0x3c8220['splice'](_0x1cf779,0x1),_0x2ecbfe--,_0x5226aa['isAdded']=!0x1);}for(let _0x200ce1=0x0;_0x200ce1<_0x3c8220['length'];_0x200ce1++)_0x49990a['has'](_0x3c8220[_0x200ce1]['pairId'])&&(_0x3c8220[_0x200ce1]['pairId']=_0x49990a['get'](_0x3c8220[_0x200ce1]['pairId']));}['_removeMissingPairs'](_0x42514e){const _0x46f258=new Set(_0x42514e['map'](_0x544ba4=>_0x544ba4['id']));for(let _0x465216=0x0;_0x465216<_0x42514e['length'];_0x465216++)_0x46f258['has'](_0x42514e[_0x465216]['pairId'])||0x0==_0x42514e[_0x465216]['distance']||(_0x42514e[_0x465216]['isIncorrect']=!0x0);return _0x42514e['filter'](_0x45a539=>!_0x45a539['isIncorrect']);}['_markMismatchedRemovedTags'](_0xc9bbc1){const _0x2b3ecd=new Set();for(let _0x22894f=0x0;_0x22894f<_0xc9bbc1['length'];_0x22894f++){if(_0x2b3ecd['has'](_0xc9bbc1[_0x22894f]['id'])&&_0xc9bbc1[_0x22894f]['isRemoved']&&(_0xc9bbc1[_0x22894f]['isIncorrect']=!0x0),_0xc9bbc1[_0x22894f]['isIncorrect'])continue;if(0x0==_0xc9bbc1[_0x22894f]['distance'])continue;if('elementStart'!=_0xc9bbc1[_0x22894f]['type'])continue;if(null==_0xc9bbc1[_0x22894f]['pairId'])continue;let _0x5f11b1=_0x22894f+0x1,_0x65b525=0x0;for(;_0xc9bbc1[_0x5f11b1]['id']!=_0xc9bbc1[_0x22894f]['pairId'];)'elementStart'==_0xc9bbc1[_0x5f11b1]['type']?_0x65b525++:'elementEnd'==_0xc9bbc1[_0x5f11b1]['type']&&_0x65b525--,_0x5f11b1++;if(0x0!=_0x65b525){if(_0xc9bbc1[_0x22894f]['isRemoved'])_0xc9bbc1[_0x22894f]['isIncorrect']=!0x0;else{for(;_0x5f11b1!=_0x22894f;)_0xc9bbc1[_0x5f11b1]['isRemoved']&&0x0!=_0xc9bbc1[_0x5f11b1]['distance']&&(_0xc9bbc1[_0x5f11b1]['isIncorrect']=!0x0,_0x2b3ecd['add'](_0xc9bbc1[_0x5f11b1]['pairId'])),_0x5f11b1--;}}}return _0xc9bbc1['filter'](_0x3b80a6=>!_0x3b80a6['isIncorrect']);}['_removeUnsupportedChanges'](_0x415c94){const _0x3dd507=this['editor']['model']['schema'];for(let _0x32355a=0x0;_0x32355a<_0x415c94['length'];_0x32355a++){if(!(_0x415c94[_0x32355a]['isAdded']||_0x415c94[_0x32355a]['isAddSuggestion']||_0x415c94[_0x32355a]['isRemoved']||_0x415c94[_0x32355a]['isRemoveSuggestion']))continue;if(0x0==_0x415c94[_0x32355a]['distance'])continue;const _0x44c7f4=_0x415c94[_0x32355a]['item'];_0x3dd507['isBlock'](_0x44c7f4)||_0x3dd507['isLimit'](_0x44c7f4)||(_0x415c94[_0x32355a]['isAdded']&&delete _0x415c94[_0x32355a]['isAdded'],_0x415c94[_0x32355a]['isAddSuggestion']&&delete _0x415c94[_0x32355a]['isAddSuggestion'],_0x415c94[_0x32355a]['isRemoveSuggestion']&&delete _0x415c94[_0x32355a]['isRemoveSuggestion'],_0x415c94[_0x32355a]['isRemoved']&&(_0x415c94[_0x32355a]['isIncorrect']=!0x0));}return _0x415c94['filter'](_0x212e06=>!_0x212e06['isIncorrect']);}['_makeModelFromTape'](_0x1e2829,_0x559e9e,_0x3bfc4f){const _0x58fc2c=new mt(),_0x35e397=[],_0x1af043=new Map(),_0x17eb5=this['editor']['model'],_0x3d6b34=_0x17eb5['schema'],_0x4bc169=[_0x58fc2c],_0x158225={},_0x14d53a={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x247a3c=null;const _0x528391=[0x0];for(let _0x211d6a=0x0;_0x211d6a<_0x1e2829['length'];_0x211d6a++)if('elementStart'===_0x1e2829[_0x211d6a]['type']){_0x1e2829[_0x211d6a]['previousPosition']=_0x17eb5['createPositionFromPath'](_0x58fc2c,_0x528391);const _0x2fee34=new ft(_0x1e2829[_0x211d6a]['item']['name'],_0x1e2829[_0x211d6a]['item']['getAttributes']());_0x4bc169[0x0]['_appendChild'](_0x2fee34),_0x528391['push'](0x0),_0x4bc169['unshift'](_0x2fee34),_0x1e2829[_0x211d6a]['nextPosition']=_0x17eb5['createPositionFromPath'](_0x58fc2c,_0x528391);}else'elementEnd'===_0x1e2829[_0x211d6a]['type']?(_0x4bc169['shift'](),_0x1e2829[_0x211d6a]['previousPosition']=_0x17eb5['createPositionFromPath'](_0x58fc2c,_0x528391),_0x528391['pop'](),_0x528391[_0x528391['length']-0x1]++,_0x1e2829[_0x211d6a]['nextPosition']=_0x17eb5['createPositionFromPath'](_0x58fc2c,_0x528391)):(_0x1e2829[_0x211d6a]['previousPosition']=_0x17eb5['createPositionFromPath'](_0x58fc2c,_0x528391),_0x247a3c?_0x247a3c['_data']+=_0x1e2829[_0x211d6a]['item']['data']:_0x247a3c=new wt(_0x1e2829[_0x211d6a]['item']['data'],_0x1e2829[_0x211d6a]['item']['getAttributes']()),_0x1e2829[_0x211d6a+0x1]&&'text'===_0x1e2829[_0x211d6a+0x1]['type']&&_0x427f05(_0x247a3c,_0x1e2829[_0x211d6a+0x1]['item'])||(_0x4bc169[0x0]['_appendChild'](_0x247a3c),_0x247a3c=null),_0x528391[_0x528391['length']-0x1]+=_0x1e2829[_0x211d6a]['item']['offsetSize'],_0x1e2829[_0x211d6a]['nextPosition']=_0x17eb5['createPositionFromPath'](_0x58fc2c,_0x528391));for(let _0x58a84f=0x0;_0x58a84f<_0x1e2829['length'];_0x58a84f++){const _0x5b0e8d=_0x1e2829[_0x58a84f]['previousPosition'],_0x54455e=_0x1e2829[_0x58a84f]['nextPosition'];for(const _0x17c1df of _0x1e2829[_0x58a84f]['markersStart'])_0x1af043['set'](_0x17c1df,{'start':_0x5b0e8d,'end':null});_0x35a5c2('isRemoveSuggestion',_0x58a84f,_0x5b0e8d,_0x54455e),_0x35a5c2('isAddSuggestion',_0x58a84f,_0x5b0e8d,_0x54455e),_0x35a5c2('isRemoved',_0x58a84f,_0x5b0e8d,_0x54455e),_0x35a5c2('isAdded',_0x58a84f,_0x5b0e8d,_0x54455e);for(const _0x2ca3d9 of _0x1e2829[_0x58a84f]['markersEnd']){_0x1af043['get'](_0x2ca3d9)['end']=_0x54455e;}}for(const [_0x174e9a,_0x411f0e]of _0x1af043){const _0x2c21f3=this['editor']['model']['createRange'](_0x411f0e['start'],_0x411f0e['end']);_0x58fc2c['markers']['set'](_0x174e9a,_0x2c21f3);}return _0x35e397['sort']((_0x2c443c,_0x14f95a)=>{const _0x5bd4fa=_0x58fc2c['markers']['get']('revision:'+_0x2c443c['id']),_0x5051f6=_0x58fc2c['markers']['get']('revision:'+_0x14f95a['id']);return _0x5bd4fa['start']['isBefore'](_0x5051f6['start'])?-0x1:_0x5bd4fa['start']['isAfter'](_0x5051f6['start'])?0x1:_0x5bd4fa['end']['isBefore'](_0x5051f6['end'])?-0x1:_0x5bd4fa['end']['isAfter'](_0x5051f6['end'])?0x1:'add'===_0x2c443c['type']?-0x1:0x1;}),{'root':_0x58fc2c,'changes':_0x35e397};function _0x35a5c2(_0x1ad04f,_0x392e2d,_0x2811a6,_0x3aaf75){const _0x498ccd=!!_0x1e2829[_0x392e2d][_0x1ad04f],_0x3b4080=_0x498ccd?_0x1e2829[_0x392e2d][_0x1ad04f]['userId']:null,_0x5116f9=_0x392e2d===_0x1e2829['length']-0x1,_0x2b5a5e=_0x14d53a[_0x1ad04f][0x0],_0x202108=_0x3d6b34['isObject'](_0x1e2829[_0x392e2d]['item']);!_0x158225[_0x1ad04f]&&_0x498ccd?_0x158225[_0x1ad04f]={'start':_0x2811a6,'tapeItem':_0x1e2829[_0x392e2d],'userId':_0x3b4080,'type':_0x1ad04f}:_0x158225[_0x1ad04f]&&!_0x498ccd?(_0x158225[_0x1ad04f]['end']=_0x2811a6,_0x2fd491(_0x158225[_0x1ad04f]),_0x158225[_0x1ad04f]=null):_0x158225[_0x1ad04f]&&_0x498ccd&&_0x158225[_0x1ad04f]['userId']!==_0x3b4080&&(_0x158225[_0x1ad04f]['end']=_0x2811a6,_0x2b5a5e&&_0x2b5a5e['userId']===_0x158225[_0x1ad04f]['userId']||_0x2fd491(_0x158225[_0x1ad04f]),_0x158225[_0x1ad04f]={'start':_0x2811a6,'tapeItem':_0x1e2829[_0x392e2d],'userId':_0x3b4080,'type':_0x1ad04f}),_0x158225[_0x1ad04f]&&_0x202108&&('elementStart'!==_0x1e2829[_0x392e2d]['type']||_0x2b5a5e&&_0x2b5a5e['userId']===_0x3b4080||_0x14d53a[_0x1ad04f]['unshift']({'userId':_0x3b4080,'object':_0x1e2829[_0x392e2d]['item'],'change':_0x158225[_0x1ad04f]}),'elementEnd'===_0x1e2829[_0x392e2d]['type']&&_0x2b5a5e&&_0x2b5a5e['object']===_0x1e2829[_0x392e2d]['item']&&(_0x14d53a[_0x1ad04f]['shift'](),_0x158225[_0x1ad04f]=_0x2b5a5e['change'])),_0x158225[_0x1ad04f]&&_0x5116f9&&(_0x158225[_0x1ad04f]['end']=_0x3aaf75,_0x2fd491(_0x158225[_0x1ad04f]),_0x158225[_0x1ad04f]=null);}function _0x2fd491({start:_0x3be29a,end:_0x5df60f,tapeItem:_0x37b800,userId:_0x13d7a2,type:_0x4a41d1}){const _0x367b47=_0x37b800['item'],_0x3b1a10=_0x17eb5['schema']['isBlock'](_0x367b47)&&!_0x17eb5['schema']['isLimit'](_0x367b47),_0x4aa1b5=_0x3be29a['nodeAfter']==_0x5df60f['parent']&&_0x5df60f['isAtStart'];if(_0x3b1a10&&_0x4aa1b5)return;const _0x5ea4e8=_0x17eb5['createRange'](_0x3be29a,_0x5df60f),_0x5e23af=_0x559e9e['get'](_0x13d7a2),_0x11813f=new r({'author':_0x5e23af,'type':'isAdded'==_0x4a41d1||'isAddSuggestion'==_0x4a41d1?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4a41d1||'isRemoveSuggestion'==_0x4a41d1},'createdAt':new Date(),'rootName':_0x3bfc4f});_0x35e397['push'](_0x11813f),_0x58fc2c['markers']['set']('revision:'+_0x11813f['id'],_0x5ea4e8);}function _0x427f05(_0x445a95,_0x2dfc35){const _0x519915=_0x445a95['getAttributes'](),_0xc81e34=_0x2dfc35['getAttributes']();for(const _0x227ecb of _0x519915){if(_0x227ecb[0x1]!==_0x2dfc35['getAttribute'](_0x227ecb[0x0]))return!0x1;_0xc81e34['next']();}return _0xc81e34['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x53d929=>{const _0x26096b=_0x53d929['markerName']['split'](':')[0x1],_0x3e0e72=this['_getChangeFromId'](_0x26096b);if(!_0x3e0e72)return null;const _0x175a31='add'==_0x3e0e72['type']?'insertion':'deletion',_0x179bdd=['ck-suggestion-marker','ck-suggestion-marker-'+_0x175a31];return _0x3e0e72['data']['isSuggestion']&&_0x179bdd['push']('ck-suggestion-marker-'+_0x175a31+'-new'),this['activeChange']==_0x3e0e72&&_0x179bdd['push']('ck-suggestion-marker--active'),{'classes':_0x179bdd,'attributes':{'data-change-id':_0x26096b}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x415ec9=>{_0x415ec9['on']('element:pre',(_0x1d45b5,_0x280224,_0x2ab3db)=>{const _0x151531=_0x280224['viewItem']['getChild'](0x0);if(!_0x151531||!_0x151531['is']('element','code'))return;if(!_0x2ab3db['consumable']['consume'](_0x151531,{'attributes':['vid_start','vid_end']}))return;const _0x3eeab3=_0x280224['modelRange']['start']['nodeAfter'];_0x2ab3db['writer']['setAttribute']('vid_start',_0x151531['getAttribute']('vid_start'),_0x3eeab3),_0x2ab3db['writer']['setAttribute']('vid_end',_0x151531['getAttribute']('vid_end'),_0x3eeab3);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x1a652c=>{_0x1a652c['on']('element',(_0x56e2e4,_0x109e21,_0x12d08e)=>{if(!_0x12d08e['consumable']['consume'](_0x109e21['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x109e21['modelRange']['isCollapsed'])return;const _0x537d5d=_0x109e21['modelRange']['start']['nodeAfter'];_0x537d5d['hasAttribute']('vid_start')||_0x537d5d['hasAttribute']('vid')||(_0x12d08e['writer']['setAttribute']('vid_start',_0x109e21['viewItem']['getAttribute']('vid_start'),_0x537d5d),_0x12d08e['writer']['setAttribute']('vid_end',_0x109e21['viewItem']['getAttribute']('vid_end'),_0x537d5d));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x192f10=>_0x192f10['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x22eaf7,[,_0x40c017])=>{['vid_start','vid_end','vid']['includes'](_0x40c017)&&(_0x22eaf7['return']=!0x0,_0x22eaf7['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x599907=>{_0x599907['on']('attribute:vid',(_0x34db9b,_0x37351b,_0x2821f9)=>{if('\x20'!=_0x37351b['item']['data']||_0x37351b['item']['parent']['maxOffset']>0x1)return;if(!_0x2821f9['consumable']['consume'](_0x37351b['item'],_0x34db9b['name']))return;const _0x5c3865=_0x2821f9['writer'],_0x15503b=_0x2821f9['mapper']['toViewRange'](_0x37351b['range']);_0x5c3865['wrap'](_0x15503b,_0x5c3865['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x1cdc7e){const _0x293e57=_0x1cdc7e['plugins']['get']('RevisionViewer');return(_0x97a57a,_0x58fcfe,_0x34c41f)=>{const _0x28ab2f=_0x58fcfe['markerName']['split'](':')[0x1],_0x3376c6=_0x293e57['_getChangeFromId'](_0x28ab2f);if(!_0x3376c6)return null;const _0x19712a='add'==_0x3376c6['type']?'split':'merge';if(!_0x34c41f['consumable']['test'](_0x58fcfe['markerRange'],_0x97a57a['name']))return;const _0x195ada=_0x58fcfe['markerRange']['getWalker'](),_0x1223e6=_0x58fcfe['markerRange']['start'],_0xc2cc2a=_0x1cdc7e['model']['schema'];let _0x1704a9=null,_0x3743ee=null,_0x407106=!0x1,_0x487147=!0x1;for(const _0x4ee2e1 of _0x195ada){const _0x40878a=_0x4ee2e1['item'];_0x407106=_0x407106||_0xc2cc2a['isContent'](_0x40878a);const _0x4e0685=_0x34c41f['mapper']['toViewElement'](_0x40878a);if(_0x4e0685&&_0x4e0685['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4ee2e1['type']&&(_0xc2cc2a['isBlock'](_0x40878a)&&!_0xc2cc2a['isLimit'](_0x40878a)&&(_0x40878a['nextSibling']||_0x1223e6['isAtEnd']?_0x1704a9&&_0x1704a9['parent']==_0x40878a||(_0x1704a9=_0x40878a,_0x3a3937(_0x4ee2e1['previousPosition']),_0x487147=!0x0):_0x3743ee=_0x3743ee||_0x4ee2e1['previousPosition']));}function _0x3a3937(_0x3cf7d1){const _0x4064f4=_0x34c41f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x19712a}),_0x37ad4a=_0x34c41f['mapper']['toViewPosition'](_0x3cf7d1);_0x3376c6['data']['isSuggestion']&&_0x34c41f['writer']['addClass']('ck-suggestion-marker-'+_0x19712a+'-new',_0x4064f4),_0x293e57['activeChange']==_0x3376c6&&_0x34c41f['writer']['addClass']('ck-suggestion-marker--active',_0x4064f4),_0x34c41f['writer']['insert'](_0x37ad4a,_0x4064f4),_0x34c41f['mapper']['bindElementToMarker'](_0x4064f4,_0x58fcfe['markerName']);}_0x407106||_0x487147||!_0x3743ee||_0x3a3937(_0x3743ee);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x53ee75,_0x23c944,_0x19e035)=>{const _0x537a59=_0x19e035['mapper']['markerNameToElements'](_0x23c944['markerName']);if(_0x537a59){for(const _0x5b4ced of _0x537a59)(_0x5b4ced['hasClass']('ck-suggestion-marker-split')||_0x5b4ced['hasClass']('ck-suggestion-marker-merge'))&&(_0x19e035['mapper']['unbindElementFromMarkerName'](_0x5b4ced,_0x23c944['markerName']),_0x19e035['writer']['remove'](_0x5b4ced));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x13b23d,_0x5b2cd7,_0xd578cf)=>{const _0x2db423=_0x5b2cd7['markerName']['split'](':')[0x1],_0x18d139=this['_getChangeFromId'](_0x2db423);if(!_0x18d139)return null;const _0x5b0efe='add'==_0x18d139['type']?'split':'merge';if(_0xd578cf['consumable']['test'](_0x5b2cd7['markerRange'],_0x13b23d['name']))for(const _0x13a149 of _0x5b2cd7['markerRange']['getItems']()){if(!_0x13a149['is']('element','softBreak'))continue;const _0xd8c70b=_0xd578cf['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5b0efe}),_0x2e1e74=_0xd578cf['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x13a149));_0x18d139['data']['isSuggestion']&&_0xd578cf['writer']['addClass']('ck-suggestion-marker-'+_0x5b0efe+'-new',_0xd8c70b),this['activeChange']==_0x18d139&&_0xd578cf['writer']['addClass']('ck-suggestion-marker--active',_0xd8c70b),_0xd578cf['writer']['insert'](_0x2e1e74,_0xd8c70b),_0xd578cf['mapper']['bindElementToMarker'](_0xd8c70b,_0x5b2cd7['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x922bc8=>{for(const _0x47adc3 of this['editor']['model']['document']['getRootNames']()){const _0x417a70=this['editor']['model']['document']['getRoot'](_0x47adc3),_0x430cb3=this['editor']['editing']['view']['document']['getRoot'](_0x47adc3);if(_0x430cb3){const _0x3f5530=_0x417a70['getAttribute']('revisionHistoryAttachChange');if(_0x922bc8['removeAttribute']('data-change-id',_0x430cb3),_0x922bc8['removeClass']('ck-revision-history-root-add',_0x430cb3),_0x922bc8['removeClass']('ck-revision-history-root-remove',_0x430cb3),_0x922bc8['removeClass']('ck-revision-history-root--active',_0x430cb3),_0x3f5530){const _0x2d9a6f=this['_getChangeFromId'](_0x3f5530);if(!_0x2d9a6f)return null;_0x922bc8['setAttribute']('data-change-id',_0x3f5530,_0x430cb3),_0x922bc8['addClass']('ck-revision-history-root-'+_0x2d9a6f['type'],_0x430cb3),this['activeChange']==_0x2d9a6f&&_0x922bc8['addClass']('ck-revision-history-root--active',_0x430cb3);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x58ebeb=>'revision-comment:'+_0x58ebeb,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x9a122f=>'revision-suggestion:'+_0x9a122f,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x4f0546=>({'name':'suggestion:'+_0x4f0546,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x4cc479=>{const _0x43bc12=_0x4cc479['markerName']['split'](':')[0x1];return'insertion'!=_0x43bc12&&'deletion'!=_0x43bc12?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x43bc12]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x56f36b,_0x15389c,_0x4bdb07)=>{const _0x1e8032=_0x4bdb07['mapper']['markerNameToElements'](_0x15389c['markerName']);if(_0x1e8032){for(const _0x513443 of _0x1e8032)_0x513443['is']('uiElement')&&(_0x4bdb07['mapper']['unbindElementFromMarkerName'](_0x513443,_0x15389c['markerName']),_0x4bdb07['writer']['remove'](_0x513443));}},{'priority':'high'});}['_getChangeFromId'](_0x438810){return this['_changeIdToChange']['get'](_0x438810);}['_getViewForChange'](_0x38147d){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x38147d),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x11b1f1,_0x1bb460,_0x196fb7,_0x482efb)=>{_0x482efb&&this['_balloon']['remove'](_0x482efb),_0x196fb7&&(this['_balloon']['add']({'view':_0x196fb7,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4652e2=this['editor']['editing'],_0x58fbf4=this['_getChangeFromId'](_0x196fb7['changeId']);let _0x4b7c8a;if(_0x58fbf4['data']['isOnRoot']){const _0x51f04a=_0x4652e2['view']['getDomRoot'](_0x58fbf4['rootName']);_0x4b7c8a=Array['from'](_0x51f04a['getClientRects']());}else{const _0x4f5901=this['editor']['model']['markers']['get']('revision:'+_0x196fb7['changeId']);_0x4b7c8a=Array['from'](_0x4652e2['mapper']['markerNameToElements'](_0x4f5901['name']))['map'](_0x350511=>_0x4652e2['view']['domConverter']['mapViewToDom'](_0x350511))['map'](_0x25c1a3=>Array['from'](_0x25c1a3['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x4b7c8a[0x0];return _0x4b7c8a['find'](_0x56a70c=>_0x56a70c['top']-0x3<=this['_activeViewTarget']['y']&&_0x56a70c['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x56a70c['left']-0x3<=this['_activeViewTarget']['x']&&_0x56a70c['right']+0x3>=this['_activeViewTarget']['x'])||_0x4b7c8a[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x11d15d,_0x331d76,_0x4f9f71,_0x4cacda)=>{this['activeView']=_0x4f9f71?this['_getViewForChange'](_0x4f9f71):null,this['editor']['model']['change'](()=>{const _0x477ee5=this['editor']['editing'];_0x4cacda&&(_0x4cacda['data']['isOnRoot']?_0x477ee5['view']['change'](_0x28c016=>{_0x28c016['removeClass']('ck-revision-history-root--active',_0x477ee5['view']['document']['getRoot'](_0x4cacda['rootName']));}):_0x477ee5['reconvertMarker']('revision:'+_0x4cacda['id'])),_0x4f9f71&&(_0x4f9f71['data']['isOnRoot']?_0x477ee5['view']['change'](_0x246a17=>{_0x246a17['addClass']('ck-revision-history-root--active',_0x477ee5['view']['document']['getRoot'](_0x4f9f71['rootName']));}):_0x477ee5['reconvertMarker']('revision:'+_0x4f9f71['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x28e217,_0x4bcf08)=>{if(this['activeChange'])return;const _0x47c03d=this['_findChangeIdFromDomTarget'](_0x4bcf08['target']),_0x3e352b=this['_changeIdToChange']['get'](_0x47c03d);_0x3e352b?(this['_activeViewTarget']={'x':_0x4bcf08['domEvent']['x'],'y':_0x4bcf08['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3e352b)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x35cda8,_0x4c6fa7)=>{const _0x549bd0=this['_findChangeIdFromDomTarget'](_0x4c6fa7['target']),_0xa1b3df=this['_changeIdToChange']['get'](_0x549bd0);_0xa1b3df?(this['_activeViewTarget']={'x':_0x4c6fa7['domEvent']['x'],'y':_0x4c6fa7['domEvent']['y']},_0xa1b3df===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xa1b3df):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x597856){do{const _0x15ca5a=_0x597856['getAttribute']('data-change-id');if(_0x15ca5a)return _0x15ca5a;_0x597856=_0x597856['parent'];}while(_0x597856);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x547c5a=>{for(const _0x1e8f65 of this['editor']['model']['markers'])_0x547c5a['removeMarker'](_0x1e8f65);});}}function tt(_0x12ee21,_0x5e5478){return(_0xb637fc,_0x3c46e8,_0xb8f4b6)=>{if(!_0xb8f4b6['consumable']['test'](_0x3c46e8['markerRange'],_0xb637fc['name']))return;const _0x429348=_0x3c46e8['markerRange']['getWalker'](),_0x46d31c=_0x3c46e8['markerRange']['start'],_0x3a6123=_0x12ee21['model']['schema'];let _0x4f7a6a=null,_0x118aea=null,_0x4cd877=!0x1,_0x3bff92=!0x1;for(const _0x337609 of _0x429348){const _0x474298=_0x337609['item'];_0x4cd877=_0x4cd877||_0x3a6123['isContent'](_0x474298);const _0x5b1aff=_0xb8f4b6['mapper']['toViewElement'](_0x474298);if(_0x5b1aff&&_0x5b1aff['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x337609['type']&&(_0x3a6123['isBlock'](_0x474298)&&!_0x3a6123['isLimit'](_0x474298)&&(_0x474298['nextSibling']||_0x46d31c['isAtEnd']?_0x4f7a6a&&_0x4f7a6a['parent']==_0x474298||(_0x4f7a6a=_0x474298,_0x12df86(_0x337609['previousPosition']),_0x3bff92=!0x0):_0x118aea=_0x118aea||_0x337609['previousPosition']));}function _0x12df86(_0x6da3e4){const _0x5c2a0c=_0xb8f4b6['mapper']['toViewPosition'](_0x6da3e4),_0x15dc35=_0xb8f4b6['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x5e5478});_0xb8f4b6['writer']['insert'](_0x5c2a0c,_0x15dc35),_0xb8f4b6['mapper']['bindElementToMarker'](_0x15dc35,_0x3c46e8['markerName']);}_0x4cd877||_0x3bff92||!_0x118aea||_0x12df86(_0x118aea);};}class _t extends _0xb9095c{constructor(_0x3807b3){super(_0x3807b3);const _0xaf0662=_0x3807b3['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0xaf0662,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xaf0662,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x43696e=this['editor'],_0x549336=_0x43696e['plugins']['get'](d),_0x3be3dd=_0x549336['isReady']?_0x549336['diff']['newRevisionId']:null;_0x43696e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3be3dd);}['refresh'](){const {isReady:_0xf258a9,isEnabled:_0x162150,repository:_0x347c88,diff:_0x1a581a}=this['editor']['plugins']['get'](d),_0x8dd5c1=_0x1a581a&&_0x347c88['getLaterVisibleRevision'](_0x1a581a['newRevisionId']);this['isEnabled']=_0xf258a9&&_0x162150&&Boolean(_0x8dd5c1);}}class yt extends _0xb9095c{['_step'];constructor(_0x38e189,{direction:_0x4e87e2}){super(_0x38e189);const _0x2ec117=_0x38e189['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x4e87e2?0x1:-0x1,this['listenTo'](_0x2ec117,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2ec117,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2ec117,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4be2bc=this['editor'],_0x1b530f=_0x4be2bc['plugins']['get'](d),{isNavigationMode:_0xe50fa1,currentChangeNumber:_0x2e10c4}=_0x1b530f;let _0x47800f;if(_0x1b530f['activeChange']=_0xe50fa1?_0x1b530f['diff']['changes']['get'](_0x2e10c4+this['_step']):_0x1b530f['diff']['changes']['first'],_0x1b530f['activeChange']['data']['isOnRoot'])_0x47800f=_0x4be2bc['editing']['view']['getDomRoot'](_0x1b530f['activeChange']['rootName']);else{const _0x1d34fe=_0x4be2bc['model']['markers']['get']('revision:'+_0x1b530f['activeChange']['id']);_0x47800f=_0x38b134(_0x4be2bc['editing'],_0x1d34fe);}_0x11b89e({'target':_0x47800f,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x330c46,currentChangeNumber:_0x415f67,numberOfChanges:_0x4e3c17,isReady:_0x37276b,isEnabled:_0x3a1140}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x3a1140&&_0x37276b&&_0x4e3c17)&&(!_0x330c46||(0x1===this['_step']?_0x415f67<_0x4e3c17-0x1:_0x415f67>0x0));}}class ui extends ts{constructor(_0x44419b){super(_0x44419b);const _0x1af245=this['bindTemplate'],_0x3fd775=new te(_0x44419b),_0x5e7689=new te(_0x44419b);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',(_0x2b4235,_0x5d9b62)=>_0x2b4235&&_0x5d9b62>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x726364,_0x9ff611,_0x516578,_0x44dc5c)=>{if(!_0x726364)return R(_0x44419b,'Loading...');if(!_0x516578)return R(_0x44419b,'No\x20changes');const _0x103b21=R(_0x44419b,'NUMBER_OF_CHANGES',_0x516578);return _0x44dc5c?R(_0x44419b,'X_OF_Y_CHANGES',[_0x9ff611+0x1,_0x516578]):_0x103b21;}),_0x3fd775['set']({'label':R(_0x44419b,'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'}),_0x5e7689['set']({'label':R(_0x44419b,'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'}),_0x3fd775['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5e7689['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3fd775['on']('execute',()=>this['fire']('execute','backward')),_0x5e7689['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',_0x1af245['if']('_isStatusLabelVisible','ck-hidden',_0x363354=>!_0x363354)]},'children':[{'text':_0x1af245['to']('isNavigationMode',_0x3c9577=>_0x3c9577?R(_0x44419b,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x44419b,'Total')+':\x20')}]},{'text':_0x1af245['to']('_statusText')}]},new _0xfdf3f0(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3fd775,_0x5e7689]}]});}}const le='ck-editor__editable__loading-overlay';class de extends _0x49e1b4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x52e79c=this['editor']['editing']['view'];_0x52e79c['change'](_0x2d4f17=>{for(const _0x2785f8 of _0x52e79c['document']['roots'])_0x2d4f17['addClass'](le,_0x2785f8);});}['hide'](){const _0x4ba453=this['editor']['editing']['view'];_0x4ba453['change'](_0x527010=>{for(const _0x3c553e of _0x4ba453['document']['roots'])_0x527010['removeClass'](le,_0x3c553e);});}}class m extends _0x49e1b4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,de];}['init'](){const _0x2f96c7=this['editor'],_0x2ef338=_0x2f96c7['plugins']['get'](d),_0x27b502=_0x2f96c7['plugins']['get'](de);_0x2f96c7['ui']['componentFactory']['add']('exitToEditing',_0xf12607=>{const _0x37abe9=new te(_0xf12607);return _0x37abe9['set']({'label':R(_0xf12607,'Back\x20to\x20editing'),'icon':_0x4e4052['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x37abe9,'execute',()=>{_0x2f96c7['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x37abe9;}),_0x2f96c7['ui']['componentFactory']['add']('restoreRevision',_0x180e66=>{const _0x15e051=new te(_0x180e66);return _0x15e051['set']({'label':R(_0x180e66,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x15e051['bind']('isEnabled')['to'](_0x2f96c7['commands']['get']('restoreRevision')),this['listenTo'](_0x15e051,'execute',()=>_0x2f96c7['execute']('restoreRevision')),_0x15e051;}),_0x2f96c7['ui']['componentFactory']['add']('changesNavigation',_0x5e3914=>{const _0x189ca4=new ui(_0x5e3914),_0x30cb82=_0x2f96c7['commands']['get']('showPreviousChange'),_0x4e1862=_0x2f96c7['commands']['get']('showNextChange');return _0x189ca4['bind']('isBackwardNavigationEnabled')['to'](_0x30cb82,'isEnabled'),_0x189ca4['bind']('isForwardNavigationEnabled')['to'](_0x4e1862,'isEnabled'),_0x189ca4['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2ef338),this['listenTo'](_0x189ca4,'execute',(_0xfc3e2f,_0x140705)=>{_0x2f96c7['execute']('forward'===_0x140705?'showNextChange':'showPreviousChange');}),_0x189ca4;}),_0x27b502['show'](),_0x2ef338['on']('change:isReady',(_0x2a9261,_0x5256be,_0x1d9dd6)=>{_0x1d9dd6?_0x27b502['hide']():_0x27b502['show']();});}}class pt extends _0x2dd0c6{['_resizeObserver']=null;constructor(_0x14cc50,_0x5a7b35){super(_0x14cc50,_0x5a7b35);const _0x385815=this['bindTemplate'];this['set']({'label':R(_0x14cc50,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x14cc50,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x385815['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 _0x158216=this['fieldView']['element'];this['_tooltipString']=_0x158216['scrollWidth']>_0x158216['clientWidth']&&_0x158216['value']||'';}}class ri extends ts{constructor(_0x4054ae,_0x1acd00,_0x22942e){super(_0x4054ae);const _0x19dacd=new _0x4cf3df();_0x19dacd['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 _0x278612=['ck','ck-revision-history-sidebar__revision-author'];_0x22942e&&_0x278612['push']('ck-revision-history-sidebar__revision-author_creator');const _0x728c01=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x4054ae,_0x22942e?'Revision\x20creator':'Revision\x20author')},'children':[_0x19dacd,_0x1acd00['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x278612},'children':_0x728c01});}}function oi(_0x131fd8,_0x4e8cf5){const _0x1d8bb6=_0x131fd8['bindTemplate'],_0x343727=_0x131fd8['locale'],_0x41352b=_0x10f4d8(_0x343727);_0x41352b['panelPosition']='sw';const _0x3b6645=function(_0x517301,_0x27cd19){const _0x4cb9f3=function(_0x138142,_0x203537){const _0x536322=_0x138142['locale'],_0x87db32={'Compare\x20against\x20selected':R(_0x536322,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x536322,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x536322,'Restore\x20this\x20revision')};return _0x203537['map'](_0x259267=>{const _0x22b442=_0x87db32[_0x259267['name']];return _0x22b442&&_0x22b442!==_0x259267['name']&&(_0x259267['name']=_0x22b442),_0x259267;});}(_0x517301,_0x27cd19),_0x36bf42=new _0x53bf0e();for(const _0x3e5bd5 of _0x4cb9f3){const _0xf56929={'type':'button','model':new _0x563314({'label':_0x3e5bd5['name'],'class':_0x3e5bd5['class'],'withText':!0x0,'role':'menuitem','_action':_0x3e5bd5['action']})};_0xf56929['model']['bind']('isEnabled')['to'](_0x517301,'isActionsDropdownOpen',_0x28c096=>'function'!=typeof _0x3e5bd5['isEnabled']||(!_0x28c096||_0x3e5bd5['isEnabled'](_0x517301))),_0x36bf42['add'](_0xf56929);}return _0x36bf42;}(_0x131fd8,_0x4e8cf5);return _0x131fd8['bind']('isActionsDropdownOpen')['to'](_0x41352b,'isOpen'),_0x41352b['buttonView']['set']({'label':R(_0x343727,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x4e4052['threeVerticalDots']}),_0x41352b['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1d8bb6['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1d8bb6['to'](_0x38b0ee=>_0x38b0ee['stopPropagation']())}}),_0x41352b['on']('execute',_0x35a2dc=>{_0x131fd8['isReady']&&'function'==typeof _0x35a2dc['source']['_action']&&_0x35a2dc['source']['_action'](_0x131fd8);}),to(_0x41352b,_0x3b6645,{'role':'menu'}),_0x41352b['listenTo'](_0x131fd8,'change:isActionsDropdownOpen',(_0x490693,_0x45c300,_0x310e01)=>{if(_0x310e01)for(const _0x2f39b1 of _0x41352b['listView']['items']){const _0x289fbb=_0x2f39b1['children']['first'],_0x4b4544=_0x4e8cf5['find'](_0x317c79=>_0x317c79['action']===_0x289fbb['_action'])['isVisible'];_0x2f39b1['isVisible']=void 0x0===_0x4b4544||_0x4b4544(_0x131fd8);}}),_0x41352b;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x4add69,_0x1df5ce,_0x125b6e,_0x40cd77){super(_0x4add69);const _0x4cf1b0=this['bindTemplate'],_0x48b99b=function(_0x2d38f3,_0x199d66){const _0x290ae5=Array['from'](_0x199d66['authors'])['filter'](_0x5e495d=>_0x5e495d!=_0x199d66['creator']);return _0x199d66['creator']&&_0x290ae5['unshift'](_0x199d66['creator']),_0x290ae5['map'](_0x24bffb=>new ri(_0x2d38f3,_0x24bffb,_0x24bffb==_0x199d66['creator']));}(_0x4add69,_0x1df5ce);this['id']=_0x1df5ce['id'],this['_revision']=_0x1df5ce,this['_requireRevisionName']=_0x40cd77,this['bind']('name','createdAt')['to'](_0x1df5ce),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3844d8=>{return _0x45913f=_0x4add69['uiLanguage'],(_0x350967=_0x3844d8)['toLocaleDateString'](_0x45913f,{'month':'long','day':'numeric'})+',\x20'+_0x350967['toLocaleTimeString'](_0x45913f,{'hour':'numeric','minute':'numeric'});var _0x45913f,_0x350967;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x4add69,_0x1df99b),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x195f9d=>_0x195f9d||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x39a922,_0x2d4e36)=>_0x39a922&&_0x2d4e36),this['revisionActionsView']=_0x125b6e&&_0x125b6e['length']?oi(this,_0x125b6e):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4cf1b0['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4cf1b0['if']('isEnabled','ck-disabled',_0x5a15f9=>!_0x5a15f9),_0x4cf1b0['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4cf1b0['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4cf1b0['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':_0x4cf1b0['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':_0x48b99b}]},this['revisionActionsView']],'on':{'click':_0x4cf1b0['to'](_0x71884c=>{_0x71884c['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5b916d=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5b916d,'change',()=>{this['_requireRevisionName']&&!_0x5b916d['value']||this['fire']('setName',{'id':this['id'],'name':_0x5b916d['value']}),_0x5b916d['value']||(_0x5b916d['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x56a3de,_0x2ce621){const _0x4c6583=_0x1dd358['fromJSDate'](_0x56a3de)['setLocale'](_0x2ce621),_0x4a9778=_0x1dd358['local'](),_0x349a43=_0x4a9778['minus']({'days':0x1})['startOf']('day');let _0x489f82,_0x47a1df;return _0x4c6583['hasSame'](_0x4a9778,'day')?(_0x489f82=_0x4c6583['startOf']('day')['toJSDate'](),_0x47a1df=_0x4c6583['toRelativeCalendar']()):_0x4c6583['hasSame'](_0x349a43,'day')?(_0x489f82=_0x349a43['toJSDate'](),_0x47a1df=_0x4c6583['toRelativeCalendar']()):_0x4c6583['hasSame'](_0x4a9778,'week')?(_0x489f82=_0x4c6583['startOf']('week')['toJSDate'](),_0x47a1df=_0x4c6583['weekdayLong']||''):_0x4c6583['hasSame'](_0x4a9778,'year')?(_0x489f82=_0x4c6583['startOf']('month')['toJSDate'](),_0x47a1df=_0x4c6583['monthLong']||''):(_0x489f82=_0x4c6583['startOf']('year')['toJSDate'](),_0x47a1df=String(_0x4c6583['year'])),{'startDate':_0x489f82,'localizedPeriodName':_0x47a1df};}class vi extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x171389,_0x13df71,_0x55d179,_0x13aa9b){super(_0x171389);const _0x520341=mi(_0x13df71,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x13df71,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x55d179,this['_requireRevisionName']=_0x13aa9b,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':_0x520341}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x24d280){const _0x51aed0=new hi(this['locale'],_0x24d280,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x51aed0);}['removeRevision'](_0x1a2d8e){const _0xfed954=this['revisionViews']['find'](_0x5b8557=>_0x5b8557['id']===_0x1a2d8e['id']);this['revisionViews']['remove'](_0xfed954);}}class as extends ts{constructor(_0xc8b599){super(_0xc8b599);const _0x3ebd4d=new _0x4cf3df();_0x3ebd4d['content']=_0x4e4052['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x3ebd4d,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0xc8b599,'Revision\x20history')]}]});}}class di extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x294845,_0x26cdda,_0x1757c3,_0x19b900){super(_0x294845);const _0x4943a6=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x26cdda,this['_revisionActions']=_0x1757c3,this['_requireRevisionName']=_0x19b900,this['on']('select',(_0x2c9068,_0x55dc46)=>{this['fire']('revisionSelected',_0x55dc46);}),this['on']('setName',(_0x1e190f,_0x545101)=>{this['fire']('revisionSetName',_0x545101);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x294845),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x4943a6['if']('isEnabled','ck-disabled',_0x463b3d=>!_0x463b3d)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x58a44d of this['_revisions'])this['_addRevision'](_0x58a44d);this['_revisions']['on']('add',(_0x45fc8c,_0x24430c)=>{this['_addRevision'](_0x24430c);}),this['_revisions']['on']('remove',(_0x497420,_0x8013da)=>{this['_removeRevision'](_0x8013da);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x24dc31=>_0x24dc31['revisionViews']['map'](_0x427f08=>_0x427f08))['flat']();}['selectRevision'](_0x4fbbc6){for(const _0x28330d of this['revisionViews'])_0x4fbbc6&&_0x4fbbc6['id']===_0x28330d['id']?_0x28330d['select']():_0x28330d['deselect']();}['highlightRevisions'](_0x5b29e7){for(const _0x278561 of this['revisionViews'])_0x5b29e7['some'](({id:_0x569f7d})=>_0x569f7d===_0x278561['id'])?_0x278561['highlight']():_0x278561['unhighlight']();}['_addRevision'](_0x4d7c6d){const _0x5e9afe=mi(_0x4d7c6d['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x3437a2=this['timePeriodViews']['get'](0x0);_0x3437a2&&_0x3437a2['startDate']['getTime']()===_0x5e9afe['getTime']()||(_0x3437a2=new vi(this['locale'],_0x5e9afe,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x3437a2)),_0x3437a2['addRevision'](_0x4d7c6d);}['_removeRevision'](_0x563b0a){const _0x307381=mi(_0x563b0a['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x307381)['removeRevision'](_0x563b0a);}['_getTimePeriodViewByStartDate'](_0x4ca4fc){return this['timePeriodViews']['find'](_0x175b0e=>_0x175b0e['startDate']['getTime']()===_0x4ca4fc['getTime']());}}class g extends _0x49e1b4{['_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(_0x37fa96){super(_0x37fa96),this['_revisionViewer']=_0x37fa96['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x251e18=this['_revisionsRepository']['_revisions'],_0xb39689=this['_createRevisionActions'](),_0x2657d4=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x251e18,_0xb39689,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',(_0x48d948,_0x42f654)=>{_0x42f654['revisionViews']['on']('add',(_0x25ab96,_0x416cfe)=>{_0x416cfe['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)),_0x2657d4['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x106648=this['_revisionsRepository']['getRevision'](0x0);if(_0x106648){const _0x3082f6=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x106648['id']);this['_revisionViewer']['compare'](_0x106648,_0x3082f6);}}['_handleRevisionSelected'](_0x30b6d7,_0x45998e){const _0x548ff7=this['_revisionsRepository']['getRevision'](_0x45998e['id']),_0x38120c=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x548ff7['id']);this['_revisionViewer']['compare'](_0x548ff7,_0x38120c);}['_handleRevisionSetName'](_0x22c58f,_0x26ef4f){this['_revisionsRepository']['getRevision'](_0x26ef4f['id'])['setName'](_0x26ef4f['name']);}['_handleDiffChange'](_0x3f7410,_0x1bb0a4,_0x4ab5dd){const _0x2781fc=this['_revisionsRepository']['getRevisionsInDiff'](_0x4ab5dd);_0x2781fc['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x2781fc),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x2781fc[0x0]));}['_createRevisionActions'](){const _0x469337=this['editor'],_0x1c4259=g['availableRevisionActions'],_0x308d0c=_0x469337['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x308d0c['length'])return _0x308d0c['map'](_0x259cc3=>{const _0x178f54='string'==typeof _0x259cc3?Object['assign']({},_0x1c4259[_0x259cc3]):_0x259cc3;return _0x178f54['action']=_0x178f54['action']['bind'](this,_0x469337),_0x178f54['isVisible']&&(_0x178f54['isVisible']=_0x178f54['isVisible']['bind'](this,_0x469337)),_0x178f54;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x473644},_0x464f36)=>{const _0x58a58c=_0x473644['get'](d),_0x23d85b=_0x58a58c['repository'];let _0x449fa3=_0x58a58c['diff']['newRevisionId'],_0x785907=_0x464f36['id'];_0x23d85b['getIndex'](_0x449fa3)>_0x23d85b['getIndex'](_0x785907)&&([_0x449fa3,_0x785907]=[_0x785907,_0x449fa3]),_0x58a58c['compare'](_0x449fa3,_0x785907);},'isVisible':({plugins:_0x4454ab},_0x423a77)=>{const _0x4cbe10=_0x4454ab['get'](d);return!(_0x4cbe10['repository']['getRevisionsInDiff'](_0x4cbe10['diff'])['length']>0x2)&&!_0x423a77['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x413dba,{id:_0x2c65d2})=>{_0x413dba['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x2c65d2);},'isVisible':({plugins:_0x1873ad},_0x4e4ae9)=>!!_0x1873ad['get'](d)['repository']['getLaterVisibleRevision'](_0x4e4ae9['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x6b6814},{id:_0x13f926,revisionNameView:_0x1bcba0})=>{const _0x5047bc=_0x6b6814['get'](d),_0x33aa19=_0x5047bc['repository']['getEarlierVisibleRevision'](_0x13f926);_0x5047bc['compare'](_0x13f926,_0x33aa19),_0x1bcba0['focus'](),_0x1bcba0['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x2306bb,_0x3ebaba){super(_0x2306bb),this['_view']=_0x3ebaba,this['_toolbarConfig']=ht(_0x2306bb['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x51f45b){const _0x40c7d6=this['editor'],_0x5cbfdb=this['view'],_0x53ed45=_0x40c7d6['editing']['view'],_0x69c6cb=_0x5cbfdb['editable'],_0x4cf194=_0x53ed45['document']['getRoot']();_0x69c6cb['name']=_0x4cf194['rootName'],_0x5cbfdb['render']();const _0x5920ff=_0x69c6cb['element'];this['setEditableElement'](_0x69c6cb['name'],_0x5920ff),_0x5cbfdb['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x53ed45['attachDomRoot'](_0x5920ff),this['_elementReplacer']['replace'](_0x51f45b,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2fd88d=this['view'],_0x7a7ae0=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x7a7ae0['detachDomRoot'](_0x2fd88d['editable']['name']),_0x2fd88d['destroy']();}['_initToolbar'](){const _0x3bdddd=this['view'];_0x3bdddd['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3bdddd['stickyPanel']['limiterElement']=_0x3bdddd['element'],_0x3bdddd['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x43c78c})=>_0x43c78c),_0x3bdddd['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3bdddd['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x350134,_0x29441e,_0x1ba71a={}){super(_0x350134),this['stickyPanel']=new lt(_0x350134),this['toolbar']=new nt(_0x350134,{'shouldGroupWhenFull':_0x1ba71a['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x350134,_0x29441e);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
- rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4342d7,_0x122f34){super(_0x122f34),this['sourceElement']=_0x4342d7,this['model']['document']['createRoot']();const _0x62c02f=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x62c02f);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x130e60,_0x439ef2){const _0x43af54=new this(_0x130e60,_0x439ef2);return await _0x43af54['initPlugins'](),await _0x43af54['ui']['init'](_0x130e60),await _0x43af54['data']['init'](_0x43af54['config']['get']('initialData')||''),_0x43af54['fire']('ready'),_0x43af54;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x5951b8{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2631ca){function _0x1ab6d9(_0x101ec5){return _0x101ec5['map'](_0x9c3348=>String['fromCharCode'](_0x9c3348))['join']('');}super(_0x2631ca),this['result']='end',_0x2631ca[_0x1ab6d9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1ab6d9([0x76,0x69,0x65,0x77])][_0x1ab6d9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1ab6d9([0x61,0x75,0x74,0x6f]),_0x2631ca[_0x1ab6d9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1ab6d9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1ab6d9([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1ab6d9([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1ab6d9([0x6f,0x6b])});}}class H extends _0x5951b8{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x4588f2){if(super(_0x4588f2),!this['editor']['config']['get']('revisionHistory'))throw new _0x3fa815('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x50819c=>this['_showRevisionViewer']({..._0x50819c,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x305ceb=>this['_closeRevisionViewer'](_0x305ceb)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x889008=>this['_restoreRevision'](_0x889008)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1a8d84){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1a8d84;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x5c6f1f){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x5c6f1f);}['getRevision'](_0x19a00c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x19a00c);}['getRevisions'](_0x4a8836){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4a8836||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4207eb=this['editor'],_0x2db3a7=_0x19230e(_0x4207eb,p),_0x4a44b4=_0x4207eb['plugins']['get']('RevisionTracker'),_0x2870e9=_0x4207eb['plugins']['get']('Users')['users'];return _0x2db3a7['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x2db3a7['lazyRoots'],(_0x2db3a7['plugins']['push'](k,d,m,class extends _0x5951b8{static get['requires'](){return[d,'Users'];}['init'](){const _0x4299a0=this['editor']['plugins']['get']('Users');for(const _0x33cd7c of _0x2870e9)_0x33cd7c['isAnonymous']||_0x4299a0['getUser'](_0x33cd7c['id'])||_0x4299a0['addUser'](_0x33cd7c);const _0x5c1586=_0x4a44b4['repository']['getRevisions']();let _0x3d5c83=null;const _0x2c668f=this['editor']['plugins']['get']('RevisionViewer');_0x2c668f['adapter']=_0x4a44b4['adapter'],_0x2c668f['bind']('isEnabled')['to'](_0x4a44b4),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4207eb,'isReadOnly',_0x11788d=>!_0x11788d);for(const _0x12b838 of _0x5c1586){const _0x55e3e3=null===_0x12b838['creator'];if(_0x55e3e3&&_0x12b838['toVersion']===_0x12b838['fromVersion'])continue;const _0x1f76f4=_0x12b838['toJSON']();_0x2c668f['addRevisionData'](_0x1f76f4,(_0x542cac,_0x38b86d,_0x3e38ad)=>{if(_0x55e3e3){if(_0x3d5c83)_0x3d5c83['_update'](_0x542cac,_0x38b86d);else{if(!_0x38b86d){const _0x463eca=_0x3e38ad['toJSON']();_0x463eca['id']=_0x5168c7(),_0x4a44b4['saveRevision'](_0x463eca,_0x3e38ad['toVersion'])['then'](_0x318234=>{_0x3d5c83=_0x318234;});}}}else _0x12b838['_update'](_0x542cac,_0x38b86d);});}}},g),_0x2db3a7);}['_enhanceShowRevisionViewerCallback'](){const _0x1e7511=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x452e15=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x803c92=this['editor']['plugins']['get']('Autosave');await _0x803c92['save']();}else await _0x452e15['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x219938=this['editor']['plugins']['get']('Dialog');_0x219938['isOpen']&&_0x219938['hide']();}const _0x3ef292=this['_getRevisionViewerEditorConfig']();return _0x1e7511(_0x3ef292)['then'](_0x50c912=>{return(this['_viewerEditor']=_0x50c912,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x50c912;})['catch'](_0x4152fa=>(console['error'](_0x4152fa),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5663b6=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'](),_0x5663b6(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x3d4bc6=this['editor']['plugins']['get']('Annotations');_0x3d4bc6['refreshVisibility'](),_0x3d4bc6['refreshPositioning']();}})));}['_showRevisionViewer'](_0x2a3590){const _0x1679ec=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x159138=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x9b06e3=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x9b06e3,_0x2a3590)['then'](_0x2cbc2c=>(_0x159138['style']['display']='block',_0x1679ec['style']['display']='none',_0x2cbc2c));}['_closeRevisionViewer'](_0xfacd4a){const _0x28cbfd=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x28cbfd['style']['display']='',_0xfacd4a['destroy']();}async['_restoreRevision'](_0x497d73){const _0x485bb9=this['editor'],_0x464378=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1c2520=_0x485bb9['plugins']['get']('RevisionTracker'),_0x39ee4e=_0x464378['repository']['getRevision'](_0x497d73);let _0x4c8ef0,_0x31ed6f,_0x366e9f;try{_0x4c8ef0=await _0x464378['getRevisionData'](_0x39ee4e),_0x31ed6f=await _0x464378['getRevisionRootsAttributes'](_0x39ee4e);}catch(_0x3c1cb8){return void console['error'](_0x3c1cb8);}_0x485bb9['model']['change'](_0x23ec92=>{for(const _0x3674fc of Array['from'](_0x485bb9['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x23ec92['removeMarker'](_0x3674fc);}),_0x464378['isReady']=!0x1,_0x485bb9['model']['enqueueChange'](_0x1b4bd4=>{_0x1b4bd4['setSelection'](null),_0x1b4bd4['removeSelectionAttribute'](_0x485bb9['model']['document']['selection']['getAttributeKeys']());const _0xd0d413=Object['keys'](_0x4c8ef0);for(const _0x12aecf of _0x485bb9['model']['document']['roots'])'$graveyard'!=_0x12aecf['rootName']&&_0x12aecf['isAttached']()&&!_0xd0d413['includes'](_0x12aecf['rootName'])&&_0x1b4bd4['detachRoot'](_0x12aecf);for(const _0x54922a of _0xd0d413){let _0x511d22=_0x485bb9['model']['document']['getRoot'](_0x54922a);_0x511d22&&_0x511d22['isAttached']()||(_0x511d22=_0x1b4bd4['addRoot'](_0x54922a));const _0x53b6cf=_0x31ed6f[_0x54922a],_0x5958a9=Object['keys'](_0x53b6cf),_0x1818d8=_0x4c8ef0[_0x54922a];for(const _0x4d75af of _0x511d22['getAttributeKeys']())_0x5958a9['includes'](_0x4d75af)||_0x1b4bd4['removeAttribute'](_0x4d75af,_0x511d22);for(const _0x593744 of _0x5958a9)_0x1b4bd4['setAttribute'](_0x593744,_0x31ed6f[_0x54922a][_0x593744],_0x511d22);_0x1b4bd4['remove'](_0x1b4bd4['createRangeIn'](_0x511d22)),_0x1b4bd4['insert'](_0x485bb9['data']['parse'](_0x1818d8,_0x511d22),_0x511d22,0x0);}});const _0x1b8d3b=R(_0x485bb9['locale'],'Restored');if(_0x39ee4e['name'])_0x366e9f=-0x1==_0x39ee4e['name']['indexOf'](_0x1b8d3b)?_0x1b8d3b+':\x20'+_0x39ee4e['name']:_0x39ee4e['name'];else _0x366e9f=_0x1b8d3b+':\x20'+(_0x39ee4e['createdAt']['toLocaleDateString'](_0x485bb9['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x39ee4e['createdAt']['toLocaleTimeString'](_0x485bb9['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1c2520['saveRevision']({'name':_0x366e9f}),_0x464378['isReady']=!0x0,_0x485bb9['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,de as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
28
+ bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0xae1e8){super(_0xae1e8),this['_revisionViewer']=_0xae1e8['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x148cd4=this['_revisionsRepository']['_revisions'],_0x5f0282=this['_createRevisionActions'](),_0x5afd66=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x148cd4,_0x5f0282,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',(_0x32b783,_0x2d80d8)=>{_0x2d80d8['revisionViews']['on']('add',(_0x2acdf1,_0x1a554f)=>{_0x1a554f['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)),_0x5afd66['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x48cd6e=this['_revisionsRepository']['getRevision'](0x0);if(_0x48cd6e){const _0x4a2499=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x48cd6e['id']);this['_revisionViewer']['compare'](_0x48cd6e,_0x4a2499);}}['_handleRevisionSelected'](_0x82de76,_0x17e826){const _0x2a8b82=this['_revisionsRepository']['getRevision'](_0x17e826['id']),_0x55a15a=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2a8b82['id']);this['_revisionViewer']['compare'](_0x2a8b82,_0x55a15a);}['_handleRevisionSetName'](_0xc75bf5,_0x5883b4){this['_revisionsRepository']['getRevision'](_0x5883b4['id'])['setName'](_0x5883b4['name']);}['_handleDiffChange'](_0x2cbdc5,_0x545e59,_0x70d2c){const _0x150240=this['_revisionsRepository']['getRevisionsInDiff'](_0x70d2c);_0x150240['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x150240),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x150240[0x0]));}['_createRevisionActions'](){const _0x18827f=this['editor'],_0x1bda1f=g['availableRevisionActions'],_0x441a30=_0x18827f['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x441a30['length'])return _0x441a30['map'](_0x3e7d39=>{const _0x22cc33='string'==typeof _0x3e7d39?Object['assign']({},_0x1bda1f[_0x3e7d39]):_0x3e7d39;return _0x22cc33['action']=_0x22cc33['action']['bind'](this,_0x18827f),_0x22cc33['isVisible']&&(_0x22cc33['isVisible']=_0x22cc33['isVisible']['bind'](this,_0x18827f)),_0x22cc33;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x5680fe},_0x5abe6b)=>{const _0x1c21cb=_0x5680fe['get'](d),_0x276c84=_0x1c21cb['repository'];let _0x311094=_0x1c21cb['diff']['newRevisionId'],_0xfc3c91=_0x5abe6b['id'];_0x276c84['getIndex'](_0x311094)>_0x276c84['getIndex'](_0xfc3c91)&&([_0x311094,_0xfc3c91]=[_0xfc3c91,_0x311094]),_0x1c21cb['compare'](_0x311094,_0xfc3c91);},'isVisible':({plugins:_0x3a4cd0},_0x3d8059)=>{const _0x23c8f6=_0x3a4cd0['get'](d);return!(_0x23c8f6['repository']['getRevisionsInDiff'](_0x23c8f6['diff'])['length']>0x2)&&!_0x3d8059['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x32455f,{id:_0x5195eb})=>{_0x32455f['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5195eb);},'isVisible':({plugins:_0x257127},_0x2f526a)=>!!_0x257127['get'](d)['repository']['getLaterVisibleRevision'](_0x2f526a['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x207c78},{id:_0x4156cf,revisionNameView:_0x4a3f9a})=>{const _0x398e79=_0x207c78['get'](d),_0x236c9f=_0x398e79['repository']['getEarlierVisibleRevision'](_0x4156cf);_0x398e79['compare'](_0x4156cf,_0x236c9f),_0x4a3f9a['focus'](),_0x4a3f9a['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x3dff0e,_0x344ef2){super(_0x3dff0e),this['_view']=_0x344ef2,this['_toolbarConfig']=ht(_0x3dff0e['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0xd07992){const _0x75f3d0=this['editor'],_0x49d28e=this['view'],_0x395fb2=_0x75f3d0['editing']['view'],_0x28bcb2=_0x49d28e['editable'],_0x493622=_0x395fb2['document']['getRoot']();_0x28bcb2['name']=_0x493622['rootName'],_0x49d28e['render']();const _0x58ffab=_0x28bcb2['element'];this['setEditableElement'](_0x28bcb2['name'],_0x58ffab),_0x49d28e['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x395fb2['attachDomRoot'](_0x58ffab),this['_elementReplacer']['replace'](_0xd07992,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x381656=this['view'],_0x10d13a=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x10d13a['detachDomRoot'](_0x381656['editable']['name']),_0x381656['destroy']();}['_initToolbar'](){const _0x2ecc8b=this['view'];_0x2ecc8b['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2ecc8b['stickyPanel']['limiterElement']=_0x2ecc8b['element'],_0x2ecc8b['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x73519})=>_0x73519),_0x2ecc8b['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2ecc8b['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x11e116,_0x23e98b,_0x210cb8={}){super(_0x11e116),this['stickyPanel']=new lt(_0x11e116),this['toolbar']=new nt(_0x11e116,{'shouldGroupWhenFull':_0x210cb8['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x11e116,_0x23e98b);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
+ rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4d2c80,_0x2a3456){super(_0x2a3456),this['sourceElement']=_0x4d2c80,this['model']['document']['createRoot']();const _0x2d94ee=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x2d94ee);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x10a7a1,_0xb0f3d9){const _0x346f56=new this(_0x10a7a1,_0xb0f3d9);return await _0x346f56['initPlugins'](),await _0x346f56['ui']['init'](_0x10a7a1),await _0x346f56['data']['init'](_0x346f56['config']['get']('initialData')||''),_0x346f56['fire']('ready'),_0x346f56;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x49e1b4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x117ed9){function _0x552bbe(_0x5bf4bf){return _0x5bf4bf['map'](_0x31d23c=>String['fromCharCode'](_0x31d23c))['join']('');}super(_0x117ed9),this['result']='end',_0x117ed9[_0x552bbe([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x552bbe([0x76,0x69,0x65,0x77])][_0x552bbe([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x552bbe([0x61,0x75,0x74,0x6f]),_0x117ed9[_0x552bbe([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x552bbe([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x552bbe([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x552bbe([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x552bbe([0x6f,0x6b])});}}class H extends _0x49e1b4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x1b1eeb){if(super(_0x1b1eeb),!this['editor']['config']['get']('revisionHistory'))throw new _0x51a18f('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x275b1d=>this['_showRevisionViewer']({..._0x275b1d,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x9d542d=>this['_closeRevisionViewer'](_0x9d542d)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x381244=>this['_restoreRevision'](_0x381244)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x23836d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x23836d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x145932){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x145932);}['getRevision'](_0x71065d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x71065d);}['getRevisions'](_0x1ec291){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x1ec291||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x59b405=this['editor'],_0x363a0d=_0x368ecc(_0x59b405,p),_0xa602c5=_0x59b405['plugins']['get']('RevisionTracker'),_0x1b275c=_0x59b405['plugins']['get']('Users')['users'];return _0x363a0d['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x363a0d['lazyRoots'],(_0x363a0d['plugins']['push'](k,d,m,class extends _0x49e1b4{static get['requires'](){return[d,'Users'];}['init'](){const _0x44491b=this['editor']['plugins']['get']('Users');for(const _0x5cdf4d of _0x1b275c)_0x5cdf4d['isAnonymous']||_0x44491b['getUser'](_0x5cdf4d['id'])||_0x44491b['addUser'](_0x5cdf4d);const _0x51a3f=_0xa602c5['repository']['getRevisions']();let _0xb19d78=null;const _0x88c7c=this['editor']['plugins']['get']('RevisionViewer');_0x88c7c['adapter']=_0xa602c5['adapter'],_0x88c7c['bind']('isEnabled')['to'](_0xa602c5),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x59b405,'isReadOnly',_0x47c774=>!_0x47c774);for(const _0x4ea9c3 of _0x51a3f){const _0x5702c9=null===_0x4ea9c3['creator'];if(_0x5702c9&&_0x4ea9c3['toVersion']===_0x4ea9c3['fromVersion'])continue;const _0xb43239=_0x4ea9c3['toJSON']();_0x88c7c['addRevisionData'](_0xb43239,(_0xd98443,_0x2eaabb,_0xb00ec3)=>{if(_0x5702c9){if(_0xb19d78)_0xb19d78['_update'](_0xd98443,_0x2eaabb);else{if(!_0x2eaabb){const _0x500622=_0xb00ec3['toJSON']();_0x500622['id']=_0x1c3ee2(),_0xa602c5['saveRevision'](_0x500622,_0xb00ec3['toVersion'])['then'](_0x5b9276=>{_0xb19d78=_0x5b9276;});}}}else _0x4ea9c3['_update'](_0xd98443,_0x2eaabb);});}}},g),_0x363a0d);}['_enhanceShowRevisionViewerCallback'](){const _0x4b7a45=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2d2792=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x3393dd=this['editor']['plugins']['get']('Autosave');await _0x3393dd['save']();}else await _0x2d2792['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x745aed=this['editor']['plugins']['get']('Dialog');_0x745aed['isOpen']&&_0x745aed['hide']();}const _0x14859f=this['_getRevisionViewerEditorConfig']();return _0x4b7a45(_0x14859f)['then'](_0x14ab1b=>{return(this['_viewerEditor']=_0x14ab1b,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x14ab1b;})['catch'](_0x1a35ac=>(console['error'](_0x1a35ac),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x277318=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'](),_0x277318(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x457ade=this['editor']['plugins']['get']('Annotations');_0x457ade['refreshVisibility'](),_0x457ade['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5db325){const _0x47cec9=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x520985=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x4eff55=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x4eff55,_0x5db325)['then'](_0x462054=>(_0x520985['style']['display']='block',_0x47cec9['style']['display']='none',_0x462054));}['_closeRevisionViewer'](_0x2afbc8){const _0x5d0ece=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x5d0ece['style']['display']='',_0x2afbc8['destroy']();}async['_restoreRevision'](_0x3a0652){const _0x5f0771=this['editor'],_0x1c2ad6=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x53a9fb=_0x5f0771['plugins']['get']('RevisionTracker'),_0xd010be=_0x1c2ad6['repository']['getRevision'](_0x3a0652);let _0xae90e,_0xcffc59,_0x33d015;try{_0xae90e=await _0x1c2ad6['getRevisionData'](_0xd010be),_0xcffc59=await _0x1c2ad6['getRevisionRootsAttributes'](_0xd010be);}catch(_0x48dfb2){return void console['error'](_0x48dfb2);}_0x5f0771['model']['change'](_0x19a294=>{for(const _0x2e40cb of Array['from'](_0x5f0771['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x19a294['removeMarker'](_0x2e40cb);}),_0x1c2ad6['isReady']=!0x1,_0x5f0771['model']['enqueueChange'](_0x220a85=>{_0x220a85['setSelection'](null),_0x220a85['removeSelectionAttribute'](_0x5f0771['model']['document']['selection']['getAttributeKeys']());const _0x56a2bd=Object['keys'](_0xae90e);for(const _0x3c5995 of _0x5f0771['model']['document']['roots'])'$graveyard'!=_0x3c5995['rootName']&&_0x3c5995['isAttached']()&&!_0x56a2bd['includes'](_0x3c5995['rootName'])&&_0x220a85['detachRoot'](_0x3c5995);for(const _0x59f59a of _0x56a2bd){let _0x457001=_0x5f0771['model']['document']['getRoot'](_0x59f59a);_0x457001&&_0x457001['isAttached']()||(_0x457001=_0x220a85['addRoot'](_0x59f59a));const _0x2a2477=_0xcffc59[_0x59f59a],_0x457495=Object['keys'](_0x2a2477),_0x51a42c=_0xae90e[_0x59f59a];for(const _0x5093f6 of _0x457001['getAttributeKeys']())_0x457495['includes'](_0x5093f6)||_0x220a85['removeAttribute'](_0x5093f6,_0x457001);for(const _0x48d3c4 of _0x457495)_0x220a85['setAttribute'](_0x48d3c4,_0xcffc59[_0x59f59a][_0x48d3c4],_0x457001);_0x220a85['remove'](_0x220a85['createRangeIn'](_0x457001)),_0x220a85['insert'](_0x5f0771['data']['parse'](_0x51a42c,_0x457001),_0x457001,0x0);}});const _0x246b08=R(_0x5f0771['locale'],'Restored');if(_0xd010be['name'])_0x33d015=-0x1==_0xd010be['name']['indexOf'](_0x246b08)?_0x246b08+':\x20'+_0xd010be['name']:_0xd010be['name'];else _0x33d015=_0x246b08+':\x20'+(_0xd010be['createdAt']['toLocaleDateString'](_0x5f0771['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xd010be['createdAt']['toLocaleTimeString'](_0x5f0771['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x53a9fb['saveRevision']({'name':_0x33d015}),_0x1c2ad6['isReady']=!0x0,_0x5f0771['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,de as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};