@ckeditor/ckeditor5-revision-history 44.2.0-alpha.13 → 44.2.0-alpha.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) hide show
  1. package/build/revision-history.js +1 -1
  2. package/dist/index.js +6 -6
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/bg.js +1 -1
  12. package/dist/translations/bg.umd.js +1 -1
  13. package/dist/translations/bn.js +1 -1
  14. package/dist/translations/bn.umd.js +1 -1
  15. package/dist/translations/bs.js +1 -1
  16. package/dist/translations/bs.umd.js +1 -1
  17. package/dist/translations/ca.js +1 -1
  18. package/dist/translations/ca.umd.js +1 -1
  19. package/dist/translations/cs.js +1 -1
  20. package/dist/translations/cs.umd.js +1 -1
  21. package/dist/translations/da.js +1 -1
  22. package/dist/translations/da.umd.js +1 -1
  23. package/dist/translations/de-ch.js +1 -1
  24. package/dist/translations/de-ch.umd.js +1 -1
  25. package/dist/translations/de.js +1 -1
  26. package/dist/translations/de.umd.js +1 -1
  27. package/dist/translations/el.js +1 -1
  28. package/dist/translations/el.umd.js +1 -1
  29. package/dist/translations/en-au.js +1 -1
  30. package/dist/translations/en-au.umd.js +1 -1
  31. package/dist/translations/en-gb.js +1 -1
  32. package/dist/translations/en-gb.umd.js +1 -1
  33. package/dist/translations/en.js +1 -1
  34. package/dist/translations/en.umd.js +1 -1
  35. package/dist/translations/eo.js +1 -1
  36. package/dist/translations/eo.umd.js +1 -1
  37. package/dist/translations/es-co.js +1 -1
  38. package/dist/translations/es-co.umd.js +1 -1
  39. package/dist/translations/es.js +1 -1
  40. package/dist/translations/es.umd.js +1 -1
  41. package/dist/translations/et.js +1 -1
  42. package/dist/translations/et.umd.js +1 -1
  43. package/dist/translations/eu.js +1 -1
  44. package/dist/translations/eu.umd.js +1 -1
  45. package/dist/translations/fa.js +1 -1
  46. package/dist/translations/fa.umd.js +1 -1
  47. package/dist/translations/fi.js +1 -1
  48. package/dist/translations/fi.umd.js +1 -1
  49. package/dist/translations/fr.js +1 -1
  50. package/dist/translations/fr.umd.js +1 -1
  51. package/dist/translations/gl.js +1 -1
  52. package/dist/translations/gl.umd.js +1 -1
  53. package/dist/translations/gu.js +1 -1
  54. package/dist/translations/gu.umd.js +1 -1
  55. package/dist/translations/he.js +1 -1
  56. package/dist/translations/he.umd.js +1 -1
  57. package/dist/translations/hi.js +1 -1
  58. package/dist/translations/hi.umd.js +1 -1
  59. package/dist/translations/hr.js +1 -1
  60. package/dist/translations/hr.umd.js +1 -1
  61. package/dist/translations/hu.js +1 -1
  62. package/dist/translations/hu.umd.js +1 -1
  63. package/dist/translations/hy.js +1 -1
  64. package/dist/translations/hy.umd.js +1 -1
  65. package/dist/translations/id.js +1 -1
  66. package/dist/translations/id.umd.js +1 -1
  67. package/dist/translations/it.js +1 -1
  68. package/dist/translations/it.umd.js +1 -1
  69. package/dist/translations/ja.js +1 -1
  70. package/dist/translations/ja.umd.js +1 -1
  71. package/dist/translations/jv.js +1 -1
  72. package/dist/translations/jv.umd.js +1 -1
  73. package/dist/translations/kk.js +1 -1
  74. package/dist/translations/kk.umd.js +1 -1
  75. package/dist/translations/km.js +1 -1
  76. package/dist/translations/km.umd.js +1 -1
  77. package/dist/translations/kn.js +1 -1
  78. package/dist/translations/kn.umd.js +1 -1
  79. package/dist/translations/ko.js +1 -1
  80. package/dist/translations/ko.umd.js +1 -1
  81. package/dist/translations/ku.js +1 -1
  82. package/dist/translations/ku.umd.js +1 -1
  83. package/dist/translations/lt.js +1 -1
  84. package/dist/translations/lt.umd.js +1 -1
  85. package/dist/translations/lv.js +1 -1
  86. package/dist/translations/lv.umd.js +1 -1
  87. package/dist/translations/ms.js +1 -1
  88. package/dist/translations/ms.umd.js +1 -1
  89. package/dist/translations/nb.js +1 -1
  90. package/dist/translations/nb.umd.js +1 -1
  91. package/dist/translations/ne.js +1 -1
  92. package/dist/translations/ne.umd.js +1 -1
  93. package/dist/translations/nl.js +1 -1
  94. package/dist/translations/nl.umd.js +1 -1
  95. package/dist/translations/no.js +1 -1
  96. package/dist/translations/no.umd.js +1 -1
  97. package/dist/translations/oc.js +1 -1
  98. package/dist/translations/oc.umd.js +1 -1
  99. package/dist/translations/pl.js +1 -1
  100. package/dist/translations/pl.umd.js +1 -1
  101. package/dist/translations/pt-br.js +1 -1
  102. package/dist/translations/pt-br.umd.js +1 -1
  103. package/dist/translations/pt.js +1 -1
  104. package/dist/translations/pt.umd.js +1 -1
  105. package/dist/translations/ro.js +1 -1
  106. package/dist/translations/ro.umd.js +1 -1
  107. package/dist/translations/ru.js +1 -1
  108. package/dist/translations/ru.umd.js +1 -1
  109. package/dist/translations/si.js +1 -1
  110. package/dist/translations/si.umd.js +1 -1
  111. package/dist/translations/sk.js +1 -1
  112. package/dist/translations/sk.umd.js +1 -1
  113. package/dist/translations/sl.js +1 -1
  114. package/dist/translations/sl.umd.js +1 -1
  115. package/dist/translations/sq.js +1 -1
  116. package/dist/translations/sq.umd.js +1 -1
  117. package/dist/translations/sr-latn.js +1 -1
  118. package/dist/translations/sr-latn.umd.js +1 -1
  119. package/dist/translations/sr.js +1 -1
  120. package/dist/translations/sr.umd.js +1 -1
  121. package/dist/translations/sv.js +1 -1
  122. package/dist/translations/sv.umd.js +1 -1
  123. package/dist/translations/th.js +1 -1
  124. package/dist/translations/th.umd.js +1 -1
  125. package/dist/translations/ti.js +1 -1
  126. package/dist/translations/ti.umd.js +1 -1
  127. package/dist/translations/tk.js +1 -1
  128. package/dist/translations/tk.umd.js +1 -1
  129. package/dist/translations/tr.js +1 -1
  130. package/dist/translations/tr.umd.js +1 -1
  131. package/dist/translations/tt.js +1 -1
  132. package/dist/translations/tt.umd.js +1 -1
  133. package/dist/translations/ug.js +1 -1
  134. package/dist/translations/ug.umd.js +1 -1
  135. package/dist/translations/uk.js +1 -1
  136. package/dist/translations/uk.umd.js +1 -1
  137. package/dist/translations/ur.js +1 -1
  138. package/dist/translations/ur.umd.js +1 -1
  139. package/dist/translations/uz.js +1 -1
  140. package/dist/translations/uz.umd.js +1 -1
  141. package/dist/translations/vi.js +1 -1
  142. package/dist/translations/vi.umd.js +1 -1
  143. package/dist/translations/zh-cn.js +1 -1
  144. package/dist/translations/zh-cn.umd.js +1 -1
  145. package/dist/translations/zh.js +1 -1
  146. package/dist/translations/zh.umd.js +1 -1
  147. package/package.json +10 -10
  148. package/src/changeitem.js +2 -2
  149. package/src/editor/revisionviewereditor.js +2 -2
  150. package/src/editor/revisionviewereditorui.js +1 -1
  151. package/src/editor/revisionviewereditoruiview.js +1 -1
  152. package/src/index.js +1 -1
  153. package/src/revision.js +2 -2
  154. package/src/revisiondiff.js +1 -1
  155. package/src/revisionhistory.js +1 -1
  156. package/src/revisionsrepository.js +1 -1
  157. package/src/revisiontracker.js +1 -1
  158. package/src/revisionviewer.js +1 -1
  159. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  160. package/src/ui/revision/revisionauthorview.js +1 -1
  161. package/src/ui/revision/revisionnameview.js +1 -1
  162. package/src/ui/revision/revisionview.js +2 -2
  163. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  164. package/src/ui/revision/subrevisionview.js +1 -1
  165. package/src/ui/revision/utils.js +1 -1
  166. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  167. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  168. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  169. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  170. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  172. package/src/ui/revisionssidebar/utils.js +1 -1
  173. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  174. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  175. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  176. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  177. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x116fa3,uid as _0x4813fb,Collection as _0x332746,logWarning as _0x4238c3,FocusTracker as _0x28c48b,KeystrokeHandler as _0x5f4f2d,scrollViewportToShowTarget as _0x69e4b0,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x2e39c8}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x36027d,set as _0x5a66e9,unset as _0x39fe82,isEqual as _0x133c61}from'lodash-es';import{Plugin as _0x47f245,PendingActions as _0x4eecd5,icons as _0x1018a7,Command as _0x5a4468,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x5f1544,getMarkerDomElement as _0x4a8ca9,ConfirmMixin as _0x2a5179,sanitizeEditorConfig as _0x31b616}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x41a6bf,Element as ft,Range as vt,ViewUIElement as _0x564fc7,ViewRawElement as _0x10bd14,ViewEmptyElement as _0x52b095,ViewAttributeElement as _0x3e1147,ViewContainerElement as _0x518472,Position as gt,ViewText as _0x2bf8d1,ViewElement as _0x150663,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x12ccec,injectCssTransitionDisabler as ts,submitHandler as _0x3dffdf,LabeledFieldView as nt,createLabeledInputText as _0x2956bd,createDropdown as _0x2e0b5d,ListView as te,ListItemView as _0x5300ff,ButtonView as _0x1e9806,MenuBarMenuView as _0x5d993f,MenuBarMenuListView as _0x1a39a8,MenuBarMenuListItemView as _0x5ddf95,MenuBarMenuListItemButtonView as _0x1dee65,ContextualBalloon as _0x2d6f89,ToolbarSeparatorView as _0x48992c,IconView as _0x1aa1d0,addListToDropdown as _0x462102,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as ut,ToolbarView as lt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x150ab6}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
- _0x116fa3(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x406c4c){super(),this['id']=_0x406c4c['id']||_0x4813fb(),this['creator']=_0x406c4c['creator']||null,this['authors']=_0x406c4c['authors']||[],this['diffData']=_0x406c4c['diffData']||null,this['toVersion']=_0x406c4c['toVersion']||0x0,this['fromVersion']=_0x406c4c['fromVersion']||0x0,this['set']('name',_0x406c4c['name']||''),this['set']('createdAt',_0x406c4c['createdAt']||new Date()),this['set']('attributes',_0x406c4c['attributes']||{});}['setName'](_0x7c00c7){this['_update']({'name':_0x7c00c7});}['setAttribute'](_0x582cf,_0x48f73d){const _0x43f66c=_0x36027d(this['attributes']);_0x5a66e9(_0x43f66c,_0x582cf,_0x48f73d),this['_update']({'attributes':_0x43f66c});}['removeAttribute'](_0x7d0641){const _0x1aeca2=_0x36027d(this['attributes']);_0x39fe82(_0x1aeca2,_0x7d0641),this['_update']({'attributes':_0x1aeca2});}['_update'](_0x34704e,_0x984b90=!0x1){let _0x288286=!0x1;const _0x3a88f8={'id':this['id']},_0x211161=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4b726c of _0x211161){const _0x3fbdff=_0x34704e[_0x4b726c];void 0x0!==_0x3fbdff&&_0x3fbdff!==this[_0x4b726c]&&(this[_0x4b726c]=_0x3fbdff,_0x3a88f8[_0x4b726c]=_0x3fbdff,_0x288286=!0x0);}_0x288286&&(_0x3a88f8['authors']&&(_0x3a88f8['authorsIds']=_0x3a88f8['authors']['map'](_0x3819fd=>_0x3819fd['id']),delete _0x3a88f8['authors']),this['fire']('_update',_0x3a88f8,_0x984b90));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x442743=>_0x442743['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x47f245{['_revisions'];static get['requires'](){return[_0x5f1544];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5bbfe0){super(_0x5bbfe0),this['_revisions']=new _0x332746();}['afterInit'](){!async function(_0x245e1b){const _0x3165c3=_0xf91279([0x77,0x4d,0x56,0x71,0x4b,0x52,0x53,0x5a,0x35,0x4a,0x76,0x30,0x4c,0x58,0x63,0x79,0x4e,0x72,0x74,0x34,0x66,0x48,0x62,0x37,0x6e,0x55,0x33,0x44,0x65,0x59,0x6f,0x51,0x78,0x68,0x45,0x39,0x36,0x6a,0x41,0x38,0x73,0x64,0x6d,0x70,0x46,0x49,0x32,0x43,0x47,0x6c,0x54,0x6b,0x61,0x42,0x57,0x50,0x31,0x67,0x69,0x7a,0x4f,0x75]),_0x1c83fa=0xeb829,_0x5a337c=0x4b273ae3,_0x54f1f2=0x4b2065e3^_0x5a337c,_0x540164=window[_0xf91279([0x44,0x61,0x74,0x65])][_0xf91279([0x6e,0x6f,0x77])](),_0x124456=_0x245e1b[_0xf91279([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2e2a64=new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4c3465=>{_0x124456[_0xf91279([0x6f,0x6e,0x63,0x65])](_0xf91279([0x72,0x65,0x61,0x64,0x79]),_0x4c3465);}),_0x478a40={[_0xf91279([0x6b,0x74,0x79])]:_0xf91279([0x45,0x43]),[_0xf91279([0x75,0x73,0x65])]:_0xf91279([0x73,0x69,0x67]),[_0xf91279([0x63,0x72,0x76])]:_0xf91279([0x50,0x2d,0x32,0x35,0x36]),[_0xf91279([0x78])]:_0xf91279([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]),[_0xf91279([0x79])]:_0xf91279([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]),[_0xf91279([0x61,0x6c,0x67])]:_0xf91279([0x45,0x53,0x32,0x35,0x36])},_0x4fbd0c=_0x124456[_0xf91279([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xf91279([0x67,0x65,0x74])](_0xf91279([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x416193(){let _0x3951d8,_0x29656d=null,_0x307d97=null;try{if(_0x4fbd0c==_0xf91279([0x47,0x50,0x4c]))return _0xf91279([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3951d8=_0x2a7188(),!_0x3951d8)return _0xf91279([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3951d8[_0xf91279([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x307d97=_0x2cdaca(_0x3951d8[_0xf91279([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3951d8[_0xf91279([0x6a,0x74,0x69])])),await _0x113b34()?_0x5d901a()?_0x647106()?_0xf91279([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1d5761()?(_0x3951d8[_0xf91279([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xf91279([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x29656d=_0x7a18c3(_0xf91279([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3951d8[_0xf91279([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xf91279([0x74,0x72,0x69,0x61,0x6c])&&(_0x29656d=_0x7a18c3(_0xf91279([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0xbc4a22()):_0xf91279([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xf91279([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xf91279([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x1534d7){return _0xf91279([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x647106(){const _0x318a32=[_0xf91279([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xf91279([0x74,0x72,0x69,0x61,0x6c])][_0xf91279([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3951d8[_0xf91279([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x540164/0x3e8:0xe10*_0x54f1f2;return _0x3951d8[_0xf91279([0x65,0x78,0x70])]<_0x318a32;}function _0x5d901a(){const _0x4f95ab=_0x3951d8[_0xf91279([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4f95ab)return!0x1;if(_0x4f95ab[_0xf91279([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xf91279([0x2a])))return!0x0;if(_0x4f95ab[_0xf91279([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xf91279([0x52,0x48])))return!0x0;if(_0x4f95ab[_0xf91279([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xf91279([0x52,0x52,0x48]))){if(_0x1f04b9())return!0x0;if(_0xf7f0ac()||_0x2421db())return!0x0;}return!0x1;}function _0x1d5761(){const _0x2fed1a=_0x3951d8[_0xf91279([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2fed1a||0x0==_0x2fed1a[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x241f30}=new URL(window[_0xf91279([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2fed1a[_0xf91279([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x241f30))return!0x0;const _0x13a212=_0x241f30[_0xf91279([0x73,0x70,0x6c,0x69,0x74])](_0xf91279([0x2e]));return _0x2fed1a[_0xf91279([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xc78b35=>_0xc78b35[_0xf91279([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xf91279([0x2a])))[_0xf91279([0x6d,0x61,0x70])](_0x46e46e=>_0x46e46e[_0xf91279([0x73,0x70,0x6c,0x69,0x74])](_0xf91279([0x2e])))[_0xf91279([0x73,0x6f,0x6d,0x65])](_0x269985=>_0x13a212[_0xf91279([0x65,0x76,0x65,0x72,0x79])]((_0x30c7a2,_0x2079bf)=>_0x269985[_0x2079bf]===_0x30c7a2||_0x269985[_0x2079bf]===_0xf91279([0x2a])));}function _0xbc4a22(){return _0x29656d&&_0x307d97?new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xcac0f5,_0x2afc7e)=>{_0x29656d[_0xf91279([0x74,0x68,0x65,0x6e])](_0xcac0f5,_0x2afc7e),_0x307d97[_0xf91279([0x74,0x68,0x65,0x6e])](_0xb75312=>{_0xb75312!=_0xf91279([0x56,0x61,0x6c,0x69,0x64])&&_0xcac0f5(_0xb75312);},_0x2afc7e);}):_0x29656d||_0x307d97||_0xf91279([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2cdaca(_0x1ec1b3,_0x2bb8c7){return new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x29502c=>{if(_0x228df1())return _0x29502c(_0xf91279([0x56,0x61,0x6c,0x69,0x64]));_0x3bc08f(),_0x124456[_0xf91279([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xf91279([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x59001b=!0x1;const _0x1cd6fa=_0x4813fb();function _0x4e6bf4(_0x10f04b){return!!_0x10f04b&&(typeof _0x10f04b===_0xf91279([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x10f04b===_0xf91279([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x10f04b[_0xf91279([0x74,0x68,0x65,0x6e])]===_0xf91279([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x10f04b[_0xf91279([0x63,0x61,0x74,0x63,0x68])]===_0xf91279([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2f48dd(_0x223e32){_0xdb413(_0x223e32)[_0xf91279([0x74,0x68,0x65,0x6e])](_0x4e3fdd=>{if(!_0x4e3fdd||_0x4e3fdd[_0xf91279([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xf91279([0x6f,0x6b]))return _0xf91279([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xff94c0(_0x165019(_0x1cd6fa+_0x2bb8c7))!=_0x4e3fdd[_0xf91279([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xf91279([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xf91279([0x56,0x61,0x6c,0x69,0x64]);})[_0xf91279([0x74,0x68,0x65,0x6e])](_0x4d4ce1=>(_0x3b90cf(),_0x4d4ce1),()=>{const _0x18fe7a=_0x48668d();return null==_0x18fe7a?(_0x3b90cf(),_0xf91279([0x56,0x61,0x6c,0x69,0x64])):_0xf91279(_0x540164-_0x18fe7a>(0x6f2bbee3^_0x5a337c)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xf91279([0x74,0x68,0x65,0x6e])](_0x29502c)[_0xf91279([0x63,0x61,0x74,0x63,0x68])](()=>{_0x29502c(_0xf91279([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x82f571=0x4b11d463^_0x5a337c;function _0x3b90cf(){const _0x7d11cb=_0xf91279([0x6c,0x6c,0x63,0x74,0x2d])+_0xff94c0(_0x165019(_0x1ec1b3)),_0x26d62d=_0xc06e54(_0xff94c0(window[_0xf91279([0x4d,0x61,0x74,0x68])][_0xf91279([0x63,0x65,0x69,0x6c])](_0x540164/_0x82f571)));window[_0xf91279([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xf91279([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x7d11cb,_0x26d62d);}function _0x48668d(){const _0x583f0a=_0xf91279([0x6c,0x6c,0x63,0x74,0x2d])+_0xff94c0(_0x165019(_0x1ec1b3)),_0x5341a8=window[_0xf91279([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xf91279([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x583f0a);return _0x5341a8?window[_0xf91279([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xc06e54(_0x5341a8),0x10)*_0x82f571:null;}function _0xdb413(_0x2a2725){return new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3365f7,_0x264584)=>{_0x2a2725[_0xf91279([0x74,0x68,0x65,0x6e])](_0x3365f7,_0x264584),window[_0xf91279([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x264584,0x4b26ee23^_0x5a337c);});}}_0x124456[_0xf91279([0x6f,0x6e])](_0xf91279([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x677b0,_0x5f3b5b)=>{if(_0x5f3b5b[0x0]!=_0x1ec1b3)return _0x29502c(_0xf91279([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5f3b5b[0x1]={..._0x5f3b5b[0x1],[_0xf91279([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1cd6fa};},{[_0xf91279([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xf91279([0x68,0x69,0x67,0x68])}),_0x124456[_0xf91279([0x6f,0x6e])](_0xf91279([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xd20951=>{_0x4e6bf4(_0xd20951[_0xf91279([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x59001b=!0x0,_0x2f48dd(_0xd20951[_0xf91279([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xf91279([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xf91279([0x6c,0x6f,0x77])}),_0x2e2a64[_0xf91279([0x74,0x68,0x65,0x6e])](()=>{_0x59001b||_0x29502c(_0xf91279([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x228df1(){return _0x124456[_0xf91279([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xf91279([0x76,0x69,0x65,0x77])][_0xf91279([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xf91279([0x61,0x75,0x74,0x6f]);}function _0x3bc08f(){_0x124456[_0xf91279([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xf91279([0x76,0x69,0x65,0x77])][_0xf91279([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xf91279([0x61,0x75,0x74,0x6f]);}}function _0x7a18c3(_0x1903a5){const _0x5d5843=[new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xe7ab00=>setTimeout(_0xe7ab00,0x4b2e042f^_0x5a337c)),_0x2e2a64[_0xf91279([0x74,0x68,0x65,0x6e])](()=>new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x214f7d=>{const _0x38b7f5=0x4b273ae4^_0x5a337c,_0x3d5a3f=_0x245e1b[_0xf91279([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x420cc8(){_0x3d5a3f[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x38b7f5&&_0x214f7d();}_0x420cc8(),_0x3d5a3f[_0xf91279([0x6f,0x6e])](_0xf91279([0x61,0x64,0x64]),_0x420cc8);})),new window[(_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xcacbfc=>{function _0x4ba899(){for(const _0x238471 in window)if(window[_0xf91279([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0xf91279([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x238471))&&window[_0x238471]==_0x1c83fa)return _0xcacbfc();_0x124456[_0xf91279([0x73,0x74,0x61,0x74,0x65])]!=_0xf91279([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0xf91279([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4ba899,0x4b27296b^_0x5a337c);}_0x1b02dc(_0xf91279([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4ba899();})];return window[_0xf91279([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xf91279([0x72,0x61,0x63,0x65])](_0x5d5843)[_0xf91279([0x74,0x68,0x65,0x6e])](()=>_0x1903a5);}async function _0x26b3db(){if(await _0x2e2a64,_0x1b02dc(_0xf91279([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3f4594=_0x245e1b[_0xf91279([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4ca34b=_0x245e1b[_0xf91279([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])](_0x3f4594[_0xf91279([0x69,0x64])]),_0x37f528=_0x31c5f1(_0xf91279([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x37f528[_0xf91279([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3f4594['id'],_0x4ca34b?_0x4ca34b['id']:null,!0x0),_0x37f528[_0xf91279([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xf91279([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x37f528[_0xf91279([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x37f528[_0xf91279([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x4cb09a,void(_0x37f528[_0xf91279([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x4cb09a);}if(_0x1b02dc(_0xf91279([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0xb97a8d=_0x31c5f1(_0xf91279([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0xb97a8d[_0xf91279([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xf91279([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xb97a8d[_0xf91279([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xb97a8d[_0xf91279([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x4cb09a,_0xb97a8d[_0xf91279([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x4cb09a;}_0x124456[_0xf91279([0x6d,0x6f,0x64,0x65,0x6c])][_0xf91279([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4cb09a,_0x124456[_0xf91279([0x6d,0x6f,0x64,0x65,0x6c])][_0xf91279([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4cb09a,_0x124456[_0xf91279([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xf91279([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1f04b9(){return _0x1b02dc(_0xf91279([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x31c5f1(_0xf91279([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0xf91279([0x73,0x74,0x61,0x74,0x65])]==_0xf91279([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0xf7f0ac(){return _0x1b02dc(_0xf91279([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 _0x2421db(){return _0x1b02dc(_0xf91279([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x585c2a(_0x4072be){const _0x26a8c2=_0x20747b();_0x124456[_0x26a8c2]=_0xf91279([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])+_0x4072be,_0x4072be[_0xf91279([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0xf91279([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x20747b()]=_0x1c83fa),_0x4072be!=_0xf91279([0x56,0x61,0x6c,0x69,0x64])&&_0x26b3db();}function _0x20747b(){const _0x107023=window[_0xf91279([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xf91279([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xf91279([0x6e,0x6f,0x77])]())[_0xf91279([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xf91279([0x2e]),'');let _0x1103ee=_0xf91279([0x77]);for(let _0x1d181a=0x0;_0x1d181a<_0x107023[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1d181a+=0x2){let _0x19e117=window[_0xf91279([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x107023[_0xf91279([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1d181a,_0x1d181a+0x2));_0x19e117>=_0x3165c3[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x19e117-=_0x3165c3[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1103ee+=_0x3165c3[_0x19e117];}return _0x1103ee;}function _0x2a7188(){const _0x46223e=_0x4fbd0c[_0xf91279([0x73,0x70,0x6c,0x69,0x74])](_0xf91279([0x2e]));if(0x3!=_0x46223e[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2f7a23(_0x46223e[0x1]);function _0x2f7a23(_0x536c4a){const _0xf322e=_0x5f4b84(_0x536c4a);return _0xf322e&&_0x27a348()?_0xf322e:null;function _0x27a348(){const _0x274f4c=_0xf322e[_0xf91279([0x6a,0x74,0x69])],_0x295128=window[_0xf91279([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x274f4c[_0xf91279([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x274f4c[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x19eee8={..._0xf322e,[_0xf91279([0x6a,0x74,0x69])]:_0x274f4c[_0xf91279([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x274f4c[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x19eee8[_0xf91279([0x76,0x63])],_0x165019(_0x19eee8)==_0x295128;}}}async function _0x113b34(){let _0x592cf0=!0x0;try{const _0xb25bd3=_0x4fbd0c[_0xf91279([0x73,0x70,0x6c,0x69,0x74])](_0xf91279([0x2e])),[_0x23df63,_0x4ea601,_0x141a4b]=_0xb25bd3;return _0x3b4be3(_0x23df63),await _0x149ebb(_0x23df63,_0x4ea601,_0x141a4b),_0x592cf0;}catch(_0x236cb2){return!0x1;}function _0x3b4be3(_0x54d895){const _0x1f9133=_0x5f4b84(_0x54d895);_0x1f9133&&_0x1f9133[_0xf91279([0x61,0x6c,0x67])]==_0xf91279([0x45,0x53,0x32,0x35,0x36])||(_0x592cf0=!0x1);}async function _0x149ebb(_0x2877a8,_0x20409f,_0x25ad63){const _0x84a09f=window[_0xf91279([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xf91279([0x66,0x72,0x6f,0x6d])](_0x153b98(_0x25ad63),_0x3293fc=>_0x3293fc[_0xf91279([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3d9a3c=new window[(_0xf91279([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xf91279([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2877a8+_0xf91279([0x2e])+_0x20409f),_0x14acff=window[_0xf91279([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xf91279([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x14acff)return;const _0x4b0873=await _0x14acff[_0xf91279([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xf91279([0x6a,0x77,0x6b]),_0x478a40,{[_0xf91279([0x6e,0x61,0x6d,0x65])]:_0xf91279([0x45,0x43,0x44,0x53,0x41]),[_0xf91279([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xf91279([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xf91279([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x14acff[_0xf91279([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xf91279([0x6e,0x61,0x6d,0x65])]:_0xf91279([0x45,0x43,0x44,0x53,0x41]),[_0xf91279([0x68,0x61,0x73,0x68])]:{[_0xf91279([0x6e,0x61,0x6d,0x65])]:_0xf91279([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4b0873,_0x84a09f,_0x3d9a3c)||(_0x592cf0=!0x1);}}function _0x5f4b84(_0x26fa08){return _0x26fa08[_0xf91279([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xf91279([0x65,0x79]))?JSON[_0xf91279([0x70,0x61,0x72,0x73,0x65])](_0x153b98(_0x26fa08)):null;}function _0x153b98(_0x4179e4){return window[_0xf91279([0x61,0x74,0x6f,0x62])](_0x4179e4[_0xf91279([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xf91279([0x2b]))[_0xf91279([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xf91279([0x2f])));}function _0x165019(_0x76fa28){let _0x3948a1=0x1505;function _0x1f1540(_0xf68a8c){for(let _0x35d09b=0x0;_0x35d09b<_0xf68a8c[_0xf91279([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x35d09b++){const _0x29a08f=_0xf68a8c[_0xf91279([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x35d09b);_0x3948a1=(_0x3948a1<<0x5)+_0x3948a1+_0x29a08f,_0x3948a1&=_0x3948a1;}}function _0x426f0c(_0x1a9f91){Array[_0xf91279([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1a9f91)?_0x1a9f91[_0xf91279([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x426f0c):_0x1a9f91&&typeof _0x1a9f91==_0xf91279([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xf91279([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1a9f91)[_0xf91279([0x73,0x6f,0x72,0x74])]()[_0xf91279([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x529960,_0x12824b])=>{_0x1f1540(_0x529960),_0x426f0c(_0x12824b);}):_0x1f1540(window[_0xf91279([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1a9f91));}return _0x426f0c(_0x76fa28),_0x3948a1>>>0x0;}function _0xff94c0(_0x26e459){return _0x26e459[_0xf91279([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xf91279([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xf91279([0x30]));}function _0xc06e54(_0x4a5d46){return _0x4a5d46[_0xf91279([0x73,0x70,0x6c,0x69,0x74])]('')[_0xf91279([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xf91279([0x6a,0x6f,0x69,0x6e])]('');}function _0x1b02dc(_0x50ca55){return _0x124456[_0xf91279([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xf91279([0x68,0x61,0x73])](_0x50ca55);}function _0x31c5f1(_0x28673b){return _0x124456[_0xf91279([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xf91279([0x67,0x65,0x74])](_0x28673b);}function _0x4cb09a(){}function _0xf91279(_0x383606){return _0x383606['map'](_0x39ed72=>String['fromCharCode'](_0x39ed72))['join']('');}_0x585c2a(await _0x416193());}(this);}['createRevision'](_0x100278){const _0x2dc756=this['editor']['plugins']['get']('Users');return new a({'id':_0x100278['id'],'name':_0x100278['name'],'creator':_0x100278['creatorId']?_0x2dc756['getUser'](_0x100278['creatorId']):null,'diffData':_0x100278['diffData']||_0x100278['data'],'authors':_0x100278['authorsIds']['map'](_0x5a0324=>_0x2dc756['getUser'](_0x5a0324)),'createdAt':new Date(_0x100278['createdAt']),'attributes':_0x100278['attributes'],'fromVersion':_0x100278['fromVersion'],'toVersion':_0x100278['toVersion']});}['addRevision'](_0x4f2aa5,_0x41db5b=0x0){this['_revisions']['add'](_0x4f2aa5,_0x41db5b);}['getRevision'](_0x2f1d54){return this['_revisions']['get'](_0x2f1d54);}['getRevisions'](_0x3db78e={'toJSON':!0x1}){const _0x4902a4=Array['from'](this['_revisions']);return _0x4902a4['reverse'](),_0x3db78e['toJSON']?_0x4902a4['map'](_0x15fdb2=>_0x15fdb2['toJSON']()):_0x4902a4;}['getIndex'](_0x61807f){return this['_revisions']['getIndex'](_0x61807f);}['getEarlierVisibleRevision'](_0x349ec6){const [,_0xa52310]=this['getRevisionsIterator'](_0x349ec6,{'direction':'earlier'});return _0xa52310;}['getLaterVisibleRevision'](_0x1e15ef){const [,_0x539790]=this['getRevisionsIterator'](_0x1e15ef,{'direction':'later'});return _0x539790;}['getRevisionsInDiff'](_0x3139b4){const _0x1d5feb=[];for(const _0x14570e of this['getRevisionsIterator'](_0x3139b4['newRevisionId']))if(_0x1d5feb['push'](_0x14570e),_0x14570e['id']===_0x3139b4['oldRevisionId'])break;return _0x1d5feb;}*['getRevisionsIterator'](_0x1722b5,{direction:_0x1b71cb='earlier',filter:_0x21f8e3=()=>!0x0}={}){const _0x58d057='earlier'===_0x1b71cb?0x1:-0x1;let _0x5cff8d=this['_revisions']['get'](_0x1722b5),_0x618df2=this['getIndex'](_0x5cff8d);for(yield _0x5cff8d;_0x5cff8d;){if(_0x618df2+=_0x58d057,_0x5cff8d=this['getRevision'](_0x618df2),!_0x5cff8d)return;_0x21f8e3(_0x5cff8d)&&(yield _0x5cff8d);}}}function m(_0x1cad3c,_0x39403f,_0x58461c){const t=_0x1cad3c['t'];switch(_0x39403f){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'},_0x58461c);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x58461c);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const P={'c':_0x518472,'a':_0x3e1147,'e':_0x52b095,'r':_0x10bd14,'u':_0x564fc7};class l extends _0x47f245{['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[_0x5f1544,j,_0x4eecd5];}constructor(_0x47ebc5){super(_0x47ebc5),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0xb85ab7=_0x4813fb();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0xb85ab7},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 _0x53fee6=this['repository']['getRevision'](0x0),_0x2ee0d3=_0x53fee6&&null===_0x53fee6['creator']?_0x53fee6:null;if(this['_continueCurrentRevision']=!!_0x2ee0d3&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x537b81=this['_source']['getCurrentRevisionId'](),_0x3540e4=this['repository']['getRevision'](_0x537b81);if(_0x3540e4)this['_startingVersion']=_0x3540e4['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1b64f6=this['_source']['history']['_operations']['find'](_0x1147ad=>!_0x1147ad['_isInit']),_0x4f3365=_0x1b64f6?_0x1b64f6['baseVersion']:this['_source']['history']['version'];_0x53fee6?(_0x53fee6['toVersion']<_0x4f3365&&_0x53fee6['_update']({'toVersion':_0x4f3365}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x2ee0d3['id'],this['_startingVersion']=_0x2ee0d3['fromVersion']):(this['_startingVersion']=_0x53fee6['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4f3365,this['_continueCurrentRevision']=!0x1);}}else _0x2ee0d3&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x2ee0d3['toVersion'],this['editor']['model']['document']['history']['version']),_0x2ee0d3['fromVersion']===_0x2ee0d3['toVersion']?(0x0!==_0x2ee0d3['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x2ee0d3['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x2ee0d3['id'],this['_startingVersion']=_0x2ee0d3['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',_0x5204d8=>!_0x5204d8),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2611d5=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x41ddb4;for(const _0x416f31 in _0x2611d5){const _0x2d63c4=_0x416f31,_0x59ce8b=_0x2611d5[_0x2d63c4];if('revisionHistoryLicenseKeyValid'==_0x59ce8b||'revisionHistoryLicenseKeyInvalid'==_0x59ce8b||'revisionHistoryLicenseKeyExpired'==_0x59ce8b||'revisionHistoryLicenseKeyDomainLimit'==_0x59ce8b||'revisionHistoryLicenseKeyNotAllowed'==_0x59ce8b||'revisionHistoryLicenseKeyEvaluationLimit'==_0x59ce8b||'revisionHistoryLicenseKeyTrialLimit'==_0x59ce8b||'revisionHistoryLicenseKeyUsageLimit'==_0x59ce8b){delete _0x2611d5[_0x2d63c4],_0x41ddb4=_0x59ce8b,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x41ddb4&&_0x2611d5['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x41ddb4&&_0x2611d5['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x41ddb4&&_0x2611d5['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x41ddb4&&_0x2611d5['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x41ddb4&&_0x2611d5['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x41ddb4&&_0x2611d5['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x41ddb4&&_0x2611d5['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0xd7712b=this['repository']['getRevision'](0x0),_0x171c40=await this['getRevisionDocumentData'](_0xd7712b),_0x5b11a4=await this['getRevisionRootsAttributes'](_0xd7712b);this['_replaceEditorDataWithRevisionData'](_0x171c40,_0x5b11a4);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x26b81b){this['_source']=_0x26b81b;}async['update'](){const _0xd2b3ae=await this['_source']['getLatestVersion']();if(_0xd2b3ae>this['currentRevision']['toVersion']){await this['_loadState']();const _0x9816d4=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0xd2b3ae});_0x9816d4['authors']=_0x9816d4['authorsIds']['map'](_0x6442f8=>this['editor']['plugins']['get']('Users')['getUser'](_0x6442f8)),this['currentRevision']['_update'](_0x9816d4);}}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'](_0x4b3eda={},_0x28f9dc=null){const _0x101200=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x28f9dc>this['currentRevision']['toVersion']&&(_0x28f9dc=null),null===_0x28f9dc&&(_0x28f9dc=await this['_source']['getLatestVersion']());const _0x39cd0a=this['_getFromVersion'](_0x28f9dc),_0x4f69a1=this['buildRevisionData']({'from':_0x39cd0a,'to':_0x28f9dc});if(this['currentRevision']['toVersion']<_0x28f9dc){const _0x2acadb=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x28f9dc,'to':_0x28f9dc});_0x2acadb['authors']=[],_0x2acadb['authorsIds']=[],_0x2acadb['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2acadb,!0x0),delete _0x2acadb['authors'],_0x101200['push'](_0x2acadb);}_0x4b3eda['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4b3eda['name']=_0x4b3eda['name']||null,_0x4b3eda['id']=_0x4b3eda['id']||_0x4813fb(),_0x4b3eda={..._0x4b3eda,..._0x4f69a1};const _0xb9eadc=this['addRevisionData'](_0x4b3eda);_0x101200['push'](_0x4b3eda);const _0x5c9b6a=this['repository']['getIndex'](_0xb9eadc);if(0x0!==_0x5c9b6a){const _0x1c47ca=this['repository']['getRevision'](_0x5c9b6a-0x1);if(_0x1c47ca['fromVersion']!==_0x28f9dc){const _0x414efd=this['_revisionDataBuilder']['getData'](_0x28f9dc,_0x1c47ca['toVersion']),_0x3f1245={'id':_0x1c47ca['id'],'diffData':_0x414efd['diffData'],'authorsIds':_0x414efd['authorsIds'],'authors':_0x414efd['authorsIds']['map'](_0x1c4b81=>this['editor']['plugins']['get']('Users')['getUser'](_0x1c4b81)),'fromVersion':_0x28f9dc};_0x1c47ca===this['currentRevision']&&(_0x3f1245['createdAt']=new Date(_0x4b3eda['createdAt']['getTime']()+0xa)),_0x1c47ca['_update'](_0x3f1245,!0x0),delete _0x3f1245['authors'],_0x101200['push'](_0x3f1245);}}if(this['adapter']){for(const _0x55b9d9 of _0x101200)this['_bufferUpdate'](_0x55b9d9['id'],_0x55b9d9,!0x0);this['sendBufferedUpdates']();}return _0xb9eadc;}['addRevisionData'](_0xe3c024){const _0x2530f9=this['repository']['createRevision'](_0xe3c024);return this['adapter']&&_0x2530f9['on']('_update',(_0x4b3a86,_0x3bfccf,_0x3bdba6)=>{_0x3bdba6||(this['_bufferUpdate'](_0x3bfccf['id'],_0x3bfccf,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2530f9,this['_findInsertionIndex'](_0x2530f9)),_0x2530f9;}async['getRevisionDocumentData'](_0x3987dc){await this['_loadRevisionData'](_0x3987dc);const _0x239b61={};for(const _0x34ce73 in _0x3987dc['diffData']){if(_0x3987dc['diffData'][_0x34ce73]['attachChange']&&!_0x3987dc['diffData'][_0x34ce73]['attachChange']['isAttached'])continue;const _0x1a7c7d=this['_removeRevisionMarkers'](JSON['parse'](_0x3987dc['diffData'][_0x34ce73]['insertions'])),_0x1381d8=this['editor']['editing']['view']['document'],_0x135b64=new _0x41a6bf(_0x1381d8,_0x1a7c7d['map'](_0x22aeeb=>C(_0x22aeeb,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x239b61[_0x34ce73]=this['editor']['data']['processor']['toData'](_0x135b64),this['editor']['data']['processor']['useFillerType']('default');}return _0x239b61;}async['getRevisionRootsAttributes'](_0x3f83fd){await this['_loadRevisionData'](_0x3f83fd);const _0x229138={};for(const _0x3b5cda in _0x3f83fd['diffData'])_0x3f83fd['diffData'][_0x3b5cda]['attachChange']&&!_0x3f83fd['diffData'][_0x3b5cda]['attachChange']['isAttached']||(_0x229138[_0x3b5cda]=_0x3f83fd['diffData'][_0x3b5cda]['attributesAfter']||{});return _0x229138;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x440283=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x8f27b5=0x0;_0x8f27b5<_0x440283['length'];_0x8f27b5++){const _0x2d1bbf=_0x440283[_0x8f27b5];let _0x44b2d2=!0x1;for(const _0x9beb3a of Object['keys'](_0x2d1bbf))void 0x0===_0x2d1bbf[_0x9beb3a]?delete _0x2d1bbf[_0x9beb3a]:'id'!==_0x9beb3a&&(_0x44b2d2=!0x0);_0x44b2d2||(_0x440283[_0x8f27b5]=null);}if(_0x440283=_0x440283['filter'](_0x4423dc=>null!==_0x4423dc),!_0x440283['length'])return;for(let _0x3943dc=0x0;_0x3943dc<_0x440283['length'];_0x3943dc++){const _0x3d4c8b=_0x440283[_0x3943dc];void 0x0!==_0x3d4c8b['fromVersion']&&void 0x0===_0x3d4c8b['toVersion']&&(_0x3d4c8b['toVersion']=this['repository']['getRevision'](_0x3d4c8b['id'])['toVersion']),void 0x0!==_0x3d4c8b['toVersion']&&void 0x0===_0x3d4c8b['fromVersion']&&(_0x3d4c8b['fromVersion']=this['repository']['getRevision'](_0x3d4c8b['id'])['fromVersion']);}const _0x4ab867=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x440283,_0x4ab867)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x248ad6=>{if(_0x248ad6){for(const _0x1c05ff of _0x248ad6)this['setRevisionData']({'id':_0x1c05ff['id'],'createdAt':_0x1c05ff['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x5b5f11,_0x59c9a7){let _0x2407b5=this['editor']['config']['get']('initialData'),_0x36d69c=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x2407b5){_0x2407b5={};for(const _0xeca367 of this['editor']['model']['document']['getRootNames']())_0x2407b5[_0xeca367]='';}if('string'==typeof _0x2407b5&&(_0x2407b5={'main':_0x2407b5}),void 0x0===_0x36d69c){_0x36d69c={};for(const _0x57173b of this['editor']['model']['document']['getRootNames']())_0x36d69c[_0x57173b]={};}let _0x128813=!0x1;const _0x41039c=Object['keys'](_0x2407b5),_0x18abff=Object['keys'](_0x5b5f11);for(const _0x240b81 of _0x41039c){if(_0x2407b5[_0x240b81]!==_0x5b5f11[_0x240b81]&&''!==_0x2407b5[_0x240b81]['trim']()){_0x128813=!0x0;break;}if(!_0x133c61(_0x36d69c[_0x240b81],_0x59c9a7[_0x240b81])&&Object['keys'](_0x36d69c[_0x240b81])['length']>0x0){_0x128813=!0x0;break;}}_0x128813||(_0x128813=_0x18abff['some'](_0x24b036=>!this['editor']['model']['document']['getRoot'](_0x24b036))),_0x128813&&_0x4238c3('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2407b5,'editorRootsAttributes':_0x36d69c,'revisionData':_0x5b5f11,'revisionRootsAttributes':_0x59c9a7}),this['editor']['config']['set']('initialData',_0x5b5f11),this['editor']['config']['set']('rootsAttributes',_0x59c9a7);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x1465a2=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x1465a2['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x373661){const _0x53408b=this['repository']['getRevisions']();_0x53408b['reverse']();let _0x211364=0x0;for(;_0x211364<_0x53408b['length'];){const _0xcd7ab2=_0x53408b[_0x211364];if(_0xcd7ab2===this['currentRevision']){_0x211364++;continue;}if(_0xcd7ab2['id']===this['_initialRevisionId'])break;const _0x2e518e=_0x373661['toVersion']-_0xcd7ab2['toVersion']||_0x373661['fromVersion']-_0xcd7ab2['fromVersion'];if(_0x2e518e>0x0)break;if(_0x2e518e<0x0)_0x211364++;else{if(!_0x373661['creator']&&_0xcd7ab2['creator'])break;if(_0xcd7ab2['creator']||!_0x373661['creator']){if(_0x373661['createdAt']>_0xcd7ab2['createdAt'])break;_0x211364++;}else _0x211364++;}}return _0x211364;}['setRevisionData'](_0x149817){const _0x4499c3=this['repository']['getRevision'](_0x149817['id']);if(_0x149817['createdAt']&&(_0x149817['createdAt']=new Date(_0x149817['createdAt'])),_0x149817['authorsIds']){const _0xe88c7c=this['editor']['plugins']['get']('Users');_0x149817['authors']=_0x149817['authorsIds']['map'](_0x2b79b7=>_0xe88c7c['getUser'](_0x2b79b7));}_0x4499c3['_update'](_0x149817,!0x0);}['buildRevisionData']({revision:_0x52f20b=null,from:_0x15b10f=null,to:_0x1cad35=null}){_0x15b10f=null!==_0x15b10f?_0x15b10f:_0x52f20b['fromVersion'],_0x1cad35=null!==_0x1cad35?_0x1cad35:_0x52f20b['toVersion'];const _0x2d82ed=this['_revisionDataBuilder']['getData'](_0x15b10f,_0x1cad35),_0x1427b7={'diffData':_0x2d82ed['diffData'],'authorsIds':_0x2d82ed['authorsIds'],'fromVersion':_0x15b10f,'toVersion':_0x1cad35};if(!_0x52f20b||_0x1cad35!==_0x52f20b['toVersion']){const _0x12d32a=_0x1cad35-0x1,_0x498080=this['_source']['history']['getOperation'](_0x12d32a);_0x1427b7['createdAt']=_0x498080&&_0x498080['createdAt']||new Date();}if(this['_loadedStateData']&&_0x15b10f===this['_loadedStateData']['fromVersion']){for(const _0x155e10 of this['_loadedStateData']['authors'])_0x1427b7['authorsIds']['includes'](_0x155e10['id'])||_0x1427b7['authorsIds']['push'](_0x155e10['id']);}return _0x1427b7;}['_loadRevisionData'](_0x320727){if(!_0x320727||_0x320727['diffData'])return Promise['resolve']();{const _0x33b083=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x33b083,'revisionId':_0x320727['id']})['then'](_0x4891dd=>{_0x320727['diffData']=_0x4891dd['diffData'];});}}['_bufferUpdate'](_0x43a34f,_0x8551d0,_0x4afede){if(this['_bufferedUpdates']['has'](_0x43a34f)){const _0x4874d9=this['_bufferedUpdates']['get'](_0x43a34f);_0x8551d0=_0x4afede?{..._0x4874d9,..._0x8551d0}:{..._0x8551d0,..._0x4874d9};}this['_bufferedUpdates']['set'](_0x43a34f,_0x8551d0);}['_getFromVersion'](_0x5f16fc){const _0x3bb1f0=this['repository']['getRevisions']();_0x3bb1f0['reverse'](),_0x3bb1f0['shift']();const _0x1a6d0a=_0x3bb1f0['find'](_0xc97c64=>_0xc97c64['toVersion']<=_0x5f16fc)['toVersion'];return _0x1a6d0a<this['_startingVersion']?this['_startingVersion']:_0x1a6d0a;}['_createInitialRevision'](_0x1b5e1f){const _0x413251=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x413251)this['_initialRevisionId']=_0x413251['id'];else{const _0x517a65=!this['editor']['model']['document']['roots']['find'](_0x3bfd0e=>this['editor']['model']['hasContent'](_0x3bfd0e)),_0x471104=this['editor']['plugins']['get']('Users')['me']['id'],_0x175adf=m(this['editor']['locale'],_0x517a65?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x1b5e1f,'to':_0x1b5e1f,'id':this['_initialRevisionId'],'name':_0x175adf,'creatorId':_0x471104});}}['_createCurrentRevision'](_0x75d363){const _0x41c847=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x41c847),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x75d363,'to':_0x75d363,'id':_0x41c847,'name':'','creatorId':null}));}['_makeRevision']({name:_0x2a5cfb,from:_0x407738,to:_0x59fbf2,creatorId:_0xd7dc10,id:_0x1777cb}){const _0x42cb7f=this['buildRevisionData']({'from':_0x407738,'to':_0x59fbf2});_0x42cb7f['name']=_0x2a5cfb,_0x42cb7f['creatorId']=_0xd7dc10,_0x42cb7f['id']=_0x1777cb;const _0x57ac58=this['addRevisionData'](_0x42cb7f);return this['adapter']&&this['_bufferUpdate'](_0x42cb7f['id'],_0x42cb7f,!0x0),_0x57ac58;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x4ecb34){return(_0x4ecb34=_0x4ecb34['filter'](_0x24edb8=>!_0x24edb8['name']||'revision-start'!==_0x24edb8['name']&&'revision-end'!==_0x24edb8['name']))['forEach'](_0x69130d=>{'string'!=typeof _0x69130d&&(_0x69130d['children']=this['_removeRevisionMarkers'](_0x69130d['children']),_0x69130d['attributes']=_0x69130d['attributes']['filter'](_0xadc25=>!_0xadc25[0x0]['startsWith']('data-revision-')));}),_0x4ecb34;}}function C(_0x1c4fbc,_0x16cbf1){const _0x341aa4=_0x16cbf1['editing']['view']['document'];if('string'==typeof _0x1c4fbc)return new _0x2bf8d1(_0x341aa4,_0x1c4fbc);{const _0x458e32=_0x1c4fbc['children']['map'](_0x5537f7=>C(_0x5537f7,_0x16cbf1));return new(P[_0x1c4fbc['type']]||_0x150663)(_0x341aa4,_0x1c4fbc['name'],_0x1c4fbc['attributes'],_0x458e32);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x248dce){this['editor']=_0x248dce,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'](_0x12a0ae){this['source']=_0x12a0ae;const _0x44dd04=new Map(),_0x28d4f0=new Map(),_0x37da7f=this['editor']['model']['document']['roots']['map'](_0x149351=>_0x149351['rootName']);for(const _0x323280 of _0x37da7f){const _0x3ea4a5=this['editor']['model']['document']['getRoot'](_0x323280),_0x5c2a84=T(_0x3ea4a5);_0x44dd04['set'](_0x323280,_0x5c2a84),_0x28d4f0['set'](_0x323280,Object['fromEntries'](_0x3ea4a5['getAttributes']()));}const _0x4adf50=Array['from'](this['editor']['model']['markers'])['map'](_0x1a362e=>[_0x1a362e['name'],_0x1a362e['getRange']()]),_0x320a7e=this['source']['version'];this['_saveMetaData'](_0x320a7e,_0x44dd04,_0x4adf50,_0x28d4f0),this['_startingRevisionId']=this['_revisionId'];const _0x1ba9a2=new Map(),_0x4d636a=new Map();for(const _0x3478a2 of _0x37da7f){const _0x3a5c93=F(_0x3478a2);_0x1ba9a2['set'](_0x3478a2,_0x3a5c93),_0x4d636a['set'](_0x3478a2,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1ba9a2,[],_0x4d636a);}['getData'](_0x48651f,_0x5ddd32){if(this['_lastFrom']===_0x48651f&&this['_lastTo']<=_0x5ddd32)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x5ddd32,!0x0);else{if(!this['_savedMetaData']['has'](_0x48651f)){const _0x592232=this['_getPreviousFrom'](_0x48651f);this['_calculateMetaData'](_0x592232,_0x48651f,!0x1);}this['_calculateMetaData'](_0x48651f,_0x5ddd32,!0x0);}return this['_lastFrom']=_0x48651f,this['_lastTo']=_0x5ddd32,this['_getState']();}['loadState'](_0x466e3f){this['_reset'](),this['_lastFrom']=_0x466e3f['fromVersion'],this['_lastTo']=_0x466e3f['toVersion'];for(const _0x127823 in _0x466e3f['diffData']){const _0x2e056c=_0x466e3f['diffData'][_0x127823]['attachChange'],_0x3cbcdb=_0x36027d(_0x466e3f['diffData'][_0x127823]['attributesBefore'])||{},_0x1e8a3a=this['_makeModelFromViewString'](_0x466e3f['diffData'][_0x127823]['deletions']);_0x1e8a3a['rootName']=_0x127823,_0x1e8a3a['_isAttached']=!_0x2e056c||!_0x2e056c['isAttached'],_0x1e8a3a['isAttached']=()=>_0x1e8a3a['_isAttached'],this['_baseRoots']['set'](_0x127823,_0x1e8a3a),this['_baseRootsAttributes']['set'](_0x127823,_0x3cbcdb),_0x2e056c&&this['_touchedRoots']['set'](_0x127823,_0x2e056c);const _0x1f7246=this['_makeIdsRoot'](_0x1e8a3a);this['_baseIdsRoots']['set'](_0x127823,_0x1f7246);for(const [_0x526861,_0x5db049]of _0x1e8a3a['markers']){if(!_0x526861['startsWith']('revision:'))continue;const _0x49dae2=_0x526861['split'](':')[0x2];for(const _0x3fb3f2 of _0x5db049['getWalker']({'singleCharacters':!0x0})){const _0x10ef41=this['_getVidAttributeName'](_0x3fb3f2),_0x7d33cc='elementEnd'==_0x3fb3f2['type']?_0x3fb3f2['previousPosition']['path']['slice'](0x0,-0x1):_0x3fb3f2['previousPosition']['path'],_0x3ccf85=_0x1f7246['getNodeByPath'](_0x7d33cc)['getAttribute'](_0x10ef41);this['_touched']['set'](_0x3ccf85,{'userId':_0x49dae2});}}}this['_startingRevisionId']=this['_revisionId'];const _0x327748=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x4a82a7=>!this['_touched']['has'](_0x4a82a7));let _0x3a010a=0x0;const _0x23a325=new Map();for(const _0x37dd6c in _0x466e3f['diffData']){const _0x54c33e=_0x466e3f['diffData'][_0x37dd6c]['attachChange'],_0x1ba761=_0x36027d(_0x466e3f['diffData'][_0x37dd6c]['attributesAfter'])||{},_0x3fa1b1=this['_makeModelFromViewString'](_0x466e3f['diffData'][_0x37dd6c]['insertions']);_0x3fa1b1['rootName']=_0x37dd6c,_0x3fa1b1['_isAttached']=!_0x54c33e||_0x54c33e['isAttached'],_0x3fa1b1['isAttached']=()=>_0x3fa1b1['_isAttached'],this['_diffRoots']['set'](_0x37dd6c,_0x3fa1b1),this['_diffRootsAttributes']['set'](_0x37dd6c,_0x1ba761);const _0x36df13=this['_makeIdsRoot'](_0x3fa1b1,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x37dd6c,_0x36df13),_0x23a325['set'](_0x37dd6c,_0x3fa1b1['isAttached']()?_0x1ba761:{});for(const [_0x9f3af1,_0x1f4e5c]of _0x3fa1b1['markers']){if(!_0x9f3af1['startsWith']('revision:'))continue;const _0x8f40b4=_0x9f3af1['split'](':')[0x2];for(const _0x504ccb of _0x1f4e5c['getWalker']({'singleCharacters':!0x0})){const _0x3889b7=this['_getVidAttributeName'](_0x504ccb),_0x3dac29=this['_revisionId']++,_0x48b937='elementEnd'==_0x504ccb['type']?_0x504ccb['previousPosition']['path']['slice'](0x0,-0x1):_0x504ccb['previousPosition']['path'];_0x36df13['getNodeByPath'](_0x48b937)['_setAttribute'](_0x3889b7,_0x3dac29),this['_touched']['set'](_0x3dac29,{'userId':_0x8f40b4});}}for(const _0xe30fc8 of this['editor']['model']['createRangeIn'](_0x3fa1b1)['getWalker']({'singleCharacters':!0x0})){const _0x57d8ed=this['_getVidAttributeName'](_0xe30fc8),_0x344953='elementEnd'==_0xe30fc8['type']?_0xe30fc8['previousPosition']['path']['slice'](0x0,-0x1):_0xe30fc8['previousPosition']['path'],_0x35dc5a=_0x36df13['getNodeByPath'](_0x344953);_0x35dc5a['getAttribute'](_0x57d8ed)>0x0||_0x35dc5a['_setAttribute'](_0x57d8ed,_0x327748[_0x3a010a++]);}for(const [_0x2fee18,_0x2c7260]of _0x3fa1b1['markers'])_0x2fee18['startsWith']('revision:')||this['_markers']['set'](_0x2fee18,_0x2c7260);}const _0x243a24=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x243a24),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x243a24,0x1));const _0x48c45b=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x48c45b),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x48c45b,0x1));const _0x4d48f6=Array['from'](this['_diffRoots'])['map'](([_0x12988d,_0x5264d4])=>[_0x12988d,T(_0x5264d4)]);this['_saveMetaData'](this['_lastTo'],_0x4d48f6,this['_markers'],_0x23a325);}['_makeModelFromViewString'](_0x2e9443){const _0x31985a=JSON['parse'](_0x2e9443),_0x4e60e8=this['editor']['editing']['view']['document'],_0x79b948=new _0x41a6bf(_0x4e60e8,_0x31985a['map'](_0x34dc70=>C(_0x34dc70,this['editor'])));return this['editor']['data']['toModel'](_0x79b948);}['_saveMetaData'](_0x2559e8,_0x2ab42e,_0x141de0,_0xfaea2a){const _0x2e1566=new Map(_0x2ab42e),_0x198690=new Map(_0x36027d(_0xfaea2a)),_0x370ed0=new Map();for(const [_0x7c4702,_0x59848f]of _0x141de0)_0x370ed0['set'](_0x7c4702,{'start':_0x59848f['start']['clone'](),'end':_0x59848f['end']['clone'](),'rootName':_0x59848f['root']['rootName']});this['_savedMetaData']['set'](_0x2559e8,{'roots':_0x2e1566,'markers':_0x370ed0,'rootsAttributes':_0x198690});}['_removeMetaData'](_0x4c4128){this['_savedMetaData']['delete'](_0x4c4128);}['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'](_0x37ae14,_0x29e097=null){let _0x1dd9ab=null;_0x37ae14['is']('documentFragment')||(_0x1dd9ab=new ft(_0x37ae14['name'],{'vid_start':null===_0x29e097?this['_revisionId']++:_0x29e097++}));const _0x2859d2=[];for(const _0x2525ae of _0x37ae14['getChildren']())if(_0x2525ae['is']('element')){_0x2859d2['push'](this['_makeIdsRoot'](_0x2525ae,_0x29e097));const _0x3df88f=_0x2859d2[_0x2859d2['length']-0x1];null!==_0x29e097&&(_0x29e097=_0x3df88f['is']('element','$text')?_0x3df88f['getAttribute']('vid')+0x1:_0x3df88f['getAttribute']('vid_end')+0x1);}else{for(let _0x302c4b=0x0;_0x302c4b<_0x2525ae['offsetSize'];_0x302c4b++)_0x2859d2['push'](new ft('$text',{'vid':null===_0x29e097?this['_revisionId']++:_0x29e097++}));}if(_0x37ae14['is']('documentFragment')){const _0x1f0c06=F(_0x37ae14['rootName']);return _0x1f0c06['_insertChild'](0x0,_0x2859d2),_0x1f0c06;}return _0x1dd9ab['_setAttribute']('vid_end',null===_0x29e097?this['_revisionId']++:_0x29e097++),_0x1dd9ab['_insertChild'](0x0,_0x2859d2),_0x1dd9ab;}['_calculateMetaData'](_0x58eed9,_0x29c575,_0x585639){this['_reset']();const {roots:_0x40cb1e,markers:_0x5667ae,rootsAttributes:_0x509a9e}=this['_savedMetaData']['get'](_0x58eed9);this['_baseRoots']=new Map(_0x40cb1e),this['_baseRootsAttributes']=new Map(_0x36027d(_0x509a9e));for(const [_0x38301c,_0x281b0e]of this['_baseRoots'])if('$graveyard'!==_0x38301c&&(this['_diffRoots']['set'](_0x38301c,T(_0x281b0e)),this['_diffRootsAttributes']=new Map(_0x36027d(_0x509a9e)),_0x585639)){const _0x5c25fd=this['_revisionId'];this['_idsRoots']['set'](_0x38301c,this['_makeIdsRoot'](_0x281b0e)),this['_baseIdsRoots']['set'](_0x38301c,this['_makeIdsRoot'](_0x281b0e,_0x5c25fd));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x585639&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1b8260,_0x4acbdb]of _0x5667ae){const _0x53f48f=this['_baseRoots']['get'](_0x4acbdb['rootName']),_0x73fe51=this['_diffRoots']['get'](_0x4acbdb['rootName']),_0x11c2d4=new vt(this['_fixPosition'](_0x4acbdb['start'],_0x53f48f),this['_fixPosition'](_0x4acbdb['end'],_0x53f48f)),_0x212b55=this['_fixRange'](_0x11c2d4,_0x73fe51);_0x53f48f['markers']['set'](_0x1b8260,_0x11c2d4),this['_markers']['set'](_0x1b8260,_0x212b55);}this['_applyOperations'](_0x58eed9,_0x29c575,_0x585639);}['_applyOperations'](_0x4db128,_0x218440,_0x4c82d5){for(const _0x1bbf22 of this['source']['getOperations'](_0x4db128,_0x218440))this['_handleOperation'](_0x1bbf22,_0x4c82d5);for(const _0xf9bb90 of this['_diffRoots']['values']())_0xf9bb90['markers']['clear']();for(const [_0x4a0b36,_0x4462f5]of this['_markers']){this['_diffRoots']['get'](_0x4462f5['root']['rootName'])['markers']['set'](_0x4a0b36,_0x4462f5['clone']());}const _0x2c2a48=new Map(),_0xf6bd51=new Map();for(const [_0x24bc59,_0x59d4dc]of this['_diffRoots'])_0x2c2a48['set'](_0x24bc59,T(_0x59d4dc)),_0xf6bd51['set'](_0x24bc59,this['_diffRootsAttributes']['get'](_0x24bc59));this['_saveMetaData'](_0x218440,_0x2c2a48,this['_markers'],_0xf6bd51);}['_getPreviousFrom'](_0x314bef){const _0x521247=Array['from'](this['_savedMetaData']['keys']());_0x521247['sort']((_0x2ef116,_0x7768a2)=>_0x2ef116-_0x7768a2),_0x521247['reverse']();for(const _0x266882 of _0x521247)if(_0x266882<_0x314bef)return _0x266882;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1ee3ab,_0x4b0f4d){const _0x19228b=Array['from'](_0x4b0f4d['markers'])['map'](([_0x3d1d05,_0x1eb20f])=>[_0x3d1d05,this['_fixRange'](_0x1eb20f,_0x1ee3ab)]);_0x1ee3ab['markers']=new Map(_0x19228b);}['_transformMarkers'](_0x19374d){for(const _0x4e300f of this['_markers']['values']()){const _0x133985=_0x4e300f['getTransformedByOperation'](_0x19374d),_0x3daa2f=vt['_createFromRanges'](_0x133985);_0x4e300f['start']=_0x3daa2f['start'],_0x4e300f['end']=_0x3daa2f['end'];}}['_handleOperation'](_0xc41b8a,_0x19513c){if('addRoot'!=_0xc41b8a['type']&&'detachRoot'!=_0xc41b8a['type']){if('insert'==_0xc41b8a['type']){const _0x2a11dd=_0xc41b8a['position']['root']['rootName'];this['_diffRoots']['has'](_0x2a11dd)||(this['_diffRoots']['set'](_0x2a11dd,F(_0x2a11dd,!0x0)),this['_diffRootsAttributes']['set'](_0x2a11dd,{}),_0x19513c&&this['_idsRoots']['set'](_0x2a11dd,F(_0x2a11dd,!0x0)));}else{if('addRootAttribute'==_0xc41b8a['type']||'removeRootAttribute'==_0xc41b8a['type']||'changeRootAttribute'==_0xc41b8a['type'])return void this['_handleRootAttributeOperation'](_0xc41b8a);'marker'==_0xc41b8a['type']&&this['_handleMarkerOperation'](_0xc41b8a);}if('marker'!==_0xc41b8a['type']){const _0xc0966a=this['_cloneOperation'](_0xc41b8a,this['_diffRoots']);_0xc0966a['_execute'](),this['_transformMarkers'](_0xc0966a);}if(_0x19513c)switch(_0xc41b8a['type']){case'insert':this['_handleInsertOperation'](_0xc41b8a);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xc41b8a);break;case'merge':this['_handleMergeOperation'](_0xc41b8a);break;case'split':this['_handleSplitOperation'](_0xc41b8a);}}else this['_handleRootOperation'](_0xc41b8a,_0x19513c);}['_cloneOperation'](_0x4cc764,_0x30db3b){const _0xc7c846=_0x4cc764['clone']();return _0xc7c846['_authorId']=_0x4cc764['_authorId'],this['_fixOperation'](_0xc7c846,_0x30db3b),_0xc7c846;}['_getBaseVids'](_0x14b18a){return _0x14b18a['map'](_0x481164=>{const _0x29a9bc=this['_getVidAttributeName'](_0x481164);return Number(_0x481164['item']['getAttribute'](_0x29a9bc));});}['_generateTape'](_0x4f74f0,_0x15955a){if(_0x4f74f0['is']('element','$text'))_0x15955a['push']({'item':_0x4f74f0,'type':'text'});else{_0x4f74f0['is']('element')&&_0x15955a['push']({'item':_0x4f74f0,'type':'elementStart'});for(const _0xd1d5a5 of _0x4f74f0['getChildren']())this['_generateTape'](_0xd1d5a5,_0x15955a);_0x4f74f0['is']('element')&&_0x15955a['push']({'item':_0x4f74f0,'type':'elementEnd'});}return _0x15955a;}['_getState'](){const _0x2d4dba=new Map(this['_touched']),_0x589c1b=new Map(_0x2d4dba),_0x57c5c7=new Map(),_0x85fc69={'insertions':{},'deletions':{}},_0x100512={'insertions':{},'deletions':{}},_0x48b748=new Map(),_0xa7890b=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0xa7890b['delete']('$graveyard');for(const _0x5de6c7 of _0xa7890b){const _0x41f346=this['_diffRoots']['get'](_0x5de6c7)||F(_0x5de6c7,!0x1),_0x8e7771=this['_baseRoots']['get'](_0x5de6c7)||F(_0x5de6c7,!0x1);_0x41f346['isAttached']()||_0x8e7771['isAttached']()?(_0x85fc69['insertions'][_0x5de6c7]=T(_0x41f346),_0x85fc69['deletions'][_0x5de6c7]=T(_0x8e7771),this['_copyMarkers'](_0x85fc69['deletions'][_0x5de6c7],_0x8e7771),this['_copyMarkers'](_0x85fc69['insertions'][_0x5de6c7],_0x41f346),_0x100512['insertions'][_0x5de6c7]=this['_generateTape'](this['_idsRoots']['get'](_0x5de6c7),[]),_0x100512['deletions'][_0x5de6c7]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x5de6c7)||F(_0x5de6c7,!0x1),[])):_0xa7890b['delete'](_0x5de6c7);}for(const _0x50bdf4 of _0xa7890b){const _0x5625b4=_0x100512['insertions'][_0x50bdf4];for(const _0x508270 of _0x5625b4){const _0x142039=this['_getVidAttributeName'](_0x508270),_0x3a0b3f=_0x508270['item']['getAttribute'](_0x142039);_0x589c1b['delete'](_0x3a0b3f),_0x3a0b3f>=this['_startingRevisionId']&&_0x57c5c7['set'](_0x3a0b3f,_0x2d4dba['get'](_0x3a0b3f));}}for(const _0x376fe0 of _0xa7890b){const _0x157b21=_0x100512['insertions'][_0x376fe0],_0x47aa50=this['_getBaseVids'](_0x100512['deletions'][_0x376fe0]);let _0x5e19c7=0x0;for(const _0x4e934a of _0x157b21){const _0x13f6bc=this['_getVidAttributeName'](_0x4e934a),_0x2c0ce3=_0x4e934a['item']['getAttribute'](_0x13f6bc);if(!_0x57c5c7['has'](_0x2c0ce3)&&!_0x48b748['has'](_0x2c0ce3)){if(_0x589c1b['has'](_0x2c0ce3))_0x5e19c7++;else{if(_0x2c0ce3!=_0x47aa50[_0x5e19c7]){const _0x5a544f=_0x2d4dba['get'](_0x2c0ce3)||_0x2d4dba['get'](_0x47aa50[_0x5e19c7]);for(;_0x2c0ce3!=_0x47aa50[_0x5e19c7];)_0x589c1b['has'](_0x47aa50[_0x5e19c7])||(_0x48b748['set'](_0x47aa50[_0x5e19c7],_0x5a544f),_0x2d4dba['set'](_0x47aa50[_0x5e19c7],_0x5a544f)),_0x5e19c7++;}_0x5e19c7++;}}}}for(const _0x451e5a of _0xa7890b){const _0x388ddc=_0x100512['insertions'][_0x451e5a];for(const _0x7c3300 of _0x388ddc){const _0x567dea=this['_getVidAttributeName'](_0x7c3300),_0x5500fd=_0x7c3300['item']['getAttribute'](_0x567dea);if(_0x48b748['has'](_0x5500fd)){const _0x4d6fb0=_0x48b748['get'](_0x5500fd);_0x589c1b['has'](_0x5500fd)||_0x589c1b['set'](_0x5500fd,{..._0x4d6fb0}),_0x57c5c7['set'](_0x5500fd,{..._0x4d6fb0});}}}for(const _0x1ba476 of _0x589c1b['keys']())_0x1ba476>=this['_startingRevisionId']&&_0x589c1b['delete'](_0x1ba476);const _0x371709=new Map();for(const _0x410152 of _0xa7890b){let _0x34dc16=_0x100512['insertions'][_0x410152];for(const _0x34d793 of _0x34dc16)if(_0x34d793['item']['is']('element','tableCell')){const _0x33cb17=this['_getVidAttributeName'](_0x34d793),_0x89bb4=_0x34d793['item']['getAttribute'](_0x33cb17);if(_0x57c5c7['has'](_0x89bb4)){const _0x4fdebe=_0x34d793['item']['parent']['parent']['getAttribute']('vid_start'),_0x55bc0c=_0x371709['get'](_0x4fdebe)||new Set();_0x55bc0c['add'](_0x57c5c7['get'](_0x89bb4)['userId']),_0x371709['set'](_0x4fdebe,_0x55bc0c);}}_0x34dc16=_0x100512['deletions'][_0x410152];for(const _0x2638ff of _0x34dc16)if(_0x2638ff['item']['is']('element','tableCell')){const _0x4be9e3=this['_getVidAttributeName'](_0x2638ff),_0x2c6124=_0x2638ff['item']['getAttribute'](_0x4be9e3);if(_0x589c1b['has'](_0x2c6124)){const _0x2b8def=_0x2638ff['item']['parent']['parent']['getAttribute']('vid_start'),_0x5e1821=_0x371709['get'](_0x2b8def)||new Set();_0x5e1821['add'](_0x589c1b['get'](_0x2c6124)['userId']),_0x371709['set'](_0x2b8def,_0x5e1821);}}for(const _0x1f6327 of _0x371709['keys']())(_0x57c5c7['has'](_0x1f6327)||_0x589c1b['has'](_0x1f6327))&&_0x371709['delete'](_0x1f6327);}for(const _0x5af03f of _0xa7890b){const _0x1fb1b6=_0x100512['insertions'][_0x5af03f];let _0x19b11f=null,_0x2b0740=null;for(const _0x3149b4 of _0x1fb1b6){const _0x4cddb8=this['_getVidAttributeName'](_0x3149b4),_0x5591b0=_0x3149b4['item']['getAttribute'](_0x4cddb8),_0x3e7d1c=_0x371709['get'](_0x5591b0);_0x3e7d1c&&'elementStart'==_0x3149b4['type']&&(_0x19b11f=Array['from'](_0x3e7d1c)[0x0],_0x2b0740=_0x3149b4['item']['getAttribute']('vid_end')),_0x19b11f&&(_0x589c1b['set'](_0x5591b0,{'userId':_0x19b11f}),_0x57c5c7['set'](_0x5591b0,{'userId':_0x19b11f})),_0x5591b0==_0x2b0740&&(_0x19b11f=null,_0x2b0740=null);}}const _0x292716={},_0x2bc114=new Set();for(const _0x1acc73 of _0xa7890b){const _0x51fab5=_0x85fc69['deletions'][_0x1acc73],_0x77ea6c=_0x85fc69['insertions'][_0x1acc73];for(const {userId:_0x1238d9}of this['_touchedMarkers']['values']())null!==_0x1238d9&&_0x2bc114['add'](_0x1238d9);for(const {userId:_0x2ad6b5}of this['_touchedRoots']['values']())null!==_0x2ad6b5&&_0x2bc114['add'](_0x2ad6b5);this['_markChanges'](_0x77ea6c,_0x100512['insertions'][_0x1acc73],_0x57c5c7,'insertion',_0x2bc114),this['_markChanges'](_0x51fab5,_0x100512['deletions'][_0x1acc73],_0x589c1b,'deletion',_0x2bc114),_0x292716[_0x1acc73]={'insertions':this['_prepareViewToSave'](_0x77ea6c),'deletions':this['_prepareViewToSave'](_0x51fab5),'attachChange':this['_touchedRoots']['get'](_0x1acc73)||null,'attributesBefore':_0x36027d(this['_baseRootsAttributes']['get'](_0x1acc73))||{},'attributesAfter':_0x36027d(this['_diffRootsAttributes']['get'](_0x1acc73))};}return{'diffData':_0x292716,'authorsIds':Array['from'](_0x2bc114)};}['_processRootBeforeSave'](_0x3e5ae1){for(const [,_0x4c49f3]of _0x3e5ae1['markers']){const _0x5d28bc=_0x4c49f3['start']['getAncestors']()['filter'](_0x29f82b=>'tableCell'==_0x29f82b['name']);for(const _0x4ca5d4 of _0x5d28bc)0x1==_0x4ca5d4['childCount']&&_0x4ca5d4['getChild'](0x0)['is']('element','paragraph')&&_0x4ca5d4['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2f3a53){this['_processRootBeforeSave'](_0x2f3a53);const _0x416179=this['editor']['data']['toView'](_0x2f3a53,{}),_0x195159=Array['from'](_0x416179['getChildren']())['map'](_0x48183f=>this['_getViewJson'](_0x48183f));return JSON['stringify'](_0x195159);}['_getViewJson'](_0x63e629){if(_0x63e629['is']('$text'))return _0x63e629['data'];{const _0x261f63=_0x63e629;return{'type':Object['keys'](P)['find'](_0x418607=>_0x63e629 instanceof P[_0x418607]),'name':_0x261f63['name'],'attributes':Array['from'](_0x261f63['getAttributes']()),'children':Array['from'](_0x261f63['getChildren']())['map'](_0x2f919d=>this['_getViewJson'](_0x2f919d))};}}['_markChanges'](_0x1f9eee,_0x42ce7e,_0x5cd84c,_0x11b57d,_0x2c6732){let _0x41a9e2=null,_0x4990be=null,_0x29ce20=0x0;const _0x39d46d=this['editor']['model'];for(let _0x4f6f7=0x0;_0x4f6f7<_0x42ce7e['length'];_0x4f6f7++){const _0x8c047e=this['_getVidAttributeName'](_0x42ce7e[_0x4f6f7]),_0x15b59d=_0x42ce7e[_0x4f6f7]['item']['getAttribute'](_0x8c047e),_0x5cf8ee=_0x5cd84c['get'](_0x15b59d),_0x231680=_0x4f6f7==_0x42ce7e['length']-0x1;(!_0x41a9e2&&_0x5cf8ee&&(_0x41a9e2=_0x5cf8ee,_0x4990be=_0x42ce7e[_0x4f6f7]),_0x41a9e2&&(!_0x5cf8ee||_0x5cf8ee['userId']!=_0x41a9e2['userId']))&&(_0x1337aa(_0x5cf8ee,B(_0x4990be,_0x1f9eee,_0x39d46d),B(_0x42ce7e[_0x4f6f7],_0x1f9eee,_0x39d46d)),_0x41a9e2=_0x5cf8ee||null,_0x4990be=_0x5cf8ee?_0x42ce7e[_0x4f6f7]:null),_0x41a9e2&&_0x231680&&_0x1337aa(_0x5cf8ee,B(_0x4990be,_0x1f9eee,_0x39d46d),J(_0x42ce7e[_0x4f6f7],_0x1f9eee,_0x39d46d));}function _0x1337aa(_0x13be38,_0x2bcbd1,_0x5da40f){const _0x3d6bea=_0x41a9e2['userId'],_0x14839a='revision:'+_0x11b57d+':'+_0x3d6bea+':'+_0x29ce20++,_0x31d597=_0x39d46d['createRange'](_0x2bcbd1,_0x5da40f);_0x1f9eee['markers']['set'](_0x14839a,_0x31d597),null!==_0x3d6bea&&_0x2c6732['add'](_0x3d6bea);}}['_getVidAttributeName'](_0x9d93d4){switch(_0x9d93d4['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x2a2c5b,_0x3061e0){_0x2a2c5b['baseVersion']=null;for(const _0x4e6600 in _0x2a2c5b){const _0x4d655d=_0x2a2c5b[_0x4e6600];if(_0x4d655d instanceof gt){const _0x4c20df=_0x3061e0['get'](_0x4d655d['root']['rootName']);_0x2a2c5b[_0x4e6600]=this['_fixPosition'](_0x4d655d,_0x4c20df);}if(_0x4d655d instanceof vt){const _0x368ac9=_0x3061e0['get'](_0x4d655d['root']['rootName']);_0x2a2c5b[_0x4e6600]=this['_fixRange'](_0x4d655d,_0x368ac9);}'root'===_0x4e6600&&(_0x2a2c5b['root']=_0x3061e0['get'](_0x2a2c5b['root']['rootName']));}}['_fixRange'](_0x2ee65b,_0x2d87fe){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2ee65b['start'],_0x2d87fe),this['_fixPosition'](_0x2ee65b['end'],_0x2d87fe));}['_fixPosition'](_0x321aa2,_0x53f3b8){return this['editor']['model']['createPositionFromPath'](_0x53f3b8,_0x321aa2['path'],_0x321aa2['stickiness']);}['_handleInsertOperation'](_0x4db897){const _0x4545bb=this['_idsRoots']['get'](_0x4db897['position']['root']['rootName']),_0x4536dd=this['_fixPosition'](_0x4db897['position'],_0x4545bb),_0x42609a=null===_0x4db897['_authorId']?null:_0x4db897['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5c720f=_0x4536dd['parent'],_0x5f0175=this['_revisionId'],_0xf306a=[];for(const _0x57261e of _0x4db897['nodes'])if(_0x57261e['is']('element'))_0xf306a['push'](this['_makeIdsRoot'](_0x57261e));else{for(let _0x4ac7b5=0x0;_0x4ac7b5<_0x57261e['offsetSize'];_0x4ac7b5++)_0xf306a['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x3eba55=this['_revisionId'];for(let _0x1c4116=_0x5f0175;_0x1c4116<_0x3eba55;_0x1c4116++)this['_touched']['set'](_0x1c4116,{'userId':_0x42609a});_0x5c720f['_insertChild'](_0x4536dd['offset'],_0xf306a);}['_handleMoveOperation'](_0x4efbce){(_0x4efbce=this['_cloneOperation'](_0x4efbce,this['_idsRoots']))['_execute']();const _0x2c060c=null===_0x4efbce['_authorId']?null:_0x4efbce['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3762e6=_0x4efbce['getMovedRangeStart'](),_0x642c61=_0x3762e6['parent'],_0x3237a5=_0x3762e6['offset'];!function _0x2621ff(_0x599f7f,_0xec210d,_0x25f5d0,_0x4cc7f0){for(let _0x204a91=_0x25f5d0;_0x204a91<_0x4cc7f0;_0x204a91++){const _0x5beef3=_0xec210d['getChild'](_0x204a91);_0x5beef3['is']('element','$text')?_0x599f7f['set'](_0x5beef3['getAttribute']('vid'),{'userId':_0x2c060c}):(_0x599f7f['set'](_0x5beef3['getAttribute']('vid_start'),{'userId':_0x2c060c}),_0x2621ff(_0x599f7f,_0x5beef3,0x0,_0x5beef3['childCount']),_0x599f7f['set'](_0x5beef3['getAttribute']('vid_end'),{'userId':_0x2c060c}));}}(this['_touched'],_0x642c61,_0x3237a5,_0x3237a5+_0x4efbce['howMany']);}['_handleMergeOperation'](_0xfc8a1f){const _0x480dad=null===(_0xfc8a1f=this['_cloneOperation'](_0xfc8a1f,this['_idsRoots']))['_authorId']?null:_0xfc8a1f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1276b4=_0xfc8a1f['targetPosition']['parent'],_0x424cbf=_0xfc8a1f['sourcePosition']['parent'],_0x52d1e5=_0x1276b4['getAttribute']('vid_end'),_0x5eefaa=_0x424cbf['getAttribute']('vid_start');_0x1276b4['_setAttribute']('vid_end',_0x424cbf['getAttribute']('vid_end')),_0x424cbf['_setAttribute']('vid_end',_0x52d1e5),this['_touched']['set'](_0x5eefaa,{'userId':_0x480dad}),this['_touched']['set'](_0x52d1e5,{'userId':_0x480dad}),_0xfc8a1f['_execute']();}['_handleSplitOperation'](_0x351431){const _0xd1a6f3=null===(_0x351431=this['_cloneOperation'](_0x351431,this['_idsRoots']))['_authorId']?null:_0x351431['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x171fca=_0x351431['graveyardPosition'],_0x3d8693=_0x351431['splitPosition']['parent'];_0x351431['_execute']();const _0x4f7bb3=_0x3d8693['getAttribute']('vid_end'),_0x35c8bf=_0x351431['insertionPosition']['nodeAfter'];if(_0x171fca){const _0x1202f0=_0x35c8bf['getAttribute']('vid_end'),_0x4233ed=_0x3d8693['getAttribute']('vid_end');_0x3d8693['_setAttribute']('vid_end',_0x1202f0),_0x35c8bf['_setAttribute']('vid_end',_0x4233ed),this['_touched']['set'](_0x3d8693['getAttribute']('vid_end'),{'userId':_0xd1a6f3}),this['_touched']['set'](_0x35c8bf['getAttribute']('vid_start'),{'userId':_0xd1a6f3});}else{const _0xcda827=this['_revisionId']++,_0x1572c6=this['_revisionId']++;_0x3d8693['_setAttribute']('vid_end',_0xcda827),_0x35c8bf['_setAttribute']('vid_start',_0x1572c6),_0x35c8bf['_setAttribute']('vid_end',_0x4f7bb3),this['_touched']['set'](_0xcda827,{'userId':_0xd1a6f3}),this['_touched']['set'](_0x1572c6,{'userId':_0xd1a6f3});}}['_handleMarkerOperation'](_0x4a352b){if(!_0x4a352b['affectsData'])return;const _0x46fc26=(_0x4a352b=this['_cloneOperation'](_0x4a352b,this['_diffRoots']))['oldRange']?_0x4a352b['oldRange']['root']:null,_0x335257=_0x4a352b['newRange']?_0x4a352b['newRange']['root']:null;_0x46fc26&&this['_markers']['delete'](_0x4a352b['name']),_0x335257&&this['_markers']['set'](_0x4a352b['name'],_0x4a352b['newRange']['clone']());const _0x34e79e=null===_0x4a352b['_authorId']?null:_0x4a352b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x53510e=_0x4a352b['name'];if(!this['_touchedMarkers']['has'](_0x53510e))return void this['_touchedMarkers']['set'](_0x53510e,{'range':_0x4a352b['oldRange'],'userId':_0x34e79e});const _0x25ed39=this['_touchedMarkers']['get'](_0x53510e),_0x4479b1=_0x25ed39['range'],_0x56f2d1=_0x4a352b['newRange'];null==_0x4479b1&&null==_0x56f2d1||_0x4479b1&&_0x56f2d1&&_0x4479b1['isEqual'](_0x56f2d1)?this['_touchedMarkers']['delete'](_0x4a352b['name']):_0x25ed39['userId']=_0x34e79e;}['_handleRootOperation'](_0x2ed1f9,_0x10297a){this['_diffRoots']['has'](_0x2ed1f9['rootName'])?this['_diffRoots']['get'](_0x2ed1f9['rootName'])['_isAttached']=_0x2ed1f9['isAdd']:(this['_diffRoots']['set'](_0x2ed1f9['rootName'],F(_0x2ed1f9['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2ed1f9['rootName'],{}),_0x10297a&&this['_idsRoots']['set'](_0x2ed1f9['rootName'],F(_0x2ed1f9['rootName'],!0x0)));const _0x3ccdd9=null===_0x2ed1f9['_authorId']?null:_0x2ed1f9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x18210f=this['_touchedRoots']['get'](_0x2ed1f9['rootName']);_0x18210f&&_0x18210f['userId']===_0x3ccdd9?this['_touchedRoots']['delete'](_0x2ed1f9['rootName']):this['_touchedRoots']['set'](_0x2ed1f9['rootName'],{'userId':_0x3ccdd9,'isAttached':_0x2ed1f9['isAdd']});}['_handleRootAttributeOperation'](_0x47135b){const _0x5b24a1=this['_diffRootsAttributes']['get'](_0x47135b['root']['rootName']);null===_0x47135b['newValue']?delete _0x5b24a1[_0x47135b['key']]:_0x5b24a1[_0x47135b['key']]=_0x47135b['newValue'];}}function T(_0x543811){const _0x4e2568=F(_0x543811['rootName'],_0x543811['isAttached']());for(const _0x75ff55 of _0x543811['getChildren']()){const _0x345bad=_0x75ff55['_clone'](!0x0);_0x4e2568['_appendChild'](_0x345bad);}return _0x4e2568;}function F(_0x5a587b,_0x347529=!0x0){const _0x470f19=new mt();return _0x470f19['rootName']=_0x5a587b,_0x470f19['_isAttached']=_0x347529,_0x470f19['isAttached']=()=>_0x470f19['_isAttached'],_0x470f19;}function B(_0x1cd4e1,_0x3be915,_0x4c1d57){const _0x27a453='elementEnd'==_0x1cd4e1['type']?_0x4c1d57['createPositionAt'](_0x1cd4e1['item'],'end'):_0x4c1d57['createPositionBefore'](_0x1cd4e1['item']);return _0x4c1d57['createPositionFromPath'](_0x3be915,_0x27a453['path'],_0x27a453['stickiness']);}function J(_0x42b62b,_0x4c4141,_0x3ce9ec){const _0x5ece75='elementStart'==_0x42b62b['type']?_0x3ce9ec['createPositionAt'](_0x42b62b['item'],0x0):_0x3ce9ec['createPositionAfter'](_0x42b62b['item']);return _0x3ce9ec['createPositionFromPath'](_0x4c4141,_0x5ece75['path'],_0x5ece75['stickiness']);}class ns extends _0x12ccec{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x141246,_0x5efa1e){super(_0x141246),this['focusTracker']=new _0x28c48b(),this['keystrokes']=new _0x5f4f2d(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5efa1e),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x3dffdf({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5ea886=_0x357233=>_0x357233['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5ea886),this['keystrokes']['set']('arrowleft',_0x5ea886),this['keystrokes']['set']('arrowup',_0x5ea886),this['keystrokes']['set']('arrowdown',_0x5ea886);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x49e113){this['revisionNameInputView']['fieldView']['element']['value']=_0x49e113['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3d1a2c){const _0x44a74c=new nt(this['locale'],_0x2956bd),_0x11228c=_0x44a74c['fieldView'];_0x11228c['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x588d44=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3d1a2c&&(_0x588d44+='\x20('+m(this['locale'],'optional')+')'),(_0x44a74c['label']=_0x588d44,_0x11228c['on']('input',()=>{this['revisionNameInputValue']=_0x11228c['element']['value']['trim']();}),_0x44a74c);}}class u extends _0x47f245{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0xbf92ca=this['editor'],_0x249f23=_0xbf92ca['plugins']['get']('RevisionTracker');_0xbf92ca['ui']['componentFactory']['add']('revisionHistory',_0x4e0383=>{const _0x25c942=_0x2e0b5d(_0x4e0383),_0x4ef08f=_0x25c942['panelView']['children'],_0xce47c2=new te(_0x4e0383),_0xa31909=new _0x5300ff(_0x4e0383),_0x5bae78=new _0x1e9806(_0x4e0383),_0x5a362d=new _0x5300ff(_0x4e0383),_0xb50d5e=new _0x1e9806(_0x4e0383);return _0x25c942['bind']('isEnabled')['to'](_0x249f23,'isReady',_0x249f23,'isEnabled',_0xbf92ca,'isReadOnly',(_0x21130a,_0x518825,_0x555402)=>_0x21130a&&_0x518825&&!_0x555402),_0x25c942['buttonView']['set']({'icon':_0x1018a7['history'],'label':m(_0x4e0383,'Revision\x20history'),'tooltip':!0x0}),_0x5bae78['set']({'label':m(_0x4e0383,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x5bae78['bind']('isEnabled')['to'](_0x249f23,'isReady',_0x249f23,'isEnabled',_0xbf92ca,'isReadOnly',(_0x1c6117,_0x1f5095,_0x3f90bc)=>_0x1c6117&&_0x1f5095&&!_0x3f90bc),_0x5bae78['on']('execute',()=>this['_showDialog']()),_0xb50d5e['set']({'label':m(_0x4e0383,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0xb50d5e['bind']('isEnabled')['to'](_0x249f23,'isReady',_0xbf92ca,'isReadOnly',(_0x3f48b9,_0x2d7f94)=>_0x3f48b9&&!_0x2d7f94),_0xb50d5e['on']('execute',()=>{_0xbf92ca['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x25c942['isOpen']=!0x1,_0xbf92ca['editing']['view']['focus']();}),_0xa31909['children']['add'](_0x5bae78),_0x5a362d['children']['add'](_0xb50d5e),_0xce47c2['role']='menu',_0xce47c2['items']['addMany']([_0xa31909,_0x5a362d]),_0x4ef08f['add'](_0xce47c2),_0x25c942;}),_0xbf92ca['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x174786=this['editor'],_0x5d1ab8=_0x174786['locale'],_0x3006aa=new _0x5d993f(_0x5d1ab8),_0x3e3578=new _0x1a39a8(_0x5d1ab8);_0x3006aa['buttonView']['set']({'icon':_0x1018a7['history'],'label':m(_0x5d1ab8,'Revision\x20history')});const _0x553f9c=new _0x5ddf95(_0x5d1ab8,_0x3006aa),_0x172710=new _0x1dee65(_0x5d1ab8);_0x172710['set']({'label':m(_0x5d1ab8,'Save\x20current\x20revision')}),_0x172710['delegate']('execute')['to'](_0x3006aa),_0x172710['on']('execute',()=>{this['_showDialog']();}),_0x553f9c['children']['add'](_0x172710),_0x3e3578['items']['add'](_0x553f9c);const _0x1b591d=new _0x5ddf95(_0x5d1ab8,_0x3006aa),_0x599c3f=new _0x1dee65(_0x5d1ab8);return _0x599c3f['set']({'label':m(_0x5d1ab8,'Open\x20revision\x20history')}),_0x599c3f['delegate']('execute')['to'](_0x3006aa),_0x599c3f['on']('execute',()=>{_0x174786['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x1b591d['children']['add'](_0x599c3f),_0x3e3578['items']['add'](_0x1b591d),_0x3006aa['panelView']['children']['add'](_0x3e3578),_0x3006aa;}['_showDialog'](){const _0x5d0a5a=this['editor'],_0x4366bf=_0x5d0a5a['locale'],_0x3a5a6a=_0x5d0a5a['plugins']['get']('Dialog'),_0x1b9524=_0x5d0a5a['plugins']['get']('RevisionTracker');function _0x3e8f36(_0x139594){_0x5d0a5a['config']['get']('revisionHistory.requireRevisionName')&&''===_0x139594['revisionName']?_0x139594['revisionNameInputView']['errorText']=m(_0x4366bf,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x5d0a5a['plugins']['get'](l)['saveRevision']({'name':_0x139594['revisionName']}),_0x3a5a6a['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3e8f36(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3a5a6a['show']({'id':'revisionSave','title':m(_0x4366bf,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x5d0a5a['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3a5a6a['hide']()},{'label':m(_0x5d0a5a['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x40a8b5){_0x40a8b5['bind']('isEnabled')['to'](_0x1b9524,'isReady',_0x1b9524,'isEnabled',_0x5d0a5a,'isReadOnly',(_0x2af188,_0x3fe4ee,_0x573cbe)=>_0x2af188&&_0x3fe4ee&&!_0x573cbe);},'onExecute':()=>_0x3e8f36(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x29ad33=this['editor'],_0x3b6c91=_0x29ad33['locale'];this['_saveRevisionFormView']=new ns(_0x3b6c91,_0x29ad33['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x12ccec{['changeId'];['_model'];constructor(_0x2b525f,_0x39ad06){super(_0x2b525f),this['_model']=_0x39ad06,this['changeId']=_0x39ad06['id'];const _0x2b378d=this['bindTemplate'],_0xcfe578=m(_0x2b525f,_0x39ad06['data']['isSuggestion']?'Suggested\x20by':'add'==_0x39ad06['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x39ad06['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x2b378d['to']('type',_0x1514e8=>'ck-revision-change__'+_0x1514e8)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0xcfe578}]},{'text':'\x20'+_0x39ad06['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x116fa3(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x4cae9b){super(),this['id']=_0x4cae9b['id']||_0x4813fb(),this['author']=_0x4cae9b['author'],this['type']=_0x4cae9b['type'],this['data']=_0x4cae9b['data']||{},this['rootName']=_0x4cae9b['rootName'],this['set']('createdAt',_0x4cae9b['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(_0x4ea404,_0x3adf87){this['newRevisionId']=_0x4ea404,this['oldRevisionId']=_0x3adf87,this['changes']=new _0x332746();}['_setChanges'](_0x5114dc){for(const _0x2b5bfc of _0x5114dc)this['changes']['add'](_0x2b5bfc);}}const Y={'c':_0x518472,'a':_0x3e1147,'e':_0x52b095,'r':_0x10bd14,'u':_0x564fc7};class d extends _0x47f245{['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[_0x5f1544,_0x2d6f89,j];}constructor(_0x596e74){super(_0x596e74),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',(_0x5bbff7,_0x422975,_0x555685)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1b6f2b=>{for(const _0x4ac32d of this['editor']['editing']['view']['document']['roots'])_0x555685?_0x1b6f2b['removeClass']('ck-editor__editable__overlay',_0x4ac32d):_0x1b6f2b['addClass']('ck-editor__editable__overlay',_0x4ac32d);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x26a1e2=>null!==_0x26a1e2),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4b8adf,_0x38530c,_0x13b4e6)=>_0x4b8adf&&_0x13b4e6?_0x38530c['changes']['getIndex'](_0x13b4e6):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1543dd,_0x3aec6a)=>_0x1543dd?_0x3aec6a['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x2d6f89);}['init'](){const _0x564445=this['editor'],_0x4df7c5=new yt(_0x564445,{'direction':'backward'}),_0x2f8b26=new yt(_0x564445,{'direction':'forward'});(_0x564445['commands']['add']('showPreviousChange',_0x4df7c5),_0x564445['commands']['add']('showNextChange',_0x2f8b26),_0x564445['commands']['add']('restoreRevision',new _t(_0x564445)),this['on']('change:numberOfChanges',()=>{_0x4df7c5['refresh'](),_0x2f8b26['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x564445['enableReadOnlyMode']('revision-viewer'),_0x564445['plugins']['has']('WidgetToolbarRepository'))&&_0x564445['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x491269){await this['loadRevisionData'](_0x491269);const _0x344152={};for(const _0x15ccb4 in _0x491269['diffData']){if(_0x491269['diffData'][_0x15ccb4]['attachChange']&&!_0x491269['diffData'][_0x15ccb4]['attachChange']['isAttached'])continue;const _0x37b7ed=this['_removeRevisionMarkers'](JSON['parse'](_0x491269['diffData'][_0x15ccb4]['insertions'])),_0x4c6f3f=this['editor']['editing']['view']['document'],_0x5c78f7=new _0x41a6bf(_0x4c6f3f,_0x37b7ed['map'](_0x517b4f=>this['_getViewObj'](_0x517b4f)));this['editor']['data']['processor']['useFillerType']('marked'),_0x344152[_0x15ccb4]=this['editor']['data']['processor']['toData'](_0x5c78f7),this['editor']['data']['processor']['useFillerType']('default');}return _0x344152;}async['getRevisionRootsAttributes'](_0x3e00c4){await this['loadRevisionData'](_0x3e00c4);const _0x285d8e={};for(const _0x53fb19 in _0x3e00c4['diffData'])_0x3e00c4['diffData'][_0x53fb19]['attachChange']&&!_0x3e00c4['diffData'][_0x53fb19]['attachChange']['isAttached']||(_0x285d8e[_0x53fb19]=_0x3e00c4['diffData'][_0x53fb19]['attributesAfter']||{});return _0x285d8e;}['_removeRevisionMarkers'](_0x3dc257){return(_0x3dc257=_0x3dc257['filter'](_0x5d607a=>!_0x5d607a['name']||'revision-start'!==_0x5d607a['name']&&'revision-end'!==_0x5d607a['name']))['forEach'](_0x2b6c03=>{'string'!=typeof _0x2b6c03&&(_0x2b6c03['children']=this['_removeRevisionMarkers'](_0x2b6c03['children']),_0x2b6c03['attributes']=_0x2b6c03['attributes']['filter'](_0x4c3aba=>!_0x4c3aba[0x0]['startsWith']('data-revision-')));}),_0x3dc257;}async['compare'](_0x58fd0c,_0x1aecb0,_0x16d462=!0x1){if(!this['isEnabled'])return;const _0x3b14a4=this['diff'],_0x317880=this['repository'],_0x8b4d10='string'==typeof _0x58fd0c?_0x317880['getRevision'](_0x58fd0c):_0x58fd0c,_0x1ca448='string'==typeof _0x1aecb0?_0x317880['getRevision'](_0x1aecb0):_0x1aecb0,_0x4cf78d=_0x8b4d10['id'],_0x2cf19c=_0x1ca448?_0x1ca448['id']:null;if(!_0x16d462&&this['diff']&&this['diff']['newRevisionId']===_0x4cf78d&&this['diff']['oldRevisionId']===_0x2cf19c)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x4cf78d,_0x2cf19c);const _0x2492e4=this['_getRevisionsRange'](_0x8b4d10,_0x1ca448,!0x0)['map'](_0x69c33e=>this['loadRevisionData'](_0x69c33e));return _0x2492e4['push'](new Promise(_0x318bb6=>{setTimeout(_0x318bb6,0x14);})),Promise['all'](_0x2492e4)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x315150=this['_getDiff'](_0x4cf78d,_0x2cf19c);for(const _0x2c63af of _0x315150['changes'])this['_changeIdToChange']['set'](_0x2c63af['id'],_0x2c63af);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x43db71=>{for(const _0x1a5a2f of this['editor']['model']['document']['getRootNames']())_0x43db71['detachRoot'](_0x1a5a2f);for(const _0x1b773e of Object['keys'](_0x315150['model'])){const _0x5009d6=_0x43db71['addRoot'](_0x1b773e);for(const _0x3577c2 of Object['keys'](_0x315150['attributes'][_0x1b773e]))_0x43db71['setAttribute'](_0x3577c2,_0x315150['attributes'][_0x1b773e][_0x3577c2],_0x5009d6);_0x43db71['insert'](_0x315150['model'][_0x1b773e],_0x5009d6,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x315150['changes'])),this['isReady']=!0x0;})['catch'](_0x21672d=>{console['error'](_0x21672d),this['_cleanUp'](),_0x3b14a4&&(this['diff']=_0x3b14a4),this['isReady']=!0x0;});}['addRevisionData'](_0x3135ae,_0x378542){const _0x1ab190=this['repository']['createRevision'](_0x3135ae);return _0x1ab190['on']('_update',(_0x5c39a0,_0x9880dd,_0x1245b3)=>_0x378542(_0x9880dd,_0x1245b3,_0x1ab190)),this['repository']['addRevision'](_0x1ab190),_0x1ab190;}['loadRevisionData'](_0x3ecfbc){if(!_0x3ecfbc||_0x3ecfbc['diffData'])return Promise['resolve']();{const _0x118b4f=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x118b4f,'revisionId':_0x3ecfbc['id']})['then'](_0x138d81=>{_0x3ecfbc['_update']({'diffData':_0x138d81['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},_0x49cd05=>{for(const _0x5a49d4 of this['editor']['model']['document']['getRootNames']())_0x49cd05['detachRoot'](_0x5a49d4);});}['_sortAndFilterDiffChanges'](_0xe30c0e){const _0x28de88=[],_0x538e2a=new Map();for(const _0x4ecfa0 of this['editor']['model']['document']['getRootNames']()){const _0x20279d=this['editor']['editing']['view']['getDomRoot'](_0x4ecfa0);if(!_0x20279d)continue;const _0x4024e3=_0x20279d['getClientRects']()['item'](0x0);_0x4024e3&&(_0x28de88['push'](_0x4ecfa0),_0x538e2a['set'](_0x4ecfa0,_0x4024e3));}return _0x28de88['sort']((_0x1a937c,_0x3bce9a)=>{const _0x228087=_0x538e2a['get'](_0x1a937c),_0x5902e9=_0x538e2a['get'](_0x3bce9a);return _0x228087['y']-_0x5902e9['y']||_0x228087['x']-_0x5902e9['x'];}),(_0xe30c0e=_0xe30c0e['filter'](_0x2f51d1=>_0x28de88['includes'](_0x2f51d1['rootName'])))['sort']((_0x207601,_0x52ccb0)=>_0x28de88['indexOf'](_0x207601['rootName'])-_0x28de88['indexOf'](_0x52ccb0['rootName'])),_0xe30c0e;}['_makeTape'](_0xf336dc){const _0x3f7a30=Array['from'](_0xf336dc['markers'])['filter'](([_0x2a2a0e,_0x1081f3])=>_0x2a2a0e['startsWith']('revision:')&&!_0x1081f3['isCollapsed']),_0x207e83=Array['from'](this['editor']['model']['createRangeIn'](_0xf336dc)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3f7a30['length'])for(const _0x1595d3 of _0x207e83){const [_0x5d083f,_0x41f131]=_0x3f7a30[0x0],[,_0x3fe126,_0x8c873b]=_0x5d083f['split'](':');if(_0x41f131['end']['isEqual'](_0x1595d3['nextPosition'])&&_0x3f7a30['shift'](),(_0x1595d3['previousPosition']['isEqual'](_0x41f131['start'])||_0x1595d3['previousPosition']['isAfter'](_0x41f131['start']))&&('insertion'==_0x3fe126?_0x1595d3['isAdded']={'userId':_0x8c873b}:'deletion'==_0x3fe126&&(_0x1595d3['isRemoved']={'userId':_0x8c873b})),0x0==_0x3f7a30['length'])break;}return _0x207e83;}['_refreshStartEndIndex'](_0x479047){const _0x38b236=new Map();for(let _0x9bd1b0=0x0;_0x9bd1b0<_0x479047['length'];_0x9bd1b0++)'text'===_0x479047[_0x9bd1b0]['type']?(_0x479047[_0x9bd1b0]['item']['startIndex']=_0x9bd1b0,_0x479047[_0x9bd1b0]['item']['endIndex']=_0x9bd1b0):('elementStart'===_0x479047[_0x9bd1b0]['type']?_0x479047[_0x9bd1b0]['item']['startIndex']=_0x9bd1b0:'elementEnd'===_0x479047[_0x9bd1b0]['type']&&(_0x479047[_0x9bd1b0]['item']['endIndex']=_0x9bd1b0),_0x38b236['set'](_0x479047[_0x9bd1b0]['id'],_0x9bd1b0));for(const _0x4c6070 of _0x38b236['values']())'elementStart'===_0x479047[_0x4c6070]['type']?_0x479047[_0x4c6070]['item']['endIndex']=_0x38b236['get'](_0x479047[_0x4c6070]['pairId']):'elementEnd'===_0x479047[_0x4c6070]['type']&&(_0x479047[_0x4c6070]['item']['startIndex']=_0x38b236['get'](_0x479047[_0x4c6070]['pairId']));}['_processTape'](_0x4f4653){for(let _0x3f5aed=0x0;_0x3f5aed<_0x4f4653['length'];_0x3f5aed++){if('elementStart'===_0x4f4653[_0x3f5aed]['type'])_0x4f4653[_0x3f5aed]['item']['startIndex']=_0x3f5aed;else{if('elementEnd'===_0x4f4653[_0x3f5aed]['type']){_0x4f4653[_0x3f5aed]['item']['endIndex']=_0x3f5aed;const _0x25423a=_0x4f4653[_0x3f5aed]['item']['startIndex'];_0x4f4653[_0x25423a]['pairId']=_0x4f4653[_0x3f5aed]['id'],_0x4f4653[_0x3f5aed]['pairId']=_0x4f4653[_0x25423a]['id'];}else _0x4f4653[_0x3f5aed]['item']['startIndex']=_0x3f5aed,_0x4f4653[_0x3f5aed]['item']['endIndex']=_0x3f5aed,_0x4f4653[_0x3f5aed]['pairId']=null;}_0x4f4653[_0x3f5aed]['markersStart']||(_0x4f4653[_0x3f5aed]['markersStart']=[],_0x4f4653[_0x3f5aed]['markersEnd']=[]);}}['_markInsertions'](_0x2c166c,_0x156fc2){const _0x1431cf=_0x2c166c['filter'](_0x56b410=>!_0x56b410['isAdded']);for(let _0x411ad9=0x0;_0x411ad9<_0x156fc2['length'];_0x411ad9++)_0x156fc2[_0x411ad9]['isAdded']&&(_0x1431cf[_0x411ad9]['isAdded']=_0x156fc2[_0x411ad9]['isAdded']);}['_makeModelFromViewString'](_0x3b814c){const _0x38b683=JSON['parse'](_0x3b814c),_0x66b35f=this['editor']['editing']['view']['document'],_0x55382d=new _0x41a6bf(_0x66b35f,_0x38b683['map'](_0x415b2e=>this['_getViewObj'](_0x415b2e)));return this['editor']['data']['toModel'](_0x55382d);}['_getViewObj'](_0x3e175b){const _0x21b41e=this['editor']['editing']['view']['document'];if('string'==typeof _0x3e175b)return new _0x2bf8d1(_0x21b41e,_0x3e175b);{const _0x5c91e4=_0x3e175b['children']['map'](_0x3dc872=>this['_getViewObj'](_0x3dc872));return new(Y[_0x3e175b['type']]||_0x150663)(_0x21b41e,_0x3e175b['name'],_0x3e175b['attributes'],_0x5c91e4);}}['_getDiff'](_0x24da22,_0xf1acd2=null){const _0x2779e3=this['repository']['getRevision'](_0x24da22),_0xa20a87=_0xf1acd2?this['repository']['getRevision'](_0xf1acd2):null,_0x898d9f=this['_getRevisionsRange'](_0x2779e3,_0xa20a87),_0x5bd3ea=_0x898d9f[_0x898d9f['length']-0x1],_0x3ca014=new Map(),_0x20e40f={'model':{},'attributes':{},'changes':[]},_0x1254d5=new Set(),_0x389ff2=new Map();for(let _0x2e738e=_0x898d9f['length']-0x1;_0x2e738e>=0x0;_0x2e738e--){const _0x5aa5e5=_0x898d9f[_0x2e738e];for(const _0x4796e9 of Object['keys'](_0x5aa5e5['diffData']))if(_0x5aa5e5['diffData'][_0x4796e9]['attachChange']){const _0x34c664=_0x5aa5e5['diffData'][_0x4796e9]['attachChange'];_0x34c664['isAttached']?(_0x1254d5['add'](_0x4796e9),_0x389ff2['has'](_0x4796e9)&&_0x389ff2['get'](_0x4796e9)['userId']==_0x34c664['userId']?_0x389ff2['delete'](_0x4796e9):_0x389ff2['set'](_0x4796e9,_0x34c664)):_0x389ff2['has'](_0x4796e9)?(_0x1254d5['delete'](_0x4796e9),_0x389ff2['delete'](_0x4796e9)):(_0x1254d5['add'](_0x4796e9),_0x389ff2['set'](_0x4796e9,_0x34c664));}else _0x1254d5['add'](_0x4796e9);}for(const _0x4efd00 of _0x1254d5){const _0x58be0d=_0x389ff2['has'](_0x4efd00)&&!_0x389ff2['get'](_0x4efd00)['isAttached'];let _0x18f3ef=_0x58be0d?_0x898d9f['length']-0x1:0x0;const _0x418c55=_0x58be0d?-0x1:0x1;for(;_0x898d9f[_0x18f3ef];){const _0x235fb2=_0x898d9f[_0x18f3ef];if(_0x235fb2['diffData'][_0x4efd00]){const _0x2e1de2=_0x58be0d?_0x235fb2['diffData'][_0x4efd00]['attributesBefore']:_0x235fb2['diffData'][_0x4efd00]['attributesAfter'];_0x20e40f['attributes'][_0x4efd00]=_0x2e1de2?_0x36027d(_0x2e1de2):{};break;}_0x18f3ef+=_0x418c55;}}for(const _0x1e5ac8 of _0x898d9f){_0x1e5ac8['model']={};for(const _0x36f21b of _0x1e5ac8['authors'])_0x3ca014['set'](_0x36f21b['id'],_0x36f21b);for(const _0x491547 of _0x1254d5){const _0x41fd19=_0x1e5ac8['diffData'][_0x491547]?_0x1e5ac8['diffData'][_0x491547]['insertions']:'[]',_0x5d451b=_0x1e5ac8['diffData'][_0x491547]?_0x1e5ac8['diffData'][_0x491547]['deletions']:'[]';_0x1e5ac8['model'][_0x491547]={'insertions':this['_makeModelFromViewString'](_0x41fd19),'deletions':this['_makeModelFromViewString'](_0x5d451b)};}}for(const _0x2d8aed of _0x1254d5){let _0x2bf131=null,_0x212e90=0x0;const _0x4aee28=new Map(Array['from'](_0x2779e3['model'][_0x2d8aed]['insertions']['markers'])['filter'](([_0x50e039])=>!_0x50e039['startsWith']('revision:')));let _0x2a6ae3=0x0;for(const _0x5cdf33 of _0x898d9f){const _0x463fb2=this['_makeTape'](_0x5cdf33['model'][_0x2d8aed]['insertions']);_0x5cdf33==_0x2779e3?(_0x2bf131=_0x463fb2,_0x212e90=_0x2bf131['length'],_0x2bf131['forEach'](_0x533f4c=>{_0x533f4c['id']=_0x2a6ae3++;}),this['_processTape'](_0x2bf131)):this['_markInsertions'](_0x2bf131,_0x463fb2);const _0x9ffb1d=_0x2bf131['filter'](_0x5e5a19=>!_0x5e5a19['isAdded'])['map'](_0x2fcd5a=>_0x2fcd5a['id']);let _0x41ce32=0x0;const _0x290e99=this['_makeTape'](_0x5cdf33['model'][_0x2d8aed]['deletions']);_0x290e99['forEach'](_0x47af60=>{_0x47af60['isRemoved']?_0x47af60['id']=_0x212e90++:_0x47af60['id']=_0x9ffb1d[_0x41ce32++];}),this['_processTape'](_0x290e99),this['_setDistance'](_0x2bf131,'isAdded'),this['_setDistance'](_0x290e99,'isRemoved'),_0x5cdf33==_0x2779e3&&this['_markMarkers'](_0x2bf131,_0x4aee28),_0x2bf131=this['_joinTapes'](_0x2bf131,_0x290e99),this['_refreshStartEndIndex'](_0x2bf131),this['_setDistance'](_0x2bf131,'isRemoved');}_0x2bf131=_0x2bf131['filter'](_0x160c0a=>!(_0x160c0a['isAdded']&&_0x160c0a['isRemoved']));const _0x5a2658=new Map(_0x5bd3ea['model'][_0x2d8aed]['deletions']['markers']),_0x2fe98c=new Set(_0x4aee28['keys']());for(const _0x1ccb99 of _0x5a2658['keys']())_0x2fe98c['delete'](_0x1ccb99);this['_markSuggestions'](_0x2bf131,_0x2fe98c),this['_fixObsoleteTags'](_0x2bf131),_0x2bf131=this['_removeMissingPairs'](_0x2bf131),_0x2bf131=this['_markMismatchedRemovedTags'](_0x2bf131),_0x2bf131=this['_removeUnsupportedChanges'](_0x2bf131);const {root:_0x2c1ba7,changes:_0x5b6c72}=this['_makeModelFromTape'](_0x2bf131,_0x3ca014,_0x2d8aed);_0x20e40f['model'][_0x2d8aed]=_0x2c1ba7;const _0x12b5fd=_0x389ff2['get'](_0x2d8aed);if(_0x12b5fd){const _0x34c82d=_0x3ca014['get'](_0x12b5fd['userId']),_0x4dede3=new r({'author':_0x34c82d,'type':_0x12b5fd['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2d8aed});_0x5b6c72['unshift'](_0x4dede3),_0x20e40f['attributes'][_0x2d8aed]['revisionHistoryAttachChange']=_0x4dede3['id'];}_0x20e40f['changes']=_0x20e40f['changes']['concat'](_0x5b6c72);}return _0x20e40f;}['_markMarkers'](_0x381fc9,_0x1672c6){for(let _0x42191b=0x0;_0x42191b<_0x381fc9['length'];_0x42191b++)for(const [_0x3ba2a3,_0x19e9dc]of _0x1672c6)_0x19e9dc['start']['isEqual'](_0x381fc9[_0x42191b]['previousPosition'])&&_0x381fc9[_0x42191b]['markersStart']['push'](_0x3ba2a3),_0x19e9dc['end']['isEqual'](_0x381fc9[_0x42191b]['nextPosition'])&&_0x381fc9[_0x42191b]['markersEnd']['push'](_0x3ba2a3);}['_joinTapes'](_0x166464,_0x4974a3){let _0x31030b=[],_0x567473=0x0,_0x5d7d91=0x0;for(;_0x567473<_0x166464['length']||_0x5d7d91<_0x4974a3['length'];){const _0x5a824a=_0x166464[_0x567473]||{},_0x1b8a95=_0x4974a3[_0x5d7d91]||{};if(_0x5a824a['id']==_0x1b8a95['id'])_0x567473++,_0x5d7d91++,_0x31030b['push'](_0x5a824a);else{if(_0x1b8a95['isRemoved']&&_0x5a824a['isAdded']){const {commonTape:_0x5d8e8a,iEnd:_0x40a5f3,jEnd:_0x3130b}=this['_threeWayMerge'](_0x166464,_0x567473,_0x4974a3,_0x5d7d91);_0x31030b=_0x31030b['concat'](_0x5d8e8a),_0x567473=_0x40a5f3,_0x5d7d91=_0x3130b;}else _0x1b8a95['isRemoved']?(_0x5d7d91++,_0x31030b['push'](_0x1b8a95)):(_0x567473++,_0x31030b['push'](_0x5a824a));}}return _0x31030b;}['_markSuggestions'](_0x10c963,_0x38a1a6){const _0x2a35fd=[];for(let _0x128df1=0x0;_0x128df1<_0x10c963['length'];_0x128df1++){for(let _0x592165=0x0;_0x592165<_0x10c963[_0x128df1]['markersStart']['length'];_0x592165++){const _0x968a1f=_0x10c963[_0x128df1]['markersStart'][_0x592165];if(!_0x38a1a6['has'](_0x968a1f))continue;const {group:_0x593e27,type:_0x2e45b3,authorId:_0x10eb8a}=_0x27219c(_0x968a1f);'revision-suggestion'!=_0x593e27||'insertion'!=_0x2e45b3&&'deletion'!=_0x2e45b3||(_0x2a35fd['unshift']({'type':_0x2e45b3,'name':_0x968a1f,'userId':_0x10eb8a}),_0x10c963[_0x128df1]['markersStart']['splice'](_0x592165,0x1),_0x592165--);}_0x15d094(_0x10c963[_0x128df1]);for(let _0x37b7d5=0x0;_0x37b7d5<_0x10c963[_0x128df1]['markersEnd']['length'];_0x37b7d5++){const _0x21751a=_0x10c963[_0x128df1]['markersEnd'][_0x37b7d5];if(!_0x38a1a6['has'](_0x21751a))continue;const {group:_0x3f6a7b,type:_0x1c77f0}=_0x27219c(_0x21751a);if('revision-suggestion'!=_0x3f6a7b||'insertion'!=_0x1c77f0&&'deletion'!=_0x1c77f0)continue;_0x10c963[_0x128df1]['markersEnd']['splice'](_0x37b7d5,0x1),_0x37b7d5--;const _0x127486=_0x2a35fd['findIndex'](_0x566103=>_0x566103['name']==_0x21751a);_0x127486>-0x1&&_0x2a35fd['splice'](_0x127486,0x1);}}function _0x27219c(_0x1b5507){const _0x1b95a0=_0x1b5507['split'](':');return{'group':_0x1b95a0[0x0],'type':_0x1b95a0[0x1],'subType':_0x1b95a0['length']>=0x5?_0x1b95a0[0x2]:null,'id':_0x1b95a0['length']<0x5?_0x1b95a0[0x2]:_0x1b95a0[0x3],'authorId':_0x1b95a0['length']<0x5?_0x1b95a0[0x3]:_0x1b95a0[0x4],'markerCount':0x6==_0x1b95a0['length']?_0x1b95a0[0x5]:null};}function _0x15d094(_0x416cef){for(let _0x24a0a1=0x0;_0x24a0a1<_0x2a35fd['length'];_0x24a0a1++){if(_0x416cef['isAdded']&&'insertion'==_0x2a35fd[_0x24a0a1]['type'])return _0x416cef['isAddSuggestion']=_0x2a35fd[_0x24a0a1],void delete _0x416cef['isAdded'];if(!_0x416cef['isAdded']&&!_0x416cef['isRemoved']&&'deletion'==_0x2a35fd[_0x24a0a1]['type'])return void(_0x416cef['isRemoveSuggestion']=_0x2a35fd[_0x24a0a1]);}}}['_setDistance'](_0x3bac3b,_0x409883){let _0x5b803e=0x0,_0xeb6ba6=!0x1;const _0x1f9a1b=new Map();for(const _0x2ffe88 of _0x3bac3b)_0x2ffe88[_0x409883]?_0xeb6ba6&&(_0x5b803e++,_0xeb6ba6=!0x1):(_0x5b803e++,_0xeb6ba6=!0x0),_0x1f9a1b['set'](_0x2ffe88['id'],_0x5b803e);for(let _0x528a6f=0x0;_0x528a6f<_0x3bac3b['length'];_0x528a6f++){if('isRemoved'==_0x409883&&_0x3bac3b[_0x528a6f]['isAdded']||'isAdded'==_0x409883&&_0x3bac3b[_0x528a6f]['isRemoved'])continue;if('text'==_0x3bac3b[_0x528a6f]['type']){_0x3bac3b[_0x528a6f]['distance']=0x0;continue;}const _0x55c6d4=_0x1f9a1b['get'](_0x3bac3b[_0x528a6f]['pairId']),_0x95b9ca=_0x1f9a1b['get'](_0x3bac3b[_0x528a6f]['id']);_0x3bac3b[_0x528a6f]['distance']=_0x55c6d4-_0x95b9ca;}}['_getRevisionsRange'](_0x4278df,_0x58f233,_0x3342c6=!0x1){const _0x1b3557=[];let _0x1d10d7=this['repository']['getIndex'](_0x4278df),_0xddf39b=this['repository']['getIndex'](_0x58f233);for(-0x1==_0xddf39b&&(_0xddf39b=this['repository']['_revisions']['length'],_0x3342c6=!0x1);_0x1d10d7<_0xddf39b;)_0x1b3557['push'](this['repository']['getRevision'](_0x1d10d7)),_0x1d10d7++;return _0x3342c6&&_0x1b3557['push'](this['repository']['getRevision'](_0x1d10d7)),_0x1b3557;}['_threeWayMerge'](_0x218d52,_0x55710c,_0x50b611,_0x42c724){const _0x3bf40d=this['editor']['model']['schema'];let _0x3ef5cc=_0x55710c;for(;_0x218d52[_0x3ef5cc]&&_0x218d52[_0x3ef5cc]['isAdded'];)_0x3ef5cc++;let _0x29d435=_0x42c724;for(;_0x50b611[_0x29d435]&&_0x50b611[_0x29d435]['isRemoved'];)_0x29d435++;_0x4c604f(_0x218d52,_0x55710c,_0x3ef5cc),_0x4c604f(_0x50b611,_0x42c724,_0x29d435);const _0x3cbeb5=_0x50b611['slice'](_0x42c724,_0x29d435)['concat'](_0x218d52['slice'](_0x55710c,_0x3ef5cc));return _0x3cbeb5['sort']((_0x4a1dcf,_0x24270b)=>_0x4a1dcf['side']!=_0x24270b['side']?_0x4a1dcf['side']-_0x24270b['side']:_0x4a1dcf['level']!=_0x24270b['level']?_0x4a1dcf['level']-_0x24270b['level']:_0x4a1dcf['distance']!=_0x24270b['distance']?_0x24270b['distance']-_0x4a1dcf['distance']:!!_0x4a1dcf['isAdded']!=!!_0x24270b['isAdded']?-0x1==_0x4a1dcf['side']||0x0==_0x4a1dcf['side']?_0x4a1dcf['isAdded']?-0x1:0x1:_0x4a1dcf['isAdded']?0x1:-0x1:_0x4a1dcf['index']-_0x24270b['index']),{'commonTape':_0x3cbeb5,'iEnd':_0x3ef5cc,'jEnd':_0x29d435};function _0x4c604f(_0x3be4ba,_0x32fe7a,_0x31fcc4){let _0x5305fc=-0x1,_0xd44306=Number['POSITIVE_INFINITY'],_0x57c29c=!0x0;for(let _0x5d1dc4=_0x32fe7a;_0x5d1dc4<_0x31fcc4;_0x5d1dc4++)if(_0x3bf40d['isInline'](_0x3be4ba[_0x5d1dc4]['item'])||(_0x57c29c=!0x1),_0x3be4ba[_0x5d1dc4]['item']['startIndex']<_0x32fe7a&&(_0x5305fc=_0x5d1dc4),_0x3be4ba[_0x5d1dc4]['item']['endIndex']>=_0x31fcc4){_0xd44306=_0x5d1dc4;break;}_0x57c29c&&(_0x5305fc=_0x31fcc4-0x1);for(let _0x5e8306=_0x32fe7a;_0x5e8306<_0x31fcc4;_0x5e8306++)_0x3be4ba[_0x5e8306]['side']=_0x5e8306<=_0x5305fc?-0x1:_0x5e8306<_0xd44306?0x0:0x1,_0x3be4ba[_0x5e8306]['index']=_0x5e8306;let _0x405363=0x0;for(let _0xbc2c57=_0x32fe7a;_0xbc2c57<=_0x5305fc;_0xbc2c57++)0x0==_0x3be4ba[_0xbc2c57]['distance']?_0x3be4ba[_0xbc2c57]['level']=_0x405363:(_0x405363++,_0x3be4ba[_0xbc2c57]['level']=_0x405363,_0x405363++);for(let _0x4aca56=_0x32fe7a;_0x4aca56<_0x31fcc4;_0x4aca56++)0x0==_0x3be4ba[_0x4aca56]['side']&&(_0x3be4ba[_0x4aca56]['level']=_0x405363);_0x405363=0x0;for(let _0x246643=_0x31fcc4-0x1;_0x246643>=_0xd44306;_0x246643--)0x0==_0x3be4ba[_0x246643]['distance']?_0x3be4ba[_0x246643]['level']=_0x405363:(_0x405363--,_0x3be4ba[_0x246643]['level']=_0x405363,_0x405363--);}}['_fixObsoleteTags'](_0x2e4c95){const _0x4a6ebe=new Map(),_0x35d54a=this['editor']['model']['schema'];for(let _0x1bc7df=0x1;_0x1bc7df<_0x2e4c95['length'];_0x1bc7df++){let _0x5f0c02,_0x526f5d,_0x1738c4;const _0x1f4c94=_0x2e4c95[_0x1bc7df],_0x3053ed=_0x2e4c95[_0x1bc7df-0x1];if('text'==_0x1f4c94['type'])continue;if(_0x1f4c94['type']!=_0x3053ed['type'])continue;if(!_0x35d54a['isBlock'](_0x3053ed['item'])||_0x35d54a['isLimit'](_0x3053ed['item']))continue;if(!_0x35d54a['isBlock'](_0x1f4c94['item'])||_0x35d54a['isLimit'](_0x1f4c94['item']))continue;if((_0x2e4c95[_0x1bc7df]['isAdded']||_0x2e4c95[_0x1bc7df]['isAddSuggestion'])&&_0x2e4c95[_0x1bc7df-0x1]['isRemoved'])_0x5f0c02=_0x2e4c95[_0x1bc7df],_0x526f5d=_0x2e4c95[_0x1bc7df-0x1],_0x1738c4=_0x1bc7df-0x1;else{if(!_0x2e4c95[_0x1bc7df]['isRemoved']||!_0x2e4c95[_0x1bc7df-0x1]['isAdded']&&!_0x2e4c95[_0x1bc7df-0x1]['isAddSuggestion'])continue;_0x5f0c02=_0x2e4c95[_0x1bc7df-0x1],_0x526f5d=_0x2e4c95[_0x1bc7df],_0x1738c4=_0x1bc7df;}const _0x3a7c63=_0x5f0c02['level']==_0x526f5d['level'],_0x77ec6a=Math['abs'](_0x5f0c02['level'])<Math['abs'](_0x526f5d['level'])&&0x0==_0x526f5d['distance'];(_0x3a7c63||_0x77ec6a)&&(_0x4a6ebe['set'](_0x526f5d['id'],_0x5f0c02['id']),_0x2e4c95['splice'](_0x1738c4,0x1),_0x1bc7df--,_0x5f0c02['isAdded']=!0x1);}for(let _0x1315b8=0x0;_0x1315b8<_0x2e4c95['length'];_0x1315b8++)_0x4a6ebe['has'](_0x2e4c95[_0x1315b8]['pairId'])&&(_0x2e4c95[_0x1315b8]['pairId']=_0x4a6ebe['get'](_0x2e4c95[_0x1315b8]['pairId']));}['_removeMissingPairs'](_0x389974){const _0x271b61=new Set(_0x389974['map'](_0x5eb776=>_0x5eb776['id']));for(let _0x4dbd86=0x0;_0x4dbd86<_0x389974['length'];_0x4dbd86++)_0x271b61['has'](_0x389974[_0x4dbd86]['pairId'])||0x0==_0x389974[_0x4dbd86]['distance']||(_0x389974[_0x4dbd86]['isIncorrect']=!0x0);return _0x389974['filter'](_0x398848=>!_0x398848['isIncorrect']);}['_markMismatchedRemovedTags'](_0x232b5d){const _0x58b802=new Set();for(let _0x157f26=0x0;_0x157f26<_0x232b5d['length'];_0x157f26++){if(_0x58b802['has'](_0x232b5d[_0x157f26]['id'])&&_0x232b5d[_0x157f26]['isRemoved']&&(_0x232b5d[_0x157f26]['isIncorrect']=!0x0),_0x232b5d[_0x157f26]['isIncorrect'])continue;if(0x0==_0x232b5d[_0x157f26]['distance'])continue;if('elementStart'!=_0x232b5d[_0x157f26]['type'])continue;if(null==_0x232b5d[_0x157f26]['pairId'])continue;let _0x20f8b3=_0x157f26+0x1,_0x484c8f=0x0;for(;_0x232b5d[_0x20f8b3]['id']!=_0x232b5d[_0x157f26]['pairId'];)'elementStart'==_0x232b5d[_0x20f8b3]['type']?_0x484c8f++:'elementEnd'==_0x232b5d[_0x20f8b3]['type']&&_0x484c8f--,_0x20f8b3++;if(0x0!=_0x484c8f){if(_0x232b5d[_0x157f26]['isRemoved'])_0x232b5d[_0x157f26]['isIncorrect']=!0x0;else{for(;_0x20f8b3!=_0x157f26;)_0x232b5d[_0x20f8b3]['isRemoved']&&0x0!=_0x232b5d[_0x20f8b3]['distance']&&(_0x232b5d[_0x20f8b3]['isIncorrect']=!0x0,_0x58b802['add'](_0x232b5d[_0x20f8b3]['pairId'])),_0x20f8b3--;}}}return _0x232b5d['filter'](_0x2fc4db=>!_0x2fc4db['isIncorrect']);}['_removeUnsupportedChanges'](_0x1dbdfa){const _0x58f2e2=this['editor']['model']['schema'];for(let _0x285af1=0x0;_0x285af1<_0x1dbdfa['length'];_0x285af1++){if(!(_0x1dbdfa[_0x285af1]['isAdded']||_0x1dbdfa[_0x285af1]['isAddSuggestion']||_0x1dbdfa[_0x285af1]['isRemoved']||_0x1dbdfa[_0x285af1]['isRemoveSuggestion']))continue;if(0x0==_0x1dbdfa[_0x285af1]['distance'])continue;const _0x508355=_0x1dbdfa[_0x285af1]['item'];_0x58f2e2['isBlock'](_0x508355)||_0x58f2e2['isLimit'](_0x508355)||(_0x1dbdfa[_0x285af1]['isAdded']&&delete _0x1dbdfa[_0x285af1]['isAdded'],_0x1dbdfa[_0x285af1]['isAddSuggestion']&&delete _0x1dbdfa[_0x285af1]['isAddSuggestion'],_0x1dbdfa[_0x285af1]['isRemoveSuggestion']&&delete _0x1dbdfa[_0x285af1]['isRemoveSuggestion'],_0x1dbdfa[_0x285af1]['isRemoved']&&(_0x1dbdfa[_0x285af1]['isIncorrect']=!0x0));}return _0x1dbdfa['filter'](_0x46a1ab=>!_0x46a1ab['isIncorrect']);}['_makeModelFromTape'](_0x1deb1a,_0x5ba7ea,_0x5d568d){const _0x1cb5d3=new mt(),_0x7baf07=[],_0x1ef005=new Map(),_0x1d1d63=this['editor']['model'],_0x5cd1d2=_0x1d1d63['schema'],_0x4984d4=[_0x1cb5d3],_0x3334c9={},_0x39bca4={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1d141c=null;const _0x31b380=[0x0];for(let _0x49d66d=0x0;_0x49d66d<_0x1deb1a['length'];_0x49d66d++)if('elementStart'===_0x1deb1a[_0x49d66d]['type']){_0x1deb1a[_0x49d66d]['previousPosition']=_0x1d1d63['createPositionFromPath'](_0x1cb5d3,_0x31b380);const _0x179d29=new ft(_0x1deb1a[_0x49d66d]['item']['name'],_0x1deb1a[_0x49d66d]['item']['getAttributes']());_0x4984d4[0x0]['_appendChild'](_0x179d29),_0x31b380['push'](0x0),_0x4984d4['unshift'](_0x179d29),_0x1deb1a[_0x49d66d]['nextPosition']=_0x1d1d63['createPositionFromPath'](_0x1cb5d3,_0x31b380);}else'elementEnd'===_0x1deb1a[_0x49d66d]['type']?(_0x4984d4['shift'](),_0x1deb1a[_0x49d66d]['previousPosition']=_0x1d1d63['createPositionFromPath'](_0x1cb5d3,_0x31b380),_0x31b380['pop'](),_0x31b380[_0x31b380['length']-0x1]++,_0x1deb1a[_0x49d66d]['nextPosition']=_0x1d1d63['createPositionFromPath'](_0x1cb5d3,_0x31b380)):(_0x1deb1a[_0x49d66d]['previousPosition']=_0x1d1d63['createPositionFromPath'](_0x1cb5d3,_0x31b380),_0x1d141c?_0x1d141c['_data']+=_0x1deb1a[_0x49d66d]['item']['data']:_0x1d141c=new wt(_0x1deb1a[_0x49d66d]['item']['data'],_0x1deb1a[_0x49d66d]['item']['getAttributes']()),_0x1deb1a[_0x49d66d+0x1]&&'text'===_0x1deb1a[_0x49d66d+0x1]['type']&&_0x37e4f1(_0x1d141c,_0x1deb1a[_0x49d66d+0x1]['item'])||(_0x4984d4[0x0]['_appendChild'](_0x1d141c),_0x1d141c=null),_0x31b380[_0x31b380['length']-0x1]+=_0x1deb1a[_0x49d66d]['item']['offsetSize'],_0x1deb1a[_0x49d66d]['nextPosition']=_0x1d1d63['createPositionFromPath'](_0x1cb5d3,_0x31b380));for(let _0x50b3b6=0x0;_0x50b3b6<_0x1deb1a['length'];_0x50b3b6++){const _0x323185=_0x1deb1a[_0x50b3b6]['previousPosition'],_0x233a3e=_0x1deb1a[_0x50b3b6]['nextPosition'];for(const _0x2287c3 of _0x1deb1a[_0x50b3b6]['markersStart'])_0x1ef005['set'](_0x2287c3,{'start':_0x323185,'end':null});_0x144086('isRemoveSuggestion',_0x50b3b6,_0x323185,_0x233a3e),_0x144086('isAddSuggestion',_0x50b3b6,_0x323185,_0x233a3e),_0x144086('isRemoved',_0x50b3b6,_0x323185,_0x233a3e),_0x144086('isAdded',_0x50b3b6,_0x323185,_0x233a3e);for(const _0x56b787 of _0x1deb1a[_0x50b3b6]['markersEnd']){_0x1ef005['get'](_0x56b787)['end']=_0x233a3e;}}for(const [_0x597f35,_0x14a179]of _0x1ef005){const _0x3ac780=this['editor']['model']['createRange'](_0x14a179['start'],_0x14a179['end']);_0x1cb5d3['markers']['set'](_0x597f35,_0x3ac780);}return _0x7baf07['sort']((_0x390041,_0xa00b70)=>{const _0x71a5ec=_0x1cb5d3['markers']['get']('revision:'+_0x390041['id']),_0x1d71db=_0x1cb5d3['markers']['get']('revision:'+_0xa00b70['id']);return _0x71a5ec['start']['isBefore'](_0x1d71db['start'])?-0x1:_0x71a5ec['start']['isAfter'](_0x1d71db['start'])?0x1:_0x71a5ec['end']['isBefore'](_0x1d71db['end'])?-0x1:_0x71a5ec['end']['isAfter'](_0x1d71db['end'])?0x1:'add'===_0x390041['type']?-0x1:0x1;}),{'root':_0x1cb5d3,'changes':_0x7baf07};function _0x144086(_0x3d178a,_0x385269,_0x1ef5b3,_0xf340e0){const _0x2a15a8=!!_0x1deb1a[_0x385269][_0x3d178a],_0x2b67c1=_0x2a15a8?_0x1deb1a[_0x385269][_0x3d178a]['userId']:null,_0x25a16c=_0x385269===_0x1deb1a['length']-0x1,_0x341c04=_0x39bca4[_0x3d178a][0x0],_0x1ed544=_0x5cd1d2['isObject'](_0x1deb1a[_0x385269]['item']);!_0x3334c9[_0x3d178a]&&_0x2a15a8?_0x3334c9[_0x3d178a]={'start':_0x1ef5b3,'tapeItem':_0x1deb1a[_0x385269],'userId':_0x2b67c1,'type':_0x3d178a}:_0x3334c9[_0x3d178a]&&!_0x2a15a8?(_0x3334c9[_0x3d178a]['end']=_0x1ef5b3,_0x18651a(_0x3334c9[_0x3d178a]),_0x3334c9[_0x3d178a]=null):_0x3334c9[_0x3d178a]&&_0x2a15a8&&_0x3334c9[_0x3d178a]['userId']!==_0x2b67c1&&(_0x3334c9[_0x3d178a]['end']=_0x1ef5b3,_0x341c04&&_0x341c04['userId']===_0x3334c9[_0x3d178a]['userId']||_0x18651a(_0x3334c9[_0x3d178a]),_0x3334c9[_0x3d178a]={'start':_0x1ef5b3,'tapeItem':_0x1deb1a[_0x385269],'userId':_0x2b67c1,'type':_0x3d178a}),_0x3334c9[_0x3d178a]&&_0x1ed544&&('elementStart'!==_0x1deb1a[_0x385269]['type']||_0x341c04&&_0x341c04['userId']===_0x2b67c1||_0x39bca4[_0x3d178a]['unshift']({'userId':_0x2b67c1,'object':_0x1deb1a[_0x385269]['item'],'change':_0x3334c9[_0x3d178a]}),'elementEnd'===_0x1deb1a[_0x385269]['type']&&_0x341c04&&_0x341c04['object']===_0x1deb1a[_0x385269]['item']&&(_0x39bca4[_0x3d178a]['shift'](),_0x3334c9[_0x3d178a]=_0x341c04['change'])),_0x3334c9[_0x3d178a]&&_0x25a16c&&(_0x3334c9[_0x3d178a]['end']=_0xf340e0,_0x18651a(_0x3334c9[_0x3d178a]),_0x3334c9[_0x3d178a]=null);}function _0x18651a({start:_0x58e8ad,end:_0x21d289,tapeItem:_0x916e48,userId:_0x242837,type:_0x4d1354}){const _0x3a26d8=_0x916e48['item'],_0x2669ca=_0x1d1d63['schema']['isBlock'](_0x3a26d8)&&!_0x1d1d63['schema']['isLimit'](_0x3a26d8),_0x5ebb07=_0x58e8ad['nodeAfter']==_0x21d289['parent']&&_0x21d289['isAtStart'];if(_0x2669ca&&_0x5ebb07)return;const _0xa875d8=_0x1d1d63['createRange'](_0x58e8ad,_0x21d289),_0x3ba48e=_0x5ba7ea['get'](_0x242837),_0x578000=new r({'author':_0x3ba48e,'type':'isAdded'==_0x4d1354||'isAddSuggestion'==_0x4d1354?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4d1354||'isRemoveSuggestion'==_0x4d1354},'createdAt':new Date(),'rootName':_0x5d568d});_0x7baf07['push'](_0x578000),_0x1cb5d3['markers']['set']('revision:'+_0x578000['id'],_0xa875d8);}function _0x37e4f1(_0x142876,_0x16438e){const _0x44a2c4=_0x142876['getAttributes'](),_0x312fcc=_0x16438e['getAttributes']();for(const _0x50c393 of _0x44a2c4){if(_0x50c393[0x1]!==_0x16438e['getAttribute'](_0x50c393[0x0]))return!0x1;_0x312fcc['next']();}return _0x312fcc['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4c32db=>{const _0x68e819=_0x4c32db['markerName']['split'](':')[0x1],_0x6427ec=this['_getChangeFromId'](_0x68e819);if(!_0x6427ec)return null;const _0x17c324='add'==_0x6427ec['type']?'insertion':'deletion',_0x1c7dae=['ck-suggestion-marker','ck-suggestion-marker-'+_0x17c324];return _0x6427ec['data']['isSuggestion']&&_0x1c7dae['push']('ck-suggestion-marker-'+_0x17c324+'-new'),this['activeChange']==_0x6427ec&&_0x1c7dae['push']('ck-suggestion-marker--active'),{'classes':_0x1c7dae,'attributes':{'data-change-id':_0x68e819}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3f98d5=>{_0x3f98d5['on']('element:pre',(_0x4a362e,_0x225aaf,_0x715e4)=>{const _0x42ceeb=_0x225aaf['viewItem']['getChild'](0x0);if(!_0x42ceeb||!_0x42ceeb['is']('element','code'))return;if(!_0x715e4['consumable']['consume'](_0x42ceeb,{'attributes':['vid_start','vid_end']}))return;const _0x2a4ce3=_0x225aaf['modelRange']['start']['nodeAfter'];_0x715e4['writer']['setAttribute']('vid_start',_0x42ceeb['getAttribute']('vid_start'),_0x2a4ce3),_0x715e4['writer']['setAttribute']('vid_end',_0x42ceeb['getAttribute']('vid_end'),_0x2a4ce3);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x10dac4=>{_0x10dac4['on']('element',(_0x3ffe0d,_0x418216,_0x5c9ce7)=>{if(!_0x5c9ce7['consumable']['consume'](_0x418216['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x418216['modelRange']['isCollapsed'])return;const _0x5bacaf=_0x418216['modelRange']['start']['nodeAfter'];_0x5bacaf['hasAttribute']('vid_start')||_0x5bacaf['hasAttribute']('vid')||(_0x5c9ce7['writer']['setAttribute']('vid_start',_0x418216['viewItem']['getAttribute']('vid_start'),_0x5bacaf),_0x5c9ce7['writer']['setAttribute']('vid_end',_0x418216['viewItem']['getAttribute']('vid_end'),_0x5bacaf));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x3fff16=>_0x3fff16['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5d2f83,[,_0x2985e7])=>{['vid_start','vid_end','vid']['includes'](_0x2985e7)&&(_0x5d2f83['return']=!0x0,_0x5d2f83['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x34eccb=>{_0x34eccb['on']('attribute:vid',(_0x4c44ff,_0x3636f7,_0x377041)=>{if('\x20'!=_0x3636f7['item']['data']||_0x3636f7['item']['parent']['maxOffset']>0x1)return;if(!_0x377041['consumable']['consume'](_0x3636f7['item'],_0x4c44ff['name']))return;const _0x10452b=_0x377041['writer'],_0x4ec8cd=_0x377041['mapper']['toViewRange'](_0x3636f7['range']);_0x10452b['wrap'](_0x4ec8cd,_0x10452b['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x183f99){const _0x31fd1f=_0x183f99['plugins']['get']('RevisionViewer');return(_0x217b10,_0x3c6782,_0x136008)=>{const _0xfd480f=_0x3c6782['markerName']['split'](':')[0x1],_0x12505e=_0x31fd1f['_getChangeFromId'](_0xfd480f);if(!_0x12505e)return null;const _0x5eac5e='add'==_0x12505e['type']?'split':'merge';if(!_0x136008['consumable']['test'](_0x3c6782['markerRange'],_0x217b10['name']))return;const _0x5c8337=_0x3c6782['markerRange']['getWalker'](),_0x5ed023=_0x3c6782['markerRange']['start'],_0x3c5bc5=_0x183f99['model']['schema'];let _0x346ed9=null,_0x2d7530=null,_0x153fde=!0x1,_0x479890=!0x1;for(const _0x2bf4d6 of _0x5c8337){const _0x235421=_0x2bf4d6['item'];_0x153fde=_0x153fde||_0x3c5bc5['isContent'](_0x235421);const _0x3511c5=_0x136008['mapper']['toViewElement'](_0x235421);if(_0x3511c5&&_0x3511c5['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2bf4d6['type']&&(_0x3c5bc5['isBlock'](_0x235421)&&!_0x3c5bc5['isLimit'](_0x235421)&&(_0x235421['nextSibling']||_0x5ed023['isAtEnd']?_0x346ed9&&_0x346ed9['parent']==_0x235421||(_0x346ed9=_0x235421,_0x81aaaf(_0x2bf4d6['previousPosition']),_0x479890=!0x0):_0x2d7530=_0x2d7530||_0x2bf4d6['previousPosition']));}function _0x81aaaf(_0x1b6528){const _0x30aa86=_0x136008['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5eac5e}),_0x5f5565=_0x136008['mapper']['toViewPosition'](_0x1b6528);_0x12505e['data']['isSuggestion']&&_0x136008['writer']['addClass']('ck-suggestion-marker-'+_0x5eac5e+'-new',_0x30aa86),_0x31fd1f['activeChange']==_0x12505e&&_0x136008['writer']['addClass']('ck-suggestion-marker--active',_0x30aa86),_0x136008['writer']['insert'](_0x5f5565,_0x30aa86),_0x136008['mapper']['bindElementToMarker'](_0x30aa86,_0x3c6782['markerName']);}_0x153fde||_0x479890||!_0x2d7530||_0x81aaaf(_0x2d7530);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xfe9406,_0x276c39,_0x1c9122)=>{const _0x1aa535=_0x1c9122['mapper']['markerNameToElements'](_0x276c39['markerName']);if(_0x1aa535){for(const _0xda4ed6 of _0x1aa535)(_0xda4ed6['hasClass']('ck-suggestion-marker-split')||_0xda4ed6['hasClass']('ck-suggestion-marker-merge'))&&(_0x1c9122['mapper']['unbindElementFromMarkerName'](_0xda4ed6,_0x276c39['markerName']),_0x1c9122['writer']['remove'](_0xda4ed6));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x9d43,_0x7fd802,_0x5f2d16)=>{const _0x34ec8e=_0x7fd802['markerName']['split'](':')[0x1],_0x5564f1=this['_getChangeFromId'](_0x34ec8e);if(!_0x5564f1)return null;const _0x337691='add'==_0x5564f1['type']?'split':'merge';if(_0x5f2d16['consumable']['test'](_0x7fd802['markerRange'],_0x9d43['name']))for(const _0x419735 of _0x7fd802['markerRange']['getItems']()){if(!_0x419735['is']('element','softBreak'))continue;const _0xfb7011=_0x5f2d16['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x337691}),_0x1fb119=_0x5f2d16['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x419735));_0x5564f1['data']['isSuggestion']&&_0x5f2d16['writer']['addClass']('ck-suggestion-marker-'+_0x337691+'-new',_0xfb7011),this['activeChange']==_0x5564f1&&_0x5f2d16['writer']['addClass']('ck-suggestion-marker--active',_0xfb7011),_0x5f2d16['writer']['insert'](_0x1fb119,_0xfb7011),_0x5f2d16['mapper']['bindElementToMarker'](_0xfb7011,_0x7fd802['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x12138f=>{for(const _0x515aca of this['editor']['model']['document']['getRootNames']()){const _0xa0159=this['editor']['model']['document']['getRoot'](_0x515aca),_0x58ecda=this['editor']['editing']['view']['document']['getRoot'](_0x515aca);if(_0x58ecda){const _0x2f8cf0=_0xa0159['getAttribute']('revisionHistoryAttachChange');if(_0x12138f['removeAttribute']('data-change-id',_0x58ecda),_0x12138f['removeClass']('ck-revision-history-root-add',_0x58ecda),_0x12138f['removeClass']('ck-revision-history-root-remove',_0x58ecda),_0x12138f['removeClass']('ck-revision-history-root--active',_0x58ecda),_0x2f8cf0){const _0x399bc7=this['_getChangeFromId'](_0x2f8cf0);if(!_0x399bc7)return null;_0x12138f['setAttribute']('data-change-id',_0x2f8cf0,_0x58ecda),_0x12138f['addClass']('ck-revision-history-root-'+_0x399bc7['type'],_0x58ecda),this['activeChange']==_0x399bc7&&_0x12138f['addClass']('ck-revision-history-root--active',_0x58ecda);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x56244e=>'revision-comment:'+_0x56244e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x383699=>'revision-suggestion:'+_0x383699,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x46a088=>({'name':'suggestion:'+_0x46a088,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3d0e4b=>{const _0x11bb28=_0x3d0e4b['markerName']['split'](':')[0x1];return'insertion'!=_0x11bb28&&'deletion'!=_0x11bb28?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x11bb28]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x5f0940,_0x45dea8,_0x9fa42)=>{const _0x383a7f=_0x9fa42['mapper']['markerNameToElements'](_0x45dea8['markerName']);if(_0x383a7f){for(const _0x2ea93e of _0x383a7f)_0x2ea93e['is']('uiElement')&&(_0x9fa42['mapper']['unbindElementFromMarkerName'](_0x2ea93e,_0x45dea8['markerName']),_0x9fa42['writer']['remove'](_0x2ea93e));}},{'priority':'high'});}['_getChangeFromId'](_0x532063){return this['_changeIdToChange']['get'](_0x532063);}['_getViewForChange'](_0x36b2d5){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x36b2d5),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3dfe61,_0x231d99,_0x7956bf,_0x526734)=>{_0x526734&&this['_balloon']['remove'](_0x526734),_0x7956bf&&(this['_balloon']['add']({'view':_0x7956bf,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x406212=this['editor']['editing'],_0x30956d=this['_getChangeFromId'](_0x7956bf['changeId']);let _0x35dc0a;if(_0x30956d['data']['isOnRoot']){const _0x35373d=_0x406212['view']['getDomRoot'](_0x30956d['rootName']);_0x35dc0a=Array['from'](_0x35373d['getClientRects']());}else{const _0x2bc352=this['editor']['model']['markers']['get']('revision:'+_0x7956bf['changeId']);_0x35dc0a=Array['from'](_0x406212['mapper']['markerNameToElements'](_0x2bc352['name']))['map'](_0x5cbef4=>_0x406212['view']['domConverter']['mapViewToDom'](_0x5cbef4))['map'](_0xe2c1a7=>Array['from'](_0xe2c1a7['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x35dc0a[0x0];return _0x35dc0a['find'](_0x4faa0f=>_0x4faa0f['top']-0x3<=this['_activeViewTarget']['y']&&_0x4faa0f['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4faa0f['left']-0x3<=this['_activeViewTarget']['x']&&_0x4faa0f['right']+0x3>=this['_activeViewTarget']['x'])||_0x35dc0a[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xe06c6a,_0x57016a,_0x833b37,_0x2c7eda)=>{this['activeView']=_0x833b37?this['_getViewForChange'](_0x833b37):null,this['editor']['model']['change'](()=>{const _0x41e7ec=this['editor']['editing'];_0x2c7eda&&(_0x2c7eda['data']['isOnRoot']?_0x41e7ec['view']['change'](_0x2fac80=>{_0x2fac80['removeClass']('ck-revision-history-root--active',_0x41e7ec['view']['document']['getRoot'](_0x2c7eda['rootName']));}):_0x41e7ec['reconvertMarker']('revision:'+_0x2c7eda['id'])),_0x833b37&&(_0x833b37['data']['isOnRoot']?_0x41e7ec['view']['change'](_0x2bf20a=>{_0x2bf20a['addClass']('ck-revision-history-root--active',_0x41e7ec['view']['document']['getRoot'](_0x833b37['rootName']));}):_0x41e7ec['reconvertMarker']('revision:'+_0x833b37['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x592e51,_0x5cad56)=>{if(this['activeChange'])return;const _0xcb9bac=this['_findChangeIdFromDomTarget'](_0x5cad56['target']),_0x12af49=this['_changeIdToChange']['get'](_0xcb9bac);_0x12af49?(this['_activeViewTarget']={'x':_0x5cad56['domEvent']['x'],'y':_0x5cad56['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x12af49)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x5a20fe,_0x310ddd)=>{const _0x370336=this['_findChangeIdFromDomTarget'](_0x310ddd['target']),_0x1e86cf=this['_changeIdToChange']['get'](_0x370336);_0x1e86cf?(this['_activeViewTarget']={'x':_0x310ddd['domEvent']['x'],'y':_0x310ddd['domEvent']['y']},_0x1e86cf===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1e86cf):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3e2357){do{const _0x1f6f82=_0x3e2357['getAttribute']('data-change-id');if(_0x1f6f82)return _0x1f6f82;_0x3e2357=_0x3e2357['parent'];}while(_0x3e2357);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5978db=>{for(const _0x15935a of this['editor']['model']['markers'])_0x5978db['removeMarker'](_0x15935a);});}}function Z(_0x3c017b,_0x518b25){return(_0x309ff4,_0x2cbef,_0x222a9e)=>{if(!_0x222a9e['consumable']['test'](_0x2cbef['markerRange'],_0x309ff4['name']))return;const _0x2e812d=_0x2cbef['markerRange']['getWalker'](),_0x4d1d25=_0x2cbef['markerRange']['start'],_0x27a186=_0x3c017b['model']['schema'];let _0x539835=null,_0x5dfa12=null,_0x4713f1=!0x1,_0x1e37a1=!0x1;for(const _0x5d107f of _0x2e812d){const _0x35e1b2=_0x5d107f['item'];_0x4713f1=_0x4713f1||_0x27a186['isContent'](_0x35e1b2);const _0x606ef4=_0x222a9e['mapper']['toViewElement'](_0x35e1b2);if(_0x606ef4&&_0x606ef4['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5d107f['type']&&(_0x27a186['isBlock'](_0x35e1b2)&&!_0x27a186['isLimit'](_0x35e1b2)&&(_0x35e1b2['nextSibling']||_0x4d1d25['isAtEnd']?_0x539835&&_0x539835['parent']==_0x35e1b2||(_0x539835=_0x35e1b2,_0x374d12(_0x5d107f['previousPosition']),_0x1e37a1=!0x0):_0x5dfa12=_0x5dfa12||_0x5d107f['previousPosition']));}function _0x374d12(_0x3089c4){const _0x2f324a=_0x222a9e['mapper']['toViewPosition'](_0x3089c4),_0x3e7072=_0x222a9e['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x518b25});_0x222a9e['writer']['insert'](_0x2f324a,_0x3e7072),_0x222a9e['mapper']['bindElementToMarker'](_0x3e7072,_0x2cbef['markerName']);}_0x4713f1||_0x1e37a1||!_0x5dfa12||_0x374d12(_0x5dfa12);};}class _t extends _0x5a4468{constructor(_0x2817bb){super(_0x2817bb);const _0xe134c7=_0x2817bb['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0xe134c7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xe134c7,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x438635=this['editor'],_0x515819=_0x438635['plugins']['get'](d),_0x4487e1=_0x515819['isReady']?_0x515819['diff']['newRevisionId']:null;_0x438635['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4487e1);}['refresh'](){const {isReady:_0x2798ba,isEnabled:_0x2457a1,repository:_0x1e6cda,diff:_0x1aeba8}=this['editor']['plugins']['get'](d),_0x1e6740=_0x1aeba8&&_0x1e6cda['getLaterVisibleRevision'](_0x1aeba8['newRevisionId']);this['isEnabled']=_0x2798ba&&_0x2457a1&&Boolean(_0x1e6740);}}class yt extends _0x5a4468{['_step'];constructor(_0x3659d3,{direction:_0xb4658b}){super(_0x3659d3);const _0x418526=_0x3659d3['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0xb4658b?0x1:-0x1,this['listenTo'](_0x418526,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x418526,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x418526,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x3c84c5=this['editor'],_0x35192c=_0x3c84c5['plugins']['get'](d),{isNavigationMode:_0x1e9722,currentChangeNumber:_0xf2e3a9}=_0x35192c;let _0x59110f;if(_0x35192c['activeChange']=_0x1e9722?_0x35192c['diff']['changes']['get'](_0xf2e3a9+this['_step']):_0x35192c['diff']['changes']['first'],_0x35192c['activeChange']['data']['isOnRoot'])_0x59110f=_0x3c84c5['editing']['view']['getDomRoot'](_0x35192c['activeChange']['rootName']);else{const _0x2277ce=_0x3c84c5['model']['markers']['get']('revision:'+_0x35192c['activeChange']['id']);_0x59110f=_0x4a8ca9(_0x3c84c5['editing'],_0x2277ce);}_0x69e4b0({'target':_0x59110f,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0xce01d4,currentChangeNumber:_0x674067,numberOfChanges:_0x2ed484,isReady:_0x220157,isEnabled:_0x5cdbb0}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x5cdbb0&&_0x220157&&_0x2ed484)&&(!_0xce01d4||(0x1===this['_step']?_0x674067<_0x2ed484-0x1:_0x674067>0x0));}}class _i extends _0x12ccec{constructor(_0x3e5342){super(_0x3e5342);const _0x37c377=this['bindTemplate'],_0x26cbf3=new _0x1e9806(_0x3e5342),_0x14a99e=new _0x1e9806(_0x3e5342);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',(_0x3a64fa,_0x38365c)=>_0x3a64fa&&_0x38365c>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x479700,_0x57f87d,_0x54704d,_0x16a35d)=>{if(!_0x479700)return m(_0x3e5342,'Loading...');if(!_0x54704d)return m(_0x3e5342,'No\x20changes');const _0x3d4ef5=m(_0x3e5342,'NUMBER_OF_CHANGES',_0x54704d);return _0x16a35d?m(_0x3e5342,'X_OF_Y_CHANGES',[_0x57f87d+0x1,_0x54704d]):_0x3d4ef5;}),_0x26cbf3['set']({'label':m(_0x3e5342,'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'}),_0x14a99e['set']({'label':m(_0x3e5342,'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'}),_0x26cbf3['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x14a99e['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x26cbf3['on']('execute',()=>this['fire']('execute','backward')),_0x14a99e['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',_0x37c377['if']('_isStatusLabelVisible','ck-hidden',_0x3ad71f=>!_0x3ad71f)]},'children':[{'text':_0x37c377['to']('isNavigationMode',_0xc3200f=>_0xc3200f?m(_0x3e5342,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x3e5342,'Total')+':\x20')}]},{'text':_0x37c377['to']('_statusText')}]},new _0x48992c(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x26cbf3,_0x14a99e]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x47f245{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x267d69=this['editor']['editing']['view'];_0x267d69['change'](_0x255f9c=>{for(const _0x1b2694 of _0x267d69['document']['roots'])_0x255f9c['addClass'](ce,_0x1b2694);});}['hide'](){const _0x3064df=this['editor']['editing']['view'];_0x3064df['change'](_0x2d0b34=>{for(const _0x2b0369 of _0x3064df['document']['roots'])_0x2d0b34['removeClass'](ce,_0x2b0369);});}}class g extends _0x47f245{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,le];}['init'](){const _0x3ebf05=this['editor'],_0x1220a1=_0x3ebf05['plugins']['get'](d),_0x46e013=_0x3ebf05['plugins']['get'](le);_0x3ebf05['ui']['componentFactory']['add']('exitToEditing',_0x13eb50=>{const _0x3c6c8b=new _0x1e9806(_0x13eb50);return _0x3c6c8b['set']({'label':m(_0x13eb50,'Back\x20to\x20editing'),'icon':_0x1018a7['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3c6c8b,'execute',()=>{_0x3ebf05['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3c6c8b;}),_0x3ebf05['ui']['componentFactory']['add']('restoreRevision',_0x21adfe=>{const _0x1d5025=new _0x1e9806(_0x21adfe);return _0x1d5025['set']({'label':m(_0x21adfe,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1d5025['bind']('isEnabled')['to'](_0x3ebf05['commands']['get']('restoreRevision')),this['listenTo'](_0x1d5025,'execute',()=>_0x3ebf05['execute']('restoreRevision')),_0x1d5025;}),_0x3ebf05['ui']['componentFactory']['add']('changesNavigation',_0x223978=>{const _0x58a35b=new _i(_0x223978),_0x40b06c=_0x3ebf05['commands']['get']('showPreviousChange'),_0x58b4a6=_0x3ebf05['commands']['get']('showNextChange');return _0x58a35b['bind']('isBackwardNavigationEnabled')['to'](_0x40b06c,'isEnabled'),_0x58a35b['bind']('isForwardNavigationEnabled')['to'](_0x58b4a6,'isEnabled'),_0x58a35b['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1220a1),this['listenTo'](_0x58a35b,'execute',(_0x15fca4,_0xdde13b)=>{_0x3ebf05['execute']('forward'===_0xdde13b?'showNextChange':'showPreviousChange');}),_0x58a35b;}),_0x46e013['show'](),_0x1220a1['on']('change:isReady',(_0x30d228,_0x335dc4,_0xcd7c21)=>{_0xcd7c21?_0x46e013['hide']():_0x46e013['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x538aea,_0x2206b6){super(_0x538aea,_0x2206b6);const _0x578340=this['bindTemplate'];this['set']({'label':m(_0x538aea,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x538aea,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x578340['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 _0x2bae7a=this['fieldView']['element'];this['_tooltipString']=_0x2bae7a['scrollWidth']>_0x2bae7a['clientWidth']&&_0x2bae7a['value']||'';}}class ti extends _0x12ccec{constructor(_0x22f97e,_0x5315c0,_0x5ef930){super(_0x22f97e);const _0xab1248=new _0x1aa1d0();_0xab1248['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 _0xfb8783=['ck','ck-revision-history-sidebar__revision-author'];_0x5ef930&&_0xfb8783['push']('ck-revision-history-sidebar__revision-author_creator');const _0xc1bb43=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x22f97e,_0x5ef930?'Revision\x20creator':'Revision\x20author')},'children':[_0xab1248,_0x5315c0['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xfb8783},'children':_0xc1bb43});}}function ni(_0x2d26ff,_0x49022c){const _0x303467=_0x2d26ff['bindTemplate'],_0x2be39d=_0x2d26ff['locale'],_0x3fd93a=_0x2e0b5d(_0x2be39d);_0x3fd93a['panelPosition']='sw';const _0x18c7a9=function(_0x5e370e,_0x54f9a8){const _0x1cd7b0=function(_0x309fd9,_0x28f50a){const _0x38625d=_0x309fd9['locale'],_0x278be4={'Compare\x20against\x20selected':m(_0x38625d,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x38625d,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x38625d,'Restore\x20this\x20revision')};return _0x28f50a['map'](_0x2ef478=>{const _0x466f8c=_0x278be4[_0x2ef478['name']];return _0x466f8c&&_0x466f8c!==_0x2ef478['name']&&(_0x2ef478['name']=_0x466f8c),_0x2ef478;});}(_0x5e370e,_0x54f9a8),_0x436f36=new _0x332746();for(const _0x51fec9 of _0x1cd7b0){const _0x332fbb={'type':'button','model':new to({'label':_0x51fec9['name'],'class':_0x51fec9['class'],'withText':!0x0,'role':'menuitem','_action':_0x51fec9['action']})};_0x332fbb['model']['bind']('isEnabled')['to'](_0x5e370e,'isActionsDropdownOpen',_0x19b65f=>'function'!=typeof _0x51fec9['isEnabled']||(!_0x19b65f||_0x51fec9['isEnabled'](_0x5e370e))),_0x436f36['add'](_0x332fbb);}return _0x436f36;}(_0x2d26ff,_0x49022c);return _0x2d26ff['bind']('isActionsDropdownOpen')['to'](_0x3fd93a,'isOpen'),_0x3fd93a['buttonView']['set']({'label':m(_0x2be39d,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x1018a7['threeVerticalDots']}),_0x3fd93a['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x303467['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x303467['to'](_0x37d68b=>_0x37d68b['stopPropagation']())}}),_0x3fd93a['on']('execute',_0x4f941e=>{_0x2d26ff['isReady']&&'function'==typeof _0x4f941e['source']['_action']&&_0x4f941e['source']['_action'](_0x2d26ff);}),_0x462102(_0x3fd93a,_0x18c7a9,{'role':'menu'}),_0x3fd93a['listenTo'](_0x2d26ff,'change:isActionsDropdownOpen',(_0x33d912,_0x1a34c4,_0x2df1d0)=>{if(_0x2df1d0)for(const _0x1df851 of _0x3fd93a['listView']['items']){const _0x211bd2=_0x1df851['children']['first'],_0x4afafa=_0x49022c['find'](_0x301513=>_0x301513['action']===_0x211bd2['_action'])['isVisible'];_0x1df851['isVisible']=void 0x0===_0x4afafa||_0x4afafa(_0x2d26ff);}}),_0x3fd93a;}class ai extends/* #__PURE__ -- @preserve */
26
- _0x2a5179(_0x12ccec){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x3470a7,_0x1b646e,_0x1d562c,_0x4193e6){super(_0x3470a7);const _0x2a9096=this['bindTemplate'],_0x16e283=function(_0xd94bcc,_0x2be08d){const _0x176700=Array['from'](_0x2be08d['authors'])['filter'](_0x3f8165=>_0x3f8165!=_0x2be08d['creator']);return _0x2be08d['creator']&&_0x176700['unshift'](_0x2be08d['creator']),_0x176700['map'](_0x1a4fd9=>new ti(_0xd94bcc,_0x1a4fd9,_0x1a4fd9==_0x2be08d['creator']));}(_0x3470a7,_0x1b646e);this['id']=_0x1b646e['id'],this['_revision']=_0x1b646e,this['_requireRevisionName']=_0x4193e6,this['bind']('name','createdAt')['to'](_0x1b646e),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x4456ae=>{return _0x259fac=_0x3470a7['uiLanguage'],(_0x13f9e1=_0x4456ae)['toLocaleDateString'](_0x259fac,{'month':'long','day':'numeric'})+',\x20'+_0x13f9e1['toLocaleTimeString'](_0x259fac,{'hour':'numeric','minute':'numeric'});var _0x259fac,_0x13f9e1;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x3470a7,_0x2956bd),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x31eeb3=>_0x31eeb3||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x4cc892,_0x370e5a)=>_0x4cc892&&_0x370e5a),this['revisionActionsView']=_0x1d562c&&_0x1d562c['length']?ni(this,_0x1d562c):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x2a9096['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x2a9096['if']('isEnabled','ck-disabled',_0xeec2b9=>!_0xeec2b9),_0x2a9096['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x2a9096['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x2a9096['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':_0x2a9096['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':_0x16e283}]},this['revisionActionsView']],'on':{'click':_0x2a9096['to'](_0x184daf=>{_0x184daf['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x29a49a=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x29a49a,'change',()=>{this['_requireRevisionName']&&!_0x29a49a['value']||this['fire']('setName',{'id':this['id'],'name':_0x29a49a['value']}),_0x29a49a['value']||(_0x29a49a['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function di(_0x39c30d,_0x244abe){const _0x361a60=_0x150ab6['fromJSDate'](_0x39c30d)['setLocale'](_0x244abe),_0x2bf677=_0x150ab6['local'](),_0x8bcfdd=_0x2bf677['minus']({'days':0x1})['startOf']('day');let _0x3daaf1,_0x528243;return _0x361a60['hasSame'](_0x2bf677,'day')?(_0x3daaf1=_0x361a60['startOf']('day')['toJSDate'](),_0x528243=_0x361a60['toRelativeCalendar']()):_0x361a60['hasSame'](_0x8bcfdd,'day')?(_0x3daaf1=_0x8bcfdd['toJSDate'](),_0x528243=_0x361a60['toRelativeCalendar']()):_0x361a60['hasSame'](_0x2bf677,'week')?(_0x3daaf1=_0x361a60['startOf']('week')['toJSDate'](),_0x528243=_0x361a60['weekdayLong']||''):_0x361a60['hasSame'](_0x2bf677,'year')?(_0x3daaf1=_0x361a60['startOf']('month')['toJSDate'](),_0x528243=_0x361a60['monthLong']||''):(_0x3daaf1=_0x361a60['startOf']('year')['toJSDate'](),_0x528243=String(_0x361a60['year'])),{'startDate':_0x3daaf1,'localizedPeriodName':_0x528243};}class mi extends _0x12ccec{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x427655,_0x4ffd6a,_0x33c527,_0x2ba69b){super(_0x427655);const _0x67b7d6=di(_0x4ffd6a,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x4ffd6a,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x33c527,this['_requireRevisionName']=_0x2ba69b,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':_0x67b7d6}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x3c0631){const _0x228289=new ai(this['locale'],_0x3c0631,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x228289);}['removeRevision'](_0x217261){const _0x29d92d=this['revisionViews']['find'](_0x37f281=>_0x37f281['id']===_0x217261['id']);this['revisionViews']['remove'](_0x29d92d);}}class as extends _0x12ccec{constructor(_0x456939){super(_0x456939);const _0x295ab8=new _0x1aa1d0();_0x295ab8['content']=_0x1018a7['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x295ab8,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x456939,'Revision\x20history')]}]});}}class ci extends _0x12ccec{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x10c3d2,_0x2db824,_0x88f032,_0x351c9c){super(_0x10c3d2);const _0x4ab1eb=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x2db824,this['_revisionActions']=_0x88f032,this['_requireRevisionName']=_0x351c9c,this['on']('select',(_0x3666be,_0xb71ab9)=>{this['fire']('revisionSelected',_0xb71ab9);}),this['on']('setName',(_0x277d5d,_0x36048d)=>{this['fire']('revisionSetName',_0x36048d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x10c3d2),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x4ab1eb['if']('isEnabled','ck-disabled',_0x468e25=>!_0x468e25)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x3e77bc of this['_revisions'])this['_addRevision'](_0x3e77bc);this['_revisions']['on']('add',(_0x4c8032,_0x6de342)=>{this['_addRevision'](_0x6de342);}),this['_revisions']['on']('remove',(_0x354c78,_0x280fe3)=>{this['_removeRevision'](_0x280fe3);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x57d875=>_0x57d875['revisionViews']['map'](_0x56e8ad=>_0x56e8ad))['flat']();}['selectRevision'](_0x1708e7){for(const _0x1cbe64 of this['revisionViews'])_0x1708e7&&_0x1708e7['id']===_0x1cbe64['id']?_0x1cbe64['select']():_0x1cbe64['deselect']();}['highlightRevisions'](_0x1851de){for(const _0x4a01ae of this['revisionViews'])_0x1851de['some'](({id:_0x5a928f})=>_0x5a928f===_0x4a01ae['id'])?_0x4a01ae['highlight']():_0x4a01ae['unhighlight']();}['_addRevision'](_0x74537){const _0x1b4cdb=di(_0x74537['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4f15eb=this['timePeriodViews']['get'](0x0);_0x4f15eb&&_0x4f15eb['startDate']['getTime']()===_0x1b4cdb['getTime']()||(_0x4f15eb=new mi(this['locale'],_0x1b4cdb,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4f15eb)),_0x4f15eb['addRevision'](_0x74537);}['_removeRevision'](_0x38e403){const _0x362a37=di(_0x38e403['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x362a37)['removeRevision'](_0x38e403);}['_getTimePeriodViewByStartDate'](_0x5bdcea){return this['timePeriodViews']['find'](_0x5bd4ac=>_0x5bd4ac['startDate']['getTime']()===_0x5bdcea['getTime']());}}class w extends _0x47f245{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x17bb2d,uid as _0x32ae7e,Collection as _0x2733e7,logWarning as _0x4bca8d,FocusTracker as _0x520137,KeystrokeHandler as _0x48d79d,scrollViewportToShowTarget as _0x515f4b,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x44dbd9}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x10c153,set as _0x1c2af7,unset as _0x4bba44,isEqual as _0x4709f3}from'lodash-es';import{Plugin as _0x23fe3b,PendingActions as _0x5d7a9c,icons as _0x5d0720,Command as _0x82edf0,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x36152c,getMarkerDomElement as _0x5990eb,ConfirmMixin as _0x4a7df6,sanitizeEditorConfig as _0x4cc66b}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0xeaf0ed,Element as ft,Range as vt,ViewUIElement as _0x44f7dc,ViewRawElement as _0x10477d,ViewEmptyElement as _0x1313cb,ViewAttributeElement as _0xe31744,ViewContainerElement as _0x5ef4e4,Position as gt,ViewText as _0x4f8a2d,ViewElement as _0x10c154,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x4cb52,injectCssTransitionDisabler as ts,submitHandler as _0x1c5528,LabeledFieldView as nt,createLabeledInputText as _0x1ddc75,createDropdown as _0x4daaa8,ListView as te,ListItemView as _0x32e635,ButtonView as _0x219c24,MenuBarMenuView as _0x327427,MenuBarMenuListView as _0x4081ea,MenuBarMenuListItemView as _0x375dc5,MenuBarMenuListItemButtonView as _0x3b43e0,ContextualBalloon as _0x4804bd,ToolbarSeparatorView as _0x28a40c,IconView as _0x2a92f3,addListToDropdown as _0x34f7ce,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as ut,ToolbarView as lt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x304bdb}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
+ _0x17bb2d(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x18ea9c){super(),this['id']=_0x18ea9c['id']||_0x32ae7e(),this['creator']=_0x18ea9c['creator']||null,this['authors']=_0x18ea9c['authors']||[],this['diffData']=_0x18ea9c['diffData']||null,this['toVersion']=_0x18ea9c['toVersion']||0x0,this['fromVersion']=_0x18ea9c['fromVersion']||0x0,this['set']('name',_0x18ea9c['name']||''),this['set']('createdAt',_0x18ea9c['createdAt']||new Date()),this['set']('attributes',_0x18ea9c['attributes']||{});}['setName'](_0x1dcdf4){this['_update']({'name':_0x1dcdf4});}['setAttribute'](_0x5ef065,_0x38c648){const _0x4f2d3b=_0x10c153(this['attributes']);_0x1c2af7(_0x4f2d3b,_0x5ef065,_0x38c648),this['_update']({'attributes':_0x4f2d3b});}['removeAttribute'](_0x52c6d1){const _0xa0cdfd=_0x10c153(this['attributes']);_0x4bba44(_0xa0cdfd,_0x52c6d1),this['_update']({'attributes':_0xa0cdfd});}['_update'](_0x1328ba,_0x5bcf0d=!0x1){let _0x4611bf=!0x1;const _0x51ff1c={'id':this['id']},_0x2621fd=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xcd0d4a of _0x2621fd){const _0x32c015=_0x1328ba[_0xcd0d4a];void 0x0!==_0x32c015&&_0x32c015!==this[_0xcd0d4a]&&(this[_0xcd0d4a]=_0x32c015,_0x51ff1c[_0xcd0d4a]=_0x32c015,_0x4611bf=!0x0);}_0x4611bf&&(_0x51ff1c['authors']&&(_0x51ff1c['authorsIds']=_0x51ff1c['authors']['map'](_0x45325f=>_0x45325f['id']),delete _0x51ff1c['authors']),this['fire']('_update',_0x51ff1c,_0x5bcf0d));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x224f89=>_0x224f89['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x23fe3b{['_revisions'];static get['requires'](){return[_0x36152c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1fd7d1){super(_0x1fd7d1),this['_revisions']=new _0x2733e7();}['afterInit'](){!async function(_0x4217dc){const _0x3c3285=_0x240cc4([0x4f,0x70,0x48,0x47,0x54,0x76,0x66,0x59,0x72,0x79,0x75,0x49,0x62,0x33,0x56,0x64,0x58,0x50,0x71,0x45,0x78,0x38,0x51,0x6d,0x61,0x32,0x6b,0x6e,0x4b,0x53,0x69,0x36,0x6f,0x6c,0x46,0x5a,0x74,0x31,0x43,0x7a,0x30,0x77,0x4d,0x55,0x41,0x68,0x37,0x44,0x65,0x39,0x63,0x42,0x67,0x52,0x4e,0x34,0x6a,0x4a,0x4c,0x57,0x35,0x73]),_0x351967=0xeb829,_0x6e154b=0x2aaa37db,_0x27de31=0x2aad68eb^_0x6e154b,_0x43977e=window[_0x240cc4([0x44,0x61,0x74,0x65])][_0x240cc4([0x6e,0x6f,0x77])](),_0x415165=_0x4217dc[_0x240cc4([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x575652=new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x57c997=>{_0x415165[_0x240cc4([0x6f,0x6e,0x63,0x65])](_0x240cc4([0x72,0x65,0x61,0x64,0x79]),_0x57c997);}),_0x53acd1={[_0x240cc4([0x6b,0x74,0x79])]:_0x240cc4([0x45,0x43]),[_0x240cc4([0x75,0x73,0x65])]:_0x240cc4([0x73,0x69,0x67]),[_0x240cc4([0x63,0x72,0x76])]:_0x240cc4([0x50,0x2d,0x32,0x35,0x36]),[_0x240cc4([0x78])]:_0x240cc4([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]),[_0x240cc4([0x79])]:_0x240cc4([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]),[_0x240cc4([0x61,0x6c,0x67])]:_0x240cc4([0x45,0x53,0x32,0x35,0x36])},_0x28403f=_0x415165[_0x240cc4([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x240cc4([0x67,0x65,0x74])](_0x240cc4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4efd54(){let _0x3d4199,_0x21d9bb=null,_0x41dc3d=null;try{if(_0x28403f==_0x240cc4([0x47,0x50,0x4c]))return _0x240cc4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3d4199=_0x4dc179(),!_0x3d4199)return _0x240cc4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3d4199[_0x240cc4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x41dc3d=_0x59045b(_0x3d4199[_0x240cc4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3d4199[_0x240cc4([0x6a,0x74,0x69])])),await _0x4638ef()?_0x42f009()?_0x3dd392()?_0x240cc4([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x41cb61()?(_0x3d4199[_0x240cc4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x240cc4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x21d9bb=_0x2cb3a4(_0x240cc4([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3d4199[_0x240cc4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x240cc4([0x74,0x72,0x69,0x61,0x6c])&&(_0x21d9bb=_0x2cb3a4(_0x240cc4([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1dc3d4()):_0x240cc4([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x240cc4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x240cc4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x3db5ef){return _0x240cc4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3dd392(){const _0x148626=[_0x240cc4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x240cc4([0x74,0x72,0x69,0x61,0x6c])][_0x240cc4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3d4199[_0x240cc4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x43977e/0x3e8:0xe10*_0x27de31;return _0x3d4199[_0x240cc4([0x65,0x78,0x70])]<_0x148626;}function _0x42f009(){const _0x5dc9de=_0x3d4199[_0x240cc4([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5dc9de)return!0x1;if(_0x5dc9de[_0x240cc4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x240cc4([0x2a])))return!0x0;if(_0x5dc9de[_0x240cc4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x240cc4([0x52,0x48])))return!0x0;if(_0x5dc9de[_0x240cc4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x240cc4([0x52,0x52,0x48]))){if(_0x32cbcd())return!0x0;if(_0xbc9059()||_0x104212())return!0x0;}return!0x1;}function _0x41cb61(){const _0x2562be=_0x3d4199[_0x240cc4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2562be||0x0==_0x2562be[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x58b933}=new URL(window[_0x240cc4([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2562be[_0x240cc4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x58b933))return!0x0;const _0xd76d99=_0x58b933[_0x240cc4([0x73,0x70,0x6c,0x69,0x74])](_0x240cc4([0x2e]));return _0x2562be[_0x240cc4([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x22e576=>_0x22e576[_0x240cc4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x240cc4([0x2a])))[_0x240cc4([0x6d,0x61,0x70])](_0x158fae=>_0x158fae[_0x240cc4([0x73,0x70,0x6c,0x69,0x74])](_0x240cc4([0x2e])))[_0x240cc4([0x73,0x6f,0x6d,0x65])](_0x205aaa=>_0xd76d99[_0x240cc4([0x65,0x76,0x65,0x72,0x79])]((_0x32d04a,_0xfcb039)=>_0x205aaa[_0xfcb039]===_0x32d04a||_0x205aaa[_0xfcb039]===_0x240cc4([0x2a])));}function _0x1dc3d4(){return _0x21d9bb&&_0x41dc3d?new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4fc3fc,_0x2e2c74)=>{_0x21d9bb[_0x240cc4([0x74,0x68,0x65,0x6e])](_0x4fc3fc,_0x2e2c74),_0x41dc3d[_0x240cc4([0x74,0x68,0x65,0x6e])](_0x22082a=>{_0x22082a!=_0x240cc4([0x56,0x61,0x6c,0x69,0x64])&&_0x4fc3fc(_0x22082a);},_0x2e2c74);}):_0x21d9bb||_0x41dc3d||_0x240cc4([0x56,0x61,0x6c,0x69,0x64]);}}function _0x59045b(_0x4c238b,_0x49f826){return new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x51ba5b=>{if(_0x1ede58())return _0x51ba5b(_0x240cc4([0x56,0x61,0x6c,0x69,0x64]));_0x880cdb(),_0x415165[_0x240cc4([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x240cc4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x212716=!0x1;const _0x1f7d4f=_0x32ae7e();function _0x133877(_0x9821ff){return!!_0x9821ff&&(typeof _0x9821ff===_0x240cc4([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x9821ff===_0x240cc4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x9821ff[_0x240cc4([0x74,0x68,0x65,0x6e])]===_0x240cc4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x9821ff[_0x240cc4([0x63,0x61,0x74,0x63,0x68])]===_0x240cc4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x8dedaf(_0x545802){_0x5f0e8a(_0x545802)[_0x240cc4([0x74,0x68,0x65,0x6e])](_0x3e052d=>{if(!_0x3e052d||_0x3e052d[_0x240cc4([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x240cc4([0x6f,0x6b]))return _0x240cc4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1b875c(_0x30ec8a(_0x1f7d4f+_0x49f826))!=_0x3e052d[_0x240cc4([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x240cc4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x240cc4([0x56,0x61,0x6c,0x69,0x64]);})[_0x240cc4([0x74,0x68,0x65,0x6e])](_0x316c43=>(_0x350425(),_0x316c43),()=>{const _0x4a2e72=_0x14711c();return null==_0x4a2e72?(_0x350425(),_0x240cc4([0x56,0x61,0x6c,0x69,0x64])):_0x240cc4(_0x43977e-_0x4a2e72>(0xea6b3db^_0x6e154b)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x240cc4([0x74,0x68,0x65,0x6e])](_0x51ba5b)[_0x240cc4([0x63,0x61,0x74,0x63,0x68])](()=>{_0x51ba5b(_0x240cc4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x48a023=0x2a9cd95b^_0x6e154b;function _0x350425(){const _0x4d9815=_0x240cc4([0x6c,0x6c,0x63,0x74,0x2d])+_0x1b875c(_0x30ec8a(_0x4c238b)),_0x445587=_0x45a449(_0x1b875c(window[_0x240cc4([0x4d,0x61,0x74,0x68])][_0x240cc4([0x63,0x65,0x69,0x6c])](_0x43977e/_0x48a023)));window[_0x240cc4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x240cc4([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4d9815,_0x445587);}function _0x14711c(){const _0x162cc1=_0x240cc4([0x6c,0x6c,0x63,0x74,0x2d])+_0x1b875c(_0x30ec8a(_0x4c238b)),_0x52819a=window[_0x240cc4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x240cc4([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x162cc1);return _0x52819a?window[_0x240cc4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x45a449(_0x52819a),0x10)*_0x48a023:null;}function _0x5f0e8a(_0x78100d){return new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x939323,_0xdd32dc)=>{_0x78100d[_0x240cc4([0x74,0x68,0x65,0x6e])](_0x939323,_0xdd32dc),window[_0x240cc4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xdd32dc,0x2aabe31b^_0x6e154b);});}}_0x415165[_0x240cc4([0x6f,0x6e])](_0x240cc4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x330004,_0x208934)=>{if(_0x208934[0x0]!=_0x4c238b)return _0x51ba5b(_0x240cc4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x208934[0x1]={..._0x208934[0x1],[_0x240cc4([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1f7d4f};},{[_0x240cc4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x240cc4([0x68,0x69,0x67,0x68])}),_0x415165[_0x240cc4([0x6f,0x6e])](_0x240cc4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5ce9c7=>{_0x133877(_0x5ce9c7[_0x240cc4([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x212716=!0x0,_0x8dedaf(_0x5ce9c7[_0x240cc4([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x240cc4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x240cc4([0x6c,0x6f,0x77])}),_0x575652[_0x240cc4([0x74,0x68,0x65,0x6e])](()=>{_0x212716||_0x51ba5b(_0x240cc4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1ede58(){return _0x415165[_0x240cc4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x240cc4([0x76,0x69,0x65,0x77])][_0x240cc4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x240cc4([0x61,0x75,0x74,0x6f]);}function _0x880cdb(){_0x415165[_0x240cc4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x240cc4([0x76,0x69,0x65,0x77])][_0x240cc4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x240cc4([0x61,0x75,0x74,0x6f]);}}function _0x2cb3a4(_0x3b3e1a){const _0x477034=[new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4da27f=>setTimeout(_0x4da27f,0x2aa30917^_0x6e154b)),_0x575652[_0x240cc4([0x74,0x68,0x65,0x6e])](()=>new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1a8b3b=>{const _0x3262d4=0x2aaa37dc^_0x6e154b,_0x26a2c9=_0x4217dc[_0x240cc4([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x4ac40b(){_0x26a2c9[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3262d4&&_0x1a8b3b();}_0x4ac40b(),_0x26a2c9[_0x240cc4([0x6f,0x6e])](_0x240cc4([0x61,0x64,0x64]),_0x4ac40b);})),new window[(_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3156e5=>{function _0x146fa4(){for(const _0x3d7462 in window)if(window[_0x240cc4([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x240cc4([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3d7462))&&window[_0x3d7462]==_0x351967)return _0x3156e5();_0x415165[_0x240cc4([0x73,0x74,0x61,0x74,0x65])]!=_0x240cc4([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x240cc4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x146fa4,0x2aaa2453^_0x6e154b);}_0x20ee6d(_0x240cc4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x146fa4();})];return window[_0x240cc4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x240cc4([0x72,0x61,0x63,0x65])](_0x477034)[_0x240cc4([0x74,0x68,0x65,0x6e])](()=>_0x3b3e1a);}async function _0x2baab8(){if(await _0x575652,_0x20ee6d(_0x240cc4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x10737a=_0x4217dc[_0x240cc4([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4119c3=_0x4217dc[_0x240cc4([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])](_0x10737a[_0x240cc4([0x69,0x64])]),_0x5a8470=_0x559327(_0x240cc4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5a8470[_0x240cc4([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x10737a['id'],_0x4119c3?_0x4119c3['id']:null,!0x0),_0x5a8470[_0x240cc4([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x240cc4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5a8470[_0x240cc4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5a8470[_0x240cc4([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0xb4e36,void(_0x5a8470[_0x240cc4([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0xb4e36);}if(_0x20ee6d(_0x240cc4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4cde89=_0x559327(_0x240cc4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4cde89[_0x240cc4([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x240cc4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4cde89[_0x240cc4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4cde89[_0x240cc4([0x75,0x70,0x64,0x61,0x74,0x65])]=_0xb4e36,_0x4cde89[_0x240cc4([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0xb4e36;}_0x415165[_0x240cc4([0x6d,0x6f,0x64,0x65,0x6c])][_0x240cc4([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0xb4e36,_0x415165[_0x240cc4([0x6d,0x6f,0x64,0x65,0x6c])][_0x240cc4([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0xb4e36,_0x415165[_0x240cc4([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x240cc4([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x32cbcd(){return _0x20ee6d(_0x240cc4([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x559327(_0x240cc4([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x240cc4([0x73,0x74,0x61,0x74,0x65])]==_0x240cc4([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0xbc9059(){return _0x20ee6d(_0x240cc4([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 _0x104212(){return _0x20ee6d(_0x240cc4([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2456ff(_0x589ec7){const _0x4d0b00=_0x3de764();_0x415165[_0x4d0b00]=_0x240cc4([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])+_0x589ec7,_0x589ec7[_0x240cc4([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x240cc4([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3de764()]=_0x351967),_0x589ec7!=_0x240cc4([0x56,0x61,0x6c,0x69,0x64])&&_0x2baab8();}function _0x3de764(){const _0x49c4e4=window[_0x240cc4([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x240cc4([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x240cc4([0x6e,0x6f,0x77])]())[_0x240cc4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x240cc4([0x2e]),'');let _0x19b5c7=_0x240cc4([0x4f]);for(let _0x42964a=0x0;_0x42964a<_0x49c4e4[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x42964a+=0x2){let _0x2094df=window[_0x240cc4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x49c4e4[_0x240cc4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x42964a,_0x42964a+0x2));_0x2094df>=_0x3c3285[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2094df-=_0x3c3285[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x19b5c7+=_0x3c3285[_0x2094df];}return _0x19b5c7;}function _0x4dc179(){const _0x8c96e2=_0x28403f[_0x240cc4([0x73,0x70,0x6c,0x69,0x74])](_0x240cc4([0x2e]));if(0x3!=_0x8c96e2[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x27e3a4(_0x8c96e2[0x1]);function _0x27e3a4(_0x22d422){const _0x5130d9=_0x5ac599(_0x22d422);return _0x5130d9&&_0x3ceb9f()?_0x5130d9:null;function _0x3ceb9f(){const _0x3702e6=_0x5130d9[_0x240cc4([0x6a,0x74,0x69])],_0x12ea87=window[_0x240cc4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3702e6[_0x240cc4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3702e6[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x55e935={..._0x5130d9,[_0x240cc4([0x6a,0x74,0x69])]:_0x3702e6[_0x240cc4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x3702e6[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x55e935[_0x240cc4([0x76,0x63])],_0x30ec8a(_0x55e935)==_0x12ea87;}}}async function _0x4638ef(){let _0x23af86=!0x0;try{const _0x4d52fc=_0x28403f[_0x240cc4([0x73,0x70,0x6c,0x69,0x74])](_0x240cc4([0x2e])),[_0x556c8e,_0x12faa8,_0xf16d5d]=_0x4d52fc;return _0x41618f(_0x556c8e),await _0x5b9816(_0x556c8e,_0x12faa8,_0xf16d5d),_0x23af86;}catch(_0x416440){return!0x1;}function _0x41618f(_0x1c2d31){const _0x829b33=_0x5ac599(_0x1c2d31);_0x829b33&&_0x829b33[_0x240cc4([0x61,0x6c,0x67])]==_0x240cc4([0x45,0x53,0x32,0x35,0x36])||(_0x23af86=!0x1);}async function _0x5b9816(_0x3e5956,_0x5ab10a,_0x18aa7e){const _0xaaa93c=window[_0x240cc4([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x240cc4([0x66,0x72,0x6f,0x6d])](_0x5e6569(_0x18aa7e),_0x4936b9=>_0x4936b9[_0x240cc4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3fc1b6=new window[(_0x240cc4([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x240cc4([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3e5956+_0x240cc4([0x2e])+_0x5ab10a),_0x247433=window[_0x240cc4([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x240cc4([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x247433)return;const _0x1a946a=await _0x247433[_0x240cc4([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x240cc4([0x6a,0x77,0x6b]),_0x53acd1,{[_0x240cc4([0x6e,0x61,0x6d,0x65])]:_0x240cc4([0x45,0x43,0x44,0x53,0x41]),[_0x240cc4([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x240cc4([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x240cc4([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x247433[_0x240cc4([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x240cc4([0x6e,0x61,0x6d,0x65])]:_0x240cc4([0x45,0x43,0x44,0x53,0x41]),[_0x240cc4([0x68,0x61,0x73,0x68])]:{[_0x240cc4([0x6e,0x61,0x6d,0x65])]:_0x240cc4([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x1a946a,_0xaaa93c,_0x3fc1b6)||(_0x23af86=!0x1);}}function _0x5ac599(_0x252293){return _0x252293[_0x240cc4([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x240cc4([0x65,0x79]))?JSON[_0x240cc4([0x70,0x61,0x72,0x73,0x65])](_0x5e6569(_0x252293)):null;}function _0x5e6569(_0x587e4f){return window[_0x240cc4([0x61,0x74,0x6f,0x62])](_0x587e4f[_0x240cc4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x240cc4([0x2b]))[_0x240cc4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x240cc4([0x2f])));}function _0x30ec8a(_0x4d8b6d){let _0x1c6275=0x1505;function _0x1f74f4(_0x2a28f4){for(let _0x3510d6=0x0;_0x3510d6<_0x2a28f4[_0x240cc4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3510d6++){const _0xcf5ee1=_0x2a28f4[_0x240cc4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x3510d6);_0x1c6275=(_0x1c6275<<0x5)+_0x1c6275+_0xcf5ee1,_0x1c6275&=_0x1c6275;}}function _0x48bd40(_0x2893ff){Array[_0x240cc4([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2893ff)?_0x2893ff[_0x240cc4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x48bd40):_0x2893ff&&typeof _0x2893ff==_0x240cc4([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x240cc4([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2893ff)[_0x240cc4([0x73,0x6f,0x72,0x74])]()[_0x240cc4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0xd0c3a7,_0x42957e])=>{_0x1f74f4(_0xd0c3a7),_0x48bd40(_0x42957e);}):_0x1f74f4(window[_0x240cc4([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2893ff));}return _0x48bd40(_0x4d8b6d),_0x1c6275>>>0x0;}function _0x1b875c(_0x310351){return _0x310351[_0x240cc4([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x240cc4([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x240cc4([0x30]));}function _0x45a449(_0x1d7882){return _0x1d7882[_0x240cc4([0x73,0x70,0x6c,0x69,0x74])]('')[_0x240cc4([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x240cc4([0x6a,0x6f,0x69,0x6e])]('');}function _0x20ee6d(_0x4e5903){return _0x415165[_0x240cc4([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x240cc4([0x68,0x61,0x73])](_0x4e5903);}function _0x559327(_0x5f3342){return _0x415165[_0x240cc4([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x240cc4([0x67,0x65,0x74])](_0x5f3342);}function _0xb4e36(){}function _0x240cc4(_0x230b47){return _0x230b47['map'](_0x6ffd23=>String['fromCharCode'](_0x6ffd23))['join']('');}_0x2456ff(await _0x4efd54());}(this);}['createRevision'](_0x202d44){const _0x4af4f5=this['editor']['plugins']['get']('Users');return new a({'id':_0x202d44['id'],'name':_0x202d44['name'],'creator':_0x202d44['creatorId']?_0x4af4f5['getUser'](_0x202d44['creatorId']):null,'diffData':_0x202d44['diffData']||_0x202d44['data'],'authors':_0x202d44['authorsIds']['map'](_0xc7da45=>_0x4af4f5['getUser'](_0xc7da45)),'createdAt':new Date(_0x202d44['createdAt']),'attributes':_0x202d44['attributes'],'fromVersion':_0x202d44['fromVersion'],'toVersion':_0x202d44['toVersion']});}['addRevision'](_0x25e4ef,_0x1c06de=0x0){this['_revisions']['add'](_0x25e4ef,_0x1c06de);}['getRevision'](_0x2e23d4){return this['_revisions']['get'](_0x2e23d4);}['getRevisions'](_0x2bf892={'toJSON':!0x1}){const _0x5a9e90=Array['from'](this['_revisions']);return _0x5a9e90['reverse'](),_0x2bf892['toJSON']?_0x5a9e90['map'](_0x1eae92=>_0x1eae92['toJSON']()):_0x5a9e90;}['getIndex'](_0x26194){return this['_revisions']['getIndex'](_0x26194);}['getEarlierVisibleRevision'](_0x3992ef){const [,_0x1812f8]=this['getRevisionsIterator'](_0x3992ef,{'direction':'earlier'});return _0x1812f8;}['getLaterVisibleRevision'](_0x4a7405){const [,_0x4f9021]=this['getRevisionsIterator'](_0x4a7405,{'direction':'later'});return _0x4f9021;}['getRevisionsInDiff'](_0xabcd70){const _0x25ea38=[];for(const _0x250214 of this['getRevisionsIterator'](_0xabcd70['newRevisionId']))if(_0x25ea38['push'](_0x250214),_0x250214['id']===_0xabcd70['oldRevisionId'])break;return _0x25ea38;}*['getRevisionsIterator'](_0x16b292,{direction:_0x5ac3ff='earlier',filter:_0x5544e3=()=>!0x0}={}){const _0x4eb2c5='earlier'===_0x5ac3ff?0x1:-0x1;let _0x33eb8e=this['_revisions']['get'](_0x16b292),_0x6f5915=this['getIndex'](_0x33eb8e);for(yield _0x33eb8e;_0x33eb8e;){if(_0x6f5915+=_0x4eb2c5,_0x33eb8e=this['getRevision'](_0x6f5915),!_0x33eb8e)return;_0x5544e3(_0x33eb8e)&&(yield _0x33eb8e);}}}function m(_0x505903,_0x1fa0b8,_0x446102){const t=_0x505903['t'];switch(_0x1fa0b8){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'},_0x446102);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x446102);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const P={'c':_0x5ef4e4,'a':_0xe31744,'e':_0x1313cb,'r':_0x10477d,'u':_0x44f7dc};class l extends _0x23fe3b{['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[_0x36152c,j,_0x5d7a9c];}constructor(_0x1ab094){super(_0x1ab094),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0xb19fb0=_0x32ae7e();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0xb19fb0},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 _0x3cf97b=this['repository']['getRevision'](0x0),_0x4c9682=_0x3cf97b&&null===_0x3cf97b['creator']?_0x3cf97b:null;if(this['_continueCurrentRevision']=!!_0x4c9682&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x11ea73=this['_source']['getCurrentRevisionId'](),_0x35fc04=this['repository']['getRevision'](_0x11ea73);if(_0x35fc04)this['_startingVersion']=_0x35fc04['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x372c95=this['_source']['history']['_operations']['find'](_0xc86532=>!_0xc86532['_isInit']),_0x4d4309=_0x372c95?_0x372c95['baseVersion']:this['_source']['history']['version'];_0x3cf97b?(_0x3cf97b['toVersion']<_0x4d4309&&_0x3cf97b['_update']({'toVersion':_0x4d4309}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4c9682['id'],this['_startingVersion']=_0x4c9682['fromVersion']):(this['_startingVersion']=_0x3cf97b['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4d4309,this['_continueCurrentRevision']=!0x1);}}else _0x4c9682&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4c9682['toVersion'],this['editor']['model']['document']['history']['version']),_0x4c9682['fromVersion']===_0x4c9682['toVersion']?(0x0!==_0x4c9682['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4c9682['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4c9682['id'],this['_startingVersion']=_0x4c9682['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',_0x369739=>!_0x369739),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5ac93f=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x243da9;for(const _0x31981a in _0x5ac93f){const _0xdd9bf8=_0x31981a,_0x354b02=_0x5ac93f[_0xdd9bf8];if('revisionHistoryLicenseKeyValid'==_0x354b02||'revisionHistoryLicenseKeyInvalid'==_0x354b02||'revisionHistoryLicenseKeyExpired'==_0x354b02||'revisionHistoryLicenseKeyDomainLimit'==_0x354b02||'revisionHistoryLicenseKeyNotAllowed'==_0x354b02||'revisionHistoryLicenseKeyEvaluationLimit'==_0x354b02||'revisionHistoryLicenseKeyTrialLimit'==_0x354b02||'revisionHistoryLicenseKeyUsageLimit'==_0x354b02){delete _0x5ac93f[_0xdd9bf8],_0x243da9=_0x354b02,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x243da9&&_0x5ac93f['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x243da9&&_0x5ac93f['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x243da9&&_0x5ac93f['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x243da9&&_0x5ac93f['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x243da9&&_0x5ac93f['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x243da9&&_0x5ac93f['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x243da9&&_0x5ac93f['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x310532=this['repository']['getRevision'](0x0),_0x5d7e39=await this['getRevisionDocumentData'](_0x310532),_0x3353a2=await this['getRevisionRootsAttributes'](_0x310532);this['_replaceEditorDataWithRevisionData'](_0x5d7e39,_0x3353a2);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3371d3){this['_source']=_0x3371d3;}async['update'](){const _0x24f099=await this['_source']['getLatestVersion']();if(_0x24f099>this['currentRevision']['toVersion']){await this['_loadState']();const _0x20da7b=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x24f099});_0x20da7b['authors']=_0x20da7b['authorsIds']['map'](_0x52ff57=>this['editor']['plugins']['get']('Users')['getUser'](_0x52ff57)),this['currentRevision']['_update'](_0x20da7b);}}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'](_0x198028={},_0x3d91c5=null){const _0x91bc5b=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3d91c5>this['currentRevision']['toVersion']&&(_0x3d91c5=null),null===_0x3d91c5&&(_0x3d91c5=await this['_source']['getLatestVersion']());const _0x168904=this['_getFromVersion'](_0x3d91c5),_0x1cd686=this['buildRevisionData']({'from':_0x168904,'to':_0x3d91c5});if(this['currentRevision']['toVersion']<_0x3d91c5){const _0x4aac37=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3d91c5,'to':_0x3d91c5});_0x4aac37['authors']=[],_0x4aac37['authorsIds']=[],_0x4aac37['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x4aac37,!0x0),delete _0x4aac37['authors'],_0x91bc5b['push'](_0x4aac37);}_0x198028['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x198028['name']=_0x198028['name']||null,_0x198028['id']=_0x198028['id']||_0x32ae7e(),_0x198028={..._0x198028,..._0x1cd686};const _0x144221=this['addRevisionData'](_0x198028);_0x91bc5b['push'](_0x198028);const _0x2cc861=this['repository']['getIndex'](_0x144221);if(0x0!==_0x2cc861){const _0x404e2a=this['repository']['getRevision'](_0x2cc861-0x1);if(_0x404e2a['fromVersion']!==_0x3d91c5){const _0x485c7c=this['_revisionDataBuilder']['getData'](_0x3d91c5,_0x404e2a['toVersion']),_0x546456={'id':_0x404e2a['id'],'diffData':_0x485c7c['diffData'],'authorsIds':_0x485c7c['authorsIds'],'authors':_0x485c7c['authorsIds']['map'](_0x4061a0=>this['editor']['plugins']['get']('Users')['getUser'](_0x4061a0)),'fromVersion':_0x3d91c5};_0x404e2a===this['currentRevision']&&(_0x546456['createdAt']=new Date(_0x198028['createdAt']['getTime']()+0xa)),_0x404e2a['_update'](_0x546456,!0x0),delete _0x546456['authors'],_0x91bc5b['push'](_0x546456);}}if(this['adapter']){for(const _0x29f84e of _0x91bc5b)this['_bufferUpdate'](_0x29f84e['id'],_0x29f84e,!0x0);this['sendBufferedUpdates']();}return _0x144221;}['addRevisionData'](_0xbd93ca){const _0x156acb=this['repository']['createRevision'](_0xbd93ca);return this['adapter']&&_0x156acb['on']('_update',(_0x463a8e,_0x11d100,_0x19d075)=>{_0x19d075||(this['_bufferUpdate'](_0x11d100['id'],_0x11d100,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x156acb,this['_findInsertionIndex'](_0x156acb)),_0x156acb;}async['getRevisionDocumentData'](_0x17785f){await this['_loadRevisionData'](_0x17785f);const _0x565067={};for(const _0x2df420 in _0x17785f['diffData']){if(_0x17785f['diffData'][_0x2df420]['attachChange']&&!_0x17785f['diffData'][_0x2df420]['attachChange']['isAttached'])continue;const _0x52c09d=this['_removeRevisionMarkers'](JSON['parse'](_0x17785f['diffData'][_0x2df420]['insertions'])),_0x117810=this['editor']['editing']['view']['document'],_0x1f5ab7=new _0xeaf0ed(_0x117810,_0x52c09d['map'](_0x5a0f78=>C(_0x5a0f78,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x565067[_0x2df420]=this['editor']['data']['processor']['toData'](_0x1f5ab7),this['editor']['data']['processor']['useFillerType']('default');}return _0x565067;}async['getRevisionRootsAttributes'](_0x414a42){await this['_loadRevisionData'](_0x414a42);const _0x41824d={};for(const _0x45487a in _0x414a42['diffData'])_0x414a42['diffData'][_0x45487a]['attachChange']&&!_0x414a42['diffData'][_0x45487a]['attachChange']['isAttached']||(_0x41824d[_0x45487a]=_0x414a42['diffData'][_0x45487a]['attributesAfter']||{});return _0x41824d;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x45abf5=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x35542b=0x0;_0x35542b<_0x45abf5['length'];_0x35542b++){const _0x4272bd=_0x45abf5[_0x35542b];let _0x37ba77=!0x1;for(const _0x1bce1d of Object['keys'](_0x4272bd))void 0x0===_0x4272bd[_0x1bce1d]?delete _0x4272bd[_0x1bce1d]:'id'!==_0x1bce1d&&(_0x37ba77=!0x0);_0x37ba77||(_0x45abf5[_0x35542b]=null);}if(_0x45abf5=_0x45abf5['filter'](_0x164a09=>null!==_0x164a09),!_0x45abf5['length'])return;for(let _0x2f57c8=0x0;_0x2f57c8<_0x45abf5['length'];_0x2f57c8++){const _0x28ac7e=_0x45abf5[_0x2f57c8];void 0x0!==_0x28ac7e['fromVersion']&&void 0x0===_0x28ac7e['toVersion']&&(_0x28ac7e['toVersion']=this['repository']['getRevision'](_0x28ac7e['id'])['toVersion']),void 0x0!==_0x28ac7e['toVersion']&&void 0x0===_0x28ac7e['fromVersion']&&(_0x28ac7e['fromVersion']=this['repository']['getRevision'](_0x28ac7e['id'])['fromVersion']);}const _0x5aeaaa=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x45abf5,_0x5aeaaa)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1ed2fa=>{if(_0x1ed2fa){for(const _0x4eb77b of _0x1ed2fa)this['setRevisionData']({'id':_0x4eb77b['id'],'createdAt':_0x4eb77b['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x45126f,_0x31c7aa){let _0x1d3e76=this['editor']['config']['get']('initialData'),_0x1b5ba7=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1d3e76){_0x1d3e76={};for(const _0x4ebb79 of this['editor']['model']['document']['getRootNames']())_0x1d3e76[_0x4ebb79]='';}if('string'==typeof _0x1d3e76&&(_0x1d3e76={'main':_0x1d3e76}),void 0x0===_0x1b5ba7){_0x1b5ba7={};for(const _0x45647c of this['editor']['model']['document']['getRootNames']())_0x1b5ba7[_0x45647c]={};}let _0x59bbd1=!0x1;const _0xbf75f=Object['keys'](_0x1d3e76),_0x25bb52=Object['keys'](_0x45126f);for(const _0x19b251 of _0xbf75f){if(_0x1d3e76[_0x19b251]!==_0x45126f[_0x19b251]&&''!==_0x1d3e76[_0x19b251]['trim']()){_0x59bbd1=!0x0;break;}if(!_0x4709f3(_0x1b5ba7[_0x19b251],_0x31c7aa[_0x19b251])&&Object['keys'](_0x1b5ba7[_0x19b251])['length']>0x0){_0x59bbd1=!0x0;break;}}_0x59bbd1||(_0x59bbd1=_0x25bb52['some'](_0x143284=>!this['editor']['model']['document']['getRoot'](_0x143284))),_0x59bbd1&&_0x4bca8d('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1d3e76,'editorRootsAttributes':_0x1b5ba7,'revisionData':_0x45126f,'revisionRootsAttributes':_0x31c7aa}),this['editor']['config']['set']('initialData',_0x45126f),this['editor']['config']['set']('rootsAttributes',_0x31c7aa);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x209cb3=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x209cb3['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4b4601){const _0x40b4c0=this['repository']['getRevisions']();_0x40b4c0['reverse']();let _0x2f0035=0x0;for(;_0x2f0035<_0x40b4c0['length'];){const _0x543297=_0x40b4c0[_0x2f0035];if(_0x543297===this['currentRevision']){_0x2f0035++;continue;}if(_0x543297['id']===this['_initialRevisionId'])break;const _0x3c5077=_0x4b4601['toVersion']-_0x543297['toVersion']||_0x4b4601['fromVersion']-_0x543297['fromVersion'];if(_0x3c5077>0x0)break;if(_0x3c5077<0x0)_0x2f0035++;else{if(!_0x4b4601['creator']&&_0x543297['creator'])break;if(_0x543297['creator']||!_0x4b4601['creator']){if(_0x4b4601['createdAt']>_0x543297['createdAt'])break;_0x2f0035++;}else _0x2f0035++;}}return _0x2f0035;}['setRevisionData'](_0x5aecc2){const _0x5ebc11=this['repository']['getRevision'](_0x5aecc2['id']);if(_0x5aecc2['createdAt']&&(_0x5aecc2['createdAt']=new Date(_0x5aecc2['createdAt'])),_0x5aecc2['authorsIds']){const _0x4bfe9d=this['editor']['plugins']['get']('Users');_0x5aecc2['authors']=_0x5aecc2['authorsIds']['map'](_0xcd8607=>_0x4bfe9d['getUser'](_0xcd8607));}_0x5ebc11['_update'](_0x5aecc2,!0x0);}['buildRevisionData']({revision:_0x5bdadd=null,from:_0x32a766=null,to:_0x297bb=null}){_0x32a766=null!==_0x32a766?_0x32a766:_0x5bdadd['fromVersion'],_0x297bb=null!==_0x297bb?_0x297bb:_0x5bdadd['toVersion'];const _0x52d95a=this['_revisionDataBuilder']['getData'](_0x32a766,_0x297bb),_0x35b4ca={'diffData':_0x52d95a['diffData'],'authorsIds':_0x52d95a['authorsIds'],'fromVersion':_0x32a766,'toVersion':_0x297bb};if(!_0x5bdadd||_0x297bb!==_0x5bdadd['toVersion']){const _0x2afbd0=_0x297bb-0x1,_0x41d378=this['_source']['history']['getOperation'](_0x2afbd0);_0x35b4ca['createdAt']=_0x41d378&&_0x41d378['createdAt']||new Date();}if(this['_loadedStateData']&&_0x32a766===this['_loadedStateData']['fromVersion']){for(const _0x90c8eb of this['_loadedStateData']['authors'])_0x35b4ca['authorsIds']['includes'](_0x90c8eb['id'])||_0x35b4ca['authorsIds']['push'](_0x90c8eb['id']);}return _0x35b4ca;}['_loadRevisionData'](_0x43496c){if(!_0x43496c||_0x43496c['diffData'])return Promise['resolve']();{const _0x821f03=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x821f03,'revisionId':_0x43496c['id']})['then'](_0x1fdea7=>{_0x43496c['diffData']=_0x1fdea7['diffData'];});}}['_bufferUpdate'](_0x246af3,_0x139bfa,_0x5cb917){if(this['_bufferedUpdates']['has'](_0x246af3)){const _0x30063b=this['_bufferedUpdates']['get'](_0x246af3);_0x139bfa=_0x5cb917?{..._0x30063b,..._0x139bfa}:{..._0x139bfa,..._0x30063b};}this['_bufferedUpdates']['set'](_0x246af3,_0x139bfa);}['_getFromVersion'](_0xaf8ddc){const _0x3316ec=this['repository']['getRevisions']();_0x3316ec['reverse'](),_0x3316ec['shift']();const _0x3ba13a=_0x3316ec['find'](_0x1f223e=>_0x1f223e['toVersion']<=_0xaf8ddc)['toVersion'];return _0x3ba13a<this['_startingVersion']?this['_startingVersion']:_0x3ba13a;}['_createInitialRevision'](_0x59cdc3){const _0xef9b8a=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0xef9b8a)this['_initialRevisionId']=_0xef9b8a['id'];else{const _0x12f922=!this['editor']['model']['document']['roots']['find'](_0x57f3bd=>this['editor']['model']['hasContent'](_0x57f3bd)),_0x590db7=this['editor']['plugins']['get']('Users')['me']['id'],_0x475a55=m(this['editor']['locale'],_0x12f922?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x59cdc3,'to':_0x59cdc3,'id':this['_initialRevisionId'],'name':_0x475a55,'creatorId':_0x590db7});}}['_createCurrentRevision'](_0x3d8e9b){const _0xd27499=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xd27499),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3d8e9b,'to':_0x3d8e9b,'id':_0xd27499,'name':'','creatorId':null}));}['_makeRevision']({name:_0x160b09,from:_0x19be73,to:_0x11e41e,creatorId:_0x327c0e,id:_0x193da3}){const _0x370531=this['buildRevisionData']({'from':_0x19be73,'to':_0x11e41e});_0x370531['name']=_0x160b09,_0x370531['creatorId']=_0x327c0e,_0x370531['id']=_0x193da3;const _0x576b0e=this['addRevisionData'](_0x370531);return this['adapter']&&this['_bufferUpdate'](_0x370531['id'],_0x370531,!0x0),_0x576b0e;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x519c66){return(_0x519c66=_0x519c66['filter'](_0x30f237=>!_0x30f237['name']||'revision-start'!==_0x30f237['name']&&'revision-end'!==_0x30f237['name']))['forEach'](_0x36ce9a=>{'string'!=typeof _0x36ce9a&&(_0x36ce9a['children']=this['_removeRevisionMarkers'](_0x36ce9a['children']),_0x36ce9a['attributes']=_0x36ce9a['attributes']['filter'](_0x68b5bc=>!_0x68b5bc[0x0]['startsWith']('data-revision-')));}),_0x519c66;}}function C(_0x5d4b43,_0x249d43){const _0x51d1a2=_0x249d43['editing']['view']['document'];if('string'==typeof _0x5d4b43)return new _0x4f8a2d(_0x51d1a2,_0x5d4b43);{const _0x1e2981=_0x5d4b43['children']['map'](_0x3a9e3c=>C(_0x3a9e3c,_0x249d43));return new(P[_0x5d4b43['type']]||_0x10c154)(_0x51d1a2,_0x5d4b43['name'],_0x5d4b43['attributes'],_0x1e2981);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x4886d7){this['editor']=_0x4886d7,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'](_0x511fd5){this['source']=_0x511fd5;const _0x12b245=new Map(),_0x6b93f8=new Map(),_0x547269=this['editor']['model']['document']['roots']['map'](_0x12c813=>_0x12c813['rootName']);for(const _0x4d7156 of _0x547269){const _0x1ae469=this['editor']['model']['document']['getRoot'](_0x4d7156),_0x2f6965=T(_0x1ae469);_0x12b245['set'](_0x4d7156,_0x2f6965),_0x6b93f8['set'](_0x4d7156,Object['fromEntries'](_0x1ae469['getAttributes']()));}const _0x1661e2=Array['from'](this['editor']['model']['markers'])['map'](_0xecefea=>[_0xecefea['name'],_0xecefea['getRange']()]),_0x4aa23c=this['source']['version'];this['_saveMetaData'](_0x4aa23c,_0x12b245,_0x1661e2,_0x6b93f8),this['_startingRevisionId']=this['_revisionId'];const _0x5289e2=new Map(),_0x5f28aa=new Map();for(const _0x43fe04 of _0x547269){const _0x5bcbe0=F(_0x43fe04);_0x5289e2['set'](_0x43fe04,_0x5bcbe0),_0x5f28aa['set'](_0x43fe04,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x5289e2,[],_0x5f28aa);}['getData'](_0x34c247,_0x1a9c20){if(this['_lastFrom']===_0x34c247&&this['_lastTo']<=_0x1a9c20)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x1a9c20,!0x0);else{if(!this['_savedMetaData']['has'](_0x34c247)){const _0x2a65cb=this['_getPreviousFrom'](_0x34c247);this['_calculateMetaData'](_0x2a65cb,_0x34c247,!0x1);}this['_calculateMetaData'](_0x34c247,_0x1a9c20,!0x0);}return this['_lastFrom']=_0x34c247,this['_lastTo']=_0x1a9c20,this['_getState']();}['loadState'](_0x5e8600){this['_reset'](),this['_lastFrom']=_0x5e8600['fromVersion'],this['_lastTo']=_0x5e8600['toVersion'];for(const _0x49b1c7 in _0x5e8600['diffData']){const _0x26f8dc=_0x5e8600['diffData'][_0x49b1c7]['attachChange'],_0x4f6950=_0x10c153(_0x5e8600['diffData'][_0x49b1c7]['attributesBefore'])||{},_0x27d8a1=this['_makeModelFromViewString'](_0x5e8600['diffData'][_0x49b1c7]['deletions']);_0x27d8a1['rootName']=_0x49b1c7,_0x27d8a1['_isAttached']=!_0x26f8dc||!_0x26f8dc['isAttached'],_0x27d8a1['isAttached']=()=>_0x27d8a1['_isAttached'],this['_baseRoots']['set'](_0x49b1c7,_0x27d8a1),this['_baseRootsAttributes']['set'](_0x49b1c7,_0x4f6950),_0x26f8dc&&this['_touchedRoots']['set'](_0x49b1c7,_0x26f8dc);const _0x3d8a98=this['_makeIdsRoot'](_0x27d8a1);this['_baseIdsRoots']['set'](_0x49b1c7,_0x3d8a98);for(const [_0x2dfca9,_0x28f29c]of _0x27d8a1['markers']){if(!_0x2dfca9['startsWith']('revision:'))continue;const _0x42b4aa=_0x2dfca9['split'](':')[0x2];for(const _0x7a23cc of _0x28f29c['getWalker']({'singleCharacters':!0x0})){const _0x5d63ee=this['_getVidAttributeName'](_0x7a23cc),_0x3d6078='elementEnd'==_0x7a23cc['type']?_0x7a23cc['previousPosition']['path']['slice'](0x0,-0x1):_0x7a23cc['previousPosition']['path'],_0x43976b=_0x3d8a98['getNodeByPath'](_0x3d6078)['getAttribute'](_0x5d63ee);this['_touched']['set'](_0x43976b,{'userId':_0x42b4aa});}}}this['_startingRevisionId']=this['_revisionId'];const _0x410fda=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x5cda35=>!this['_touched']['has'](_0x5cda35));let _0x523d45=0x0;const _0x48f379=new Map();for(const _0x5263bd in _0x5e8600['diffData']){const _0x118754=_0x5e8600['diffData'][_0x5263bd]['attachChange'],_0x2e5275=_0x10c153(_0x5e8600['diffData'][_0x5263bd]['attributesAfter'])||{},_0x48d2b2=this['_makeModelFromViewString'](_0x5e8600['diffData'][_0x5263bd]['insertions']);_0x48d2b2['rootName']=_0x5263bd,_0x48d2b2['_isAttached']=!_0x118754||_0x118754['isAttached'],_0x48d2b2['isAttached']=()=>_0x48d2b2['_isAttached'],this['_diffRoots']['set'](_0x5263bd,_0x48d2b2),this['_diffRootsAttributes']['set'](_0x5263bd,_0x2e5275);const _0x28aa9a=this['_makeIdsRoot'](_0x48d2b2,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5263bd,_0x28aa9a),_0x48f379['set'](_0x5263bd,_0x48d2b2['isAttached']()?_0x2e5275:{});for(const [_0x34b2bc,_0x2e2ec1]of _0x48d2b2['markers']){if(!_0x34b2bc['startsWith']('revision:'))continue;const _0x958567=_0x34b2bc['split'](':')[0x2];for(const _0x2834a8 of _0x2e2ec1['getWalker']({'singleCharacters':!0x0})){const _0x16444d=this['_getVidAttributeName'](_0x2834a8),_0x5acefb=this['_revisionId']++,_0x46d54d='elementEnd'==_0x2834a8['type']?_0x2834a8['previousPosition']['path']['slice'](0x0,-0x1):_0x2834a8['previousPosition']['path'];_0x28aa9a['getNodeByPath'](_0x46d54d)['_setAttribute'](_0x16444d,_0x5acefb),this['_touched']['set'](_0x5acefb,{'userId':_0x958567});}}for(const _0x17d2c1 of this['editor']['model']['createRangeIn'](_0x48d2b2)['getWalker']({'singleCharacters':!0x0})){const _0x3ece87=this['_getVidAttributeName'](_0x17d2c1),_0x57017c='elementEnd'==_0x17d2c1['type']?_0x17d2c1['previousPosition']['path']['slice'](0x0,-0x1):_0x17d2c1['previousPosition']['path'],_0x1680ad=_0x28aa9a['getNodeByPath'](_0x57017c);_0x1680ad['getAttribute'](_0x3ece87)>0x0||_0x1680ad['_setAttribute'](_0x3ece87,_0x410fda[_0x523d45++]);}for(const [_0xd8f515,_0x4a7f67]of _0x48d2b2['markers'])_0xd8f515['startsWith']('revision:')||this['_markers']['set'](_0xd8f515,_0x4a7f67);}const _0x12d176=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x12d176),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x12d176,0x1));const _0x3780c3=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x3780c3),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3780c3,0x1));const _0x59a6f3=Array['from'](this['_diffRoots'])['map'](([_0x3bd563,_0x527cc2])=>[_0x3bd563,T(_0x527cc2)]);this['_saveMetaData'](this['_lastTo'],_0x59a6f3,this['_markers'],_0x48f379);}['_makeModelFromViewString'](_0x1dce15){const _0x1ab1e2=JSON['parse'](_0x1dce15),_0x50cfde=this['editor']['editing']['view']['document'],_0x18aa7d=new _0xeaf0ed(_0x50cfde,_0x1ab1e2['map'](_0x31336f=>C(_0x31336f,this['editor'])));return this['editor']['data']['toModel'](_0x18aa7d);}['_saveMetaData'](_0x415e5d,_0xb12a90,_0x114f9b,_0x31a4d6){const _0x111b53=new Map(_0xb12a90),_0x2bc6aa=new Map(_0x10c153(_0x31a4d6)),_0x3afc81=new Map();for(const [_0x192b06,_0xcc5c93]of _0x114f9b)_0x3afc81['set'](_0x192b06,{'start':_0xcc5c93['start']['clone'](),'end':_0xcc5c93['end']['clone'](),'rootName':_0xcc5c93['root']['rootName']});this['_savedMetaData']['set'](_0x415e5d,{'roots':_0x111b53,'markers':_0x3afc81,'rootsAttributes':_0x2bc6aa});}['_removeMetaData'](_0x1b5df9){this['_savedMetaData']['delete'](_0x1b5df9);}['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'](_0x2d1068,_0x14fa58=null){let _0x55e7d4=null;_0x2d1068['is']('documentFragment')||(_0x55e7d4=new ft(_0x2d1068['name'],{'vid_start':null===_0x14fa58?this['_revisionId']++:_0x14fa58++}));const _0x453858=[];for(const _0x19ba64 of _0x2d1068['getChildren']())if(_0x19ba64['is']('element')){_0x453858['push'](this['_makeIdsRoot'](_0x19ba64,_0x14fa58));const _0x3c130e=_0x453858[_0x453858['length']-0x1];null!==_0x14fa58&&(_0x14fa58=_0x3c130e['is']('element','$text')?_0x3c130e['getAttribute']('vid')+0x1:_0x3c130e['getAttribute']('vid_end')+0x1);}else{for(let _0x3a0d94=0x0;_0x3a0d94<_0x19ba64['offsetSize'];_0x3a0d94++)_0x453858['push'](new ft('$text',{'vid':null===_0x14fa58?this['_revisionId']++:_0x14fa58++}));}if(_0x2d1068['is']('documentFragment')){const _0x35f868=F(_0x2d1068['rootName']);return _0x35f868['_insertChild'](0x0,_0x453858),_0x35f868;}return _0x55e7d4['_setAttribute']('vid_end',null===_0x14fa58?this['_revisionId']++:_0x14fa58++),_0x55e7d4['_insertChild'](0x0,_0x453858),_0x55e7d4;}['_calculateMetaData'](_0x431445,_0x676f5e,_0x3a51de){this['_reset']();const {roots:_0x316e38,markers:_0x184a6d,rootsAttributes:_0x5047e4}=this['_savedMetaData']['get'](_0x431445);this['_baseRoots']=new Map(_0x316e38),this['_baseRootsAttributes']=new Map(_0x10c153(_0x5047e4));for(const [_0x9c3779,_0x1126cf]of this['_baseRoots'])if('$graveyard'!==_0x9c3779&&(this['_diffRoots']['set'](_0x9c3779,T(_0x1126cf)),this['_diffRootsAttributes']=new Map(_0x10c153(_0x5047e4)),_0x3a51de)){const _0x191725=this['_revisionId'];this['_idsRoots']['set'](_0x9c3779,this['_makeIdsRoot'](_0x1126cf)),this['_baseIdsRoots']['set'](_0x9c3779,this['_makeIdsRoot'](_0x1126cf,_0x191725));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x3a51de&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0xff0fd8,_0x2d7580]of _0x184a6d){const _0x5a20b7=this['_baseRoots']['get'](_0x2d7580['rootName']),_0x43580d=this['_diffRoots']['get'](_0x2d7580['rootName']),_0x41a454=new vt(this['_fixPosition'](_0x2d7580['start'],_0x5a20b7),this['_fixPosition'](_0x2d7580['end'],_0x5a20b7)),_0x59b956=this['_fixRange'](_0x41a454,_0x43580d);_0x5a20b7['markers']['set'](_0xff0fd8,_0x41a454),this['_markers']['set'](_0xff0fd8,_0x59b956);}this['_applyOperations'](_0x431445,_0x676f5e,_0x3a51de);}['_applyOperations'](_0x477652,_0x3bf0a6,_0x14a3bc){for(const _0x2d3c4f of this['source']['getOperations'](_0x477652,_0x3bf0a6))this['_handleOperation'](_0x2d3c4f,_0x14a3bc);for(const _0x21db46 of this['_diffRoots']['values']())_0x21db46['markers']['clear']();for(const [_0x1ce0fd,_0x506b8a]of this['_markers']){this['_diffRoots']['get'](_0x506b8a['root']['rootName'])['markers']['set'](_0x1ce0fd,_0x506b8a['clone']());}const _0x583bac=new Map(),_0x32514f=new Map();for(const [_0x1350d7,_0x3321c0]of this['_diffRoots'])_0x583bac['set'](_0x1350d7,T(_0x3321c0)),_0x32514f['set'](_0x1350d7,this['_diffRootsAttributes']['get'](_0x1350d7));this['_saveMetaData'](_0x3bf0a6,_0x583bac,this['_markers'],_0x32514f);}['_getPreviousFrom'](_0x4a054f){const _0x2966b3=Array['from'](this['_savedMetaData']['keys']());_0x2966b3['sort']((_0x5bde0d,_0x702b83)=>_0x5bde0d-_0x702b83),_0x2966b3['reverse']();for(const _0x49b59c of _0x2966b3)if(_0x49b59c<_0x4a054f)return _0x49b59c;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x19f49c,_0x1cb2ed){const _0x350621=Array['from'](_0x1cb2ed['markers'])['map'](([_0x404c06,_0x488380])=>[_0x404c06,this['_fixRange'](_0x488380,_0x19f49c)]);_0x19f49c['markers']=new Map(_0x350621);}['_transformMarkers'](_0xb6055){for(const _0x4382ee of this['_markers']['values']()){const _0x2ef3b4=_0x4382ee['getTransformedByOperation'](_0xb6055),_0x2c27cd=vt['_createFromRanges'](_0x2ef3b4);_0x4382ee['start']=_0x2c27cd['start'],_0x4382ee['end']=_0x2c27cd['end'];}}['_handleOperation'](_0x5177de,_0x24c84f){if('addRoot'!=_0x5177de['type']&&'detachRoot'!=_0x5177de['type']){if('insert'==_0x5177de['type']){const _0x1a02f9=_0x5177de['position']['root']['rootName'];this['_diffRoots']['has'](_0x1a02f9)||(this['_diffRoots']['set'](_0x1a02f9,F(_0x1a02f9,!0x0)),this['_diffRootsAttributes']['set'](_0x1a02f9,{}),_0x24c84f&&this['_idsRoots']['set'](_0x1a02f9,F(_0x1a02f9,!0x0)));}else{if('addRootAttribute'==_0x5177de['type']||'removeRootAttribute'==_0x5177de['type']||'changeRootAttribute'==_0x5177de['type'])return void this['_handleRootAttributeOperation'](_0x5177de);'marker'==_0x5177de['type']&&this['_handleMarkerOperation'](_0x5177de);}if('marker'!==_0x5177de['type']){const _0x518831=this['_cloneOperation'](_0x5177de,this['_diffRoots']);_0x518831['_execute'](),this['_transformMarkers'](_0x518831);}if(_0x24c84f)switch(_0x5177de['type']){case'insert':this['_handleInsertOperation'](_0x5177de);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5177de);break;case'merge':this['_handleMergeOperation'](_0x5177de);break;case'split':this['_handleSplitOperation'](_0x5177de);}}else this['_handleRootOperation'](_0x5177de,_0x24c84f);}['_cloneOperation'](_0x5afe4d,_0x26bdda){const _0x453469=_0x5afe4d['clone']();return _0x453469['_authorId']=_0x5afe4d['_authorId'],this['_fixOperation'](_0x453469,_0x26bdda),_0x453469;}['_getBaseVids'](_0x133bce){return _0x133bce['map'](_0x3240af=>{const _0xf3eb18=this['_getVidAttributeName'](_0x3240af);return Number(_0x3240af['item']['getAttribute'](_0xf3eb18));});}['_generateTape'](_0x5ce831,_0x9ed098){if(_0x5ce831['is']('element','$text'))_0x9ed098['push']({'item':_0x5ce831,'type':'text'});else{_0x5ce831['is']('element')&&_0x9ed098['push']({'item':_0x5ce831,'type':'elementStart'});for(const _0x56d202 of _0x5ce831['getChildren']())this['_generateTape'](_0x56d202,_0x9ed098);_0x5ce831['is']('element')&&_0x9ed098['push']({'item':_0x5ce831,'type':'elementEnd'});}return _0x9ed098;}['_getState'](){const _0x43d9ed=new Map(this['_touched']),_0x31e1ab=new Map(_0x43d9ed),_0x58fe00=new Map(),_0x124c7c={'insertions':{},'deletions':{}},_0x1934f8={'insertions':{},'deletions':{}},_0x32faf9=new Map(),_0x5634e7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x5634e7['delete']('$graveyard');for(const _0x360476 of _0x5634e7){const _0xc4d848=this['_diffRoots']['get'](_0x360476)||F(_0x360476,!0x1),_0x44ecc0=this['_baseRoots']['get'](_0x360476)||F(_0x360476,!0x1);_0xc4d848['isAttached']()||_0x44ecc0['isAttached']()?(_0x124c7c['insertions'][_0x360476]=T(_0xc4d848),_0x124c7c['deletions'][_0x360476]=T(_0x44ecc0),this['_copyMarkers'](_0x124c7c['deletions'][_0x360476],_0x44ecc0),this['_copyMarkers'](_0x124c7c['insertions'][_0x360476],_0xc4d848),_0x1934f8['insertions'][_0x360476]=this['_generateTape'](this['_idsRoots']['get'](_0x360476),[]),_0x1934f8['deletions'][_0x360476]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x360476)||F(_0x360476,!0x1),[])):_0x5634e7['delete'](_0x360476);}for(const _0x426317 of _0x5634e7){const _0x262ec2=_0x1934f8['insertions'][_0x426317];for(const _0x1debf6 of _0x262ec2){const _0x3c7483=this['_getVidAttributeName'](_0x1debf6),_0x5d6d74=_0x1debf6['item']['getAttribute'](_0x3c7483);_0x31e1ab['delete'](_0x5d6d74),_0x5d6d74>=this['_startingRevisionId']&&_0x58fe00['set'](_0x5d6d74,_0x43d9ed['get'](_0x5d6d74));}}for(const _0x5b8617 of _0x5634e7){const _0x200ad4=_0x1934f8['insertions'][_0x5b8617],_0x20f3c9=this['_getBaseVids'](_0x1934f8['deletions'][_0x5b8617]);let _0x3c4674=0x0;for(const _0x179506 of _0x200ad4){const _0x3a868d=this['_getVidAttributeName'](_0x179506),_0x35de81=_0x179506['item']['getAttribute'](_0x3a868d);if(!_0x58fe00['has'](_0x35de81)&&!_0x32faf9['has'](_0x35de81)){if(_0x31e1ab['has'](_0x35de81))_0x3c4674++;else{if(_0x35de81!=_0x20f3c9[_0x3c4674]){const _0x57094c=_0x43d9ed['get'](_0x35de81)||_0x43d9ed['get'](_0x20f3c9[_0x3c4674]);for(;_0x35de81!=_0x20f3c9[_0x3c4674];)_0x31e1ab['has'](_0x20f3c9[_0x3c4674])||(_0x32faf9['set'](_0x20f3c9[_0x3c4674],_0x57094c),_0x43d9ed['set'](_0x20f3c9[_0x3c4674],_0x57094c)),_0x3c4674++;}_0x3c4674++;}}}}for(const _0x1bab4a of _0x5634e7){const _0x18f1de=_0x1934f8['insertions'][_0x1bab4a];for(const _0x2706fc of _0x18f1de){const _0x3d9841=this['_getVidAttributeName'](_0x2706fc),_0x55e8d0=_0x2706fc['item']['getAttribute'](_0x3d9841);if(_0x32faf9['has'](_0x55e8d0)){const _0x589f4c=_0x32faf9['get'](_0x55e8d0);_0x31e1ab['has'](_0x55e8d0)||_0x31e1ab['set'](_0x55e8d0,{..._0x589f4c}),_0x58fe00['set'](_0x55e8d0,{..._0x589f4c});}}}for(const _0x5ae9b5 of _0x31e1ab['keys']())_0x5ae9b5>=this['_startingRevisionId']&&_0x31e1ab['delete'](_0x5ae9b5);const _0x47aafd=new Map();for(const _0xc86210 of _0x5634e7){let _0x4a5a62=_0x1934f8['insertions'][_0xc86210];for(const _0x306ac7 of _0x4a5a62)if(_0x306ac7['item']['is']('element','tableCell')){const _0x3190b3=this['_getVidAttributeName'](_0x306ac7),_0x46d4af=_0x306ac7['item']['getAttribute'](_0x3190b3);if(_0x58fe00['has'](_0x46d4af)){const _0x193558=_0x306ac7['item']['parent']['parent']['getAttribute']('vid_start'),_0xa08ab7=_0x47aafd['get'](_0x193558)||new Set();_0xa08ab7['add'](_0x58fe00['get'](_0x46d4af)['userId']),_0x47aafd['set'](_0x193558,_0xa08ab7);}}_0x4a5a62=_0x1934f8['deletions'][_0xc86210];for(const _0x29236c of _0x4a5a62)if(_0x29236c['item']['is']('element','tableCell')){const _0xc01657=this['_getVidAttributeName'](_0x29236c),_0x643e2e=_0x29236c['item']['getAttribute'](_0xc01657);if(_0x31e1ab['has'](_0x643e2e)){const _0x43598c=_0x29236c['item']['parent']['parent']['getAttribute']('vid_start'),_0x3ba65b=_0x47aafd['get'](_0x43598c)||new Set();_0x3ba65b['add'](_0x31e1ab['get'](_0x643e2e)['userId']),_0x47aafd['set'](_0x43598c,_0x3ba65b);}}for(const _0x442299 of _0x47aafd['keys']())(_0x58fe00['has'](_0x442299)||_0x31e1ab['has'](_0x442299))&&_0x47aafd['delete'](_0x442299);}for(const _0x3d47df of _0x5634e7){const _0x32de2a=_0x1934f8['insertions'][_0x3d47df];let _0x1c2a34=null,_0x244345=null;for(const _0xc5f8fb of _0x32de2a){const _0x26dcbf=this['_getVidAttributeName'](_0xc5f8fb),_0x2491eb=_0xc5f8fb['item']['getAttribute'](_0x26dcbf),_0x4591e7=_0x47aafd['get'](_0x2491eb);_0x4591e7&&'elementStart'==_0xc5f8fb['type']&&(_0x1c2a34=Array['from'](_0x4591e7)[0x0],_0x244345=_0xc5f8fb['item']['getAttribute']('vid_end')),_0x1c2a34&&(_0x31e1ab['set'](_0x2491eb,{'userId':_0x1c2a34}),_0x58fe00['set'](_0x2491eb,{'userId':_0x1c2a34})),_0x2491eb==_0x244345&&(_0x1c2a34=null,_0x244345=null);}}const _0x12ca78={},_0x2cd5be=new Set();for(const _0x22b5f1 of _0x5634e7){const _0x56b89e=_0x124c7c['deletions'][_0x22b5f1],_0x2cf328=_0x124c7c['insertions'][_0x22b5f1];for(const {userId:_0xa92dc6}of this['_touchedMarkers']['values']())null!==_0xa92dc6&&_0x2cd5be['add'](_0xa92dc6);for(const {userId:_0x59993b}of this['_touchedRoots']['values']())null!==_0x59993b&&_0x2cd5be['add'](_0x59993b);this['_markChanges'](_0x2cf328,_0x1934f8['insertions'][_0x22b5f1],_0x58fe00,'insertion',_0x2cd5be),this['_markChanges'](_0x56b89e,_0x1934f8['deletions'][_0x22b5f1],_0x31e1ab,'deletion',_0x2cd5be),_0x12ca78[_0x22b5f1]={'insertions':this['_prepareViewToSave'](_0x2cf328),'deletions':this['_prepareViewToSave'](_0x56b89e),'attachChange':this['_touchedRoots']['get'](_0x22b5f1)||null,'attributesBefore':_0x10c153(this['_baseRootsAttributes']['get'](_0x22b5f1))||{},'attributesAfter':_0x10c153(this['_diffRootsAttributes']['get'](_0x22b5f1))};}return{'diffData':_0x12ca78,'authorsIds':Array['from'](_0x2cd5be)};}['_processRootBeforeSave'](_0x122633){for(const [,_0x5a9d7e]of _0x122633['markers']){const _0x13dfdb=_0x5a9d7e['start']['getAncestors']()['filter'](_0x57dbea=>'tableCell'==_0x57dbea['name']);for(const _0x4423f5 of _0x13dfdb)0x1==_0x4423f5['childCount']&&_0x4423f5['getChild'](0x0)['is']('element','paragraph')&&_0x4423f5['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x592175){this['_processRootBeforeSave'](_0x592175);const _0x109356=this['editor']['data']['toView'](_0x592175,{}),_0x28811b=Array['from'](_0x109356['getChildren']())['map'](_0x177a12=>this['_getViewJson'](_0x177a12));return JSON['stringify'](_0x28811b);}['_getViewJson'](_0x167fe5){if(_0x167fe5['is']('$text'))return _0x167fe5['data'];{const _0x3ab409=_0x167fe5;return{'type':Object['keys'](P)['find'](_0xa31316=>_0x167fe5 instanceof P[_0xa31316]),'name':_0x3ab409['name'],'attributes':Array['from'](_0x3ab409['getAttributes']()),'children':Array['from'](_0x3ab409['getChildren']())['map'](_0x745631=>this['_getViewJson'](_0x745631))};}}['_markChanges'](_0x4af24e,_0x12d897,_0x94bf1a,_0x161112,_0x3e65ac){let _0x20d0cc=null,_0x41be5e=null,_0x158a29=0x0;const _0x453622=this['editor']['model'];for(let _0x4ffce9=0x0;_0x4ffce9<_0x12d897['length'];_0x4ffce9++){const _0x5e3f86=this['_getVidAttributeName'](_0x12d897[_0x4ffce9]),_0x3d9536=_0x12d897[_0x4ffce9]['item']['getAttribute'](_0x5e3f86),_0x13cd30=_0x94bf1a['get'](_0x3d9536),_0x599360=_0x4ffce9==_0x12d897['length']-0x1;(!_0x20d0cc&&_0x13cd30&&(_0x20d0cc=_0x13cd30,_0x41be5e=_0x12d897[_0x4ffce9]),_0x20d0cc&&(!_0x13cd30||_0x13cd30['userId']!=_0x20d0cc['userId']))&&(_0x4c8974(_0x13cd30,B(_0x41be5e,_0x4af24e,_0x453622),B(_0x12d897[_0x4ffce9],_0x4af24e,_0x453622)),_0x20d0cc=_0x13cd30||null,_0x41be5e=_0x13cd30?_0x12d897[_0x4ffce9]:null),_0x20d0cc&&_0x599360&&_0x4c8974(_0x13cd30,B(_0x41be5e,_0x4af24e,_0x453622),J(_0x12d897[_0x4ffce9],_0x4af24e,_0x453622));}function _0x4c8974(_0x3365fc,_0x1bc956,_0x525dbe){const _0x4ab85d=_0x20d0cc['userId'],_0x1bcb88='revision:'+_0x161112+':'+_0x4ab85d+':'+_0x158a29++,_0xb335b7=_0x453622['createRange'](_0x1bc956,_0x525dbe);_0x4af24e['markers']['set'](_0x1bcb88,_0xb335b7),null!==_0x4ab85d&&_0x3e65ac['add'](_0x4ab85d);}}['_getVidAttributeName'](_0x33e301){switch(_0x33e301['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1cb79d,_0x24d164){_0x1cb79d['baseVersion']=null;for(const _0x1eb048 in _0x1cb79d){const _0x53f635=_0x1cb79d[_0x1eb048];if(_0x53f635 instanceof gt){const _0x5f2b81=_0x24d164['get'](_0x53f635['root']['rootName']);_0x1cb79d[_0x1eb048]=this['_fixPosition'](_0x53f635,_0x5f2b81);}if(_0x53f635 instanceof vt){const _0xcc1df3=_0x24d164['get'](_0x53f635['root']['rootName']);_0x1cb79d[_0x1eb048]=this['_fixRange'](_0x53f635,_0xcc1df3);}'root'===_0x1eb048&&(_0x1cb79d['root']=_0x24d164['get'](_0x1cb79d['root']['rootName']));}}['_fixRange'](_0x16d295,_0x46427f){return this['editor']['model']['createRange'](this['_fixPosition'](_0x16d295['start'],_0x46427f),this['_fixPosition'](_0x16d295['end'],_0x46427f));}['_fixPosition'](_0x52ab45,_0x486d01){return this['editor']['model']['createPositionFromPath'](_0x486d01,_0x52ab45['path'],_0x52ab45['stickiness']);}['_handleInsertOperation'](_0x520c33){const _0x4ec599=this['_idsRoots']['get'](_0x520c33['position']['root']['rootName']),_0x169fcf=this['_fixPosition'](_0x520c33['position'],_0x4ec599),_0xac2666=null===_0x520c33['_authorId']?null:_0x520c33['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x428e5f=_0x169fcf['parent'],_0x5b38e8=this['_revisionId'],_0x3c9055=[];for(const _0x620f54 of _0x520c33['nodes'])if(_0x620f54['is']('element'))_0x3c9055['push'](this['_makeIdsRoot'](_0x620f54));else{for(let _0xcd120b=0x0;_0xcd120b<_0x620f54['offsetSize'];_0xcd120b++)_0x3c9055['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x4a0b56=this['_revisionId'];for(let _0x205079=_0x5b38e8;_0x205079<_0x4a0b56;_0x205079++)this['_touched']['set'](_0x205079,{'userId':_0xac2666});_0x428e5f['_insertChild'](_0x169fcf['offset'],_0x3c9055);}['_handleMoveOperation'](_0x16f4d2){(_0x16f4d2=this['_cloneOperation'](_0x16f4d2,this['_idsRoots']))['_execute']();const _0x3d4de1=null===_0x16f4d2['_authorId']?null:_0x16f4d2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1c5974=_0x16f4d2['getMovedRangeStart'](),_0x47c8c1=_0x1c5974['parent'],_0xc566d9=_0x1c5974['offset'];!function _0x3cbdcf(_0x1ff34e,_0xc5190e,_0x13a010,_0x362639){for(let _0x1be832=_0x13a010;_0x1be832<_0x362639;_0x1be832++){const _0x74c00e=_0xc5190e['getChild'](_0x1be832);_0x74c00e['is']('element','$text')?_0x1ff34e['set'](_0x74c00e['getAttribute']('vid'),{'userId':_0x3d4de1}):(_0x1ff34e['set'](_0x74c00e['getAttribute']('vid_start'),{'userId':_0x3d4de1}),_0x3cbdcf(_0x1ff34e,_0x74c00e,0x0,_0x74c00e['childCount']),_0x1ff34e['set'](_0x74c00e['getAttribute']('vid_end'),{'userId':_0x3d4de1}));}}(this['_touched'],_0x47c8c1,_0xc566d9,_0xc566d9+_0x16f4d2['howMany']);}['_handleMergeOperation'](_0x14a2a2){const _0x2eef16=null===(_0x14a2a2=this['_cloneOperation'](_0x14a2a2,this['_idsRoots']))['_authorId']?null:_0x14a2a2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xb1489f=_0x14a2a2['targetPosition']['parent'],_0x359ad4=_0x14a2a2['sourcePosition']['parent'],_0x21b4eb=_0xb1489f['getAttribute']('vid_end'),_0xfa3b37=_0x359ad4['getAttribute']('vid_start');_0xb1489f['_setAttribute']('vid_end',_0x359ad4['getAttribute']('vid_end')),_0x359ad4['_setAttribute']('vid_end',_0x21b4eb),this['_touched']['set'](_0xfa3b37,{'userId':_0x2eef16}),this['_touched']['set'](_0x21b4eb,{'userId':_0x2eef16}),_0x14a2a2['_execute']();}['_handleSplitOperation'](_0x16971a){const _0x1ed2b8=null===(_0x16971a=this['_cloneOperation'](_0x16971a,this['_idsRoots']))['_authorId']?null:_0x16971a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1924f7=_0x16971a['graveyardPosition'],_0x39f4ae=_0x16971a['splitPosition']['parent'];_0x16971a['_execute']();const _0x59722d=_0x39f4ae['getAttribute']('vid_end'),_0x3f185e=_0x16971a['insertionPosition']['nodeAfter'];if(_0x1924f7){const _0x4e6752=_0x3f185e['getAttribute']('vid_end'),_0x3733a7=_0x39f4ae['getAttribute']('vid_end');_0x39f4ae['_setAttribute']('vid_end',_0x4e6752),_0x3f185e['_setAttribute']('vid_end',_0x3733a7),this['_touched']['set'](_0x39f4ae['getAttribute']('vid_end'),{'userId':_0x1ed2b8}),this['_touched']['set'](_0x3f185e['getAttribute']('vid_start'),{'userId':_0x1ed2b8});}else{const _0x4b5aea=this['_revisionId']++,_0x56c026=this['_revisionId']++;_0x39f4ae['_setAttribute']('vid_end',_0x4b5aea),_0x3f185e['_setAttribute']('vid_start',_0x56c026),_0x3f185e['_setAttribute']('vid_end',_0x59722d),this['_touched']['set'](_0x4b5aea,{'userId':_0x1ed2b8}),this['_touched']['set'](_0x56c026,{'userId':_0x1ed2b8});}}['_handleMarkerOperation'](_0x11c2d8){if(!_0x11c2d8['affectsData'])return;const _0x40268d=(_0x11c2d8=this['_cloneOperation'](_0x11c2d8,this['_diffRoots']))['oldRange']?_0x11c2d8['oldRange']['root']:null,_0x76e149=_0x11c2d8['newRange']?_0x11c2d8['newRange']['root']:null;_0x40268d&&this['_markers']['delete'](_0x11c2d8['name']),_0x76e149&&this['_markers']['set'](_0x11c2d8['name'],_0x11c2d8['newRange']['clone']());const _0xaa0b80=null===_0x11c2d8['_authorId']?null:_0x11c2d8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x50124d=_0x11c2d8['name'];if(!this['_touchedMarkers']['has'](_0x50124d))return void this['_touchedMarkers']['set'](_0x50124d,{'range':_0x11c2d8['oldRange'],'userId':_0xaa0b80});const _0x16c8b2=this['_touchedMarkers']['get'](_0x50124d),_0x542ad6=_0x16c8b2['range'],_0x3ee124=_0x11c2d8['newRange'];null==_0x542ad6&&null==_0x3ee124||_0x542ad6&&_0x3ee124&&_0x542ad6['isEqual'](_0x3ee124)?this['_touchedMarkers']['delete'](_0x11c2d8['name']):_0x16c8b2['userId']=_0xaa0b80;}['_handleRootOperation'](_0x4b8ae4,_0x3d9e17){this['_diffRoots']['has'](_0x4b8ae4['rootName'])?this['_diffRoots']['get'](_0x4b8ae4['rootName'])['_isAttached']=_0x4b8ae4['isAdd']:(this['_diffRoots']['set'](_0x4b8ae4['rootName'],F(_0x4b8ae4['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4b8ae4['rootName'],{}),_0x3d9e17&&this['_idsRoots']['set'](_0x4b8ae4['rootName'],F(_0x4b8ae4['rootName'],!0x0)));const _0x59bf6c=null===_0x4b8ae4['_authorId']?null:_0x4b8ae4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5e34f2=this['_touchedRoots']['get'](_0x4b8ae4['rootName']);_0x5e34f2&&_0x5e34f2['userId']===_0x59bf6c?this['_touchedRoots']['delete'](_0x4b8ae4['rootName']):this['_touchedRoots']['set'](_0x4b8ae4['rootName'],{'userId':_0x59bf6c,'isAttached':_0x4b8ae4['isAdd']});}['_handleRootAttributeOperation'](_0xc7f87e){const _0x2212fc=this['_diffRootsAttributes']['get'](_0xc7f87e['root']['rootName']);null===_0xc7f87e['newValue']?delete _0x2212fc[_0xc7f87e['key']]:_0x2212fc[_0xc7f87e['key']]=_0xc7f87e['newValue'];}}function T(_0x1b6bd3){const _0x3a82f6=F(_0x1b6bd3['rootName'],_0x1b6bd3['isAttached']());for(const _0x265011 of _0x1b6bd3['getChildren']()){const _0xf04e6a=_0x265011['_clone'](!0x0);_0x3a82f6['_appendChild'](_0xf04e6a);}return _0x3a82f6;}function F(_0x133ae2,_0x495d90=!0x0){const _0x1a37c9=new mt();return _0x1a37c9['rootName']=_0x133ae2,_0x1a37c9['_isAttached']=_0x495d90,_0x1a37c9['isAttached']=()=>_0x1a37c9['_isAttached'],_0x1a37c9;}function B(_0x453195,_0x560226,_0x5b1c8e){const _0x3fe110='elementEnd'==_0x453195['type']?_0x5b1c8e['createPositionAt'](_0x453195['item'],'end'):_0x5b1c8e['createPositionBefore'](_0x453195['item']);return _0x5b1c8e['createPositionFromPath'](_0x560226,_0x3fe110['path'],_0x3fe110['stickiness']);}function J(_0x225d70,_0x150008,_0x367a3b){const _0x4ee030='elementStart'==_0x225d70['type']?_0x367a3b['createPositionAt'](_0x225d70['item'],0x0):_0x367a3b['createPositionAfter'](_0x225d70['item']);return _0x367a3b['createPositionFromPath'](_0x150008,_0x4ee030['path'],_0x4ee030['stickiness']);}class ns extends _0x4cb52{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x676936,_0x23fca2){super(_0x676936),this['focusTracker']=new _0x520137(),this['keystrokes']=new _0x48d79d(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x23fca2),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x1c5528({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x239337=_0x2ffeb9=>_0x2ffeb9['stopPropagation']();this['keystrokes']['set']('arrowright',_0x239337),this['keystrokes']['set']('arrowleft',_0x239337),this['keystrokes']['set']('arrowup',_0x239337),this['keystrokes']['set']('arrowdown',_0x239337);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x497317){this['revisionNameInputView']['fieldView']['element']['value']=_0x497317['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4589b6){const _0x55d784=new nt(this['locale'],_0x1ddc75),_0x4b3190=_0x55d784['fieldView'];_0x4b3190['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x44f965=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4589b6&&(_0x44f965+='\x20('+m(this['locale'],'optional')+')'),(_0x55d784['label']=_0x44f965,_0x4b3190['on']('input',()=>{this['revisionNameInputValue']=_0x4b3190['element']['value']['trim']();}),_0x55d784);}}class u extends _0x23fe3b{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x3ea8d3=this['editor'],_0xce5798=_0x3ea8d3['plugins']['get']('RevisionTracker');_0x3ea8d3['ui']['componentFactory']['add']('revisionHistory',_0x2d376b=>{const _0x41a7ec=_0x4daaa8(_0x2d376b),_0x40809a=_0x41a7ec['panelView']['children'],_0x594e39=new te(_0x2d376b),_0x528c89=new _0x32e635(_0x2d376b),_0x5e0130=new _0x219c24(_0x2d376b),_0x583157=new _0x32e635(_0x2d376b),_0x3a50f3=new _0x219c24(_0x2d376b);return _0x41a7ec['bind']('isEnabled')['to'](_0xce5798,'isReady',_0xce5798,'isEnabled',_0x3ea8d3,'isReadOnly',(_0x269c0b,_0x32a6e9,_0x10a39c)=>_0x269c0b&&_0x32a6e9&&!_0x10a39c),_0x41a7ec['buttonView']['set']({'icon':_0x5d0720['history'],'label':m(_0x2d376b,'Revision\x20history'),'tooltip':!0x0}),_0x5e0130['set']({'label':m(_0x2d376b,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x5e0130['bind']('isEnabled')['to'](_0xce5798,'isReady',_0xce5798,'isEnabled',_0x3ea8d3,'isReadOnly',(_0x55501a,_0x11f33e,_0x452e83)=>_0x55501a&&_0x11f33e&&!_0x452e83),_0x5e0130['on']('execute',()=>this['_showDialog']()),_0x3a50f3['set']({'label':m(_0x2d376b,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x3a50f3['bind']('isEnabled')['to'](_0xce5798,'isReady',_0x3ea8d3,'isReadOnly',(_0x54ea1f,_0x2e96da)=>_0x54ea1f&&!_0x2e96da),_0x3a50f3['on']('execute',()=>{_0x3ea8d3['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x41a7ec['isOpen']=!0x1,_0x3ea8d3['editing']['view']['focus']();}),_0x528c89['children']['add'](_0x5e0130),_0x583157['children']['add'](_0x3a50f3),_0x594e39['role']='menu',_0x594e39['items']['addMany']([_0x528c89,_0x583157]),_0x40809a['add'](_0x594e39),_0x41a7ec;}),_0x3ea8d3['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x44cb47=this['editor'],_0x2a2579=_0x44cb47['locale'],_0x3db44a=new _0x327427(_0x2a2579),_0xa99223=new _0x4081ea(_0x2a2579);_0x3db44a['buttonView']['set']({'icon':_0x5d0720['history'],'label':m(_0x2a2579,'Revision\x20history')});const _0x5cb142=new _0x375dc5(_0x2a2579,_0x3db44a),_0x183d67=new _0x3b43e0(_0x2a2579);_0x183d67['set']({'label':m(_0x2a2579,'Save\x20current\x20revision')}),_0x183d67['delegate']('execute')['to'](_0x3db44a),_0x183d67['on']('execute',()=>{this['_showDialog']();}),_0x5cb142['children']['add'](_0x183d67),_0xa99223['items']['add'](_0x5cb142);const _0x41347f=new _0x375dc5(_0x2a2579,_0x3db44a),_0x215fdc=new _0x3b43e0(_0x2a2579);return _0x215fdc['set']({'label':m(_0x2a2579,'Open\x20revision\x20history')}),_0x215fdc['delegate']('execute')['to'](_0x3db44a),_0x215fdc['on']('execute',()=>{_0x44cb47['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x41347f['children']['add'](_0x215fdc),_0xa99223['items']['add'](_0x41347f),_0x3db44a['panelView']['children']['add'](_0xa99223),_0x3db44a;}['_showDialog'](){const _0xd36a47=this['editor'],_0x48a308=_0xd36a47['locale'],_0x2285df=_0xd36a47['plugins']['get']('Dialog'),_0x5130de=_0xd36a47['plugins']['get']('RevisionTracker');function _0x3924b4(_0x42b5b5){_0xd36a47['config']['get']('revisionHistory.requireRevisionName')&&''===_0x42b5b5['revisionName']?_0x42b5b5['revisionNameInputView']['errorText']=m(_0x48a308,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0xd36a47['plugins']['get'](l)['saveRevision']({'name':_0x42b5b5['revisionName']}),_0x2285df['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3924b4(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2285df['show']({'id':'revisionSave','title':m(_0x48a308,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0xd36a47['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2285df['hide']()},{'label':m(_0xd36a47['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2a2843){_0x2a2843['bind']('isEnabled')['to'](_0x5130de,'isReady',_0x5130de,'isEnabled',_0xd36a47,'isReadOnly',(_0x2f0269,_0x3ebfd6,_0xc890)=>_0x2f0269&&_0x3ebfd6&&!_0xc890);},'onExecute':()=>_0x3924b4(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x51190e=this['editor'],_0x1f7ee7=_0x51190e['locale'];this['_saveRevisionFormView']=new ns(_0x1f7ee7,_0x51190e['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x4cb52{['changeId'];['_model'];constructor(_0x2f836e,_0x18db82){super(_0x2f836e),this['_model']=_0x18db82,this['changeId']=_0x18db82['id'];const _0x35ca43=this['bindTemplate'],_0x581fb5=m(_0x2f836e,_0x18db82['data']['isSuggestion']?'Suggested\x20by':'add'==_0x18db82['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x18db82['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x35ca43['to']('type',_0x418804=>'ck-revision-change__'+_0x418804)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x581fb5}]},{'text':'\x20'+_0x18db82['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x17bb2d(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x37f8d9){super(),this['id']=_0x37f8d9['id']||_0x32ae7e(),this['author']=_0x37f8d9['author'],this['type']=_0x37f8d9['type'],this['data']=_0x37f8d9['data']||{},this['rootName']=_0x37f8d9['rootName'],this['set']('createdAt',_0x37f8d9['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(_0x35ad1e,_0x4a7226){this['newRevisionId']=_0x35ad1e,this['oldRevisionId']=_0x4a7226,this['changes']=new _0x2733e7();}['_setChanges'](_0x975aa5){for(const _0x5ecde1 of _0x975aa5)this['changes']['add'](_0x5ecde1);}}const Y={'c':_0x5ef4e4,'a':_0xe31744,'e':_0x1313cb,'r':_0x10477d,'u':_0x44f7dc};class d extends _0x23fe3b{['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[_0x36152c,_0x4804bd,j];}constructor(_0x1bbcaf){super(_0x1bbcaf),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',(_0x509ce8,_0x2baca1,_0x299c23)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1ffb86=>{for(const _0x2afc26 of this['editor']['editing']['view']['document']['roots'])_0x299c23?_0x1ffb86['removeClass']('ck-editor__editable__overlay',_0x2afc26):_0x1ffb86['addClass']('ck-editor__editable__overlay',_0x2afc26);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x12dcd0=>null!==_0x12dcd0),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x535947,_0x4483c0,_0x4b5b32)=>_0x535947&&_0x4b5b32?_0x4483c0['changes']['getIndex'](_0x4b5b32):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3368af,_0x58e2b2)=>_0x3368af?_0x58e2b2['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x4804bd);}['init'](){const _0x4173c3=this['editor'],_0x363a8c=new yt(_0x4173c3,{'direction':'backward'}),_0x12c095=new yt(_0x4173c3,{'direction':'forward'});(_0x4173c3['commands']['add']('showPreviousChange',_0x363a8c),_0x4173c3['commands']['add']('showNextChange',_0x12c095),_0x4173c3['commands']['add']('restoreRevision',new _t(_0x4173c3)),this['on']('change:numberOfChanges',()=>{_0x363a8c['refresh'](),_0x12c095['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4173c3['enableReadOnlyMode']('revision-viewer'),_0x4173c3['plugins']['has']('WidgetToolbarRepository'))&&_0x4173c3['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x226074){await this['loadRevisionData'](_0x226074);const _0x573ebe={};for(const _0x12e92b in _0x226074['diffData']){if(_0x226074['diffData'][_0x12e92b]['attachChange']&&!_0x226074['diffData'][_0x12e92b]['attachChange']['isAttached'])continue;const _0x5a0da9=this['_removeRevisionMarkers'](JSON['parse'](_0x226074['diffData'][_0x12e92b]['insertions'])),_0xce882f=this['editor']['editing']['view']['document'],_0x40f9bc=new _0xeaf0ed(_0xce882f,_0x5a0da9['map'](_0x1ef793=>this['_getViewObj'](_0x1ef793)));this['editor']['data']['processor']['useFillerType']('marked'),_0x573ebe[_0x12e92b]=this['editor']['data']['processor']['toData'](_0x40f9bc),this['editor']['data']['processor']['useFillerType']('default');}return _0x573ebe;}async['getRevisionRootsAttributes'](_0x168ae1){await this['loadRevisionData'](_0x168ae1);const _0x501d52={};for(const _0x19c5cd in _0x168ae1['diffData'])_0x168ae1['diffData'][_0x19c5cd]['attachChange']&&!_0x168ae1['diffData'][_0x19c5cd]['attachChange']['isAttached']||(_0x501d52[_0x19c5cd]=_0x168ae1['diffData'][_0x19c5cd]['attributesAfter']||{});return _0x501d52;}['_removeRevisionMarkers'](_0x535a3d){return(_0x535a3d=_0x535a3d['filter'](_0x25522a=>!_0x25522a['name']||'revision-start'!==_0x25522a['name']&&'revision-end'!==_0x25522a['name']))['forEach'](_0xa1e773=>{'string'!=typeof _0xa1e773&&(_0xa1e773['children']=this['_removeRevisionMarkers'](_0xa1e773['children']),_0xa1e773['attributes']=_0xa1e773['attributes']['filter'](_0x5b7d08=>!_0x5b7d08[0x0]['startsWith']('data-revision-')));}),_0x535a3d;}async['compare'](_0x1abd50,_0x3ad663,_0x21929a=!0x1){if(!this['isEnabled'])return;const _0x540550=this['diff'],_0x355c37=this['repository'],_0x41780a='string'==typeof _0x1abd50?_0x355c37['getRevision'](_0x1abd50):_0x1abd50,_0x8c0e0c='string'==typeof _0x3ad663?_0x355c37['getRevision'](_0x3ad663):_0x3ad663,_0x91007e=_0x41780a['id'],_0x3d79a4=_0x8c0e0c?_0x8c0e0c['id']:null;if(!_0x21929a&&this['diff']&&this['diff']['newRevisionId']===_0x91007e&&this['diff']['oldRevisionId']===_0x3d79a4)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x91007e,_0x3d79a4);const _0x588403=this['_getRevisionsRange'](_0x41780a,_0x8c0e0c,!0x0)['map'](_0x44c060=>this['loadRevisionData'](_0x44c060));return _0x588403['push'](new Promise(_0x67aba6=>{setTimeout(_0x67aba6,0x14);})),Promise['all'](_0x588403)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x503467=this['_getDiff'](_0x91007e,_0x3d79a4);for(const _0x5a5f6a of _0x503467['changes'])this['_changeIdToChange']['set'](_0x5a5f6a['id'],_0x5a5f6a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xc4b6bd=>{for(const _0x5ec054 of this['editor']['model']['document']['getRootNames']())_0xc4b6bd['detachRoot'](_0x5ec054);for(const _0x50f578 of Object['keys'](_0x503467['model'])){const _0x551e84=_0xc4b6bd['addRoot'](_0x50f578);for(const _0xb4b2ec of Object['keys'](_0x503467['attributes'][_0x50f578]))_0xc4b6bd['setAttribute'](_0xb4b2ec,_0x503467['attributes'][_0x50f578][_0xb4b2ec],_0x551e84);_0xc4b6bd['insert'](_0x503467['model'][_0x50f578],_0x551e84,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x503467['changes'])),this['isReady']=!0x0;})['catch'](_0x13ed44=>{console['error'](_0x13ed44),this['_cleanUp'](),_0x540550&&(this['diff']=_0x540550),this['isReady']=!0x0;});}['addRevisionData'](_0x19b751,_0x472a51){const _0xf12e2b=this['repository']['createRevision'](_0x19b751);return _0xf12e2b['on']('_update',(_0xa069ed,_0xd75ef0,_0x4ec6b2)=>_0x472a51(_0xd75ef0,_0x4ec6b2,_0xf12e2b)),this['repository']['addRevision'](_0xf12e2b),_0xf12e2b;}['loadRevisionData'](_0x5d4773){if(!_0x5d4773||_0x5d4773['diffData'])return Promise['resolve']();{const _0x184e05=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x184e05,'revisionId':_0x5d4773['id']})['then'](_0x1b78fb=>{_0x5d4773['_update']({'diffData':_0x1b78fb['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},_0xb11c96=>{for(const _0x5d09b4 of this['editor']['model']['document']['getRootNames']())_0xb11c96['detachRoot'](_0x5d09b4);});}['_sortAndFilterDiffChanges'](_0x459746){const _0xd8cdf8=[],_0xdd6e4=new Map();for(const _0xa726e6 of this['editor']['model']['document']['getRootNames']()){const _0x9fc5e9=this['editor']['editing']['view']['getDomRoot'](_0xa726e6);if(!_0x9fc5e9)continue;const _0x47a7eb=_0x9fc5e9['getClientRects']()['item'](0x0);_0x47a7eb&&(_0xd8cdf8['push'](_0xa726e6),_0xdd6e4['set'](_0xa726e6,_0x47a7eb));}return _0xd8cdf8['sort']((_0x373b9c,_0xe543e6)=>{const _0x19ddc4=_0xdd6e4['get'](_0x373b9c),_0x421eac=_0xdd6e4['get'](_0xe543e6);return _0x19ddc4['y']-_0x421eac['y']||_0x19ddc4['x']-_0x421eac['x'];}),(_0x459746=_0x459746['filter'](_0xb1d01d=>_0xd8cdf8['includes'](_0xb1d01d['rootName'])))['sort']((_0x42777a,_0x3a73c6)=>_0xd8cdf8['indexOf'](_0x42777a['rootName'])-_0xd8cdf8['indexOf'](_0x3a73c6['rootName'])),_0x459746;}['_makeTape'](_0x232ef8){const _0xd930da=Array['from'](_0x232ef8['markers'])['filter'](([_0x34e7db,_0x2a1230])=>_0x34e7db['startsWith']('revision:')&&!_0x2a1230['isCollapsed']),_0x4aa07b=Array['from'](this['editor']['model']['createRangeIn'](_0x232ef8)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0xd930da['length'])for(const _0x18c1eb of _0x4aa07b){const [_0x52b923,_0x4fda7f]=_0xd930da[0x0],[,_0x38903f,_0x24c84b]=_0x52b923['split'](':');if(_0x4fda7f['end']['isEqual'](_0x18c1eb['nextPosition'])&&_0xd930da['shift'](),(_0x18c1eb['previousPosition']['isEqual'](_0x4fda7f['start'])||_0x18c1eb['previousPosition']['isAfter'](_0x4fda7f['start']))&&('insertion'==_0x38903f?_0x18c1eb['isAdded']={'userId':_0x24c84b}:'deletion'==_0x38903f&&(_0x18c1eb['isRemoved']={'userId':_0x24c84b})),0x0==_0xd930da['length'])break;}return _0x4aa07b;}['_refreshStartEndIndex'](_0x39917f){const _0x442519=new Map();for(let _0x2211c6=0x0;_0x2211c6<_0x39917f['length'];_0x2211c6++)'text'===_0x39917f[_0x2211c6]['type']?(_0x39917f[_0x2211c6]['item']['startIndex']=_0x2211c6,_0x39917f[_0x2211c6]['item']['endIndex']=_0x2211c6):('elementStart'===_0x39917f[_0x2211c6]['type']?_0x39917f[_0x2211c6]['item']['startIndex']=_0x2211c6:'elementEnd'===_0x39917f[_0x2211c6]['type']&&(_0x39917f[_0x2211c6]['item']['endIndex']=_0x2211c6),_0x442519['set'](_0x39917f[_0x2211c6]['id'],_0x2211c6));for(const _0x4e0d11 of _0x442519['values']())'elementStart'===_0x39917f[_0x4e0d11]['type']?_0x39917f[_0x4e0d11]['item']['endIndex']=_0x442519['get'](_0x39917f[_0x4e0d11]['pairId']):'elementEnd'===_0x39917f[_0x4e0d11]['type']&&(_0x39917f[_0x4e0d11]['item']['startIndex']=_0x442519['get'](_0x39917f[_0x4e0d11]['pairId']));}['_processTape'](_0x3228d1){for(let _0x50d6d5=0x0;_0x50d6d5<_0x3228d1['length'];_0x50d6d5++){if('elementStart'===_0x3228d1[_0x50d6d5]['type'])_0x3228d1[_0x50d6d5]['item']['startIndex']=_0x50d6d5;else{if('elementEnd'===_0x3228d1[_0x50d6d5]['type']){_0x3228d1[_0x50d6d5]['item']['endIndex']=_0x50d6d5;const _0x1af968=_0x3228d1[_0x50d6d5]['item']['startIndex'];_0x3228d1[_0x1af968]['pairId']=_0x3228d1[_0x50d6d5]['id'],_0x3228d1[_0x50d6d5]['pairId']=_0x3228d1[_0x1af968]['id'];}else _0x3228d1[_0x50d6d5]['item']['startIndex']=_0x50d6d5,_0x3228d1[_0x50d6d5]['item']['endIndex']=_0x50d6d5,_0x3228d1[_0x50d6d5]['pairId']=null;}_0x3228d1[_0x50d6d5]['markersStart']||(_0x3228d1[_0x50d6d5]['markersStart']=[],_0x3228d1[_0x50d6d5]['markersEnd']=[]);}}['_markInsertions'](_0x1ec339,_0x7fc0c3){const _0x69c236=_0x1ec339['filter'](_0xa9b27e=>!_0xa9b27e['isAdded']);for(let _0x291ab6=0x0;_0x291ab6<_0x7fc0c3['length'];_0x291ab6++)_0x7fc0c3[_0x291ab6]['isAdded']&&(_0x69c236[_0x291ab6]['isAdded']=_0x7fc0c3[_0x291ab6]['isAdded']);}['_makeModelFromViewString'](_0x1d3d6d){const _0x442eb2=JSON['parse'](_0x1d3d6d),_0x18c9ce=this['editor']['editing']['view']['document'],_0x4b12fa=new _0xeaf0ed(_0x18c9ce,_0x442eb2['map'](_0x2b462c=>this['_getViewObj'](_0x2b462c)));return this['editor']['data']['toModel'](_0x4b12fa);}['_getViewObj'](_0x2de7e2){const _0x34fefe=this['editor']['editing']['view']['document'];if('string'==typeof _0x2de7e2)return new _0x4f8a2d(_0x34fefe,_0x2de7e2);{const _0x5d177d=_0x2de7e2['children']['map'](_0x527066=>this['_getViewObj'](_0x527066));return new(Y[_0x2de7e2['type']]||_0x10c154)(_0x34fefe,_0x2de7e2['name'],_0x2de7e2['attributes'],_0x5d177d);}}['_getDiff'](_0x151175,_0x1d1ee4=null){const _0x274e0a=this['repository']['getRevision'](_0x151175),_0x46bee7=_0x1d1ee4?this['repository']['getRevision'](_0x1d1ee4):null,_0x2205d4=this['_getRevisionsRange'](_0x274e0a,_0x46bee7),_0x3dc80f=_0x2205d4[_0x2205d4['length']-0x1],_0x4a07f6=new Map(),_0x19e7dc={'model':{},'attributes':{},'changes':[]},_0x1af3c4=new Set(),_0x46cd65=new Map();for(let _0x17dc8c=_0x2205d4['length']-0x1;_0x17dc8c>=0x0;_0x17dc8c--){const _0x465c43=_0x2205d4[_0x17dc8c];for(const _0x93b07c of Object['keys'](_0x465c43['diffData']))if(_0x465c43['diffData'][_0x93b07c]['attachChange']){const _0x5f34d3=_0x465c43['diffData'][_0x93b07c]['attachChange'];_0x5f34d3['isAttached']?(_0x1af3c4['add'](_0x93b07c),_0x46cd65['has'](_0x93b07c)&&_0x46cd65['get'](_0x93b07c)['userId']==_0x5f34d3['userId']?_0x46cd65['delete'](_0x93b07c):_0x46cd65['set'](_0x93b07c,_0x5f34d3)):_0x46cd65['has'](_0x93b07c)?(_0x1af3c4['delete'](_0x93b07c),_0x46cd65['delete'](_0x93b07c)):(_0x1af3c4['add'](_0x93b07c),_0x46cd65['set'](_0x93b07c,_0x5f34d3));}else _0x1af3c4['add'](_0x93b07c);}for(const _0x59b13d of _0x1af3c4){const _0x29113a=_0x46cd65['has'](_0x59b13d)&&!_0x46cd65['get'](_0x59b13d)['isAttached'];let _0x4732e7=_0x29113a?_0x2205d4['length']-0x1:0x0;const _0x2b2f2b=_0x29113a?-0x1:0x1;for(;_0x2205d4[_0x4732e7];){const _0x186440=_0x2205d4[_0x4732e7];if(_0x186440['diffData'][_0x59b13d]){const _0x596aa4=_0x29113a?_0x186440['diffData'][_0x59b13d]['attributesBefore']:_0x186440['diffData'][_0x59b13d]['attributesAfter'];_0x19e7dc['attributes'][_0x59b13d]=_0x596aa4?_0x10c153(_0x596aa4):{};break;}_0x4732e7+=_0x2b2f2b;}}for(const _0x4317fb of _0x2205d4){_0x4317fb['model']={};for(const _0x1bdd61 of _0x4317fb['authors'])_0x4a07f6['set'](_0x1bdd61['id'],_0x1bdd61);for(const _0x287af4 of _0x1af3c4){const _0x33b8eb=_0x4317fb['diffData'][_0x287af4]?_0x4317fb['diffData'][_0x287af4]['insertions']:'[]',_0x10e7ee=_0x4317fb['diffData'][_0x287af4]?_0x4317fb['diffData'][_0x287af4]['deletions']:'[]';_0x4317fb['model'][_0x287af4]={'insertions':this['_makeModelFromViewString'](_0x33b8eb),'deletions':this['_makeModelFromViewString'](_0x10e7ee)};}}for(const _0x8477a8 of _0x1af3c4){let _0x4bad8b=null,_0x3b0e86=0x0;const _0x584843=new Map(Array['from'](_0x274e0a['model'][_0x8477a8]['insertions']['markers'])['filter'](([_0x37e4b9])=>!_0x37e4b9['startsWith']('revision:')));let _0x1702ee=0x0;for(const _0x624185 of _0x2205d4){const _0x49da4c=this['_makeTape'](_0x624185['model'][_0x8477a8]['insertions']);_0x624185==_0x274e0a?(_0x4bad8b=_0x49da4c,_0x3b0e86=_0x4bad8b['length'],_0x4bad8b['forEach'](_0x3c5b10=>{_0x3c5b10['id']=_0x1702ee++;}),this['_processTape'](_0x4bad8b)):this['_markInsertions'](_0x4bad8b,_0x49da4c);const _0x347bd9=_0x4bad8b['filter'](_0x17d966=>!_0x17d966['isAdded'])['map'](_0x2986fe=>_0x2986fe['id']);let _0x2ed165=0x0;const _0x2ca4d9=this['_makeTape'](_0x624185['model'][_0x8477a8]['deletions']);_0x2ca4d9['forEach'](_0x5cc15a=>{_0x5cc15a['isRemoved']?_0x5cc15a['id']=_0x3b0e86++:_0x5cc15a['id']=_0x347bd9[_0x2ed165++];}),this['_processTape'](_0x2ca4d9),this['_setDistance'](_0x4bad8b,'isAdded'),this['_setDistance'](_0x2ca4d9,'isRemoved'),_0x624185==_0x274e0a&&this['_markMarkers'](_0x4bad8b,_0x584843),_0x4bad8b=this['_joinTapes'](_0x4bad8b,_0x2ca4d9),this['_refreshStartEndIndex'](_0x4bad8b),this['_setDistance'](_0x4bad8b,'isRemoved');}_0x4bad8b=_0x4bad8b['filter'](_0x2a0261=>!(_0x2a0261['isAdded']&&_0x2a0261['isRemoved']));const _0x1e577e=new Map(_0x3dc80f['model'][_0x8477a8]['deletions']['markers']),_0x4ab3fd=new Set(_0x584843['keys']());for(const _0x54a0ac of _0x1e577e['keys']())_0x4ab3fd['delete'](_0x54a0ac);this['_markSuggestions'](_0x4bad8b,_0x4ab3fd),this['_fixObsoleteTags'](_0x4bad8b),_0x4bad8b=this['_removeMissingPairs'](_0x4bad8b),_0x4bad8b=this['_markMismatchedRemovedTags'](_0x4bad8b),_0x4bad8b=this['_removeUnsupportedChanges'](_0x4bad8b);const {root:_0x2513f,changes:_0x34fc09}=this['_makeModelFromTape'](_0x4bad8b,_0x4a07f6,_0x8477a8);_0x19e7dc['model'][_0x8477a8]=_0x2513f;const _0x215a63=_0x46cd65['get'](_0x8477a8);if(_0x215a63){const _0x3001da=_0x4a07f6['get'](_0x215a63['userId']),_0x27a1f0=new r({'author':_0x3001da,'type':_0x215a63['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x8477a8});_0x34fc09['unshift'](_0x27a1f0),_0x19e7dc['attributes'][_0x8477a8]['revisionHistoryAttachChange']=_0x27a1f0['id'];}_0x19e7dc['changes']=_0x19e7dc['changes']['concat'](_0x34fc09);}return _0x19e7dc;}['_markMarkers'](_0x2c4b62,_0x31166b){for(let _0x5c631e=0x0;_0x5c631e<_0x2c4b62['length'];_0x5c631e++)for(const [_0x227069,_0x248656]of _0x31166b)_0x248656['start']['isEqual'](_0x2c4b62[_0x5c631e]['previousPosition'])&&_0x2c4b62[_0x5c631e]['markersStart']['push'](_0x227069),_0x248656['end']['isEqual'](_0x2c4b62[_0x5c631e]['nextPosition'])&&_0x2c4b62[_0x5c631e]['markersEnd']['push'](_0x227069);}['_joinTapes'](_0x4e1f3b,_0x4d97fc){let _0x2504ac=[],_0x3ae948=0x0,_0x4ebd26=0x0;for(;_0x3ae948<_0x4e1f3b['length']||_0x4ebd26<_0x4d97fc['length'];){const _0x299ccf=_0x4e1f3b[_0x3ae948]||{},_0x3bc125=_0x4d97fc[_0x4ebd26]||{};if(_0x299ccf['id']==_0x3bc125['id'])_0x3ae948++,_0x4ebd26++,_0x2504ac['push'](_0x299ccf);else{if(_0x3bc125['isRemoved']&&_0x299ccf['isAdded']){const {commonTape:_0x4bffdc,iEnd:_0x34d6cf,jEnd:_0x12564d}=this['_threeWayMerge'](_0x4e1f3b,_0x3ae948,_0x4d97fc,_0x4ebd26);_0x2504ac=_0x2504ac['concat'](_0x4bffdc),_0x3ae948=_0x34d6cf,_0x4ebd26=_0x12564d;}else _0x3bc125['isRemoved']?(_0x4ebd26++,_0x2504ac['push'](_0x3bc125)):(_0x3ae948++,_0x2504ac['push'](_0x299ccf));}}return _0x2504ac;}['_markSuggestions'](_0x1a664f,_0x2757c1){const _0x13edc5=[];for(let _0x2dc777=0x0;_0x2dc777<_0x1a664f['length'];_0x2dc777++){for(let _0x4090b0=0x0;_0x4090b0<_0x1a664f[_0x2dc777]['markersStart']['length'];_0x4090b0++){const _0x1200ec=_0x1a664f[_0x2dc777]['markersStart'][_0x4090b0];if(!_0x2757c1['has'](_0x1200ec))continue;const {group:_0x573d4a,type:_0x4b1ebe,authorId:_0x38cf48}=_0x1559e6(_0x1200ec);'revision-suggestion'!=_0x573d4a||'insertion'!=_0x4b1ebe&&'deletion'!=_0x4b1ebe||(_0x13edc5['unshift']({'type':_0x4b1ebe,'name':_0x1200ec,'userId':_0x38cf48}),_0x1a664f[_0x2dc777]['markersStart']['splice'](_0x4090b0,0x1),_0x4090b0--);}_0xa0cc27(_0x1a664f[_0x2dc777]);for(let _0x4d7b24=0x0;_0x4d7b24<_0x1a664f[_0x2dc777]['markersEnd']['length'];_0x4d7b24++){const _0x51aa41=_0x1a664f[_0x2dc777]['markersEnd'][_0x4d7b24];if(!_0x2757c1['has'](_0x51aa41))continue;const {group:_0x257b53,type:_0x116162}=_0x1559e6(_0x51aa41);if('revision-suggestion'!=_0x257b53||'insertion'!=_0x116162&&'deletion'!=_0x116162)continue;_0x1a664f[_0x2dc777]['markersEnd']['splice'](_0x4d7b24,0x1),_0x4d7b24--;const _0x3c0fc8=_0x13edc5['findIndex'](_0x3e04e7=>_0x3e04e7['name']==_0x51aa41);_0x3c0fc8>-0x1&&_0x13edc5['splice'](_0x3c0fc8,0x1);}}function _0x1559e6(_0x5cdbfd){const _0x2f2df9=_0x5cdbfd['split'](':');return{'group':_0x2f2df9[0x0],'type':_0x2f2df9[0x1],'subType':_0x2f2df9['length']>=0x5?_0x2f2df9[0x2]:null,'id':_0x2f2df9['length']<0x5?_0x2f2df9[0x2]:_0x2f2df9[0x3],'authorId':_0x2f2df9['length']<0x5?_0x2f2df9[0x3]:_0x2f2df9[0x4],'markerCount':0x6==_0x2f2df9['length']?_0x2f2df9[0x5]:null};}function _0xa0cc27(_0x456221){for(let _0x1f9604=0x0;_0x1f9604<_0x13edc5['length'];_0x1f9604++){if(_0x456221['isAdded']&&'insertion'==_0x13edc5[_0x1f9604]['type'])return _0x456221['isAddSuggestion']=_0x13edc5[_0x1f9604],void delete _0x456221['isAdded'];if(!_0x456221['isAdded']&&!_0x456221['isRemoved']&&'deletion'==_0x13edc5[_0x1f9604]['type'])return void(_0x456221['isRemoveSuggestion']=_0x13edc5[_0x1f9604]);}}}['_setDistance'](_0x36a6d9,_0x27db47){let _0x3188e7=0x0,_0x414219=!0x1;const _0x5bd53b=new Map();for(const _0x267017 of _0x36a6d9)_0x267017[_0x27db47]?_0x414219&&(_0x3188e7++,_0x414219=!0x1):(_0x3188e7++,_0x414219=!0x0),_0x5bd53b['set'](_0x267017['id'],_0x3188e7);for(let _0x3b6634=0x0;_0x3b6634<_0x36a6d9['length'];_0x3b6634++){if('isRemoved'==_0x27db47&&_0x36a6d9[_0x3b6634]['isAdded']||'isAdded'==_0x27db47&&_0x36a6d9[_0x3b6634]['isRemoved'])continue;if('text'==_0x36a6d9[_0x3b6634]['type']){_0x36a6d9[_0x3b6634]['distance']=0x0;continue;}const _0x280a9f=_0x5bd53b['get'](_0x36a6d9[_0x3b6634]['pairId']),_0xec729b=_0x5bd53b['get'](_0x36a6d9[_0x3b6634]['id']);_0x36a6d9[_0x3b6634]['distance']=_0x280a9f-_0xec729b;}}['_getRevisionsRange'](_0x50494e,_0x5800d6,_0x23fd25=!0x1){const _0x26a7c1=[];let _0xb8e14d=this['repository']['getIndex'](_0x50494e),_0x2140ab=this['repository']['getIndex'](_0x5800d6);for(-0x1==_0x2140ab&&(_0x2140ab=this['repository']['_revisions']['length'],_0x23fd25=!0x1);_0xb8e14d<_0x2140ab;)_0x26a7c1['push'](this['repository']['getRevision'](_0xb8e14d)),_0xb8e14d++;return _0x23fd25&&_0x26a7c1['push'](this['repository']['getRevision'](_0xb8e14d)),_0x26a7c1;}['_threeWayMerge'](_0x469dcb,_0x19745e,_0x53bb64,_0x582bd1){const _0x9a8130=this['editor']['model']['schema'];let _0x392ad=_0x19745e;for(;_0x469dcb[_0x392ad]&&_0x469dcb[_0x392ad]['isAdded'];)_0x392ad++;let _0x4a815e=_0x582bd1;for(;_0x53bb64[_0x4a815e]&&_0x53bb64[_0x4a815e]['isRemoved'];)_0x4a815e++;_0xa221d4(_0x469dcb,_0x19745e,_0x392ad),_0xa221d4(_0x53bb64,_0x582bd1,_0x4a815e);const _0xa88ff2=_0x53bb64['slice'](_0x582bd1,_0x4a815e)['concat'](_0x469dcb['slice'](_0x19745e,_0x392ad));return _0xa88ff2['sort']((_0x2b668c,_0x417bc9)=>_0x2b668c['side']!=_0x417bc9['side']?_0x2b668c['side']-_0x417bc9['side']:_0x2b668c['level']!=_0x417bc9['level']?_0x2b668c['level']-_0x417bc9['level']:_0x2b668c['distance']!=_0x417bc9['distance']?_0x417bc9['distance']-_0x2b668c['distance']:!!_0x2b668c['isAdded']!=!!_0x417bc9['isAdded']?-0x1==_0x2b668c['side']||0x0==_0x2b668c['side']?_0x2b668c['isAdded']?-0x1:0x1:_0x2b668c['isAdded']?0x1:-0x1:_0x2b668c['index']-_0x417bc9['index']),{'commonTape':_0xa88ff2,'iEnd':_0x392ad,'jEnd':_0x4a815e};function _0xa221d4(_0x5139de,_0x36877f,_0x4ade7f){let _0x4944d7=-0x1,_0x53e07f=Number['POSITIVE_INFINITY'],_0x5d564b=!0x0;for(let _0x5c91bd=_0x36877f;_0x5c91bd<_0x4ade7f;_0x5c91bd++)if(_0x9a8130['isInline'](_0x5139de[_0x5c91bd]['item'])||(_0x5d564b=!0x1),_0x5139de[_0x5c91bd]['item']['startIndex']<_0x36877f&&(_0x4944d7=_0x5c91bd),_0x5139de[_0x5c91bd]['item']['endIndex']>=_0x4ade7f){_0x53e07f=_0x5c91bd;break;}_0x5d564b&&(_0x4944d7=_0x4ade7f-0x1);for(let _0x474d6d=_0x36877f;_0x474d6d<_0x4ade7f;_0x474d6d++)_0x5139de[_0x474d6d]['side']=_0x474d6d<=_0x4944d7?-0x1:_0x474d6d<_0x53e07f?0x0:0x1,_0x5139de[_0x474d6d]['index']=_0x474d6d;let _0x3678f9=0x0;for(let _0x30c491=_0x36877f;_0x30c491<=_0x4944d7;_0x30c491++)0x0==_0x5139de[_0x30c491]['distance']?_0x5139de[_0x30c491]['level']=_0x3678f9:(_0x3678f9++,_0x5139de[_0x30c491]['level']=_0x3678f9,_0x3678f9++);for(let _0x375936=_0x36877f;_0x375936<_0x4ade7f;_0x375936++)0x0==_0x5139de[_0x375936]['side']&&(_0x5139de[_0x375936]['level']=_0x3678f9);_0x3678f9=0x0;for(let _0x4f0dc9=_0x4ade7f-0x1;_0x4f0dc9>=_0x53e07f;_0x4f0dc9--)0x0==_0x5139de[_0x4f0dc9]['distance']?_0x5139de[_0x4f0dc9]['level']=_0x3678f9:(_0x3678f9--,_0x5139de[_0x4f0dc9]['level']=_0x3678f9,_0x3678f9--);}}['_fixObsoleteTags'](_0x5b0eca){const _0x578816=new Map(),_0x229e54=this['editor']['model']['schema'];for(let _0x175961=0x1;_0x175961<_0x5b0eca['length'];_0x175961++){let _0x5dafe7,_0x49f393,_0x59b6fd;const _0x599dd1=_0x5b0eca[_0x175961],_0x3f9f81=_0x5b0eca[_0x175961-0x1];if('text'==_0x599dd1['type'])continue;if(_0x599dd1['type']!=_0x3f9f81['type'])continue;if(!_0x229e54['isBlock'](_0x3f9f81['item'])||_0x229e54['isLimit'](_0x3f9f81['item']))continue;if(!_0x229e54['isBlock'](_0x599dd1['item'])||_0x229e54['isLimit'](_0x599dd1['item']))continue;if((_0x5b0eca[_0x175961]['isAdded']||_0x5b0eca[_0x175961]['isAddSuggestion'])&&_0x5b0eca[_0x175961-0x1]['isRemoved'])_0x5dafe7=_0x5b0eca[_0x175961],_0x49f393=_0x5b0eca[_0x175961-0x1],_0x59b6fd=_0x175961-0x1;else{if(!_0x5b0eca[_0x175961]['isRemoved']||!_0x5b0eca[_0x175961-0x1]['isAdded']&&!_0x5b0eca[_0x175961-0x1]['isAddSuggestion'])continue;_0x5dafe7=_0x5b0eca[_0x175961-0x1],_0x49f393=_0x5b0eca[_0x175961],_0x59b6fd=_0x175961;}const _0x17fa7d=_0x5dafe7['level']==_0x49f393['level'],_0x198a4d=Math['abs'](_0x5dafe7['level'])<Math['abs'](_0x49f393['level'])&&0x0==_0x49f393['distance'];(_0x17fa7d||_0x198a4d)&&(_0x578816['set'](_0x49f393['id'],_0x5dafe7['id']),_0x5b0eca['splice'](_0x59b6fd,0x1),_0x175961--,_0x5dafe7['isAdded']=!0x1);}for(let _0x3fab94=0x0;_0x3fab94<_0x5b0eca['length'];_0x3fab94++)_0x578816['has'](_0x5b0eca[_0x3fab94]['pairId'])&&(_0x5b0eca[_0x3fab94]['pairId']=_0x578816['get'](_0x5b0eca[_0x3fab94]['pairId']));}['_removeMissingPairs'](_0x5911fd){const _0x55dca3=new Set(_0x5911fd['map'](_0x271272=>_0x271272['id']));for(let _0x4fe69d=0x0;_0x4fe69d<_0x5911fd['length'];_0x4fe69d++)_0x55dca3['has'](_0x5911fd[_0x4fe69d]['pairId'])||0x0==_0x5911fd[_0x4fe69d]['distance']||(_0x5911fd[_0x4fe69d]['isIncorrect']=!0x0);return _0x5911fd['filter'](_0x12521f=>!_0x12521f['isIncorrect']);}['_markMismatchedRemovedTags'](_0x431f2a){const _0x28cbb3=new Set();for(let _0x4012bf=0x0;_0x4012bf<_0x431f2a['length'];_0x4012bf++){if(_0x28cbb3['has'](_0x431f2a[_0x4012bf]['id'])&&_0x431f2a[_0x4012bf]['isRemoved']&&(_0x431f2a[_0x4012bf]['isIncorrect']=!0x0),_0x431f2a[_0x4012bf]['isIncorrect'])continue;if(0x0==_0x431f2a[_0x4012bf]['distance'])continue;if('elementStart'!=_0x431f2a[_0x4012bf]['type'])continue;if(null==_0x431f2a[_0x4012bf]['pairId'])continue;let _0x4836cd=_0x4012bf+0x1,_0x17213f=0x0;for(;_0x431f2a[_0x4836cd]['id']!=_0x431f2a[_0x4012bf]['pairId'];)'elementStart'==_0x431f2a[_0x4836cd]['type']?_0x17213f++:'elementEnd'==_0x431f2a[_0x4836cd]['type']&&_0x17213f--,_0x4836cd++;if(0x0!=_0x17213f){if(_0x431f2a[_0x4012bf]['isRemoved'])_0x431f2a[_0x4012bf]['isIncorrect']=!0x0;else{for(;_0x4836cd!=_0x4012bf;)_0x431f2a[_0x4836cd]['isRemoved']&&0x0!=_0x431f2a[_0x4836cd]['distance']&&(_0x431f2a[_0x4836cd]['isIncorrect']=!0x0,_0x28cbb3['add'](_0x431f2a[_0x4836cd]['pairId'])),_0x4836cd--;}}}return _0x431f2a['filter'](_0x790842=>!_0x790842['isIncorrect']);}['_removeUnsupportedChanges'](_0x26b1d8){const _0xa71c8d=this['editor']['model']['schema'];for(let _0x486a47=0x0;_0x486a47<_0x26b1d8['length'];_0x486a47++){if(!(_0x26b1d8[_0x486a47]['isAdded']||_0x26b1d8[_0x486a47]['isAddSuggestion']||_0x26b1d8[_0x486a47]['isRemoved']||_0x26b1d8[_0x486a47]['isRemoveSuggestion']))continue;if(0x0==_0x26b1d8[_0x486a47]['distance'])continue;const _0x4ada91=_0x26b1d8[_0x486a47]['item'];_0xa71c8d['isBlock'](_0x4ada91)||_0xa71c8d['isLimit'](_0x4ada91)||(_0x26b1d8[_0x486a47]['isAdded']&&delete _0x26b1d8[_0x486a47]['isAdded'],_0x26b1d8[_0x486a47]['isAddSuggestion']&&delete _0x26b1d8[_0x486a47]['isAddSuggestion'],_0x26b1d8[_0x486a47]['isRemoveSuggestion']&&delete _0x26b1d8[_0x486a47]['isRemoveSuggestion'],_0x26b1d8[_0x486a47]['isRemoved']&&(_0x26b1d8[_0x486a47]['isIncorrect']=!0x0));}return _0x26b1d8['filter'](_0xf0a3f3=>!_0xf0a3f3['isIncorrect']);}['_makeModelFromTape'](_0x1c5ebb,_0xed8873,_0x359ff3){const _0x21033a=new mt(),_0x341797=[],_0x415003=new Map(),_0x3eef44=this['editor']['model'],_0x6c2f1=_0x3eef44['schema'],_0x4e7433=[_0x21033a],_0x31a26a={},_0x5210ca={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x26e290=null;const _0x5cab14=[0x0];for(let _0x21322e=0x0;_0x21322e<_0x1c5ebb['length'];_0x21322e++)if('elementStart'===_0x1c5ebb[_0x21322e]['type']){_0x1c5ebb[_0x21322e]['previousPosition']=_0x3eef44['createPositionFromPath'](_0x21033a,_0x5cab14);const _0x4f8ce2=new ft(_0x1c5ebb[_0x21322e]['item']['name'],_0x1c5ebb[_0x21322e]['item']['getAttributes']());_0x4e7433[0x0]['_appendChild'](_0x4f8ce2),_0x5cab14['push'](0x0),_0x4e7433['unshift'](_0x4f8ce2),_0x1c5ebb[_0x21322e]['nextPosition']=_0x3eef44['createPositionFromPath'](_0x21033a,_0x5cab14);}else'elementEnd'===_0x1c5ebb[_0x21322e]['type']?(_0x4e7433['shift'](),_0x1c5ebb[_0x21322e]['previousPosition']=_0x3eef44['createPositionFromPath'](_0x21033a,_0x5cab14),_0x5cab14['pop'](),_0x5cab14[_0x5cab14['length']-0x1]++,_0x1c5ebb[_0x21322e]['nextPosition']=_0x3eef44['createPositionFromPath'](_0x21033a,_0x5cab14)):(_0x1c5ebb[_0x21322e]['previousPosition']=_0x3eef44['createPositionFromPath'](_0x21033a,_0x5cab14),_0x26e290?_0x26e290['_data']+=_0x1c5ebb[_0x21322e]['item']['data']:_0x26e290=new wt(_0x1c5ebb[_0x21322e]['item']['data'],_0x1c5ebb[_0x21322e]['item']['getAttributes']()),_0x1c5ebb[_0x21322e+0x1]&&'text'===_0x1c5ebb[_0x21322e+0x1]['type']&&_0x2720d3(_0x26e290,_0x1c5ebb[_0x21322e+0x1]['item'])||(_0x4e7433[0x0]['_appendChild'](_0x26e290),_0x26e290=null),_0x5cab14[_0x5cab14['length']-0x1]+=_0x1c5ebb[_0x21322e]['item']['offsetSize'],_0x1c5ebb[_0x21322e]['nextPosition']=_0x3eef44['createPositionFromPath'](_0x21033a,_0x5cab14));for(let _0x29de0b=0x0;_0x29de0b<_0x1c5ebb['length'];_0x29de0b++){const _0x4747e2=_0x1c5ebb[_0x29de0b]['previousPosition'],_0x3c9abd=_0x1c5ebb[_0x29de0b]['nextPosition'];for(const _0x582842 of _0x1c5ebb[_0x29de0b]['markersStart'])_0x415003['set'](_0x582842,{'start':_0x4747e2,'end':null});_0xebc321('isRemoveSuggestion',_0x29de0b,_0x4747e2,_0x3c9abd),_0xebc321('isAddSuggestion',_0x29de0b,_0x4747e2,_0x3c9abd),_0xebc321('isRemoved',_0x29de0b,_0x4747e2,_0x3c9abd),_0xebc321('isAdded',_0x29de0b,_0x4747e2,_0x3c9abd);for(const _0x1bd43c of _0x1c5ebb[_0x29de0b]['markersEnd']){_0x415003['get'](_0x1bd43c)['end']=_0x3c9abd;}}for(const [_0xffcd3e,_0x4db0fb]of _0x415003){const _0x255a0e=this['editor']['model']['createRange'](_0x4db0fb['start'],_0x4db0fb['end']);_0x21033a['markers']['set'](_0xffcd3e,_0x255a0e);}return _0x341797['sort']((_0x596787,_0x3d2ed1)=>{const _0x2d263b=_0x21033a['markers']['get']('revision:'+_0x596787['id']),_0x5d16e1=_0x21033a['markers']['get']('revision:'+_0x3d2ed1['id']);return _0x2d263b['start']['isBefore'](_0x5d16e1['start'])?-0x1:_0x2d263b['start']['isAfter'](_0x5d16e1['start'])?0x1:_0x2d263b['end']['isBefore'](_0x5d16e1['end'])?-0x1:_0x2d263b['end']['isAfter'](_0x5d16e1['end'])?0x1:'add'===_0x596787['type']?-0x1:0x1;}),{'root':_0x21033a,'changes':_0x341797};function _0xebc321(_0x303072,_0x1c1f78,_0x5c4715,_0x498ae7){const _0x1d0154=!!_0x1c5ebb[_0x1c1f78][_0x303072],_0x536b7f=_0x1d0154?_0x1c5ebb[_0x1c1f78][_0x303072]['userId']:null,_0x1c72d8=_0x1c1f78===_0x1c5ebb['length']-0x1,_0x5ed102=_0x5210ca[_0x303072][0x0],_0x2fb7e6=_0x6c2f1['isObject'](_0x1c5ebb[_0x1c1f78]['item']);!_0x31a26a[_0x303072]&&_0x1d0154?_0x31a26a[_0x303072]={'start':_0x5c4715,'tapeItem':_0x1c5ebb[_0x1c1f78],'userId':_0x536b7f,'type':_0x303072}:_0x31a26a[_0x303072]&&!_0x1d0154?(_0x31a26a[_0x303072]['end']=_0x5c4715,_0x3f44e8(_0x31a26a[_0x303072]),_0x31a26a[_0x303072]=null):_0x31a26a[_0x303072]&&_0x1d0154&&_0x31a26a[_0x303072]['userId']!==_0x536b7f&&(_0x31a26a[_0x303072]['end']=_0x5c4715,_0x5ed102&&_0x5ed102['userId']===_0x31a26a[_0x303072]['userId']||_0x3f44e8(_0x31a26a[_0x303072]),_0x31a26a[_0x303072]={'start':_0x5c4715,'tapeItem':_0x1c5ebb[_0x1c1f78],'userId':_0x536b7f,'type':_0x303072}),_0x31a26a[_0x303072]&&_0x2fb7e6&&('elementStart'!==_0x1c5ebb[_0x1c1f78]['type']||_0x5ed102&&_0x5ed102['userId']===_0x536b7f||_0x5210ca[_0x303072]['unshift']({'userId':_0x536b7f,'object':_0x1c5ebb[_0x1c1f78]['item'],'change':_0x31a26a[_0x303072]}),'elementEnd'===_0x1c5ebb[_0x1c1f78]['type']&&_0x5ed102&&_0x5ed102['object']===_0x1c5ebb[_0x1c1f78]['item']&&(_0x5210ca[_0x303072]['shift'](),_0x31a26a[_0x303072]=_0x5ed102['change'])),_0x31a26a[_0x303072]&&_0x1c72d8&&(_0x31a26a[_0x303072]['end']=_0x498ae7,_0x3f44e8(_0x31a26a[_0x303072]),_0x31a26a[_0x303072]=null);}function _0x3f44e8({start:_0x2aae90,end:_0x419dd7,tapeItem:_0xd2bcb3,userId:_0x55a8c4,type:_0x261d1e}){const _0x37a076=_0xd2bcb3['item'],_0x4e17f3=_0x3eef44['schema']['isBlock'](_0x37a076)&&!_0x3eef44['schema']['isLimit'](_0x37a076),_0x1a0761=_0x2aae90['nodeAfter']==_0x419dd7['parent']&&_0x419dd7['isAtStart'];if(_0x4e17f3&&_0x1a0761)return;const _0x5c9197=_0x3eef44['createRange'](_0x2aae90,_0x419dd7),_0xd85f8f=_0xed8873['get'](_0x55a8c4),_0x573b5d=new r({'author':_0xd85f8f,'type':'isAdded'==_0x261d1e||'isAddSuggestion'==_0x261d1e?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x261d1e||'isRemoveSuggestion'==_0x261d1e},'createdAt':new Date(),'rootName':_0x359ff3});_0x341797['push'](_0x573b5d),_0x21033a['markers']['set']('revision:'+_0x573b5d['id'],_0x5c9197);}function _0x2720d3(_0x2b92a0,_0x1d5602){const _0x57a5c0=_0x2b92a0['getAttributes'](),_0x5bc22d=_0x1d5602['getAttributes']();for(const _0x5e4707 of _0x57a5c0){if(_0x5e4707[0x1]!==_0x1d5602['getAttribute'](_0x5e4707[0x0]))return!0x1;_0x5bc22d['next']();}return _0x5bc22d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x14d13e=>{const _0x4b05c4=_0x14d13e['markerName']['split'](':')[0x1],_0x350fa1=this['_getChangeFromId'](_0x4b05c4);if(!_0x350fa1)return null;const _0x512dac='add'==_0x350fa1['type']?'insertion':'deletion',_0x270616=['ck-suggestion-marker','ck-suggestion-marker-'+_0x512dac];return _0x350fa1['data']['isSuggestion']&&_0x270616['push']('ck-suggestion-marker-'+_0x512dac+'-new'),this['activeChange']==_0x350fa1&&_0x270616['push']('ck-suggestion-marker--active'),{'classes':_0x270616,'attributes':{'data-change-id':_0x4b05c4}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x338acb=>{_0x338acb['on']('element:pre',(_0x4492c6,_0x423a72,_0x3f332b)=>{const _0x1a234c=_0x423a72['viewItem']['getChild'](0x0);if(!_0x1a234c||!_0x1a234c['is']('element','code'))return;if(!_0x3f332b['consumable']['consume'](_0x1a234c,{'attributes':['vid_start','vid_end']}))return;const _0x1723e8=_0x423a72['modelRange']['start']['nodeAfter'];_0x3f332b['writer']['setAttribute']('vid_start',_0x1a234c['getAttribute']('vid_start'),_0x1723e8),_0x3f332b['writer']['setAttribute']('vid_end',_0x1a234c['getAttribute']('vid_end'),_0x1723e8);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x180d68=>{_0x180d68['on']('element',(_0x1abeb7,_0xe16b6,_0x595e63)=>{if(!_0x595e63['consumable']['consume'](_0xe16b6['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xe16b6['modelRange']['isCollapsed'])return;const _0x25e4e9=_0xe16b6['modelRange']['start']['nodeAfter'];_0x25e4e9['hasAttribute']('vid_start')||_0x25e4e9['hasAttribute']('vid')||(_0x595e63['writer']['setAttribute']('vid_start',_0xe16b6['viewItem']['getAttribute']('vid_start'),_0x25e4e9),_0x595e63['writer']['setAttribute']('vid_end',_0xe16b6['viewItem']['getAttribute']('vid_end'),_0x25e4e9));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xb78ea=>_0xb78ea['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x475a31,[,_0x4e68c4])=>{['vid_start','vid_end','vid']['includes'](_0x4e68c4)&&(_0x475a31['return']=!0x0,_0x475a31['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1957ba=>{_0x1957ba['on']('attribute:vid',(_0x3a48bc,_0x317a57,_0x1cb51b)=>{if('\x20'!=_0x317a57['item']['data']||_0x317a57['item']['parent']['maxOffset']>0x1)return;if(!_0x1cb51b['consumable']['consume'](_0x317a57['item'],_0x3a48bc['name']))return;const _0xb6d9bf=_0x1cb51b['writer'],_0x349938=_0x1cb51b['mapper']['toViewRange'](_0x317a57['range']);_0xb6d9bf['wrap'](_0x349938,_0xb6d9bf['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x16f39c){const _0x4426e2=_0x16f39c['plugins']['get']('RevisionViewer');return(_0x1c8b3c,_0x1f5bf2,_0xfa6aa3)=>{const _0x1b180f=_0x1f5bf2['markerName']['split'](':')[0x1],_0x42f995=_0x4426e2['_getChangeFromId'](_0x1b180f);if(!_0x42f995)return null;const _0x4d1c92='add'==_0x42f995['type']?'split':'merge';if(!_0xfa6aa3['consumable']['test'](_0x1f5bf2['markerRange'],_0x1c8b3c['name']))return;const _0x36710e=_0x1f5bf2['markerRange']['getWalker'](),_0x3b45b1=_0x1f5bf2['markerRange']['start'],_0x4e96a7=_0x16f39c['model']['schema'];let _0x5b5659=null,_0x1c02f5=null,_0x348b4f=!0x1,_0x15523c=!0x1;for(const _0x1a1220 of _0x36710e){const _0x5b9448=_0x1a1220['item'];_0x348b4f=_0x348b4f||_0x4e96a7['isContent'](_0x5b9448);const _0xea3b50=_0xfa6aa3['mapper']['toViewElement'](_0x5b9448);if(_0xea3b50&&_0xea3b50['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1a1220['type']&&(_0x4e96a7['isBlock'](_0x5b9448)&&!_0x4e96a7['isLimit'](_0x5b9448)&&(_0x5b9448['nextSibling']||_0x3b45b1['isAtEnd']?_0x5b5659&&_0x5b5659['parent']==_0x5b9448||(_0x5b5659=_0x5b9448,_0x128437(_0x1a1220['previousPosition']),_0x15523c=!0x0):_0x1c02f5=_0x1c02f5||_0x1a1220['previousPosition']));}function _0x128437(_0x23af68){const _0x2f99e8=_0xfa6aa3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4d1c92}),_0x3d0c71=_0xfa6aa3['mapper']['toViewPosition'](_0x23af68);_0x42f995['data']['isSuggestion']&&_0xfa6aa3['writer']['addClass']('ck-suggestion-marker-'+_0x4d1c92+'-new',_0x2f99e8),_0x4426e2['activeChange']==_0x42f995&&_0xfa6aa3['writer']['addClass']('ck-suggestion-marker--active',_0x2f99e8),_0xfa6aa3['writer']['insert'](_0x3d0c71,_0x2f99e8),_0xfa6aa3['mapper']['bindElementToMarker'](_0x2f99e8,_0x1f5bf2['markerName']);}_0x348b4f||_0x15523c||!_0x1c02f5||_0x128437(_0x1c02f5);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x5554c6,_0x3ef4ac,_0x92efd7)=>{const _0x16ad30=_0x92efd7['mapper']['markerNameToElements'](_0x3ef4ac['markerName']);if(_0x16ad30){for(const _0x3f825d of _0x16ad30)(_0x3f825d['hasClass']('ck-suggestion-marker-split')||_0x3f825d['hasClass']('ck-suggestion-marker-merge'))&&(_0x92efd7['mapper']['unbindElementFromMarkerName'](_0x3f825d,_0x3ef4ac['markerName']),_0x92efd7['writer']['remove'](_0x3f825d));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x278e94,_0x545a4f,_0x25cc37)=>{const _0x5bcebd=_0x545a4f['markerName']['split'](':')[0x1],_0x54b2d3=this['_getChangeFromId'](_0x5bcebd);if(!_0x54b2d3)return null;const _0x918baf='add'==_0x54b2d3['type']?'split':'merge';if(_0x25cc37['consumable']['test'](_0x545a4f['markerRange'],_0x278e94['name']))for(const _0x1de8bd of _0x545a4f['markerRange']['getItems']()){if(!_0x1de8bd['is']('element','softBreak'))continue;const _0x3c65f0=_0x25cc37['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x918baf}),_0x269b82=_0x25cc37['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1de8bd));_0x54b2d3['data']['isSuggestion']&&_0x25cc37['writer']['addClass']('ck-suggestion-marker-'+_0x918baf+'-new',_0x3c65f0),this['activeChange']==_0x54b2d3&&_0x25cc37['writer']['addClass']('ck-suggestion-marker--active',_0x3c65f0),_0x25cc37['writer']['insert'](_0x269b82,_0x3c65f0),_0x25cc37['mapper']['bindElementToMarker'](_0x3c65f0,_0x545a4f['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x98c8a1=>{for(const _0x4d44c6 of this['editor']['model']['document']['getRootNames']()){const _0x569af1=this['editor']['model']['document']['getRoot'](_0x4d44c6),_0x3e32bf=this['editor']['editing']['view']['document']['getRoot'](_0x4d44c6);if(_0x3e32bf){const _0x48fa33=_0x569af1['getAttribute']('revisionHistoryAttachChange');if(_0x98c8a1['removeAttribute']('data-change-id',_0x3e32bf),_0x98c8a1['removeClass']('ck-revision-history-root-add',_0x3e32bf),_0x98c8a1['removeClass']('ck-revision-history-root-remove',_0x3e32bf),_0x98c8a1['removeClass']('ck-revision-history-root--active',_0x3e32bf),_0x48fa33){const _0x1f8bed=this['_getChangeFromId'](_0x48fa33);if(!_0x1f8bed)return null;_0x98c8a1['setAttribute']('data-change-id',_0x48fa33,_0x3e32bf),_0x98c8a1['addClass']('ck-revision-history-root-'+_0x1f8bed['type'],_0x3e32bf),this['activeChange']==_0x1f8bed&&_0x98c8a1['addClass']('ck-revision-history-root--active',_0x3e32bf);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2bb5c5=>'revision-comment:'+_0x2bb5c5,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0xbe433e=>'revision-suggestion:'+_0xbe433e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3dedbf=>({'name':'suggestion:'+_0x3dedbf,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2b7b26=>{const _0x21336c=_0x2b7b26['markerName']['split'](':')[0x1];return'insertion'!=_0x21336c&&'deletion'!=_0x21336c?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x21336c]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x27b7ad,_0xb70ae1,_0xae0fc6)=>{const _0x12d0bd=_0xae0fc6['mapper']['markerNameToElements'](_0xb70ae1['markerName']);if(_0x12d0bd){for(const _0x15ee53 of _0x12d0bd)_0x15ee53['is']('uiElement')&&(_0xae0fc6['mapper']['unbindElementFromMarkerName'](_0x15ee53,_0xb70ae1['markerName']),_0xae0fc6['writer']['remove'](_0x15ee53));}},{'priority':'high'});}['_getChangeFromId'](_0x52d9b1){return this['_changeIdToChange']['get'](_0x52d9b1);}['_getViewForChange'](_0xc6c211){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0xc6c211),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3626fd,_0x180ecd,_0x24ef1f,_0x9948c9)=>{_0x9948c9&&this['_balloon']['remove'](_0x9948c9),_0x24ef1f&&(this['_balloon']['add']({'view':_0x24ef1f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x1a437e=this['editor']['editing'],_0x29fd2d=this['_getChangeFromId'](_0x24ef1f['changeId']);let _0x5b040f;if(_0x29fd2d['data']['isOnRoot']){const _0x53bb0c=_0x1a437e['view']['getDomRoot'](_0x29fd2d['rootName']);_0x5b040f=Array['from'](_0x53bb0c['getClientRects']());}else{const _0x53f5f6=this['editor']['model']['markers']['get']('revision:'+_0x24ef1f['changeId']);_0x5b040f=Array['from'](_0x1a437e['mapper']['markerNameToElements'](_0x53f5f6['name']))['map'](_0x4a9cfe=>_0x1a437e['view']['domConverter']['mapViewToDom'](_0x4a9cfe))['map'](_0x2c53ae=>Array['from'](_0x2c53ae['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x5b040f[0x0];return _0x5b040f['find'](_0x26c2d6=>_0x26c2d6['top']-0x3<=this['_activeViewTarget']['y']&&_0x26c2d6['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x26c2d6['left']-0x3<=this['_activeViewTarget']['x']&&_0x26c2d6['right']+0x3>=this['_activeViewTarget']['x'])||_0x5b040f[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x919a85,_0x3d0e93,_0xc21fdd,_0x43ac0f)=>{this['activeView']=_0xc21fdd?this['_getViewForChange'](_0xc21fdd):null,this['editor']['model']['change'](()=>{const _0x3c6b45=this['editor']['editing'];_0x43ac0f&&(_0x43ac0f['data']['isOnRoot']?_0x3c6b45['view']['change'](_0x410e30=>{_0x410e30['removeClass']('ck-revision-history-root--active',_0x3c6b45['view']['document']['getRoot'](_0x43ac0f['rootName']));}):_0x3c6b45['reconvertMarker']('revision:'+_0x43ac0f['id'])),_0xc21fdd&&(_0xc21fdd['data']['isOnRoot']?_0x3c6b45['view']['change'](_0x325632=>{_0x325632['addClass']('ck-revision-history-root--active',_0x3c6b45['view']['document']['getRoot'](_0xc21fdd['rootName']));}):_0x3c6b45['reconvertMarker']('revision:'+_0xc21fdd['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0xa2956f,_0x4edfb0)=>{if(this['activeChange'])return;const _0x319a3a=this['_findChangeIdFromDomTarget'](_0x4edfb0['target']),_0x4aadfd=this['_changeIdToChange']['get'](_0x319a3a);_0x4aadfd?(this['_activeViewTarget']={'x':_0x4edfb0['domEvent']['x'],'y':_0x4edfb0['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x4aadfd)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x24ef8d,_0x1ca3fe)=>{const _0x3fa728=this['_findChangeIdFromDomTarget'](_0x1ca3fe['target']),_0x5bdb45=this['_changeIdToChange']['get'](_0x3fa728);_0x5bdb45?(this['_activeViewTarget']={'x':_0x1ca3fe['domEvent']['x'],'y':_0x1ca3fe['domEvent']['y']},_0x5bdb45===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5bdb45):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x114418){do{const _0x5a335b=_0x114418['getAttribute']('data-change-id');if(_0x5a335b)return _0x5a335b;_0x114418=_0x114418['parent'];}while(_0x114418);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4973fa=>{for(const _0x22ad22 of this['editor']['model']['markers'])_0x4973fa['removeMarker'](_0x22ad22);});}}function Z(_0x4a144f,_0x13bb9a){return(_0x575910,_0x220ead,_0x167150)=>{if(!_0x167150['consumable']['test'](_0x220ead['markerRange'],_0x575910['name']))return;const _0x46053b=_0x220ead['markerRange']['getWalker'](),_0x291665=_0x220ead['markerRange']['start'],_0x5dc9cd=_0x4a144f['model']['schema'];let _0x2f60d2=null,_0x584dfc=null,_0x235d4e=!0x1,_0x31bcf7=!0x1;for(const _0xe8bbb8 of _0x46053b){const _0x3ae5b0=_0xe8bbb8['item'];_0x235d4e=_0x235d4e||_0x5dc9cd['isContent'](_0x3ae5b0);const _0x47077e=_0x167150['mapper']['toViewElement'](_0x3ae5b0);if(_0x47077e&&_0x47077e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xe8bbb8['type']&&(_0x5dc9cd['isBlock'](_0x3ae5b0)&&!_0x5dc9cd['isLimit'](_0x3ae5b0)&&(_0x3ae5b0['nextSibling']||_0x291665['isAtEnd']?_0x2f60d2&&_0x2f60d2['parent']==_0x3ae5b0||(_0x2f60d2=_0x3ae5b0,_0x5691c1(_0xe8bbb8['previousPosition']),_0x31bcf7=!0x0):_0x584dfc=_0x584dfc||_0xe8bbb8['previousPosition']));}function _0x5691c1(_0xcfec5f){const _0x52ca32=_0x167150['mapper']['toViewPosition'](_0xcfec5f),_0x258a4b=_0x167150['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x13bb9a});_0x167150['writer']['insert'](_0x52ca32,_0x258a4b),_0x167150['mapper']['bindElementToMarker'](_0x258a4b,_0x220ead['markerName']);}_0x235d4e||_0x31bcf7||!_0x584dfc||_0x5691c1(_0x584dfc);};}class _t extends _0x82edf0{constructor(_0x172a35){super(_0x172a35);const _0x5a3b03=_0x172a35['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x5a3b03,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5a3b03,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x430e3e=this['editor'],_0x1b7ec7=_0x430e3e['plugins']['get'](d),_0x259321=_0x1b7ec7['isReady']?_0x1b7ec7['diff']['newRevisionId']:null;_0x430e3e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x259321);}['refresh'](){const {isReady:_0x149370,isEnabled:_0x5b5266,repository:_0x267f69,diff:_0x36aa80}=this['editor']['plugins']['get'](d),_0x2cb7de=_0x36aa80&&_0x267f69['getLaterVisibleRevision'](_0x36aa80['newRevisionId']);this['isEnabled']=_0x149370&&_0x5b5266&&Boolean(_0x2cb7de);}}class yt extends _0x82edf0{['_step'];constructor(_0x8b8fff,{direction:_0x288fce}){super(_0x8b8fff);const _0x1b618c=_0x8b8fff['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x288fce?0x1:-0x1,this['listenTo'](_0x1b618c,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1b618c,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1b618c,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x406317=this['editor'],_0x1759c2=_0x406317['plugins']['get'](d),{isNavigationMode:_0x295f45,currentChangeNumber:_0x24137a}=_0x1759c2;let _0x11f94f;if(_0x1759c2['activeChange']=_0x295f45?_0x1759c2['diff']['changes']['get'](_0x24137a+this['_step']):_0x1759c2['diff']['changes']['first'],_0x1759c2['activeChange']['data']['isOnRoot'])_0x11f94f=_0x406317['editing']['view']['getDomRoot'](_0x1759c2['activeChange']['rootName']);else{const _0xba7074=_0x406317['model']['markers']['get']('revision:'+_0x1759c2['activeChange']['id']);_0x11f94f=_0x5990eb(_0x406317['editing'],_0xba7074);}_0x515f4b({'target':_0x11f94f,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x2ff995,currentChangeNumber:_0x386b72,numberOfChanges:_0x22ebf4,isReady:_0x4f480e,isEnabled:_0x42b04c}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x42b04c&&_0x4f480e&&_0x22ebf4)&&(!_0x2ff995||(0x1===this['_step']?_0x386b72<_0x22ebf4-0x1:_0x386b72>0x0));}}class di extends _0x4cb52{constructor(_0x1e5633){super(_0x1e5633);const _0x61bdfb=this['bindTemplate'],_0x28acff=new _0x219c24(_0x1e5633),_0x4b6313=new _0x219c24(_0x1e5633);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',(_0x198918,_0x1f926e)=>_0x198918&&_0x1f926e>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3a8621,_0x122040,_0x515ffe,_0x197dd7)=>{if(!_0x3a8621)return m(_0x1e5633,'Loading...');if(!_0x515ffe)return m(_0x1e5633,'No\x20changes');const _0x3db6db=m(_0x1e5633,'NUMBER_OF_CHANGES',_0x515ffe);return _0x197dd7?m(_0x1e5633,'X_OF_Y_CHANGES',[_0x122040+0x1,_0x515ffe]):_0x3db6db;}),_0x28acff['set']({'label':m(_0x1e5633,'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'}),_0x4b6313['set']({'label':m(_0x1e5633,'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'}),_0x28acff['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4b6313['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x28acff['on']('execute',()=>this['fire']('execute','backward')),_0x4b6313['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',_0x61bdfb['if']('_isStatusLabelVisible','ck-hidden',_0x1e28a9=>!_0x1e28a9)]},'children':[{'text':_0x61bdfb['to']('isNavigationMode',_0x307659=>_0x307659?m(_0x1e5633,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x1e5633,'Total')+':\x20')}]},{'text':_0x61bdfb['to']('_statusText')}]},new _0x28a40c(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x28acff,_0x4b6313]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x23fe3b{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5b2f41=this['editor']['editing']['view'];_0x5b2f41['change'](_0x49b5f0=>{for(const _0x2288dc of _0x5b2f41['document']['roots'])_0x49b5f0['addClass'](ce,_0x2288dc);});}['hide'](){const _0x8319e2=this['editor']['editing']['view'];_0x8319e2['change'](_0x32c5fd=>{for(const _0x509cfa of _0x8319e2['document']['roots'])_0x32c5fd['removeClass'](ce,_0x509cfa);});}}class g extends _0x23fe3b{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x445f3e=this['editor'],_0x468350=_0x445f3e['plugins']['get'](d),_0x5e6bc4=_0x445f3e['plugins']['get'](ae);_0x445f3e['ui']['componentFactory']['add']('exitToEditing',_0x509071=>{const _0x2f5eef=new _0x219c24(_0x509071);return _0x2f5eef['set']({'label':m(_0x509071,'Back\x20to\x20editing'),'icon':_0x5d0720['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x2f5eef,'execute',()=>{_0x445f3e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x2f5eef;}),_0x445f3e['ui']['componentFactory']['add']('restoreRevision',_0x51a292=>{const _0x334340=new _0x219c24(_0x51a292);return _0x334340['set']({'label':m(_0x51a292,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x334340['bind']('isEnabled')['to'](_0x445f3e['commands']['get']('restoreRevision')),this['listenTo'](_0x334340,'execute',()=>_0x445f3e['execute']('restoreRevision')),_0x334340;}),_0x445f3e['ui']['componentFactory']['add']('changesNavigation',_0x3e8cf6=>{const _0x20b028=new di(_0x3e8cf6),_0x50a809=_0x445f3e['commands']['get']('showPreviousChange'),_0x5b8d04=_0x445f3e['commands']['get']('showNextChange');return _0x20b028['bind']('isBackwardNavigationEnabled')['to'](_0x50a809,'isEnabled'),_0x20b028['bind']('isForwardNavigationEnabled')['to'](_0x5b8d04,'isEnabled'),_0x20b028['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x468350),this['listenTo'](_0x20b028,'execute',(_0x46e06f,_0x5ab9aa)=>{_0x445f3e['execute']('forward'===_0x5ab9aa?'showNextChange':'showPreviousChange');}),_0x20b028;}),_0x5e6bc4['show'](),_0x468350['on']('change:isReady',(_0x5ccb15,_0x1ab840,_0x56d57c)=>{_0x56d57c?_0x5e6bc4['hide']():_0x5e6bc4['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x12441a,_0x54dde3){super(_0x12441a,_0x54dde3);const _0x291461=this['bindTemplate'];this['set']({'label':m(_0x12441a,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x12441a,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x291461['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 _0x179c75=this['fieldView']['element'];this['_tooltipString']=_0x179c75['scrollWidth']>_0x179c75['clientWidth']&&_0x179c75['value']||'';}}class ti extends _0x4cb52{constructor(_0x2edfef,_0x3481c9,_0x4713d6){super(_0x2edfef);const _0x1e6ebf=new _0x2a92f3();_0x1e6ebf['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 _0x2ab9c9=['ck','ck-revision-history-sidebar__revision-author'];_0x4713d6&&_0x2ab9c9['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2e3a6a=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x2edfef,_0x4713d6?'Revision\x20creator':'Revision\x20author')},'children':[_0x1e6ebf,_0x3481c9['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2ab9c9},'children':_0x2e3a6a});}}function ni(_0x5d8de7,_0x358e80){const _0x1eca2d=_0x5d8de7['bindTemplate'],_0x5f5308=_0x5d8de7['locale'],_0x1d0e07=_0x4daaa8(_0x5f5308);_0x1d0e07['panelPosition']='sw';const _0x4c3d4d=function(_0x20dc39,_0x20658d){const _0x52636e=function(_0x11792f,_0x50bfba){const _0x229396=_0x11792f['locale'],_0x10292e={'Compare\x20against\x20selected':m(_0x229396,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x229396,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x229396,'Restore\x20this\x20revision')};return _0x50bfba['map'](_0x542186=>{const _0xc43b65=_0x10292e[_0x542186['name']];return _0xc43b65&&_0xc43b65!==_0x542186['name']&&(_0x542186['name']=_0xc43b65),_0x542186;});}(_0x20dc39,_0x20658d),_0x5474cd=new _0x2733e7();for(const _0x4a1aad of _0x52636e){const _0x244cd5={'type':'button','model':new to({'label':_0x4a1aad['name'],'class':_0x4a1aad['class'],'withText':!0x0,'role':'menuitem','_action':_0x4a1aad['action']})};_0x244cd5['model']['bind']('isEnabled')['to'](_0x20dc39,'isActionsDropdownOpen',_0x3099c0=>'function'!=typeof _0x4a1aad['isEnabled']||(!_0x3099c0||_0x4a1aad['isEnabled'](_0x20dc39))),_0x5474cd['add'](_0x244cd5);}return _0x5474cd;}(_0x5d8de7,_0x358e80);return _0x5d8de7['bind']('isActionsDropdownOpen')['to'](_0x1d0e07,'isOpen'),_0x1d0e07['buttonView']['set']({'label':m(_0x5f5308,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5d0720['threeVerticalDots']}),_0x1d0e07['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1eca2d['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1eca2d['to'](_0x13a287=>_0x13a287['stopPropagation']())}}),_0x1d0e07['on']('execute',_0x1b69f2=>{_0x5d8de7['isReady']&&'function'==typeof _0x1b69f2['source']['_action']&&_0x1b69f2['source']['_action'](_0x5d8de7);}),_0x34f7ce(_0x1d0e07,_0x4c3d4d,{'role':'menu'}),_0x1d0e07['listenTo'](_0x5d8de7,'change:isActionsDropdownOpen',(_0x9cbb8c,_0x314c09,_0x31e1ca)=>{if(_0x31e1ca)for(const _0x168381 of _0x1d0e07['listView']['items']){const _0xb47fc2=_0x168381['children']['first'],_0x240398=_0x358e80['find'](_0x3f45f5=>_0x3f45f5['action']===_0xb47fc2['_action'])['isVisible'];_0x168381['isVisible']=void 0x0===_0x240398||_0x240398(_0x5d8de7);}}),_0x1d0e07;}class ai extends/* #__PURE__ -- @preserve */
26
+ _0x4a7df6(_0x4cb52){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5d2f10,_0x253c9b,_0x22b4ab,_0x36e210){super(_0x5d2f10);const _0x4f2594=this['bindTemplate'],_0x58ae53=function(_0xd6b96c,_0x50b8c6){const _0x11ce94=Array['from'](_0x50b8c6['authors'])['filter'](_0x2efbdd=>_0x2efbdd!=_0x50b8c6['creator']);return _0x50b8c6['creator']&&_0x11ce94['unshift'](_0x50b8c6['creator']),_0x11ce94['map'](_0x3da2ce=>new ti(_0xd6b96c,_0x3da2ce,_0x3da2ce==_0x50b8c6['creator']));}(_0x5d2f10,_0x253c9b);this['id']=_0x253c9b['id'],this['_revision']=_0x253c9b,this['_requireRevisionName']=_0x36e210,this['bind']('name','createdAt')['to'](_0x253c9b),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x413c54=>{return _0x43f8c2=_0x5d2f10['uiLanguage'],(_0x54b16c=_0x413c54)['toLocaleDateString'](_0x43f8c2,{'month':'long','day':'numeric'})+',\x20'+_0x54b16c['toLocaleTimeString'](_0x43f8c2,{'hour':'numeric','minute':'numeric'});var _0x43f8c2,_0x54b16c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x5d2f10,_0x1ddc75),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x57a06d=>_0x57a06d||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0xf2a336,_0x716cae)=>_0xf2a336&&_0x716cae),this['revisionActionsView']=_0x22b4ab&&_0x22b4ab['length']?ni(this,_0x22b4ab):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4f2594['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4f2594['if']('isEnabled','ck-disabled',_0x209c47=>!_0x209c47),_0x4f2594['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4f2594['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4f2594['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':_0x4f2594['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':_0x58ae53}]},this['revisionActionsView']],'on':{'click':_0x4f2594['to'](_0x48f2d3=>{_0x48f2d3['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0xf5adbb=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0xf5adbb,'change',()=>{this['_requireRevisionName']&&!_0xf5adbb['value']||this['fire']('setName',{'id':this['id'],'name':_0xf5adbb['value']}),_0xf5adbb['value']||(_0xf5adbb['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(_0x395613,_0x5eeb7e){const _0x1e7009=_0x304bdb['fromJSDate'](_0x395613)['setLocale'](_0x5eeb7e),_0x3be02a=_0x304bdb['local'](),_0x5d2968=_0x3be02a['minus']({'days':0x1})['startOf']('day');let _0x15f526,_0x2607ef;return _0x1e7009['hasSame'](_0x3be02a,'day')?(_0x15f526=_0x1e7009['startOf']('day')['toJSDate'](),_0x2607ef=_0x1e7009['toRelativeCalendar']()):_0x1e7009['hasSame'](_0x5d2968,'day')?(_0x15f526=_0x5d2968['toJSDate'](),_0x2607ef=_0x1e7009['toRelativeCalendar']()):_0x1e7009['hasSame'](_0x3be02a,'week')?(_0x15f526=_0x1e7009['startOf']('week')['toJSDate'](),_0x2607ef=_0x1e7009['weekdayLong']||''):_0x1e7009['hasSame'](_0x3be02a,'year')?(_0x15f526=_0x1e7009['startOf']('month')['toJSDate'](),_0x2607ef=_0x1e7009['monthLong']||''):(_0x15f526=_0x1e7009['startOf']('year')['toJSDate'](),_0x2607ef=String(_0x1e7009['year'])),{'startDate':_0x15f526,'localizedPeriodName':_0x2607ef};}class vi extends _0x4cb52{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x175be9,_0x268ebd,_0x3b7f52,_0x39fd21){super(_0x175be9);const _0x2e78d2=mi(_0x268ebd,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x268ebd,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3b7f52,this['_requireRevisionName']=_0x39fd21,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':_0x2e78d2}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x319a38){const _0x4ba740=new ai(this['locale'],_0x319a38,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x4ba740);}['removeRevision'](_0x1fd873){const _0x3725b0=this['revisionViews']['find'](_0x5d3e54=>_0x5d3e54['id']===_0x1fd873['id']);this['revisionViews']['remove'](_0x3725b0);}}class as extends _0x4cb52{constructor(_0x514ee8){super(_0x514ee8);const _0x5b7db5=new _0x2a92f3();_0x5b7db5['content']=_0x5d0720['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x5b7db5,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x514ee8,'Revision\x20history')]}]});}}class li extends _0x4cb52{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4a0472,_0x3677af,_0x237eac,_0x2d5f24){super(_0x4a0472);const _0x41a34d=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x3677af,this['_revisionActions']=_0x237eac,this['_requireRevisionName']=_0x2d5f24,this['on']('select',(_0x37167a,_0x4dffca)=>{this['fire']('revisionSelected',_0x4dffca);}),this['on']('setName',(_0x3e58f9,_0xe4a508)=>{this['fire']('revisionSetName',_0xe4a508);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x4a0472),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x41a34d['if']('isEnabled','ck-disabled',_0x3ad098=>!_0x3ad098)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x10f859 of this['_revisions'])this['_addRevision'](_0x10f859);this['_revisions']['on']('add',(_0xe387c5,_0x1f894c)=>{this['_addRevision'](_0x1f894c);}),this['_revisions']['on']('remove',(_0x5b6775,_0x196016)=>{this['_removeRevision'](_0x196016);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x51a307=>_0x51a307['revisionViews']['map'](_0x3847ba=>_0x3847ba))['flat']();}['selectRevision'](_0xbac942){for(const _0x59afc0 of this['revisionViews'])_0xbac942&&_0xbac942['id']===_0x59afc0['id']?_0x59afc0['select']():_0x59afc0['deselect']();}['highlightRevisions'](_0x379ea7){for(const _0x4c4d14 of this['revisionViews'])_0x379ea7['some'](({id:_0x578f73})=>_0x578f73===_0x4c4d14['id'])?_0x4c4d14['highlight']():_0x4c4d14['unhighlight']();}['_addRevision'](_0x331872){const _0x42be7f=mi(_0x331872['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1f55d6=this['timePeriodViews']['get'](0x0);_0x1f55d6&&_0x1f55d6['startDate']['getTime']()===_0x42be7f['getTime']()||(_0x1f55d6=new vi(this['locale'],_0x42be7f,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1f55d6)),_0x1f55d6['addRevision'](_0x331872);}['_removeRevision'](_0x1374f4){const _0x4d8972=mi(_0x1374f4['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4d8972)['removeRevision'](_0x1374f4);}['_getTimePeriodViewByStartDate'](_0x45b478){return this['timePeriodViews']['find'](_0x2b114f=>_0x2b114f['startDate']['getTime']()===_0x45b478['getTime']());}}class w extends _0x23fe3b{['_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(_0x1f2bb4){super(_0x1f2bb4),this['_revisionViewer']=_0x1f2bb4['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x166bc6=this['_revisionsRepository']['_revisions'],_0x2884bd=this['_createRevisionActions'](),_0x4ab639=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ci(this['editor']['locale'],_0x166bc6,_0x2884bd,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',(_0x53b56e,_0x2857fd)=>{_0x2857fd['revisionViews']['on']('add',(_0x8e1249,_0x556d3d)=>{_0x556d3d['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)),_0x4ab639['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x5b41f1=this['_revisionsRepository']['getRevision'](0x0);if(_0x5b41f1){const _0x2431eb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5b41f1['id']);this['_revisionViewer']['compare'](_0x5b41f1,_0x2431eb);}}['_handleRevisionSelected'](_0x3feeb8,_0x4e7a1a){const _0x2cc1d5=this['_revisionsRepository']['getRevision'](_0x4e7a1a['id']),_0x599266=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2cc1d5['id']);this['_revisionViewer']['compare'](_0x2cc1d5,_0x599266);}['_handleRevisionSetName'](_0x8ee623,_0x275d3d){this['_revisionsRepository']['getRevision'](_0x275d3d['id'])['setName'](_0x275d3d['name']);}['_handleDiffChange'](_0x5347d0,_0x3cc152,_0x5e78ba){const _0x4e1423=this['_revisionsRepository']['getRevisionsInDiff'](_0x5e78ba);_0x4e1423['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x4e1423),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x4e1423[0x0]));}['_createRevisionActions'](){const _0x50712c=this['editor'],_0x1f0681=w['availableRevisionActions'],_0x294765=_0x50712c['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x294765['length'])return _0x294765['map'](_0x44826b=>{const _0x48f6fe='string'==typeof _0x44826b?Object['assign']({},_0x1f0681[_0x44826b]):_0x44826b;return _0x48f6fe['action']=_0x48f6fe['action']['bind'](this,_0x50712c),_0x48f6fe['isVisible']&&(_0x48f6fe['isVisible']=_0x48f6fe['isVisible']['bind'](this,_0x50712c)),_0x48f6fe;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x314477},_0x36ad6b)=>{const _0x22dad2=_0x314477['get'](d),_0x1e0217=_0x22dad2['repository'];let _0x3f8c30=_0x22dad2['diff']['newRevisionId'],_0x40af07=_0x36ad6b['id'];_0x1e0217['getIndex'](_0x3f8c30)>_0x1e0217['getIndex'](_0x40af07)&&([_0x3f8c30,_0x40af07]=[_0x40af07,_0x3f8c30]),_0x22dad2['compare'](_0x3f8c30,_0x40af07);},'isVisible':({plugins:_0x25b993},_0x11768b)=>{const _0x5df1b9=_0x25b993['get'](d);return!(_0x5df1b9['repository']['getRevisionsInDiff'](_0x5df1b9['diff'])['length']>0x2)&&!_0x11768b['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x2159a3,{id:_0xb14632})=>{_0x2159a3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xb14632);},'isVisible':({plugins:_0x40e32e},_0x17daf8)=>!!_0x40e32e['get'](d)['repository']['getLaterVisibleRevision'](_0x17daf8['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0xc57708},{id:_0x6a5d6d,revisionNameView:_0x5942bf})=>{const _0xac6b03=_0xc57708['get'](d),_0x46239d=_0xac6b03['repository']['getEarlierVisibleRevision'](_0x6a5d6d);_0xac6b03['compare'](_0x6a5d6d,_0x46239d),_0x5942bf['focus'](),_0x5942bf['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1a90cd,_0x4b59d1){super(_0x1a90cd),this['_view']=_0x4b59d1,this['_toolbarConfig']=ot(_0x1a90cd['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x345e70){const _0x22a301=this['editor'],_0x235909=this['view'],_0x34303b=_0x22a301['editing']['view'],_0x4caa8f=_0x235909['editable'],_0x5a494c=_0x34303b['document']['getRoot']();_0x4caa8f['name']=_0x5a494c['rootName'],_0x235909['render']();const _0x218a92=_0x4caa8f['element'];this['setEditableElement'](_0x4caa8f['name'],_0x218a92),_0x235909['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x34303b['attachDomRoot'](_0x218a92),this['_elementReplacer']['replace'](_0x345e70,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x4232eb=this['view'],_0x424f95=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x424f95['detachDomRoot'](_0x4232eb['editable']['name']),_0x4232eb['destroy']();}['_initToolbar'](){const _0x36435d=this['view'];_0x36435d['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x36435d['stickyPanel']['limiterElement']=_0x36435d['element'],_0x36435d['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x5359eb})=>_0x5359eb),_0x36435d['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x36435d['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x5d6a0c,_0x52f7e7,_0x11c985={}){super(_0x5d6a0c),this['stickyPanel']=new ut(_0x5d6a0c),this['toolbar']=new lt(_0x5d6a0c,{'shouldGroupWhenFull':_0x11c985['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x5d6a0c,_0x52f7e7);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class R extends/* #__PURE__ -- @preserve */
29
- it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x23fe02,_0x3d06bb){super(_0x3d06bb),this['sourceElement']=_0x23fe02,this['model']['document']['createRoot']();const _0x427fa9=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x427fa9);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x1eee88,_0x26a573){const _0x3ccbc3=new this(_0x1eee88,_0x26a573);return await _0x3ccbc3['initPlugins'](),await _0x3ccbc3['ui']['init'](_0x1eee88),await _0x3ccbc3['data']['init'](_0x3ccbc3['config']['get']('initialData')||''),_0x3ccbc3['fire']('ready'),_0x3ccbc3;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x47f245{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x58d0d0){function _0x1780eb(_0x3fb292){return _0x3fb292['map'](_0x4f0d11=>String['fromCharCode'](_0x4f0d11))['join']('');}super(_0x58d0d0),this['result']='end',_0x58d0d0[_0x1780eb([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1780eb([0x76,0x69,0x65,0x77])][_0x1780eb([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1780eb([0x61,0x75,0x74,0x6f]),_0x58d0d0[_0x1780eb([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1780eb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1780eb([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1780eb([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1780eb([0x6f,0x6b])});}}class k extends _0x47f245{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x30d28f){if(super(_0x30d28f),!this['editor']['config']['get']('revisionHistory'))throw new _0x2e39c8('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x3f1eb8=>this['_showRevisionViewer']({..._0x3f1eb8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3826c7=>this['_closeRevisionViewer'](_0x3826c7)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4d8bbb=>this['_restoreRevision'](_0x4d8bbb)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x38d324){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x38d324;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xbce24c){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xbce24c);}['getRevision'](_0x3cc48c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x3cc48c);}['getRevisions'](_0x16e213){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x16e213||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x5162b5=this['editor'],_0xead1de=_0x31b616(_0x5162b5,p),_0x725478=_0x5162b5['plugins']['get']('RevisionTracker'),_0x2db6d5=_0x5162b5['plugins']['get']('Users')['users'];return _0xead1de['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0xead1de['lazyRoots'],(_0xead1de['plugins']['push'](Rt,d,g,class extends _0x47f245{static get['requires'](){return[d,'Users'];}['init'](){const _0x2fee2f=this['editor']['plugins']['get']('Users');for(const _0x41b577 of _0x2db6d5)_0x41b577['isAnonymous']||_0x2fee2f['getUser'](_0x41b577['id'])||_0x2fee2f['addUser'](_0x41b577);const _0x12e98f=_0x725478['repository']['getRevisions']();let _0x63d771=null;const _0x5b056c=this['editor']['plugins']['get']('RevisionViewer');_0x5b056c['adapter']=_0x725478['adapter'],_0x5b056c['bind']('isEnabled')['to'](_0x725478),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x5162b5,'isReadOnly',_0x109e73=>!_0x109e73);for(const _0x381f28 of _0x12e98f){const _0x19d30f=null===_0x381f28['creator'];if(_0x19d30f&&_0x381f28['toVersion']===_0x381f28['fromVersion'])continue;const _0x34c71f=_0x381f28['toJSON']();_0x5b056c['addRevisionData'](_0x34c71f,(_0x31a8ba,_0x27b429,_0x2f6f03)=>{if(_0x19d30f){if(_0x63d771)_0x63d771['_update'](_0x31a8ba,_0x27b429);else{if(!_0x27b429){const _0x321c55=_0x2f6f03['toJSON']();_0x321c55['id']=_0x4813fb(),_0x725478['saveRevision'](_0x321c55,_0x2f6f03['toVersion'])['then'](_0x367c1b=>{_0x63d771=_0x367c1b;});}}}else _0x381f28['_update'](_0x31a8ba,_0x27b429);});}}},w),_0xead1de);}['_enhanceShowRevisionViewerCallback'](){const _0x2266fa=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x23a788=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4f611c=this['editor']['plugins']['get']('Autosave');await _0x4f611c['save']();}else await _0x23a788['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x4c7203=this['editor']['plugins']['get']('Dialog');_0x4c7203['isOpen']&&_0x4c7203['hide']();}const _0x4060fd=this['_getRevisionViewerEditorConfig']();return _0x2266fa(_0x4060fd)['then'](_0x5ea034=>{return(this['_viewerEditor']=_0x5ea034,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x5ea034;})['catch'](_0x1114e5=>(console['error'](_0x1114e5),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5cb817=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'](),_0x5cb817(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x556447=this['editor']['plugins']['get']('Annotations');_0x556447['refreshVisibility'](),_0x556447['refreshPositioning']();}})));}['_showRevisionViewer'](_0x225ca0){const _0x49d9ad=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x5f1b0c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0xa20091=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0xa20091,_0x225ca0)['then'](_0x4aea37=>(_0x5f1b0c['style']['display']='block',_0x49d9ad['style']['display']='none',_0x4aea37));}['_closeRevisionViewer'](_0x1e19c3){const _0x5c24ce=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x5c24ce['style']['display']='',_0x1e19c3['destroy']();}async['_restoreRevision'](_0x76425d){const _0x53db91=this['editor'],_0x5af94d=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5e8127=_0x53db91['plugins']['get']('RevisionTracker'),_0x1827e0=_0x5af94d['repository']['getRevision'](_0x76425d);let _0x429dc2,_0x2a5d5d,_0x14ddf0;try{_0x429dc2=await _0x5af94d['getRevisionData'](_0x1827e0),_0x2a5d5d=await _0x5af94d['getRevisionRootsAttributes'](_0x1827e0);}catch(_0x47e45b){return void console['error'](_0x47e45b);}_0x53db91['model']['change'](_0x2ebd3f=>{for(const _0x567594 of Array['from'](_0x53db91['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x2ebd3f['removeMarker'](_0x567594);}),_0x5af94d['isReady']=!0x1,_0x53db91['model']['enqueueChange'](_0xf27f15=>{_0xf27f15['setSelection'](null),_0xf27f15['removeSelectionAttribute'](_0x53db91['model']['document']['selection']['getAttributeKeys']());const _0x5637a7=Object['keys'](_0x429dc2);for(const _0x1813a6 of _0x53db91['model']['document']['roots'])'$graveyard'!=_0x1813a6['rootName']&&_0x1813a6['isAttached']()&&!_0x5637a7['includes'](_0x1813a6['rootName'])&&_0xf27f15['detachRoot'](_0x1813a6);for(const _0x344539 of _0x5637a7){let _0x4f4cdb=_0x53db91['model']['document']['getRoot'](_0x344539);_0x4f4cdb&&_0x4f4cdb['isAttached']()||(_0x4f4cdb=_0xf27f15['addRoot'](_0x344539));const _0xda958=_0x2a5d5d[_0x344539],_0x4e1a99=Object['keys'](_0xda958),_0x1b6fd2=_0x429dc2[_0x344539];for(const _0x2cbf16 of _0x4f4cdb['getAttributeKeys']())_0x4e1a99['includes'](_0x2cbf16)||_0xf27f15['removeAttribute'](_0x2cbf16,_0x4f4cdb);for(const _0x1a2067 of _0x4e1a99)_0xf27f15['setAttribute'](_0x1a2067,_0x2a5d5d[_0x344539][_0x1a2067],_0x4f4cdb);_0xf27f15['remove'](_0xf27f15['createRangeIn'](_0x4f4cdb)),_0xf27f15['insert'](_0x53db91['data']['parse'](_0x1b6fd2,_0x4f4cdb),_0x4f4cdb,0x0);}});const _0xe35800=m(_0x53db91['locale'],'Restored');if(_0x1827e0['name'])_0x14ddf0=-0x1==_0x1827e0['name']['indexOf'](_0xe35800)?_0xe35800+':\x20'+_0x1827e0['name']:_0x1827e0['name'];else _0x14ddf0=_0xe35800+':\x20'+(_0x1827e0['createdAt']['toLocaleDateString'](_0x53db91['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1827e0['createdAt']['toLocaleTimeString'](_0x53db91['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5e8127['saveRevision']({'name':_0x14ddf0}),_0x5af94d['isReady']=!0x0,_0x53db91['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,le as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
28
+ bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x6265da){super(_0x6265da),this['_revisionViewer']=_0x6265da['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0xdff101=this['_revisionsRepository']['_revisions'],_0x4641cc=this['_createRevisionActions'](),_0x46861d=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0xdff101,_0x4641cc,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',(_0x1e958e,_0x2cf48b)=>{_0x2cf48b['revisionViews']['on']('add',(_0x1041da,_0x593c3b)=>{_0x593c3b['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)),_0x46861d['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x5e7627=this['_revisionsRepository']['getRevision'](0x0);if(_0x5e7627){const _0x46b957=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5e7627['id']);this['_revisionViewer']['compare'](_0x5e7627,_0x46b957);}}['_handleRevisionSelected'](_0x4ae85b,_0x3c72d){const _0x401ae9=this['_revisionsRepository']['getRevision'](_0x3c72d['id']),_0x274804=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x401ae9['id']);this['_revisionViewer']['compare'](_0x401ae9,_0x274804);}['_handleRevisionSetName'](_0x3becde,_0x3f94f8){this['_revisionsRepository']['getRevision'](_0x3f94f8['id'])['setName'](_0x3f94f8['name']);}['_handleDiffChange'](_0x85637b,_0x25dee4,_0x6211fb){const _0x3173a5=this['_revisionsRepository']['getRevisionsInDiff'](_0x6211fb);_0x3173a5['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3173a5),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3173a5[0x0]));}['_createRevisionActions'](){const _0x43e068=this['editor'],_0x4c6a65=w['availableRevisionActions'],_0x378a38=_0x43e068['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x378a38['length'])return _0x378a38['map'](_0x43cc7d=>{const _0xccd7d='string'==typeof _0x43cc7d?Object['assign']({},_0x4c6a65[_0x43cc7d]):_0x43cc7d;return _0xccd7d['action']=_0xccd7d['action']['bind'](this,_0x43e068),_0xccd7d['isVisible']&&(_0xccd7d['isVisible']=_0xccd7d['isVisible']['bind'](this,_0x43e068)),_0xccd7d;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x1c4960},_0x3b5cfc)=>{const _0xdbcef1=_0x1c4960['get'](d),_0x493bfc=_0xdbcef1['repository'];let _0x5848f0=_0xdbcef1['diff']['newRevisionId'],_0x1b81e3=_0x3b5cfc['id'];_0x493bfc['getIndex'](_0x5848f0)>_0x493bfc['getIndex'](_0x1b81e3)&&([_0x5848f0,_0x1b81e3]=[_0x1b81e3,_0x5848f0]),_0xdbcef1['compare'](_0x5848f0,_0x1b81e3);},'isVisible':({plugins:_0x8a388e},_0x26aa8a)=>{const _0x2dbf2f=_0x8a388e['get'](d);return!(_0x2dbf2f['repository']['getRevisionsInDiff'](_0x2dbf2f['diff'])['length']>0x2)&&!_0x26aa8a['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x3a76e1,{id:_0x5c15f8})=>{_0x3a76e1['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5c15f8);},'isVisible':({plugins:_0x210a9e},_0x760ca2)=>!!_0x210a9e['get'](d)['repository']['getLaterVisibleRevision'](_0x760ca2['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4e576e},{id:_0x2653d1,revisionNameView:_0x12533b})=>{const _0x208b96=_0x4e576e['get'](d),_0x1898f9=_0x208b96['repository']['getEarlierVisibleRevision'](_0x2653d1);_0x208b96['compare'](_0x2653d1,_0x1898f9),_0x12533b['focus'](),_0x12533b['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x38ab8c,_0x478838){super(_0x38ab8c),this['_view']=_0x478838,this['_toolbarConfig']=ot(_0x38ab8c['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x331ed5){const _0x4ce0e6=this['editor'],_0x547cc2=this['view'],_0x17e082=_0x4ce0e6['editing']['view'],_0x1cd88b=_0x547cc2['editable'],_0x1adade=_0x17e082['document']['getRoot']();_0x1cd88b['name']=_0x1adade['rootName'],_0x547cc2['render']();const _0x3233c8=_0x1cd88b['element'];this['setEditableElement'](_0x1cd88b['name'],_0x3233c8),_0x547cc2['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x17e082['attachDomRoot'](_0x3233c8),this['_elementReplacer']['replace'](_0x331ed5,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x44a482=this['view'],_0x27851a=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x27851a['detachDomRoot'](_0x44a482['editable']['name']),_0x44a482['destroy']();}['_initToolbar'](){const _0x2b1956=this['view'];_0x2b1956['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2b1956['stickyPanel']['limiterElement']=_0x2b1956['element'],_0x2b1956['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x2a9925})=>_0x2a9925),_0x2b1956['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2b1956['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x9bb564,_0x19b4b1,_0x3fe8e2={}){super(_0x9bb564),this['stickyPanel']=new ut(_0x9bb564),this['toolbar']=new lt(_0x9bb564,{'shouldGroupWhenFull':_0x3fe8e2['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x9bb564,_0x19b4b1);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class R extends/* #__PURE__ -- @preserve */
29
+ it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3ddafc,_0x215c93){super(_0x215c93),this['sourceElement']=_0x3ddafc,this['model']['document']['createRoot']();const _0x1e1faf=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x1e1faf);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x5d96c9,_0x32ff64){const _0x55018a=new this(_0x5d96c9,_0x32ff64);return await _0x55018a['initPlugins'](),await _0x55018a['ui']['init'](_0x5d96c9),await _0x55018a['data']['init'](_0x55018a['config']['get']('initialData')||''),_0x55018a['fire']('ready'),_0x55018a;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x23fe3b{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x336e0f){function _0x2b7098(_0x1a6285){return _0x1a6285['map'](_0x35e09c=>String['fromCharCode'](_0x35e09c))['join']('');}super(_0x336e0f),this['result']='end',_0x336e0f[_0x2b7098([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2b7098([0x76,0x69,0x65,0x77])][_0x2b7098([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2b7098([0x61,0x75,0x74,0x6f]),_0x336e0f[_0x2b7098([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x2b7098([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2b7098([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x2b7098([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x2b7098([0x6f,0x6b])});}}class k extends _0x23fe3b{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x14e75d){if(super(_0x14e75d),!this['editor']['config']['get']('revisionHistory'))throw new _0x44dbd9('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x13fe5e=>this['_showRevisionViewer']({..._0x13fe5e,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x44767c=>this['_closeRevisionViewer'](_0x44767c)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x1f83de=>this['_restoreRevision'](_0x1f83de)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x5e3bb3){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x5e3bb3;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x2b6570){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x2b6570);}['getRevision'](_0x4d60ad){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x4d60ad);}['getRevisions'](_0x42c31d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x42c31d||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x1c8626=this['editor'],_0x5806ae=_0x4cc66b(_0x1c8626,p),_0x157376=_0x1c8626['plugins']['get']('RevisionTracker'),_0x1a0573=_0x1c8626['plugins']['get']('Users')['users'];return _0x5806ae['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5806ae['lazyRoots'],(_0x5806ae['plugins']['push'](Rt,d,g,class extends _0x23fe3b{static get['requires'](){return[d,'Users'];}['init'](){const _0x353d2c=this['editor']['plugins']['get']('Users');for(const _0x550658 of _0x1a0573)_0x550658['isAnonymous']||_0x353d2c['getUser'](_0x550658['id'])||_0x353d2c['addUser'](_0x550658);const _0x567a94=_0x157376['repository']['getRevisions']();let _0x2b70c9=null;const _0x32b81e=this['editor']['plugins']['get']('RevisionViewer');_0x32b81e['adapter']=_0x157376['adapter'],_0x32b81e['bind']('isEnabled')['to'](_0x157376),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x1c8626,'isReadOnly',_0x599633=>!_0x599633);for(const _0x21755c of _0x567a94){const _0x226da2=null===_0x21755c['creator'];if(_0x226da2&&_0x21755c['toVersion']===_0x21755c['fromVersion'])continue;const _0x1b366a=_0x21755c['toJSON']();_0x32b81e['addRevisionData'](_0x1b366a,(_0x836fc1,_0x56268f,_0x35e30c)=>{if(_0x226da2){if(_0x2b70c9)_0x2b70c9['_update'](_0x836fc1,_0x56268f);else{if(!_0x56268f){const _0x144e87=_0x35e30c['toJSON']();_0x144e87['id']=_0x32ae7e(),_0x157376['saveRevision'](_0x144e87,_0x35e30c['toVersion'])['then'](_0x185c4c=>{_0x2b70c9=_0x185c4c;});}}}else _0x21755c['_update'](_0x836fc1,_0x56268f);});}}},w),_0x5806ae);}['_enhanceShowRevisionViewerCallback'](){const _0x26bd5c=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x751cb=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x436a68=this['editor']['plugins']['get']('Autosave');await _0x436a68['save']();}else await _0x751cb['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x401bf2=this['editor']['plugins']['get']('Dialog');_0x401bf2['isOpen']&&_0x401bf2['hide']();}const _0x4ea0ce=this['_getRevisionViewerEditorConfig']();return _0x26bd5c(_0x4ea0ce)['then'](_0x36eef7=>{return(this['_viewerEditor']=_0x36eef7,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x36eef7;})['catch'](_0xd559d7=>(console['error'](_0xd559d7),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x326c83=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'](),_0x326c83(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1765f4=this['editor']['plugins']['get']('Annotations');_0x1765f4['refreshVisibility'](),_0x1765f4['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5c40dd){const _0x26e053=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x22e01f=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x4c5f71=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x4c5f71,_0x5c40dd)['then'](_0x1a1669=>(_0x22e01f['style']['display']='block',_0x26e053['style']['display']='none',_0x1a1669));}['_closeRevisionViewer'](_0x165cf2){const _0xc1ad4a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xc1ad4a['style']['display']='',_0x165cf2['destroy']();}async['_restoreRevision'](_0x3ae974){const _0x45059a=this['editor'],_0x45aaf2=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x39cfc3=_0x45059a['plugins']['get']('RevisionTracker'),_0x204b81=_0x45aaf2['repository']['getRevision'](_0x3ae974);let _0x4fa4b1,_0x58e227,_0x175ae2;try{_0x4fa4b1=await _0x45aaf2['getRevisionData'](_0x204b81),_0x58e227=await _0x45aaf2['getRevisionRootsAttributes'](_0x204b81);}catch(_0x1ab3a1){return void console['error'](_0x1ab3a1);}_0x45059a['model']['change'](_0x26f926=>{for(const _0x5ebe8b of Array['from'](_0x45059a['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x26f926['removeMarker'](_0x5ebe8b);}),_0x45aaf2['isReady']=!0x1,_0x45059a['model']['enqueueChange'](_0x4f596e=>{_0x4f596e['setSelection'](null),_0x4f596e['removeSelectionAttribute'](_0x45059a['model']['document']['selection']['getAttributeKeys']());const _0x5db6b3=Object['keys'](_0x4fa4b1);for(const _0x109070 of _0x45059a['model']['document']['roots'])'$graveyard'!=_0x109070['rootName']&&_0x109070['isAttached']()&&!_0x5db6b3['includes'](_0x109070['rootName'])&&_0x4f596e['detachRoot'](_0x109070);for(const _0x5e07df of _0x5db6b3){let _0x460baa=_0x45059a['model']['document']['getRoot'](_0x5e07df);_0x460baa&&_0x460baa['isAttached']()||(_0x460baa=_0x4f596e['addRoot'](_0x5e07df));const _0x14969d=_0x58e227[_0x5e07df],_0x1186b4=Object['keys'](_0x14969d),_0x46d0b6=_0x4fa4b1[_0x5e07df];for(const _0x4423bc of _0x460baa['getAttributeKeys']())_0x1186b4['includes'](_0x4423bc)||_0x4f596e['removeAttribute'](_0x4423bc,_0x460baa);for(const _0x281436 of _0x1186b4)_0x4f596e['setAttribute'](_0x281436,_0x58e227[_0x5e07df][_0x281436],_0x460baa);_0x4f596e['remove'](_0x4f596e['createRangeIn'](_0x460baa)),_0x4f596e['insert'](_0x45059a['data']['parse'](_0x46d0b6,_0x460baa),_0x460baa,0x0);}});const _0x4a93b5=m(_0x45059a['locale'],'Restored');if(_0x204b81['name'])_0x175ae2=-0x1==_0x204b81['name']['indexOf'](_0x4a93b5)?_0x4a93b5+':\x20'+_0x204b81['name']:_0x204b81['name'];else _0x175ae2=_0x4a93b5+':\x20'+(_0x204b81['createdAt']['toLocaleDateString'](_0x45059a['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x204b81['createdAt']['toLocaleTimeString'](_0x45059a['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x39cfc3['saveRevision']({'name':_0x175ae2}),_0x45aaf2['isReady']=!0x0,_0x45059a['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};