@ckeditor/ckeditor5-revision-history 44.0.0-alpha.7 → 44.0.0-alpha.9

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 (179) hide show
  1. package/LICENSE.md +7 -7
  2. package/README.md +14 -11
  3. package/build/revision-history.js +1 -1
  4. package/dist/index.js +6 -6
  5. package/dist/translations/af.js +1 -1
  6. package/dist/translations/af.umd.js +1 -1
  7. package/dist/translations/ar.js +1 -1
  8. package/dist/translations/ar.umd.js +1 -1
  9. package/dist/translations/ast.js +1 -1
  10. package/dist/translations/ast.umd.js +1 -1
  11. package/dist/translations/az.js +1 -1
  12. package/dist/translations/az.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +8 -8
  150. package/src/changeitem.js +2 -2
  151. package/src/editor/revisionviewereditor.js +2 -2
  152. package/src/editor/revisionviewereditorui.js +1 -1
  153. package/src/editor/revisionviewereditoruiview.js +1 -1
  154. package/src/index.js +1 -1
  155. package/src/revision.js +2 -2
  156. package/src/revisiondiff.js +1 -1
  157. package/src/revisionhistory.js +1 -1
  158. package/src/revisionsrepository.js +1 -1
  159. package/src/revisiontracker.js +1 -1
  160. package/src/revisionviewer.js +1 -1
  161. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  162. package/src/ui/revision/revisionauthorview.js +1 -1
  163. package/src/ui/revision/revisionnameview.js +1 -1
  164. package/src/ui/revision/revisionview.js +2 -2
  165. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  166. package/src/ui/revision/subrevisionview.js +1 -1
  167. package/src/ui/revision/utils.js +1 -1
  168. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  169. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  170. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  172. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  173. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  174. package/src/ui/revisionssidebar/utils.js +1 -1
  175. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  176. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  177. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  178. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  179. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x5c7d88,uid as _0x4dce4d,Collection as _0x2ad968,logWarning as _0x482cd7,FocusTracker as _0x5cf0e0,KeystrokeHandler as _0x3a2814,scrollViewportToShowTarget as _0x277b74,ResizeObserver as pt,ElementReplacer as ct,CKEditorError as _0x2c83c4}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x295472,set as _0x8cbf8d,unset as _0x222f53,isEqual as _0x23c23a}from'lodash-es';import{Plugin as _0x24aabd,PendingActions as _0x23b549,icons as _0x888a61,Command as _0xf66950,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x4943c5,getMarkerDomElement as _0x218286,ConfirmMixin as _0x33105c,sanitizeEditorConfig as _0x3f5003}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x4833c1,ViewText as _0xd57083,ViewElement as _0x2c4196,Element as ft,Range as vt,Position as gt,DocumentFragment as wt,ViewContainerElement as _0x23c6b9,ViewAttributeElement as _0x3e4e99,ViewEmptyElement as _0x46de0e,ViewRawElement as _0xcf47a2,ViewUIElement as _0x131e84,Text as _t}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x2c43c9,injectCssTransitionDisabler as ts,submitHandler as _0x5b1924,LabeledFieldView as at,createLabeledInputText as _0x4fabfa,createDropdown as _0x20789c,ListView as te,ListItemView as _0x4e494e,ButtonView as _0x15a92a,MenuBarMenuView as _0x5320cf,MenuBarMenuListView as _0xae8b9,MenuBarMenuListItemView as _0x414113,MenuBarMenuListItemButtonView as _0x1ea6c3,ContextualBalloon as _0x276f8f,ToolbarSeparatorView as _0x372320,IconView as _0x544954,addListToDropdown as _0x3d32c0,ViewModel as to,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x283079}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
- _0x5c7d88(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x419778){super(),this['id']=_0x419778['id']||_0x4dce4d(),this['creator']=_0x419778['creator']||null,this['authors']=_0x419778['authors']||[],this['diffData']=_0x419778['diffData']||null,this['toVersion']=_0x419778['toVersion']||0x0,this['fromVersion']=_0x419778['fromVersion']||0x0,this['set']('name',_0x419778['name']||''),this['set']('createdAt',_0x419778['createdAt']||new Date()),this['set']('attributes',_0x419778['attributes']||{});}['setName'](_0x1e9d96){this['_update']({'name':_0x1e9d96});}['setAttribute'](_0x4c8012,_0x144a76){const _0x33fd19=_0x295472(this['attributes']);_0x8cbf8d(_0x33fd19,_0x4c8012,_0x144a76),this['_update']({'attributes':_0x33fd19});}['removeAttribute'](_0x524985){const _0x373fb5=_0x295472(this['attributes']);_0x222f53(_0x373fb5,_0x524985),this['_update']({'attributes':_0x373fb5});}['_update'](_0x50adb9,_0x4a7be8=!0x1){let _0x54e226=!0x1;const _0x40973c={'id':this['id']},_0x4f02ce=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xc9892f of _0x4f02ce){const _0x38850b=_0x50adb9[_0xc9892f];void 0x0!==_0x38850b&&_0x38850b!==this[_0xc9892f]&&(this[_0xc9892f]=_0x38850b,_0x40973c[_0xc9892f]=_0x38850b,_0x54e226=!0x0);}_0x54e226&&(_0x40973c['authors']&&(_0x40973c['authorsIds']=_0x40973c['authors']['map'](_0x1ea1a2=>_0x1ea1a2['id']),delete _0x40973c['authors']),this['fire']('_update',_0x40973c,_0x4a7be8));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x19791a=>_0x19791a['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x24aabd{['_revisions'];static get['requires'](){return[_0x4943c5];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xa1d20c){super(_0xa1d20c),this['_revisions']=new _0x2ad968();}['afterInit'](){!async function(_0x5340a2){const _0x464530=_0x3ad719([0x36,0x69,0x38,0x32,0x59,0x67,0x51,0x41,0x47,0x31,0x70,0x6a,0x35,0x48,0x6d,0x37,0x57,0x7a,0x50,0x76,0x44,0x5a,0x63,0x45,0x6b,0x79,0x73,0x33,0x4e,0x72,0x46,0x64,0x55,0x39,0x6f,0x77,0x30,0x62,0x34,0x61,0x4d,0x4b,0x6c,0x56,0x58,0x4f,0x4c,0x49,0x65,0x68,0x75,0x43,0x53,0x6e,0x66,0x71,0x4a,0x52,0x78,0x74,0x54,0x42]),_0x3bb680=0xeb829,_0x2e7537=0x7d72a7d8,_0x7c16ea=0x7d75ffc8^_0x2e7537,_0x53780f=window[_0x3ad719([0x44,0x61,0x74,0x65])][_0x3ad719([0x6e,0x6f,0x77])](),_0x9e3d64=_0x5340a2[_0x3ad719([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x3a878b=new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x546cc6=>{_0x9e3d64[_0x3ad719([0x6f,0x6e,0x63,0x65])](_0x3ad719([0x72,0x65,0x61,0x64,0x79]),_0x546cc6);}),_0x1c9644={[_0x3ad719([0x6b,0x74,0x79])]:_0x3ad719([0x45,0x43]),[_0x3ad719([0x75,0x73,0x65])]:_0x3ad719([0x73,0x69,0x67]),[_0x3ad719([0x63,0x72,0x76])]:_0x3ad719([0x50,0x2d,0x32,0x35,0x36]),[_0x3ad719([0x78])]:_0x3ad719([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]),[_0x3ad719([0x79])]:_0x3ad719([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]),[_0x3ad719([0x61,0x6c,0x67])]:_0x3ad719([0x45,0x53,0x32,0x35,0x36])},_0x3c14c5=_0x9e3d64[_0x3ad719([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3ad719([0x67,0x65,0x74])](_0x3ad719([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4cfcf4(){let _0x45d878,_0x4850af=null,_0x23882f=null;try{if(_0x3c14c5==_0x3ad719([0x47,0x50,0x4c]))return _0x3ad719([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x45d878=_0x36fe8e(),!_0x45d878)return _0x3ad719([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x45d878[_0x3ad719([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x23882f=_0x914192(_0x45d878[_0x3ad719([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x45d878[_0x3ad719([0x6a,0x74,0x69])])),await _0x3e43f8()?_0x194bb2()?_0x124c20()?_0x3ad719([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x113eae()?(_0x45d878[_0x3ad719([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ad719([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4850af=_0x3b4a67(_0x3ad719([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x45d878[_0x3ad719([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ad719([0x74,0x72,0x69,0x61,0x6c])&&(_0x4850af=_0x3b4a67(_0x3ad719([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x45d878[_0x3ad719([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ad719([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x4850af=_0x3b4a67(_0x3ad719([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x64c4a8()):_0x3ad719([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3ad719([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3ad719([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x27fe0e){return _0x3ad719([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x124c20(){const _0x333b1a=[_0x3ad719([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3ad719([0x74,0x72,0x69,0x61,0x6c])][_0x3ad719([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x45d878[_0x3ad719([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x53780f/0x3e8:0xe10*_0x7c16ea;return _0x45d878[_0x3ad719([0x65,0x78,0x70])]<_0x333b1a;}function _0x194bb2(){const _0x5943e8=_0x45d878[_0x3ad719([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x5943e8&&(!!_0x5943e8[_0x3ad719([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ad719([0x2a]))||(!!_0x5943e8[_0x3ad719([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ad719([0x52,0x48]))||!(!_0x5943e8[_0x3ad719([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ad719([0x52,0x52,0x48]))||!_0x90a7f3())));}function _0x113eae(){const _0x495904=_0x45d878[_0x3ad719([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x495904||0x0==_0x495904[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3ae30a}=new URL(window[_0x3ad719([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x495904[_0x3ad719([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ae30a))return!0x0;const _0x247f55=_0x3ae30a[_0x3ad719([0x73,0x70,0x6c,0x69,0x74])](_0x3ad719([0x2e]));return _0x495904[_0x3ad719([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5d884e=>_0x5d884e[_0x3ad719([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ad719([0x2a])))[_0x3ad719([0x6d,0x61,0x70])](_0x271f71=>_0x271f71[_0x3ad719([0x73,0x70,0x6c,0x69,0x74])](_0x3ad719([0x2e])))[_0x3ad719([0x73,0x6f,0x6d,0x65])](_0x36fa03=>_0x247f55[_0x3ad719([0x65,0x76,0x65,0x72,0x79])]((_0x1957cb,_0x1ffe7f)=>_0x36fa03[_0x1ffe7f]===_0x1957cb||_0x36fa03[_0x1ffe7f]===_0x3ad719([0x2a])));}function _0x64c4a8(){return _0x4850af&&_0x23882f?new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xf31d60,_0x2f3b48)=>{_0x4850af[_0x3ad719([0x74,0x68,0x65,0x6e])](_0xf31d60,_0x2f3b48),_0x23882f[_0x3ad719([0x74,0x68,0x65,0x6e])](_0xa9e8e7=>{_0xa9e8e7!=_0x3ad719([0x56,0x61,0x6c,0x69,0x64])&&_0xf31d60(_0xa9e8e7);},_0x2f3b48);}):_0x4850af||_0x23882f||_0x3ad719([0x56,0x61,0x6c,0x69,0x64]);}}function _0x914192(_0x28296f,_0x171217){return new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x46b17a=>{if(_0x82c58f())return _0x46b17a(_0x3ad719([0x56,0x61,0x6c,0x69,0x64]));_0x3c0545(),_0x9e3d64[_0x3ad719([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3ad719([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x27bb41=!0x1;const _0x4ea5ca=_0x4dce4d();function _0x54eeaf(_0xde3533){return!!_0xde3533&&(typeof _0xde3533===_0x3ad719([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0xde3533===_0x3ad719([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0xde3533[_0x3ad719([0x74,0x68,0x65,0x6e])]===_0x3ad719([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0xde3533[_0x3ad719([0x63,0x61,0x74,0x63,0x68])]===_0x3ad719([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4c9605(_0x3ff4b8){_0x2c73fa(_0x3ff4b8)[_0x3ad719([0x74,0x68,0x65,0x6e])](_0x1dae87=>{if(!_0x1dae87||_0x1dae87[_0x3ad719([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3ad719([0x6f,0x6b]))return _0x3ad719([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3173fe(_0xc42e86(_0x4ea5ca+_0x171217))!=_0x1dae87[_0x3ad719([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3ad719([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3ad719([0x56,0x61,0x6c,0x69,0x64]);})[_0x3ad719([0x74,0x68,0x65,0x6e])](_0x44c666=>(_0x3b0c74(),_0x44c666),()=>{const _0x4d334b=_0x5e1f60();return null==_0x4d334b?(_0x3b0c74(),_0x3ad719([0x56,0x61,0x6c,0x69,0x64])):_0x3ad719(_0x53780f-_0x4d334b>(0x597e23d8^_0x2e7537)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3ad719([0x74,0x68,0x65,0x6e])](_0x46b17a)[_0x3ad719([0x63,0x61,0x74,0x63,0x68])](()=>{_0x46b17a(_0x3ad719([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x47a8e0=0x7d444958^_0x2e7537;function _0x3b0c74(){const _0x4ad696=_0x3ad719([0x6c,0x6c,0x63,0x74,0x2d])+_0x3173fe(_0xc42e86(_0x28296f)),_0x29b374=_0x343095(_0x3173fe(window[_0x3ad719([0x4d,0x61,0x74,0x68])][_0x3ad719([0x63,0x65,0x69,0x6c])](_0x53780f/_0x47a8e0)));window[_0x3ad719([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3ad719([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4ad696,_0x29b374);}function _0x5e1f60(){const _0x461d7e=_0x3ad719([0x6c,0x6c,0x63,0x74,0x2d])+_0x3173fe(_0xc42e86(_0x28296f)),_0x59d759=window[_0x3ad719([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3ad719([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x461d7e);return _0x59d759?window[_0x3ad719([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x343095(_0x59d759),0x10)*_0x47a8e0:null;}function _0x2c73fa(_0x310102){return new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x50619e,_0x263214)=>{_0x310102[_0x3ad719([0x74,0x68,0x65,0x6e])](_0x50619e,_0x263214),window[_0x3ad719([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x263214,0x7d737318^_0x2e7537);});}}_0x9e3d64[_0x3ad719([0x6f,0x6e])](_0x3ad719([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x467090,_0xd0ec25)=>{if(_0xd0ec25[0x0]!=_0x28296f)return _0x46b17a(_0x3ad719([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xd0ec25[0x1]={..._0xd0ec25[0x1],[_0x3ad719([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4ea5ca};},{[_0x3ad719([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3ad719([0x68,0x69,0x67,0x68])}),_0x9e3d64[_0x3ad719([0x6f,0x6e])](_0x3ad719([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x19e3b7=>{_0x54eeaf(_0x19e3b7[_0x3ad719([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x27bb41=!0x0,_0x4c9605(_0x19e3b7[_0x3ad719([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3ad719([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3ad719([0x6c,0x6f,0x77])}),_0x3a878b[_0x3ad719([0x74,0x68,0x65,0x6e])](()=>{_0x27bb41||_0x46b17a(_0x3ad719([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x82c58f(){return _0x9e3d64[_0x3ad719([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ad719([0x76,0x69,0x65,0x77])][_0x3ad719([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3ad719([0x61,0x75,0x74,0x6f]);}function _0x3c0545(){_0x9e3d64[_0x3ad719([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ad719([0x76,0x69,0x65,0x77])][_0x3ad719([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3ad719([0x61,0x75,0x74,0x6f]);}}function _0x3b4a67(_0x26b156){const _0x4fa974=[new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x513be9=>setTimeout(_0x513be9,0x7d7b9914^_0x2e7537)),_0x3a878b[_0x3ad719([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x55141b=>{const _0xfb3db7=0x7d72a7df^_0x2e7537,_0x160a88=_0x5340a2[_0x3ad719([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x1597c2(){_0x160a88[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xfb3db7&&_0x55141b();}_0x1597c2(),_0x160a88[_0x3ad719([0x6f,0x6e])](_0x3ad719([0x61,0x64,0x64]),_0x1597c2);})),new window[(_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x26c705=>{function _0x271cd5(){for(const _0x103f6e in window)if(window[_0x3ad719([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x3ad719([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x103f6e))&&window[_0x103f6e]==_0x3bb680)return _0x26c705();_0x9e3d64[_0x3ad719([0x73,0x74,0x61,0x74,0x65])]!=_0x3ad719([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x3ad719([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x271cd5,0x7d72b450^_0x2e7537);}_0x57b27f(_0x3ad719([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x271cd5();})];return window[_0x3ad719([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3ad719([0x72,0x61,0x63,0x65])](_0x4fa974)[_0x3ad719([0x74,0x68,0x65,0x6e])](()=>_0x26b156);}async function _0x3c9295(){if(await _0x3a878b,_0x57b27f(_0x3ad719([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x33f97f=_0x5340a2[_0x3ad719([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3b7aea=_0x5340a2[_0x3ad719([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])](_0x33f97f[_0x3ad719([0x69,0x64])]),_0x538961=_0x55d28e(_0x3ad719([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x538961[_0x3ad719([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x33f97f['id'],_0x3b7aea?_0x3b7aea['id']:null,!0x0),_0x538961[_0x3ad719([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3ad719([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x538961[_0x3ad719([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x538961[_0x3ad719([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x5858e7,void(_0x538961[_0x3ad719([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x5858e7);}if(_0x57b27f(_0x3ad719([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x5314ba=_0x55d28e(_0x3ad719([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x5314ba[_0x3ad719([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3ad719([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5314ba[_0x3ad719([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5314ba[_0x3ad719([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x5858e7,_0x5314ba[_0x3ad719([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x5858e7;}_0x9e3d64[_0x3ad719([0x6d,0x6f,0x64,0x65,0x6c])][_0x3ad719([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5858e7,_0x9e3d64[_0x3ad719([0x6d,0x6f,0x64,0x65,0x6c])][_0x3ad719([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5858e7,_0x9e3d64[_0x3ad719([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3ad719([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x90a7f3(){return _0x57b27f(_0x3ad719([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x55d28e(_0x3ad719([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3ad719([0x73,0x74,0x61,0x74,0x65])]==_0x3ad719([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1ab29c(_0x7f47a){const _0x6b9d8d=_0x1ecb84();_0x9e3d64[_0x6b9d8d]=_0x3ad719([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])+_0x7f47a,_0x7f47a[_0x3ad719([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x3ad719([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x1ecb84()]=_0x3bb680),_0x7f47a!=_0x3ad719([0x56,0x61,0x6c,0x69,0x64])&&_0x3c9295();}function _0x1ecb84(){const _0x324195=window[_0x3ad719([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3ad719([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3ad719([0x6e,0x6f,0x77])]())[_0x3ad719([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3ad719([0x2e]),'');let _0x366eb3=_0x3ad719([0x69]);for(let _0x3a6e50=0x0;_0x3a6e50<_0x324195[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3a6e50+=0x2){let _0x5bfec0=window[_0x3ad719([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x324195[_0x3ad719([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3a6e50,_0x3a6e50+0x2));_0x5bfec0>=_0x464530[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5bfec0-=_0x464530[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x366eb3+=_0x464530[_0x5bfec0];}return _0x366eb3;}function _0x36fe8e(){const _0x41017e=_0x3c14c5[_0x3ad719([0x73,0x70,0x6c,0x69,0x74])](_0x3ad719([0x2e]));if(0x3!=_0x41017e[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x489464(_0x41017e[0x1]);function _0x489464(_0x436751){const _0x2450c7=_0x355f1f(_0x436751);return _0x2450c7&&_0x4bd888()?_0x2450c7:null;function _0x4bd888(){const _0x49bb6c=_0x2450c7[_0x3ad719([0x6a,0x74,0x69])],_0x2a1123=window[_0x3ad719([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x49bb6c[_0x3ad719([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x49bb6c[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3b7d3a={..._0x2450c7,[_0x3ad719([0x6a,0x74,0x69])]:_0x49bb6c[_0x3ad719([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x49bb6c[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3b7d3a[_0x3ad719([0x76,0x63])],_0xc42e86(_0x3b7d3a)==_0x2a1123;}}}async function _0x3e43f8(){let _0x4a5957=!0x0;try{const _0x50a9d7=_0x3c14c5[_0x3ad719([0x73,0x70,0x6c,0x69,0x74])](_0x3ad719([0x2e])),[_0x3235c7,_0x91a284,_0x5b6fa8]=_0x50a9d7;return _0x41b661(_0x3235c7),await _0x126fae(_0x3235c7,_0x91a284,_0x5b6fa8),_0x4a5957;}catch(_0x15a9f7){return!0x1;}function _0x41b661(_0xcdd0e5){const _0x5dadb4=_0x355f1f(_0xcdd0e5);_0x5dadb4&&_0x5dadb4[_0x3ad719([0x61,0x6c,0x67])]==_0x3ad719([0x45,0x53,0x32,0x35,0x36])||(_0x4a5957=!0x1);}async function _0x126fae(_0x34e43e,_0x5cec72,_0x2e0af0){const _0x54203e=window[_0x3ad719([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3ad719([0x66,0x72,0x6f,0x6d])](_0x38a00d(_0x2e0af0),_0x34559e=>_0x34559e[_0x3ad719([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x98e63a=new window[(_0x3ad719([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3ad719([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x34e43e+_0x3ad719([0x2e])+_0x5cec72),_0x4f12b8=window[_0x3ad719([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3ad719([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4f12b8)return;const _0x4f57aa=await _0x4f12b8[_0x3ad719([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3ad719([0x6a,0x77,0x6b]),_0x1c9644,{[_0x3ad719([0x6e,0x61,0x6d,0x65])]:_0x3ad719([0x45,0x43,0x44,0x53,0x41]),[_0x3ad719([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3ad719([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3ad719([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4f12b8[_0x3ad719([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3ad719([0x6e,0x61,0x6d,0x65])]:_0x3ad719([0x45,0x43,0x44,0x53,0x41]),[_0x3ad719([0x68,0x61,0x73,0x68])]:{[_0x3ad719([0x6e,0x61,0x6d,0x65])]:_0x3ad719([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4f57aa,_0x54203e,_0x98e63a)||(_0x4a5957=!0x1);}}function _0x355f1f(_0x3842c4){return _0x3842c4[_0x3ad719([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3ad719([0x65,0x79]))?JSON[_0x3ad719([0x70,0x61,0x72,0x73,0x65])](_0x38a00d(_0x3842c4)):null;}function _0x38a00d(_0x57205a){return window[_0x3ad719([0x61,0x74,0x6f,0x62])](_0x57205a[_0x3ad719([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3ad719([0x2b]))[_0x3ad719([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3ad719([0x2f])));}function _0xc42e86(_0xe12558){let _0x1f90a6=0x1505;function _0x185fd4(_0x4c4d6e){for(let _0x34aeca=0x0;_0x34aeca<_0x4c4d6e[_0x3ad719([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x34aeca++){const _0x48680c=_0x4c4d6e[_0x3ad719([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x34aeca);_0x1f90a6=(_0x1f90a6<<0x5)+_0x1f90a6+_0x48680c,_0x1f90a6&=_0x1f90a6;}}function _0x5e3522(_0x2519c0){Array[_0x3ad719([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2519c0)?_0x2519c0[_0x3ad719([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5e3522):_0x2519c0&&typeof _0x2519c0==_0x3ad719([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3ad719([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2519c0)[_0x3ad719([0x73,0x6f,0x72,0x74])]()[_0x3ad719([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2c34e9,_0x7aa52f])=>{_0x185fd4(_0x2c34e9),_0x5e3522(_0x7aa52f);}):_0x185fd4(window[_0x3ad719([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2519c0));}return _0x5e3522(_0xe12558),_0x1f90a6>>>0x0;}function _0x3173fe(_0x45437b){return _0x45437b[_0x3ad719([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3ad719([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3ad719([0x30]));}function _0x343095(_0x480e14){return _0x480e14[_0x3ad719([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3ad719([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3ad719([0x6a,0x6f,0x69,0x6e])]('');}function _0x57b27f(_0x3b9ba4){return _0x9e3d64[_0x3ad719([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3ad719([0x68,0x61,0x73])](_0x3b9ba4);}function _0x55d28e(_0x597b9c){return _0x9e3d64[_0x3ad719([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3ad719([0x67,0x65,0x74])](_0x597b9c);}function _0x5858e7(){}function _0x3ad719(_0x12aca5){return _0x12aca5['map'](_0x11ab20=>String['fromCharCode'](_0x11ab20))['join']('');}_0x1ab29c(await _0x4cfcf4());}(this);}['createRevision'](_0x16f426){const _0x42bfdf=this['editor']['plugins']['get']('Users');return new a({'id':_0x16f426['id'],'name':_0x16f426['name'],'creator':_0x16f426['creatorId']?_0x42bfdf['getUser'](_0x16f426['creatorId']):null,'diffData':_0x16f426['diffData']||_0x16f426['data'],'authors':_0x16f426['authorsIds']['map'](_0x5139d5=>_0x42bfdf['getUser'](_0x5139d5)),'createdAt':new Date(_0x16f426['createdAt']),'attributes':_0x16f426['attributes'],'fromVersion':_0x16f426['fromVersion'],'toVersion':_0x16f426['toVersion']});}['addRevision'](_0x1a7bf7,_0x26d4ba=0x0){this['_revisions']['add'](_0x1a7bf7,_0x26d4ba);}['getRevision'](_0x354f2d){return this['_revisions']['get'](_0x354f2d);}['getRevisions'](_0x20ef89={'toJSON':!0x1}){const _0x5e235d=Array['from'](this['_revisions']);return _0x5e235d['reverse'](),_0x20ef89['toJSON']?_0x5e235d['map'](_0x2f753d=>_0x2f753d['toJSON']()):_0x5e235d;}['getIndex'](_0x25ed66){return this['_revisions']['getIndex'](_0x25ed66);}['getEarlierVisibleRevision'](_0xc891e4){const [,_0x32af89]=this['getRevisionsIterator'](_0xc891e4,{'direction':'earlier'});return _0x32af89;}['getLaterVisibleRevision'](_0x4b87e8){const [,_0x2244ed]=this['getRevisionsIterator'](_0x4b87e8,{'direction':'later'});return _0x2244ed;}['getRevisionsInDiff'](_0x215673){const _0x309e8d=[];for(const _0x252723 of this['getRevisionsIterator'](_0x215673['newRevisionId']))if(_0x309e8d['push'](_0x252723),_0x252723['id']===_0x215673['oldRevisionId'])break;return _0x309e8d;}*['getRevisionsIterator'](_0x18d91e,{direction:_0x55fe8b='earlier',filter:_0xced462=()=>!0x0}={}){const _0x46e6f4='earlier'===_0x55fe8b?0x1:-0x1;let _0x3e7cd8=this['_revisions']['get'](_0x18d91e),_0x5d2645=this['getIndex'](_0x3e7cd8);for(yield _0x3e7cd8;_0x3e7cd8;){if(_0x5d2645+=_0x46e6f4,_0x3e7cd8=this['getRevision'](_0x5d2645),!_0x3e7cd8)return;_0xced462(_0x3e7cd8)&&(yield _0x3e7cd8);}}}function R(_0xa9f3c2,_0x2a22b2,_0x2c03ec){const t=_0xa9f3c2['t'];switch(_0x2a22b2){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'},_0x2c03ec);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x2c03ec);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const C={'c':_0x23c6b9,'a':_0x3e4e99,'e':_0x46de0e,'r':_0xcf47a2,'u':_0x131e84};class l extends _0x24aabd{['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[_0x4943c5,j,_0x23b549];}constructor(_0x8f3592){super(_0x8f3592),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x18a83f=_0x4dce4d();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x18a83f},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 _0x448b50=this['repository']['getRevision'](0x0),_0x5f3425=_0x448b50&&null===_0x448b50['creator']?_0x448b50:null;if(this['_continueCurrentRevision']=!!_0x5f3425&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5eb682=this['_source']['getCurrentRevisionId'](),_0x5aeb13=this['repository']['getRevision'](_0x5eb682);if(_0x5aeb13)this['_startingVersion']=_0x5aeb13['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5e90be=this['_source']['history']['_operations']['find'](_0x5a09b3=>!_0x5a09b3['_isInit']),_0x2cd52e=_0x5e90be?_0x5e90be['baseVersion']:this['_source']['history']['version'];_0x448b50?(_0x448b50['toVersion']<_0x2cd52e&&_0x448b50['_update']({'toVersion':_0x2cd52e}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x5f3425['id'],this['_startingVersion']=_0x5f3425['fromVersion']):(this['_startingVersion']=_0x448b50['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x2cd52e,this['_continueCurrentRevision']=!0x1);}}else _0x5f3425&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x5f3425['toVersion'],this['editor']['model']['document']['history']['version']),_0x5f3425['fromVersion']===_0x5f3425['toVersion']?(0x0!==_0x5f3425['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x5f3425['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x5f3425['id'],this['_startingVersion']=_0x5f3425['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',_0x59d97e=>!_0x59d97e),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3ffbe=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2767e0;for(const _0x3c4f0f in _0x3ffbe){const _0x22386c=_0x3c4f0f,_0x2ca479=_0x3ffbe[_0x22386c];if('revisionHistoryLicenseKeyValid'==_0x2ca479||'revisionHistoryLicenseKeyInvalid'==_0x2ca479||'revisionHistoryLicenseKeyExpired'==_0x2ca479||'revisionHistoryLicenseKeyDomainLimit'==_0x2ca479||'revisionHistoryLicenseKeyNotAllowed'==_0x2ca479||'revisionHistoryLicenseKeyEvaluationLimit'==_0x2ca479||'revisionHistoryLicenseKeyTrialLimit'==_0x2ca479||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x2ca479||'revisionHistoryLicenseKeyUsageLimit'==_0x2ca479){delete _0x3ffbe[_0x22386c],_0x2767e0=_0x2ca479,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2767e0&&_0x3ffbe['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2767e0&&_0x3ffbe['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2767e0&&_0x3ffbe['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2767e0&&_0x3ffbe['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2767e0&&_0x3ffbe['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2767e0&&_0x3ffbe['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x2767e0&&_0x3ffbe['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2767e0&&_0x3ffbe['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x168faa=this['repository']['getRevision'](0x0),_0xa2f83=await this['getRevisionDocumentData'](_0x168faa),_0x2afe14=await this['getRevisionRootsAttributes'](_0x168faa);this['_replaceEditorDataWithRevisionData'](_0xa2f83,_0x2afe14);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5a6034){this['_source']=_0x5a6034;}async['update'](){const _0x13ebaf=await this['_source']['getLatestVersion']();if(_0x13ebaf>this['currentRevision']['toVersion']){await this['_loadState']();const _0x4e6d83=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x13ebaf});_0x4e6d83['authors']=_0x4e6d83['authorsIds']['map'](_0x4ec68f=>this['editor']['plugins']['get']('Users')['getUser'](_0x4ec68f)),this['currentRevision']['_update'](_0x4e6d83);}}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'](_0x3a952c={},_0x2b599b=null){const _0xfe899=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2b599b>this['currentRevision']['toVersion']&&(_0x2b599b=null),null===_0x2b599b&&(_0x2b599b=await this['_source']['getLatestVersion']());const _0x599efa=this['_getFromVersion'](_0x2b599b),_0x4c46e9=this['buildRevisionData']({'from':_0x599efa,'to':_0x2b599b});if(this['currentRevision']['toVersion']<_0x2b599b){const _0x14548d=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2b599b,'to':_0x2b599b});_0x14548d['authors']=[],_0x14548d['authorsIds']=[],_0x14548d['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x14548d,!0x0),delete _0x14548d['authors'],_0xfe899['push'](_0x14548d);}_0x3a952c['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3a952c['name']=_0x3a952c['name']||null,_0x3a952c['id']=_0x3a952c['id']||_0x4dce4d(),_0x3a952c={..._0x3a952c,..._0x4c46e9};const _0x504914=this['addRevisionData'](_0x3a952c);_0xfe899['push'](_0x3a952c);const _0x3e29da=this['repository']['getIndex'](_0x504914);if(0x0!==_0x3e29da){const _0x49a848=this['repository']['getRevision'](_0x3e29da-0x1);if(_0x49a848['fromVersion']!==_0x2b599b){const _0x43f4aa=this['_revisionDataBuilder']['getData'](_0x2b599b,_0x49a848['toVersion']),_0x6bfc2f={'id':_0x49a848['id'],'diffData':_0x43f4aa['diffData'],'authorsIds':_0x43f4aa['authorsIds'],'authors':_0x43f4aa['authorsIds']['map'](_0x3e51aa=>this['editor']['plugins']['get']('Users')['getUser'](_0x3e51aa)),'fromVersion':_0x2b599b};_0x49a848===this['currentRevision']&&(_0x6bfc2f['createdAt']=new Date(_0x3a952c['createdAt']['getTime']()+0xa)),_0x49a848['_update'](_0x6bfc2f,!0x0),delete _0x6bfc2f['authors'],_0xfe899['push'](_0x6bfc2f);}}if(this['adapter']){for(const _0x4f8e91 of _0xfe899)this['_bufferUpdate'](_0x4f8e91['id'],_0x4f8e91,!0x0);this['sendBufferedUpdates']();}return _0x504914;}['addRevisionData'](_0x1def92){const _0x1cc712=this['repository']['createRevision'](_0x1def92);return this['adapter']&&_0x1cc712['on']('_update',(_0x24d07c,_0x493151,_0x524323)=>{_0x524323||(this['_bufferUpdate'](_0x493151['id'],_0x493151,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x1cc712,this['_findInsertionIndex'](_0x1cc712)),_0x1cc712;}async['getRevisionDocumentData'](_0x4866ad){await this['_loadRevisionData'](_0x4866ad);const _0x44729b={};for(const _0x4cf61d in _0x4866ad['diffData']){if(_0x4866ad['diffData'][_0x4cf61d]['attachChange']&&!_0x4866ad['diffData'][_0x4cf61d]['attachChange']['isAttached'])continue;const _0x1b1d9f=this['_removeRevisionMarkers'](JSON['parse'](_0x4866ad['diffData'][_0x4cf61d]['insertions'])),_0xb39278=this['editor']['editing']['view']['document'],_0x5b9a43=new _0x4833c1(_0xb39278,_0x1b1d9f['map'](_0x2d6a11=>V(_0x2d6a11,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x44729b[_0x4cf61d]=this['editor']['data']['processor']['toData'](_0x5b9a43),this['editor']['data']['processor']['useFillerType']('default');}return _0x44729b;}async['getRevisionRootsAttributes'](_0x11e137){await this['_loadRevisionData'](_0x11e137);const _0x50cad7={};for(const _0x15961a in _0x11e137['diffData'])_0x11e137['diffData'][_0x15961a]['attachChange']&&!_0x11e137['diffData'][_0x15961a]['attachChange']['isAttached']||(_0x50cad7[_0x15961a]=_0x11e137['diffData'][_0x15961a]['attributesAfter']||{});return _0x50cad7;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x504d98=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1f686f=0x0;_0x1f686f<_0x504d98['length'];_0x1f686f++){const _0x5d9cef=_0x504d98[_0x1f686f];let _0x29261f=!0x1;for(const _0x19bc96 of Object['keys'](_0x5d9cef))void 0x0===_0x5d9cef[_0x19bc96]?delete _0x5d9cef[_0x19bc96]:'id'!==_0x19bc96&&(_0x29261f=!0x0);_0x29261f||(_0x504d98[_0x1f686f]=null);}if(_0x504d98=_0x504d98['filter'](_0x55aada=>null!==_0x55aada),!_0x504d98['length'])return;for(let _0x20f2af=0x0;_0x20f2af<_0x504d98['length'];_0x20f2af++){const _0x519030=_0x504d98[_0x20f2af];void 0x0!==_0x519030['fromVersion']&&void 0x0===_0x519030['toVersion']&&(_0x519030['toVersion']=this['repository']['getRevision'](_0x519030['id'])['toVersion']),void 0x0!==_0x519030['toVersion']&&void 0x0===_0x519030['fromVersion']&&(_0x519030['fromVersion']=this['repository']['getRevision'](_0x519030['id'])['fromVersion']);}const _0x7e91de=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x504d98,_0x7e91de)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1621c5=>{if(_0x1621c5){for(const _0x31f75a of _0x1621c5)this['setRevisionData']({'id':_0x31f75a['id'],'createdAt':_0x31f75a['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x3a3076,_0xcc1fe2){let _0x46c766=this['editor']['config']['get']('initialData'),_0x4acca2=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x46c766){_0x46c766={};for(const _0x5b667d of this['editor']['model']['document']['getRootNames']())_0x46c766[_0x5b667d]='';}if('string'==typeof _0x46c766&&(_0x46c766={'main':_0x46c766}),void 0x0===_0x4acca2){_0x4acca2={};for(const _0x66ac65 of this['editor']['model']['document']['getRootNames']())_0x4acca2[_0x66ac65]={};}let _0x5e6a44=!0x1;const _0x3e77c3=Object['keys'](_0x46c766),_0xd4831=Object['keys'](_0x3a3076);for(const _0x21ca3e of _0x3e77c3){if(_0x46c766[_0x21ca3e]!==_0x3a3076[_0x21ca3e]&&''!==_0x46c766[_0x21ca3e]['trim']()){_0x5e6a44=!0x0;break;}if(!_0x23c23a(_0x4acca2[_0x21ca3e],_0xcc1fe2[_0x21ca3e])&&Object['keys'](_0x4acca2[_0x21ca3e])['length']>0x0){_0x5e6a44=!0x0;break;}}_0x5e6a44||(_0x5e6a44=_0xd4831['some'](_0x22193d=>!this['editor']['model']['document']['getRoot'](_0x22193d))),_0x5e6a44&&_0x482cd7('editor-initial-data-replaced-with-revision-data',{'editorData':_0x46c766,'editorRootsAttributes':_0x4acca2,'revisionData':_0x3a3076,'revisionRootsAttributes':_0xcc1fe2}),this['editor']['config']['set']('initialData',_0x3a3076),this['editor']['config']['set']('rootsAttributes',_0xcc1fe2);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4f3ec5=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4f3ec5['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x102773){const _0x5bd694=this['repository']['getRevisions']();_0x5bd694['reverse']();let _0x29bf75=0x0;for(;_0x29bf75<_0x5bd694['length'];){const _0x432dcb=_0x5bd694[_0x29bf75];if(_0x432dcb===this['currentRevision']){_0x29bf75++;continue;}if(_0x432dcb['id']===this['_initialRevisionId'])break;const _0x4a43fc=_0x102773['toVersion']-_0x432dcb['toVersion']||_0x102773['fromVersion']-_0x432dcb['fromVersion'];if(_0x4a43fc>0x0)break;if(_0x4a43fc<0x0)_0x29bf75++;else{if(!_0x102773['creator']&&_0x432dcb['creator'])break;if(_0x432dcb['creator']||!_0x102773['creator']){if(_0x102773['createdAt']>_0x432dcb['createdAt'])break;_0x29bf75++;}else _0x29bf75++;}}return _0x29bf75;}['setRevisionData'](_0x47b951){const _0x36f34a=this['repository']['getRevision'](_0x47b951['id']);if(_0x47b951['createdAt']&&(_0x47b951['createdAt']=new Date(_0x47b951['createdAt'])),_0x47b951['authorsIds']){const _0x312c8f=this['editor']['plugins']['get']('Users');_0x47b951['authors']=_0x47b951['authorsIds']['map'](_0x2e00d0=>_0x312c8f['getUser'](_0x2e00d0));}_0x36f34a['_update'](_0x47b951,!0x0);}['buildRevisionData']({revision:_0x4842c8=null,from:_0x4f7818=null,to:_0x30b6d1=null}){_0x4f7818=null!==_0x4f7818?_0x4f7818:_0x4842c8['fromVersion'],_0x30b6d1=null!==_0x30b6d1?_0x30b6d1:_0x4842c8['toVersion'];const _0x2e8ef4=this['_revisionDataBuilder']['getData'](_0x4f7818,_0x30b6d1),_0xd79ed4={'diffData':_0x2e8ef4['diffData'],'authorsIds':_0x2e8ef4['authorsIds'],'fromVersion':_0x4f7818,'toVersion':_0x30b6d1};if(!_0x4842c8||_0x30b6d1!==_0x4842c8['toVersion']){const _0xcbf99c=_0x30b6d1-0x1,_0x41b4ca=this['_source']['history']['getOperation'](_0xcbf99c);_0xd79ed4['createdAt']=_0x41b4ca&&_0x41b4ca['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4f7818===this['_loadedStateData']['fromVersion']){for(const _0x111ac8 of this['_loadedStateData']['authors'])_0xd79ed4['authorsIds']['includes'](_0x111ac8['id'])||_0xd79ed4['authorsIds']['push'](_0x111ac8['id']);}return _0xd79ed4;}['_loadRevisionData'](_0x165b8b){if(!_0x165b8b||_0x165b8b['diffData'])return Promise['resolve']();{const _0x364aed=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x364aed,'revisionId':_0x165b8b['id']})['then'](_0x2e5e60=>{_0x165b8b['diffData']=_0x2e5e60['diffData'];});}}['_bufferUpdate'](_0x39bfb8,_0x24f75b,_0xb9e1a2){if(this['_bufferedUpdates']['has'](_0x39bfb8)){const _0x3bdbc8=this['_bufferedUpdates']['get'](_0x39bfb8);_0x24f75b=_0xb9e1a2?{..._0x3bdbc8,..._0x24f75b}:{..._0x24f75b,..._0x3bdbc8};}this['_bufferedUpdates']['set'](_0x39bfb8,_0x24f75b);}['_getFromVersion'](_0x33b2f0){const _0x3be4a6=this['repository']['getRevisions']();_0x3be4a6['reverse'](),_0x3be4a6['shift']();const _0x1947ba=_0x3be4a6['find'](_0x5ee92b=>_0x5ee92b['toVersion']<=_0x33b2f0)['toVersion'];return _0x1947ba<this['_startingVersion']?this['_startingVersion']:_0x1947ba;}['_createInitialRevision'](_0x2077ad){const _0x7268b1=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x7268b1)this['_initialRevisionId']=_0x7268b1['id'];else{const _0x1fff2a=!this['editor']['model']['document']['roots']['find'](_0x338930=>this['editor']['model']['hasContent'](_0x338930)),_0xa52812=this['editor']['plugins']['get']('Users')['me']['id'],_0x239c44=R(this['editor']['locale'],_0x1fff2a?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2077ad,'to':_0x2077ad,'id':this['_initialRevisionId'],'name':_0x239c44,'creatorId':_0xa52812});}}['_createCurrentRevision'](_0x1e6ce2){const _0x3e31c2=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3e31c2),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1e6ce2,'to':_0x1e6ce2,'id':_0x3e31c2,'name':'','creatorId':null}));}['_makeRevision']({name:_0x42b386,from:_0x2a1c15,to:_0x50a8e4,creatorId:_0x858237,id:_0x41c25c}){const _0x1d5e83=this['buildRevisionData']({'from':_0x2a1c15,'to':_0x50a8e4});_0x1d5e83['name']=_0x42b386,_0x1d5e83['creatorId']=_0x858237,_0x1d5e83['id']=_0x41c25c;const _0x27fc23=this['addRevisionData'](_0x1d5e83);return this['adapter']&&this['_bufferUpdate'](_0x1d5e83['id'],_0x1d5e83,!0x0),_0x27fc23;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x58bf7e){return(_0x58bf7e=_0x58bf7e['filter'](_0x241d9c=>!_0x241d9c['name']||'revision-start'!==_0x241d9c['name']&&'revision-end'!==_0x241d9c['name']))['forEach'](_0x1006f0=>{'string'!=typeof _0x1006f0&&(_0x1006f0['children']=this['_removeRevisionMarkers'](_0x1006f0['children']),_0x1006f0['attributes']=_0x1006f0['attributes']['filter'](_0x1cdc68=>!_0x1cdc68[0x0]['startsWith']('data-revision-')));}),_0x58bf7e;}}function V(_0xa0927e,_0x599793){const _0x5c606e=_0x599793['editing']['view']['document'];if('string'==typeof _0xa0927e)return new _0xd57083(_0x5c606e,_0xa0927e);{const _0xe687a5=_0xa0927e['children']['map'](_0x46296c=>V(_0x46296c,_0x599793));return new(C[_0xa0927e['type']]||_0x2c4196)(_0x5c606e,_0xa0927e['name'],_0xa0927e['attributes'],_0xe687a5);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x7176c4){this['editor']=_0x7176c4,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'](_0x2dd5df){this['source']=_0x2dd5df;const _0x38c5cc=new Map(),_0x50144d=new Map(),_0x27b84b=this['editor']['model']['document']['roots']['map'](_0x176634=>_0x176634['rootName']);for(const _0x4bee9e of _0x27b84b){const _0x15680e=this['editor']['model']['document']['getRoot'](_0x4bee9e),_0x1bcd76=F(_0x15680e);_0x38c5cc['set'](_0x4bee9e,_0x1bcd76),_0x50144d['set'](_0x4bee9e,Object['fromEntries'](_0x15680e['getAttributes']()));}const _0x601a8e=Array['from'](this['editor']['model']['markers'])['map'](_0x5e7e91=>[_0x5e7e91['name'],_0x5e7e91['getRange']()]),_0x4e6098=this['source']['version'];this['_saveMetaData'](_0x4e6098,_0x38c5cc,_0x601a8e,_0x50144d),this['_startingRevisionId']=this['_revisionId'];const _0x2967c2=new Map(),_0x992431=new Map();for(const _0x38fecc of _0x27b84b){const _0x52be48=B(_0x38fecc);_0x2967c2['set'](_0x38fecc,_0x52be48),_0x992431['set'](_0x38fecc,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2967c2,[],_0x992431);}['getData'](_0x56a22a,_0x46df74){if(this['_lastFrom']===_0x56a22a&&this['_lastTo']<=_0x46df74)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x46df74,!0x0);else{if(!this['_savedMetaData']['has'](_0x56a22a)){const _0x37c1cb=this['_getPreviousFrom'](_0x56a22a);this['_calculateMetaData'](_0x37c1cb,_0x56a22a,!0x1);}this['_calculateMetaData'](_0x56a22a,_0x46df74,!0x0);}return this['_lastFrom']=_0x56a22a,this['_lastTo']=_0x46df74,this['_getState']();}['loadState'](_0xf75fcc){this['_reset'](),this['_lastFrom']=_0xf75fcc['fromVersion'],this['_lastTo']=_0xf75fcc['toVersion'];for(const _0x4acb8e in _0xf75fcc['diffData']){const _0x19aec5=_0xf75fcc['diffData'][_0x4acb8e]['attachChange'],_0x3c300a=_0x295472(_0xf75fcc['diffData'][_0x4acb8e]['attributesBefore'])||{},_0x1b5c64=this['_makeModelFromViewString'](_0xf75fcc['diffData'][_0x4acb8e]['deletions']);_0x1b5c64['rootName']=_0x4acb8e,_0x1b5c64['_isAttached']=!_0x19aec5||!_0x19aec5['isAttached'],_0x1b5c64['isAttached']=()=>_0x1b5c64['_isAttached'],this['_baseRoots']['set'](_0x4acb8e,_0x1b5c64),this['_baseRootsAttributes']['set'](_0x4acb8e,_0x3c300a),_0x19aec5&&this['_touchedRoots']['set'](_0x4acb8e,_0x19aec5);const _0x581fa7=this['_makeIdsRoot'](_0x1b5c64);this['_baseIdsRoots']['set'](_0x4acb8e,_0x581fa7);for(const [_0x2a86ae,_0x2b0e68]of _0x1b5c64['markers']){if(!_0x2a86ae['startsWith']('revision:'))continue;const _0x3e958e=_0x2a86ae['split'](':')[0x2];for(const _0x38b83e of _0x2b0e68['getWalker']({'singleCharacters':!0x0})){const _0x21a904=this['_getVidAttributeName'](_0x38b83e),_0x3cf5f4='elementEnd'==_0x38b83e['type']?_0x38b83e['previousPosition']['path']['slice'](0x0,-0x1):_0x38b83e['previousPosition']['path'],_0x3e3b5a=_0x581fa7['getNodeByPath'](_0x3cf5f4)['getAttribute'](_0x21a904);this['_touched']['set'](_0x3e3b5a,{'userId':_0x3e958e});}}}this['_startingRevisionId']=this['_revisionId'];const _0x5aefdf=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x40fb45=>!this['_touched']['has'](_0x40fb45));let _0x6b50a7=0x0;const _0x94b8cb=new Map();for(const _0x482faf in _0xf75fcc['diffData']){const _0x4dfd9f=_0xf75fcc['diffData'][_0x482faf]['attachChange'],_0x46d6e1=_0x295472(_0xf75fcc['diffData'][_0x482faf]['attributesAfter'])||{},_0x317cac=this['_makeModelFromViewString'](_0xf75fcc['diffData'][_0x482faf]['insertions']);_0x317cac['rootName']=_0x482faf,_0x317cac['_isAttached']=!_0x4dfd9f||_0x4dfd9f['isAttached'],_0x317cac['isAttached']=()=>_0x317cac['_isAttached'],this['_diffRoots']['set'](_0x482faf,_0x317cac),this['_diffRootsAttributes']['set'](_0x482faf,_0x46d6e1);const _0x377408=this['_makeIdsRoot'](_0x317cac,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x482faf,_0x377408),_0x94b8cb['set'](_0x482faf,_0x317cac['isAttached']()?_0x46d6e1:{});for(const [_0x15d77b,_0x5d51a0]of _0x317cac['markers']){if(!_0x15d77b['startsWith']('revision:'))continue;const _0x217ca3=_0x15d77b['split'](':')[0x2];for(const _0x14c650 of _0x5d51a0['getWalker']({'singleCharacters':!0x0})){const _0x3363d4=this['_getVidAttributeName'](_0x14c650),_0x1d7d11=this['_revisionId']++,_0x5d4fab='elementEnd'==_0x14c650['type']?_0x14c650['previousPosition']['path']['slice'](0x0,-0x1):_0x14c650['previousPosition']['path'];_0x377408['getNodeByPath'](_0x5d4fab)['_setAttribute'](_0x3363d4,_0x1d7d11),this['_touched']['set'](_0x1d7d11,{'userId':_0x217ca3});}}for(const _0x46ba32 of this['editor']['model']['createRangeIn'](_0x317cac)['getWalker']({'singleCharacters':!0x0})){const _0x576e85=this['_getVidAttributeName'](_0x46ba32),_0x1aee12='elementEnd'==_0x46ba32['type']?_0x46ba32['previousPosition']['path']['slice'](0x0,-0x1):_0x46ba32['previousPosition']['path'],_0x18c9cb=_0x377408['getNodeByPath'](_0x1aee12);_0x18c9cb['getAttribute'](_0x576e85)>0x0||_0x18c9cb['_setAttribute'](_0x576e85,_0x5aefdf[_0x6b50a7++]);}for(const [_0x5e6276,_0x56b5bb]of _0x317cac['markers'])_0x5e6276['startsWith']('revision:')||this['_markers']['set'](_0x5e6276,_0x56b5bb);}const _0x29a107=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x29a107),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x29a107,0x1));const _0x1e691b=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x1e691b),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1e691b,0x1));const _0x4e68e7=Array['from'](this['_diffRoots'])['map'](([_0x4aac75,_0xddb746])=>[_0x4aac75,F(_0xddb746)]);this['_saveMetaData'](this['_lastTo'],_0x4e68e7,this['_markers'],_0x94b8cb);}['_makeModelFromViewString'](_0x8cc927){const _0x504161=JSON['parse'](_0x8cc927),_0x2de130=this['editor']['editing']['view']['document'],_0x3cd7b4=new _0x4833c1(_0x2de130,_0x504161['map'](_0x345261=>V(_0x345261,this['editor'])));return this['editor']['data']['toModel'](_0x3cd7b4);}['_saveMetaData'](_0x2d6865,_0x51d6c7,_0x4fcf06,_0x5bca5c){const _0x585d86=new Map(_0x51d6c7),_0x2c7919=new Map(_0x295472(_0x5bca5c)),_0x3a82c2=new Map();for(const [_0x2a774d,_0x11b64e]of _0x4fcf06)_0x3a82c2['set'](_0x2a774d,{'start':_0x11b64e['start']['clone'](),'end':_0x11b64e['end']['clone'](),'rootName':_0x11b64e['root']['rootName']});this['_savedMetaData']['set'](_0x2d6865,{'roots':_0x585d86,'markers':_0x3a82c2,'rootsAttributes':_0x2c7919});}['_removeMetaData'](_0x2fa536){this['_savedMetaData']['delete'](_0x2fa536);}['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'](_0x130843,_0x322b7d=null){let _0x234976=null;_0x130843['is']('documentFragment')||(_0x234976=new ft(_0x130843['name'],{'vid_start':null===_0x322b7d?this['_revisionId']++:_0x322b7d++}));const _0x4cd76d=[];for(const _0x2886af of _0x130843['getChildren']())if(_0x2886af['is']('element')){_0x4cd76d['push'](this['_makeIdsRoot'](_0x2886af,_0x322b7d));const _0x57de46=_0x4cd76d[_0x4cd76d['length']-0x1];null!==_0x322b7d&&(_0x322b7d=_0x57de46['is']('element','$text')?_0x57de46['getAttribute']('vid')+0x1:_0x57de46['getAttribute']('vid_end')+0x1);}else{for(let _0x32d205=0x0;_0x32d205<_0x2886af['offsetSize'];_0x32d205++)_0x4cd76d['push'](new ft('$text',{'vid':null===_0x322b7d?this['_revisionId']++:_0x322b7d++}));}if(_0x130843['is']('documentFragment')){const _0x2b5907=B(_0x130843['rootName']);return _0x2b5907['_insertChild'](0x0,_0x4cd76d),_0x2b5907;}return _0x234976['_setAttribute']('vid_end',null===_0x322b7d?this['_revisionId']++:_0x322b7d++),_0x234976['_insertChild'](0x0,_0x4cd76d),_0x234976;}['_calculateMetaData'](_0x2a3da3,_0x5ee7f0,_0x2e0edb){this['_reset']();const {roots:_0x35c342,markers:_0x3c04ab,rootsAttributes:_0x41a080}=this['_savedMetaData']['get'](_0x2a3da3);this['_baseRoots']=new Map(_0x35c342),this['_baseRootsAttributes']=new Map(_0x295472(_0x41a080));for(const [_0xe6d4e1,_0x354587]of this['_baseRoots'])if('$graveyard'!==_0xe6d4e1&&(this['_diffRoots']['set'](_0xe6d4e1,F(_0x354587)),this['_diffRootsAttributes']=new Map(_0x295472(_0x41a080)),_0x2e0edb)){const _0x1f0fe5=this['_revisionId'];this['_idsRoots']['set'](_0xe6d4e1,this['_makeIdsRoot'](_0x354587)),this['_baseIdsRoots']['set'](_0xe6d4e1,this['_makeIdsRoot'](_0x354587,_0x1f0fe5));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x2e0edb&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3446e4,_0x3430f9]of _0x3c04ab){const _0x105724=this['_baseRoots']['get'](_0x3430f9['rootName']),_0x3610c9=this['_diffRoots']['get'](_0x3430f9['rootName']),_0x3d5e23=new vt(this['_fixPosition'](_0x3430f9['start'],_0x105724),this['_fixPosition'](_0x3430f9['end'],_0x105724)),_0x486db8=this['_fixRange'](_0x3d5e23,_0x3610c9);_0x105724['markers']['set'](_0x3446e4,_0x3d5e23),this['_markers']['set'](_0x3446e4,_0x486db8);}this['_applyOperations'](_0x2a3da3,_0x5ee7f0,_0x2e0edb);}['_applyOperations'](_0x21f882,_0x28d697,_0x2e3c47){for(const _0x49ebad of this['source']['getOperations'](_0x21f882,_0x28d697))this['_handleOperation'](_0x49ebad,_0x2e3c47);for(const _0x54fbce of this['_diffRoots']['values']())_0x54fbce['markers']['clear']();for(const [_0x4f08e2,_0x38bde5]of this['_markers']){this['_diffRoots']['get'](_0x38bde5['root']['rootName'])['markers']['set'](_0x4f08e2,_0x38bde5['clone']());}const _0x3b7a39=new Map(),_0x261118=new Map();for(const [_0x19644a,_0xef3e2a]of this['_diffRoots'])_0x3b7a39['set'](_0x19644a,F(_0xef3e2a)),_0x261118['set'](_0x19644a,this['_diffRootsAttributes']['get'](_0x19644a));this['_saveMetaData'](_0x28d697,_0x3b7a39,this['_markers'],_0x261118);}['_getPreviousFrom'](_0x109d04){const _0x4e52a7=Array['from'](this['_savedMetaData']['keys']());_0x4e52a7['sort']((_0x138aa2,_0xcfcac3)=>_0x138aa2-_0xcfcac3),_0x4e52a7['reverse']();for(const _0x56f07b of _0x4e52a7)if(_0x56f07b<_0x109d04)return _0x56f07b;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x45c659,_0x1d9185){const _0xd6603d=Array['from'](_0x1d9185['markers'])['map'](([_0x26b0d6,_0xd7f4f9])=>[_0x26b0d6,this['_fixRange'](_0xd7f4f9,_0x45c659)]);_0x45c659['markers']=new Map(_0xd6603d);}['_transformMarkers'](_0x1aac4e){for(const _0x25e8e5 of this['_markers']['values']()){const _0x256a47=_0x25e8e5['getTransformedByOperation'](_0x1aac4e),_0x33333e=vt['_createFromRanges'](_0x256a47);_0x25e8e5['start']=_0x33333e['start'],_0x25e8e5['end']=_0x33333e['end'];}}['_handleOperation'](_0x37db7d,_0x49c079){if('addRoot'!=_0x37db7d['type']&&'detachRoot'!=_0x37db7d['type']){if('insert'==_0x37db7d['type']){const _0x241511=_0x37db7d['position']['root']['rootName'];this['_diffRoots']['has'](_0x241511)||(this['_diffRoots']['set'](_0x241511,B(_0x241511,!0x0)),this['_diffRootsAttributes']['set'](_0x241511,{}),_0x49c079&&this['_idsRoots']['set'](_0x241511,B(_0x241511,!0x0)));}else{if('addRootAttribute'==_0x37db7d['type']||'removeRootAttribute'==_0x37db7d['type']||'changeRootAttribute'==_0x37db7d['type'])return void this['_handleRootAttributeOperation'](_0x37db7d);'marker'==_0x37db7d['type']&&this['_handleMarkerOperation'](_0x37db7d);}if('marker'!==_0x37db7d['type']){const _0x58c1bf=this['_cloneOperation'](_0x37db7d,this['_diffRoots']);_0x58c1bf['_execute'](),this['_transformMarkers'](_0x58c1bf);}if(_0x49c079)switch(_0x37db7d['type']){case'insert':this['_handleInsertOperation'](_0x37db7d);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x37db7d);break;case'merge':this['_handleMergeOperation'](_0x37db7d);break;case'split':this['_handleSplitOperation'](_0x37db7d);}}else this['_handleRootOperation'](_0x37db7d,_0x49c079);}['_cloneOperation'](_0x5ebee1,_0x461f07){const _0x545928=_0x5ebee1['clone']();return _0x545928['_authorId']=_0x5ebee1['_authorId'],this['_fixOperation'](_0x545928,_0x461f07),_0x545928;}['_getBaseVids'](_0x19e478){return _0x19e478['map'](_0x144e5c=>{const _0x506b38=this['_getVidAttributeName'](_0x144e5c);return Number(_0x144e5c['item']['getAttribute'](_0x506b38));});}['_generateTape'](_0x3dbe3a,_0x5ccc90){if(_0x3dbe3a['is']('element','$text'))_0x5ccc90['push']({'item':_0x3dbe3a,'type':'text'});else{_0x3dbe3a['is']('element')&&_0x5ccc90['push']({'item':_0x3dbe3a,'type':'elementStart'});for(const _0x2e2687 of _0x3dbe3a['getChildren']())this['_generateTape'](_0x2e2687,_0x5ccc90);_0x3dbe3a['is']('element')&&_0x5ccc90['push']({'item':_0x3dbe3a,'type':'elementEnd'});}return _0x5ccc90;}['_getState'](){const _0x24e574=new Map(this['_touched']),_0x46670f=new Map(_0x24e574),_0x3798b4=new Map(),_0x12ac6f={'insertions':{},'deletions':{}},_0x143e89={'insertions':{},'deletions':{}},_0x128694=new Map(),_0x2f2993=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x2f2993['delete']('$graveyard');for(const _0x3bbb7d of _0x2f2993){const _0x51c9b4=this['_diffRoots']['get'](_0x3bbb7d)||B(_0x3bbb7d,!0x1),_0x19c1cc=this['_baseRoots']['get'](_0x3bbb7d)||B(_0x3bbb7d,!0x1);_0x51c9b4['isAttached']()||_0x19c1cc['isAttached']()?(_0x12ac6f['insertions'][_0x3bbb7d]=F(_0x51c9b4),_0x12ac6f['deletions'][_0x3bbb7d]=F(_0x19c1cc),this['_copyMarkers'](_0x12ac6f['deletions'][_0x3bbb7d],_0x19c1cc),this['_copyMarkers'](_0x12ac6f['insertions'][_0x3bbb7d],_0x51c9b4),_0x143e89['insertions'][_0x3bbb7d]=this['_generateTape'](this['_idsRoots']['get'](_0x3bbb7d),[]),_0x143e89['deletions'][_0x3bbb7d]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3bbb7d)||B(_0x3bbb7d,!0x1),[])):_0x2f2993['delete'](_0x3bbb7d);}for(const _0x55eb81 of _0x2f2993){const _0x131c25=_0x143e89['insertions'][_0x55eb81];for(const _0x10aaad of _0x131c25){const _0x19ce73=this['_getVidAttributeName'](_0x10aaad),_0x842c4d=_0x10aaad['item']['getAttribute'](_0x19ce73);_0x46670f['delete'](_0x842c4d),_0x842c4d>=this['_startingRevisionId']&&_0x3798b4['set'](_0x842c4d,_0x24e574['get'](_0x842c4d));}}for(const _0x5201ab of _0x2f2993){const _0xe18253=_0x143e89['insertions'][_0x5201ab],_0x8bd45b=this['_getBaseVids'](_0x143e89['deletions'][_0x5201ab]);let _0x54fb92=0x0;for(const _0x12b5ac of _0xe18253){const _0xa82039=this['_getVidAttributeName'](_0x12b5ac),_0x2727c1=_0x12b5ac['item']['getAttribute'](_0xa82039);if(!_0x3798b4['has'](_0x2727c1)&&!_0x128694['has'](_0x2727c1)){if(_0x46670f['has'](_0x2727c1))_0x54fb92++;else{if(_0x2727c1!=_0x8bd45b[_0x54fb92]){const _0x551d2f=_0x24e574['get'](_0x2727c1)||_0x24e574['get'](_0x8bd45b[_0x54fb92]);for(;_0x2727c1!=_0x8bd45b[_0x54fb92];)_0x46670f['has'](_0x8bd45b[_0x54fb92])||(_0x128694['set'](_0x8bd45b[_0x54fb92],_0x551d2f),_0x24e574['set'](_0x8bd45b[_0x54fb92],_0x551d2f)),_0x54fb92++;}_0x54fb92++;}}}}for(const _0x433476 of _0x2f2993){const _0x51bfec=_0x143e89['insertions'][_0x433476];for(const _0x15b8d6 of _0x51bfec){const _0x19b115=this['_getVidAttributeName'](_0x15b8d6),_0x24feb5=_0x15b8d6['item']['getAttribute'](_0x19b115);if(_0x128694['has'](_0x24feb5)){const _0x421661=_0x128694['get'](_0x24feb5);_0x46670f['has'](_0x24feb5)||_0x46670f['set'](_0x24feb5,{..._0x421661}),_0x3798b4['set'](_0x24feb5,{..._0x421661});}}}for(const _0x31d48e of _0x46670f['keys']())_0x31d48e>=this['_startingRevisionId']&&_0x46670f['delete'](_0x31d48e);const _0x5d6a29=new Map();for(const _0x5562c4 of _0x2f2993){let _0x378b5d=_0x143e89['insertions'][_0x5562c4];for(const _0x294540 of _0x378b5d)if(_0x294540['item']['is']('element','tableCell')){const _0x49d477=this['_getVidAttributeName'](_0x294540),_0x1d5a37=_0x294540['item']['getAttribute'](_0x49d477);if(_0x3798b4['has'](_0x1d5a37)){const _0x2200f3=_0x294540['item']['parent']['parent']['getAttribute']('vid_start'),_0x40d1b8=_0x5d6a29['get'](_0x2200f3)||new Set();_0x40d1b8['add'](_0x3798b4['get'](_0x1d5a37)['userId']),_0x5d6a29['set'](_0x2200f3,_0x40d1b8);}}_0x378b5d=_0x143e89['deletions'][_0x5562c4];for(const _0x20fca5 of _0x378b5d)if(_0x20fca5['item']['is']('element','tableCell')){const _0x5ded06=this['_getVidAttributeName'](_0x20fca5),_0x1842ea=_0x20fca5['item']['getAttribute'](_0x5ded06);if(_0x46670f['has'](_0x1842ea)){const _0x34e1ad=_0x20fca5['item']['parent']['parent']['getAttribute']('vid_start'),_0x5de7ab=_0x5d6a29['get'](_0x34e1ad)||new Set();_0x5de7ab['add'](_0x46670f['get'](_0x1842ea)['userId']),_0x5d6a29['set'](_0x34e1ad,_0x5de7ab);}}for(const _0x28a1ef of _0x5d6a29['keys']())(_0x3798b4['has'](_0x28a1ef)||_0x46670f['has'](_0x28a1ef))&&_0x5d6a29['delete'](_0x28a1ef);}for(const _0x50cea2 of _0x2f2993){const _0x396edc=_0x143e89['insertions'][_0x50cea2];let _0x5c3628=null,_0x1aff6f=null;for(const _0x119f96 of _0x396edc){const _0x4c6349=this['_getVidAttributeName'](_0x119f96),_0x2ce2d7=_0x119f96['item']['getAttribute'](_0x4c6349),_0x5bc010=_0x5d6a29['get'](_0x2ce2d7);_0x5bc010&&'elementStart'==_0x119f96['type']&&(_0x5c3628=Array['from'](_0x5bc010)[0x0],_0x1aff6f=_0x119f96['item']['getAttribute']('vid_end')),_0x5c3628&&(_0x46670f['set'](_0x2ce2d7,{'userId':_0x5c3628}),_0x3798b4['set'](_0x2ce2d7,{'userId':_0x5c3628})),_0x2ce2d7==_0x1aff6f&&(_0x5c3628=null,_0x1aff6f=null);}}const _0x5ca6ce={},_0x79e4e4=new Set();for(const _0x265ff5 of _0x2f2993){const _0x4e83f2=_0x12ac6f['deletions'][_0x265ff5],_0x2ee800=_0x12ac6f['insertions'][_0x265ff5];for(const {userId:_0x22c1b1}of this['_touchedMarkers']['values']())null!==_0x22c1b1&&_0x79e4e4['add'](_0x22c1b1);for(const {userId:_0x3ea17a}of this['_touchedRoots']['values']())null!==_0x3ea17a&&_0x79e4e4['add'](_0x3ea17a);this['_markChanges'](_0x2ee800,_0x143e89['insertions'][_0x265ff5],_0x3798b4,'insertion',_0x79e4e4),this['_markChanges'](_0x4e83f2,_0x143e89['deletions'][_0x265ff5],_0x46670f,'deletion',_0x79e4e4),_0x5ca6ce[_0x265ff5]={'insertions':this['_prepareViewToSave'](_0x2ee800),'deletions':this['_prepareViewToSave'](_0x4e83f2),'attachChange':this['_touchedRoots']['get'](_0x265ff5)||null,'attributesBefore':_0x295472(this['_baseRootsAttributes']['get'](_0x265ff5))||{},'attributesAfter':_0x295472(this['_diffRootsAttributes']['get'](_0x265ff5))};}return{'diffData':_0x5ca6ce,'authorsIds':Array['from'](_0x79e4e4)};}['_processRootBeforeSave'](_0x19f406){for(const [,_0x5f1473]of _0x19f406['markers']){const _0x47ff96=_0x5f1473['start']['getAncestors']()['filter'](_0x49bb5d=>'tableCell'==_0x49bb5d['name']);for(const _0x291458 of _0x47ff96)0x1==_0x291458['childCount']&&_0x291458['getChild'](0x0)['is']('element','paragraph')&&_0x291458['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2add00){this['_processRootBeforeSave'](_0x2add00);const _0x299e8f=this['editor']['data']['toView'](_0x2add00,{}),_0x29eada=Array['from'](_0x299e8f['getChildren']())['map'](_0x2dc3ad=>this['_getViewJson'](_0x2dc3ad));return JSON['stringify'](_0x29eada);}['_getViewJson'](_0x14899e){if(_0x14899e['is']('$text'))return _0x14899e['data'];{const _0x421e12=_0x14899e;return{'type':Object['keys'](C)['find'](_0x2512f5=>_0x14899e instanceof C[_0x2512f5]),'name':_0x421e12['name'],'attributes':Array['from'](_0x421e12['getAttributes']()),'children':Array['from'](_0x421e12['getChildren']())['map'](_0x73a231=>this['_getViewJson'](_0x73a231))};}}['_markChanges'](_0x3990d6,_0x58b58a,_0xbb3167,_0x5df67f,_0x224bbe){let _0x406aa4=null,_0xe685d4=null,_0x3be966=0x0;const _0x18592c=this['editor']['model'];for(let _0x5d7a97=0x0;_0x5d7a97<_0x58b58a['length'];_0x5d7a97++){const _0x405fec=this['_getVidAttributeName'](_0x58b58a[_0x5d7a97]),_0x2cc560=_0x58b58a[_0x5d7a97]['item']['getAttribute'](_0x405fec),_0x5c010d=_0xbb3167['get'](_0x2cc560),_0x4bf5d7=_0x5d7a97==_0x58b58a['length']-0x1;(!_0x406aa4&&_0x5c010d&&(_0x406aa4=_0x5c010d,_0xe685d4=_0x58b58a[_0x5d7a97]),_0x406aa4&&(!_0x5c010d||_0x5c010d['userId']!=_0x406aa4['userId']))&&(_0x1eb6ba(_0x5c010d,J(_0xe685d4,_0x3990d6,_0x18592c),J(_0x58b58a[_0x5d7a97],_0x3990d6,_0x18592c)),_0x406aa4=_0x5c010d||null,_0xe685d4=_0x5c010d?_0x58b58a[_0x5d7a97]:null),_0x406aa4&&_0x4bf5d7&&_0x1eb6ba(_0x5c010d,J(_0xe685d4,_0x3990d6,_0x18592c),q(_0x58b58a[_0x5d7a97],_0x3990d6,_0x18592c));}function _0x1eb6ba(_0x10d366,_0x1dcf7f,_0x5778d5){const _0x9e9607=_0x406aa4['userId'],_0x12301c='revision:'+_0x5df67f+':'+_0x9e9607+':'+_0x3be966++,_0x370d83=_0x18592c['createRange'](_0x1dcf7f,_0x5778d5);_0x3990d6['markers']['set'](_0x12301c,_0x370d83),null!==_0x9e9607&&_0x224bbe['add'](_0x9e9607);}}['_getVidAttributeName'](_0x2624d5){switch(_0x2624d5['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1c31dd,_0x55ae2d){_0x1c31dd['baseVersion']=null;for(const _0x2650a0 in _0x1c31dd){const _0xfe793c=_0x1c31dd[_0x2650a0];if(_0xfe793c instanceof gt){const _0x1038d7=_0x55ae2d['get'](_0xfe793c['root']['rootName']);_0x1c31dd[_0x2650a0]=this['_fixPosition'](_0xfe793c,_0x1038d7);}if(_0xfe793c instanceof vt){const _0x2b143b=_0x55ae2d['get'](_0xfe793c['root']['rootName']);_0x1c31dd[_0x2650a0]=this['_fixRange'](_0xfe793c,_0x2b143b);}'root'===_0x2650a0&&(_0x1c31dd['root']=_0x55ae2d['get'](_0x1c31dd['root']['rootName']));}}['_fixRange'](_0x1394e4,_0x317ff7){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1394e4['start'],_0x317ff7),this['_fixPosition'](_0x1394e4['end'],_0x317ff7));}['_fixPosition'](_0x3d2c5b,_0x1d43b0){return this['editor']['model']['createPositionFromPath'](_0x1d43b0,_0x3d2c5b['path'],_0x3d2c5b['stickiness']);}['_handleInsertOperation'](_0x59256a){const _0x37dd52=this['_idsRoots']['get'](_0x59256a['position']['root']['rootName']),_0x18aa61=this['_fixPosition'](_0x59256a['position'],_0x37dd52),_0x59ea7d=null===_0x59256a['_authorId']?null:_0x59256a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3d06bf=_0x18aa61['parent'],_0xd207b6=this['_revisionId'],_0x5ac66c=[];for(const _0x287382 of _0x59256a['nodes'])if(_0x287382['is']('element'))_0x5ac66c['push'](this['_makeIdsRoot'](_0x287382));else{for(let _0x35968f=0x0;_0x35968f<_0x287382['offsetSize'];_0x35968f++)_0x5ac66c['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x382b39=this['_revisionId'];for(let _0x45d6c5=_0xd207b6;_0x45d6c5<_0x382b39;_0x45d6c5++)this['_touched']['set'](_0x45d6c5,{'userId':_0x59ea7d});_0x3d06bf['_insertChild'](_0x18aa61['offset'],_0x5ac66c);}['_handleMoveOperation'](_0x192e87){(_0x192e87=this['_cloneOperation'](_0x192e87,this['_idsRoots']))['_execute']();const _0x409134=null===_0x192e87['_authorId']?null:_0x192e87['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1754ce=_0x192e87['getMovedRangeStart'](),_0xdc582c=_0x1754ce['parent'],_0x51212e=_0x1754ce['offset'];!function _0x1e3518(_0x255c5c,_0x467b8c,_0x498460,_0x50a4dd){for(let _0x12a31d=_0x498460;_0x12a31d<_0x50a4dd;_0x12a31d++){const _0x100e4b=_0x467b8c['getChild'](_0x12a31d);_0x100e4b['is']('element','$text')?_0x255c5c['set'](_0x100e4b['getAttribute']('vid'),{'userId':_0x409134}):(_0x255c5c['set'](_0x100e4b['getAttribute']('vid_start'),{'userId':_0x409134}),_0x1e3518(_0x255c5c,_0x100e4b,0x0,_0x100e4b['childCount']),_0x255c5c['set'](_0x100e4b['getAttribute']('vid_end'),{'userId':_0x409134}));}}(this['_touched'],_0xdc582c,_0x51212e,_0x51212e+_0x192e87['howMany']);}['_handleMergeOperation'](_0x2c441e){const _0x31380c=null===(_0x2c441e=this['_cloneOperation'](_0x2c441e,this['_idsRoots']))['_authorId']?null:_0x2c441e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x251d38=_0x2c441e['targetPosition']['parent'],_0x3510d0=_0x2c441e['sourcePosition']['parent'],_0xe0a236=_0x251d38['getAttribute']('vid_end'),_0x249217=_0x3510d0['getAttribute']('vid_start');_0x251d38['_setAttribute']('vid_end',_0x3510d0['getAttribute']('vid_end')),_0x3510d0['_setAttribute']('vid_end',_0xe0a236),this['_touched']['set'](_0x249217,{'userId':_0x31380c}),this['_touched']['set'](_0xe0a236,{'userId':_0x31380c}),_0x2c441e['_execute']();}['_handleSplitOperation'](_0x1b0239){const _0x27d995=null===(_0x1b0239=this['_cloneOperation'](_0x1b0239,this['_idsRoots']))['_authorId']?null:_0x1b0239['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x28caa6=_0x1b0239['graveyardPosition'],_0x39f2e3=_0x1b0239['splitPosition']['parent'];_0x1b0239['_execute']();const _0x44e156=_0x39f2e3['getAttribute']('vid_end'),_0x3ffe2c=_0x1b0239['insertionPosition']['nodeAfter'];if(_0x28caa6){const _0x435ac6=_0x3ffe2c['getAttribute']('vid_end'),_0x3cfebe=_0x39f2e3['getAttribute']('vid_end');_0x39f2e3['_setAttribute']('vid_end',_0x435ac6),_0x3ffe2c['_setAttribute']('vid_end',_0x3cfebe),this['_touched']['set'](_0x39f2e3['getAttribute']('vid_end'),{'userId':_0x27d995}),this['_touched']['set'](_0x3ffe2c['getAttribute']('vid_start'),{'userId':_0x27d995});}else{const _0x29dab3=this['_revisionId']++,_0x4b89ce=this['_revisionId']++;_0x39f2e3['_setAttribute']('vid_end',_0x29dab3),_0x3ffe2c['_setAttribute']('vid_start',_0x4b89ce),_0x3ffe2c['_setAttribute']('vid_end',_0x44e156),this['_touched']['set'](_0x29dab3,{'userId':_0x27d995}),this['_touched']['set'](_0x4b89ce,{'userId':_0x27d995});}}['_handleMarkerOperation'](_0x2a2564){if(!_0x2a2564['affectsData'])return;const _0x3998da=(_0x2a2564=this['_cloneOperation'](_0x2a2564,this['_diffRoots']))['oldRange']?_0x2a2564['oldRange']['root']:null,_0x3b1bf4=_0x2a2564['newRange']?_0x2a2564['newRange']['root']:null;_0x3998da&&this['_markers']['delete'](_0x2a2564['name']),_0x3b1bf4&&this['_markers']['set'](_0x2a2564['name'],_0x2a2564['newRange']['clone']());const _0x19ee5d=null===_0x2a2564['_authorId']?null:_0x2a2564['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x575309=_0x2a2564['name'];if(!this['_touchedMarkers']['has'](_0x575309))return void this['_touchedMarkers']['set'](_0x575309,{'range':_0x2a2564['oldRange'],'userId':_0x19ee5d});const _0x3ef388=this['_touchedMarkers']['get'](_0x575309),_0x587342=_0x3ef388['range'],_0xc390fa=_0x2a2564['newRange'];null==_0x587342&&null==_0xc390fa||_0x587342&&_0xc390fa&&_0x587342['isEqual'](_0xc390fa)?this['_touchedMarkers']['delete'](_0x2a2564['name']):_0x3ef388['userId']=_0x19ee5d;}['_handleRootOperation'](_0x408399,_0x43ec6c){this['_diffRoots']['has'](_0x408399['rootName'])?this['_diffRoots']['get'](_0x408399['rootName'])['_isAttached']=_0x408399['isAdd']:(this['_diffRoots']['set'](_0x408399['rootName'],B(_0x408399['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x408399['rootName'],{}),_0x43ec6c&&this['_idsRoots']['set'](_0x408399['rootName'],B(_0x408399['rootName'],!0x0)));const _0x17c5d9=null===_0x408399['_authorId']?null:_0x408399['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x762f70=this['_touchedRoots']['get'](_0x408399['rootName']);_0x762f70&&_0x762f70['userId']===_0x17c5d9?this['_touchedRoots']['delete'](_0x408399['rootName']):this['_touchedRoots']['set'](_0x408399['rootName'],{'userId':_0x17c5d9,'isAttached':_0x408399['isAdd']});}['_handleRootAttributeOperation'](_0x847968){const _0x162c93=this['_diffRootsAttributes']['get'](_0x847968['root']['rootName']);null===_0x847968['newValue']?delete _0x162c93[_0x847968['key']]:_0x162c93[_0x847968['key']]=_0x847968['newValue'];}}function F(_0x51e79c){const _0x3081c5=B(_0x51e79c['rootName'],_0x51e79c['isAttached']());for(const _0x587a1b of _0x51e79c['getChildren']()){const _0x3e10aa=_0x587a1b['_clone'](!0x0);_0x3081c5['_appendChild'](_0x3e10aa);}return _0x3081c5;}function B(_0x1290c2,_0x6e1acf=!0x0){const _0x19edfd=new wt();return _0x19edfd['rootName']=_0x1290c2,_0x19edfd['_isAttached']=_0x6e1acf,_0x19edfd['isAttached']=()=>_0x19edfd['_isAttached'],_0x19edfd;}function J(_0xa7ba6,_0x5ceb4e,_0x186ed5){const _0x2ac71a='elementEnd'==_0xa7ba6['type']?_0x186ed5['createPositionAt'](_0xa7ba6['item'],'end'):_0x186ed5['createPositionBefore'](_0xa7ba6['item']);return _0x186ed5['createPositionFromPath'](_0x5ceb4e,_0x2ac71a['path'],_0x2ac71a['stickiness']);}function q(_0x4b4325,_0x16126c,_0x29308d){const _0x2338ac='elementStart'==_0x4b4325['type']?_0x29308d['createPositionAt'](_0x4b4325['item'],0x0):_0x29308d['createPositionAfter'](_0x4b4325['item']);return _0x29308d['createPositionFromPath'](_0x16126c,_0x2338ac['path'],_0x2338ac['stickiness']);}class ns extends _0x2c43c9{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x509ee3,_0x48cbbe){super(_0x509ee3),this['focusTracker']=new _0x5cf0e0(),this['keystrokes']=new _0x3a2814(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x48cbbe),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'](),_0x5b1924({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xdd905d=_0x118df9=>_0x118df9['stopPropagation']();this['keystrokes']['set']('arrowright',_0xdd905d),this['keystrokes']['set']('arrowleft',_0xdd905d),this['keystrokes']['set']('arrowup',_0xdd905d),this['keystrokes']['set']('arrowdown',_0xdd905d);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x36a197){this['revisionNameInputView']['fieldView']['element']['value']=_0x36a197['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4cc47d){const _0x4bb1dc=new at(this['locale'],_0x4fabfa),_0x196073=_0x4bb1dc['fieldView'];_0x196073['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x20564a=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4cc47d&&(_0x20564a+='\x20('+R(this['locale'],'optional')+')'),(_0x4bb1dc['label']=_0x20564a,_0x196073['on']('input',()=>{this['revisionNameInputValue']=_0x196073['element']['value']['trim']();}),_0x4bb1dc);}}class u extends _0x24aabd{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x2b95b0=this['editor'],_0xbc630c=_0x2b95b0['plugins']['get']('RevisionTracker');_0x2b95b0['ui']['componentFactory']['add']('revisionHistory',_0x534a0a=>{const _0x212096=_0x20789c(_0x534a0a),_0xf81698=_0x212096['panelView']['children'],_0x41302d=new te(_0x534a0a),_0x4694db=new _0x4e494e(_0x534a0a),_0x20f1e6=new _0x15a92a(_0x534a0a),_0x3d873b=new _0x4e494e(_0x534a0a),_0x1fd945=new _0x15a92a(_0x534a0a);return _0x212096['bind']('isEnabled')['to'](_0xbc630c,'isReady',_0xbc630c,'isEnabled',_0x2b95b0,'isReadOnly',(_0x37081a,_0x9d7e75,_0x5e67b0)=>_0x37081a&&_0x9d7e75&&!_0x5e67b0),_0x212096['buttonView']['set']({'icon':_0x888a61['history'],'label':R(_0x534a0a,'Revision\x20history'),'tooltip':!0x0}),_0x20f1e6['set']({'label':R(_0x534a0a,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x20f1e6['bind']('isEnabled')['to'](_0xbc630c,'isReady',_0xbc630c,'isEnabled',_0x2b95b0,'isReadOnly',(_0x4fbefa,_0x1bedeb,_0x1100f8)=>_0x4fbefa&&_0x1bedeb&&!_0x1100f8),_0x20f1e6['on']('execute',()=>this['_showDialog']()),_0x1fd945['set']({'label':R(_0x534a0a,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1fd945['bind']('isEnabled')['to'](_0xbc630c,'isReady',_0x2b95b0,'isReadOnly',(_0x5a6635,_0x41be6c)=>_0x5a6635&&!_0x41be6c),_0x1fd945['on']('execute',()=>{_0x2b95b0['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x212096['isOpen']=!0x1,_0x2b95b0['editing']['view']['focus']();}),_0x4694db['children']['add'](_0x20f1e6),_0x3d873b['children']['add'](_0x1fd945),_0x41302d['role']='menu',_0x41302d['items']['addMany']([_0x4694db,_0x3d873b]),_0xf81698['add'](_0x41302d),_0x212096;}),_0x2b95b0['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x32c57f=this['editor'],_0x5ce71d=_0x32c57f['locale'],_0x446330=new _0x5320cf(_0x5ce71d),_0x48597e=new _0xae8b9(_0x5ce71d);_0x446330['buttonView']['set']({'icon':_0x888a61['history'],'label':R(_0x5ce71d,'Revision\x20history')});const _0x32273a=new _0x414113(_0x5ce71d,_0x446330),_0x50b1a6=new _0x1ea6c3(_0x5ce71d);_0x50b1a6['set']({'label':R(_0x5ce71d,'Save\x20current\x20revision')}),_0x50b1a6['delegate']('execute')['to'](_0x446330),_0x50b1a6['on']('execute',()=>{this['_showDialog']();}),_0x32273a['children']['add'](_0x50b1a6),_0x48597e['items']['add'](_0x32273a);const _0x1f2674=new _0x414113(_0x5ce71d,_0x446330),_0x166ed1=new _0x1ea6c3(_0x5ce71d);return _0x166ed1['set']({'label':R(_0x5ce71d,'Open\x20revision\x20history')}),_0x166ed1['delegate']('execute')['to'](_0x446330),_0x166ed1['on']('execute',()=>{_0x32c57f['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x1f2674['children']['add'](_0x166ed1),_0x48597e['items']['add'](_0x1f2674),_0x446330['panelView']['children']['add'](_0x48597e),_0x446330;}['_showDialog'](){const _0x25e441=this['editor'],_0x5014bb=_0x25e441['locale'],_0x239a38=_0x25e441['plugins']['get']('Dialog'),_0x45d2f8=_0x25e441['plugins']['get']('RevisionTracker');function _0x4c32af(_0x41dbfc){_0x25e441['config']['get']('revisionHistory.requireRevisionName')&&''===_0x41dbfc['revisionName']?_0x41dbfc['revisionNameInputView']['errorText']=R(_0x5014bb,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x25e441['plugins']['get'](l)['saveRevision']({'name':_0x41dbfc['revisionName']}),_0x239a38['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4c32af(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x239a38['show']({'id':'revisionSave','title':R(_0x5014bb,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x25e441['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x239a38['hide']()},{'label':R(_0x25e441['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xcc2988){_0xcc2988['bind']('isEnabled')['to'](_0x45d2f8,'isReady',_0x45d2f8,'isEnabled',_0x25e441,'isReadOnly',(_0x1be6e2,_0x9320dd,_0x2a09ff)=>_0x1be6e2&&_0x9320dd&&!_0x2a09ff);},'onExecute':()=>_0x4c32af(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x2e050e=this['editor'],_0x422836=_0x2e050e['locale'];this['_saveRevisionFormView']=new ns(_0x422836,_0x2e050e['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends _0x2c43c9{['changeId'];['_model'];constructor(_0x5cbbeb,_0x5ef592){super(_0x5cbbeb),this['_model']=_0x5ef592,this['changeId']=_0x5ef592['id'];const _0x5d40d0=this['bindTemplate'],_0x355751=R(_0x5cbbeb,_0x5ef592['data']['isSuggestion']?'Suggested\x20by':'add'==_0x5ef592['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x5ef592['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x5d40d0['to']('type',_0x517949=>'ck-revision-change__'+_0x517949)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x355751}]},{'text':'\x20'+_0x5ef592['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x5c7d88(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x292ad7){super(),this['id']=_0x292ad7['id']||_0x4dce4d(),this['author']=_0x292ad7['author'],this['type']=_0x292ad7['type'],this['data']=_0x292ad7['data']||{},this['rootName']=_0x292ad7['rootName'],this['set']('createdAt',_0x292ad7['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(_0x2afd34,_0x1590ae){this['newRevisionId']=_0x2afd34,this['oldRevisionId']=_0x1590ae,this['changes']=new _0x2ad968();}['_setChanges'](_0x56a35c){for(const _0xcae32c of _0x56a35c)this['changes']['add'](_0xcae32c);}}const Z={'c':_0x23c6b9,'a':_0x3e4e99,'e':_0x46de0e,'r':_0xcf47a2,'u':_0x131e84};class d extends _0x24aabd{['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[_0x4943c5,_0x276f8f,j];}constructor(_0x3e28e3){super(_0x3e28e3),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',(_0x234696,_0x927a59,_0x4ccb61)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xa2dbe0=>{for(const _0x36b414 of this['editor']['editing']['view']['document']['roots'])_0x4ccb61?_0xa2dbe0['removeClass']('ck-editor__editable__overlay',_0x36b414):_0xa2dbe0['addClass']('ck-editor__editable__overlay',_0x36b414);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x51ee7a=>null!==_0x51ee7a),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x16ef7f,_0x3b8007,_0x331292)=>_0x16ef7f&&_0x331292?_0x3b8007['changes']['getIndex'](_0x331292):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x4fd678,_0x574be7)=>_0x4fd678?_0x574be7['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x276f8f);}['init'](){const _0x277f92=this['editor'],_0x4e5aee=new bt(_0x277f92,{'direction':'backward'}),_0xb84a9a=new bt(_0x277f92,{'direction':'forward'});(_0x277f92['commands']['add']('showPreviousChange',_0x4e5aee),_0x277f92['commands']['add']('showNextChange',_0xb84a9a),_0x277f92['commands']['add']('restoreRevision',new yt(_0x277f92)),this['on']('change:numberOfChanges',()=>{_0x4e5aee['refresh'](),_0xb84a9a['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x277f92['enableReadOnlyMode']('revision-viewer'),_0x277f92['plugins']['has']('WidgetToolbarRepository'))&&_0x277f92['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x3019e2){await this['loadRevisionData'](_0x3019e2);const _0x49eeb3={};for(const _0x42f227 in _0x3019e2['diffData']){if(_0x3019e2['diffData'][_0x42f227]['attachChange']&&!_0x3019e2['diffData'][_0x42f227]['attachChange']['isAttached'])continue;const _0x54bc17=this['_removeRevisionMarkers'](JSON['parse'](_0x3019e2['diffData'][_0x42f227]['insertions'])),_0x489995=this['editor']['editing']['view']['document'],_0x204556=new _0x4833c1(_0x489995,_0x54bc17['map'](_0x1aaa78=>this['_getViewObj'](_0x1aaa78)));this['editor']['data']['processor']['useFillerType']('marked'),_0x49eeb3[_0x42f227]=this['editor']['data']['processor']['toData'](_0x204556),this['editor']['data']['processor']['useFillerType']('default');}return _0x49eeb3;}async['getRevisionRootsAttributes'](_0x28776f){await this['loadRevisionData'](_0x28776f);const _0x427492={};for(const _0x43174d in _0x28776f['diffData'])_0x28776f['diffData'][_0x43174d]['attachChange']&&!_0x28776f['diffData'][_0x43174d]['attachChange']['isAttached']||(_0x427492[_0x43174d]=_0x28776f['diffData'][_0x43174d]['attributesAfter']||{});return _0x427492;}['_removeRevisionMarkers'](_0x1738cd){return(_0x1738cd=_0x1738cd['filter'](_0x3bd105=>!_0x3bd105['name']||'revision-start'!==_0x3bd105['name']&&'revision-end'!==_0x3bd105['name']))['forEach'](_0x26b757=>{'string'!=typeof _0x26b757&&(_0x26b757['children']=this['_removeRevisionMarkers'](_0x26b757['children']),_0x26b757['attributes']=_0x26b757['attributes']['filter'](_0x41dcc4=>!_0x41dcc4[0x0]['startsWith']('data-revision-')));}),_0x1738cd;}async['compare'](_0x1bf94e,_0xd3e591,_0x4329c8=!0x1){if(!this['isEnabled'])return;const _0x481aa7=this['diff'],_0x2be1f0=this['repository'],_0x576362='string'==typeof _0x1bf94e?_0x2be1f0['getRevision'](_0x1bf94e):_0x1bf94e,_0x2cb11a='string'==typeof _0xd3e591?_0x2be1f0['getRevision'](_0xd3e591):_0xd3e591,_0x5d6e1c=_0x576362['id'],_0x5a0be9=_0x2cb11a?_0x2cb11a['id']:null;if(!_0x4329c8&&this['diff']&&this['diff']['newRevisionId']===_0x5d6e1c&&this['diff']['oldRevisionId']===_0x5a0be9)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x5d6e1c,_0x5a0be9);const _0x264e5f=this['_getRevisionsRange'](_0x576362,_0x2cb11a,!0x0)['map'](_0x431fe0=>this['loadRevisionData'](_0x431fe0));return _0x264e5f['push'](new Promise(_0x4eea36=>{setTimeout(_0x4eea36,0x14);})),Promise['all'](_0x264e5f)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x7be1c9=this['_getDiff'](_0x5d6e1c,_0x5a0be9);for(const _0x54b90a of _0x7be1c9['changes'])this['_changeIdToChange']['set'](_0x54b90a['id'],_0x54b90a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x198a9d=>{for(const _0xcabfb of this['editor']['model']['document']['getRootNames']())_0x198a9d['detachRoot'](_0xcabfb);for(const _0xa434f0 of Object['keys'](_0x7be1c9['model'])){const _0x44faee=_0x198a9d['addRoot'](_0xa434f0);for(const _0x57475d of Object['keys'](_0x7be1c9['attributes'][_0xa434f0]))_0x198a9d['setAttribute'](_0x57475d,_0x7be1c9['attributes'][_0xa434f0][_0x57475d],_0x44faee);_0x198a9d['insert'](_0x7be1c9['model'][_0xa434f0],_0x44faee,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x7be1c9['changes'])),this['isReady']=!0x0;})['catch'](_0x498f6a=>{console['error'](_0x498f6a),this['_cleanUp'](),_0x481aa7&&(this['diff']=_0x481aa7),this['isReady']=!0x0;});}['addRevisionData'](_0x9aa945,_0x20abdb){const _0x382283=this['repository']['createRevision'](_0x9aa945);return _0x382283['on']('_update',(_0x56c4eb,_0x96a66b,_0x3d693c)=>_0x20abdb(_0x96a66b,_0x3d693c,_0x382283)),this['repository']['addRevision'](_0x382283),_0x382283;}['loadRevisionData'](_0x42947b){if(!_0x42947b||_0x42947b['diffData'])return Promise['resolve']();{const _0x28b187=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x28b187,'revisionId':_0x42947b['id']})['then'](_0x301714=>{_0x42947b['_update']({'diffData':_0x301714['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},_0x2bbe6d=>{for(const _0x37800d of this['editor']['model']['document']['getRootNames']())_0x2bbe6d['detachRoot'](_0x37800d);});}['_sortAndFilterDiffChanges'](_0x297f2){const _0x10125c=[],_0x3915d6=new Map();for(const _0x55c1a2 of this['editor']['model']['document']['getRootNames']()){const _0x5bcf50=this['editor']['editing']['view']['getDomRoot'](_0x55c1a2);if(!_0x5bcf50)continue;const _0x3be814=_0x5bcf50['getClientRects']()['item'](0x0);_0x3be814&&(_0x10125c['push'](_0x55c1a2),_0x3915d6['set'](_0x55c1a2,_0x3be814));}return _0x10125c['sort']((_0x3f811a,_0x3a5c11)=>{const _0x242912=_0x3915d6['get'](_0x3f811a),_0x5b7361=_0x3915d6['get'](_0x3a5c11);return _0x242912['y']-_0x5b7361['y']||_0x242912['x']-_0x5b7361['x'];}),(_0x297f2=_0x297f2['filter'](_0x187d0a=>_0x10125c['includes'](_0x187d0a['rootName'])))['sort']((_0x3d2702,_0x3d5aad)=>_0x10125c['indexOf'](_0x3d2702['rootName'])-_0x10125c['indexOf'](_0x3d5aad['rootName'])),_0x297f2;}['_makeTape'](_0xfcda5){const _0x333295=Array['from'](_0xfcda5['markers'])['filter'](([_0x185ba5,_0x46036c])=>_0x185ba5['startsWith']('revision:')&&!_0x46036c['isCollapsed']),_0x474f31=Array['from'](this['editor']['model']['createRangeIn'](_0xfcda5)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x333295['length'])for(const _0x1d3b4b of _0x474f31){const [_0x47232e,_0x40a640]=_0x333295[0x0],[,_0x4d6ffa,_0x2bc427]=_0x47232e['split'](':');if(_0x40a640['end']['isEqual'](_0x1d3b4b['nextPosition'])&&_0x333295['shift'](),(_0x1d3b4b['previousPosition']['isEqual'](_0x40a640['start'])||_0x1d3b4b['previousPosition']['isAfter'](_0x40a640['start']))&&('insertion'==_0x4d6ffa?_0x1d3b4b['isAdded']={'userId':_0x2bc427}:'deletion'==_0x4d6ffa&&(_0x1d3b4b['isRemoved']={'userId':_0x2bc427})),0x0==_0x333295['length'])break;}return _0x474f31;}['_refreshStartEndIndex'](_0x2ff1d0){const _0xa5cb1=new Map();for(let _0x126803=0x0;_0x126803<_0x2ff1d0['length'];_0x126803++)'text'===_0x2ff1d0[_0x126803]['type']?(_0x2ff1d0[_0x126803]['item']['startIndex']=_0x126803,_0x2ff1d0[_0x126803]['item']['endIndex']=_0x126803):('elementStart'===_0x2ff1d0[_0x126803]['type']?_0x2ff1d0[_0x126803]['item']['startIndex']=_0x126803:'elementEnd'===_0x2ff1d0[_0x126803]['type']&&(_0x2ff1d0[_0x126803]['item']['endIndex']=_0x126803),_0xa5cb1['set'](_0x2ff1d0[_0x126803]['id'],_0x126803));for(const _0x3fd35a of _0xa5cb1['values']())'elementStart'===_0x2ff1d0[_0x3fd35a]['type']?_0x2ff1d0[_0x3fd35a]['item']['endIndex']=_0xa5cb1['get'](_0x2ff1d0[_0x3fd35a]['pairId']):'elementEnd'===_0x2ff1d0[_0x3fd35a]['type']&&(_0x2ff1d0[_0x3fd35a]['item']['startIndex']=_0xa5cb1['get'](_0x2ff1d0[_0x3fd35a]['pairId']));}['_processTape'](_0x354f61){for(let _0x261b6a=0x0;_0x261b6a<_0x354f61['length'];_0x261b6a++){if('elementStart'===_0x354f61[_0x261b6a]['type'])_0x354f61[_0x261b6a]['item']['startIndex']=_0x261b6a;else{if('elementEnd'===_0x354f61[_0x261b6a]['type']){_0x354f61[_0x261b6a]['item']['endIndex']=_0x261b6a;const _0x28b58b=_0x354f61[_0x261b6a]['item']['startIndex'];_0x354f61[_0x28b58b]['pairId']=_0x354f61[_0x261b6a]['id'],_0x354f61[_0x261b6a]['pairId']=_0x354f61[_0x28b58b]['id'];}else _0x354f61[_0x261b6a]['item']['startIndex']=_0x261b6a,_0x354f61[_0x261b6a]['item']['endIndex']=_0x261b6a,_0x354f61[_0x261b6a]['pairId']=null;}_0x354f61[_0x261b6a]['markersStart']||(_0x354f61[_0x261b6a]['markersStart']=[],_0x354f61[_0x261b6a]['markersEnd']=[]);}}['_markInsertions'](_0x598f08,_0x43e6c5){const _0x296cab=_0x598f08['filter'](_0x1fccb3=>!_0x1fccb3['isAdded']);for(let _0x5e87c7=0x0;_0x5e87c7<_0x43e6c5['length'];_0x5e87c7++)_0x43e6c5[_0x5e87c7]['isAdded']&&(_0x296cab[_0x5e87c7]['isAdded']=_0x43e6c5[_0x5e87c7]['isAdded']);}['_makeModelFromViewString'](_0x7e8d2e){const _0x283a5f=JSON['parse'](_0x7e8d2e),_0xf75380=this['editor']['editing']['view']['document'],_0x42811a=new _0x4833c1(_0xf75380,_0x283a5f['map'](_0x427313=>this['_getViewObj'](_0x427313)));return this['editor']['data']['toModel'](_0x42811a);}['_getViewObj'](_0x4cc5a5){const _0x3b2f53=this['editor']['editing']['view']['document'];if('string'==typeof _0x4cc5a5)return new _0xd57083(_0x3b2f53,_0x4cc5a5);{const _0x5d64a6=_0x4cc5a5['children']['map'](_0x1bbedf=>this['_getViewObj'](_0x1bbedf));return new(Z[_0x4cc5a5['type']]||_0x2c4196)(_0x3b2f53,_0x4cc5a5['name'],_0x4cc5a5['attributes'],_0x5d64a6);}}['_getDiff'](_0x18c7dc,_0x439e9b=null){const _0x1beb89=this['repository']['getRevision'](_0x18c7dc),_0x27872b=_0x439e9b?this['repository']['getRevision'](_0x439e9b):null,_0x3dbdd2=this['_getRevisionsRange'](_0x1beb89,_0x27872b),_0x499c2b=_0x3dbdd2[_0x3dbdd2['length']-0x1],_0x3ad2c6=new Map(),_0x16af63={'model':{},'attributes':{},'changes':[]},_0x578150=new Set(),_0x2387b8=new Map();for(let _0x28b50a=_0x3dbdd2['length']-0x1;_0x28b50a>=0x0;_0x28b50a--){const _0x19b842=_0x3dbdd2[_0x28b50a];for(const _0x579c8c of Object['keys'](_0x19b842['diffData']))if(_0x19b842['diffData'][_0x579c8c]['attachChange']){const _0x24bf2e=_0x19b842['diffData'][_0x579c8c]['attachChange'];_0x24bf2e['isAttached']?(_0x578150['add'](_0x579c8c),_0x2387b8['has'](_0x579c8c)&&_0x2387b8['get'](_0x579c8c)['userId']==_0x24bf2e['userId']?_0x2387b8['delete'](_0x579c8c):_0x2387b8['set'](_0x579c8c,_0x24bf2e)):_0x2387b8['has'](_0x579c8c)?(_0x578150['delete'](_0x579c8c),_0x2387b8['delete'](_0x579c8c)):(_0x578150['add'](_0x579c8c),_0x2387b8['set'](_0x579c8c,_0x24bf2e));}else _0x578150['add'](_0x579c8c);}for(const _0x17f8b2 of _0x578150){const _0x3956d0=_0x2387b8['has'](_0x17f8b2)&&!_0x2387b8['get'](_0x17f8b2)['isAttached'];let _0x1ebb8d=_0x3956d0?_0x3dbdd2['length']-0x1:0x0;const _0x467f8c=_0x3956d0?-0x1:0x1;for(;_0x3dbdd2[_0x1ebb8d];){const _0x2a917f=_0x3dbdd2[_0x1ebb8d];if(_0x2a917f['diffData'][_0x17f8b2]){const _0x3e87a9=_0x3956d0?_0x2a917f['diffData'][_0x17f8b2]['attributesBefore']:_0x2a917f['diffData'][_0x17f8b2]['attributesAfter'];_0x16af63['attributes'][_0x17f8b2]=_0x3e87a9?_0x295472(_0x3e87a9):{};break;}_0x1ebb8d+=_0x467f8c;}}for(const _0x3bdb87 of _0x3dbdd2){_0x3bdb87['model']={};for(const _0x4bd6c2 of _0x3bdb87['authors'])_0x3ad2c6['set'](_0x4bd6c2['id'],_0x4bd6c2);for(const _0x544f46 of _0x578150){const _0x2c7004=_0x3bdb87['diffData'][_0x544f46]?_0x3bdb87['diffData'][_0x544f46]['insertions']:'[]',_0x483aac=_0x3bdb87['diffData'][_0x544f46]?_0x3bdb87['diffData'][_0x544f46]['deletions']:'[]';_0x3bdb87['model'][_0x544f46]={'insertions':this['_makeModelFromViewString'](_0x2c7004),'deletions':this['_makeModelFromViewString'](_0x483aac)};}}for(const _0x5d1d87 of _0x578150){let _0x427d9b=null,_0x74499a=0x0;const _0x4202f5=new Map(Array['from'](_0x1beb89['model'][_0x5d1d87]['insertions']['markers'])['filter'](([_0x328df5])=>!_0x328df5['startsWith']('revision:')));let _0x50b348=0x0;for(const _0x259823 of _0x3dbdd2){const _0x198d6f=this['_makeTape'](_0x259823['model'][_0x5d1d87]['insertions']);_0x259823==_0x1beb89?(_0x427d9b=_0x198d6f,_0x74499a=_0x427d9b['length'],_0x427d9b['forEach'](_0x508e01=>{_0x508e01['id']=_0x50b348++;}),this['_processTape'](_0x427d9b)):this['_markInsertions'](_0x427d9b,_0x198d6f);const _0x3ef541=_0x427d9b['filter'](_0x3d4985=>!_0x3d4985['isAdded'])['map'](_0x5030f9=>_0x5030f9['id']);let _0x589642=0x0;const _0x58790c=this['_makeTape'](_0x259823['model'][_0x5d1d87]['deletions']);_0x58790c['forEach'](_0x41d4cb=>{_0x41d4cb['isRemoved']?_0x41d4cb['id']=_0x74499a++:_0x41d4cb['id']=_0x3ef541[_0x589642++];}),this['_processTape'](_0x58790c),this['_setDistance'](_0x427d9b,'isAdded'),this['_setDistance'](_0x58790c,'isRemoved'),_0x259823==_0x1beb89&&this['_markMarkers'](_0x427d9b,_0x4202f5),_0x427d9b=this['_joinTapes'](_0x427d9b,_0x58790c),this['_refreshStartEndIndex'](_0x427d9b),this['_setDistance'](_0x427d9b,'isRemoved');}_0x427d9b=_0x427d9b['filter'](_0xce7c44=>!(_0xce7c44['isAdded']&&_0xce7c44['isRemoved']));const _0x19949b=new Map(_0x499c2b['model'][_0x5d1d87]['deletions']['markers']),_0x19dd8e=new Set(_0x4202f5['keys']());for(const _0x459230 of _0x19949b['keys']())_0x19dd8e['delete'](_0x459230);this['_markSuggestions'](_0x427d9b,_0x19dd8e),this['_fixObsoleteTags'](_0x427d9b),_0x427d9b=this['_removeMissingPairs'](_0x427d9b),_0x427d9b=this['_markMismatchedRemovedTags'](_0x427d9b),_0x427d9b=this['_removeUnsupportedChanges'](_0x427d9b);const {root:_0x212927,changes:_0x3a78aa}=this['_makeModelFromTape'](_0x427d9b,_0x3ad2c6,_0x5d1d87);_0x16af63['model'][_0x5d1d87]=_0x212927;const _0x3540e6=_0x2387b8['get'](_0x5d1d87);if(_0x3540e6){const _0x2b978a=_0x3ad2c6['get'](_0x3540e6['userId']),_0x1bc2bc=new r({'author':_0x2b978a,'type':_0x3540e6['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x5d1d87});_0x3a78aa['unshift'](_0x1bc2bc),_0x16af63['attributes'][_0x5d1d87]['revisionHistoryAttachChange']=_0x1bc2bc['id'];}_0x16af63['changes']=_0x16af63['changes']['concat'](_0x3a78aa);}return _0x16af63;}['_markMarkers'](_0x257b62,_0x2b768f){for(let _0x1d4892=0x0;_0x1d4892<_0x257b62['length'];_0x1d4892++)for(const [_0x50712c,_0x3b5094]of _0x2b768f)_0x3b5094['start']['isEqual'](_0x257b62[_0x1d4892]['previousPosition'])&&_0x257b62[_0x1d4892]['markersStart']['push'](_0x50712c),_0x3b5094['end']['isEqual'](_0x257b62[_0x1d4892]['nextPosition'])&&_0x257b62[_0x1d4892]['markersEnd']['push'](_0x50712c);}['_joinTapes'](_0x4d828d,_0x263598){let _0x564555=[],_0x32ca2e=0x0,_0x545e2a=0x0;for(;_0x32ca2e<_0x4d828d['length']||_0x545e2a<_0x263598['length'];){const _0x4011d4=_0x4d828d[_0x32ca2e]||{},_0x55d00e=_0x263598[_0x545e2a]||{};if(_0x4011d4['id']==_0x55d00e['id'])_0x32ca2e++,_0x545e2a++,_0x564555['push'](_0x4011d4);else{if(_0x55d00e['isRemoved']&&_0x4011d4['isAdded']){const {commonTape:_0x1fea78,iEnd:_0x2b3555,jEnd:_0x35795c}=this['_threeWayMerge'](_0x4d828d,_0x32ca2e,_0x263598,_0x545e2a);_0x564555=_0x564555['concat'](_0x1fea78),_0x32ca2e=_0x2b3555,_0x545e2a=_0x35795c;}else _0x55d00e['isRemoved']?(_0x545e2a++,_0x564555['push'](_0x55d00e)):(_0x32ca2e++,_0x564555['push'](_0x4011d4));}}return _0x564555;}['_markSuggestions'](_0x57bcaf,_0x4bd173){const _0x32cf2b=[];for(let _0x460be3=0x0;_0x460be3<_0x57bcaf['length'];_0x460be3++){for(let _0x3d4fa7=0x0;_0x3d4fa7<_0x57bcaf[_0x460be3]['markersStart']['length'];_0x3d4fa7++){const _0x563ec4=_0x57bcaf[_0x460be3]['markersStart'][_0x3d4fa7];if(!_0x4bd173['has'](_0x563ec4))continue;const {group:_0x5226b5,type:_0x53cb37,authorId:_0x2dd7c2}=_0x1d71f0(_0x563ec4);'revision-suggestion'!=_0x5226b5||'insertion'!=_0x53cb37&&'deletion'!=_0x53cb37||(_0x32cf2b['unshift']({'type':_0x53cb37,'name':_0x563ec4,'userId':_0x2dd7c2}),_0x57bcaf[_0x460be3]['markersStart']['splice'](_0x3d4fa7,0x1),_0x3d4fa7--);}_0x45504b(_0x57bcaf[_0x460be3]);for(let _0x18f018=0x0;_0x18f018<_0x57bcaf[_0x460be3]['markersEnd']['length'];_0x18f018++){const _0x526bdd=_0x57bcaf[_0x460be3]['markersEnd'][_0x18f018];if(!_0x4bd173['has'](_0x526bdd))continue;const {group:_0x5d4593,type:_0x144d85}=_0x1d71f0(_0x526bdd);if('revision-suggestion'!=_0x5d4593||'insertion'!=_0x144d85&&'deletion'!=_0x144d85)continue;_0x57bcaf[_0x460be3]['markersEnd']['splice'](_0x18f018,0x1),_0x18f018--;const _0x32fc79=_0x32cf2b['findIndex'](_0x562bb8=>_0x562bb8['name']==_0x526bdd);_0x32fc79>-0x1&&_0x32cf2b['splice'](_0x32fc79,0x1);}}function _0x1d71f0(_0x164c57){const _0x571db3=_0x164c57['split'](':');return{'group':_0x571db3[0x0],'type':_0x571db3[0x1],'subType':_0x571db3['length']>=0x5?_0x571db3[0x2]:null,'id':_0x571db3['length']<0x5?_0x571db3[0x2]:_0x571db3[0x3],'authorId':_0x571db3['length']<0x5?_0x571db3[0x3]:_0x571db3[0x4],'markerCount':0x6==_0x571db3['length']?_0x571db3[0x5]:null};}function _0x45504b(_0x2a3afb){for(let _0xbdb32e=0x0;_0xbdb32e<_0x32cf2b['length'];_0xbdb32e++){if(_0x2a3afb['isAdded']&&'insertion'==_0x32cf2b[_0xbdb32e]['type'])return _0x2a3afb['isAddSuggestion']=_0x32cf2b[_0xbdb32e],void delete _0x2a3afb['isAdded'];if(!_0x2a3afb['isAdded']&&!_0x2a3afb['isRemoved']&&'deletion'==_0x32cf2b[_0xbdb32e]['type'])return void(_0x2a3afb['isRemoveSuggestion']=_0x32cf2b[_0xbdb32e]);}}}['_setDistance'](_0x451955,_0x2bdbb7){let _0x1a066f=0x0,_0x52bcd2=!0x1;const _0x49ee95=new Map();for(const _0x4fe36a of _0x451955)_0x4fe36a[_0x2bdbb7]?_0x52bcd2&&(_0x1a066f++,_0x52bcd2=!0x1):(_0x1a066f++,_0x52bcd2=!0x0),_0x49ee95['set'](_0x4fe36a['id'],_0x1a066f);for(let _0x5b6132=0x0;_0x5b6132<_0x451955['length'];_0x5b6132++){if('isRemoved'==_0x2bdbb7&&_0x451955[_0x5b6132]['isAdded']||'isAdded'==_0x2bdbb7&&_0x451955[_0x5b6132]['isRemoved'])continue;if('text'==_0x451955[_0x5b6132]['type']){_0x451955[_0x5b6132]['distance']=0x0;continue;}const _0x547043=_0x49ee95['get'](_0x451955[_0x5b6132]['pairId']),_0x1fbfe6=_0x49ee95['get'](_0x451955[_0x5b6132]['id']);_0x451955[_0x5b6132]['distance']=_0x547043-_0x1fbfe6;}}['_getRevisionsRange'](_0x5e62bd,_0x1d9637,_0x480789=!0x1){const _0x5b0ff8=[];let _0x5c21ea=this['repository']['getIndex'](_0x5e62bd),_0x4427d8=this['repository']['getIndex'](_0x1d9637);for(-0x1==_0x4427d8&&(_0x4427d8=this['repository']['_revisions']['length'],_0x480789=!0x1);_0x5c21ea<_0x4427d8;)_0x5b0ff8['push'](this['repository']['getRevision'](_0x5c21ea)),_0x5c21ea++;return _0x480789&&_0x5b0ff8['push'](this['repository']['getRevision'](_0x5c21ea)),_0x5b0ff8;}['_threeWayMerge'](_0x5976c4,_0x2fe1ec,_0x475c73,_0x3cf5c8){const _0x32e60e=this['editor']['model']['schema'];let _0x58643c=_0x2fe1ec;for(;_0x5976c4[_0x58643c]&&_0x5976c4[_0x58643c]['isAdded'];)_0x58643c++;let _0x462413=_0x3cf5c8;for(;_0x475c73[_0x462413]&&_0x475c73[_0x462413]['isRemoved'];)_0x462413++;_0x43bca3(_0x5976c4,_0x2fe1ec,_0x58643c),_0x43bca3(_0x475c73,_0x3cf5c8,_0x462413);const _0xd7db85=_0x475c73['slice'](_0x3cf5c8,_0x462413)['concat'](_0x5976c4['slice'](_0x2fe1ec,_0x58643c));return _0xd7db85['sort']((_0x52bd34,_0x41d8d3)=>_0x52bd34['side']!=_0x41d8d3['side']?_0x52bd34['side']-_0x41d8d3['side']:_0x52bd34['level']!=_0x41d8d3['level']?_0x52bd34['level']-_0x41d8d3['level']:_0x52bd34['distance']!=_0x41d8d3['distance']?_0x41d8d3['distance']-_0x52bd34['distance']:!!_0x52bd34['isAdded']!=!!_0x41d8d3['isAdded']?-0x1==_0x52bd34['side']||0x0==_0x52bd34['side']?_0x52bd34['isAdded']?-0x1:0x1:_0x52bd34['isAdded']?0x1:-0x1:_0x52bd34['index']-_0x41d8d3['index']),{'commonTape':_0xd7db85,'iEnd':_0x58643c,'jEnd':_0x462413};function _0x43bca3(_0x18ca20,_0x222bd1,_0x22c3b9){let _0x4e6231=-0x1,_0x53cafa=Number['POSITIVE_INFINITY'],_0xf1a558=!0x0;for(let _0x55c1f4=_0x222bd1;_0x55c1f4<_0x22c3b9;_0x55c1f4++)if(_0x32e60e['isInline'](_0x18ca20[_0x55c1f4]['item'])||(_0xf1a558=!0x1),_0x18ca20[_0x55c1f4]['item']['startIndex']<_0x222bd1&&(_0x4e6231=_0x55c1f4),_0x18ca20[_0x55c1f4]['item']['endIndex']>=_0x22c3b9){_0x53cafa=_0x55c1f4;break;}_0xf1a558&&(_0x4e6231=_0x22c3b9-0x1);for(let _0x3ea76d=_0x222bd1;_0x3ea76d<_0x22c3b9;_0x3ea76d++)_0x18ca20[_0x3ea76d]['side']=_0x3ea76d<=_0x4e6231?-0x1:_0x3ea76d<_0x53cafa?0x0:0x1,_0x18ca20[_0x3ea76d]['index']=_0x3ea76d;let _0x4a5a12=0x0;for(let _0x549d25=_0x222bd1;_0x549d25<=_0x4e6231;_0x549d25++)0x0==_0x18ca20[_0x549d25]['distance']?_0x18ca20[_0x549d25]['level']=_0x4a5a12:(_0x4a5a12++,_0x18ca20[_0x549d25]['level']=_0x4a5a12,_0x4a5a12++);for(let _0x1f0f0e=_0x222bd1;_0x1f0f0e<_0x22c3b9;_0x1f0f0e++)0x0==_0x18ca20[_0x1f0f0e]['side']&&(_0x18ca20[_0x1f0f0e]['level']=_0x4a5a12);_0x4a5a12=0x0;for(let _0x17824b=_0x22c3b9-0x1;_0x17824b>=_0x53cafa;_0x17824b--)0x0==_0x18ca20[_0x17824b]['distance']?_0x18ca20[_0x17824b]['level']=_0x4a5a12:(_0x4a5a12--,_0x18ca20[_0x17824b]['level']=_0x4a5a12,_0x4a5a12--);}}['_fixObsoleteTags'](_0x4a3208){const _0x181a91=new Map(),_0x44e74d=this['editor']['model']['schema'];for(let _0x205369=0x1;_0x205369<_0x4a3208['length'];_0x205369++){let _0x32c756,_0x552ba3,_0x4dea1d;const _0x118765=_0x4a3208[_0x205369],_0x253c04=_0x4a3208[_0x205369-0x1];if('text'==_0x118765['type'])continue;if(_0x118765['type']!=_0x253c04['type'])continue;if(!_0x44e74d['isBlock'](_0x253c04['item'])||_0x44e74d['isLimit'](_0x253c04['item']))continue;if(!_0x44e74d['isBlock'](_0x118765['item'])||_0x44e74d['isLimit'](_0x118765['item']))continue;if((_0x4a3208[_0x205369]['isAdded']||_0x4a3208[_0x205369]['isAddSuggestion'])&&_0x4a3208[_0x205369-0x1]['isRemoved'])_0x32c756=_0x4a3208[_0x205369],_0x552ba3=_0x4a3208[_0x205369-0x1],_0x4dea1d=_0x205369-0x1;else{if(!_0x4a3208[_0x205369]['isRemoved']||!_0x4a3208[_0x205369-0x1]['isAdded']&&!_0x4a3208[_0x205369-0x1]['isAddSuggestion'])continue;_0x32c756=_0x4a3208[_0x205369-0x1],_0x552ba3=_0x4a3208[_0x205369],_0x4dea1d=_0x205369;}const _0x224d41=_0x32c756['level']==_0x552ba3['level'],_0x1a7f7e=Math['abs'](_0x32c756['level'])<Math['abs'](_0x552ba3['level'])&&0x0==_0x552ba3['distance'];(_0x224d41||_0x1a7f7e)&&(_0x181a91['set'](_0x552ba3['id'],_0x32c756['id']),_0x4a3208['splice'](_0x4dea1d,0x1),_0x205369--,_0x32c756['isAdded']=!0x1);}for(let _0xab0966=0x0;_0xab0966<_0x4a3208['length'];_0xab0966++)_0x181a91['has'](_0x4a3208[_0xab0966]['pairId'])&&(_0x4a3208[_0xab0966]['pairId']=_0x181a91['get'](_0x4a3208[_0xab0966]['pairId']));}['_removeMissingPairs'](_0x4e2ddc){const _0x517902=new Set(_0x4e2ddc['map'](_0xc0b0a7=>_0xc0b0a7['id']));for(let _0x51a75e=0x0;_0x51a75e<_0x4e2ddc['length'];_0x51a75e++)_0x517902['has'](_0x4e2ddc[_0x51a75e]['pairId'])||0x0==_0x4e2ddc[_0x51a75e]['distance']||(_0x4e2ddc[_0x51a75e]['isIncorrect']=!0x0);return _0x4e2ddc['filter'](_0x10a331=>!_0x10a331['isIncorrect']);}['_markMismatchedRemovedTags'](_0x137910){const _0x3cb612=new Set();for(let _0x3916ed=0x0;_0x3916ed<_0x137910['length'];_0x3916ed++){if(_0x3cb612['has'](_0x137910[_0x3916ed]['id'])&&_0x137910[_0x3916ed]['isRemoved']&&(_0x137910[_0x3916ed]['isIncorrect']=!0x0),_0x137910[_0x3916ed]['isIncorrect'])continue;if(0x0==_0x137910[_0x3916ed]['distance'])continue;if('elementStart'!=_0x137910[_0x3916ed]['type'])continue;if(null==_0x137910[_0x3916ed]['pairId'])continue;let _0x4faded=_0x3916ed+0x1,_0x3ca314=0x0;for(;_0x137910[_0x4faded]['id']!=_0x137910[_0x3916ed]['pairId'];)'elementStart'==_0x137910[_0x4faded]['type']?_0x3ca314++:'elementEnd'==_0x137910[_0x4faded]['type']&&_0x3ca314--,_0x4faded++;if(0x0!=_0x3ca314){if(_0x137910[_0x3916ed]['isRemoved'])_0x137910[_0x3916ed]['isIncorrect']=!0x0;else{for(;_0x4faded!=_0x3916ed;)_0x137910[_0x4faded]['isRemoved']&&0x0!=_0x137910[_0x4faded]['distance']&&(_0x137910[_0x4faded]['isIncorrect']=!0x0,_0x3cb612['add'](_0x137910[_0x4faded]['pairId'])),_0x4faded--;}}}return _0x137910['filter'](_0x4b9710=>!_0x4b9710['isIncorrect']);}['_removeUnsupportedChanges'](_0x2d2e39){const _0x4fed9c=this['editor']['model']['schema'];for(let _0xede69e=0x0;_0xede69e<_0x2d2e39['length'];_0xede69e++){if(!(_0x2d2e39[_0xede69e]['isAdded']||_0x2d2e39[_0xede69e]['isAddSuggestion']||_0x2d2e39[_0xede69e]['isRemoved']||_0x2d2e39[_0xede69e]['isRemoveSuggestion']))continue;if(0x0==_0x2d2e39[_0xede69e]['distance'])continue;const _0x493aeb=_0x2d2e39[_0xede69e]['item'];_0x4fed9c['isBlock'](_0x493aeb)||_0x4fed9c['isLimit'](_0x493aeb)||(_0x2d2e39[_0xede69e]['isAdded']&&delete _0x2d2e39[_0xede69e]['isAdded'],_0x2d2e39[_0xede69e]['isAddSuggestion']&&delete _0x2d2e39[_0xede69e]['isAddSuggestion'],_0x2d2e39[_0xede69e]['isRemoveSuggestion']&&delete _0x2d2e39[_0xede69e]['isRemoveSuggestion'],_0x2d2e39[_0xede69e]['isRemoved']&&(_0x2d2e39[_0xede69e]['isIncorrect']=!0x0));}return _0x2d2e39['filter'](_0x196297=>!_0x196297['isIncorrect']);}['_makeModelFromTape'](_0x3aaf89,_0x2630d9,_0x475fb6){const _0xdb00a4=new wt(),_0x3b3af9=[],_0x2a1b51=new Map(),_0x1c9470=this['editor']['model'],_0x372309=_0x1c9470['schema'],_0x274d50=[_0xdb00a4],_0x114564={},_0x491bd7={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3808d4=null;const _0x34af5f=[0x0];for(let _0x2f1d0b=0x0;_0x2f1d0b<_0x3aaf89['length'];_0x2f1d0b++)if('elementStart'===_0x3aaf89[_0x2f1d0b]['type']){_0x3aaf89[_0x2f1d0b]['previousPosition']=_0x1c9470['createPositionFromPath'](_0xdb00a4,_0x34af5f);const _0x129676=new ft(_0x3aaf89[_0x2f1d0b]['item']['name'],_0x3aaf89[_0x2f1d0b]['item']['getAttributes']());_0x274d50[0x0]['_appendChild'](_0x129676),_0x34af5f['push'](0x0),_0x274d50['unshift'](_0x129676),_0x3aaf89[_0x2f1d0b]['nextPosition']=_0x1c9470['createPositionFromPath'](_0xdb00a4,_0x34af5f);}else'elementEnd'===_0x3aaf89[_0x2f1d0b]['type']?(_0x274d50['shift'](),_0x3aaf89[_0x2f1d0b]['previousPosition']=_0x1c9470['createPositionFromPath'](_0xdb00a4,_0x34af5f),_0x34af5f['pop'](),_0x34af5f[_0x34af5f['length']-0x1]++,_0x3aaf89[_0x2f1d0b]['nextPosition']=_0x1c9470['createPositionFromPath'](_0xdb00a4,_0x34af5f)):(_0x3aaf89[_0x2f1d0b]['previousPosition']=_0x1c9470['createPositionFromPath'](_0xdb00a4,_0x34af5f),_0x3808d4?_0x3808d4['_data']+=_0x3aaf89[_0x2f1d0b]['item']['data']:_0x3808d4=new _t(_0x3aaf89[_0x2f1d0b]['item']['data'],_0x3aaf89[_0x2f1d0b]['item']['getAttributes']()),_0x3aaf89[_0x2f1d0b+0x1]&&'text'===_0x3aaf89[_0x2f1d0b+0x1]['type']&&_0x1082d1(_0x3808d4,_0x3aaf89[_0x2f1d0b+0x1]['item'])||(_0x274d50[0x0]['_appendChild'](_0x3808d4),_0x3808d4=null),_0x34af5f[_0x34af5f['length']-0x1]+=_0x3aaf89[_0x2f1d0b]['item']['offsetSize'],_0x3aaf89[_0x2f1d0b]['nextPosition']=_0x1c9470['createPositionFromPath'](_0xdb00a4,_0x34af5f));for(let _0x2f07ee=0x0;_0x2f07ee<_0x3aaf89['length'];_0x2f07ee++){const _0x499324=_0x3aaf89[_0x2f07ee]['previousPosition'],_0x135cc9=_0x3aaf89[_0x2f07ee]['nextPosition'];for(const _0x13f00a of _0x3aaf89[_0x2f07ee]['markersStart'])_0x2a1b51['set'](_0x13f00a,{'start':_0x499324,'end':null});_0x4bc19d('isRemoveSuggestion',_0x2f07ee,_0x499324,_0x135cc9),_0x4bc19d('isAddSuggestion',_0x2f07ee,_0x499324,_0x135cc9),_0x4bc19d('isRemoved',_0x2f07ee,_0x499324,_0x135cc9),_0x4bc19d('isAdded',_0x2f07ee,_0x499324,_0x135cc9);for(const _0x128f8e of _0x3aaf89[_0x2f07ee]['markersEnd']){_0x2a1b51['get'](_0x128f8e)['end']=_0x135cc9;}}for(const [_0x55b556,_0x2c481c]of _0x2a1b51){const _0x483481=this['editor']['model']['createRange'](_0x2c481c['start'],_0x2c481c['end']);_0xdb00a4['markers']['set'](_0x55b556,_0x483481);}return _0x3b3af9['sort']((_0x48ea01,_0x2b7795)=>{const _0x3cac0e=_0xdb00a4['markers']['get']('revision:'+_0x48ea01['id']),_0x773f7=_0xdb00a4['markers']['get']('revision:'+_0x2b7795['id']);return _0x3cac0e['start']['isBefore'](_0x773f7['start'])?-0x1:_0x3cac0e['start']['isAfter'](_0x773f7['start'])?0x1:_0x3cac0e['end']['isBefore'](_0x773f7['end'])?-0x1:_0x3cac0e['end']['isAfter'](_0x773f7['end'])?0x1:'add'===_0x48ea01['type']?-0x1:0x1;}),{'root':_0xdb00a4,'changes':_0x3b3af9};function _0x4bc19d(_0x255722,_0x343552,_0x509cfd,_0x5e2c57){const _0x44de08=!!_0x3aaf89[_0x343552][_0x255722],_0x4b3dd1=_0x44de08?_0x3aaf89[_0x343552][_0x255722]['userId']:null,_0x4f3e11=_0x343552===_0x3aaf89['length']-0x1,_0x35a031=_0x491bd7[_0x255722][0x0],_0x553602=_0x372309['isObject'](_0x3aaf89[_0x343552]['item']);!_0x114564[_0x255722]&&_0x44de08?_0x114564[_0x255722]={'start':_0x509cfd,'tapeItem':_0x3aaf89[_0x343552],'userId':_0x4b3dd1,'type':_0x255722}:_0x114564[_0x255722]&&!_0x44de08?(_0x114564[_0x255722]['end']=_0x509cfd,_0x2c50ce(_0x114564[_0x255722]),_0x114564[_0x255722]=null):_0x114564[_0x255722]&&_0x44de08&&_0x114564[_0x255722]['userId']!==_0x4b3dd1&&(_0x114564[_0x255722]['end']=_0x509cfd,_0x35a031&&_0x35a031['userId']===_0x114564[_0x255722]['userId']||_0x2c50ce(_0x114564[_0x255722]),_0x114564[_0x255722]={'start':_0x509cfd,'tapeItem':_0x3aaf89[_0x343552],'userId':_0x4b3dd1,'type':_0x255722}),_0x114564[_0x255722]&&_0x553602&&('elementStart'!==_0x3aaf89[_0x343552]['type']||_0x35a031&&_0x35a031['userId']===_0x4b3dd1||_0x491bd7[_0x255722]['unshift']({'userId':_0x4b3dd1,'object':_0x3aaf89[_0x343552]['item'],'change':_0x114564[_0x255722]}),'elementEnd'===_0x3aaf89[_0x343552]['type']&&_0x35a031&&_0x35a031['object']===_0x3aaf89[_0x343552]['item']&&(_0x491bd7[_0x255722]['shift'](),_0x114564[_0x255722]=_0x35a031['change'])),_0x114564[_0x255722]&&_0x4f3e11&&(_0x114564[_0x255722]['end']=_0x5e2c57,_0x2c50ce(_0x114564[_0x255722]),_0x114564[_0x255722]=null);}function _0x2c50ce({start:_0x1e6024,end:_0x23d7ef,tapeItem:_0x5f5417,userId:_0x23837e,type:_0x5bed2d}){const _0x2b6bba=_0x5f5417['item'],_0xa5ff27=_0x1c9470['schema']['isBlock'](_0x2b6bba)&&!_0x1c9470['schema']['isLimit'](_0x2b6bba),_0x4a5556=_0x1e6024['nodeAfter']==_0x23d7ef['parent']&&_0x23d7ef['isAtStart'];if(_0xa5ff27&&_0x4a5556)return;const _0x57d3f7=_0x1c9470['createRange'](_0x1e6024,_0x23d7ef),_0x185204=_0x2630d9['get'](_0x23837e),_0x150e21=new r({'author':_0x185204,'type':'isAdded'==_0x5bed2d||'isAddSuggestion'==_0x5bed2d?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5bed2d||'isRemoveSuggestion'==_0x5bed2d},'createdAt':new Date(),'rootName':_0x475fb6});_0x3b3af9['push'](_0x150e21),_0xdb00a4['markers']['set']('revision:'+_0x150e21['id'],_0x57d3f7);}function _0x1082d1(_0x15b065,_0x4b98c5){const _0x245d9f=_0x15b065['getAttributes'](),_0x304056=_0x4b98c5['getAttributes']();for(const _0x49bdb6 of _0x245d9f){if(_0x49bdb6[0x1]!==_0x4b98c5['getAttribute'](_0x49bdb6[0x0]))return!0x1;_0x304056['next']();}return _0x304056['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3f34e1=>{const _0x5e0c66=_0x3f34e1['markerName']['split'](':')[0x1],_0x565b66=this['_getChangeFromId'](_0x5e0c66);if(!_0x565b66)return null;const _0x3ece90='add'==_0x565b66['type']?'insertion':'deletion',_0x2cd11a=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3ece90];return _0x565b66['data']['isSuggestion']&&_0x2cd11a['push']('ck-suggestion-marker-'+_0x3ece90+'-new'),this['activeChange']==_0x565b66&&_0x2cd11a['push']('ck-suggestion-marker--active'),{'classes':_0x2cd11a,'attributes':{'data-change-id':_0x5e0c66}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3abe2e=>{_0x3abe2e['on']('element:pre',(_0x468efd,_0x14a68f,_0x3112b8)=>{const _0x3279da=_0x14a68f['viewItem']['getChild'](0x0);if(!_0x3279da||!_0x3279da['is']('element','code'))return;if(!_0x3112b8['consumable']['consume'](_0x3279da,{'attributes':['vid_start','vid_end']}))return;const _0x5aaf4b=_0x14a68f['modelRange']['start']['nodeAfter'];_0x3112b8['writer']['setAttribute']('vid_start',_0x3279da['getAttribute']('vid_start'),_0x5aaf4b),_0x3112b8['writer']['setAttribute']('vid_end',_0x3279da['getAttribute']('vid_end'),_0x5aaf4b);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x193fd7=>{_0x193fd7['on']('element',(_0x22d3d6,_0x397cec,_0x74f73d)=>{if(!_0x74f73d['consumable']['consume'](_0x397cec['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x397cec['modelRange']['isCollapsed'])return;const _0x1dc4cb=_0x397cec['modelRange']['start']['nodeAfter'];_0x1dc4cb['hasAttribute']('vid_start')||_0x1dc4cb['hasAttribute']('vid')||(_0x74f73d['writer']['setAttribute']('vid_start',_0x397cec['viewItem']['getAttribute']('vid_start'),_0x1dc4cb),_0x74f73d['writer']['setAttribute']('vid_end',_0x397cec['viewItem']['getAttribute']('vid_end'),_0x1dc4cb));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x40d1a8=>_0x40d1a8['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x368526,[,_0x2f0691])=>{['vid_start','vid_end','vid']['includes'](_0x2f0691)&&(_0x368526['return']=!0x0,_0x368526['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x13e606=>{_0x13e606['on']('attribute:vid',(_0x68016c,_0x10ff5e,_0x22bce0)=>{if('\x20'!=_0x10ff5e['item']['data']||_0x10ff5e['item']['parent']['maxOffset']>0x1)return;if(!_0x22bce0['consumable']['consume'](_0x10ff5e['item'],_0x68016c['name']))return;const _0x5b43dd=_0x22bce0['writer'],_0x37672e=_0x22bce0['mapper']['toViewRange'](_0x10ff5e['range']);_0x5b43dd['wrap'](_0x37672e,_0x5b43dd['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x9c69a4){const _0x1dcde9=_0x9c69a4['plugins']['get']('RevisionViewer');return(_0x321421,_0x73afe2,_0x533549)=>{const _0x2ccabf=_0x73afe2['markerName']['split'](':')[0x1],_0x36bbfa=_0x1dcde9['_getChangeFromId'](_0x2ccabf);if(!_0x36bbfa)return null;const _0x4f48c7='add'==_0x36bbfa['type']?'split':'merge';if(!_0x533549['consumable']['test'](_0x73afe2['markerRange'],_0x321421['name']))return;const _0x2fc0b8=_0x73afe2['markerRange']['getWalker'](),_0x1ef924=_0x73afe2['markerRange']['start'],_0x5eea7b=_0x9c69a4['model']['schema'];let _0x27345c=null,_0x96f11f=null,_0x12f46e=!0x1,_0x54be47=!0x1;for(const _0x5b547a of _0x2fc0b8){const _0x5f26a2=_0x5b547a['item'];_0x12f46e=_0x12f46e||_0x5eea7b['isContent'](_0x5f26a2);const _0x3606eb=_0x533549['mapper']['toViewElement'](_0x5f26a2);if(_0x3606eb&&_0x3606eb['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5b547a['type']&&(_0x5eea7b['isBlock'](_0x5f26a2)&&!_0x5eea7b['isLimit'](_0x5f26a2)&&(_0x5f26a2['nextSibling']||_0x1ef924['isAtEnd']?_0x27345c&&_0x27345c['parent']==_0x5f26a2||(_0x27345c=_0x5f26a2,_0x229a75(_0x5b547a['previousPosition']),_0x54be47=!0x0):_0x96f11f=_0x96f11f||_0x5b547a['previousPosition']));}function _0x229a75(_0x12b5d7){const _0x34387f=_0x533549['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4f48c7}),_0x41ce10=_0x533549['mapper']['toViewPosition'](_0x12b5d7);_0x36bbfa['data']['isSuggestion']&&_0x533549['writer']['addClass']('ck-suggestion-marker-'+_0x4f48c7+'-new',_0x34387f),_0x1dcde9['activeChange']==_0x36bbfa&&_0x533549['writer']['addClass']('ck-suggestion-marker--active',_0x34387f),_0x533549['writer']['insert'](_0x41ce10,_0x34387f),_0x533549['mapper']['bindElementToMarker'](_0x34387f,_0x73afe2['markerName']);}_0x12f46e||_0x54be47||!_0x96f11f||_0x229a75(_0x96f11f);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4128f0,_0x22bc93,_0x403402)=>{const _0x1de816=_0x403402['mapper']['markerNameToElements'](_0x22bc93['markerName']);if(_0x1de816){for(const _0x2d4921 of _0x1de816)(_0x2d4921['hasClass']('ck-suggestion-marker-split')||_0x2d4921['hasClass']('ck-suggestion-marker-merge'))&&(_0x403402['mapper']['unbindElementFromMarkerName'](_0x2d4921,_0x22bc93['markerName']),_0x403402['writer']['remove'](_0x2d4921));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3e5661,_0x138d70,_0x209b09)=>{const _0x4f9f9c=_0x138d70['markerName']['split'](':')[0x1],_0x175451=this['_getChangeFromId'](_0x4f9f9c);if(!_0x175451)return null;const _0x6a61ee='add'==_0x175451['type']?'split':'merge';if(_0x209b09['consumable']['test'](_0x138d70['markerRange'],_0x3e5661['name']))for(const _0x468ae3 of _0x138d70['markerRange']['getItems']()){if(!_0x468ae3['is']('element','softBreak'))continue;const _0x2344bd=_0x209b09['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x6a61ee}),_0x69b92e=_0x209b09['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x468ae3));_0x175451['data']['isSuggestion']&&_0x209b09['writer']['addClass']('ck-suggestion-marker-'+_0x6a61ee+'-new',_0x2344bd),this['activeChange']==_0x175451&&_0x209b09['writer']['addClass']('ck-suggestion-marker--active',_0x2344bd),_0x209b09['writer']['insert'](_0x69b92e,_0x2344bd),_0x209b09['mapper']['bindElementToMarker'](_0x2344bd,_0x138d70['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x20d1ed=>{for(const _0x314768 of this['editor']['model']['document']['getRootNames']()){const _0x42097c=this['editor']['model']['document']['getRoot'](_0x314768),_0xc51b24=this['editor']['editing']['view']['document']['getRoot'](_0x314768);if(_0xc51b24){const _0x1583d6=_0x42097c['getAttribute']('revisionHistoryAttachChange');if(_0x20d1ed['removeAttribute']('data-change-id',_0xc51b24),_0x20d1ed['removeClass']('ck-revision-history-root-add',_0xc51b24),_0x20d1ed['removeClass']('ck-revision-history-root-remove',_0xc51b24),_0x20d1ed['removeClass']('ck-revision-history-root--active',_0xc51b24),_0x1583d6){const _0x2db85a=this['_getChangeFromId'](_0x1583d6);if(!_0x2db85a)return null;_0x20d1ed['setAttribute']('data-change-id',_0x1583d6,_0xc51b24),_0x20d1ed['addClass']('ck-revision-history-root-'+_0x2db85a['type'],_0xc51b24),this['activeChange']==_0x2db85a&&_0x20d1ed['addClass']('ck-revision-history-root--active',_0xc51b24);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x22583e=>'revision-comment:'+_0x22583e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x5ba6d8=>'revision-suggestion:'+_0x5ba6d8,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x15d4bf=>({'name':'suggestion:'+_0x15d4bf,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2fe35b=>{const _0x525ee6=_0x2fe35b['markerName']['split'](':')[0x1];return'insertion'!=_0x525ee6&&'deletion'!=_0x525ee6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x525ee6]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x31a284,_0x578ccf,_0x5d85cc)=>{const _0x3980b7=_0x5d85cc['mapper']['markerNameToElements'](_0x578ccf['markerName']);if(_0x3980b7){for(const _0x5c88fc of _0x3980b7)_0x5c88fc['is']('uiElement')&&(_0x5d85cc['mapper']['unbindElementFromMarkerName'](_0x5c88fc,_0x578ccf['markerName']),_0x5d85cc['writer']['remove'](_0x5c88fc));}},{'priority':'high'});}['_getChangeFromId'](_0x1b01cb){return this['_changeIdToChange']['get'](_0x1b01cb);}['_getViewForChange'](_0x439308){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x439308),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5e4c9e,_0x535177,_0x474b19,_0x3ef1ed)=>{_0x3ef1ed&&this['_balloon']['remove'](_0x3ef1ed),_0x474b19&&(this['_balloon']['add']({'view':_0x474b19,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0xe10cb0=this['editor']['editing'],_0x2ab02d=this['_getChangeFromId'](_0x474b19['changeId']);let _0x3cd958;if(_0x2ab02d['data']['isOnRoot']){const _0x55d641=_0xe10cb0['view']['getDomRoot'](_0x2ab02d['rootName']);_0x3cd958=Array['from'](_0x55d641['getClientRects']());}else{const _0x5dfe50=this['editor']['model']['markers']['get']('revision:'+_0x474b19['changeId']);_0x3cd958=Array['from'](_0xe10cb0['mapper']['markerNameToElements'](_0x5dfe50['name']))['map'](_0x256d3c=>_0xe10cb0['view']['domConverter']['mapViewToDom'](_0x256d3c))['map'](_0x2e1cb3=>Array['from'](_0x2e1cb3['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x3cd958[0x0];return _0x3cd958['find'](_0x59021b=>_0x59021b['top']-0x3<=this['_activeViewTarget']['y']&&_0x59021b['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x59021b['left']-0x3<=this['_activeViewTarget']['x']&&_0x59021b['right']+0x3>=this['_activeViewTarget']['x'])||_0x3cd958[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x3bb7bf,_0x107390,_0x446a6b,_0x3b9759)=>{this['activeView']=_0x446a6b?this['_getViewForChange'](_0x446a6b):null,this['editor']['model']['change'](()=>{const _0x4cb634=this['editor']['editing'];_0x3b9759&&(_0x3b9759['data']['isOnRoot']?_0x4cb634['view']['change'](_0x226984=>{_0x226984['removeClass']('ck-revision-history-root--active',_0x4cb634['view']['document']['getRoot'](_0x3b9759['rootName']));}):_0x4cb634['reconvertMarker']('revision:'+_0x3b9759['id'])),_0x446a6b&&(_0x446a6b['data']['isOnRoot']?_0x4cb634['view']['change'](_0x4e1381=>{_0x4e1381['addClass']('ck-revision-history-root--active',_0x4cb634['view']['document']['getRoot'](_0x446a6b['rootName']));}):_0x4cb634['reconvertMarker']('revision:'+_0x446a6b['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3bae6c,_0x11c7bc)=>{if(this['activeChange'])return;const _0x34b2f9=this['_findChangeIdFromDomTarget'](_0x11c7bc['target']),_0x31ba0f=this['_changeIdToChange']['get'](_0x34b2f9);_0x31ba0f?(this['_activeViewTarget']={'x':_0x11c7bc['domEvent']['x'],'y':_0x11c7bc['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x31ba0f)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0xa18566,_0x4bdd74)=>{const _0x928a11=this['_findChangeIdFromDomTarget'](_0x4bdd74['target']),_0x373308=this['_changeIdToChange']['get'](_0x928a11);_0x373308?(this['_activeViewTarget']={'x':_0x4bdd74['domEvent']['x'],'y':_0x4bdd74['domEvent']['y']},_0x373308===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x373308):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x291ebb){do{const _0x1352c7=_0x291ebb['getAttribute']('data-change-id');if(_0x1352c7)return _0x1352c7;_0x291ebb=_0x291ebb['parent'];}while(_0x291ebb);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x43b56d=>{for(const _0x4f22f8 of this['editor']['model']['markers'])_0x43b56d['removeMarker'](_0x4f22f8);});}}function tt(_0x403237,_0x2b380f){return(_0x157b12,_0x160c7a,_0x3011ca)=>{if(!_0x3011ca['consumable']['test'](_0x160c7a['markerRange'],_0x157b12['name']))return;const _0x4c93d4=_0x160c7a['markerRange']['getWalker'](),_0x1f50e3=_0x160c7a['markerRange']['start'],_0x2a78cb=_0x403237['model']['schema'];let _0x4e4ecf=null,_0x35267c=null,_0x1d6c2c=!0x1,_0x52e107=!0x1;for(const _0x2e6428 of _0x4c93d4){const _0x2e0528=_0x2e6428['item'];_0x1d6c2c=_0x1d6c2c||_0x2a78cb['isContent'](_0x2e0528);const _0x44a668=_0x3011ca['mapper']['toViewElement'](_0x2e0528);if(_0x44a668&&_0x44a668['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2e6428['type']&&(_0x2a78cb['isBlock'](_0x2e0528)&&!_0x2a78cb['isLimit'](_0x2e0528)&&(_0x2e0528['nextSibling']||_0x1f50e3['isAtEnd']?_0x4e4ecf&&_0x4e4ecf['parent']==_0x2e0528||(_0x4e4ecf=_0x2e0528,_0x105347(_0x2e6428['previousPosition']),_0x52e107=!0x0):_0x35267c=_0x35267c||_0x2e6428['previousPosition']));}function _0x105347(_0x23eae6){const _0x2bdbdc=_0x3011ca['mapper']['toViewPosition'](_0x23eae6),_0x2a5fb1=_0x3011ca['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x2b380f});_0x3011ca['writer']['insert'](_0x2bdbdc,_0x2a5fb1),_0x3011ca['mapper']['bindElementToMarker'](_0x2a5fb1,_0x160c7a['markerName']);}_0x1d6c2c||_0x52e107||!_0x35267c||_0x105347(_0x35267c);};}class yt extends _0xf66950{constructor(_0x215e7b){super(_0x215e7b);const _0x105b5e=_0x215e7b['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x105b5e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x105b5e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x206b48=this['editor'],_0x28818c=_0x206b48['plugins']['get'](d),_0x5b466b=_0x28818c['isReady']?_0x28818c['diff']['newRevisionId']:null;_0x206b48['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5b466b);}['refresh'](){const {isReady:_0x515b45,isEnabled:_0x105197}=this['editor']['plugins']['get'](d);this['isEnabled']=_0x515b45&&_0x105197;}}class bt extends _0xf66950{['_step'];constructor(_0x19f96c,{direction:_0x5d2bfb}){super(_0x19f96c);const _0x208407=_0x19f96c['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x5d2bfb?0x1:-0x1,this['listenTo'](_0x208407,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x208407,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x208407,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2585a5=this['editor'],_0x4893b5=_0x2585a5['plugins']['get'](d),{isNavigationMode:_0x4c4bfc,currentChangeNumber:_0x4a397f}=_0x4893b5;let _0x44a8ac;if(_0x4893b5['activeChange']=_0x4c4bfc?_0x4893b5['diff']['changes']['get'](_0x4a397f+this['_step']):_0x4893b5['diff']['changes']['first'],_0x4893b5['activeChange']['data']['isOnRoot'])_0x44a8ac=_0x2585a5['editing']['view']['getDomRoot'](_0x4893b5['activeChange']['rootName']);else{const _0x442c28=_0x2585a5['model']['markers']['get']('revision:'+_0x4893b5['activeChange']['id']);_0x44a8ac=_0x218286(_0x2585a5['editing'],_0x442c28);}_0x277b74({'target':_0x44a8ac,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0xa2c776,currentChangeNumber:_0x422560,numberOfChanges:_0x4bbf44,isReady:_0x4af0be,isEnabled:_0x3301d0}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x3301d0&&_0x4af0be&&_0x4bbf44)&&(!_0xa2c776||(0x1===this['_step']?_0x422560<_0x4bbf44-0x1:_0x422560>0x0));}}class _i extends _0x2c43c9{constructor(_0x316ee7){super(_0x316ee7);const _0x2da79c=this['bindTemplate'],_0x124bfa=new _0x15a92a(_0x316ee7),_0x506ccb=new _0x15a92a(_0x316ee7);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',(_0x5c29bb,_0x3a7ce0)=>_0x5c29bb&&_0x3a7ce0>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x4783e8,_0x4fe40b,_0x26b87c,_0x1afc4f)=>{if(!_0x4783e8)return R(_0x316ee7,'Loading...');if(!_0x26b87c)return R(_0x316ee7,'No\x20changes');const _0x5b71f4=R(_0x316ee7,'NUMBER_OF_CHANGES',_0x26b87c);return _0x1afc4f?R(_0x316ee7,'X_OF_Y_CHANGES',[_0x4fe40b+0x1,_0x26b87c]):_0x5b71f4;}),_0x124bfa['set']({'label':R(_0x316ee7,'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'}),_0x506ccb['set']({'label':R(_0x316ee7,'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'}),_0x124bfa['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x506ccb['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x124bfa['on']('execute',()=>this['fire']('execute','backward')),_0x506ccb['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',_0x2da79c['if']('_isStatusLabelVisible','ck-hidden',_0x5715b1=>!_0x5715b1)]},'children':[{'text':_0x2da79c['to']('isNavigationMode',_0x541b6e=>_0x541b6e?R(_0x316ee7,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x316ee7,'Total')+':\x20')}]},{'text':_0x2da79c['to']('_statusText')}]},new _0x372320(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x124bfa,_0x506ccb]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x24aabd{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x3dbd4c=this['editor']['editing']['view'];_0x3dbd4c['change'](_0x8f5126=>{for(const _0x2f6d48 of _0x3dbd4c['document']['roots'])_0x8f5126['addClass'](ce,_0x2f6d48);});}['hide'](){const _0x1ab7e7=this['editor']['editing']['view'];_0x1ab7e7['change'](_0x4122b0=>{for(const _0x132a12 of _0x1ab7e7['document']['roots'])_0x4122b0['removeClass'](ce,_0x132a12);});}}class m extends _0x24aabd{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,le];}['init'](){const _0x14cee4=this['editor'],_0x474734=_0x14cee4['plugins']['get'](d),_0x32a771=_0x14cee4['plugins']['get'](le);_0x14cee4['ui']['componentFactory']['add']('exitToEditing',_0x2a65f7=>{const _0x2447c6=new _0x15a92a(_0x2a65f7);return _0x2447c6['set']({'label':R(_0x2a65f7,'Back\x20to\x20editing'),'icon':_0x888a61['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x2447c6,'execute',()=>{_0x14cee4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x2447c6;}),_0x14cee4['ui']['componentFactory']['add']('restoreRevision',_0x53c57e=>{const _0x5cb4b2=new _0x15a92a(_0x53c57e);return _0x5cb4b2['set']({'label':R(_0x53c57e,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x5cb4b2['bind']('isEnabled')['to'](_0x14cee4['commands']['get']('restoreRevision')),this['listenTo'](_0x5cb4b2,'execute',()=>_0x14cee4['execute']('restoreRevision')),_0x5cb4b2;}),_0x14cee4['ui']['componentFactory']['add']('changesNavigation',_0x398727=>{const _0x90d155=new _i(_0x398727),_0x4f7525=_0x14cee4['commands']['get']('showPreviousChange'),_0x14da1c=_0x14cee4['commands']['get']('showNextChange');return _0x90d155['bind']('isBackwardNavigationEnabled')['to'](_0x4f7525,'isEnabled'),_0x90d155['bind']('isForwardNavigationEnabled')['to'](_0x14da1c,'isEnabled'),_0x90d155['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x474734),this['listenTo'](_0x90d155,'execute',(_0x4150fb,_0xaa58b)=>{_0x14cee4['execute']('forward'===_0xaa58b?'showNextChange':'showPreviousChange');}),_0x90d155;}),_0x32a771['show'](),_0x474734['on']('change:isReady',(_0x2abb09,_0x45974a,_0x393bf4)=>{_0x393bf4?_0x32a771['hide']():_0x32a771['show']();});}}class mt extends at{['_resizeObserver']=null;constructor(_0x19513d,_0x45f2e4){super(_0x19513d,_0x45f2e4);const _0x60952c=this['bindTemplate'];this['set']({'label':R(_0x19513d,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x19513d,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x60952c['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new pt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x38ffce=this['fieldView']['element'];this['_tooltipString']=_0x38ffce['scrollWidth']>_0x38ffce['clientWidth']&&_0x38ffce['value']||'';}}class ti extends _0x2c43c9{constructor(_0x478222,_0x4347f3,_0x4a2034){super(_0x478222);const _0x323a21=new _0x544954();_0x323a21['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 _0x261530=['ck','ck-revision-history-sidebar__revision-author'];_0x4a2034&&_0x261530['push']('ck-revision-history-sidebar__revision-author_creator');const _0x57b687=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x478222,_0x4a2034?'Revision\x20creator':'Revision\x20author')},'children':[_0x323a21,_0x4347f3['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x261530},'children':_0x57b687});}}function ni(_0x2a9079,_0x2d2159){const _0x4fbdeb=_0x2a9079['bindTemplate'],_0x3e248b=_0x2a9079['locale'],_0x5660ec=_0x20789c(_0x3e248b);_0x5660ec['panelPosition']='sw';const _0x3ab3ea=function(_0x537b8b,_0x546701){const _0x16da37=function(_0x1cf03a,_0x3c3303){const _0x117e11=_0x1cf03a['locale'],_0xcd3b1b={'Compare\x20against\x20selected':R(_0x117e11,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x117e11,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x117e11,'Restore\x20this\x20revision')};return _0x3c3303['map'](_0x271354=>{const _0x5e6cf8=_0xcd3b1b[_0x271354['name']];return _0x5e6cf8&&_0x5e6cf8!==_0x271354['name']&&(_0x271354['name']=_0x5e6cf8),_0x271354;});}(_0x537b8b,_0x546701),_0x22424c=new _0x2ad968();for(const _0x33c59e of _0x16da37){const _0xbf0e06={'type':'button','model':new to({'label':_0x33c59e['name'],'class':_0x33c59e['class'],'withText':!0x0,'role':'menuitem','_action':_0x33c59e['action']})};_0xbf0e06['model']['bind']('isEnabled')['to'](_0x537b8b,'isActionsDropdownOpen',_0x5973f3=>'function'!=typeof _0x33c59e['isEnabled']||(!_0x5973f3||_0x33c59e['isEnabled'](_0x537b8b))),_0x22424c['add'](_0xbf0e06);}return _0x22424c;}(_0x2a9079,_0x2d2159);return _0x2a9079['bind']('isActionsDropdownOpen')['to'](_0x5660ec,'isOpen'),_0x5660ec['buttonView']['set']({'label':R(_0x3e248b,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x888a61['threeVerticalDots']}),_0x5660ec['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4fbdeb['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4fbdeb['to'](_0x4fad9f=>_0x4fad9f['stopPropagation']())}}),_0x5660ec['on']('execute',_0xcacd75=>{_0x2a9079['isReady']&&'function'==typeof _0xcacd75['source']['_action']&&_0xcacd75['source']['_action'](_0x2a9079);}),_0x3d32c0(_0x5660ec,_0x3ab3ea,{'role':'menu'}),_0x5660ec['listenTo'](_0x2a9079,'change:isActionsDropdownOpen',(_0x1080aa,_0x6ffbf0,_0x2965eb)=>{if(_0x2965eb)for(const _0x4cec23 of _0x5660ec['listView']['items']){const _0x5b8c30=_0x4cec23['children']['first'],_0x233bc5=_0x2d2159['find'](_0x3b46af=>_0x3b46af['action']===_0x5b8c30['_action'])['isVisible'];_0x4cec23['isVisible']=void 0x0===_0x233bc5||_0x233bc5(_0x2a9079);}}),_0x5660ec;}class ai extends/* #__PURE__ -- @preserve */
26
- _0x33105c(_0x2c43c9){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x277f19,_0x878266,_0xbfbaa,_0x227e2a){super(_0x277f19);const _0x131a7b=this['bindTemplate'],_0x40d7b6=function(_0x390b19,_0x3139db){const _0x59d2e8=Array['from'](_0x3139db['authors'])['filter'](_0x2ddb0b=>_0x2ddb0b!=_0x3139db['creator']);return _0x3139db['creator']&&_0x59d2e8['unshift'](_0x3139db['creator']),_0x59d2e8['map'](_0x54ca7a=>new ti(_0x390b19,_0x54ca7a,_0x54ca7a==_0x3139db['creator']));}(_0x277f19,_0x878266);this['id']=_0x878266['id'],this['_revision']=_0x878266,this['_requireRevisionName']=_0x227e2a,this['bind']('name','createdAt')['to'](_0x878266),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x40a6f4=>{return _0x204042=_0x277f19['uiLanguage'],(_0x54bf08=_0x40a6f4)['toLocaleDateString'](_0x204042,{'month':'long','day':'numeric'})+',\x20'+_0x54bf08['toLocaleTimeString'](_0x204042,{'hour':'numeric','minute':'numeric'});var _0x204042,_0x54bf08;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new mt(_0x277f19,_0x4fabfa),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x135ea7=>_0x135ea7||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x1cac97,_0x3ddfbd)=>_0x1cac97&&_0x3ddfbd),this['revisionActionsView']=_0xbfbaa&&_0xbfbaa['length']?ni(this,_0xbfbaa):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x131a7b['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x131a7b['if']('isEnabled','ck-disabled',_0x38262f=>!_0x38262f),_0x131a7b['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x131a7b['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x131a7b['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':_0x131a7b['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':_0x40d7b6}]},this['revisionActionsView']],'on':{'click':_0x131a7b['to'](_0x448d64=>{_0x448d64['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2ca3b8=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2ca3b8,'change',()=>{this['_requireRevisionName']&&!_0x2ca3b8['value']||this['fire']('setName',{'id':this['id'],'name':_0x2ca3b8['value']}),_0x2ca3b8['value']||(_0x2ca3b8['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(_0x52a232,_0x3ecc1b){const _0x33f11b=_0x283079['fromJSDate'](_0x52a232)['setLocale'](_0x3ecc1b),_0x419b8a=_0x283079['local'](),_0xddfcb8=_0x419b8a['minus']({'days':0x1})['startOf']('day');let _0xdecbb5,_0x2d7a96;return _0x33f11b['hasSame'](_0x419b8a,'day')?(_0xdecbb5=_0x33f11b['startOf']('day')['toJSDate'](),_0x2d7a96=_0x33f11b['toRelativeCalendar']()):_0x33f11b['hasSame'](_0xddfcb8,'day')?(_0xdecbb5=_0xddfcb8['toJSDate'](),_0x2d7a96=_0x33f11b['toRelativeCalendar']()):_0x33f11b['hasSame'](_0x419b8a,'week')?(_0xdecbb5=_0x33f11b['startOf']('week')['toJSDate'](),_0x2d7a96=_0x33f11b['weekdayLong']||''):_0x33f11b['hasSame'](_0x419b8a,'year')?(_0xdecbb5=_0x33f11b['startOf']('month')['toJSDate'](),_0x2d7a96=_0x33f11b['monthLong']||''):(_0xdecbb5=_0x33f11b['startOf']('year')['toJSDate'](),_0x2d7a96=String(_0x33f11b['year'])),{'startDate':_0xdecbb5,'localizedPeriodName':_0x2d7a96};}class mi extends _0x2c43c9{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x34d782,_0x4341ff,_0x42bdc2,_0x11d983){super(_0x34d782);const _0x109877=di(_0x4341ff,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x4341ff,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x42bdc2,this['_requireRevisionName']=_0x11d983,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':_0x109877}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x4ccaf3){const _0x3d30ed=new ai(this['locale'],_0x4ccaf3,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x3d30ed);}['removeRevision'](_0x4d4261){const _0xf31c4c=this['revisionViews']['find'](_0x22e299=>_0x22e299['id']===_0x4d4261['id']);this['revisionViews']['remove'](_0xf31c4c);}}class as extends _0x2c43c9{constructor(_0x5e47ec){super(_0x5e47ec);const _0x2d9a9f=new _0x544954();_0x2d9a9f['content']=_0x888a61['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2d9a9f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x5e47ec,'Revision\x20history')]}]});}}class ci extends _0x2c43c9{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0xf73ee9,_0x4dbff5,_0x4e7077,_0x593d4e){super(_0xf73ee9);const _0x59442b=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4dbff5,this['_revisionActions']=_0x4e7077,this['_requireRevisionName']=_0x593d4e,this['on']('select',(_0x2b8669,_0x3ab664)=>{this['fire']('revisionSelected',_0x3ab664);}),this['on']('setName',(_0x3087f7,_0x5648b9)=>{this['fire']('revisionSetName',_0x5648b9);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0xf73ee9),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x59442b['if']('isEnabled','ck-disabled',_0x5f02d2=>!_0x5f02d2)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2dc929 of this['_revisions'])this['_addRevision'](_0x2dc929);this['_revisions']['on']('add',(_0x1a269b,_0x2e8de3)=>{this['_addRevision'](_0x2e8de3);}),this['_revisions']['on']('remove',(_0x96f07d,_0x2e4979)=>{this['_removeRevision'](_0x2e4979);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2e98a8=>_0x2e98a8['revisionViews']['map'](_0x494419=>_0x494419))['flat']();}['selectRevision'](_0x1ca27c){for(const _0x492714 of this['revisionViews'])_0x1ca27c&&_0x1ca27c['id']===_0x492714['id']?_0x492714['select']():_0x492714['deselect']();}['highlightRevisions'](_0x4f6b91){for(const _0x4c1bd3 of this['revisionViews'])_0x4f6b91['some'](({id:_0x5eaa02})=>_0x5eaa02===_0x4c1bd3['id'])?_0x4c1bd3['highlight']():_0x4c1bd3['unhighlight']();}['_addRevision'](_0x5cc6cb){const _0x295da7=di(_0x5cc6cb['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x23e232=this['timePeriodViews']['get'](0x0);_0x23e232&&_0x23e232['startDate']['getTime']()===_0x295da7['getTime']()||(_0x23e232=new mi(this['locale'],_0x295da7,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x23e232)),_0x23e232['addRevision'](_0x5cc6cb);}['_removeRevision'](_0x3318f0){const _0x40e459=di(_0x3318f0['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x40e459)['removeRevision'](_0x3318f0);}['_getTimePeriodViewByStartDate'](_0x311728){return this['timePeriodViews']['find'](_0x3a056d=>_0x3a056d['startDate']['getTime']()===_0x311728['getTime']());}}class g extends _0x24aabd{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x1604e4,uid as _0x4c5b41,Collection as _0x510f19,logWarning as _0x355e99,FocusTracker as _0x517e8a,KeystrokeHandler as _0xdf8882,scrollViewportToShowTarget as _0xfae4f5,ResizeObserver as at,ElementReplacer as ct,CKEditorError as _0x147c38}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x3327e9,set as _0x352a3b,unset as _0x3f1f49,isEqual as _0x3ed3c3}from'lodash-es';import{Plugin as _0x4e17c7,PendingActions as _0x3ba5ec,icons as _0x3bf8ea,Command as _0x470aae,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x2edfe1,getMarkerDomElement as _0x10f5bf,ConfirmMixin as ti,sanitizeEditorConfig as _0x26dfbd}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x5d7012,ViewText as _0x448105,ViewElement as _0x24222b,Element as ft,Range as vt,Position as gt,DocumentFragment as mt,ViewContainerElement as _0x3cb2a9,ViewAttributeElement as _0x3121ff,ViewEmptyElement as _0x43ffa6,ViewRawElement as _0x113701,ViewUIElement as _0x46f8b2,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x3f2453,submitHandler as _0x2f836c,LabeledFieldView as _0x11555d,createLabeledInputText as _0x2f692f,createDropdown as _0x32fc3c,ListView as _0x30e1f8,ListItemView as _0x19040f,ButtonView as te,MenuBarMenuView as _0x353bde,MenuBarMenuListView as _0x3924bf,MenuBarMenuListItemView as _0x495609,MenuBarMenuListItemButtonView as _0x5e75f3,ContextualBalloon as _0x3444f0,ToolbarSeparatorView as _0x2540ab,IconView as _0x40c008,addListToDropdown as to,ViewModel as _0x4a878a,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x5aa3dd}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
+ _0x1604e4(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1fe598){super(),this['id']=_0x1fe598['id']||_0x4c5b41(),this['creator']=_0x1fe598['creator']||null,this['authors']=_0x1fe598['authors']||[],this['diffData']=_0x1fe598['diffData']||null,this['toVersion']=_0x1fe598['toVersion']||0x0,this['fromVersion']=_0x1fe598['fromVersion']||0x0,this['set']('name',_0x1fe598['name']||''),this['set']('createdAt',_0x1fe598['createdAt']||new Date()),this['set']('attributes',_0x1fe598['attributes']||{});}['setName'](_0x1b0484){this['_update']({'name':_0x1b0484});}['setAttribute'](_0x459ceb,_0x18b2b4){const _0x340cb5=_0x3327e9(this['attributes']);_0x352a3b(_0x340cb5,_0x459ceb,_0x18b2b4),this['_update']({'attributes':_0x340cb5});}['removeAttribute'](_0x10bea6){const _0x219be1=_0x3327e9(this['attributes']);_0x3f1f49(_0x219be1,_0x10bea6),this['_update']({'attributes':_0x219be1});}['_update'](_0x444572,_0x4df435=!0x1){let _0x4e3db4=!0x1;const _0x33af16={'id':this['id']},_0x1575c4=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x52cc04 of _0x1575c4){const _0x15874c=_0x444572[_0x52cc04];void 0x0!==_0x15874c&&_0x15874c!==this[_0x52cc04]&&(this[_0x52cc04]=_0x15874c,_0x33af16[_0x52cc04]=_0x15874c,_0x4e3db4=!0x0);}_0x4e3db4&&(_0x33af16['authors']&&(_0x33af16['authorsIds']=_0x33af16['authors']['map'](_0x475b1f=>_0x475b1f['id']),delete _0x33af16['authors']),this['fire']('_update',_0x33af16,_0x4df435));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4df8c0=>_0x4df8c0['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x4e17c7{['_revisions'];static get['requires'](){return[_0x2edfe1];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xf5bf6a){super(_0xf5bf6a),this['_revisions']=new _0x510f19();}['afterInit'](){!async function(_0x4f7c49){const _0x162cdb=_0xa3734([0x42,0x6f,0x63,0x50,0x45,0x67,0x6d,0x62,0x48,0x4a,0x65,0x4f,0x53,0x59,0x57,0x56,0x47,0x4b,0x37,0x51,0x55,0x6b,0x70,0x36,0x76,0x54,0x31,0x38,0x52,0x39,0x7a,0x44,0x46,0x4d,0x64,0x32,0x6a,0x4e,0x43,0x4c,0x41,0x61,0x34,0x77,0x71,0x75,0x74,0x78,0x33,0x49,0x6e,0x6c,0x68,0x73,0x58,0x30,0x5a,0x35,0x66,0x79,0x72,0x69]),_0x26359d=0xeb829,_0x27c57a=0x1c9ecc82,_0x36f52c=0x1c9994c2^_0x27c57a,_0x2bfc51=window[_0xa3734([0x44,0x61,0x74,0x65])][_0xa3734([0x6e,0x6f,0x77])](),_0x250c4a=_0x4f7c49[_0xa3734([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5071e9=new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x20fca6=>{_0x250c4a[_0xa3734([0x6f,0x6e,0x63,0x65])](_0xa3734([0x72,0x65,0x61,0x64,0x79]),_0x20fca6);}),_0x3a6196={[_0xa3734([0x6b,0x74,0x79])]:_0xa3734([0x45,0x43]),[_0xa3734([0x75,0x73,0x65])]:_0xa3734([0x73,0x69,0x67]),[_0xa3734([0x63,0x72,0x76])]:_0xa3734([0x50,0x2d,0x32,0x35,0x36]),[_0xa3734([0x78])]:_0xa3734([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]),[_0xa3734([0x79])]:_0xa3734([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]),[_0xa3734([0x61,0x6c,0x67])]:_0xa3734([0x45,0x53,0x32,0x35,0x36])},_0x36e547=_0x250c4a[_0xa3734([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xa3734([0x67,0x65,0x74])](_0xa3734([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4b9177(){let _0x4442b5,_0x294331=null,_0x3266cf=null;try{if(_0x36e547==_0xa3734([0x47,0x50,0x4c]))return _0xa3734([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x4442b5=_0x2925cf(),!_0x4442b5)return _0xa3734([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x4442b5[_0xa3734([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3266cf=_0xacfe86(_0x4442b5[_0xa3734([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x4442b5[_0xa3734([0x6a,0x74,0x69])])),await _0x407a6f()?_0x4780bd()?_0x1c7143()?_0xa3734([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x545791()?(_0x4442b5[_0xa3734([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa3734([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x294331=_0x32b6bb(_0xa3734([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x4442b5[_0xa3734([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa3734([0x74,0x72,0x69,0x61,0x6c])&&(_0x294331=_0x32b6bb(_0xa3734([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x4442b5[_0xa3734([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa3734([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x294331=_0x32b6bb(_0xa3734([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x13bfa0()):_0xa3734([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xa3734([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xa3734([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x295835){return _0xa3734([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1c7143(){const _0x488bf6=[_0xa3734([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xa3734([0x74,0x72,0x69,0x61,0x6c])][_0xa3734([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4442b5[_0xa3734([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2bfc51/0x3e8:0xe10*_0x36f52c;return _0x4442b5[_0xa3734([0x65,0x78,0x70])]<_0x488bf6;}function _0x4780bd(){const _0xb08bec=_0x4442b5[_0xa3734([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0xb08bec)return!0x1;if(_0xb08bec[_0xa3734([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa3734([0x2a])))return!0x0;if(_0xb08bec[_0xa3734([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa3734([0x52,0x48])))return!0x0;if(_0xb08bec[_0xa3734([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa3734([0x52,0x52,0x48]))){if(_0x630ccd())return!0x0;if(_0x59064c()||_0x5aebde())return!0x0;}return!0x1;}function _0x545791(){const _0x2e1f0f=_0x4442b5[_0xa3734([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2e1f0f||0x0==_0x2e1f0f[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x535b56}=new URL(window[_0xa3734([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2e1f0f[_0xa3734([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x535b56))return!0x0;const _0x2a6c2a=_0x535b56[_0xa3734([0x73,0x70,0x6c,0x69,0x74])](_0xa3734([0x2e]));return _0x2e1f0f[_0xa3734([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x48a125=>_0x48a125[_0xa3734([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa3734([0x2a])))[_0xa3734([0x6d,0x61,0x70])](_0x233036=>_0x233036[_0xa3734([0x73,0x70,0x6c,0x69,0x74])](_0xa3734([0x2e])))[_0xa3734([0x73,0x6f,0x6d,0x65])](_0x32528=>_0x2a6c2a[_0xa3734([0x65,0x76,0x65,0x72,0x79])]((_0x2ad478,_0x1748ad)=>_0x32528[_0x1748ad]===_0x2ad478||_0x32528[_0x1748ad]===_0xa3734([0x2a])));}function _0x13bfa0(){return _0x294331&&_0x3266cf?new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1aeb87,_0x4262bc)=>{_0x294331[_0xa3734([0x74,0x68,0x65,0x6e])](_0x1aeb87,_0x4262bc),_0x3266cf[_0xa3734([0x74,0x68,0x65,0x6e])](_0x481327=>{_0x481327!=_0xa3734([0x56,0x61,0x6c,0x69,0x64])&&_0x1aeb87(_0x481327);},_0x4262bc);}):_0x294331||_0x3266cf||_0xa3734([0x56,0x61,0x6c,0x69,0x64]);}}function _0xacfe86(_0x9eeb,_0x2b0efc){return new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x12a70d=>{if(_0x4c4ab1())return _0x12a70d(_0xa3734([0x56,0x61,0x6c,0x69,0x64]));_0x5b4b61(),_0x250c4a[_0xa3734([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xa3734([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x13096c=!0x1;const _0x5d66ff=_0x4c5b41();function _0x5028e9(_0x46cce3){return!!_0x46cce3&&(typeof _0x46cce3===_0xa3734([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x46cce3===_0xa3734([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x46cce3[_0xa3734([0x74,0x68,0x65,0x6e])]===_0xa3734([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x46cce3[_0xa3734([0x63,0x61,0x74,0x63,0x68])]===_0xa3734([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x900ba8(_0x52d026){_0xe6fe16(_0x52d026)[_0xa3734([0x74,0x68,0x65,0x6e])](_0x6ccc5b=>{if(!_0x6ccc5b||_0x6ccc5b[_0xa3734([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xa3734([0x6f,0x6b]))return _0xa3734([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x55e4da(_0x5f3c7c(_0x5d66ff+_0x2b0efc))!=_0x6ccc5b[_0xa3734([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xa3734([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xa3734([0x56,0x61,0x6c,0x69,0x64]);})[_0xa3734([0x74,0x68,0x65,0x6e])](_0x19d2cb=>(_0x17ee31(),_0x19d2cb),()=>{const _0x2acac1=_0x2017ee();return null==_0x2acac1?(_0x17ee31(),_0xa3734([0x56,0x61,0x6c,0x69,0x64])):_0xa3734(_0x2bfc51-_0x2acac1>(0x38924882^_0x27c57a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xa3734([0x74,0x68,0x65,0x6e])](_0x12a70d)[_0xa3734([0x63,0x61,0x74,0x63,0x68])](()=>{_0x12a70d(_0xa3734([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x26db6a=0x1ca82202^_0x27c57a;function _0x17ee31(){const _0x2aed87=_0xa3734([0x6c,0x6c,0x63,0x74,0x2d])+_0x55e4da(_0x5f3c7c(_0x9eeb)),_0x38c90b=_0x5a4d05(_0x55e4da(window[_0xa3734([0x4d,0x61,0x74,0x68])][_0xa3734([0x63,0x65,0x69,0x6c])](_0x2bfc51/_0x26db6a)));window[_0xa3734([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xa3734([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2aed87,_0x38c90b);}function _0x2017ee(){const _0x2fe770=_0xa3734([0x6c,0x6c,0x63,0x74,0x2d])+_0x55e4da(_0x5f3c7c(_0x9eeb)),_0xda29e7=window[_0xa3734([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xa3734([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2fe770);return _0xda29e7?window[_0xa3734([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5a4d05(_0xda29e7),0x10)*_0x26db6a:null;}function _0xe6fe16(_0x4603c9){return new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2f9efc,_0x39daa6)=>{_0x4603c9[_0xa3734([0x74,0x68,0x65,0x6e])](_0x2f9efc,_0x39daa6),window[_0xa3734([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x39daa6,0x1c9f1842^_0x27c57a);});}}_0x250c4a[_0xa3734([0x6f,0x6e])](_0xa3734([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x7a7edc,_0x20025c)=>{if(_0x20025c[0x0]!=_0x9eeb)return _0x12a70d(_0xa3734([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x20025c[0x1]={..._0x20025c[0x1],[_0xa3734([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5d66ff};},{[_0xa3734([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xa3734([0x68,0x69,0x67,0x68])}),_0x250c4a[_0xa3734([0x6f,0x6e])](_0xa3734([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x46c966=>{_0x5028e9(_0x46c966[_0xa3734([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x13096c=!0x0,_0x900ba8(_0x46c966[_0xa3734([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xa3734([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xa3734([0x6c,0x6f,0x77])}),_0x5071e9[_0xa3734([0x74,0x68,0x65,0x6e])](()=>{_0x13096c||_0x12a70d(_0xa3734([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4c4ab1(){return _0x250c4a[_0xa3734([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa3734([0x76,0x69,0x65,0x77])][_0xa3734([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xa3734([0x61,0x75,0x74,0x6f]);}function _0x5b4b61(){_0x250c4a[_0xa3734([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa3734([0x76,0x69,0x65,0x77])][_0xa3734([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xa3734([0x61,0x75,0x74,0x6f]);}}function _0x32b6bb(_0x34eacb){const _0x40ce8d=[new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x510182=>setTimeout(_0x510182,0x1c97f24e^_0x27c57a)),_0x5071e9[_0xa3734([0x74,0x68,0x65,0x6e])](()=>new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4a4f33=>{const _0x119320=0x1c9ecc85^_0x27c57a,_0x1be0ee=_0x4f7c49[_0xa3734([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x261c34(){_0x1be0ee[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x119320&&_0x4a4f33();}_0x261c34(),_0x1be0ee[_0xa3734([0x6f,0x6e])](_0xa3734([0x61,0x64,0x64]),_0x261c34);})),new window[(_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5a1076=>{function _0x5005a7(){for(const _0x23c7c1 in window)if(window[_0xa3734([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0xa3734([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x23c7c1))&&window[_0x23c7c1]==_0x26359d)return _0x5a1076();_0x250c4a[_0xa3734([0x73,0x74,0x61,0x74,0x65])]!=_0xa3734([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0xa3734([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5005a7,0x1c9edf0a^_0x27c57a);}_0x22a37c(_0xa3734([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5005a7();})];return window[_0xa3734([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xa3734([0x72,0x61,0x63,0x65])](_0x40ce8d)[_0xa3734([0x74,0x68,0x65,0x6e])](()=>_0x34eacb);}async function _0x21644b(){if(await _0x5071e9,_0x22a37c(_0xa3734([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x44c3af=_0x4f7c49[_0xa3734([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x6578e0=_0x4f7c49[_0xa3734([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])](_0x44c3af[_0xa3734([0x69,0x64])]),_0x2374e3=_0x35bd30(_0xa3734([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2374e3[_0xa3734([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x44c3af['id'],_0x6578e0?_0x6578e0['id']:null,!0x0),_0x2374e3[_0xa3734([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xa3734([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2374e3[_0xa3734([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2374e3[_0xa3734([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x3cd0b3,void(_0x2374e3[_0xa3734([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x3cd0b3);}if(_0x22a37c(_0xa3734([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x17dec5=_0x35bd30(_0xa3734([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x17dec5[_0xa3734([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xa3734([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x17dec5[_0xa3734([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x17dec5[_0xa3734([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x3cd0b3,_0x17dec5[_0xa3734([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x3cd0b3;}_0x250c4a[_0xa3734([0x6d,0x6f,0x64,0x65,0x6c])][_0xa3734([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3cd0b3,_0x250c4a[_0xa3734([0x6d,0x6f,0x64,0x65,0x6c])][_0xa3734([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3cd0b3,_0x250c4a[_0xa3734([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xa3734([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x630ccd(){return _0x22a37c(_0xa3734([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x35bd30(_0xa3734([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0xa3734([0x73,0x74,0x61,0x74,0x65])]==_0xa3734([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x59064c(){return _0x22a37c(_0xa3734([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 _0x5aebde(){return _0x22a37c(_0xa3734([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xd096bf(_0x348627){const _0x3fd210=_0xd86a2e();_0x250c4a[_0x3fd210]=_0xa3734([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])+_0x348627,_0x348627[_0xa3734([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0xa3734([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0xd86a2e()]=_0x26359d),_0x348627!=_0xa3734([0x56,0x61,0x6c,0x69,0x64])&&_0x21644b();}function _0xd86a2e(){const _0x35a215=window[_0xa3734([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xa3734([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xa3734([0x6e,0x6f,0x77])]())[_0xa3734([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xa3734([0x2e]),'');let _0x4097ce=_0xa3734([0x42]);for(let _0x345187=0x0;_0x345187<_0x35a215[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x345187+=0x2){let _0x4a4e4d=window[_0xa3734([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x35a215[_0xa3734([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x345187,_0x345187+0x2));_0x4a4e4d>=_0x162cdb[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x4a4e4d-=_0x162cdb[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4097ce+=_0x162cdb[_0x4a4e4d];}return _0x4097ce;}function _0x2925cf(){const _0x1834f7=_0x36e547[_0xa3734([0x73,0x70,0x6c,0x69,0x74])](_0xa3734([0x2e]));if(0x3!=_0x1834f7[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x56a412(_0x1834f7[0x1]);function _0x56a412(_0x3c9098){const _0x6d8655=_0x146d57(_0x3c9098);return _0x6d8655&&_0x4bb1af()?_0x6d8655:null;function _0x4bb1af(){const _0x38ad72=_0x6d8655[_0xa3734([0x6a,0x74,0x69])],_0x3ed77f=window[_0xa3734([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x38ad72[_0xa3734([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x38ad72[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xc65eab={..._0x6d8655,[_0xa3734([0x6a,0x74,0x69])]:_0x38ad72[_0xa3734([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x38ad72[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xc65eab[_0xa3734([0x76,0x63])],_0x5f3c7c(_0xc65eab)==_0x3ed77f;}}}async function _0x407a6f(){let _0x4dfc4b=!0x0;try{const _0x17511e=_0x36e547[_0xa3734([0x73,0x70,0x6c,0x69,0x74])](_0xa3734([0x2e])),[_0x37c4ba,_0x4dbd39,_0x5a7114]=_0x17511e;return _0x252aa0(_0x37c4ba),await _0x21c286(_0x37c4ba,_0x4dbd39,_0x5a7114),_0x4dfc4b;}catch(_0x4230a7){return!0x1;}function _0x252aa0(_0x4926bb){const _0x213dd2=_0x146d57(_0x4926bb);_0x213dd2&&_0x213dd2[_0xa3734([0x61,0x6c,0x67])]==_0xa3734([0x45,0x53,0x32,0x35,0x36])||(_0x4dfc4b=!0x1);}async function _0x21c286(_0x24192e,_0x58ff2a,_0xed0546){const _0x4e4714=window[_0xa3734([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xa3734([0x66,0x72,0x6f,0x6d])](_0x71ebe5(_0xed0546),_0x1552a4=>_0x1552a4[_0xa3734([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1ec5b3=new window[(_0xa3734([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xa3734([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x24192e+_0xa3734([0x2e])+_0x58ff2a),_0x3bba2b=window[_0xa3734([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xa3734([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3bba2b)return;const _0x5e4604=await _0x3bba2b[_0xa3734([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xa3734([0x6a,0x77,0x6b]),_0x3a6196,{[_0xa3734([0x6e,0x61,0x6d,0x65])]:_0xa3734([0x45,0x43,0x44,0x53,0x41]),[_0xa3734([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xa3734([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xa3734([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3bba2b[_0xa3734([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xa3734([0x6e,0x61,0x6d,0x65])]:_0xa3734([0x45,0x43,0x44,0x53,0x41]),[_0xa3734([0x68,0x61,0x73,0x68])]:{[_0xa3734([0x6e,0x61,0x6d,0x65])]:_0xa3734([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5e4604,_0x4e4714,_0x1ec5b3)||(_0x4dfc4b=!0x1);}}function _0x146d57(_0x579427){return _0x579427[_0xa3734([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xa3734([0x65,0x79]))?JSON[_0xa3734([0x70,0x61,0x72,0x73,0x65])](_0x71ebe5(_0x579427)):null;}function _0x71ebe5(_0x2e2283){return window[_0xa3734([0x61,0x74,0x6f,0x62])](_0x2e2283[_0xa3734([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xa3734([0x2b]))[_0xa3734([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xa3734([0x2f])));}function _0x5f3c7c(_0x12ac8b){let _0x38f1b4=0x1505;function _0x46d407(_0x472652){for(let _0x524fb4=0x0;_0x524fb4<_0x472652[_0xa3734([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x524fb4++){const _0x5c1d3c=_0x472652[_0xa3734([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x524fb4);_0x38f1b4=(_0x38f1b4<<0x5)+_0x38f1b4+_0x5c1d3c,_0x38f1b4&=_0x38f1b4;}}function _0xac2cdb(_0x4932bd){Array[_0xa3734([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4932bd)?_0x4932bd[_0xa3734([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0xac2cdb):_0x4932bd&&typeof _0x4932bd==_0xa3734([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xa3734([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4932bd)[_0xa3734([0x73,0x6f,0x72,0x74])]()[_0xa3734([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1ad31f,_0x4c493e])=>{_0x46d407(_0x1ad31f),_0xac2cdb(_0x4c493e);}):_0x46d407(window[_0xa3734([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4932bd));}return _0xac2cdb(_0x12ac8b),_0x38f1b4>>>0x0;}function _0x55e4da(_0x152a63){return _0x152a63[_0xa3734([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xa3734([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xa3734([0x30]));}function _0x5a4d05(_0x3145d2){return _0x3145d2[_0xa3734([0x73,0x70,0x6c,0x69,0x74])]('')[_0xa3734([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xa3734([0x6a,0x6f,0x69,0x6e])]('');}function _0x22a37c(_0x1248f2){return _0x250c4a[_0xa3734([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xa3734([0x68,0x61,0x73])](_0x1248f2);}function _0x35bd30(_0x458dae){return _0x250c4a[_0xa3734([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xa3734([0x67,0x65,0x74])](_0x458dae);}function _0x3cd0b3(){}function _0xa3734(_0x2835ab){return _0x2835ab['map'](_0x378bce=>String['fromCharCode'](_0x378bce))['join']('');}_0xd096bf(await _0x4b9177());}(this);}['createRevision'](_0xb94a6d){const _0x41afce=this['editor']['plugins']['get']('Users');return new a({'id':_0xb94a6d['id'],'name':_0xb94a6d['name'],'creator':_0xb94a6d['creatorId']?_0x41afce['getUser'](_0xb94a6d['creatorId']):null,'diffData':_0xb94a6d['diffData']||_0xb94a6d['data'],'authors':_0xb94a6d['authorsIds']['map'](_0x245295=>_0x41afce['getUser'](_0x245295)),'createdAt':new Date(_0xb94a6d['createdAt']),'attributes':_0xb94a6d['attributes'],'fromVersion':_0xb94a6d['fromVersion'],'toVersion':_0xb94a6d['toVersion']});}['addRevision'](_0x1d853e,_0xc7e884=0x0){this['_revisions']['add'](_0x1d853e,_0xc7e884);}['getRevision'](_0x4d619b){return this['_revisions']['get'](_0x4d619b);}['getRevisions'](_0x85e70f={'toJSON':!0x1}){const _0x1ecd51=Array['from'](this['_revisions']);return _0x1ecd51['reverse'](),_0x85e70f['toJSON']?_0x1ecd51['map'](_0x1c6a78=>_0x1c6a78['toJSON']()):_0x1ecd51;}['getIndex'](_0x29dbd6){return this['_revisions']['getIndex'](_0x29dbd6);}['getEarlierVisibleRevision'](_0x3c4b43){const [,_0x3a7271]=this['getRevisionsIterator'](_0x3c4b43,{'direction':'earlier'});return _0x3a7271;}['getLaterVisibleRevision'](_0x78500e){const [,_0x22d0ed]=this['getRevisionsIterator'](_0x78500e,{'direction':'later'});return _0x22d0ed;}['getRevisionsInDiff'](_0x3c8109){const _0xc487ee=[];for(const _0x2b29d5 of this['getRevisionsIterator'](_0x3c8109['newRevisionId']))if(_0xc487ee['push'](_0x2b29d5),_0x2b29d5['id']===_0x3c8109['oldRevisionId'])break;return _0xc487ee;}*['getRevisionsIterator'](_0x47cfd2,{direction:_0x2ae445='earlier',filter:_0x2125d1=()=>!0x0}={}){const _0x30a38f='earlier'===_0x2ae445?0x1:-0x1;let _0x17043b=this['_revisions']['get'](_0x47cfd2),_0x1656ea=this['getIndex'](_0x17043b);for(yield _0x17043b;_0x17043b;){if(_0x1656ea+=_0x30a38f,_0x17043b=this['getRevision'](_0x1656ea),!_0x17043b)return;_0x2125d1(_0x17043b)&&(yield _0x17043b);}}}function R(_0x3ed5ed,_0x2d34b5,_0x506f0d){const t=_0x3ed5ed['t'];switch(_0x2d34b5){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'},_0x506f0d);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x506f0d);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const C={'c':_0x3cb2a9,'a':_0x3121ff,'e':_0x43ffa6,'r':_0x113701,'u':_0x46f8b2};class l extends _0x4e17c7{['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[_0x2edfe1,j,_0x3ba5ec];}constructor(_0x53ad9b){super(_0x53ad9b),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x198d31=_0x4c5b41();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x198d31},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 _0x323060=this['repository']['getRevision'](0x0),_0x20d06f=_0x323060&&null===_0x323060['creator']?_0x323060:null;if(this['_continueCurrentRevision']=!!_0x20d06f&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x34b2f8=this['_source']['getCurrentRevisionId'](),_0x3aedff=this['repository']['getRevision'](_0x34b2f8);if(_0x3aedff)this['_startingVersion']=_0x3aedff['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x3b4e4a=this['_source']['history']['_operations']['find'](_0x126f31=>!_0x126f31['_isInit']),_0xacedbb=_0x3b4e4a?_0x3b4e4a['baseVersion']:this['_source']['history']['version'];_0x323060?(_0x323060['toVersion']<_0xacedbb&&_0x323060['_update']({'toVersion':_0xacedbb}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x20d06f['id'],this['_startingVersion']=_0x20d06f['fromVersion']):(this['_startingVersion']=_0x323060['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0xacedbb,this['_continueCurrentRevision']=!0x1);}}else _0x20d06f&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x20d06f['toVersion'],this['editor']['model']['document']['history']['version']),_0x20d06f['fromVersion']===_0x20d06f['toVersion']?(0x0!==_0x20d06f['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x20d06f['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x20d06f['id'],this['_startingVersion']=_0x20d06f['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',_0x38d294=>!_0x38d294),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x50d99f=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5a5fd0;for(const _0x4c3b05 in _0x50d99f){const _0x54079e=_0x4c3b05,_0x599a7c=_0x50d99f[_0x54079e];if('revisionHistoryLicenseKeyValid'==_0x599a7c||'revisionHistoryLicenseKeyInvalid'==_0x599a7c||'revisionHistoryLicenseKeyExpired'==_0x599a7c||'revisionHistoryLicenseKeyDomainLimit'==_0x599a7c||'revisionHistoryLicenseKeyNotAllowed'==_0x599a7c||'revisionHistoryLicenseKeyEvaluationLimit'==_0x599a7c||'revisionHistoryLicenseKeyTrialLimit'==_0x599a7c||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x599a7c||'revisionHistoryLicenseKeyUsageLimit'==_0x599a7c){delete _0x50d99f[_0x54079e],_0x5a5fd0=_0x599a7c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5a5fd0&&_0x50d99f['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x143d4b=this['repository']['getRevision'](0x0),_0x27008d=await this['getRevisionDocumentData'](_0x143d4b),_0xd09f4e=await this['getRevisionRootsAttributes'](_0x143d4b);this['_replaceEditorDataWithRevisionData'](_0x27008d,_0xd09f4e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5efe0d){this['_source']=_0x5efe0d;}async['update'](){const _0x13d0df=await this['_source']['getLatestVersion']();if(_0x13d0df>this['currentRevision']['toVersion']){await this['_loadState']();const _0x346d36=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x13d0df});_0x346d36['authors']=_0x346d36['authorsIds']['map'](_0x51888c=>this['editor']['plugins']['get']('Users')['getUser'](_0x51888c)),this['currentRevision']['_update'](_0x346d36);}}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'](_0x3d17ca={},_0x1e1ea9=null){const _0x3475a4=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x1e1ea9>this['currentRevision']['toVersion']&&(_0x1e1ea9=null),null===_0x1e1ea9&&(_0x1e1ea9=await this['_source']['getLatestVersion']());const _0x46818c=this['_getFromVersion'](_0x1e1ea9),_0x3c46fd=this['buildRevisionData']({'from':_0x46818c,'to':_0x1e1ea9});if(this['currentRevision']['toVersion']<_0x1e1ea9){const _0x1e59f3=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x1e1ea9,'to':_0x1e1ea9});_0x1e59f3['authors']=[],_0x1e59f3['authorsIds']=[],_0x1e59f3['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1e59f3,!0x0),delete _0x1e59f3['authors'],_0x3475a4['push'](_0x1e59f3);}_0x3d17ca['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3d17ca['name']=_0x3d17ca['name']||null,_0x3d17ca['id']=_0x3d17ca['id']||_0x4c5b41(),_0x3d17ca={..._0x3d17ca,..._0x3c46fd};const _0x51c4b4=this['addRevisionData'](_0x3d17ca);_0x3475a4['push'](_0x3d17ca);const _0x2a0760=this['repository']['getIndex'](_0x51c4b4);if(0x0!==_0x2a0760){const _0x6cd55b=this['repository']['getRevision'](_0x2a0760-0x1);if(_0x6cd55b['fromVersion']!==_0x1e1ea9){const _0x26b007=this['_revisionDataBuilder']['getData'](_0x1e1ea9,_0x6cd55b['toVersion']),_0x3fbf0a={'id':_0x6cd55b['id'],'diffData':_0x26b007['diffData'],'authorsIds':_0x26b007['authorsIds'],'authors':_0x26b007['authorsIds']['map'](_0x109128=>this['editor']['plugins']['get']('Users')['getUser'](_0x109128)),'fromVersion':_0x1e1ea9};_0x6cd55b===this['currentRevision']&&(_0x3fbf0a['createdAt']=new Date(_0x3d17ca['createdAt']['getTime']()+0xa)),_0x6cd55b['_update'](_0x3fbf0a,!0x0),delete _0x3fbf0a['authors'],_0x3475a4['push'](_0x3fbf0a);}}if(this['adapter']){for(const _0x5f407d of _0x3475a4)this['_bufferUpdate'](_0x5f407d['id'],_0x5f407d,!0x0);this['sendBufferedUpdates']();}return _0x51c4b4;}['addRevisionData'](_0xf57ad){const _0x351d3e=this['repository']['createRevision'](_0xf57ad);return this['adapter']&&_0x351d3e['on']('_update',(_0x198328,_0x5a908f,_0x17e47c)=>{_0x17e47c||(this['_bufferUpdate'](_0x5a908f['id'],_0x5a908f,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x351d3e,this['_findInsertionIndex'](_0x351d3e)),_0x351d3e;}async['getRevisionDocumentData'](_0xd2e630){await this['_loadRevisionData'](_0xd2e630);const _0x4b5882={};for(const _0x1b21f6 in _0xd2e630['diffData']){if(_0xd2e630['diffData'][_0x1b21f6]['attachChange']&&!_0xd2e630['diffData'][_0x1b21f6]['attachChange']['isAttached'])continue;const _0x311435=this['_removeRevisionMarkers'](JSON['parse'](_0xd2e630['diffData'][_0x1b21f6]['insertions'])),_0x33d31f=this['editor']['editing']['view']['document'],_0x3c9e1e=new _0x5d7012(_0x33d31f,_0x311435['map'](_0x5d75ec=>V(_0x5d75ec,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x4b5882[_0x1b21f6]=this['editor']['data']['processor']['toData'](_0x3c9e1e),this['editor']['data']['processor']['useFillerType']('default');}return _0x4b5882;}async['getRevisionRootsAttributes'](_0x207728){await this['_loadRevisionData'](_0x207728);const _0x2411a0={};for(const _0x1e250b in _0x207728['diffData'])_0x207728['diffData'][_0x1e250b]['attachChange']&&!_0x207728['diffData'][_0x1e250b]['attachChange']['isAttached']||(_0x2411a0[_0x1e250b]=_0x207728['diffData'][_0x1e250b]['attributesAfter']||{});return _0x2411a0;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x339dd8=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4205ff=0x0;_0x4205ff<_0x339dd8['length'];_0x4205ff++){const _0x5d25d2=_0x339dd8[_0x4205ff];let _0x141af4=!0x1;for(const _0x4c4bc6 of Object['keys'](_0x5d25d2))void 0x0===_0x5d25d2[_0x4c4bc6]?delete _0x5d25d2[_0x4c4bc6]:'id'!==_0x4c4bc6&&(_0x141af4=!0x0);_0x141af4||(_0x339dd8[_0x4205ff]=null);}if(_0x339dd8=_0x339dd8['filter'](_0x329ee4=>null!==_0x329ee4),!_0x339dd8['length'])return;for(let _0x25623a=0x0;_0x25623a<_0x339dd8['length'];_0x25623a++){const _0x3670c4=_0x339dd8[_0x25623a];void 0x0!==_0x3670c4['fromVersion']&&void 0x0===_0x3670c4['toVersion']&&(_0x3670c4['toVersion']=this['repository']['getRevision'](_0x3670c4['id'])['toVersion']),void 0x0!==_0x3670c4['toVersion']&&void 0x0===_0x3670c4['fromVersion']&&(_0x3670c4['fromVersion']=this['repository']['getRevision'](_0x3670c4['id'])['fromVersion']);}const _0x361c1d=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x339dd8,_0x361c1d)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x563c1a=>{if(_0x563c1a){for(const _0x141d65 of _0x563c1a)this['setRevisionData']({'id':_0x141d65['id'],'createdAt':_0x141d65['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x1df4d2,_0x68ee09){let _0x3154ec=this['editor']['config']['get']('initialData'),_0x2714ee=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x3154ec){_0x3154ec={};for(const _0x5d42a9 of this['editor']['model']['document']['getRootNames']())_0x3154ec[_0x5d42a9]='';}if('string'==typeof _0x3154ec&&(_0x3154ec={'main':_0x3154ec}),void 0x0===_0x2714ee){_0x2714ee={};for(const _0x2372bd of this['editor']['model']['document']['getRootNames']())_0x2714ee[_0x2372bd]={};}let _0x3dd4a7=!0x1;const _0x18d406=Object['keys'](_0x3154ec),_0x4e3dec=Object['keys'](_0x1df4d2);for(const _0x36327c of _0x18d406){if(_0x3154ec[_0x36327c]!==_0x1df4d2[_0x36327c]&&''!==_0x3154ec[_0x36327c]['trim']()){_0x3dd4a7=!0x0;break;}if(!_0x3ed3c3(_0x2714ee[_0x36327c],_0x68ee09[_0x36327c])&&Object['keys'](_0x2714ee[_0x36327c])['length']>0x0){_0x3dd4a7=!0x0;break;}}_0x3dd4a7||(_0x3dd4a7=_0x4e3dec['some'](_0x328bc7=>!this['editor']['model']['document']['getRoot'](_0x328bc7))),_0x3dd4a7&&_0x355e99('editor-initial-data-replaced-with-revision-data',{'editorData':_0x3154ec,'editorRootsAttributes':_0x2714ee,'revisionData':_0x1df4d2,'revisionRootsAttributes':_0x68ee09}),this['editor']['config']['set']('initialData',_0x1df4d2),this['editor']['config']['set']('rootsAttributes',_0x68ee09);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x1787cd=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x1787cd['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4148b9){const _0x170469=this['repository']['getRevisions']();_0x170469['reverse']();let _0x477204=0x0;for(;_0x477204<_0x170469['length'];){const _0x26bd1d=_0x170469[_0x477204];if(_0x26bd1d===this['currentRevision']){_0x477204++;continue;}if(_0x26bd1d['id']===this['_initialRevisionId'])break;const _0x4b0bab=_0x4148b9['toVersion']-_0x26bd1d['toVersion']||_0x4148b9['fromVersion']-_0x26bd1d['fromVersion'];if(_0x4b0bab>0x0)break;if(_0x4b0bab<0x0)_0x477204++;else{if(!_0x4148b9['creator']&&_0x26bd1d['creator'])break;if(_0x26bd1d['creator']||!_0x4148b9['creator']){if(_0x4148b9['createdAt']>_0x26bd1d['createdAt'])break;_0x477204++;}else _0x477204++;}}return _0x477204;}['setRevisionData'](_0xf34423){const _0x87bffd=this['repository']['getRevision'](_0xf34423['id']);if(_0xf34423['createdAt']&&(_0xf34423['createdAt']=new Date(_0xf34423['createdAt'])),_0xf34423['authorsIds']){const _0x4fa6b5=this['editor']['plugins']['get']('Users');_0xf34423['authors']=_0xf34423['authorsIds']['map'](_0x32614e=>_0x4fa6b5['getUser'](_0x32614e));}_0x87bffd['_update'](_0xf34423,!0x0);}['buildRevisionData']({revision:_0x354189=null,from:_0x110dcb=null,to:_0x2c7d03=null}){_0x110dcb=null!==_0x110dcb?_0x110dcb:_0x354189['fromVersion'],_0x2c7d03=null!==_0x2c7d03?_0x2c7d03:_0x354189['toVersion'];const _0x1e7452=this['_revisionDataBuilder']['getData'](_0x110dcb,_0x2c7d03),_0x4ab2cc={'diffData':_0x1e7452['diffData'],'authorsIds':_0x1e7452['authorsIds'],'fromVersion':_0x110dcb,'toVersion':_0x2c7d03};if(!_0x354189||_0x2c7d03!==_0x354189['toVersion']){const _0x4c0ad3=_0x2c7d03-0x1,_0x2258d0=this['_source']['history']['getOperation'](_0x4c0ad3);_0x4ab2cc['createdAt']=_0x2258d0&&_0x2258d0['createdAt']||new Date();}if(this['_loadedStateData']&&_0x110dcb===this['_loadedStateData']['fromVersion']){for(const _0xf09ba9 of this['_loadedStateData']['authors'])_0x4ab2cc['authorsIds']['includes'](_0xf09ba9['id'])||_0x4ab2cc['authorsIds']['push'](_0xf09ba9['id']);}return _0x4ab2cc;}['_loadRevisionData'](_0xb0a1b9){if(!_0xb0a1b9||_0xb0a1b9['diffData'])return Promise['resolve']();{const _0x132a48=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x132a48,'revisionId':_0xb0a1b9['id']})['then'](_0x31d51c=>{_0xb0a1b9['diffData']=_0x31d51c['diffData'];});}}['_bufferUpdate'](_0x3dc3fd,_0x2f94c2,_0x2340fc){if(this['_bufferedUpdates']['has'](_0x3dc3fd)){const _0x31fe53=this['_bufferedUpdates']['get'](_0x3dc3fd);_0x2f94c2=_0x2340fc?{..._0x31fe53,..._0x2f94c2}:{..._0x2f94c2,..._0x31fe53};}this['_bufferedUpdates']['set'](_0x3dc3fd,_0x2f94c2);}['_getFromVersion'](_0x38b7b2){const _0x3e5ffe=this['repository']['getRevisions']();_0x3e5ffe['reverse'](),_0x3e5ffe['shift']();const _0x249e53=_0x3e5ffe['find'](_0x506e4d=>_0x506e4d['toVersion']<=_0x38b7b2)['toVersion'];return _0x249e53<this['_startingVersion']?this['_startingVersion']:_0x249e53;}['_createInitialRevision'](_0x3dc9b2){const _0x2f0ad1=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2f0ad1)this['_initialRevisionId']=_0x2f0ad1['id'];else{const _0x1c5b54=!this['editor']['model']['document']['roots']['find'](_0x13d44d=>this['editor']['model']['hasContent'](_0x13d44d)),_0x55f3ff=this['editor']['plugins']['get']('Users')['me']['id'],_0x240449=R(this['editor']['locale'],_0x1c5b54?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3dc9b2,'to':_0x3dc9b2,'id':this['_initialRevisionId'],'name':_0x240449,'creatorId':_0x55f3ff});}}['_createCurrentRevision'](_0x530a63){const _0x268c26=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x268c26),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x530a63,'to':_0x530a63,'id':_0x268c26,'name':'','creatorId':null}));}['_makeRevision']({name:_0x37773f,from:_0x2177df,to:_0x25933d,creatorId:_0x3f4ff8,id:_0x517d6b}){const _0x56800a=this['buildRevisionData']({'from':_0x2177df,'to':_0x25933d});_0x56800a['name']=_0x37773f,_0x56800a['creatorId']=_0x3f4ff8,_0x56800a['id']=_0x517d6b;const _0x349226=this['addRevisionData'](_0x56800a);return this['adapter']&&this['_bufferUpdate'](_0x56800a['id'],_0x56800a,!0x0),_0x349226;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x43efe2){return(_0x43efe2=_0x43efe2['filter'](_0x1a05c8=>!_0x1a05c8['name']||'revision-start'!==_0x1a05c8['name']&&'revision-end'!==_0x1a05c8['name']))['forEach'](_0x5b08e7=>{'string'!=typeof _0x5b08e7&&(_0x5b08e7['children']=this['_removeRevisionMarkers'](_0x5b08e7['children']),_0x5b08e7['attributes']=_0x5b08e7['attributes']['filter'](_0x271000=>!_0x271000[0x0]['startsWith']('data-revision-')));}),_0x43efe2;}}function V(_0x38814b,_0x43c98c){const _0x2d9666=_0x43c98c['editing']['view']['document'];if('string'==typeof _0x38814b)return new _0x448105(_0x2d9666,_0x38814b);{const _0x2d18b6=_0x38814b['children']['map'](_0x83bf3a=>V(_0x83bf3a,_0x43c98c));return new(C[_0x38814b['type']]||_0x24222b)(_0x2d9666,_0x38814b['name'],_0x38814b['attributes'],_0x2d18b6);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x202395){this['editor']=_0x202395,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'](_0x4e61a6){this['source']=_0x4e61a6;const _0x39499e=new Map(),_0x35ccab=new Map(),_0x5836e1=this['editor']['model']['document']['roots']['map'](_0x13cf93=>_0x13cf93['rootName']);for(const _0x41d3a7 of _0x5836e1){const _0x54ff4c=this['editor']['model']['document']['getRoot'](_0x41d3a7),_0x4d2609=F(_0x54ff4c);_0x39499e['set'](_0x41d3a7,_0x4d2609),_0x35ccab['set'](_0x41d3a7,Object['fromEntries'](_0x54ff4c['getAttributes']()));}const _0x36d4b1=Array['from'](this['editor']['model']['markers'])['map'](_0x1e9a18=>[_0x1e9a18['name'],_0x1e9a18['getRange']()]),_0x401597=this['source']['version'];this['_saveMetaData'](_0x401597,_0x39499e,_0x36d4b1,_0x35ccab),this['_startingRevisionId']=this['_revisionId'];const _0x4453c1=new Map(),_0x59bbed=new Map();for(const _0x41c6e6 of _0x5836e1){const _0x438875=B(_0x41c6e6);_0x4453c1['set'](_0x41c6e6,_0x438875),_0x59bbed['set'](_0x41c6e6,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x4453c1,[],_0x59bbed);}['getData'](_0x313fd1,_0x74c6ac){if(this['_lastFrom']===_0x313fd1&&this['_lastTo']<=_0x74c6ac)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x74c6ac,!0x0);else{if(!this['_savedMetaData']['has'](_0x313fd1)){const _0x50276b=this['_getPreviousFrom'](_0x313fd1);this['_calculateMetaData'](_0x50276b,_0x313fd1,!0x1);}this['_calculateMetaData'](_0x313fd1,_0x74c6ac,!0x0);}return this['_lastFrom']=_0x313fd1,this['_lastTo']=_0x74c6ac,this['_getState']();}['loadState'](_0x107e42){this['_reset'](),this['_lastFrom']=_0x107e42['fromVersion'],this['_lastTo']=_0x107e42['toVersion'];for(const _0x15d86d in _0x107e42['diffData']){const _0x22156e=_0x107e42['diffData'][_0x15d86d]['attachChange'],_0x341555=_0x3327e9(_0x107e42['diffData'][_0x15d86d]['attributesBefore'])||{},_0x28f694=this['_makeModelFromViewString'](_0x107e42['diffData'][_0x15d86d]['deletions']);_0x28f694['rootName']=_0x15d86d,_0x28f694['_isAttached']=!_0x22156e||!_0x22156e['isAttached'],_0x28f694['isAttached']=()=>_0x28f694['_isAttached'],this['_baseRoots']['set'](_0x15d86d,_0x28f694),this['_baseRootsAttributes']['set'](_0x15d86d,_0x341555),_0x22156e&&this['_touchedRoots']['set'](_0x15d86d,_0x22156e);const _0x59f861=this['_makeIdsRoot'](_0x28f694);this['_baseIdsRoots']['set'](_0x15d86d,_0x59f861);for(const [_0x44607a,_0x1679f2]of _0x28f694['markers']){if(!_0x44607a['startsWith']('revision:'))continue;const _0x4cb9d2=_0x44607a['split'](':')[0x2];for(const _0x59321e of _0x1679f2['getWalker']({'singleCharacters':!0x0})){const _0x57a6e8=this['_getVidAttributeName'](_0x59321e),_0x4c90f4='elementEnd'==_0x59321e['type']?_0x59321e['previousPosition']['path']['slice'](0x0,-0x1):_0x59321e['previousPosition']['path'],_0x5d9725=_0x59f861['getNodeByPath'](_0x4c90f4)['getAttribute'](_0x57a6e8);this['_touched']['set'](_0x5d9725,{'userId':_0x4cb9d2});}}}this['_startingRevisionId']=this['_revisionId'];const _0x20a458=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x48e346=>!this['_touched']['has'](_0x48e346));let _0x2179d0=0x0;const _0x47cc4b=new Map();for(const _0x3f9f7b in _0x107e42['diffData']){const _0x7fc6c8=_0x107e42['diffData'][_0x3f9f7b]['attachChange'],_0x49d139=_0x3327e9(_0x107e42['diffData'][_0x3f9f7b]['attributesAfter'])||{},_0x5e6eea=this['_makeModelFromViewString'](_0x107e42['diffData'][_0x3f9f7b]['insertions']);_0x5e6eea['rootName']=_0x3f9f7b,_0x5e6eea['_isAttached']=!_0x7fc6c8||_0x7fc6c8['isAttached'],_0x5e6eea['isAttached']=()=>_0x5e6eea['_isAttached'],this['_diffRoots']['set'](_0x3f9f7b,_0x5e6eea),this['_diffRootsAttributes']['set'](_0x3f9f7b,_0x49d139);const _0x46baf6=this['_makeIdsRoot'](_0x5e6eea,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x3f9f7b,_0x46baf6),_0x47cc4b['set'](_0x3f9f7b,_0x5e6eea['isAttached']()?_0x49d139:{});for(const [_0x3a8238,_0x14a16a]of _0x5e6eea['markers']){if(!_0x3a8238['startsWith']('revision:'))continue;const _0x2e46f3=_0x3a8238['split'](':')[0x2];for(const _0x5eb287 of _0x14a16a['getWalker']({'singleCharacters':!0x0})){const _0x247288=this['_getVidAttributeName'](_0x5eb287),_0x4f75dc=this['_revisionId']++,_0x3a239c='elementEnd'==_0x5eb287['type']?_0x5eb287['previousPosition']['path']['slice'](0x0,-0x1):_0x5eb287['previousPosition']['path'];_0x46baf6['getNodeByPath'](_0x3a239c)['_setAttribute'](_0x247288,_0x4f75dc),this['_touched']['set'](_0x4f75dc,{'userId':_0x2e46f3});}}for(const _0x4bdb12 of this['editor']['model']['createRangeIn'](_0x5e6eea)['getWalker']({'singleCharacters':!0x0})){const _0xd6048d=this['_getVidAttributeName'](_0x4bdb12),_0x58d8d3='elementEnd'==_0x4bdb12['type']?_0x4bdb12['previousPosition']['path']['slice'](0x0,-0x1):_0x4bdb12['previousPosition']['path'],_0x2bd1fc=_0x46baf6['getNodeByPath'](_0x58d8d3);_0x2bd1fc['getAttribute'](_0xd6048d)>0x0||_0x2bd1fc['_setAttribute'](_0xd6048d,_0x20a458[_0x2179d0++]);}for(const [_0x535cc7,_0x21e495]of _0x5e6eea['markers'])_0x535cc7['startsWith']('revision:')||this['_markers']['set'](_0x535cc7,_0x21e495);}const _0x23cfbb=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x23cfbb),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x23cfbb,0x1));const _0xdc43e4=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0xdc43e4),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xdc43e4,0x1));const _0x2ed344=Array['from'](this['_diffRoots'])['map'](([_0x1d1d64,_0x199d99])=>[_0x1d1d64,F(_0x199d99)]);this['_saveMetaData'](this['_lastTo'],_0x2ed344,this['_markers'],_0x47cc4b);}['_makeModelFromViewString'](_0x533581){const _0x348890=JSON['parse'](_0x533581),_0x444a34=this['editor']['editing']['view']['document'],_0x4e4aa5=new _0x5d7012(_0x444a34,_0x348890['map'](_0x14976b=>V(_0x14976b,this['editor'])));return this['editor']['data']['toModel'](_0x4e4aa5);}['_saveMetaData'](_0x3e1056,_0x41f3b6,_0x5f3dae,_0xfe3ccb){const _0x2460fa=new Map(_0x41f3b6),_0x19d7b4=new Map(_0x3327e9(_0xfe3ccb)),_0x555b1b=new Map();for(const [_0x3391ca,_0x4937d0]of _0x5f3dae)_0x555b1b['set'](_0x3391ca,{'start':_0x4937d0['start']['clone'](),'end':_0x4937d0['end']['clone'](),'rootName':_0x4937d0['root']['rootName']});this['_savedMetaData']['set'](_0x3e1056,{'roots':_0x2460fa,'markers':_0x555b1b,'rootsAttributes':_0x19d7b4});}['_removeMetaData'](_0x335866){this['_savedMetaData']['delete'](_0x335866);}['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'](_0x3904ee,_0x4ea1dc=null){let _0x56f7d1=null;_0x3904ee['is']('documentFragment')||(_0x56f7d1=new ft(_0x3904ee['name'],{'vid_start':null===_0x4ea1dc?this['_revisionId']++:_0x4ea1dc++}));const _0x52e054=[];for(const _0x2217cf of _0x3904ee['getChildren']())if(_0x2217cf['is']('element')){_0x52e054['push'](this['_makeIdsRoot'](_0x2217cf,_0x4ea1dc));const _0x2fa5ee=_0x52e054[_0x52e054['length']-0x1];null!==_0x4ea1dc&&(_0x4ea1dc=_0x2fa5ee['is']('element','$text')?_0x2fa5ee['getAttribute']('vid')+0x1:_0x2fa5ee['getAttribute']('vid_end')+0x1);}else{for(let _0xf6c46c=0x0;_0xf6c46c<_0x2217cf['offsetSize'];_0xf6c46c++)_0x52e054['push'](new ft('$text',{'vid':null===_0x4ea1dc?this['_revisionId']++:_0x4ea1dc++}));}if(_0x3904ee['is']('documentFragment')){const _0x54654f=B(_0x3904ee['rootName']);return _0x54654f['_insertChild'](0x0,_0x52e054),_0x54654f;}return _0x56f7d1['_setAttribute']('vid_end',null===_0x4ea1dc?this['_revisionId']++:_0x4ea1dc++),_0x56f7d1['_insertChild'](0x0,_0x52e054),_0x56f7d1;}['_calculateMetaData'](_0x4f7ceb,_0x278758,_0x58d123){this['_reset']();const {roots:_0x1e9c1b,markers:_0x4629c3,rootsAttributes:_0x440f4d}=this['_savedMetaData']['get'](_0x4f7ceb);this['_baseRoots']=new Map(_0x1e9c1b),this['_baseRootsAttributes']=new Map(_0x3327e9(_0x440f4d));for(const [_0x493431,_0x4d959a]of this['_baseRoots'])if('$graveyard'!==_0x493431&&(this['_diffRoots']['set'](_0x493431,F(_0x4d959a)),this['_diffRootsAttributes']=new Map(_0x3327e9(_0x440f4d)),_0x58d123)){const _0x5e2827=this['_revisionId'];this['_idsRoots']['set'](_0x493431,this['_makeIdsRoot'](_0x4d959a)),this['_baseIdsRoots']['set'](_0x493431,this['_makeIdsRoot'](_0x4d959a,_0x5e2827));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x58d123&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x592a2c,_0x5d2200]of _0x4629c3){const _0x48041a=this['_baseRoots']['get'](_0x5d2200['rootName']),_0x3f3bcc=this['_diffRoots']['get'](_0x5d2200['rootName']),_0x279e6c=new vt(this['_fixPosition'](_0x5d2200['start'],_0x48041a),this['_fixPosition'](_0x5d2200['end'],_0x48041a)),_0x43ff2b=this['_fixRange'](_0x279e6c,_0x3f3bcc);_0x48041a['markers']['set'](_0x592a2c,_0x279e6c),this['_markers']['set'](_0x592a2c,_0x43ff2b);}this['_applyOperations'](_0x4f7ceb,_0x278758,_0x58d123);}['_applyOperations'](_0xaa5d7e,_0x524042,_0x43c95f){for(const _0x4b5223 of this['source']['getOperations'](_0xaa5d7e,_0x524042))this['_handleOperation'](_0x4b5223,_0x43c95f);for(const _0x254bd9 of this['_diffRoots']['values']())_0x254bd9['markers']['clear']();for(const [_0x37c3c0,_0x5401ab]of this['_markers']){this['_diffRoots']['get'](_0x5401ab['root']['rootName'])['markers']['set'](_0x37c3c0,_0x5401ab['clone']());}const _0x5b7173=new Map(),_0x19b55b=new Map();for(const [_0x936cc6,_0x59f8dd]of this['_diffRoots'])_0x5b7173['set'](_0x936cc6,F(_0x59f8dd)),_0x19b55b['set'](_0x936cc6,this['_diffRootsAttributes']['get'](_0x936cc6));this['_saveMetaData'](_0x524042,_0x5b7173,this['_markers'],_0x19b55b);}['_getPreviousFrom'](_0x16d97f){const _0x1b92de=Array['from'](this['_savedMetaData']['keys']());_0x1b92de['sort']((_0xf72180,_0x57b10b)=>_0xf72180-_0x57b10b),_0x1b92de['reverse']();for(const _0x2b1f84 of _0x1b92de)if(_0x2b1f84<_0x16d97f)return _0x2b1f84;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4cf2c5,_0x43abba){const _0x456b75=Array['from'](_0x43abba['markers'])['map'](([_0x273cef,_0x50b635])=>[_0x273cef,this['_fixRange'](_0x50b635,_0x4cf2c5)]);_0x4cf2c5['markers']=new Map(_0x456b75);}['_transformMarkers'](_0x2e64fc){for(const _0x2564ba of this['_markers']['values']()){const _0xa2e7b6=_0x2564ba['getTransformedByOperation'](_0x2e64fc),_0x16799c=vt['_createFromRanges'](_0xa2e7b6);_0x2564ba['start']=_0x16799c['start'],_0x2564ba['end']=_0x16799c['end'];}}['_handleOperation'](_0x488543,_0x380320){if('addRoot'!=_0x488543['type']&&'detachRoot'!=_0x488543['type']){if('insert'==_0x488543['type']){const _0x5d7e71=_0x488543['position']['root']['rootName'];this['_diffRoots']['has'](_0x5d7e71)||(this['_diffRoots']['set'](_0x5d7e71,B(_0x5d7e71,!0x0)),this['_diffRootsAttributes']['set'](_0x5d7e71,{}),_0x380320&&this['_idsRoots']['set'](_0x5d7e71,B(_0x5d7e71,!0x0)));}else{if('addRootAttribute'==_0x488543['type']||'removeRootAttribute'==_0x488543['type']||'changeRootAttribute'==_0x488543['type'])return void this['_handleRootAttributeOperation'](_0x488543);'marker'==_0x488543['type']&&this['_handleMarkerOperation'](_0x488543);}if('marker'!==_0x488543['type']){const _0x170762=this['_cloneOperation'](_0x488543,this['_diffRoots']);_0x170762['_execute'](),this['_transformMarkers'](_0x170762);}if(_0x380320)switch(_0x488543['type']){case'insert':this['_handleInsertOperation'](_0x488543);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x488543);break;case'merge':this['_handleMergeOperation'](_0x488543);break;case'split':this['_handleSplitOperation'](_0x488543);}}else this['_handleRootOperation'](_0x488543,_0x380320);}['_cloneOperation'](_0x2b75e7,_0x5e7af8){const _0x1368a4=_0x2b75e7['clone']();return _0x1368a4['_authorId']=_0x2b75e7['_authorId'],this['_fixOperation'](_0x1368a4,_0x5e7af8),_0x1368a4;}['_getBaseVids'](_0x17cf31){return _0x17cf31['map'](_0x5ac8c9=>{const _0x23568b=this['_getVidAttributeName'](_0x5ac8c9);return Number(_0x5ac8c9['item']['getAttribute'](_0x23568b));});}['_generateTape'](_0x51010e,_0x50514e){if(_0x51010e['is']('element','$text'))_0x50514e['push']({'item':_0x51010e,'type':'text'});else{_0x51010e['is']('element')&&_0x50514e['push']({'item':_0x51010e,'type':'elementStart'});for(const _0xad3d19 of _0x51010e['getChildren']())this['_generateTape'](_0xad3d19,_0x50514e);_0x51010e['is']('element')&&_0x50514e['push']({'item':_0x51010e,'type':'elementEnd'});}return _0x50514e;}['_getState'](){const _0x3cc3f0=new Map(this['_touched']),_0x53e00c=new Map(_0x3cc3f0),_0x4d2ee0=new Map(),_0x28ebf6={'insertions':{},'deletions':{}},_0x45ce7c={'insertions':{},'deletions':{}},_0x1c5d18=new Map(),_0x73b615=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x73b615['delete']('$graveyard');for(const _0x4717fb of _0x73b615){const _0x4ded0f=this['_diffRoots']['get'](_0x4717fb)||B(_0x4717fb,!0x1),_0x1d2bbe=this['_baseRoots']['get'](_0x4717fb)||B(_0x4717fb,!0x1);_0x4ded0f['isAttached']()||_0x1d2bbe['isAttached']()?(_0x28ebf6['insertions'][_0x4717fb]=F(_0x4ded0f),_0x28ebf6['deletions'][_0x4717fb]=F(_0x1d2bbe),this['_copyMarkers'](_0x28ebf6['deletions'][_0x4717fb],_0x1d2bbe),this['_copyMarkers'](_0x28ebf6['insertions'][_0x4717fb],_0x4ded0f),_0x45ce7c['insertions'][_0x4717fb]=this['_generateTape'](this['_idsRoots']['get'](_0x4717fb),[]),_0x45ce7c['deletions'][_0x4717fb]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4717fb)||B(_0x4717fb,!0x1),[])):_0x73b615['delete'](_0x4717fb);}for(const _0x56f310 of _0x73b615){const _0xf5586c=_0x45ce7c['insertions'][_0x56f310];for(const _0x3358a1 of _0xf5586c){const _0xd4d57b=this['_getVidAttributeName'](_0x3358a1),_0x566263=_0x3358a1['item']['getAttribute'](_0xd4d57b);_0x53e00c['delete'](_0x566263),_0x566263>=this['_startingRevisionId']&&_0x4d2ee0['set'](_0x566263,_0x3cc3f0['get'](_0x566263));}}for(const _0x595290 of _0x73b615){const _0xae93d2=_0x45ce7c['insertions'][_0x595290],_0x42151b=this['_getBaseVids'](_0x45ce7c['deletions'][_0x595290]);let _0x13b7ff=0x0;for(const _0x31eaa1 of _0xae93d2){const _0x2e333f=this['_getVidAttributeName'](_0x31eaa1),_0x391843=_0x31eaa1['item']['getAttribute'](_0x2e333f);if(!_0x4d2ee0['has'](_0x391843)&&!_0x1c5d18['has'](_0x391843)){if(_0x53e00c['has'](_0x391843))_0x13b7ff++;else{if(_0x391843!=_0x42151b[_0x13b7ff]){const _0x2085f2=_0x3cc3f0['get'](_0x391843)||_0x3cc3f0['get'](_0x42151b[_0x13b7ff]);for(;_0x391843!=_0x42151b[_0x13b7ff];)_0x53e00c['has'](_0x42151b[_0x13b7ff])||(_0x1c5d18['set'](_0x42151b[_0x13b7ff],_0x2085f2),_0x3cc3f0['set'](_0x42151b[_0x13b7ff],_0x2085f2)),_0x13b7ff++;}_0x13b7ff++;}}}}for(const _0x6655a of _0x73b615){const _0xe78e16=_0x45ce7c['insertions'][_0x6655a];for(const _0x39d8ef of _0xe78e16){const _0x1626f4=this['_getVidAttributeName'](_0x39d8ef),_0x43d988=_0x39d8ef['item']['getAttribute'](_0x1626f4);if(_0x1c5d18['has'](_0x43d988)){const _0x49aa6b=_0x1c5d18['get'](_0x43d988);_0x53e00c['has'](_0x43d988)||_0x53e00c['set'](_0x43d988,{..._0x49aa6b}),_0x4d2ee0['set'](_0x43d988,{..._0x49aa6b});}}}for(const _0x522a26 of _0x53e00c['keys']())_0x522a26>=this['_startingRevisionId']&&_0x53e00c['delete'](_0x522a26);const _0xb56720=new Map();for(const _0x4a7c0c of _0x73b615){let _0xb5d899=_0x45ce7c['insertions'][_0x4a7c0c];for(const _0x2c8498 of _0xb5d899)if(_0x2c8498['item']['is']('element','tableCell')){const _0x12f488=this['_getVidAttributeName'](_0x2c8498),_0x44c3cb=_0x2c8498['item']['getAttribute'](_0x12f488);if(_0x4d2ee0['has'](_0x44c3cb)){const _0x148cf6=_0x2c8498['item']['parent']['parent']['getAttribute']('vid_start'),_0x1cb3b2=_0xb56720['get'](_0x148cf6)||new Set();_0x1cb3b2['add'](_0x4d2ee0['get'](_0x44c3cb)['userId']),_0xb56720['set'](_0x148cf6,_0x1cb3b2);}}_0xb5d899=_0x45ce7c['deletions'][_0x4a7c0c];for(const _0x4c9168 of _0xb5d899)if(_0x4c9168['item']['is']('element','tableCell')){const _0x38f78e=this['_getVidAttributeName'](_0x4c9168),_0x24adc5=_0x4c9168['item']['getAttribute'](_0x38f78e);if(_0x53e00c['has'](_0x24adc5)){const _0x58a992=_0x4c9168['item']['parent']['parent']['getAttribute']('vid_start'),_0x4f2fb2=_0xb56720['get'](_0x58a992)||new Set();_0x4f2fb2['add'](_0x53e00c['get'](_0x24adc5)['userId']),_0xb56720['set'](_0x58a992,_0x4f2fb2);}}for(const _0x200939 of _0xb56720['keys']())(_0x4d2ee0['has'](_0x200939)||_0x53e00c['has'](_0x200939))&&_0xb56720['delete'](_0x200939);}for(const _0x20f8d8 of _0x73b615){const _0x18269b=_0x45ce7c['insertions'][_0x20f8d8];let _0x4c68c6=null,_0xed6122=null;for(const _0x397aeb of _0x18269b){const _0x32af61=this['_getVidAttributeName'](_0x397aeb),_0x545820=_0x397aeb['item']['getAttribute'](_0x32af61),_0x3fa17b=_0xb56720['get'](_0x545820);_0x3fa17b&&'elementStart'==_0x397aeb['type']&&(_0x4c68c6=Array['from'](_0x3fa17b)[0x0],_0xed6122=_0x397aeb['item']['getAttribute']('vid_end')),_0x4c68c6&&(_0x53e00c['set'](_0x545820,{'userId':_0x4c68c6}),_0x4d2ee0['set'](_0x545820,{'userId':_0x4c68c6})),_0x545820==_0xed6122&&(_0x4c68c6=null,_0xed6122=null);}}const _0x1975f0={},_0x3e964c=new Set();for(const _0x193cb9 of _0x73b615){const _0x2bbc69=_0x28ebf6['deletions'][_0x193cb9],_0x3524f1=_0x28ebf6['insertions'][_0x193cb9];for(const {userId:_0x1dd258}of this['_touchedMarkers']['values']())null!==_0x1dd258&&_0x3e964c['add'](_0x1dd258);for(const {userId:_0x5d6cf5}of this['_touchedRoots']['values']())null!==_0x5d6cf5&&_0x3e964c['add'](_0x5d6cf5);this['_markChanges'](_0x3524f1,_0x45ce7c['insertions'][_0x193cb9],_0x4d2ee0,'insertion',_0x3e964c),this['_markChanges'](_0x2bbc69,_0x45ce7c['deletions'][_0x193cb9],_0x53e00c,'deletion',_0x3e964c),_0x1975f0[_0x193cb9]={'insertions':this['_prepareViewToSave'](_0x3524f1),'deletions':this['_prepareViewToSave'](_0x2bbc69),'attachChange':this['_touchedRoots']['get'](_0x193cb9)||null,'attributesBefore':_0x3327e9(this['_baseRootsAttributes']['get'](_0x193cb9))||{},'attributesAfter':_0x3327e9(this['_diffRootsAttributes']['get'](_0x193cb9))};}return{'diffData':_0x1975f0,'authorsIds':Array['from'](_0x3e964c)};}['_processRootBeforeSave'](_0x52889d){for(const [,_0x57acc8]of _0x52889d['markers']){const _0x3cd3d6=_0x57acc8['start']['getAncestors']()['filter'](_0x2df320=>'tableCell'==_0x2df320['name']);for(const _0x4d8104 of _0x3cd3d6)0x1==_0x4d8104['childCount']&&_0x4d8104['getChild'](0x0)['is']('element','paragraph')&&_0x4d8104['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3ea53b){this['_processRootBeforeSave'](_0x3ea53b);const _0x46e4dc=this['editor']['data']['toView'](_0x3ea53b,{}),_0x124677=Array['from'](_0x46e4dc['getChildren']())['map'](_0x582355=>this['_getViewJson'](_0x582355));return JSON['stringify'](_0x124677);}['_getViewJson'](_0x4c7d6c){if(_0x4c7d6c['is']('$text'))return _0x4c7d6c['data'];{const _0x1b4573=_0x4c7d6c;return{'type':Object['keys'](C)['find'](_0x1547a3=>_0x4c7d6c instanceof C[_0x1547a3]),'name':_0x1b4573['name'],'attributes':Array['from'](_0x1b4573['getAttributes']()),'children':Array['from'](_0x1b4573['getChildren']())['map'](_0x500f80=>this['_getViewJson'](_0x500f80))};}}['_markChanges'](_0xc4f7a7,_0x5b3765,_0x51f086,_0x588d85,_0x307619){let _0x57d37c=null,_0x8d5e0e=null,_0x1a4929=0x0;const _0x22be38=this['editor']['model'];for(let _0x10cdf7=0x0;_0x10cdf7<_0x5b3765['length'];_0x10cdf7++){const _0x3bb069=this['_getVidAttributeName'](_0x5b3765[_0x10cdf7]),_0x5a825a=_0x5b3765[_0x10cdf7]['item']['getAttribute'](_0x3bb069),_0x3056a1=_0x51f086['get'](_0x5a825a),_0x6e1c73=_0x10cdf7==_0x5b3765['length']-0x1;(!_0x57d37c&&_0x3056a1&&(_0x57d37c=_0x3056a1,_0x8d5e0e=_0x5b3765[_0x10cdf7]),_0x57d37c&&(!_0x3056a1||_0x3056a1['userId']!=_0x57d37c['userId']))&&(_0x49ffd2(_0x3056a1,J(_0x8d5e0e,_0xc4f7a7,_0x22be38),J(_0x5b3765[_0x10cdf7],_0xc4f7a7,_0x22be38)),_0x57d37c=_0x3056a1||null,_0x8d5e0e=_0x3056a1?_0x5b3765[_0x10cdf7]:null),_0x57d37c&&_0x6e1c73&&_0x49ffd2(_0x3056a1,J(_0x8d5e0e,_0xc4f7a7,_0x22be38),q(_0x5b3765[_0x10cdf7],_0xc4f7a7,_0x22be38));}function _0x49ffd2(_0x1dc2ac,_0xb289a8,_0x287f48){const _0x3fbe84=_0x57d37c['userId'],_0x370f24='revision:'+_0x588d85+':'+_0x3fbe84+':'+_0x1a4929++,_0x5efde1=_0x22be38['createRange'](_0xb289a8,_0x287f48);_0xc4f7a7['markers']['set'](_0x370f24,_0x5efde1),null!==_0x3fbe84&&_0x307619['add'](_0x3fbe84);}}['_getVidAttributeName'](_0x4214ec){switch(_0x4214ec['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x13926b,_0x1aa1ea){_0x13926b['baseVersion']=null;for(const _0x5a0947 in _0x13926b){const _0xdfe48a=_0x13926b[_0x5a0947];if(_0xdfe48a instanceof gt){const _0x1fb995=_0x1aa1ea['get'](_0xdfe48a['root']['rootName']);_0x13926b[_0x5a0947]=this['_fixPosition'](_0xdfe48a,_0x1fb995);}if(_0xdfe48a instanceof vt){const _0x469ba7=_0x1aa1ea['get'](_0xdfe48a['root']['rootName']);_0x13926b[_0x5a0947]=this['_fixRange'](_0xdfe48a,_0x469ba7);}'root'===_0x5a0947&&(_0x13926b['root']=_0x1aa1ea['get'](_0x13926b['root']['rootName']));}}['_fixRange'](_0x3d3802,_0x19394c){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3d3802['start'],_0x19394c),this['_fixPosition'](_0x3d3802['end'],_0x19394c));}['_fixPosition'](_0x4b8f67,_0x19f685){return this['editor']['model']['createPositionFromPath'](_0x19f685,_0x4b8f67['path'],_0x4b8f67['stickiness']);}['_handleInsertOperation'](_0x1bc437){const _0xcb6e35=this['_idsRoots']['get'](_0x1bc437['position']['root']['rootName']),_0xd49fc6=this['_fixPosition'](_0x1bc437['position'],_0xcb6e35),_0xdfc1a=null===_0x1bc437['_authorId']?null:_0x1bc437['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4d85ff=_0xd49fc6['parent'],_0x20a9ab=this['_revisionId'],_0x2065c9=[];for(const _0x5c7d8d of _0x1bc437['nodes'])if(_0x5c7d8d['is']('element'))_0x2065c9['push'](this['_makeIdsRoot'](_0x5c7d8d));else{for(let _0x46e47b=0x0;_0x46e47b<_0x5c7d8d['offsetSize'];_0x46e47b++)_0x2065c9['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x5f0dbb=this['_revisionId'];for(let _0x3213b8=_0x20a9ab;_0x3213b8<_0x5f0dbb;_0x3213b8++)this['_touched']['set'](_0x3213b8,{'userId':_0xdfc1a});_0x4d85ff['_insertChild'](_0xd49fc6['offset'],_0x2065c9);}['_handleMoveOperation'](_0x366866){(_0x366866=this['_cloneOperation'](_0x366866,this['_idsRoots']))['_execute']();const _0x17fc0b=null===_0x366866['_authorId']?null:_0x366866['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2d770d=_0x366866['getMovedRangeStart'](),_0x271cf0=_0x2d770d['parent'],_0xcf6ffc=_0x2d770d['offset'];!function _0x4b7f33(_0x4d48c4,_0x4481bb,_0x594cdb,_0x51b848){for(let _0x59fe7e=_0x594cdb;_0x59fe7e<_0x51b848;_0x59fe7e++){const _0x5f1da1=_0x4481bb['getChild'](_0x59fe7e);_0x5f1da1['is']('element','$text')?_0x4d48c4['set'](_0x5f1da1['getAttribute']('vid'),{'userId':_0x17fc0b}):(_0x4d48c4['set'](_0x5f1da1['getAttribute']('vid_start'),{'userId':_0x17fc0b}),_0x4b7f33(_0x4d48c4,_0x5f1da1,0x0,_0x5f1da1['childCount']),_0x4d48c4['set'](_0x5f1da1['getAttribute']('vid_end'),{'userId':_0x17fc0b}));}}(this['_touched'],_0x271cf0,_0xcf6ffc,_0xcf6ffc+_0x366866['howMany']);}['_handleMergeOperation'](_0x5a4cde){const _0x855ffc=null===(_0x5a4cde=this['_cloneOperation'](_0x5a4cde,this['_idsRoots']))['_authorId']?null:_0x5a4cde['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3ad119=_0x5a4cde['targetPosition']['parent'],_0x53c120=_0x5a4cde['sourcePosition']['parent'],_0x6a03b=_0x3ad119['getAttribute']('vid_end'),_0x3cef52=_0x53c120['getAttribute']('vid_start');_0x3ad119['_setAttribute']('vid_end',_0x53c120['getAttribute']('vid_end')),_0x53c120['_setAttribute']('vid_end',_0x6a03b),this['_touched']['set'](_0x3cef52,{'userId':_0x855ffc}),this['_touched']['set'](_0x6a03b,{'userId':_0x855ffc}),_0x5a4cde['_execute']();}['_handleSplitOperation'](_0x32747c){const _0x125257=null===(_0x32747c=this['_cloneOperation'](_0x32747c,this['_idsRoots']))['_authorId']?null:_0x32747c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5e38c6=_0x32747c['graveyardPosition'],_0x41af17=_0x32747c['splitPosition']['parent'];_0x32747c['_execute']();const _0xb3cec5=_0x41af17['getAttribute']('vid_end'),_0x6f53bb=_0x32747c['insertionPosition']['nodeAfter'];if(_0x5e38c6){const _0x5b3a0d=_0x6f53bb['getAttribute']('vid_end'),_0x87c425=_0x41af17['getAttribute']('vid_end');_0x41af17['_setAttribute']('vid_end',_0x5b3a0d),_0x6f53bb['_setAttribute']('vid_end',_0x87c425),this['_touched']['set'](_0x41af17['getAttribute']('vid_end'),{'userId':_0x125257}),this['_touched']['set'](_0x6f53bb['getAttribute']('vid_start'),{'userId':_0x125257});}else{const _0x140d5d=this['_revisionId']++,_0x5c92a5=this['_revisionId']++;_0x41af17['_setAttribute']('vid_end',_0x140d5d),_0x6f53bb['_setAttribute']('vid_start',_0x5c92a5),_0x6f53bb['_setAttribute']('vid_end',_0xb3cec5),this['_touched']['set'](_0x140d5d,{'userId':_0x125257}),this['_touched']['set'](_0x5c92a5,{'userId':_0x125257});}}['_handleMarkerOperation'](_0x4b82a9){if(!_0x4b82a9['affectsData'])return;const _0x40764f=(_0x4b82a9=this['_cloneOperation'](_0x4b82a9,this['_diffRoots']))['oldRange']?_0x4b82a9['oldRange']['root']:null,_0x5ca145=_0x4b82a9['newRange']?_0x4b82a9['newRange']['root']:null;_0x40764f&&this['_markers']['delete'](_0x4b82a9['name']),_0x5ca145&&this['_markers']['set'](_0x4b82a9['name'],_0x4b82a9['newRange']['clone']());const _0x2cb9f0=null===_0x4b82a9['_authorId']?null:_0x4b82a9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x347e95=_0x4b82a9['name'];if(!this['_touchedMarkers']['has'](_0x347e95))return void this['_touchedMarkers']['set'](_0x347e95,{'range':_0x4b82a9['oldRange'],'userId':_0x2cb9f0});const _0x473999=this['_touchedMarkers']['get'](_0x347e95),_0x3a3343=_0x473999['range'],_0x58e1ac=_0x4b82a9['newRange'];null==_0x3a3343&&null==_0x58e1ac||_0x3a3343&&_0x58e1ac&&_0x3a3343['isEqual'](_0x58e1ac)?this['_touchedMarkers']['delete'](_0x4b82a9['name']):_0x473999['userId']=_0x2cb9f0;}['_handleRootOperation'](_0xe96910,_0x10590e){this['_diffRoots']['has'](_0xe96910['rootName'])?this['_diffRoots']['get'](_0xe96910['rootName'])['_isAttached']=_0xe96910['isAdd']:(this['_diffRoots']['set'](_0xe96910['rootName'],B(_0xe96910['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0xe96910['rootName'],{}),_0x10590e&&this['_idsRoots']['set'](_0xe96910['rootName'],B(_0xe96910['rootName'],!0x0)));const _0x234eb2=null===_0xe96910['_authorId']?null:_0xe96910['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x28e8e5=this['_touchedRoots']['get'](_0xe96910['rootName']);_0x28e8e5&&_0x28e8e5['userId']===_0x234eb2?this['_touchedRoots']['delete'](_0xe96910['rootName']):this['_touchedRoots']['set'](_0xe96910['rootName'],{'userId':_0x234eb2,'isAttached':_0xe96910['isAdd']});}['_handleRootAttributeOperation'](_0x14ef5b){const _0x39a42d=this['_diffRootsAttributes']['get'](_0x14ef5b['root']['rootName']);null===_0x14ef5b['newValue']?delete _0x39a42d[_0x14ef5b['key']]:_0x39a42d[_0x14ef5b['key']]=_0x14ef5b['newValue'];}}function F(_0x233216){const _0x2f5e3d=B(_0x233216['rootName'],_0x233216['isAttached']());for(const _0x1cce5b of _0x233216['getChildren']()){const _0x54de59=_0x1cce5b['_clone'](!0x0);_0x2f5e3d['_appendChild'](_0x54de59);}return _0x2f5e3d;}function B(_0x3bdffd,_0x4beebd=!0x0){const _0x34adf8=new mt();return _0x34adf8['rootName']=_0x3bdffd,_0x34adf8['_isAttached']=_0x4beebd,_0x34adf8['isAttached']=()=>_0x34adf8['_isAttached'],_0x34adf8;}function J(_0x27ec7d,_0x27ab20,_0x2ff29f){const _0x211b2d='elementEnd'==_0x27ec7d['type']?_0x2ff29f['createPositionAt'](_0x27ec7d['item'],'end'):_0x2ff29f['createPositionBefore'](_0x27ec7d['item']);return _0x2ff29f['createPositionFromPath'](_0x27ab20,_0x211b2d['path'],_0x211b2d['stickiness']);}function q(_0x364244,_0x51dd97,_0x1c365c){const _0x3760ed='elementStart'==_0x364244['type']?_0x1c365c['createPositionAt'](_0x364244['item'],0x0):_0x1c365c['createPositionAfter'](_0x364244['item']);return _0x1c365c['createPositionFromPath'](_0x51dd97,_0x3760ed['path'],_0x3760ed['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x289209,_0x9b4cb1){super(_0x289209),this['focusTracker']=new _0x517e8a(),this['keystrokes']=new _0xdf8882(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x9b4cb1),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x3f2453(this);}['render'](){super['render'](),_0x2f836c({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5e083a=_0x18b2e3=>_0x18b2e3['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5e083a),this['keystrokes']['set']('arrowleft',_0x5e083a),this['keystrokes']['set']('arrowup',_0x5e083a),this['keystrokes']['set']('arrowdown',_0x5e083a);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x296bfa){this['revisionNameInputView']['fieldView']['element']['value']=_0x296bfa['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x19273a){const _0x2ef3ec=new _0x11555d(this['locale'],_0x2f692f),_0x3592a8=_0x2ef3ec['fieldView'];_0x3592a8['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4c3722=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x19273a&&(_0x4c3722+='\x20('+R(this['locale'],'optional')+')'),(_0x2ef3ec['label']=_0x4c3722,_0x3592a8['on']('input',()=>{this['revisionNameInputValue']=_0x3592a8['element']['value']['trim']();}),_0x2ef3ec);}}class u extends _0x4e17c7{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x4dc2b4=this['editor'],_0x41366b=_0x4dc2b4['plugins']['get']('RevisionTracker');_0x4dc2b4['ui']['componentFactory']['add']('revisionHistory',_0x58b079=>{const _0x14e641=_0x32fc3c(_0x58b079),_0x46c049=_0x14e641['panelView']['children'],_0x2fedb7=new _0x30e1f8(_0x58b079),_0x3b5688=new _0x19040f(_0x58b079),_0x57848e=new te(_0x58b079),_0x5c4ce2=new _0x19040f(_0x58b079),_0x39afee=new te(_0x58b079);return _0x14e641['bind']('isEnabled')['to'](_0x41366b,'isReady',_0x41366b,'isEnabled',_0x4dc2b4,'isReadOnly',(_0x2525d7,_0x3b7dee,_0x15b89b)=>_0x2525d7&&_0x3b7dee&&!_0x15b89b),_0x14e641['buttonView']['set']({'icon':_0x3bf8ea['history'],'label':R(_0x58b079,'Revision\x20history'),'tooltip':!0x0}),_0x57848e['set']({'label':R(_0x58b079,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x57848e['bind']('isEnabled')['to'](_0x41366b,'isReady',_0x41366b,'isEnabled',_0x4dc2b4,'isReadOnly',(_0xdac863,_0x24e93a,_0x10ff34)=>_0xdac863&&_0x24e93a&&!_0x10ff34),_0x57848e['on']('execute',()=>this['_showDialog']()),_0x39afee['set']({'label':R(_0x58b079,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x39afee['bind']('isEnabled')['to'](_0x41366b,'isReady',_0x4dc2b4,'isReadOnly',(_0x2b3a0e,_0x393e9f)=>_0x2b3a0e&&!_0x393e9f),_0x39afee['on']('execute',()=>{_0x4dc2b4['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x14e641['isOpen']=!0x1,_0x4dc2b4['editing']['view']['focus']();}),_0x3b5688['children']['add'](_0x57848e),_0x5c4ce2['children']['add'](_0x39afee),_0x2fedb7['role']='menu',_0x2fedb7['items']['addMany']([_0x3b5688,_0x5c4ce2]),_0x46c049['add'](_0x2fedb7),_0x14e641;}),_0x4dc2b4['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x403efd=this['editor'],_0x186067=_0x403efd['locale'],_0x145c08=new _0x353bde(_0x186067),_0x3e17fe=new _0x3924bf(_0x186067);_0x145c08['buttonView']['set']({'icon':_0x3bf8ea['history'],'label':R(_0x186067,'Revision\x20history')});const _0x2d5e2e=new _0x495609(_0x186067,_0x145c08),_0x3e2cb2=new _0x5e75f3(_0x186067);_0x3e2cb2['set']({'label':R(_0x186067,'Save\x20current\x20revision')}),_0x3e2cb2['delegate']('execute')['to'](_0x145c08),_0x3e2cb2['on']('execute',()=>{this['_showDialog']();}),_0x2d5e2e['children']['add'](_0x3e2cb2),_0x3e17fe['items']['add'](_0x2d5e2e);const _0x3b0518=new _0x495609(_0x186067,_0x145c08),_0x1b2e6e=new _0x5e75f3(_0x186067);return _0x1b2e6e['set']({'label':R(_0x186067,'Open\x20revision\x20history')}),_0x1b2e6e['delegate']('execute')['to'](_0x145c08),_0x1b2e6e['on']('execute',()=>{_0x403efd['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x3b0518['children']['add'](_0x1b2e6e),_0x3e17fe['items']['add'](_0x3b0518),_0x145c08['panelView']['children']['add'](_0x3e17fe),_0x145c08;}['_showDialog'](){const _0x507ae5=this['editor'],_0x42cc54=_0x507ae5['locale'],_0x2344a5=_0x507ae5['plugins']['get']('Dialog'),_0x3daa79=_0x507ae5['plugins']['get']('RevisionTracker');function _0x3ddbf3(_0x287b4e){_0x507ae5['config']['get']('revisionHistory.requireRevisionName')&&''===_0x287b4e['revisionName']?_0x287b4e['revisionNameInputView']['errorText']=R(_0x42cc54,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x507ae5['plugins']['get'](l)['saveRevision']({'name':_0x287b4e['revisionName']}),_0x2344a5['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3ddbf3(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2344a5['show']({'id':'revisionSave','title':R(_0x42cc54,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x507ae5['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2344a5['hide']()},{'label':R(_0x507ae5['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x28a741){_0x28a741['bind']('isEnabled')['to'](_0x3daa79,'isReady',_0x3daa79,'isEnabled',_0x507ae5,'isReadOnly',(_0xe4abd3,_0x18c9c5,_0x234c26)=>_0xe4abd3&&_0x18c9c5&&!_0x234c26);},'onExecute':()=>_0x3ddbf3(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x44c9a7=this['editor'],_0xea87a1=_0x44c9a7['locale'];this['_saveRevisionFormView']=new hs(_0xea87a1,_0x44c9a7['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends ts{['changeId'];['_model'];constructor(_0x4b4c3d,_0x586f81){super(_0x4b4c3d),this['_model']=_0x586f81,this['changeId']=_0x586f81['id'];const _0x51c4c2=this['bindTemplate'],_0x5f38ae=R(_0x4b4c3d,_0x586f81['data']['isSuggestion']?'Suggested\x20by':'add'==_0x586f81['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x586f81['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x51c4c2['to']('type',_0x32b3f8=>'ck-revision-change__'+_0x32b3f8)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x5f38ae}]},{'text':'\x20'+_0x586f81['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x1604e4(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x370ef2){super(),this['id']=_0x370ef2['id']||_0x4c5b41(),this['author']=_0x370ef2['author'],this['type']=_0x370ef2['type'],this['data']=_0x370ef2['data']||{},this['rootName']=_0x370ef2['rootName'],this['set']('createdAt',_0x370ef2['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(_0x54b6da,_0x4c4e02){this['newRevisionId']=_0x54b6da,this['oldRevisionId']=_0x4c4e02,this['changes']=new _0x510f19();}['_setChanges'](_0x4e175c){for(const _0x15590b of _0x4e175c)this['changes']['add'](_0x15590b);}}const Z={'c':_0x3cb2a9,'a':_0x3121ff,'e':_0x43ffa6,'r':_0x113701,'u':_0x46f8b2};class d extends _0x4e17c7{['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[_0x2edfe1,_0x3444f0,j];}constructor(_0x328afb){super(_0x328afb),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',(_0x2ee039,_0x3119b7,_0x22212f)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x4fc3f6=>{for(const _0x366b8e of this['editor']['editing']['view']['document']['roots'])_0x22212f?_0x4fc3f6['removeClass']('ck-editor__editable__overlay',_0x366b8e):_0x4fc3f6['addClass']('ck-editor__editable__overlay',_0x366b8e);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x503cbf=>null!==_0x503cbf),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2df819,_0x3cbae1,_0x590365)=>_0x2df819&&_0x590365?_0x3cbae1['changes']['getIndex'](_0x590365):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0xf2347e,_0x2f087c)=>_0xf2347e?_0x2f087c['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x3444f0);}['init'](){const _0x54aaee=this['editor'],_0x546c97=new yt(_0x54aaee,{'direction':'backward'}),_0x38a291=new yt(_0x54aaee,{'direction':'forward'});(_0x54aaee['commands']['add']('showPreviousChange',_0x546c97),_0x54aaee['commands']['add']('showNextChange',_0x38a291),_0x54aaee['commands']['add']('restoreRevision',new _t(_0x54aaee)),this['on']('change:numberOfChanges',()=>{_0x546c97['refresh'](),_0x38a291['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x54aaee['enableReadOnlyMode']('revision-viewer'),_0x54aaee['plugins']['has']('WidgetToolbarRepository'))&&_0x54aaee['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x5994b5){await this['loadRevisionData'](_0x5994b5);const _0x390b83={};for(const _0x3b07fc in _0x5994b5['diffData']){if(_0x5994b5['diffData'][_0x3b07fc]['attachChange']&&!_0x5994b5['diffData'][_0x3b07fc]['attachChange']['isAttached'])continue;const _0x2355c1=this['_removeRevisionMarkers'](JSON['parse'](_0x5994b5['diffData'][_0x3b07fc]['insertions'])),_0x45ed57=this['editor']['editing']['view']['document'],_0x3a0cc7=new _0x5d7012(_0x45ed57,_0x2355c1['map'](_0x1b7b8c=>this['_getViewObj'](_0x1b7b8c)));this['editor']['data']['processor']['useFillerType']('marked'),_0x390b83[_0x3b07fc]=this['editor']['data']['processor']['toData'](_0x3a0cc7),this['editor']['data']['processor']['useFillerType']('default');}return _0x390b83;}async['getRevisionRootsAttributes'](_0x25308e){await this['loadRevisionData'](_0x25308e);const _0x21e69c={};for(const _0x5610ca in _0x25308e['diffData'])_0x25308e['diffData'][_0x5610ca]['attachChange']&&!_0x25308e['diffData'][_0x5610ca]['attachChange']['isAttached']||(_0x21e69c[_0x5610ca]=_0x25308e['diffData'][_0x5610ca]['attributesAfter']||{});return _0x21e69c;}['_removeRevisionMarkers'](_0x29113a){return(_0x29113a=_0x29113a['filter'](_0x2b040e=>!_0x2b040e['name']||'revision-start'!==_0x2b040e['name']&&'revision-end'!==_0x2b040e['name']))['forEach'](_0x35eb7f=>{'string'!=typeof _0x35eb7f&&(_0x35eb7f['children']=this['_removeRevisionMarkers'](_0x35eb7f['children']),_0x35eb7f['attributes']=_0x35eb7f['attributes']['filter'](_0x5a2be7=>!_0x5a2be7[0x0]['startsWith']('data-revision-')));}),_0x29113a;}async['compare'](_0x2bb7c5,_0xebe0ec,_0x3cc722=!0x1){if(!this['isEnabled'])return;const _0xdd1adc=this['diff'],_0x26785e=this['repository'],_0x572dfe='string'==typeof _0x2bb7c5?_0x26785e['getRevision'](_0x2bb7c5):_0x2bb7c5,_0x1a4079='string'==typeof _0xebe0ec?_0x26785e['getRevision'](_0xebe0ec):_0xebe0ec,_0x3cda9d=_0x572dfe['id'],_0x451d2b=_0x1a4079?_0x1a4079['id']:null;if(!_0x3cc722&&this['diff']&&this['diff']['newRevisionId']===_0x3cda9d&&this['diff']['oldRevisionId']===_0x451d2b)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x3cda9d,_0x451d2b);const _0x56e27f=this['_getRevisionsRange'](_0x572dfe,_0x1a4079,!0x0)['map'](_0x4abf42=>this['loadRevisionData'](_0x4abf42));return _0x56e27f['push'](new Promise(_0x3d1625=>{setTimeout(_0x3d1625,0x14);})),Promise['all'](_0x56e27f)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x4cf2e1=this['_getDiff'](_0x3cda9d,_0x451d2b);for(const _0x348cc6 of _0x4cf2e1['changes'])this['_changeIdToChange']['set'](_0x348cc6['id'],_0x348cc6);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4c01a4=>{for(const _0x1f91b3 of this['editor']['model']['document']['getRootNames']())_0x4c01a4['detachRoot'](_0x1f91b3);for(const _0x8e7bff of Object['keys'](_0x4cf2e1['model'])){const _0x51d6b3=_0x4c01a4['addRoot'](_0x8e7bff);for(const _0x38754d of Object['keys'](_0x4cf2e1['attributes'][_0x8e7bff]))_0x4c01a4['setAttribute'](_0x38754d,_0x4cf2e1['attributes'][_0x8e7bff][_0x38754d],_0x51d6b3);_0x4c01a4['insert'](_0x4cf2e1['model'][_0x8e7bff],_0x51d6b3,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x4cf2e1['changes'])),this['isReady']=!0x0;})['catch'](_0x43f55a=>{console['error'](_0x43f55a),this['_cleanUp'](),_0xdd1adc&&(this['diff']=_0xdd1adc),this['isReady']=!0x0;});}['addRevisionData'](_0x3c4de7,_0x5418e1){const _0xbcf0ab=this['repository']['createRevision'](_0x3c4de7);return _0xbcf0ab['on']('_update',(_0x41650c,_0x26db1a,_0x52e059)=>_0x5418e1(_0x26db1a,_0x52e059,_0xbcf0ab)),this['repository']['addRevision'](_0xbcf0ab),_0xbcf0ab;}['loadRevisionData'](_0x376d1f){if(!_0x376d1f||_0x376d1f['diffData'])return Promise['resolve']();{const _0x28dc28=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x28dc28,'revisionId':_0x376d1f['id']})['then'](_0x10696f=>{_0x376d1f['_update']({'diffData':_0x10696f['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},_0x3e9f91=>{for(const _0x224b69 of this['editor']['model']['document']['getRootNames']())_0x3e9f91['detachRoot'](_0x224b69);});}['_sortAndFilterDiffChanges'](_0x29d644){const _0x3a27c0=[],_0x328be0=new Map();for(const _0xdd2ea5 of this['editor']['model']['document']['getRootNames']()){const _0x515a1b=this['editor']['editing']['view']['getDomRoot'](_0xdd2ea5);if(!_0x515a1b)continue;const _0x5da9ff=_0x515a1b['getClientRects']()['item'](0x0);_0x5da9ff&&(_0x3a27c0['push'](_0xdd2ea5),_0x328be0['set'](_0xdd2ea5,_0x5da9ff));}return _0x3a27c0['sort']((_0x1183b1,_0x3b373d)=>{const _0x5ff9af=_0x328be0['get'](_0x1183b1),_0x1f6598=_0x328be0['get'](_0x3b373d);return _0x5ff9af['y']-_0x1f6598['y']||_0x5ff9af['x']-_0x1f6598['x'];}),(_0x29d644=_0x29d644['filter'](_0x1cdbe0=>_0x3a27c0['includes'](_0x1cdbe0['rootName'])))['sort']((_0xbece38,_0x419ad2)=>_0x3a27c0['indexOf'](_0xbece38['rootName'])-_0x3a27c0['indexOf'](_0x419ad2['rootName'])),_0x29d644;}['_makeTape'](_0x89abfa){const _0x320d56=Array['from'](_0x89abfa['markers'])['filter'](([_0x5ec338,_0xd6eda3])=>_0x5ec338['startsWith']('revision:')&&!_0xd6eda3['isCollapsed']),_0x1baefc=Array['from'](this['editor']['model']['createRangeIn'](_0x89abfa)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x320d56['length'])for(const _0x21684f of _0x1baefc){const [_0x4778e1,_0x27e7aa]=_0x320d56[0x0],[,_0x3ce8dd,_0x3f1189]=_0x4778e1['split'](':');if(_0x27e7aa['end']['isEqual'](_0x21684f['nextPosition'])&&_0x320d56['shift'](),(_0x21684f['previousPosition']['isEqual'](_0x27e7aa['start'])||_0x21684f['previousPosition']['isAfter'](_0x27e7aa['start']))&&('insertion'==_0x3ce8dd?_0x21684f['isAdded']={'userId':_0x3f1189}:'deletion'==_0x3ce8dd&&(_0x21684f['isRemoved']={'userId':_0x3f1189})),0x0==_0x320d56['length'])break;}return _0x1baefc;}['_refreshStartEndIndex'](_0x2e0dc5){const _0x391285=new Map();for(let _0x4d229a=0x0;_0x4d229a<_0x2e0dc5['length'];_0x4d229a++)'text'===_0x2e0dc5[_0x4d229a]['type']?(_0x2e0dc5[_0x4d229a]['item']['startIndex']=_0x4d229a,_0x2e0dc5[_0x4d229a]['item']['endIndex']=_0x4d229a):('elementStart'===_0x2e0dc5[_0x4d229a]['type']?_0x2e0dc5[_0x4d229a]['item']['startIndex']=_0x4d229a:'elementEnd'===_0x2e0dc5[_0x4d229a]['type']&&(_0x2e0dc5[_0x4d229a]['item']['endIndex']=_0x4d229a),_0x391285['set'](_0x2e0dc5[_0x4d229a]['id'],_0x4d229a));for(const _0x200d56 of _0x391285['values']())'elementStart'===_0x2e0dc5[_0x200d56]['type']?_0x2e0dc5[_0x200d56]['item']['endIndex']=_0x391285['get'](_0x2e0dc5[_0x200d56]['pairId']):'elementEnd'===_0x2e0dc5[_0x200d56]['type']&&(_0x2e0dc5[_0x200d56]['item']['startIndex']=_0x391285['get'](_0x2e0dc5[_0x200d56]['pairId']));}['_processTape'](_0x736e00){for(let _0x392b7b=0x0;_0x392b7b<_0x736e00['length'];_0x392b7b++){if('elementStart'===_0x736e00[_0x392b7b]['type'])_0x736e00[_0x392b7b]['item']['startIndex']=_0x392b7b;else{if('elementEnd'===_0x736e00[_0x392b7b]['type']){_0x736e00[_0x392b7b]['item']['endIndex']=_0x392b7b;const _0x4235b3=_0x736e00[_0x392b7b]['item']['startIndex'];_0x736e00[_0x4235b3]['pairId']=_0x736e00[_0x392b7b]['id'],_0x736e00[_0x392b7b]['pairId']=_0x736e00[_0x4235b3]['id'];}else _0x736e00[_0x392b7b]['item']['startIndex']=_0x392b7b,_0x736e00[_0x392b7b]['item']['endIndex']=_0x392b7b,_0x736e00[_0x392b7b]['pairId']=null;}_0x736e00[_0x392b7b]['markersStart']||(_0x736e00[_0x392b7b]['markersStart']=[],_0x736e00[_0x392b7b]['markersEnd']=[]);}}['_markInsertions'](_0x2787e0,_0x5eb1eb){const _0x579f50=_0x2787e0['filter'](_0x16783b=>!_0x16783b['isAdded']);for(let _0x5efdac=0x0;_0x5efdac<_0x5eb1eb['length'];_0x5efdac++)_0x5eb1eb[_0x5efdac]['isAdded']&&(_0x579f50[_0x5efdac]['isAdded']=_0x5eb1eb[_0x5efdac]['isAdded']);}['_makeModelFromViewString'](_0xbcc782){const _0x217e5a=JSON['parse'](_0xbcc782),_0x14f898=this['editor']['editing']['view']['document'],_0x3f3f37=new _0x5d7012(_0x14f898,_0x217e5a['map'](_0x11ace4=>this['_getViewObj'](_0x11ace4)));return this['editor']['data']['toModel'](_0x3f3f37);}['_getViewObj'](_0x2c2d0f){const _0x303874=this['editor']['editing']['view']['document'];if('string'==typeof _0x2c2d0f)return new _0x448105(_0x303874,_0x2c2d0f);{const _0x3d2c6e=_0x2c2d0f['children']['map'](_0x205678=>this['_getViewObj'](_0x205678));return new(Z[_0x2c2d0f['type']]||_0x24222b)(_0x303874,_0x2c2d0f['name'],_0x2c2d0f['attributes'],_0x3d2c6e);}}['_getDiff'](_0x458393,_0x4f2453=null){const _0x1eee26=this['repository']['getRevision'](_0x458393),_0x2617b5=_0x4f2453?this['repository']['getRevision'](_0x4f2453):null,_0x2310ef=this['_getRevisionsRange'](_0x1eee26,_0x2617b5),_0x35f8c6=_0x2310ef[_0x2310ef['length']-0x1],_0x3b7108=new Map(),_0x4d946a={'model':{},'attributes':{},'changes':[]},_0xb679fc=new Set(),_0x339b84=new Map();for(let _0x29b573=_0x2310ef['length']-0x1;_0x29b573>=0x0;_0x29b573--){const _0x444603=_0x2310ef[_0x29b573];for(const _0x31c0b2 of Object['keys'](_0x444603['diffData']))if(_0x444603['diffData'][_0x31c0b2]['attachChange']){const _0x4fd120=_0x444603['diffData'][_0x31c0b2]['attachChange'];_0x4fd120['isAttached']?(_0xb679fc['add'](_0x31c0b2),_0x339b84['has'](_0x31c0b2)&&_0x339b84['get'](_0x31c0b2)['userId']==_0x4fd120['userId']?_0x339b84['delete'](_0x31c0b2):_0x339b84['set'](_0x31c0b2,_0x4fd120)):_0x339b84['has'](_0x31c0b2)?(_0xb679fc['delete'](_0x31c0b2),_0x339b84['delete'](_0x31c0b2)):(_0xb679fc['add'](_0x31c0b2),_0x339b84['set'](_0x31c0b2,_0x4fd120));}else _0xb679fc['add'](_0x31c0b2);}for(const _0x4e7260 of _0xb679fc){const _0x212a03=_0x339b84['has'](_0x4e7260)&&!_0x339b84['get'](_0x4e7260)['isAttached'];let _0x279d90=_0x212a03?_0x2310ef['length']-0x1:0x0;const _0x2d86b4=_0x212a03?-0x1:0x1;for(;_0x2310ef[_0x279d90];){const _0x158d95=_0x2310ef[_0x279d90];if(_0x158d95['diffData'][_0x4e7260]){const _0x52842e=_0x212a03?_0x158d95['diffData'][_0x4e7260]['attributesBefore']:_0x158d95['diffData'][_0x4e7260]['attributesAfter'];_0x4d946a['attributes'][_0x4e7260]=_0x52842e?_0x3327e9(_0x52842e):{};break;}_0x279d90+=_0x2d86b4;}}for(const _0x504399 of _0x2310ef){_0x504399['model']={};for(const _0x5be98c of _0x504399['authors'])_0x3b7108['set'](_0x5be98c['id'],_0x5be98c);for(const _0xd224ba of _0xb679fc){const _0x1faa30=_0x504399['diffData'][_0xd224ba]?_0x504399['diffData'][_0xd224ba]['insertions']:'[]',_0x2f941f=_0x504399['diffData'][_0xd224ba]?_0x504399['diffData'][_0xd224ba]['deletions']:'[]';_0x504399['model'][_0xd224ba]={'insertions':this['_makeModelFromViewString'](_0x1faa30),'deletions':this['_makeModelFromViewString'](_0x2f941f)};}}for(const _0x22e877 of _0xb679fc){let _0x7658c=null,_0x4671e6=0x0;const _0x356b29=new Map(Array['from'](_0x1eee26['model'][_0x22e877]['insertions']['markers'])['filter'](([_0x115f7d])=>!_0x115f7d['startsWith']('revision:')));let _0x34006e=0x0;for(const _0x714e1d of _0x2310ef){const _0x1be07f=this['_makeTape'](_0x714e1d['model'][_0x22e877]['insertions']);_0x714e1d==_0x1eee26?(_0x7658c=_0x1be07f,_0x4671e6=_0x7658c['length'],_0x7658c['forEach'](_0x2af225=>{_0x2af225['id']=_0x34006e++;}),this['_processTape'](_0x7658c)):this['_markInsertions'](_0x7658c,_0x1be07f);const _0x1ef155=_0x7658c['filter'](_0x5c404c=>!_0x5c404c['isAdded'])['map'](_0x4f2689=>_0x4f2689['id']);let _0x5a489b=0x0;const _0x5b53f6=this['_makeTape'](_0x714e1d['model'][_0x22e877]['deletions']);_0x5b53f6['forEach'](_0xd870c5=>{_0xd870c5['isRemoved']?_0xd870c5['id']=_0x4671e6++:_0xd870c5['id']=_0x1ef155[_0x5a489b++];}),this['_processTape'](_0x5b53f6),this['_setDistance'](_0x7658c,'isAdded'),this['_setDistance'](_0x5b53f6,'isRemoved'),_0x714e1d==_0x1eee26&&this['_markMarkers'](_0x7658c,_0x356b29),_0x7658c=this['_joinTapes'](_0x7658c,_0x5b53f6),this['_refreshStartEndIndex'](_0x7658c),this['_setDistance'](_0x7658c,'isRemoved');}_0x7658c=_0x7658c['filter'](_0x5128e0=>!(_0x5128e0['isAdded']&&_0x5128e0['isRemoved']));const _0x566305=new Map(_0x35f8c6['model'][_0x22e877]['deletions']['markers']),_0x22e2f7=new Set(_0x356b29['keys']());for(const _0x3ac2f2 of _0x566305['keys']())_0x22e2f7['delete'](_0x3ac2f2);this['_markSuggestions'](_0x7658c,_0x22e2f7),this['_fixObsoleteTags'](_0x7658c),_0x7658c=this['_removeMissingPairs'](_0x7658c),_0x7658c=this['_markMismatchedRemovedTags'](_0x7658c),_0x7658c=this['_removeUnsupportedChanges'](_0x7658c);const {root:_0x3f8f75,changes:_0x63bd1c}=this['_makeModelFromTape'](_0x7658c,_0x3b7108,_0x22e877);_0x4d946a['model'][_0x22e877]=_0x3f8f75;const _0x244eab=_0x339b84['get'](_0x22e877);if(_0x244eab){const _0x414340=_0x3b7108['get'](_0x244eab['userId']),_0xfe205=new r({'author':_0x414340,'type':_0x244eab['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x22e877});_0x63bd1c['unshift'](_0xfe205),_0x4d946a['attributes'][_0x22e877]['revisionHistoryAttachChange']=_0xfe205['id'];}_0x4d946a['changes']=_0x4d946a['changes']['concat'](_0x63bd1c);}return _0x4d946a;}['_markMarkers'](_0x53a6dd,_0x4be20a){for(let _0x10de0b=0x0;_0x10de0b<_0x53a6dd['length'];_0x10de0b++)for(const [_0x47931f,_0x547256]of _0x4be20a)_0x547256['start']['isEqual'](_0x53a6dd[_0x10de0b]['previousPosition'])&&_0x53a6dd[_0x10de0b]['markersStart']['push'](_0x47931f),_0x547256['end']['isEqual'](_0x53a6dd[_0x10de0b]['nextPosition'])&&_0x53a6dd[_0x10de0b]['markersEnd']['push'](_0x47931f);}['_joinTapes'](_0x161101,_0xf6e55b){let _0xfda5eb=[],_0x17f5a9=0x0,_0x58a68e=0x0;for(;_0x17f5a9<_0x161101['length']||_0x58a68e<_0xf6e55b['length'];){const _0x495db9=_0x161101[_0x17f5a9]||{},_0x1c4452=_0xf6e55b[_0x58a68e]||{};if(_0x495db9['id']==_0x1c4452['id'])_0x17f5a9++,_0x58a68e++,_0xfda5eb['push'](_0x495db9);else{if(_0x1c4452['isRemoved']&&_0x495db9['isAdded']){const {commonTape:_0x53ff3d,iEnd:_0x1cf4ee,jEnd:_0x2d96d3}=this['_threeWayMerge'](_0x161101,_0x17f5a9,_0xf6e55b,_0x58a68e);_0xfda5eb=_0xfda5eb['concat'](_0x53ff3d),_0x17f5a9=_0x1cf4ee,_0x58a68e=_0x2d96d3;}else _0x1c4452['isRemoved']?(_0x58a68e++,_0xfda5eb['push'](_0x1c4452)):(_0x17f5a9++,_0xfda5eb['push'](_0x495db9));}}return _0xfda5eb;}['_markSuggestions'](_0x1677ad,_0x412d5d){const _0x592119=[];for(let _0x241d9d=0x0;_0x241d9d<_0x1677ad['length'];_0x241d9d++){for(let _0x5bda35=0x0;_0x5bda35<_0x1677ad[_0x241d9d]['markersStart']['length'];_0x5bda35++){const _0x4534bd=_0x1677ad[_0x241d9d]['markersStart'][_0x5bda35];if(!_0x412d5d['has'](_0x4534bd))continue;const {group:_0xa7fcf5,type:_0x1ac6f,authorId:_0x36521b}=_0x1d08da(_0x4534bd);'revision-suggestion'!=_0xa7fcf5||'insertion'!=_0x1ac6f&&'deletion'!=_0x1ac6f||(_0x592119['unshift']({'type':_0x1ac6f,'name':_0x4534bd,'userId':_0x36521b}),_0x1677ad[_0x241d9d]['markersStart']['splice'](_0x5bda35,0x1),_0x5bda35--);}_0x4a0b5b(_0x1677ad[_0x241d9d]);for(let _0x2751fa=0x0;_0x2751fa<_0x1677ad[_0x241d9d]['markersEnd']['length'];_0x2751fa++){const _0x41c338=_0x1677ad[_0x241d9d]['markersEnd'][_0x2751fa];if(!_0x412d5d['has'](_0x41c338))continue;const {group:_0x37c8a5,type:_0x24cde8}=_0x1d08da(_0x41c338);if('revision-suggestion'!=_0x37c8a5||'insertion'!=_0x24cde8&&'deletion'!=_0x24cde8)continue;_0x1677ad[_0x241d9d]['markersEnd']['splice'](_0x2751fa,0x1),_0x2751fa--;const _0x1b2cda=_0x592119['findIndex'](_0x41705b=>_0x41705b['name']==_0x41c338);_0x1b2cda>-0x1&&_0x592119['splice'](_0x1b2cda,0x1);}}function _0x1d08da(_0x2701d3){const _0x33838e=_0x2701d3['split'](':');return{'group':_0x33838e[0x0],'type':_0x33838e[0x1],'subType':_0x33838e['length']>=0x5?_0x33838e[0x2]:null,'id':_0x33838e['length']<0x5?_0x33838e[0x2]:_0x33838e[0x3],'authorId':_0x33838e['length']<0x5?_0x33838e[0x3]:_0x33838e[0x4],'markerCount':0x6==_0x33838e['length']?_0x33838e[0x5]:null};}function _0x4a0b5b(_0x16c452){for(let _0x47b9f1=0x0;_0x47b9f1<_0x592119['length'];_0x47b9f1++){if(_0x16c452['isAdded']&&'insertion'==_0x592119[_0x47b9f1]['type'])return _0x16c452['isAddSuggestion']=_0x592119[_0x47b9f1],void delete _0x16c452['isAdded'];if(!_0x16c452['isAdded']&&!_0x16c452['isRemoved']&&'deletion'==_0x592119[_0x47b9f1]['type'])return void(_0x16c452['isRemoveSuggestion']=_0x592119[_0x47b9f1]);}}}['_setDistance'](_0xcb37cd,_0x282647){let _0x217300=0x0,_0x40022e=!0x1;const _0x5572bd=new Map();for(const _0x594585 of _0xcb37cd)_0x594585[_0x282647]?_0x40022e&&(_0x217300++,_0x40022e=!0x1):(_0x217300++,_0x40022e=!0x0),_0x5572bd['set'](_0x594585['id'],_0x217300);for(let _0x3032a5=0x0;_0x3032a5<_0xcb37cd['length'];_0x3032a5++){if('isRemoved'==_0x282647&&_0xcb37cd[_0x3032a5]['isAdded']||'isAdded'==_0x282647&&_0xcb37cd[_0x3032a5]['isRemoved'])continue;if('text'==_0xcb37cd[_0x3032a5]['type']){_0xcb37cd[_0x3032a5]['distance']=0x0;continue;}const _0x110ae7=_0x5572bd['get'](_0xcb37cd[_0x3032a5]['pairId']),_0xe874be=_0x5572bd['get'](_0xcb37cd[_0x3032a5]['id']);_0xcb37cd[_0x3032a5]['distance']=_0x110ae7-_0xe874be;}}['_getRevisionsRange'](_0x164af3,_0x77c2a9,_0x162982=!0x1){const _0x1c1c0a=[];let _0x32596a=this['repository']['getIndex'](_0x164af3),_0x65e9da=this['repository']['getIndex'](_0x77c2a9);for(-0x1==_0x65e9da&&(_0x65e9da=this['repository']['_revisions']['length'],_0x162982=!0x1);_0x32596a<_0x65e9da;)_0x1c1c0a['push'](this['repository']['getRevision'](_0x32596a)),_0x32596a++;return _0x162982&&_0x1c1c0a['push'](this['repository']['getRevision'](_0x32596a)),_0x1c1c0a;}['_threeWayMerge'](_0x3e0f76,_0x55f906,_0x6ab987,_0x11d9ad){const _0x40c999=this['editor']['model']['schema'];let _0x41af7e=_0x55f906;for(;_0x3e0f76[_0x41af7e]&&_0x3e0f76[_0x41af7e]['isAdded'];)_0x41af7e++;let _0x500280=_0x11d9ad;for(;_0x6ab987[_0x500280]&&_0x6ab987[_0x500280]['isRemoved'];)_0x500280++;_0x456e0c(_0x3e0f76,_0x55f906,_0x41af7e),_0x456e0c(_0x6ab987,_0x11d9ad,_0x500280);const _0x418805=_0x6ab987['slice'](_0x11d9ad,_0x500280)['concat'](_0x3e0f76['slice'](_0x55f906,_0x41af7e));return _0x418805['sort']((_0x1c6c65,_0x5c5945)=>_0x1c6c65['side']!=_0x5c5945['side']?_0x1c6c65['side']-_0x5c5945['side']:_0x1c6c65['level']!=_0x5c5945['level']?_0x1c6c65['level']-_0x5c5945['level']:_0x1c6c65['distance']!=_0x5c5945['distance']?_0x5c5945['distance']-_0x1c6c65['distance']:!!_0x1c6c65['isAdded']!=!!_0x5c5945['isAdded']?-0x1==_0x1c6c65['side']||0x0==_0x1c6c65['side']?_0x1c6c65['isAdded']?-0x1:0x1:_0x1c6c65['isAdded']?0x1:-0x1:_0x1c6c65['index']-_0x5c5945['index']),{'commonTape':_0x418805,'iEnd':_0x41af7e,'jEnd':_0x500280};function _0x456e0c(_0x458450,_0x2bd18b,_0x43b635){let _0x28f3f2=-0x1,_0x29f7b8=Number['POSITIVE_INFINITY'],_0xbface0=!0x0;for(let _0x4e3e48=_0x2bd18b;_0x4e3e48<_0x43b635;_0x4e3e48++)if(_0x40c999['isInline'](_0x458450[_0x4e3e48]['item'])||(_0xbface0=!0x1),_0x458450[_0x4e3e48]['item']['startIndex']<_0x2bd18b&&(_0x28f3f2=_0x4e3e48),_0x458450[_0x4e3e48]['item']['endIndex']>=_0x43b635){_0x29f7b8=_0x4e3e48;break;}_0xbface0&&(_0x28f3f2=_0x43b635-0x1);for(let _0x14e5c2=_0x2bd18b;_0x14e5c2<_0x43b635;_0x14e5c2++)_0x458450[_0x14e5c2]['side']=_0x14e5c2<=_0x28f3f2?-0x1:_0x14e5c2<_0x29f7b8?0x0:0x1,_0x458450[_0x14e5c2]['index']=_0x14e5c2;let _0x16eee2=0x0;for(let _0x5758c6=_0x2bd18b;_0x5758c6<=_0x28f3f2;_0x5758c6++)0x0==_0x458450[_0x5758c6]['distance']?_0x458450[_0x5758c6]['level']=_0x16eee2:(_0x16eee2++,_0x458450[_0x5758c6]['level']=_0x16eee2,_0x16eee2++);for(let _0xaaaacb=_0x2bd18b;_0xaaaacb<_0x43b635;_0xaaaacb++)0x0==_0x458450[_0xaaaacb]['side']&&(_0x458450[_0xaaaacb]['level']=_0x16eee2);_0x16eee2=0x0;for(let _0x1e4cb2=_0x43b635-0x1;_0x1e4cb2>=_0x29f7b8;_0x1e4cb2--)0x0==_0x458450[_0x1e4cb2]['distance']?_0x458450[_0x1e4cb2]['level']=_0x16eee2:(_0x16eee2--,_0x458450[_0x1e4cb2]['level']=_0x16eee2,_0x16eee2--);}}['_fixObsoleteTags'](_0xdc6db0){const _0x774be6=new Map(),_0xb3cf5f=this['editor']['model']['schema'];for(let _0xd6277f=0x1;_0xd6277f<_0xdc6db0['length'];_0xd6277f++){let _0xa20b7f,_0x108233,_0x2f9b2d;const _0x38dd72=_0xdc6db0[_0xd6277f],_0x3a9733=_0xdc6db0[_0xd6277f-0x1];if('text'==_0x38dd72['type'])continue;if(_0x38dd72['type']!=_0x3a9733['type'])continue;if(!_0xb3cf5f['isBlock'](_0x3a9733['item'])||_0xb3cf5f['isLimit'](_0x3a9733['item']))continue;if(!_0xb3cf5f['isBlock'](_0x38dd72['item'])||_0xb3cf5f['isLimit'](_0x38dd72['item']))continue;if((_0xdc6db0[_0xd6277f]['isAdded']||_0xdc6db0[_0xd6277f]['isAddSuggestion'])&&_0xdc6db0[_0xd6277f-0x1]['isRemoved'])_0xa20b7f=_0xdc6db0[_0xd6277f],_0x108233=_0xdc6db0[_0xd6277f-0x1],_0x2f9b2d=_0xd6277f-0x1;else{if(!_0xdc6db0[_0xd6277f]['isRemoved']||!_0xdc6db0[_0xd6277f-0x1]['isAdded']&&!_0xdc6db0[_0xd6277f-0x1]['isAddSuggestion'])continue;_0xa20b7f=_0xdc6db0[_0xd6277f-0x1],_0x108233=_0xdc6db0[_0xd6277f],_0x2f9b2d=_0xd6277f;}const _0x2d64df=_0xa20b7f['level']==_0x108233['level'],_0x2e81c1=Math['abs'](_0xa20b7f['level'])<Math['abs'](_0x108233['level'])&&0x0==_0x108233['distance'];(_0x2d64df||_0x2e81c1)&&(_0x774be6['set'](_0x108233['id'],_0xa20b7f['id']),_0xdc6db0['splice'](_0x2f9b2d,0x1),_0xd6277f--,_0xa20b7f['isAdded']=!0x1);}for(let _0x5be0a7=0x0;_0x5be0a7<_0xdc6db0['length'];_0x5be0a7++)_0x774be6['has'](_0xdc6db0[_0x5be0a7]['pairId'])&&(_0xdc6db0[_0x5be0a7]['pairId']=_0x774be6['get'](_0xdc6db0[_0x5be0a7]['pairId']));}['_removeMissingPairs'](_0x3199ad){const _0x4aec2a=new Set(_0x3199ad['map'](_0x50d942=>_0x50d942['id']));for(let _0x2b778e=0x0;_0x2b778e<_0x3199ad['length'];_0x2b778e++)_0x4aec2a['has'](_0x3199ad[_0x2b778e]['pairId'])||0x0==_0x3199ad[_0x2b778e]['distance']||(_0x3199ad[_0x2b778e]['isIncorrect']=!0x0);return _0x3199ad['filter'](_0x87668e=>!_0x87668e['isIncorrect']);}['_markMismatchedRemovedTags'](_0x2b6fb8){const _0x5b6ff2=new Set();for(let _0x55cd5e=0x0;_0x55cd5e<_0x2b6fb8['length'];_0x55cd5e++){if(_0x5b6ff2['has'](_0x2b6fb8[_0x55cd5e]['id'])&&_0x2b6fb8[_0x55cd5e]['isRemoved']&&(_0x2b6fb8[_0x55cd5e]['isIncorrect']=!0x0),_0x2b6fb8[_0x55cd5e]['isIncorrect'])continue;if(0x0==_0x2b6fb8[_0x55cd5e]['distance'])continue;if('elementStart'!=_0x2b6fb8[_0x55cd5e]['type'])continue;if(null==_0x2b6fb8[_0x55cd5e]['pairId'])continue;let _0x469b42=_0x55cd5e+0x1,_0x4127f8=0x0;for(;_0x2b6fb8[_0x469b42]['id']!=_0x2b6fb8[_0x55cd5e]['pairId'];)'elementStart'==_0x2b6fb8[_0x469b42]['type']?_0x4127f8++:'elementEnd'==_0x2b6fb8[_0x469b42]['type']&&_0x4127f8--,_0x469b42++;if(0x0!=_0x4127f8){if(_0x2b6fb8[_0x55cd5e]['isRemoved'])_0x2b6fb8[_0x55cd5e]['isIncorrect']=!0x0;else{for(;_0x469b42!=_0x55cd5e;)_0x2b6fb8[_0x469b42]['isRemoved']&&0x0!=_0x2b6fb8[_0x469b42]['distance']&&(_0x2b6fb8[_0x469b42]['isIncorrect']=!0x0,_0x5b6ff2['add'](_0x2b6fb8[_0x469b42]['pairId'])),_0x469b42--;}}}return _0x2b6fb8['filter'](_0x5df6ee=>!_0x5df6ee['isIncorrect']);}['_removeUnsupportedChanges'](_0x55b3ec){const _0x3f7ba9=this['editor']['model']['schema'];for(let _0xaf9296=0x0;_0xaf9296<_0x55b3ec['length'];_0xaf9296++){if(!(_0x55b3ec[_0xaf9296]['isAdded']||_0x55b3ec[_0xaf9296]['isAddSuggestion']||_0x55b3ec[_0xaf9296]['isRemoved']||_0x55b3ec[_0xaf9296]['isRemoveSuggestion']))continue;if(0x0==_0x55b3ec[_0xaf9296]['distance'])continue;const _0xf953b1=_0x55b3ec[_0xaf9296]['item'];_0x3f7ba9['isBlock'](_0xf953b1)||_0x3f7ba9['isLimit'](_0xf953b1)||(_0x55b3ec[_0xaf9296]['isAdded']&&delete _0x55b3ec[_0xaf9296]['isAdded'],_0x55b3ec[_0xaf9296]['isAddSuggestion']&&delete _0x55b3ec[_0xaf9296]['isAddSuggestion'],_0x55b3ec[_0xaf9296]['isRemoveSuggestion']&&delete _0x55b3ec[_0xaf9296]['isRemoveSuggestion'],_0x55b3ec[_0xaf9296]['isRemoved']&&(_0x55b3ec[_0xaf9296]['isIncorrect']=!0x0));}return _0x55b3ec['filter'](_0x249deb=>!_0x249deb['isIncorrect']);}['_makeModelFromTape'](_0x39052d,_0x586be4,_0x3cad3a){const _0x201a7c=new mt(),_0x26f76b=[],_0x1249d8=new Map(),_0x2b3a7e=this['editor']['model'],_0x41b7f5=_0x2b3a7e['schema'],_0x3dd03b=[_0x201a7c],_0x3068c6={},_0x2087f1={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3857a4=null;const _0x318233=[0x0];for(let _0xb4f5fd=0x0;_0xb4f5fd<_0x39052d['length'];_0xb4f5fd++)if('elementStart'===_0x39052d[_0xb4f5fd]['type']){_0x39052d[_0xb4f5fd]['previousPosition']=_0x2b3a7e['createPositionFromPath'](_0x201a7c,_0x318233);const _0xaad4f6=new ft(_0x39052d[_0xb4f5fd]['item']['name'],_0x39052d[_0xb4f5fd]['item']['getAttributes']());_0x3dd03b[0x0]['_appendChild'](_0xaad4f6),_0x318233['push'](0x0),_0x3dd03b['unshift'](_0xaad4f6),_0x39052d[_0xb4f5fd]['nextPosition']=_0x2b3a7e['createPositionFromPath'](_0x201a7c,_0x318233);}else'elementEnd'===_0x39052d[_0xb4f5fd]['type']?(_0x3dd03b['shift'](),_0x39052d[_0xb4f5fd]['previousPosition']=_0x2b3a7e['createPositionFromPath'](_0x201a7c,_0x318233),_0x318233['pop'](),_0x318233[_0x318233['length']-0x1]++,_0x39052d[_0xb4f5fd]['nextPosition']=_0x2b3a7e['createPositionFromPath'](_0x201a7c,_0x318233)):(_0x39052d[_0xb4f5fd]['previousPosition']=_0x2b3a7e['createPositionFromPath'](_0x201a7c,_0x318233),_0x3857a4?_0x3857a4['_data']+=_0x39052d[_0xb4f5fd]['item']['data']:_0x3857a4=new wt(_0x39052d[_0xb4f5fd]['item']['data'],_0x39052d[_0xb4f5fd]['item']['getAttributes']()),_0x39052d[_0xb4f5fd+0x1]&&'text'===_0x39052d[_0xb4f5fd+0x1]['type']&&_0x3fe3d9(_0x3857a4,_0x39052d[_0xb4f5fd+0x1]['item'])||(_0x3dd03b[0x0]['_appendChild'](_0x3857a4),_0x3857a4=null),_0x318233[_0x318233['length']-0x1]+=_0x39052d[_0xb4f5fd]['item']['offsetSize'],_0x39052d[_0xb4f5fd]['nextPosition']=_0x2b3a7e['createPositionFromPath'](_0x201a7c,_0x318233));for(let _0x1850d6=0x0;_0x1850d6<_0x39052d['length'];_0x1850d6++){const _0x3d326b=_0x39052d[_0x1850d6]['previousPosition'],_0x337af4=_0x39052d[_0x1850d6]['nextPosition'];for(const _0x1b1c20 of _0x39052d[_0x1850d6]['markersStart'])_0x1249d8['set'](_0x1b1c20,{'start':_0x3d326b,'end':null});_0x2f8951('isRemoveSuggestion',_0x1850d6,_0x3d326b,_0x337af4),_0x2f8951('isAddSuggestion',_0x1850d6,_0x3d326b,_0x337af4),_0x2f8951('isRemoved',_0x1850d6,_0x3d326b,_0x337af4),_0x2f8951('isAdded',_0x1850d6,_0x3d326b,_0x337af4);for(const _0x16a94c of _0x39052d[_0x1850d6]['markersEnd']){_0x1249d8['get'](_0x16a94c)['end']=_0x337af4;}}for(const [_0x40a161,_0x10f9be]of _0x1249d8){const _0x5ac36a=this['editor']['model']['createRange'](_0x10f9be['start'],_0x10f9be['end']);_0x201a7c['markers']['set'](_0x40a161,_0x5ac36a);}return _0x26f76b['sort']((_0x44d373,_0x30770a)=>{const _0x194828=_0x201a7c['markers']['get']('revision:'+_0x44d373['id']),_0x246a31=_0x201a7c['markers']['get']('revision:'+_0x30770a['id']);return _0x194828['start']['isBefore'](_0x246a31['start'])?-0x1:_0x194828['start']['isAfter'](_0x246a31['start'])?0x1:_0x194828['end']['isBefore'](_0x246a31['end'])?-0x1:_0x194828['end']['isAfter'](_0x246a31['end'])?0x1:'add'===_0x44d373['type']?-0x1:0x1;}),{'root':_0x201a7c,'changes':_0x26f76b};function _0x2f8951(_0x1644b6,_0x38cb40,_0x4210bc,_0x18c246){const _0x2e0552=!!_0x39052d[_0x38cb40][_0x1644b6],_0xa44761=_0x2e0552?_0x39052d[_0x38cb40][_0x1644b6]['userId']:null,_0x40e658=_0x38cb40===_0x39052d['length']-0x1,_0x2bd0d6=_0x2087f1[_0x1644b6][0x0],_0xbc56e4=_0x41b7f5['isObject'](_0x39052d[_0x38cb40]['item']);!_0x3068c6[_0x1644b6]&&_0x2e0552?_0x3068c6[_0x1644b6]={'start':_0x4210bc,'tapeItem':_0x39052d[_0x38cb40],'userId':_0xa44761,'type':_0x1644b6}:_0x3068c6[_0x1644b6]&&!_0x2e0552?(_0x3068c6[_0x1644b6]['end']=_0x4210bc,_0x33e9f6(_0x3068c6[_0x1644b6]),_0x3068c6[_0x1644b6]=null):_0x3068c6[_0x1644b6]&&_0x2e0552&&_0x3068c6[_0x1644b6]['userId']!==_0xa44761&&(_0x3068c6[_0x1644b6]['end']=_0x4210bc,_0x2bd0d6&&_0x2bd0d6['userId']===_0x3068c6[_0x1644b6]['userId']||_0x33e9f6(_0x3068c6[_0x1644b6]),_0x3068c6[_0x1644b6]={'start':_0x4210bc,'tapeItem':_0x39052d[_0x38cb40],'userId':_0xa44761,'type':_0x1644b6}),_0x3068c6[_0x1644b6]&&_0xbc56e4&&('elementStart'!==_0x39052d[_0x38cb40]['type']||_0x2bd0d6&&_0x2bd0d6['userId']===_0xa44761||_0x2087f1[_0x1644b6]['unshift']({'userId':_0xa44761,'object':_0x39052d[_0x38cb40]['item'],'change':_0x3068c6[_0x1644b6]}),'elementEnd'===_0x39052d[_0x38cb40]['type']&&_0x2bd0d6&&_0x2bd0d6['object']===_0x39052d[_0x38cb40]['item']&&(_0x2087f1[_0x1644b6]['shift'](),_0x3068c6[_0x1644b6]=_0x2bd0d6['change'])),_0x3068c6[_0x1644b6]&&_0x40e658&&(_0x3068c6[_0x1644b6]['end']=_0x18c246,_0x33e9f6(_0x3068c6[_0x1644b6]),_0x3068c6[_0x1644b6]=null);}function _0x33e9f6({start:_0x3eb1bb,end:_0x560296,tapeItem:_0x313646,userId:_0x26b64f,type:_0x24528e}){const _0xd6c3b4=_0x313646['item'],_0x451d8a=_0x2b3a7e['schema']['isBlock'](_0xd6c3b4)&&!_0x2b3a7e['schema']['isLimit'](_0xd6c3b4),_0x441728=_0x3eb1bb['nodeAfter']==_0x560296['parent']&&_0x560296['isAtStart'];if(_0x451d8a&&_0x441728)return;const _0x151c1b=_0x2b3a7e['createRange'](_0x3eb1bb,_0x560296),_0x5a774c=_0x586be4['get'](_0x26b64f),_0x2374e=new r({'author':_0x5a774c,'type':'isAdded'==_0x24528e||'isAddSuggestion'==_0x24528e?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x24528e||'isRemoveSuggestion'==_0x24528e},'createdAt':new Date(),'rootName':_0x3cad3a});_0x26f76b['push'](_0x2374e),_0x201a7c['markers']['set']('revision:'+_0x2374e['id'],_0x151c1b);}function _0x3fe3d9(_0xa546f8,_0x232451){const _0x1d30a1=_0xa546f8['getAttributes'](),_0x5c522b=_0x232451['getAttributes']();for(const _0x435c6a of _0x1d30a1){if(_0x435c6a[0x1]!==_0x232451['getAttribute'](_0x435c6a[0x0]))return!0x1;_0x5c522b['next']();}return _0x5c522b['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xb8646b=>{const _0x28b93a=_0xb8646b['markerName']['split'](':')[0x1],_0x11fbef=this['_getChangeFromId'](_0x28b93a);if(!_0x11fbef)return null;const _0x2c69ca='add'==_0x11fbef['type']?'insertion':'deletion',_0x1b6339=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2c69ca];return _0x11fbef['data']['isSuggestion']&&_0x1b6339['push']('ck-suggestion-marker-'+_0x2c69ca+'-new'),this['activeChange']==_0x11fbef&&_0x1b6339['push']('ck-suggestion-marker--active'),{'classes':_0x1b6339,'attributes':{'data-change-id':_0x28b93a}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x1f0be0=>{_0x1f0be0['on']('element:pre',(_0x8c6a16,_0x4158f2,_0x2b1129)=>{const _0x386605=_0x4158f2['viewItem']['getChild'](0x0);if(!_0x386605||!_0x386605['is']('element','code'))return;if(!_0x2b1129['consumable']['consume'](_0x386605,{'attributes':['vid_start','vid_end']}))return;const _0x2c6901=_0x4158f2['modelRange']['start']['nodeAfter'];_0x2b1129['writer']['setAttribute']('vid_start',_0x386605['getAttribute']('vid_start'),_0x2c6901),_0x2b1129['writer']['setAttribute']('vid_end',_0x386605['getAttribute']('vid_end'),_0x2c6901);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x296702=>{_0x296702['on']('element',(_0x11ea8f,_0x3b6822,_0x24c947)=>{if(!_0x24c947['consumable']['consume'](_0x3b6822['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3b6822['modelRange']['isCollapsed'])return;const _0xce0905=_0x3b6822['modelRange']['start']['nodeAfter'];_0xce0905['hasAttribute']('vid_start')||_0xce0905['hasAttribute']('vid')||(_0x24c947['writer']['setAttribute']('vid_start',_0x3b6822['viewItem']['getAttribute']('vid_start'),_0xce0905),_0x24c947['writer']['setAttribute']('vid_end',_0x3b6822['viewItem']['getAttribute']('vid_end'),_0xce0905));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x5cd87e=>_0x5cd87e['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1bf1cc,[,_0x4be7b8])=>{['vid_start','vid_end','vid']['includes'](_0x4be7b8)&&(_0x1bf1cc['return']=!0x0,_0x1bf1cc['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0xb85986=>{_0xb85986['on']('attribute:vid',(_0x17dcf2,_0x2068cb,_0x2f5364)=>{if('\x20'!=_0x2068cb['item']['data']||_0x2068cb['item']['parent']['maxOffset']>0x1)return;if(!_0x2f5364['consumable']['consume'](_0x2068cb['item'],_0x17dcf2['name']))return;const _0x1156af=_0x2f5364['writer'],_0x9beefb=_0x2f5364['mapper']['toViewRange'](_0x2068cb['range']);_0x1156af['wrap'](_0x9beefb,_0x1156af['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4d4e1b){const _0x250212=_0x4d4e1b['plugins']['get']('RevisionViewer');return(_0x5b6e55,_0x3c0c65,_0x50e676)=>{const _0x5780c4=_0x3c0c65['markerName']['split'](':')[0x1],_0x1e146d=_0x250212['_getChangeFromId'](_0x5780c4);if(!_0x1e146d)return null;const _0x3a0d70='add'==_0x1e146d['type']?'split':'merge';if(!_0x50e676['consumable']['test'](_0x3c0c65['markerRange'],_0x5b6e55['name']))return;const _0x5f58d9=_0x3c0c65['markerRange']['getWalker'](),_0x4f9ac6=_0x3c0c65['markerRange']['start'],_0x19bd4d=_0x4d4e1b['model']['schema'];let _0x340075=null,_0x5370ee=null,_0x4e6f54=!0x1,_0x1c6664=!0x1;for(const _0x389dd0 of _0x5f58d9){const _0x16ee89=_0x389dd0['item'];_0x4e6f54=_0x4e6f54||_0x19bd4d['isContent'](_0x16ee89);const _0x3a613b=_0x50e676['mapper']['toViewElement'](_0x16ee89);if(_0x3a613b&&_0x3a613b['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x389dd0['type']&&(_0x19bd4d['isBlock'](_0x16ee89)&&!_0x19bd4d['isLimit'](_0x16ee89)&&(_0x16ee89['nextSibling']||_0x4f9ac6['isAtEnd']?_0x340075&&_0x340075['parent']==_0x16ee89||(_0x340075=_0x16ee89,_0x199336(_0x389dd0['previousPosition']),_0x1c6664=!0x0):_0x5370ee=_0x5370ee||_0x389dd0['previousPosition']));}function _0x199336(_0x567901){const _0x3f4e93=_0x50e676['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3a0d70}),_0x2ef93b=_0x50e676['mapper']['toViewPosition'](_0x567901);_0x1e146d['data']['isSuggestion']&&_0x50e676['writer']['addClass']('ck-suggestion-marker-'+_0x3a0d70+'-new',_0x3f4e93),_0x250212['activeChange']==_0x1e146d&&_0x50e676['writer']['addClass']('ck-suggestion-marker--active',_0x3f4e93),_0x50e676['writer']['insert'](_0x2ef93b,_0x3f4e93),_0x50e676['mapper']['bindElementToMarker'](_0x3f4e93,_0x3c0c65['markerName']);}_0x4e6f54||_0x1c6664||!_0x5370ee||_0x199336(_0x5370ee);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x22f857,_0x5beef9,_0x4b6fda)=>{const _0x491581=_0x4b6fda['mapper']['markerNameToElements'](_0x5beef9['markerName']);if(_0x491581){for(const _0x1df5b5 of _0x491581)(_0x1df5b5['hasClass']('ck-suggestion-marker-split')||_0x1df5b5['hasClass']('ck-suggestion-marker-merge'))&&(_0x4b6fda['mapper']['unbindElementFromMarkerName'](_0x1df5b5,_0x5beef9['markerName']),_0x4b6fda['writer']['remove'](_0x1df5b5));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x347cbc,_0x138cd7,_0x20dbc7)=>{const _0x43281a=_0x138cd7['markerName']['split'](':')[0x1],_0x581bf3=this['_getChangeFromId'](_0x43281a);if(!_0x581bf3)return null;const _0x284fed='add'==_0x581bf3['type']?'split':'merge';if(_0x20dbc7['consumable']['test'](_0x138cd7['markerRange'],_0x347cbc['name']))for(const _0x36246a of _0x138cd7['markerRange']['getItems']()){if(!_0x36246a['is']('element','softBreak'))continue;const _0xdee41c=_0x20dbc7['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x284fed}),_0x5a5ea3=_0x20dbc7['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x36246a));_0x581bf3['data']['isSuggestion']&&_0x20dbc7['writer']['addClass']('ck-suggestion-marker-'+_0x284fed+'-new',_0xdee41c),this['activeChange']==_0x581bf3&&_0x20dbc7['writer']['addClass']('ck-suggestion-marker--active',_0xdee41c),_0x20dbc7['writer']['insert'](_0x5a5ea3,_0xdee41c),_0x20dbc7['mapper']['bindElementToMarker'](_0xdee41c,_0x138cd7['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x120fd7=>{for(const _0x10ae12 of this['editor']['model']['document']['getRootNames']()){const _0x298174=this['editor']['model']['document']['getRoot'](_0x10ae12),_0x3087d0=this['editor']['editing']['view']['document']['getRoot'](_0x10ae12);if(_0x3087d0){const _0x257792=_0x298174['getAttribute']('revisionHistoryAttachChange');if(_0x120fd7['removeAttribute']('data-change-id',_0x3087d0),_0x120fd7['removeClass']('ck-revision-history-root-add',_0x3087d0),_0x120fd7['removeClass']('ck-revision-history-root-remove',_0x3087d0),_0x120fd7['removeClass']('ck-revision-history-root--active',_0x3087d0),_0x257792){const _0x4513f9=this['_getChangeFromId'](_0x257792);if(!_0x4513f9)return null;_0x120fd7['setAttribute']('data-change-id',_0x257792,_0x3087d0),_0x120fd7['addClass']('ck-revision-history-root-'+_0x4513f9['type'],_0x3087d0),this['activeChange']==_0x4513f9&&_0x120fd7['addClass']('ck-revision-history-root--active',_0x3087d0);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x4323d9=>'revision-comment:'+_0x4323d9,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x8d7d03=>'revision-suggestion:'+_0x8d7d03,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x58324f=>({'name':'suggestion:'+_0x58324f,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x15c0c6=>{const _0x1a9f73=_0x15c0c6['markerName']['split'](':')[0x1];return'insertion'!=_0x1a9f73&&'deletion'!=_0x1a9f73?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1a9f73]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x382d90,_0x94b41e,_0x69c387)=>{const _0x1864d6=_0x69c387['mapper']['markerNameToElements'](_0x94b41e['markerName']);if(_0x1864d6){for(const _0x21111e of _0x1864d6)_0x21111e['is']('uiElement')&&(_0x69c387['mapper']['unbindElementFromMarkerName'](_0x21111e,_0x94b41e['markerName']),_0x69c387['writer']['remove'](_0x21111e));}},{'priority':'high'});}['_getChangeFromId'](_0x1aa83e){return this['_changeIdToChange']['get'](_0x1aa83e);}['_getViewForChange'](_0x254ec1){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x254ec1),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x476cf1,_0xcaa7a7,_0x337502,_0xbc7251)=>{_0xbc7251&&this['_balloon']['remove'](_0xbc7251),_0x337502&&(this['_balloon']['add']({'view':_0x337502,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x55f6c6=this['editor']['editing'],_0x30bf6d=this['_getChangeFromId'](_0x337502['changeId']);let _0x5c1c4a;if(_0x30bf6d['data']['isOnRoot']){const _0x2512b9=_0x55f6c6['view']['getDomRoot'](_0x30bf6d['rootName']);_0x5c1c4a=Array['from'](_0x2512b9['getClientRects']());}else{const _0x5cccce=this['editor']['model']['markers']['get']('revision:'+_0x337502['changeId']);_0x5c1c4a=Array['from'](_0x55f6c6['mapper']['markerNameToElements'](_0x5cccce['name']))['map'](_0x4455d3=>_0x55f6c6['view']['domConverter']['mapViewToDom'](_0x4455d3))['map'](_0x3742d2=>Array['from'](_0x3742d2['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x5c1c4a[0x0];return _0x5c1c4a['find'](_0x65b0a2=>_0x65b0a2['top']-0x3<=this['_activeViewTarget']['y']&&_0x65b0a2['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x65b0a2['left']-0x3<=this['_activeViewTarget']['x']&&_0x65b0a2['right']+0x3>=this['_activeViewTarget']['x'])||_0x5c1c4a[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x3b2112,_0x4c9d7f,_0x30506d,_0x62fadd)=>{this['activeView']=_0x30506d?this['_getViewForChange'](_0x30506d):null,this['editor']['model']['change'](()=>{const _0x598956=this['editor']['editing'];_0x62fadd&&(_0x62fadd['data']['isOnRoot']?_0x598956['view']['change'](_0x3772c1=>{_0x3772c1['removeClass']('ck-revision-history-root--active',_0x598956['view']['document']['getRoot'](_0x62fadd['rootName']));}):_0x598956['reconvertMarker']('revision:'+_0x62fadd['id'])),_0x30506d&&(_0x30506d['data']['isOnRoot']?_0x598956['view']['change'](_0x9817e1=>{_0x9817e1['addClass']('ck-revision-history-root--active',_0x598956['view']['document']['getRoot'](_0x30506d['rootName']));}):_0x598956['reconvertMarker']('revision:'+_0x30506d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x408b2b,_0x1f7cc9)=>{if(this['activeChange'])return;const _0x491dbe=this['_findChangeIdFromDomTarget'](_0x1f7cc9['target']),_0x4250d9=this['_changeIdToChange']['get'](_0x491dbe);_0x4250d9?(this['_activeViewTarget']={'x':_0x1f7cc9['domEvent']['x'],'y':_0x1f7cc9['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x4250d9)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x815bca,_0x1ecc6c)=>{const _0x9271db=this['_findChangeIdFromDomTarget'](_0x1ecc6c['target']),_0x2a2511=this['_changeIdToChange']['get'](_0x9271db);_0x2a2511?(this['_activeViewTarget']={'x':_0x1ecc6c['domEvent']['x'],'y':_0x1ecc6c['domEvent']['y']},_0x2a2511===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2a2511):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x553813){do{const _0x32b6fd=_0x553813['getAttribute']('data-change-id');if(_0x32b6fd)return _0x32b6fd;_0x553813=_0x553813['parent'];}while(_0x553813);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x31a98a=>{for(const _0x286ebd of this['editor']['model']['markers'])_0x31a98a['removeMarker'](_0x286ebd);});}}function tt(_0x2fbf89,_0xf523c){return(_0x385973,_0x298949,_0x2142df)=>{if(!_0x2142df['consumable']['test'](_0x298949['markerRange'],_0x385973['name']))return;const _0x1cd51a=_0x298949['markerRange']['getWalker'](),_0xc10944=_0x298949['markerRange']['start'],_0x16350d=_0x2fbf89['model']['schema'];let _0xe8f155=null,_0x31221d=null,_0x30b795=!0x1,_0x2e056a=!0x1;for(const _0x234943 of _0x1cd51a){const _0x9a5511=_0x234943['item'];_0x30b795=_0x30b795||_0x16350d['isContent'](_0x9a5511);const _0x441e10=_0x2142df['mapper']['toViewElement'](_0x9a5511);if(_0x441e10&&_0x441e10['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x234943['type']&&(_0x16350d['isBlock'](_0x9a5511)&&!_0x16350d['isLimit'](_0x9a5511)&&(_0x9a5511['nextSibling']||_0xc10944['isAtEnd']?_0xe8f155&&_0xe8f155['parent']==_0x9a5511||(_0xe8f155=_0x9a5511,_0x58358e(_0x234943['previousPosition']),_0x2e056a=!0x0):_0x31221d=_0x31221d||_0x234943['previousPosition']));}function _0x58358e(_0x2ed888){const _0xf9a022=_0x2142df['mapper']['toViewPosition'](_0x2ed888),_0x1875a5=_0x2142df['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0xf523c});_0x2142df['writer']['insert'](_0xf9a022,_0x1875a5),_0x2142df['mapper']['bindElementToMarker'](_0x1875a5,_0x298949['markerName']);}_0x30b795||_0x2e056a||!_0x31221d||_0x58358e(_0x31221d);};}class _t extends _0x470aae{constructor(_0x1352c9){super(_0x1352c9);const _0x393747=_0x1352c9['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x393747,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x393747,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x312001=this['editor'],_0x4bd0c0=_0x312001['plugins']['get'](d),_0x28b487=_0x4bd0c0['isReady']?_0x4bd0c0['diff']['newRevisionId']:null;_0x312001['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x28b487);}['refresh'](){const {isReady:_0x108caa,isEnabled:_0x45bea6}=this['editor']['plugins']['get'](d);this['isEnabled']=_0x108caa&&_0x45bea6;}}class yt extends _0x470aae{['_step'];constructor(_0x3eee7b,{direction:_0x672384}){super(_0x3eee7b);const _0x10c666=_0x3eee7b['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x672384?0x1:-0x1,this['listenTo'](_0x10c666,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x10c666,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x10c666,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x110f0b=this['editor'],_0x4b38a9=_0x110f0b['plugins']['get'](d),{isNavigationMode:_0x159cea,currentChangeNumber:_0x44757e}=_0x4b38a9;let _0x35b17c;if(_0x4b38a9['activeChange']=_0x159cea?_0x4b38a9['diff']['changes']['get'](_0x44757e+this['_step']):_0x4b38a9['diff']['changes']['first'],_0x4b38a9['activeChange']['data']['isOnRoot'])_0x35b17c=_0x110f0b['editing']['view']['getDomRoot'](_0x4b38a9['activeChange']['rootName']);else{const _0x821f2e=_0x110f0b['model']['markers']['get']('revision:'+_0x4b38a9['activeChange']['id']);_0x35b17c=_0x10f5bf(_0x110f0b['editing'],_0x821f2e);}_0xfae4f5({'target':_0x35b17c,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x40a871,currentChangeNumber:_0x360eeb,numberOfChanges:_0x4c8984,isReady:_0x37e747,isEnabled:_0x34ddea}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x34ddea&&_0x37e747&&_0x4c8984)&&(!_0x40a871||(0x1===this['_step']?_0x360eeb<_0x4c8984-0x1:_0x360eeb>0x0));}}class ui extends ts{constructor(_0x171533){super(_0x171533);const _0x223804=this['bindTemplate'],_0x1881de=new te(_0x171533),_0x56b846=new te(_0x171533);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',(_0x2b4763,_0x1860a2)=>_0x2b4763&&_0x1860a2>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x19325b,_0x1e40f3,_0x5e2c7a,_0x3b49bc)=>{if(!_0x19325b)return R(_0x171533,'Loading...');if(!_0x5e2c7a)return R(_0x171533,'No\x20changes');const _0x44da90=R(_0x171533,'NUMBER_OF_CHANGES',_0x5e2c7a);return _0x3b49bc?R(_0x171533,'X_OF_Y_CHANGES',[_0x1e40f3+0x1,_0x5e2c7a]):_0x44da90;}),_0x1881de['set']({'label':R(_0x171533,'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'}),_0x56b846['set']({'label':R(_0x171533,'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'}),_0x1881de['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x56b846['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x1881de['on']('execute',()=>this['fire']('execute','backward')),_0x56b846['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',_0x223804['if']('_isStatusLabelVisible','ck-hidden',_0x4e0b98=>!_0x4e0b98)]},'children':[{'text':_0x223804['to']('isNavigationMode',_0x55cdea=>_0x55cdea?R(_0x171533,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x171533,'Total')+':\x20')}]},{'text':_0x223804['to']('_statusText')}]},new _0x2540ab(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x1881de,_0x56b846]}]});}}const le='ck-editor__editable__loading-overlay';class de extends _0x4e17c7{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0xbf779c=this['editor']['editing']['view'];_0xbf779c['change'](_0x1c385b=>{for(const _0x3d32ac of _0xbf779c['document']['roots'])_0x1c385b['addClass'](le,_0x3d32ac);});}['hide'](){const _0x260726=this['editor']['editing']['view'];_0x260726['change'](_0x1ba34a=>{for(const _0x46527c of _0x260726['document']['roots'])_0x1ba34a['removeClass'](le,_0x46527c);});}}class m extends _0x4e17c7{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,de];}['init'](){const _0x2c94c7=this['editor'],_0x8bcf95=_0x2c94c7['plugins']['get'](d),_0x1c2d36=_0x2c94c7['plugins']['get'](de);_0x2c94c7['ui']['componentFactory']['add']('exitToEditing',_0x35601b=>{const _0x68fd3e=new te(_0x35601b);return _0x68fd3e['set']({'label':R(_0x35601b,'Back\x20to\x20editing'),'icon':_0x3bf8ea['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x68fd3e,'execute',()=>{_0x2c94c7['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x68fd3e;}),_0x2c94c7['ui']['componentFactory']['add']('restoreRevision',_0x5ba8cd=>{const _0x20dd31=new te(_0x5ba8cd);return _0x20dd31['set']({'label':R(_0x5ba8cd,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x20dd31['bind']('isEnabled')['to'](_0x2c94c7['commands']['get']('restoreRevision')),this['listenTo'](_0x20dd31,'execute',()=>_0x2c94c7['execute']('restoreRevision')),_0x20dd31;}),_0x2c94c7['ui']['componentFactory']['add']('changesNavigation',_0x18b094=>{const _0x258a79=new ui(_0x18b094),_0x5c4034=_0x2c94c7['commands']['get']('showPreviousChange'),_0x5cfe42=_0x2c94c7['commands']['get']('showNextChange');return _0x258a79['bind']('isBackwardNavigationEnabled')['to'](_0x5c4034,'isEnabled'),_0x258a79['bind']('isForwardNavigationEnabled')['to'](_0x5cfe42,'isEnabled'),_0x258a79['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x8bcf95),this['listenTo'](_0x258a79,'execute',(_0x2ddbb6,_0x548f53)=>{_0x2c94c7['execute']('forward'===_0x548f53?'showNextChange':'showPreviousChange');}),_0x258a79;}),_0x1c2d36['show'](),_0x8bcf95['on']('change:isReady',(_0x244139,_0xf73434,_0x42b51d)=>{_0x42b51d?_0x1c2d36['hide']():_0x1c2d36['show']();});}}class pt extends _0x11555d{['_resizeObserver']=null;constructor(_0xa677f9,_0x24551e){super(_0xa677f9,_0x24551e);const _0x3a8e25=this['bindTemplate'];this['set']({'label':R(_0xa677f9,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0xa677f9,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x3a8e25['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 _0x2c1a8a=this['fieldView']['element'];this['_tooltipString']=_0x2c1a8a['scrollWidth']>_0x2c1a8a['clientWidth']&&_0x2c1a8a['value']||'';}}class ri extends ts{constructor(_0x3e584a,_0x5525df,_0x58181e){super(_0x3e584a);const _0x5494c1=new _0x40c008();_0x5494c1['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 _0x5ac5d1=['ck','ck-revision-history-sidebar__revision-author'];_0x58181e&&_0x5ac5d1['push']('ck-revision-history-sidebar__revision-author_creator');const _0x3220c2=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x3e584a,_0x58181e?'Revision\x20creator':'Revision\x20author')},'children':[_0x5494c1,_0x5525df['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5ac5d1},'children':_0x3220c2});}}function oi(_0x648128,_0x796da0){const _0x4fca94=_0x648128['bindTemplate'],_0x121daa=_0x648128['locale'],_0x4770ae=_0x32fc3c(_0x121daa);_0x4770ae['panelPosition']='sw';const _0x543ef7=function(_0x3582c4,_0x224def){const _0x539f4c=function(_0x4aa48b,_0x3924e1){const _0x4369b6=_0x4aa48b['locale'],_0x5919d2={'Compare\x20against\x20selected':R(_0x4369b6,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x4369b6,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x4369b6,'Restore\x20this\x20revision')};return _0x3924e1['map'](_0x55a133=>{const _0xce7059=_0x5919d2[_0x55a133['name']];return _0xce7059&&_0xce7059!==_0x55a133['name']&&(_0x55a133['name']=_0xce7059),_0x55a133;});}(_0x3582c4,_0x224def),_0x15a25d=new _0x510f19();for(const _0x33c60d of _0x539f4c){const _0xa624d1={'type':'button','model':new _0x4a878a({'label':_0x33c60d['name'],'class':_0x33c60d['class'],'withText':!0x0,'role':'menuitem','_action':_0x33c60d['action']})};_0xa624d1['model']['bind']('isEnabled')['to'](_0x3582c4,'isActionsDropdownOpen',_0x24de1c=>'function'!=typeof _0x33c60d['isEnabled']||(!_0x24de1c||_0x33c60d['isEnabled'](_0x3582c4))),_0x15a25d['add'](_0xa624d1);}return _0x15a25d;}(_0x648128,_0x796da0);return _0x648128['bind']('isActionsDropdownOpen')['to'](_0x4770ae,'isOpen'),_0x4770ae['buttonView']['set']({'label':R(_0x121daa,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3bf8ea['threeVerticalDots']}),_0x4770ae['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4fca94['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4fca94['to'](_0x1fc18=>_0x1fc18['stopPropagation']())}}),_0x4770ae['on']('execute',_0x28c553=>{_0x648128['isReady']&&'function'==typeof _0x28c553['source']['_action']&&_0x28c553['source']['_action'](_0x648128);}),to(_0x4770ae,_0x543ef7,{'role':'menu'}),_0x4770ae['listenTo'](_0x648128,'change:isActionsDropdownOpen',(_0x258313,_0x1850f8,_0xf08193)=>{if(_0xf08193)for(const _0x2c7658 of _0x4770ae['listView']['items']){const _0x48f2d8=_0x2c7658['children']['first'],_0x401c72=_0x796da0['find'](_0x4c71e6=>_0x4c71e6['action']===_0x48f2d8['_action'])['isVisible'];_0x2c7658['isVisible']=void 0x0===_0x401c72||_0x401c72(_0x648128);}}),_0x4770ae;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x42e5fa,_0x23ad97,_0x213945,_0x36a76d){super(_0x42e5fa);const _0xa30f19=this['bindTemplate'],_0x3bee15=function(_0x58fd91,_0xfea666){const _0x352cd0=Array['from'](_0xfea666['authors'])['filter'](_0x248b0e=>_0x248b0e!=_0xfea666['creator']);return _0xfea666['creator']&&_0x352cd0['unshift'](_0xfea666['creator']),_0x352cd0['map'](_0x17755a=>new ri(_0x58fd91,_0x17755a,_0x17755a==_0xfea666['creator']));}(_0x42e5fa,_0x23ad97);this['id']=_0x23ad97['id'],this['_revision']=_0x23ad97,this['_requireRevisionName']=_0x36a76d,this['bind']('name','createdAt')['to'](_0x23ad97),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x26bad9=>{return _0x5535d0=_0x42e5fa['uiLanguage'],(_0x360406=_0x26bad9)['toLocaleDateString'](_0x5535d0,{'month':'long','day':'numeric'})+',\x20'+_0x360406['toLocaleTimeString'](_0x5535d0,{'hour':'numeric','minute':'numeric'});var _0x5535d0,_0x360406;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x42e5fa,_0x2f692f),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x45eff6=>_0x45eff6||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2f2320,_0x57084a)=>_0x2f2320&&_0x57084a),this['revisionActionsView']=_0x213945&&_0x213945['length']?oi(this,_0x213945):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0xa30f19['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0xa30f19['if']('isEnabled','ck-disabled',_0x44b4d7=>!_0x44b4d7),_0xa30f19['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0xa30f19['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0xa30f19['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':_0xa30f19['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':_0x3bee15}]},this['revisionActionsView']],'on':{'click':_0xa30f19['to'](_0xf838fb=>{_0xf838fb['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0xae277e=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0xae277e,'change',()=>{this['_requireRevisionName']&&!_0xae277e['value']||this['fire']('setName',{'id':this['id'],'name':_0xae277e['value']}),_0xae277e['value']||(_0xae277e['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(_0x2f87cd,_0x2f5796){const _0x2a443e=_0x5aa3dd['fromJSDate'](_0x2f87cd)['setLocale'](_0x2f5796),_0x54d15a=_0x5aa3dd['local'](),_0x10826b=_0x54d15a['minus']({'days':0x1})['startOf']('day');let _0x313edf,_0x4e8b61;return _0x2a443e['hasSame'](_0x54d15a,'day')?(_0x313edf=_0x2a443e['startOf']('day')['toJSDate'](),_0x4e8b61=_0x2a443e['toRelativeCalendar']()):_0x2a443e['hasSame'](_0x10826b,'day')?(_0x313edf=_0x10826b['toJSDate'](),_0x4e8b61=_0x2a443e['toRelativeCalendar']()):_0x2a443e['hasSame'](_0x54d15a,'week')?(_0x313edf=_0x2a443e['startOf']('week')['toJSDate'](),_0x4e8b61=_0x2a443e['weekdayLong']||''):_0x2a443e['hasSame'](_0x54d15a,'year')?(_0x313edf=_0x2a443e['startOf']('month')['toJSDate'](),_0x4e8b61=_0x2a443e['monthLong']||''):(_0x313edf=_0x2a443e['startOf']('year')['toJSDate'](),_0x4e8b61=String(_0x2a443e['year'])),{'startDate':_0x313edf,'localizedPeriodName':_0x4e8b61};}class vi extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x261e30,_0x10154d,_0x22712a,_0x3e1b9c){super(_0x261e30);const _0x5946e6=mi(_0x10154d,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x10154d,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x22712a,this['_requireRevisionName']=_0x3e1b9c,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':_0x5946e6}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x55fd38){const _0x284cd4=new hi(this['locale'],_0x55fd38,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x284cd4);}['removeRevision'](_0x14f635){const _0x3e8b43=this['revisionViews']['find'](_0x3288bf=>_0x3288bf['id']===_0x14f635['id']);this['revisionViews']['remove'](_0x3e8b43);}}class as extends ts{constructor(_0x4cf72a){super(_0x4cf72a);const _0x2449c0=new _0x40c008();_0x2449c0['content']=_0x3bf8ea['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2449c0,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x4cf72a,'Revision\x20history')]}]});}}class di extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0xd4086d,_0x4bb170,_0x284398,_0x168510){super(_0xd4086d);const _0x5f05cf=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4bb170,this['_revisionActions']=_0x284398,this['_requireRevisionName']=_0x168510,this['on']('select',(_0xa8cf29,_0x227a4b)=>{this['fire']('revisionSelected',_0x227a4b);}),this['on']('setName',(_0x4505bf,_0x5317b7)=>{this['fire']('revisionSetName',_0x5317b7);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0xd4086d),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x5f05cf['if']('isEnabled','ck-disabled',_0x3c9ae9=>!_0x3c9ae9)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x12a405 of this['_revisions'])this['_addRevision'](_0x12a405);this['_revisions']['on']('add',(_0x50d785,_0xf15ace)=>{this['_addRevision'](_0xf15ace);}),this['_revisions']['on']('remove',(_0x2726e5,_0x665a59)=>{this['_removeRevision'](_0x665a59);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1ea6f8=>_0x1ea6f8['revisionViews']['map'](_0x43bd4c=>_0x43bd4c))['flat']();}['selectRevision'](_0x17b1ec){for(const _0x4910b8 of this['revisionViews'])_0x17b1ec&&_0x17b1ec['id']===_0x4910b8['id']?_0x4910b8['select']():_0x4910b8['deselect']();}['highlightRevisions'](_0x3b7c06){for(const _0x469628 of this['revisionViews'])_0x3b7c06['some'](({id:_0x537e3e})=>_0x537e3e===_0x469628['id'])?_0x469628['highlight']():_0x469628['unhighlight']();}['_addRevision'](_0x4eebf8){const _0x1c7072=mi(_0x4eebf8['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x103606=this['timePeriodViews']['get'](0x0);_0x103606&&_0x103606['startDate']['getTime']()===_0x1c7072['getTime']()||(_0x103606=new vi(this['locale'],_0x1c7072,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x103606)),_0x103606['addRevision'](_0x4eebf8);}['_removeRevision'](_0xd16b76){const _0x16d136=mi(_0xd16b76['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x16d136)['removeRevision'](_0xd16b76);}['_getTimePeriodViewByStartDate'](_0xbecb20){return this['timePeriodViews']['find'](_0x14b028=>_0x14b028['startDate']['getTime']()===_0xbecb20['getTime']());}}class g extends _0x4e17c7{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- Rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x46242a){super(_0x46242a),this['_revisionViewer']=_0x46242a['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x429c8f=this['_revisionsRepository']['_revisions'],_0xd1e78d=this['_createRevisionActions'](),_0x57cd5e=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ci(this['editor']['locale'],_0x429c8f,_0xd1e78d,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',(_0x15d719,_0x65fa1d)=>{_0x65fa1d['revisionViews']['on']('add',(_0x2635db,_0x195c0d)=>{_0x195c0d['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)),_0x57cd5e['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x2b3871=this['_revisionsRepository']['getRevision'](0x0);if(_0x2b3871){const _0x414da7=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2b3871['id']);this['_revisionViewer']['compare'](_0x2b3871,_0x414da7);}}['_handleRevisionSelected'](_0xb51152,_0x4a3064){const _0x3f9682=this['_revisionsRepository']['getRevision'](_0x4a3064['id']),_0x372837=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3f9682['id']);this['_revisionViewer']['compare'](_0x3f9682,_0x372837);}['_handleRevisionSetName'](_0x316fdd,_0x56f107){this['_revisionsRepository']['getRevision'](_0x56f107['id'])['setName'](_0x56f107['name']);}['_handleDiffChange'](_0x593a2e,_0x46384b,_0x55458b){const _0x3aa2d1=this['_revisionsRepository']['getRevisionsInDiff'](_0x55458b);_0x3aa2d1['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3aa2d1),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3aa2d1[0x0]));}['_createRevisionActions'](){const _0x22f6dd=this['editor'],_0x48675f=g['availableRevisionActions'],_0x2710ad=_0x22f6dd['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x2710ad['length'])return _0x2710ad['map'](_0x4b2988=>{const _0xd6e9db='string'==typeof _0x4b2988?Object['assign']({},_0x48675f[_0x4b2988]):_0x4b2988;return _0xd6e9db['action']=_0xd6e9db['action']['bind'](this,_0x22f6dd),_0xd6e9db['isVisible']&&(_0xd6e9db['isVisible']=_0xd6e9db['isVisible']['bind'](this,_0x22f6dd)),_0xd6e9db;});}}function Rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x32a6df},_0x1a622e)=>{const _0x26fd3e=_0x32a6df['get'](d),_0x501052=_0x26fd3e['repository'];let _0x2cfc70=_0x26fd3e['diff']['newRevisionId'],_0x2e442c=_0x1a622e['id'];_0x501052['getIndex'](_0x2cfc70)>_0x501052['getIndex'](_0x2e442c)&&([_0x2cfc70,_0x2e442c]=[_0x2e442c,_0x2cfc70]),_0x26fd3e['compare'](_0x2cfc70,_0x2e442c);},'isVisible':({plugins:_0x291be0},_0x511098)=>{const _0x34bf43=_0x291be0['get'](d);return!(_0x34bf43['repository']['getRevisionsInDiff'](_0x34bf43['diff'])['length']>0x2)&&!_0x511098['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x559025,{id:_0x2d8881})=>{_0x559025['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x2d8881);},'isVisible':({plugins:_0x2c232c},_0xa86de2)=>!!_0x2c232c['get'](d)['repository']['getLaterVisibleRevision'](_0xa86de2['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0xc04e9},{id:_0x116e2c,revisionNameView:_0x1b8077})=>{const _0x16c52a=_0xc04e9['get'](d),_0x2a4607=_0x16c52a['repository']['getEarlierVisibleRevision'](_0x116e2c);_0x16c52a['compare'](_0x116e2c,_0x2a4607),_0x1b8077['focus'](),_0x1b8077['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x3e3946,_0x20e38f){super(_0x3e3946),this['_view']=_0x20e38f,this['_toolbarConfig']=ht(_0x3e3946['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x59ea9d){const _0x1eb05d=this['editor'],_0x5c4ed4=this['view'],_0x424fe4=_0x1eb05d['editing']['view'],_0x250a3f=_0x5c4ed4['editable'],_0x43a5f5=_0x424fe4['document']['getRoot']();_0x250a3f['name']=_0x43a5f5['rootName'],_0x5c4ed4['render']();const _0x518a63=_0x250a3f['element'];this['setEditableElement'](_0x250a3f['name'],_0x518a63),_0x5c4ed4['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x424fe4['attachDomRoot'](_0x518a63),this['_elementReplacer']['replace'](_0x59ea9d,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x1c662b=this['view'],_0x524dc1=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x524dc1['detachDomRoot'](_0x1c662b['editable']['name']),_0x1c662b['destroy']();}['_initToolbar'](){const _0x1bf03e=this['view'];_0x1bf03e['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x1bf03e['stickyPanel']['limiterElement']=_0x1bf03e['element'],_0x1bf03e['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x890d08})=>_0x890d08),_0x1bf03e['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x1bf03e['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x1241a9,_0x4660f1,_0x12a88f={}){super(_0x1241a9),this['stickyPanel']=new lt(_0x1241a9),this['toolbar']=new nt(_0x1241a9,{'shouldGroupWhenFull':_0x12a88f['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x1241a9,_0x4660f1);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
- rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4e6451,_0x207961){super(_0x207961),this['sourceElement']=_0x4e6451,this['model']['document']['createRoot']();const _0x3e7d71=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x3e7d71);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2c64eb,_0xd816b0){const _0x3a1126=new this(_0x2c64eb,_0xd816b0);return await _0x3a1126['initPlugins'](),await _0x3a1126['ui']['init'](_0x2c64eb),await _0x3a1126['data']['init'](_0x3a1126['config']['get']('initialData')||''),_0x3a1126['fire']('ready'),_0x3a1126;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x24aabd{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x202c14){function _0x624173(_0xc03c99){return _0xc03c99['map'](_0x4d03b9=>String['fromCharCode'](_0x4d03b9))['join']('');}super(_0x202c14),this['result']='end',_0x202c14[_0x624173([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x624173([0x76,0x69,0x65,0x77])][_0x624173([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x624173([0x61,0x75,0x74,0x6f]),_0x202c14[_0x624173([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x624173([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x624173([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x624173([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x624173([0x6f,0x6b])});}}class H extends _0x24aabd{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x1dfd5a){if(super(_0x1dfd5a),!this['editor']['config']['get']('revisionHistory'))throw new _0x2c83c4('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x1216e0=>this['_showRevisionViewer']({..._0x1216e0,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x6efeaa=>this['_closeRevisionViewer'](_0x6efeaa)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xb5d5d8=>this['_restoreRevision'](_0xb5d5d8)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0xc5b1a4){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0xc5b1a4;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4f7658){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4f7658);}['getRevision'](_0x4ae114){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x4ae114);}['getRevisions'](_0x4705cd){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4705cd||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0xbc5759=this['editor'],_0x1fdf79=_0x3f5003(_0xbc5759,p),_0x940aad=_0xbc5759['plugins']['get']('RevisionTracker'),_0x3e2218=_0xbc5759['plugins']['get']('Users')['users'];return _0x1fdf79['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x1fdf79['lazyRoots'],(_0x1fdf79['plugins']['push'](k,d,m,class extends _0x24aabd{static get['requires'](){return[d,'Users'];}['init'](){const _0x123115=this['editor']['plugins']['get']('Users');for(const _0x19854 of _0x3e2218)_0x19854['isAnonymous']||_0x123115['getUser'](_0x19854['id'])||_0x123115['addUser'](_0x19854);const _0x267ceb=_0x940aad['repository']['getRevisions']();let _0xb13620=null;const _0x487488=this['editor']['plugins']['get']('RevisionViewer');_0x487488['adapter']=_0x940aad['adapter'],_0x487488['bind']('isEnabled')['to'](_0x940aad),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0xbc5759,'isReadOnly',_0x48c847=>!_0x48c847);for(const _0x1fb415 of _0x267ceb){const _0x383b33=null===_0x1fb415['creator'];if(_0x383b33&&_0x1fb415['toVersion']===_0x1fb415['fromVersion'])continue;const _0x37fc85=_0x1fb415['toJSON']();_0x487488['addRevisionData'](_0x37fc85,(_0x53cc82,_0xa2d568,_0x3a5440)=>{if(_0x383b33){if(_0xb13620)_0xb13620['_update'](_0x53cc82,_0xa2d568);else{if(!_0xa2d568){const _0x4e9e4a=_0x3a5440['toJSON']();_0x4e9e4a['id']=_0x4dce4d(),_0x940aad['saveRevision'](_0x4e9e4a,_0x3a5440['toVersion'])['then'](_0x295998=>{_0xb13620=_0x295998;});}}}else _0x1fb415['_update'](_0x53cc82,_0xa2d568);});}}},g),_0x1fdf79);}['_enhanceShowRevisionViewerCallback'](){const _0x3cf8d4=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4aca0f=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xd67fa3=this['editor']['plugins']['get']('Autosave');await _0xd67fa3['save']();}else await _0x4aca0f['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x131d81=this['editor']['plugins']['get']('Dialog');_0x131d81['isOpen']&&_0x131d81['hide']();}const _0x3e0d66=this['_getRevisionViewerEditorConfig']();return _0x3cf8d4(_0x3e0d66)['then'](_0x1ef73c=>{return(this['_viewerEditor']=_0x1ef73c,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x1ef73c;})['catch'](_0x16e2ee=>(console['error'](_0x16e2ee),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x379bdb=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'](),_0x379bdb(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x18c973=this['editor']['plugins']['get']('Annotations');_0x18c973['refreshVisibility'](),_0x18c973['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3e7318){const _0x3ff5db=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4ce097=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x55675a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x55675a,_0x3e7318)['then'](_0x3797e2=>(_0x4ce097['style']['display']='block',_0x3ff5db['style']['display']='none',_0x3797e2));}['_closeRevisionViewer'](_0xa5822b){const _0x53de07=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x53de07['style']['display']='',_0xa5822b['destroy']();}async['_restoreRevision'](_0x127aeb){const _0x4e113b=this['editor'],_0x35eba0=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x232de0=_0x4e113b['plugins']['get']('RevisionTracker'),_0xc6cc98=_0x35eba0['repository']['getRevision'](_0x127aeb);let _0x5633e6,_0x157a61,_0x50aa91;try{_0x5633e6=await _0x35eba0['getRevisionData'](_0xc6cc98),_0x157a61=await _0x35eba0['getRevisionRootsAttributes'](_0xc6cc98);}catch(_0xdebb31){return void console['error'](_0xdebb31);}_0x4e113b['model']['change'](_0x463336=>{for(const _0x14d38e of Array['from'](_0x4e113b['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x463336['removeMarker'](_0x14d38e);}),_0x35eba0['isReady']=!0x1,_0x4e113b['model']['enqueueChange'](_0x23b062=>{_0x23b062['setSelection'](null),_0x23b062['removeSelectionAttribute'](_0x4e113b['model']['document']['selection']['getAttributeKeys']());const _0x1ae232=Object['keys'](_0x5633e6);for(const _0x1604a2 of _0x4e113b['model']['document']['roots'])'$graveyard'!=_0x1604a2['rootName']&&_0x1604a2['isAttached']()&&!_0x1ae232['includes'](_0x1604a2['rootName'])&&_0x23b062['detachRoot'](_0x1604a2);for(const _0x13a001 of _0x1ae232){let _0x56ca54=_0x4e113b['model']['document']['getRoot'](_0x13a001);_0x56ca54&&_0x56ca54['isAttached']()||(_0x56ca54=_0x23b062['addRoot'](_0x13a001));const _0x3b905a=_0x157a61[_0x13a001],_0x16d16e=Object['keys'](_0x3b905a),_0x148f41=_0x5633e6[_0x13a001];for(const _0x8b8e0a of _0x56ca54['getAttributeKeys']())_0x16d16e['includes'](_0x8b8e0a)||_0x23b062['removeAttribute'](_0x8b8e0a,_0x56ca54);for(const _0x584244 of _0x16d16e)_0x23b062['setAttribute'](_0x584244,_0x157a61[_0x13a001][_0x584244],_0x56ca54);_0x23b062['remove'](_0x23b062['createRangeIn'](_0x56ca54)),_0x23b062['insert'](_0x4e113b['data']['parse'](_0x148f41,_0x56ca54),_0x56ca54,0x0);}});const _0x41a15b=R(_0x4e113b['locale'],'Restored');if(_0xc6cc98['name'])_0x50aa91=-0x1==_0xc6cc98['name']['indexOf'](_0x41a15b)?_0x41a15b+':\x20'+_0xc6cc98['name']:_0xc6cc98['name'];else _0x50aa91=_0x41a15b+':\x20'+(_0xc6cc98['createdAt']['toLocaleDateString'](_0x4e113b['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xc6cc98['createdAt']['toLocaleTimeString'](_0x4e113b['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x232de0['saveRevision']({'name':_0x50aa91}),_0x35eba0['isReady']=!0x0,_0x4e113b['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,le as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
28
+ bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x36a666){super(_0x36a666),this['_revisionViewer']=_0x36a666['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x242ce9=this['_revisionsRepository']['_revisions'],_0x19e6c9=this['_createRevisionActions'](),_0xd3dd2=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x242ce9,_0x19e6c9,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',(_0x55fbb7,_0xe293f8)=>{_0xe293f8['revisionViews']['on']('add',(_0x268935,_0x3ad3e2)=>{_0x3ad3e2['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)),_0xd3dd2['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x335880=this['_revisionsRepository']['getRevision'](0x0);if(_0x335880){const _0x50cd42=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x335880['id']);this['_revisionViewer']['compare'](_0x335880,_0x50cd42);}}['_handleRevisionSelected'](_0x280eb7,_0x5015f2){const _0x56c265=this['_revisionsRepository']['getRevision'](_0x5015f2['id']),_0x59b756=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x56c265['id']);this['_revisionViewer']['compare'](_0x56c265,_0x59b756);}['_handleRevisionSetName'](_0x5259fa,_0x3d0684){this['_revisionsRepository']['getRevision'](_0x3d0684['id'])['setName'](_0x3d0684['name']);}['_handleDiffChange'](_0x485399,_0x5d0edd,_0x3f4941){const _0x5b6a7e=this['_revisionsRepository']['getRevisionsInDiff'](_0x3f4941);_0x5b6a7e['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x5b6a7e),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x5b6a7e[0x0]));}['_createRevisionActions'](){const _0xdec254=this['editor'],_0x4f752b=g['availableRevisionActions'],_0x5f02ac=_0xdec254['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x5f02ac['length'])return _0x5f02ac['map'](_0x285ed8=>{const _0xd5456d='string'==typeof _0x285ed8?Object['assign']({},_0x4f752b[_0x285ed8]):_0x285ed8;return _0xd5456d['action']=_0xd5456d['action']['bind'](this,_0xdec254),_0xd5456d['isVisible']&&(_0xd5456d['isVisible']=_0xd5456d['isVisible']['bind'](this,_0xdec254)),_0xd5456d;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x46cef3},_0x591069)=>{const _0x2d1fc8=_0x46cef3['get'](d),_0x2b4c4f=_0x2d1fc8['repository'];let _0x3973a4=_0x2d1fc8['diff']['newRevisionId'],_0x999a7b=_0x591069['id'];_0x2b4c4f['getIndex'](_0x3973a4)>_0x2b4c4f['getIndex'](_0x999a7b)&&([_0x3973a4,_0x999a7b]=[_0x999a7b,_0x3973a4]),_0x2d1fc8['compare'](_0x3973a4,_0x999a7b);},'isVisible':({plugins:_0x4e059d},_0xda26a3)=>{const _0x568705=_0x4e059d['get'](d);return!(_0x568705['repository']['getRevisionsInDiff'](_0x568705['diff'])['length']>0x2)&&!_0xda26a3['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x269001,{id:_0x538cc4})=>{_0x269001['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x538cc4);},'isVisible':({plugins:_0x2aba19},_0x2db087)=>!!_0x2aba19['get'](d)['repository']['getLaterVisibleRevision'](_0x2db087['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x64364c},{id:_0x4a6ead,revisionNameView:_0x5376e5})=>{const _0xee2e5e=_0x64364c['get'](d),_0x67337=_0xee2e5e['repository']['getEarlierVisibleRevision'](_0x4a6ead);_0xee2e5e['compare'](_0x4a6ead,_0x67337),_0x5376e5['focus'](),_0x5376e5['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x585d31,_0x15bf9d){super(_0x585d31),this['_view']=_0x15bf9d,this['_toolbarConfig']=ht(_0x585d31['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x5cbe88){const _0x458978=this['editor'],_0x1e3099=this['view'],_0x51b692=_0x458978['editing']['view'],_0x212f46=_0x1e3099['editable'],_0x246714=_0x51b692['document']['getRoot']();_0x212f46['name']=_0x246714['rootName'],_0x1e3099['render']();const _0x249bde=_0x212f46['element'];this['setEditableElement'](_0x212f46['name'],_0x249bde),_0x1e3099['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x51b692['attachDomRoot'](_0x249bde),this['_elementReplacer']['replace'](_0x5cbe88,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x7cd7d6=this['view'],_0x11d712=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x11d712['detachDomRoot'](_0x7cd7d6['editable']['name']),_0x7cd7d6['destroy']();}['_initToolbar'](){const _0x2ffaad=this['view'];_0x2ffaad['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2ffaad['stickyPanel']['limiterElement']=_0x2ffaad['element'],_0x2ffaad['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x16e392})=>_0x16e392),_0x2ffaad['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2ffaad['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x2330ab,_0x539657,_0x3ac212={}){super(_0x2330ab),this['stickyPanel']=new lt(_0x2330ab),this['toolbar']=new nt(_0x2330ab,{'shouldGroupWhenFull':_0x3ac212['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x2330ab,_0x539657);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
+ rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1d1d12,_0x466fc3){super(_0x466fc3),this['sourceElement']=_0x1d1d12,this['model']['document']['createRoot']();const _0x35806c=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x35806c);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x463eaf,_0x418f02){const _0x51a3f2=new this(_0x463eaf,_0x418f02);return await _0x51a3f2['initPlugins'](),await _0x51a3f2['ui']['init'](_0x463eaf),await _0x51a3f2['data']['init'](_0x51a3f2['config']['get']('initialData')||''),_0x51a3f2['fire']('ready'),_0x51a3f2;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x4e17c7{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xb630cc){function _0xbd908(_0x59d03a){return _0x59d03a['map'](_0x673f4e=>String['fromCharCode'](_0x673f4e))['join']('');}super(_0xb630cc),this['result']='end',_0xb630cc[_0xbd908([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xbd908([0x76,0x69,0x65,0x77])][_0xbd908([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xbd908([0x61,0x75,0x74,0x6f]),_0xb630cc[_0xbd908([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xbd908([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xbd908([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xbd908([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xbd908([0x6f,0x6b])});}}class H extends _0x4e17c7{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x3dd21d){if(super(_0x3dd21d),!this['editor']['config']['get']('revisionHistory'))throw new _0x147c38('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x21a5fe=>this['_showRevisionViewer']({..._0x21a5fe,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x449c6f=>this['_closeRevisionViewer'](_0x449c6f)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5c19c7=>this['_restoreRevision'](_0x5c19c7)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x219950){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x219950;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x5c3d37){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x5c3d37);}['getRevision'](_0x2fe797){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2fe797);}['getRevisions'](_0x4091d6){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4091d6||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x280bac=this['editor'],_0x3235ec=_0x26dfbd(_0x280bac,p),_0x2e3623=_0x280bac['plugins']['get']('RevisionTracker'),_0xb6ebd8=_0x280bac['plugins']['get']('Users')['users'];return _0x3235ec['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x3235ec['lazyRoots'],(_0x3235ec['plugins']['push'](k,d,m,class extends _0x4e17c7{static get['requires'](){return[d,'Users'];}['init'](){const _0x37cd09=this['editor']['plugins']['get']('Users');for(const _0x47288e of _0xb6ebd8)_0x47288e['isAnonymous']||_0x37cd09['getUser'](_0x47288e['id'])||_0x37cd09['addUser'](_0x47288e);const _0x3a5dfa=_0x2e3623['repository']['getRevisions']();let _0x174f14=null;const _0x2ca7dc=this['editor']['plugins']['get']('RevisionViewer');_0x2ca7dc['adapter']=_0x2e3623['adapter'],_0x2ca7dc['bind']('isEnabled')['to'](_0x2e3623),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x280bac,'isReadOnly',_0x21a1d0=>!_0x21a1d0);for(const _0x4b54e5 of _0x3a5dfa){const _0x1df2f2=null===_0x4b54e5['creator'];if(_0x1df2f2&&_0x4b54e5['toVersion']===_0x4b54e5['fromVersion'])continue;const _0x442599=_0x4b54e5['toJSON']();_0x2ca7dc['addRevisionData'](_0x442599,(_0x280a20,_0x27cf6f,_0x36b532)=>{if(_0x1df2f2){if(_0x174f14)_0x174f14['_update'](_0x280a20,_0x27cf6f);else{if(!_0x27cf6f){const _0x1a7067=_0x36b532['toJSON']();_0x1a7067['id']=_0x4c5b41(),_0x2e3623['saveRevision'](_0x1a7067,_0x36b532['toVersion'])['then'](_0x4eba32=>{_0x174f14=_0x4eba32;});}}}else _0x4b54e5['_update'](_0x280a20,_0x27cf6f);});}}},g),_0x3235ec);}['_enhanceShowRevisionViewerCallback'](){const _0x10df89=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x12daa8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4a9f4f=this['editor']['plugins']['get']('Autosave');await _0x4a9f4f['save']();}else await _0x12daa8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x2bacf9=this['editor']['plugins']['get']('Dialog');_0x2bacf9['isOpen']&&_0x2bacf9['hide']();}const _0x3ab92c=this['_getRevisionViewerEditorConfig']();return _0x10df89(_0x3ab92c)['then'](_0x5deae2=>{return(this['_viewerEditor']=_0x5deae2,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x5deae2;})['catch'](_0x283027=>(console['error'](_0x283027),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2c675b=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'](),_0x2c675b(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x38aa77=this['editor']['plugins']['get']('Annotations');_0x38aa77['refreshVisibility'](),_0x38aa77['refreshPositioning']();}})));}['_showRevisionViewer'](_0xb1583d){const _0x434633=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4af39b=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x15821e=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x15821e,_0xb1583d)['then'](_0x247b4c=>(_0x4af39b['style']['display']='block',_0x434633['style']['display']='none',_0x247b4c));}['_closeRevisionViewer'](_0x4e5c86){const _0x2484ae=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2484ae['style']['display']='',_0x4e5c86['destroy']();}async['_restoreRevision'](_0x47e57b){const _0xd2c0e9=this['editor'],_0x3cd5a5=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x409d0a=_0xd2c0e9['plugins']['get']('RevisionTracker'),_0x261bad=_0x3cd5a5['repository']['getRevision'](_0x47e57b);let _0x51fa7c,_0x4ad22d,_0x5f22cf;try{_0x51fa7c=await _0x3cd5a5['getRevisionData'](_0x261bad),_0x4ad22d=await _0x3cd5a5['getRevisionRootsAttributes'](_0x261bad);}catch(_0x58fb56){return void console['error'](_0x58fb56);}_0xd2c0e9['model']['change'](_0x5bacb2=>{for(const _0x214a91 of Array['from'](_0xd2c0e9['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x5bacb2['removeMarker'](_0x214a91);}),_0x3cd5a5['isReady']=!0x1,_0xd2c0e9['model']['enqueueChange'](_0x55ed52=>{_0x55ed52['setSelection'](null),_0x55ed52['removeSelectionAttribute'](_0xd2c0e9['model']['document']['selection']['getAttributeKeys']());const _0x3aea2d=Object['keys'](_0x51fa7c);for(const _0x4740c3 of _0xd2c0e9['model']['document']['roots'])'$graveyard'!=_0x4740c3['rootName']&&_0x4740c3['isAttached']()&&!_0x3aea2d['includes'](_0x4740c3['rootName'])&&_0x55ed52['detachRoot'](_0x4740c3);for(const _0x4eeb7d of _0x3aea2d){let _0x3c8681=_0xd2c0e9['model']['document']['getRoot'](_0x4eeb7d);_0x3c8681&&_0x3c8681['isAttached']()||(_0x3c8681=_0x55ed52['addRoot'](_0x4eeb7d));const _0x498d2d=_0x4ad22d[_0x4eeb7d],_0x246ade=Object['keys'](_0x498d2d),_0x1bc859=_0x51fa7c[_0x4eeb7d];for(const _0x380f75 of _0x3c8681['getAttributeKeys']())_0x246ade['includes'](_0x380f75)||_0x55ed52['removeAttribute'](_0x380f75,_0x3c8681);for(const _0x453d39 of _0x246ade)_0x55ed52['setAttribute'](_0x453d39,_0x4ad22d[_0x4eeb7d][_0x453d39],_0x3c8681);_0x55ed52['remove'](_0x55ed52['createRangeIn'](_0x3c8681)),_0x55ed52['insert'](_0xd2c0e9['data']['parse'](_0x1bc859,_0x3c8681),_0x3c8681,0x0);}});const _0x5dfe3e=R(_0xd2c0e9['locale'],'Restored');if(_0x261bad['name'])_0x5f22cf=-0x1==_0x261bad['name']['indexOf'](_0x5dfe3e)?_0x5dfe3e+':\x20'+_0x261bad['name']:_0x261bad['name'];else _0x5f22cf=_0x5dfe3e+':\x20'+(_0x261bad['createdAt']['toLocaleDateString'](_0xd2c0e9['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x261bad['createdAt']['toLocaleTimeString'](_0xd2c0e9['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x409d0a['saveRevision']({'name':_0x5f22cf}),_0x3cd5a5['isReady']=!0x0,_0xd2c0e9['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,de as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};