@ckeditor/ckeditor5-comments 47.6.0-alpha.8 → 47.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (194) hide show
  1. package/build/comments.js +1 -1
  2. package/dist/index.js +11 -11
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.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 +19 -19
  150. package/src/annotations/annotation.js +2 -2
  151. package/src/annotations/annotationcollection.js +1 -1
  152. package/src/annotations/annotations.js +1 -1
  153. package/src/annotations/annotationsuis.js +1 -1
  154. package/src/annotations/editorannotations.js +1 -1
  155. package/src/annotations/inlineannotations.js +1 -1
  156. package/src/annotations/narrowsidebar.js +1 -1
  157. package/src/annotations/sidebar.js +1 -1
  158. package/src/annotations/view/annotationcounterbuttonview.js +1 -1
  159. package/src/annotations/view/annotationview.js +1 -1
  160. package/src/annotations/view/sidebaritemview.js +2 -2
  161. package/src/annotations/view/sidebarview.js +2 -2
  162. package/src/annotations/widesidebar.js +1 -1
  163. package/src/comments/addcommentthreadcommand.js +1 -1
  164. package/src/comments/commentsarchive.js +1 -1
  165. package/src/comments/commentsarchiveui.js +1 -1
  166. package/src/comments/commentsediting.js +1 -1
  167. package/src/comments/commentsrepository.js +3 -3
  168. package/src/comments/commentsui.js +1 -1
  169. package/src/comments/integrations/clipboard.js +1 -1
  170. package/src/comments/integrations/commentsrestrictededitingmode.js +1 -1
  171. package/src/comments/integrations/importword.js +1 -1
  172. package/src/comments/integrations/showcommenthighlights.js +1 -1
  173. package/src/comments/ui/commenteditor/commenteditor.js +2 -2
  174. package/src/comments/ui/commenteditor/commenteditorui.js +1 -1
  175. package/src/comments/ui/commenteditor/commenteditoruiview.js +1 -1
  176. package/src/comments/ui/commentthreadcontroller.js +2 -2
  177. package/src/comments/ui/view/basecommentthreadview.js +1 -1
  178. package/src/comments/ui/view/basecommentview.js +1 -1
  179. package/src/comments/ui/view/collapsedcommentsview.js +1 -1
  180. package/src/comments/ui/view/commentcontentview.js +1 -1
  181. package/src/comments/ui/view/commentinputview.js +1 -1
  182. package/src/comments/ui/view/commentsarchiveview.js +1 -1
  183. package/src/comments/ui/view/commentslistview.js +1 -1
  184. package/src/comments/ui/view/commentthreadheadercontextview.js +1 -1
  185. package/src/comments/ui/view/commentthreadheaderview.js +1 -1
  186. package/src/comments/ui/view/commentthreadinputview.js +1 -1
  187. package/src/comments/ui/view/commentthreadview.js +2 -2
  188. package/src/comments/ui/view/commentview.js +2 -2
  189. package/src/comments.js +1 -1
  190. package/src/commentsonly.js +1 -1
  191. package/src/index.js +1 -1
  192. package/src/utils/common-translations.js +1 -1
  193. package/src/utils/createmutationobserver.js +1 -1
  194. package/src/utils/splitmarkername.js +1 -1
package/dist/index.js CHANGED
@@ -20,14 +20,14 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Editor as _0x442658,ContextPlugin as _0x3905cc,PendingActions as lt,Command as _0x4812bd,Plugin as _0x2525e1,Context as _0x5337ad}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x57a519,uid as _0x411bc5,KeystrokeHandler as jt,FocusTracker as _0x3ab247,diff as _0x4f2c45,Collection as _0x3a23ae,Rect as _0x1c0a3f,CKEditorError as _0x365e72,first as _0x4a1569,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x2a9e11,keyCodes as _0xb3a348}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x10d138,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x47bf33,trimHtml as ts,LateFocusDropdownButtonView as _0x27738d,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x527b7d}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0xd7f4fb}from'es-toolkit/compat';import{IconUndo as _0x1c916e,IconCheck as _0x2a5a8b,IconPencil as _0x34713b,IconRemoveComment as _0x5de0a6,IconThreeVerticalDots as _0x56dd0f,IconAddComment as _0x12547c,IconCommentsArchive as _0x5604ad}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as $t,InlineEditableUIView as Vt,EditorUI as Ut,View as kt,FocusCycler as _0xab0a02,ButtonView as _0x51cbda,ViewCollection as _0x189f83,createDropdown as _0x21bd8b,ListView as _0x566929,focusChildOnDropdownOpen as _0x38f4a9,ListItemView as _0x1d3ca4,MenuBarMenuListItemButtonView as _0x18ac0a,BodyCollection as _0x5b6aa6,BalloonPanelView as _0x239d17,ContextualBalloon as _0xd457bc,Dialog as _0x62a5ed,DialogViewPosition as _0x2aabed}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as St,enableViewPlaceholder as Ft,MouseObserver as _0x3b27aa}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as qt,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as zt,ShiftEnter as Bt}from'@ckeditor/ckeditor5-enter/dist/index.js';import{SelectAll as Gt}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as Jt}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as Kt}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as Lt}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x1a8e77}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x8e165b}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
- _0x57a519(){['model'];['view'];constructor(_0x4554a4,_0x4e446d){super(),this['model']=_0x4554a4,this['model']['_isAttached']=!0x0,this['view']=_0x4e446d,this['listenTo'](_0x4e446d,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x4e446d,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x4e446d,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x4e446d,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x4e446d,'addComment',(_0x18fee9,_0xd67f11)=>this['addComment'](_0xd67f11)),this['listenTo'](_0x4e446d,'updateComment',(_0x1d2cf3,_0x52c2ae,_0x4d7aab)=>this['updateComment'](_0x52c2ae,_0x4d7aab)),this['listenTo'](_0x4e446d,'removeComment',(_0x208033,_0x6caee)=>this['removeComment'](_0x6caee));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x57cebf){this['model']['addComment']({'content':_0x57cebf,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x54f617,_0xfe4a7){this['model']['getComment'](_0x54f617)['update']({'content':_0xfe4a7});}['removeComment'](_0x1ed73e){this['model']['getComment'](_0x1ed73e)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x4baed0,_0x1db34d,_0x41e8df){const t=_0x4baed0['t'];switch(_0x1db34d){case'PENDING_ACTION_COMMENT_THREAD':return t({'string':'Unsaved\x20change\x20in\x20comment\x20thread.','id':'PENDING_ACTION_COMMENT_THREAD'});case'Comment':return t('Comment');case'Reply...':return t('Reply...');case'Reply\x20to\x20reopen\x20discussion...':return t('Reply\x20to\x20reopen\x20discussion...');case'Write\x20a\x20comment...':return t('Write\x20a\x20comment...');case'Comment\x20was\x20made\x20on\x20an\x20element':return t('Comment\x20was\x20made\x20on\x20an\x20element');case'Comment\x20editor':return t('Comment\x20editor');case'Delete\x20comment\x20thread?':return t('Delete\x20comment\x20thread?');case'Delete\x20comment?':return t('Delete\x20comment?');case'Marked\x20as\x20resolved':return t('Marked\x20as\x20resolved');case'Show\x20more\x20items':return t('Show\x20more\x20items');case'Cancel':return t('Cancel');case'Edit':return t('Edit');case'Resolve':return t('Resolve');case'Reopen':return t('Reopen');case'Remove':return t('Remove');case'Reply':return t('Reply');case'Save':return t('Save');case'Annotations\x20sidebar':return t('Annotations\x20sidebar');case'Annotations\x20list':return t('Annotations\x20list');case'Thread\x20comments':return t('Thread\x20comments');case'THREAD_CONTEXT_LABEL':return t({'string':'Thread\x20context:\x20%0','id':'THREAD_CONTEXT_LABEL'},_0x41e8df);case'COMMENT_THREAD_LABEL':return t({'string':'Comment\x20thread\x20by\x20%1.\x20%1\x20reply.','plural':'Comment\x20thread\x20by\x20%1.\x20%0\x20replies.','id':'COMMENT_THREAD_LABEL'},_0x41e8df);case'COMMENT_THREAD_DESCRIPTION':return t({'string':'Press\x20Enter\x20for\x20more\x20options.\x20Press\x20Escape\x20to\x20exit.','id':'COMMENT_THREAD_DESCRIPTION'});case'COMMENT_ARIA_LABEL':return t({'string':'Comment\x20by\x20%0.\x20Created\x20on\x20%1.\x20%2.\x20%3','id':'COMMENT_ARIA_LABEL'},_0x41e8df);case'LEAVE_COMMENT_ANNOUNCEMENT':return t({'string':'Leaving\x20a\x20content\x20with\x20comments.','id':'LEAVE_COMMENT_ANNOUNCEMENT'});case'ENTER_COMMENT_ANNOUNCEMENT':return t({'string':'Entering\x20a\x20content\x20with\x20comments.\x20Press\x20%0\x20to\x20go\x20to\x20the\x20discussion.','id':'ENTER_COMMENT_ANNOUNCEMENT'},_0x41e8df);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x41e8df);case'TOO_LONG_COMMENT_ALERT':return t({'string':'Comment\x20content\x20is\x20too\x20long.\x20Your\x20comment\x20has\x20%0\x20characters\x20but\x20the\x20limit\x20is\x20%1\x20characters.','id':'TOO_LONG_COMMENT_ALERT'},_0x41e8df);case'EXTERNAL_COMMENT':return t({'string':'This\x20comment\x20comes\x20from\x20an\x20external\x20source.','id':'EXTERNAL_COMMENT'});case'EXTERNAL_IMPORT_WORD_COMMENT':return t({'string':'This\x20comment\x20comes\x20from\x20an\x20imported\x20Word\x20file.','id':'EXTERNAL_IMPORT_WORD_COMMENT'});case'EXTERNAL_AVATAR':return t({'string':'Displayed\x20author\x20name\x20comes\x20from\x20external\x20source\x20(added\x20by\x20%0)','id':'EXTERNAL_AVATAR'},_0x41e8df);case'EXTERNAL_IMPORT_WORD_AVATAR':return t({'string':'Displayed\x20author\x20name\x20comes\x20from\x20a\x20Word\x20document\x20imported\x20by\x20%0','id':'EXTERNAL_IMPORT_WORD_AVATAR'},_0x41e8df);case'COMMENTS_ARCHIVE':return t({'string':'Comments\x20archive','id':'COMMENTS_ARCHIVE'});case'EMPTY_COMMENTS_ARCHIVE':return t({'string':'There\x20are\x20no\x20archived\x20comment\x20threads.','id':'EMPTY_COMMENTS_ARCHIVE'});case'COMMENTS_ARCHIVE_LIST_LABEL':return t({'string':'List\x20of\x20comments','id':'COMMENTS_ARCHIVE_LIST_LABEL'});case'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP':return t({'string':'Keystrokes\x20for\x20interacting\x20with\x20annotation\x20threads\x20(e.g.\x20comments,\x20track\x20changes\x20suggestions)','id':'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'});case'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO':return t({'string':'Move\x20focus\x20to\x20the\x20thread\x20when\x20the\x20selection\x20is\x20anchored\x20in\x20its\x20marker','id':'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'});case'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT':return t({'string':'Exit\x20the\x20annotation\x20and\x20move\x20focus\x20back\x20to\x20the\x20edited\x20content','id':'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER':return t({'string':'Browse\x20the\x20focused\x20annotation\x20thread\x20or\x20thread\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'});case'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS':return t({'string':'Move\x20across\x20internals\x20of\x20the\x20annotation\x20thread','id':'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'});case'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT':return t({'string':'Submit\x20the\x20reply\x20while\x20writing\x20a\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS':return t({'string':'Move\x20to\x20the\x20previous\x20or\x20next\x20thread\x20in\x20the\x20annotations\x20sidebar\x20or\x20comments\x20archive','id':'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'});default:return'';}}class Rt extends $t{['main'];['editable'];constructor(_0x30ce2b,_0x2ebf0b){super(_0x30ce2b);const _0x4c2d73=_0x411bc5();this['main']=this['createCollection'](),this['editable']=new Vt(_0x30ce2b,_0x2ebf0b,void 0x0,{'label':()=>N(_0x30ce2b,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x30ce2b['uiLanguageDirection'],'lang':_0x30ce2b['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x4c2d73},'children':[{'tag':'div','attributes':{'class':'ck-editor__main','role':'presentation'},'children':this['main']}]});}['render'](){super['render'](),this['main']['add'](this['editable']);}['focus'](){this['editable']['element']['focus']();}}class Et extends Ut{['view'];constructor(_0x41f56f){super(_0x41f56f),this['view']=new Rt(_0x41f56f['locale'],_0x41f56f['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x4ec4c7=this['editor']['editing']['view'],_0x54945a=this['view']['editable'],_0x5750c0=_0x4ec4c7['document']['getRoot']();_0x54945a['name']=_0x5750c0['rootName'],this['view']['render']();const _0x24f351=_0x54945a['element'];this['setEditableElement'](_0x54945a['name'],_0x24f351),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x4ec4c7['attachDomRoot'](_0x24f351),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[qt,zt,Bt,Gt,Jt,Kt,Lt];class hs extends/* #__PURE__ -- @preserve */
25
- _0x57a519(_0x442658){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
- ((()=>Qt)());constructor(_0x196c1c={}){function _0x56e4f7(_0x3aa97d){return _0x3aa97d['map'](_0x231550=>String['fromCharCode'](_0x231550))['join']('');}(_0x196c1c=Object['assign']({},_0x196c1c))['plugins']||(_0x196c1c['plugins']=hs['defaultPlugins']),super(_0x196c1c),this['ui']=new Et(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x56e4f7([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x56e4f7([0x76,0x69,0x65,0x77])][_0x56e4f7([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x56e4f7([0x61,0x75,0x74,0x6f]),this[_0x56e4f7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x56e4f7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x56e4f7([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x56e4f7([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x56e4f7([0x6f,0x6b])});}['create'](){const _0xd255a9=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0xd255a9))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x185e6d=>{const _0x703e77=this['model']['document']['getRoot'](),_0x1c2b37=_0x703e77&&_0x703e77['getChild'](_0x703e77['childCount']-0x1);_0x185e6d['setSelection'](_0x1c2b37,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x58262e=this['editing']['view'],_0x315b9a=_0x58262e['document']['getRoot'](),_0x293986=_0x315b9a['getChild'](0x0);_0x315b9a['childCount']>0x1||!_0x293986||'p'!=_0x293986['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x58262e,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x293986['placeholder']=this['placeholder']),Ft({'view':_0x58262e,'element':_0x293986,'keepOnFocus':!0x0}),this['placeholderElement']=_0x293986);}}class es extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x323f22,_0x3faee6={}){super(_0x323f22),this['editor']=null,this['_editorConfig']=_0x3faee6,this['set']('value',_0x3faee6['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x323f22,'Reply...')),this['set']('submitLabel',N(_0x323f22,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x3ab247(),this['focusCycler']=new _0xab0a02({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-comment__input-wrapper']},'children':[{'tag':'div','attributes':{'class':['ck-comment__input-actions',this['bindTemplate']['if']('showButtons','ck-comment__input-actions--active')]},'children':[this['submitButtonView'],this['cancelButtonView']]}]}),this['keystrokes']['set']('Esc',(_0x5545d9,_0x4b1d21)=>{this['cancelButtonView']['fire']('execute'),_0x4b1d21();}),this['keystrokes']['set']('Ctrl+Enter',(_0x364656,_0x5df3bc)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x5df3bc());}),this['on']('submit',(_0x199d02,_0x5dd52f)=>{_0x5dd52f['length']>0xfde8?(alert(N(_0x323f22,'TOO_LONG_COMMENT_ALERT',[_0x5dd52f['length'],0xfde8])),_0x199d02['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new hs(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x46a02f=this['editor'];this['element']['insertBefore'](_0x46a02f['ui']['element'],this['element']['firstChild']),_0x46a02f['model']['document']['on']('change',()=>this['value']=_0x46a02f['getData']()),_0x46a02f['bind']('placeholder')['to'](this),this['focusables']['add'](_0x46a02f['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x134029){-0x1===_0x134029?(this['focusCycler']['focusFirst'](),this['focusCycler']['focusLast']()):this['focusCycler']['focusFirst']();}async['destroy'](){this['_isDestroyed']||(this['_isDestroyed']=!0x0,this['editor']&&(await this['_editorCreationPromise'],await this['editor']['destroy'](),this['fire']('editorDestroyed',this['editor'])),await super['destroy']());}['_createSubmitButton'](){const {locale:_0x4b8c79}=this,_0x420935=new _0x51cbda(_0x4b8c79);return _0x420935['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x420935['withText']=!0x0,_0x420935['bind']('label')['to'](this,'submitLabel'),_0x420935['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x420935['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x5a2735,_0x2ae349)=>!_0x2ae349&&!!_0x5a2735['trim']()),_0x420935;}['_createCancelButton'](){const {locale:_0x2a39a6}=this,_0x570967=new _0x51cbda(_0x2a39a6);return _0x570967['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x570967['label']=N(_0x2a39a6,'Cancel'),_0x570967['withText']=!0x0,_0x570967['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x570967;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x55bdb4=>{this['focusTracker']['add'](_0x55bdb4['element']);}),this['focusables']['on']('change',(_0x214ae2,_0x57f037)=>{for(const _0x4755e2 of Array['from'](_0x57f037['added'])['reverse']())this['focusTracker']['add'](_0x4755e2['element']);});}}class ie extends kt{constructor(_0x264ac1,_0x32bcb9,_0x515fe2){super(_0x264ac1),this['commentInputView']=new es(_0x264ac1,_0x515fe2),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x4d8b2d,_0x55dec7)=>_0x4d8b2d||!!_0x55dec7),this['set']('showInput',!0x1),this['on']('change:showInput',()=>{this['showInput']&&!this['commentInputView']['editor']&&this['commentInputView']['createEditor']();}),this['commentInputView']['delegate']('editorReady')['to'](this),this['commentInputView']['delegate']('editorDestroyed')['to'](this),this['userView']=new _0x10d138(_0x264ac1,_0x32bcb9),this['userView']['extendTemplate']({'attributes':{'class':'ck-thread__user','aria-hidden':!0x0}}),this['commentInputView']['extendTemplate']({'attributes':{'class':'ck-thread__input'}}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-comment__input-container',this['bindTemplate']['if']('showInput','ck-comment__input-container--active')]},'children':[this['userView'],this['commentInputView']]});}['render'](){super['render'](),this['_focusOnNonInteractiveMouseDown']();}['destroy'](){return this['commentInputView']['destroy']()['then'](()=>super['destroy']());}['focus'](_0x4edbc9){this['commentInputView']['focus'](_0x4edbc9);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x48b337,_0x503218)=>{const {submitButtonView:_0x5afe4c,cancelButtonView:_0x456dbf,editor:_0xe5e0f3}=this['commentInputView'];[_0x5afe4c['element'],_0x456dbf['element'],_0xe5e0f3?_0xe5e0f3['editing']['view']['getDomRoot']():null]['filter'](_0xcb0681=>_0xcb0681)['some'](_0x4cd401=>_0x4cd401['contains'](_0x503218['target']))||(this['focus'](),_0x503218['preventDefault']());});}}class rs extends kt{constructor(_0x38e60f){super(_0x38e60f);const _0x342281=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x342281['to']('count',_0x15c7c1=>N(_0x38e60f,'NUMBER_OF_COMMENTS',_0x15c7c1))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x41c2ee,_0x4fbe0c,_0xb4c8bb){super(_0x41c2ee);const _0x5f02fe=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x4fbe0c['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x4fbe0c,this['_config']=_0xb4c8bb,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x3ab247(),this['keystrokes']=new jt(),this['focusCycler']=new _0xab0a02({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x49e750=>this['commentViews']['map'](_0x19fd59=>_0x19fd59['element'])['includes'](_0x49e750['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x41c2ee),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x3d00b7=>_0x3d00b7-this['_config']['maxCommentsWhenCollapsed']);for(const _0x484a48 of _0x4fbe0c['comments'])this['_handleNewCommentModel'](_0x484a48);this['_handleInfoComment'](),this['listenTo'](_0x4fbe0c['comments'],'add',(_0x3af2fe,_0x5a79c3)=>{const _0x59ed85=this['_calculatePosition'](_0x5a79c3);this['length']++,this['_handleNewCommentModel'](_0x5a79c3,_0x59ed85),this['refreshVisibleViews']();}),this['listenTo'](_0x4fbe0c['comments'],'remove',(_0x146833,_0x3fb0a7)=>{this['length']--,this['_handleRemoveCommentModel'](_0x3fb0a7),this['refreshVisibleViews']();}),this['listenTo'](_0x4fbe0c,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x4fbe0c,'change:isResolved',()=>this['_handleInfoComment']()),this['on']('change:isActive',()=>this['refreshVisibleViews']()),this['on']('change:hasDirtyComment',()=>this['refreshVisibleViews']()),this['setTemplate']({'tag':'ul','attributes':{'class':['ck-thread__comments',_0x5f02fe['if']('length','ck-hidden',_0x45e146=>!_0x45e146)],'aria-label':N(_0x41c2ee,'Thread\x20comments')},'children':this['visibleViews']});}get['_shouldCollapse'](){return this['_model']['weight']>this['_config']['maxThreadTotalWeight']&&!this['isActive']&&!this['hasDirtyComment'];}['render'](){super['render'](),this['refreshVisibleViews'](),this['_setupKeyboardNavigation']();}['focus'](_0x52ddc6){-0x1===_0x52ddc6?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x2e1b72 of this['commentViews'])_0x2e1b72['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x1e13fe,_0x2959cb){const _0x1f397a=new this['_config']['CommentView'](this['locale'],_0x1e13fe,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x1f397a['viewUid']=_0x1e13fe['id'],_0x1f397a['delegate']('removeComment')['to'](this),_0x1f397a['delegate']('updateComment')['to'](this),_0x1f397a['delegate']('resolveCommentThread')['to'](this),_0x1f397a['delegate']('editorReady')['to'](this),_0x1f397a['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x1f397a,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x1f397a,_0x2959cb);}['_calculatePosition'](_0x55c580){const _0x28d687=this['_model']['_findOptimalIndex'](_0x55c580);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x55c580['authoredAt']?_0x28d687-0x1:_0x28d687:_0x28d687-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x3875f3={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':N(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x3875f3,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x3875f3));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x25bca7){const _0x314ced=this['commentViews']['remove'](_0x25bca7['id']);this['stopListening'](_0x314ced),_0x314ced['isEditMode']&&this['_updateHasDirtyComment'](),_0x314ced['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x76f880=>_0x76f880['isEditMode']);}['_rearrangeCollapse'](){const _0x3b6a19=function(_0x5a46cb){const _0xcdcd7c=new _0x3a23ae();for(const _0x4fa3c0 of _0x5a46cb)_0xcdcd7c['add'](_0x4fa3c0);return _0xcdcd7c;}(this['commentViews']),_0x56e469=this['_collapsedCommentsView']['count'];for(let _0x4479a2=0x1;_0x4479a2<=_0x56e469;_0x4479a2++)_0x3b6a19['remove'](0x1);for(const _0x4fcec4 of _0x3b6a19)_0x4fcec4['collapse']();_0x56e469>0x0&&_0x3b6a19['add'](this['_collapsedCommentsView'],0x1),ns(_0x4f2c45(Array['from'](this['visibleViews']),Array['from'](_0x3b6a19)),this['visibleViews'],_0x3b6a19);}['_rearrangeExpand'](){ns(_0x4f2c45(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x3c38f7 of this['visibleViews'])_0x3c38f7['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x593dbf=>{this['focusTracker']['add'](_0x593dbf['element']),this['keystrokes']['listenTo'](_0x593dbf['element']);}),this['commentViews']['on']('change',(_0x3687c8,_0x4c9286)=>{for(const _0x16acf6 of _0x4c9286['removed'])this['focusTracker']['remove'](_0x16acf6['element']),this['keystrokes']['stopListening'](_0x16acf6['element']);for(const _0x3318b0 of Array['from'](_0x4c9286['added'])['reverse']())this['focusTracker']['add'](_0x3318b0['element']),this['keystrokes']['listenTo'](_0x3318b0['element']);});}}function ns(_0x5b0eb5,_0x7cab1b,_0x5010d8){let _0xc94dea=0x0;for(const _0x1d4459 of _0x5b0eb5)switch(_0x1d4459){case'insert':_0x7cab1b['add'](_0x5010d8['get'](_0xc94dea),_0xc94dea),_0xc94dea++;break;case'delete':_0x7cab1b['remove'](_0xc94dea);break;case'equal':_0xc94dea++;}}class oe extends kt{constructor(_0x1fabfc){super(_0x1fabfc);const _0x579ba7=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x579ba7['to']('contextValue',_0x282b8b=>N(_0x1fabfc,'THREAD_CONTEXT_LABEL',_0x282b8b)),'tabindex':-0x1},'children':[{'text':_0x579ba7['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x4bf97f,_0x1f6fa1){super(_0x4bf97f);const _0x102350=this['bindTemplate'];this['_model']=_0x1f6fa1,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x3ab247(),this['keystrokes']=new jt(),this['focusCycler']=new _0xab0a02({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x5e61ef=>!!_0x5e61ef),this['bind']('contextValue')['to'](this['_model'],'context',_0x4a293f=>_0x4a293f&&_0x4a293f['value']?this['_trimContextValue'](_0x4a293f['value']):N(this['locale'],'Comment\x20was\x20made\x20on\x20an\x20element')),this['setTemplate']({'tag':'div','attributes':{'class':['ck-thread__header']},'children':[{'tag':'div','attributes':{'class':['ck-context-wrapper']},'children':[{'tag':'div','attributes':{'class':['ck-context',_0x102350['if']('hasContext','ck-context--quotes')]},'children':[this['contextView']]}]},{'tag':'div','attributes':{'class':['ck-annotation__actions']},'children':[this['reopenButtonView']]}]});}['render'](){super['render'](),this['_attachContextActions'](),this['_setupKeyboardNavigation']();}['focus'](){this['focusCycler']['focusFirst']();}['_createReopenButton'](){const _0x3d2dc7=new _0x51cbda(this['locale']);return _0x3d2dc7['label']=N(this['locale'],'Reopen'),_0x3d2dc7['tooltip']=N(this['locale'],'Reopen'),_0x3d2dc7['icon']=_0x1c916e,_0x3d2dc7['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0xa0f039=>!_0xa0f039),_0x3d2dc7['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x2b8c5f,_0x3e2b88)=>_0x2b8c5f&&_0x3e2b88),_0x3d2dc7['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x3d2dc7;}['_trimContextValue'](_0x575e03){if(_0x575e03['length']<0x96)return _0x575e03;const _0x10c1a6=_0x575e03['lastIndexOf']('\x20',0x93);return _0x575e03['substring'](0x0,_0x10c1a6>-0x1?_0x10c1a6:0x93)+'...';}['_attachContextActions'](){const _0x41a753=this['element']['querySelector']('.ck-context'),_0x1184e3=_0x41a753['querySelector']('.ck-context__value');this['listenTo'](_0x41a753,'mouseenter',()=>{_0x1184e3['offsetWidth']<_0x1184e3['scrollWidth']&&_0x41a753['classList']['add']('overlay');}),this['listenTo'](_0x41a753,'mouseleave',()=>{_0x41a753['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x1d89b7 of this['focusables'])this['focusTracker']['add'](_0x1d89b7['element']),this['keystrokes']['listenTo'](_0x1d89b7['element']);}['_createContextView'](){const _0x221d35=new oe(this['locale']);return _0x221d35['bind']('contextValue')['to'](this),_0x221d35;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x510334,_0x14fb44,_0x3551b3,_0x68f400){super(_0x510334),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x14fb44,this['_localUser']=_0x3551b3,this['_config']=_0x68f400,this['commentThreadHeaderView']=new Xt(_0x510334,_0x14fb44),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x510334,N(_0x510334,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x510334,_0x14fb44,Object['assign']({'CommentView':this['_config']['CommentView']},_0x68f400)),this['commentsListView']['delegate']('removeComment')['to'](this),this['commentsListView']['delegate']('updateComment')['to'](this),this['commentsListView']['delegate']('resolveCommentThread')['to'](this),this['commentsListView']['delegate']('editorReady')['to'](this),this['commentsListView']['delegate']('editorDestroyed')['to'](this),this['commentsListView']['bind']('isActive')['to'](this),this['listenTo'](this,'resolveCommentThread',()=>{this['focus']();}),this['set']('length',this['commentsListView']['length']),this['bind']('length')['to'](this['commentsListView'],'length'),this['commentThreadInputView']=this['_createCommentThreadInputView'](),this['commentThreadInputView']['delegate']('editorReady')['to'](this),this['commentThreadInputView']['delegate']('editorDestroyed')['to'](this),this['on']('removeComment',()=>this['focus']()),this['bind']('isDirty')['to'](this['commentsListView'],'hasDirtyComment',this['commentThreadInputView']['commentInputView'],'value',(_0x299965,_0x5376de)=>_0x299965||!!_0x5376de),this['bind']('isUnlinked')['to'](_0x14fb44,'unlinkedAt',_0x17c209=>!!_0x17c209),this['bind']('ariaLabel')['to'](this,'length',_0xa6da0f=>{const _0x4ebc57=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0xa6da0f,_0x4ebc57]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x3ab247(),this['keystrokes']=new jt(),this['focusCycler']=new _0xab0a02({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0xb2a89e=>_0xb2a89e['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),Zt(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x3da61a=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x2ed0a9=_0x3da61a['commentInputView'];return _0x3da61a['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x2ed0a9,'value',(_0x4fc90f,_0x1a78e4,_0x33040b,_0x414a27,_0x3a3abd)=>!!_0x3a3abd||!!_0x414a27&&_0x33040b&&!_0x1a78e4||_0x4fc90f&&_0x33040b&&!_0x1a78e4),_0x2ed0a9['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x5990f4,_0x205aef,_0x2e6a24)=>{let _0x35c2b1;return _0x35c2b1=_0x2e6a24&&_0x205aef?'Reply\x20to\x20reopen\x20discussion...':_0x5990f4?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x35c2b1);}),_0x2ed0a9['bind']('submitLabel')['to'](this,'length',_0x446602=>N(this['locale'],_0x446602?'Reply':'Comment')),_0x2ed0a9['on']('submit',(_0x3d5b51,_0x1982a6)=>{this['fire']('addComment',_0x1982a6),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x2ed0a9['on']('cancel',()=>{this['focus']();}),_0x2ed0a9['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x2ed0a9['on']('cancel',_0x2a11a2=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x2a11a2['stop']());}),this['on']('change:isActive',(_0x410bc1,_0x5b74ee,_0x45f303)=>{_0x45f303||this['length']||_0x2ed0a9['value']||this['fire']('removeCommentThread');}),_0x3da61a;}}class gt extends/* #__PURE__ -- @preserve */
27
- ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x22fd22,_0x54e982,_0x933bda,_0x7fba85){super(_0x22fd22,_0x54e982,_0x933bda,_0x7fba85),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x22fd22,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x4d74f3,_0x1ddbe2,_0x10b035)=>{_0x10b035||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x4bfc50,_0x17eef9,_0x3cd710)=>{_0x3cd710&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x3ddb60=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x3ddb60['if']('isActive','ck-thread--active'),_0x3ddb60['if']('isUnlinked','ck-thread--unlinked'),_0x3ddb60['to']('actionIndicator',_0x501c97=>_0x501c97?'ck-thread--'+_0x501c97:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x3ddb60['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id']},'children':[{'tag':'div','attributes':{'class':'ck-thread__container'},'children':this['commentThreadChildren']}]};}['render'](){super['render'](),this['containerElement']=this['element']['querySelector']('.ck-thread__container'),this['_model']['on']('change:archivedAt',()=>{this['_updateArchivedThreadHeader']();}),this['_updateArchivedThreadHeader']();}['_cancelAllConfirms'](){this['cancelConfirm']();for(const _0x453da2 of this['commentsListView']['commentViews'])_0x453da2['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x5dea5d}=this,_0x2ead76=this['commentsListView']['commentViews']['get'](0x0);_0x2ead76===this['_boundFirstCommentView']||_0x2ead76['isSystemComment']||(this['_boundFirstCommentView']=_0x2ead76,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x2ead76,'actionIndicator',_0x1c04cc=>'remove'===_0x1c04cc?'remove':null),_0x2ead76['placeholder']=N(_0x5dea5d,'Write\x20a\x20comment...'),_0x2ead76['removeButton']['on']('execute',_0x5bcbe9=>{_0x5bcbe9['stop'](),this['showConfirm'](N(_0x5dea5d,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x2ead76['focus']();}),_0x2ead76['actionBar']['add'](this['resolveButton'],0x0),_0x2ead76['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x5861f8=new _0x47bf33(this['locale']);return _0x5861f8['label']=N(this['locale'],'Resolve'),_0x5861f8['tooltip']=N(this['locale'],'Resolve'),_0x5861f8['icon']=_0x2a5a8b,_0x5861f8['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x5861f8['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0xfb2ae6=>!_0xfb2ae6),_0x5861f8['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x309541,_0x5a55e8)=>_0x309541&&!_0x5a55e8),_0x5861f8['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x5861f8;}['_updateArchivedThreadHeader'](){this['_model']['archivedAt']?this['commentThreadChildren']['has'](this['commentThreadHeaderView'])||(this['commentThreadChildren']['add'](this['commentThreadHeaderView'],0x0),this['focusables']['add'](this['commentThreadHeaderView'],0x0)):this['commentThreadChildren']['has'](this['commentThreadHeaderView'])&&(this['commentThreadChildren']['remove'](this['commentThreadHeaderView']),this['focusables']['remove'](this['commentThreadHeaderView']));}}class is extends kt{constructor(_0xa4ce33){super(_0xa4ce33),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x74be26,_0x49e892,_0x273f5d)=>{this['element']['innerHTML']=_0x273f5d;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x4c2ff6,_0x2e2e6e,_0x5c1ffd){super(_0x4c2ff6),this['_model']=_0x2e2e6e,this['_config']=_0x5c1ffd,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x2e2e6e,'content',_0x2e2e6e,'authoredAt',(_0x3b09ba,_0x38293e)=>N(_0x4c2ff6,'COMMENT_ARIA_LABEL',[_0x2e2e6e['author']['name'],_0x5c1ffd['formatDateTime'](_0x38293e),new DOMParser()['parseFromString'](_0x3b09ba,'text/html')['body']['textContent'],_0x2e2e6e['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x4c2ff6,N(_0x4c2ff6,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x189f83(),this['focusTracker']=new _0x3ab247(),this['keystrokes']=new jt(),this['focusCycler']=new _0xab0a02({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0xfe546a=>_0xfe546a['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['expand'](){this['isCollapsed']=!0x1;}['collapse'](){this['isEditMode']||(this['isCollapsed']=!0x0);}['focus'](){this['element']['focus']();}['render'](){super['render'](),this['_setupKeyboardNavigation']();}async['destroy'](){await this['visibleView']['get'](0x0)['destroy'](),super['destroy']();}['switchToEditMode'](){this['isEditMode']||(this['isEditMode']=!0x0,this['visibleView']['remove'](0x0)['destroy'](),this['visibleView']['add'](this['_createCommentInputView']()));}['switchToDisplayMode'](){this['isEditMode']&&(this['isEditMode']=!0x1,this['visibleView']['remove'](0x0)['destroy'](),this['visibleView']['add'](this['_createCommentContentView']()));}['getExternalCommentNote'](){return'importWord'===this['_model']['attributes']['@external']['source']?N(this['locale'],'EXTERNAL_IMPORT_WORD_COMMENT'):N(this['locale'],'EXTERNAL_COMMENT');}['getUserViewNotificationText'](){return this['_model']['isExternal']?'importWord'===this['_model']['attributes']['@external']['source']?N(this['locale'],'EXTERNAL_IMPORT_WORD_AVATAR',this['_model']['creator']['name']):N(this['locale'],'EXTERNAL_AVATAR',this['_model']['creator']['name']):null;}['_createCommentContentView'](){const _0x12c476=new is(this['locale']);return _0x12c476['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x58e4b0,_0x4d01b0)=>_0x4d01b0?ts(_0x58e4b0,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x58e4b0),_0x12c476;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x1ddcef=new es(this['locale'],this['_config']['editorConfig']);return _0x1ddcef['value']=this['_model']['content'],_0x1ddcef['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x1ddcef['submitLabel']=N(this['locale'],'Save'),_0x1ddcef['on']('submit',(_0xaa35bc,_0x5e3a32)=>{this['fire']('updateComment',this['_model']['id'],_0x5e3a32),this['switchToDisplayMode'](),this['focus']();}),_0x1ddcef['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x1ddcef['once']('editorReady',()=>{_0x1ddcef['focus']();}),_0x1ddcef['createEditor'](),_0x1ddcef['delegate']('editorReady')['to'](this),_0x1ddcef['delegate']('editorDestroyed')['to'](this),_0x1ddcef;}['_setupKeyboardNavigation'](){const _0x57bed8=this['element'];this['keystrokes']['listenTo'](_0x57bed8);for(const _0x3fcb21 of this['focusables'])this['focusTracker']['add'](_0x3fcb21['element']),this['keystrokes']['listenTo'](_0x3fcb21['element']);this['focusables']['on']('change',(_0x565140,_0x5175ba)=>{for(const _0x1e2e68 of _0x5175ba['removed'])this['focusTracker']['remove'](_0x1e2e68['element']),this['keystrokes']['stopListening'](_0x1e2e68['element']);for(const _0x4ddd38 of _0x5175ba['added'])this['focusTracker']['add'](_0x4ddd38['element']),this['keystrokes']['listenTo'](_0x4ddd38['element']);}),this['keystrokes']['set']('enter',(_0x13470a,_0x43fdd0)=>{_0x57bed8===_0x13470a['target']&&(this['focusCycler']['focusFirst'](),_0x43fdd0());}),this['keystrokes']['set']('esc',(_0x62349e,_0x19973e)=>{_0x57bed8!==_0x62349e['target']&&(this['focus'](),_0x19973e());});}}class Tt extends/* #__PURE__ -- @preserve */
28
- ti(di){['actionBar'];['userView'];constructor(_0x4e3f42,_0x4c70ed,_0x52baf9){super(_0x4e3f42,_0x4c70ed,_0x52baf9),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x4e3f42,'Reply...')),this['bind']('authoredAt')['to'](_0x4c70ed),this['bind']('resolvedAt')['to'](_0x4c70ed),this['actionBar']=this['createCollection'](),this['isSystemComment']||(this['editButton']=this['_createEditButton'](),this['removeButton']=this['_createRemoveButton'](),this['items']=this['createCollection'](),this['items']['addMany']([this['editButton'],this['removeButton']]),this['dropdown']=this['_createDropdown'](),this['actionBar']['add'](this['dropdown']),this['focusables']['add'](this['dropdown'])),this['userView']=new _0x10d138(_0x4e3f42,_0x4c70ed['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x4c70ed,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x23b876=this['bindTemplate'],_0xb580b7=[{'tag':'div','attributes':{'class':['ck-comment__info','ck-annotation__info']},'children':[{'tag':'span','children':[{'text':this['userView']['name']}],'attributes':{'class':['ck-comment__info-name','ck-annotation__info-name'],'data-cke-tooltip-text':this['userView']['name']}},{'tag':'time','attributes':{'datetime':_0x23b876['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x23b876['to']('authoredAt',_0xc70c3d=>this['_config']['formatDateTime'](_0xc70c3d))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x23b876['if']('isEditMode','ck-comment__actions--hidden'),_0x23b876['if']('isEditMode','ck-annotation__actions--hidden')]},'children':this['actionBar']},{'tag':'div','attributes':{'class':['ck-annotation__content-wrapper']},'children':this['visibleView']},this['ariaDescriptionView']];return this['_model']['isExternal']&&_0xb580b7['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper'],'tabindex':-0x1,'aria-label':_0x23b876['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x23b876['if']('isEditMode','ck-comment--edit'),_0x23b876['if']('isSystemComment','ck-comment--info'),_0x23b876['to']('actionIndicator',_0x48b88a=>_0x48b88a?'ck-comment--'+_0x48b88a:'')],'data-author-id':this['_model']['author']['id'],'data-comment-id':this['_model']['id'],'role':'group'},'children':[this['userView'],{'tag':'div','attributes':{'class':['ck-comment__main','ck-annotation__main']},'children':_0xb580b7}]}]};}['_createEditButton'](){const _0x3a9cab=new _0x51cbda(this['locale']);return _0x3a9cab['label']=N(this['locale'],'Edit'),_0x3a9cab['icon']=_0x34713b,_0x3a9cab['withText']=!0x0,_0x3a9cab['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x3a9cab['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x32cf72=>!_0x32cf72),_0x3a9cab['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x3a9cab['on']('execute',()=>this['switchToEditMode']()),_0x3a9cab;}['_createRemoveButton'](){const _0x21e4af=new _0x51cbda(this['locale']);return _0x21e4af['label']=N(this['locale'],'Remove'),_0x21e4af['icon']=_0x5de0a6,_0x21e4af['withText']=!0x0,_0x21e4af['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x21e4af['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1dba30=>!_0x1dba30),_0x21e4af['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x21e4af['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x21e4af;}['_createDropdown'](){const _0x321e20=_0x21bd8b(this['locale'],_0x27738d),_0x37b165=_0x321e20['panelView']['children'],_0x4fe5a9=new _0x566929(this['locale']),_0x570a57=_0x321e20['bindTemplate'];_0x38f4a9(_0x321e20,()=>this['items']['find'](_0x4d902e=>_0x4d902e['isVisible'])),_0x321e20['extendTemplate']({'attributes':{'class':[_0x570a57['if']('isVisible','ck-hidden',_0x1fd7c0=>!_0x1fd7c0)]}});const _0x511ab0=(_0x182ec4,_0x3e7cbd=-0x1)=>{const _0x311dde=new _0x1d3ca4(this['locale']);_0x311dde['children']['add'](_0x182ec4);const _0x54a113=_0x3e7cbd>-0x1?_0x3e7cbd:_0x4fe5a9['items']['length'];_0x4fe5a9['items']['add'](_0x311dde,_0x54a113);const _0x2674be=Array['from'](this['items']);_0x321e20['unbind']('isEnabled','isVisible'),_0x321e20['bind']('isEnabled')['toMany'](_0x2674be,'isEnabled',(..._0x398064)=>_0x398064['some'](_0x9a6db9=>_0x9a6db9)),_0x321e20['bind']('isVisible')['toMany'](_0x2674be,'isVisible',(..._0x42bf5f)=>_0x42bf5f['some'](_0x493a0d=>_0x493a0d));};_0x321e20['panelPosition']='sw',_0x321e20['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x56dd0f});for(const _0x521e07 of this['items'])_0x511ab0(_0x521e07);return _0x37b165['add'](_0x4fe5a9),_0x321e20['listenTo'](this['items'],'add',(_0x39dd37,_0x411008,_0x45cdc4)=>{_0x511ab0(_0x411008,_0x45cdc4);}),_0x321e20['listenTo'](this['items'],'remove',(_0x3ceb74,_0x22cb57,_0xc4a30a)=>{_0x4fe5a9['items']['remove'](_0xc4a30a);}),_0x321e20;}['_attachActions'](_0x4f382a,_0x49a955){const _0x5c8b1a=_0x4f382a&&_0x4f382a['element'];_0x5c8b1a&&(this['listenTo'](_0x5c8b1a,'mouseenter',()=>this['actionIndicator']=_0x49a955),this['listenTo'](_0x5c8b1a,'focus',()=>this['actionIndicator']=_0x49a955),this['listenTo'](_0x5c8b1a,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x5c8b1a,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x4611f5=super['_createCommentInputView']();return _0x4611f5['bind']('placeholder')['to'](this),_0x4611f5;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x5db8b6){const _0xa9d9dd=Dt(_0x5db8b6,0x1e),_0x13cb5d=new MutationObserver(_0x4cbba8=>{for(const _0x4bc1e3 of _0x4cbba8)('attributes'==_0x4bc1e3['type']&&'class'==_0x4bc1e3['attributeName']||'childList'==_0x4bc1e3['type']||'characterData'==_0x4bc1e3['type'])&&_0xa9d9dd();});return{'attach'(_0x22f43d){_0x13cb5d['observe'](_0x22f43d,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x13cb5d['disconnect'](),_0xa9d9dd['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x30546e,_0x2f2895){super(_0x30546e),this['id']=_0x411bc5(),this['focusTracker']=new _0x3ab247(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x1603c8,_0x5d6cb8)=>this['fire']('Esc',_0x5d6cb8)),this['set']('targetRect',{'top':0x0,'right':0x0,'bottom':0x0,'left':0x0}),this['set']('height',0x0),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['set']('length',0x0),this['set']('type',''),this['_mutationObserver']=xt(()=>this['_updateHeight']()),this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this),this['content']['add'](_0x2f2895),this['mainView']=_0x2f2895;const _0x2eb5c6=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x2eb5c6['if']('isActive','ck-annotation-wrapper--active')],'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['focusTracker']['add'](this['element']),this['keystrokes']['listenTo'](this['element']),this['_mutationObserver']['attach'](this['element']);}['destroy'](){this['content']['clear'](),this['keystrokes']['destroy'](),this['focusTracker']['destroy'](),this['_mutationObserver']['detach'](),super['destroy']();}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['_updateHeight'](){const _0x53b6ac=this['element']['clientHeight'];_0x53b6ac&&(this['height']=_0x53b6ac);}}class T extends/* #__PURE__ -- @preserve */
29
- _0x57a519(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0xb3314a,target:_0x16906d,type:_0x1f40fb,isVisible:_0x5dd30a=!0x0}){super(),this['view']=_0xb3314a,this['view']['element']||this['view']['render'](),this['_type']=_0x1f40fb,this['_target']=_0x16906d,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x3a23ae([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x6b0ebc,_0x74f5c3)=>{this['view']['focusTracker']['add'](_0x74f5c3);}),this['focusableElements']['on']('remove',(_0x57efc3,_0x4a78fc)=>{this['view']['focusTracker']['remove'](_0x4a78fc);}),this['set']('isVisible',_0x5dd30a);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x5be576=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x5be576),_0x5be576;}get['targetRect'](){const _0x5d6e5c=this['target'];if(null===_0x5d6e5c)return null;if(_0x5d6e5c instanceof _0x1c0a3f)return _0x5d6e5c;const _0x4b84ce=_0x5d6e5c['filter'](_0x342279=>function(_0x4ec31c){const _0x12931c=_0x4ec31c['offsetParent'];if(_0x12931c)return!0x0;const _0x1da4fe=_0x4ec31c['getClientRects']()['item'](0x0);return!!_0x1da4fe;}(_0x342279));return 0x0===_0x4b84ce['length']?null:new _0x1c0a3f(_0x4b84ce[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x34c601){this['view']['isActive']=_0x34c601,this['view']['mainView']['isActive']=_0x34c601;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0xc2a7e6){if(!(null===_0xc2a7e6||_0xc2a7e6 instanceof _0x1c0a3f||Array['isArray'](_0xc2a7e6)&&_0xc2a7e6['every'](_0x29ad75=>fi(_0x29ad75))))throw new _0x365e72('annotation-invalid-target',null,{'target':_0xc2a7e6});}['_getNormalizedTarget'](){const _0x2f9023='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0x2f9023)?[_0x2f9023]:_0x2f9023;}}function fi(_0x55fbe2){return null!==_0x55fbe2&&'object'==typeof _0x55fbe2&&'nodeType'in _0x55fbe2&&0x1===_0x55fbe2['nodeType'];}class S extends _0x3a23ae{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x4d8490=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x3ab247(),this['_focusTracker']['on']('change:isFocused',(_0x46fe30,_0x150918,_0x4a1940)=>{_0x4a1940||this['fire']('blur');});for(const _0x2ab770 of _0x4d8490)this['add'](_0x2ab770);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x2b4821){if(this['has'](_0x2b4821))throw new _0x365e72('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x2b4821['innerView'],_0x2b4821),this['_viewToAnnotation']['set'](_0x2b4821['view'],_0x2b4821);for(const _0x2c739a of _0x2b4821['focusableElements'])this['_focusTracker']['add'](_0x2c739a);this['listenTo'](_0x2b4821['focusableElements'],'add',(_0x12d52f,_0x145308)=>{this['_focusTracker']['add'](_0x145308);}),this['listenTo'](_0x2b4821['focusableElements'],'remove',(_0x385c31,_0x28f940)=>{this['_focusTracker']['remove'](_0x28f940);}),this['listenTo'](_0x2b4821['view']['focusTracker'],'change:isFocused',(_0x3c6219,_0x31a351,_0xc941b7)=>{_0xc941b7&&this['fire']('focus',_0x2b4821);}),_0x2b4821['updateTargetRect']();const _0x20fa69=this['_getOrderInContent'](_0x2b4821['view']['targetRect']);return super['add'](_0x2b4821,_0x20fa69);}['remove'](_0x1d7bd2){if(!this['has'](_0x1d7bd2))throw new _0x365e72('annotationcollection-not-existing-item',null);this['stopListening'](_0x1d7bd2['view']['focusTracker']),this['stopListening'](_0x1d7bd2['focusableElements']);for(const _0x19b9bb of _0x1d7bd2['focusableElements'])this['_focusTracker']['remove'](_0x19b9bb);return this['_viewToAnnotation']['delete'](_0x1d7bd2['view']),this['_innerViewToAnnotation']['delete'](_0x1d7bd2['innerView']),super['remove'](_0x1d7bd2);}['getByInnerView'](_0x1309d9){return this['_innerViewToAnnotation']['get'](_0x1309d9);}['getByView'](_0x5d92b0){return this['_viewToAnnotation']['get'](_0x5d92b0);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0xcad6d9 of this)_0xcad6d9['updateTargetRect']();this['_sort']();}['_sort'](){const _0x188019=Array['from'](this)['sort']((_0x87e9b2,_0x5333e4)=>w(_0x87e9b2['view']['targetRect'],_0x5333e4['view']['targetRect']));for(let _0x31f160=_0x188019['length']-0x1;_0x31f160>0x0;_0x31f160--){const _0xbfdfc3=_0x188019[_0x31f160];_0x31f160!==this['getIndex'](_0xbfdfc3)&&(this['remove'](_0xbfdfc3),this['add'](_0xbfdfc3));}}['_getOrderInContent'](_0x1732d5){let _0x1f7325=0x0;if(!_0x1732d5)return this['length'];for(const _0x35b1b8 of this){const _0x1d7e03=_0x35b1b8['view']['targetRect'];if(_0x1d7e03){if(w(_0x1732d5,_0x1d7e03)<0x0)return _0x1f7325;_0x1f7325++;}}return _0x1f7325;}}function v({source:_0x31348a,target:_0x61e258,filter:_0x183c9e}){for(const _0x1cc208 of _0x31348a)_0x183c9e(_0x1cc208)&&_0x61e258['add'](_0x1cc208);_0x61e258['listenTo'](_0x31348a,'add',(_0x1e9b02,_0x53484a)=>{_0x183c9e(_0x53484a)&&_0x61e258['add'](_0x53484a);}),_0x61e258['listenTo'](_0x31348a,'remove',(_0x29fafd,_0x2353fa)=>{_0x61e258['has'](_0x2353fa)&&_0x61e258['remove'](_0x2353fa);});}function w(_0x528476,_0xe902d5){if(null===_0x528476&&null===_0xe902d5)return 0x0;if(null===_0x528476)return-0x1;if(null===_0xe902d5)return 0x1;const _0x35a9f5=_0x528476['top']-_0xe902d5['top'];return 0x0==_0x35a9f5?_0x528476['left']-_0xe902d5['left']:_0x35a9f5;}class y extends _0x3905cc{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x341495){if(super(_0x341495),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x341495 instanceof _0x442658){const _0x2549c1=_0x341495['locale'];_0x341495['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x2549c1,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x1138c6){this['collection']['add'](_0x1138c6);}['remove'](_0xe1fbf1){this['collection']['remove'](_0xe1fbf1),_0xe1fbf1['destroy']();}['refreshVisibility'](){for(const _0x3653e7 of this['collection'])_0x3653e7['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x44cd39){return this['collection']['getByInnerView'](_0x44cd39);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x2cdc65 of this['collection'])_0x2cdc65['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0xa24ec9){this['fire']('_activateAnnotation',_0xa24ec9);}['createAnnotation'](_0x2665f7){return new T(_0x2665f7);}['createAnnotationView'](_0x5ce7af,_0xc883ba){return new E(_0x5ce7af,_0xc883ba);}['_addActiveAnnotation'](_0x10d2cd){const _0x113b60=new Set(this['activeAnnotations']);_0x113b60['add'](_0x10d2cd),this['activeAnnotations']=_0x113b60;}['_removeActiveAnnotation'](_0x522b73){const _0x5ebbe9=new Set(this['activeAnnotations']);_0x5ebbe9['delete'](_0x522b73),this['activeAnnotations']=_0x5ebbe9;}['_bindAnnotationsToVisibleAnnotations'](){const _0x87a1c1=this['collection'],_0x19fec5=this['_visibleAnnotations'];function _0x3e0707(_0x5597df){const _0x54f2f9=_0x5597df['source'];_0x54f2f9['isVisible']&&!_0x19fec5['has'](_0x54f2f9)?_0x19fec5['add'](_0x54f2f9):!_0x54f2f9['isVisible']&&_0x19fec5['has'](_0x54f2f9)&&_0x19fec5['remove'](_0x54f2f9),_0x54f2f9['view']['focusTracker']['remove'](_0x54f2f9['view']['element']),_0x54f2f9['view']['focusTracker']['add'](_0x54f2f9['view']['element']);}this['listenTo'](_0x87a1c1,'add',(_0x45a095,_0x436a5f)=>{_0x436a5f['isVisible']&&_0x19fec5['add'](_0x436a5f),this['listenTo'](_0x436a5f,'change:isVisible',_0x3e0707);}),this['listenTo'](_0x87a1c1,'remove',(_0x119c8c,_0x5e9cd4)=>{_0x19fec5['has'](_0x5e9cd4)&&_0x19fec5['remove'](_0x5e9cd4),this['stopListening'](_0x5e9cd4,'change:isVisible',_0x3e0707);});}['_setupEnterAnnotationKeystroke'](){const _0x1a63c7=_0x324eab=>{_0x324eab['on']('ready',()=>{_0x324eab['keystrokes']['set'](_0x1a8e77,(_0x4af0b8,_0x4eafa3)=>{const _0x2de58c=_0x4a1569(this['activeAnnotations']['values']());_0x2de58c&&(_0x2de58c['view']['focus'](),_0x4eafa3());});});};this['context']instanceof _0x442658?_0x1a63c7(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x1d6c24,_0x2a36e1)=>{_0x1a63c7(_0x2a36e1);});}['_setupEscapeAnnotationHandling'](){const _0x570f1a=_0x54756f=>{const _0xe7dea9=_0x54756f['source'],_0x1a56d5=[];let _0x188a9f;if(Array['isArray'](_0xe7dea9['target'])){_0x188a9f=_0xe7dea9['target'][0x0],this['context']instanceof _0x442658?_0x1a56d5['push'](this['context']):this['context']['editors']&&_0x1a56d5['push'](...this['context']['editors']);for(const _0x16bfa1 of _0x1a56d5)for(const _0x2a1870 of _0x16bfa1['editing']['view']['domRoots']['values']())if(_0x2a1870['contains'](_0x188a9f))return void _0x16bfa1['editing']['view']['focus']();_0x188a9f['focus']();}};this['listenTo'](this['collection'],'add',(_0x2d7f3b,_0x1c678a)=>{this['listenTo'](_0x1c678a,'escape',_0x570f1a,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x2ee432,_0x311c12)=>{this['stopListening'](_0x311c12,'escape',_0x570f1a);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x3905cc{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[y,lt,it];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3b1e44){super(_0x3b1e44),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x3f65dd=this['context']['config'];_0x3f65dd['define']('comments.maxCommentsWhenCollapsed',0x2),_0x3f65dd['define']('comments.maxThreadTotalWeight',0x1f4),_0x3f65dd['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x3f65dd['define']('comments.CommentThreadView',gt),_0x3f65dd['define']('comments.CommentView',Tt),_0x3f65dd['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0xbb3e25=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x8981b1,_0x5545e8)=>this['_addCommentThread'](_0x5545e8)),this['on']('submitCommentThread',(_0x3eea23,_0x4c305f)=>this['_submitCommentThread'](_0x4c305f)),this['on']('resolveCommentThread',(_0x6e39f,_0xd2575e)=>this['_resolveCommentThread'](_0xd2575e)),this['on']('resolveCommentThread',(_0x2ce619,_0x1c7556)=>this['_updateActiveAnnotation'](_0x1c7556),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x10b6eb,_0x1c230d)=>this['_reopenCommentThread'](_0x1c230d)),this['on']('reopenCommentThread',(_0x3f5da9,_0x3cd1cc)=>this['_updateActiveAnnotation'](_0x3cd1cc),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x194a5d,_0xa64a44)=>this['_removeCommentThread'](_0xa64a44)),this['on']('updateCommentThread',(_0x461f28,_0x1fafd0)=>this['_updateCommentThread'](_0x1fafd0)),this['on']('updateCommentThread',(_0x3038d2,_0x7a7692)=>this['_updateActiveAnnotation'](_0x7a7692),{'priority':'lowest'}),this['on']('addComment',(_0x387a5a,_0x11099a)=>this['_addComment'](_0x11099a)),this['on']('updateComment',(_0xe48dbe,_0x537b94)=>this['_updateComment'](_0x537b94)),this['on']('removeComment',(_0xf21d68,_0x316bf1)=>this['_removeComment'](_0x316bf1)),this['on']('addComment',(_0x463143,{threadId:_0x27676b,isFromAdapter:_0x23aeed})=>{if(_0x23aeed)return;const _0x293803=this['getCommentThread'](_0x27676b),_0x1b6274=_0x293803&&this['_threadToController']['get'](_0x293803);_0x1b6274&&_0x1b6274['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0xbb3e25,'change:activeAnnotations',(_0x4fdf12,_0x15698e,_0x4a0379)=>{const _0x1ba96e=Array['from'](_0x4a0379)['map'](_0x91440e=>this['_viewToController']['get'](_0x91440e['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x1ba96e?_0x1ba96e['model']:null;});}set['adapter'](_0x44405c){if(this['_adapter'])throw new _0x365e72('commentsrepository-adapter-already-set');this['_adapter']=_0x44405c;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x5ab76b=_t,threadId:_0xd06a02=_0x411bc5(),comments:_0xeeff08=[],unlinkedAt:_0x25df7d=null,resolvedAt:_0x5e9938=null,resolvedBy:_0x55eb0c=null,target:_0x52b1c5=null,context:_0x3a5d8b=null,attributes:_0x6693c3={},isResolvable:_0x1b74ec=!0x0,isSubmitted:_0x52f422=!0x1,isFromAdapter:_0x194019=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x5ab76b),{'channelId':_0x5ab76b,'threadId':_0xd06a02,'comments':_0xeeff08,'unlinkedAt':_0x25df7d,'resolvedAt':_0x5e9938,'resolvedBy':_0x55eb0c,'target':_0x52b1c5,'context':_0x3a5d8b,'attributes':_0x6693c3,'isFromAdapter':_0x194019,'isResolvable':_0x1b74ec,'isSubmitted':_0x52f422}),this['getCommentThread'](_0xd06a02);}['openNewCommentThread']({channelId:_0x577a97=_t,threadId:_0x4afdce=_0x411bc5(),target:_0x125648,context:_0x3b85da=null,isResolvable:_0x714389=!0x0}){if(this['_readOnlyChannels']['has'](_0x577a97)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x125648)throw new _0x365e72('commentsrepository-missing-target');const _0x4e5db9=this['addCommentThread']({'channelId':_0x577a97,'threadId':_0x4afdce,'target':_0x125648,'context':_0x3b85da,'isResolvable':_0x714389});if(!_0x4e5db9)return null;const _0x290cfd=this['_threadToController']['get'](_0x4e5db9),_0x2f440f=_0x290cfd['view']['commentThreadInputView']['commentInputView'],_0x1ca431=this['context']['plugins']['get'](y),_0x5227c6=_0x1ca431['getByInnerView'](_0x290cfd['view']);return _0x1ca431['activate'](_0x5227c6),_0x2f440f['once']('editorReady',()=>_0x2f440f['focus']()),_0x4e5db9;}['hasCommentThread'](_0x49c51d){if('string'!=typeof _0x49c51d)throw new _0x365e72('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x49c51d);}['updateCommentThread']({channelId:_0x102bf6=_t,threadId:_0x24600f,context:_0x45bd86,unlinkedAt:_0x597d64,attributes:_0x414a90,isFromAdapter:_0x48e27f=!0x1}){return this['fire'](Nt('updateCommentThread',_0x102bf6),{'channelId':_0x102bf6,'threadId':_0x24600f,'context':_0x45bd86,'unlinkedAt':_0x597d64,'attributes':_0x414a90,'isFromAdapter':_0x48e27f}),this['getCommentThread'](_0x24600f);}['getCommentThread'](_0x4b50f1){if('string'!=typeof _0x4b50f1)throw new _0x365e72('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x4b50f1);}['fetchCommentThread']({channelId:_0x14056e,threadId:_0x239d3f}={}){const _0x1d12d7=this['getCommentThread'](_0x239d3f);if(_0x1d12d7)return Promise['resolve'](_0x1d12d7);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x365e72('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x14056e,'threadId':_0x239d3f})['then'](_0x2667c7=>this['hasCommentThread'](_0x239d3f)?this['getCommentThread'](_0x239d3f):_0x2667c7?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x14056e},_0x2667c7)):void 0x0)['catch'](_0x3e6c76=>{throw console['error'](_0x3e6c76),new _0x365e72('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x4e1eb2,skipNotAttached:_0x4c6c5d=!0x1,skipEmpty:_0x2cb5cf=!0x1,toJSON:_0x2b0c70=!0x1}={}){const _0x5c87a5=[];for(const _0x39b952 of this['_threads']['values']())_0x4e1eb2&&_0x39b952['channelId']!==_0x4e1eb2||_0x4c6c5d&&!_0x39b952['isAttached']||_0x2cb5cf&&0x0===_0x39b952['length']||_0x5c87a5['push'](_0x39b952);return _0x2b0c70?_0x5c87a5['map'](_0x4731e6=>_0x4731e6['toJSON']()):_0x5c87a5;}['getAnnotationForCommentThread'](_0x1484de){const _0x23339b=this['_threadToController']['get'](_0x1484de);if(!_0x23339b)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x23339b['view'])||null;}['getCommentThreadForAnnotation'](_0x2a71ca){const _0x31934e=this['_viewToController']['get'](_0x2a71ca['innerView']);return _0x31934e?_0x31934e['model']:null;}['setActiveCommentThread'](_0x4532c8){const _0x5ae525=this['context']['plugins']['get'](y);if(!_0x4532c8)return void(this['activeCommentThread']&&_0x5ae525['deactivateAll']());const _0x4d6fdb=this['getCommentThread'](_0x4532c8);if(!_0x4d6fdb)throw new _0x365e72('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x4532c8});if(!this['_threadToController']['has'](_0x4d6fdb))throw new _0x365e72('commentsrepository-active-not-attached',null,{'threadId':_0x4532c8});const _0xff0808=_0x5ae525['getByInnerView'](this['_threadToController']['get'](_0x4d6fdb)['view']);_0x5ae525['activate'](_0xff0808);}['switchReadOnly'](_0x1a6b62,_0x295a46){_0x1a6b62?this['_readOnlyChannels']['add'](_0x295a46):this['_readOnlyChannels']['delete'](_0x295a46),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x3aa581){return this['_readOnlyChannels']['has'](_0x3aa581)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x5bd7c7,_0x5bb74e){return new vt(_0x5bd7c7,_0x5bb74e);}['setPermissions'](_0x24bab0,_0x2eb185=_t){this['_permissions']['set'](_0x2eb185,_0x24bab0),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x57def5=_t){return this['_permissions']['has'](_0x57def5)?this['_permissions']['get'](_0x57def5):bt;}['_addCommentThread']({channelId:_0x9d6cee,threadId:_0x47dff2,comments:_0x5b1321,unlinkedAt:_0x5b58e8,resolvedAt:_0x1ba009,resolvedBy:_0x8727a7,target:_0x4020a4,context:_0x5efff6,attributes:_0x528a10,isFromAdapter:_0x3d081d,isResolvable:_0x360274,isSubmitted:_0x10a772}){if('string'!=typeof _0x47dff2)throw new _0x365e72('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x47dff2});if(this['hasCommentThread'](_0x47dff2))throw new _0x365e72('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x47dff2});const _0x161c71=new pi(this,{'channelId':_0x9d6cee,'id':_0x47dff2,'context':_0x5efff6,'attributes':_0x528a10,'unlinkedAt':_0x5b58e8,'resolvedAt':_0x1ba009,'resolvedBy':_0x8727a7?this['context']['plugins']['get'](it)['getUser'](_0x8727a7):null,'isResolvable':_0x360274,'isSubmitted':_0x10a772||_0x3d081d});this['_threads']['set'](_0x47dff2,_0x161c71);for(const _0x4b7d1c of _0x5b1321)_0x161c71['_add'](this['_createNewComment']({'threadId':_0x47dff2,..._0x4b7d1c}));return _0x4020a4&&_0x161c71['attachTo'](_0x4020a4),_0x3d081d||!_0x161c71['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x9d6cee,'threadId':_0x47dff2});}['_submitCommentThread']({channelId:_0x29f9e6,threadId:_0xcc3d88}){if(!this['hasCommentThread'](_0xcc3d88))throw new _0x365e72('commentsrepository-missing-comment-thread',this);const _0x5d2d07=this['getCommentThread'](_0xcc3d88);if(_0x5d2d07['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x23457d,comments:_0x43baff,resolvedAt:_0x11d8e4,resolvedBy:_0x100e73,context:_0x472378,attributes:_0x4bac7c}=_0x5d2d07,_0x4f693d=this['context']['plugins']['get']('PendingActions'),_0x4fd640=_0x4f693d['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x29f9e6,'threadId':_0x23457d,'comments':_0x43baff['map'](_0x56ea9e=>_0x56ea9e['toJSON']()),'resolvedAt':_0x11d8e4,'resolvedBy':_0x100e73?_0x100e73['id']:_0x100e73,'context':_0x472378,'attributes':_0x4bac7c})['then'](({comments:_0x1e0483})=>{_0x4f693d['remove'](_0x4fd640);for(const _0x1f0b3f of _0x1e0483)this['_updateComment']({'channelId':_0x29f9e6,'threadId':_0xcc3d88,'commentId':_0x1f0b3f['commentId'],'createdAt':_0x1f0b3f['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x556e88=>{throw console['error'](_0x556e88),new _0x365e72('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x54d99a,target:_0x1342f8}){const _0x317e0e=this['getCommentThread'](_0x54d99a);if(!_0x317e0e)throw new _0x365e72('commentsrepository-attach-missing-comment-thread',this);const _0x4a8c44=this['context']['plugins']['get']('PendingActions'),_0x2422f5=this['context']['plugins']['get'](y),_0x40f1bf=this['_createCommentThreadView'](_0x317e0e),_0x188eb3=new vt(_0x317e0e,_0x40f1bf);let _0x417c65=null;_0x40f1bf['on']('change:isDirty',(_0x1f8c29,_0x4f9d22,_0x713400)=>{_0x713400?_0x417c65=_0x4a8c44['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x417c65&&(_0x4a8c44['remove'](_0x417c65),_0x417c65=null);}),this['_threadToController']['set'](_0x317e0e,_0x188eb3),this['_viewToController']['set'](_0x40f1bf,_0x188eb3);const _0x933bfa=new E(this['context']['locale'],_0x40f1bf);_0x933bfa['bind']('length')['to'](_0x40f1bf),_0x933bfa['bind']('isDirty')['to'](_0x40f1bf,'isDirty',_0x40f1bf,'length',(_0x5e65c7,_0x5872da)=>_0x5e65c7||!_0x5872da),_0x933bfa['bind']('isActive')['to'](_0x40f1bf),_0x933bfa['type']='comment';const _0x170743=new T({'view':_0x933bfa,'target':_0x1342f8,'type':'comment','isVisible':!_0x317e0e['archivedAt']&&!!('function'==typeof _0x1342f8?_0x1342f8():_0x1342f8)});return _0x40f1bf['on']('escape',()=>{_0x170743['fire']('escape');}),this['_bindAnnotationToEditors'](_0x40f1bf,_0x170743),_0x2422f5['add'](_0x170743),_0x170743;}['_bindAnnotationToEditors'](_0x251f4e,_0x52fb16){this['listenTo'](_0x251f4e,'editorReady',(_0xc643af,_0x142092)=>{const _0x1dcbe3=_0x142092['ui']['view']['body']['bodyCollectionContainer'];_0x52fb16['focusableElements']['add'](_0x1dcbe3),this['context']instanceof _0x442658&&this['context']['ui']['focusTracker']['add'](_0x1dcbe3);},{'priority':'highest'}),this['listenTo'](_0x251f4e,'editorDestroyed',(_0x4a2105,_0x355711)=>{const _0x5d2016=_0x355711['ui']['view']['body']['bodyCollectionContainer'];_0x52fb16['focusableElements']['has'](_0x5d2016)&&_0x52fb16['focusableElements']['remove'](_0x5d2016),this['context']instanceof _0x442658&&this['context']['ui']['focusTracker']['remove'](_0x5d2016);});}['_unbindEditors'](_0x2b3727){this['stopListening'](_0x2b3727,'editorReady'),this['stopListening'](_0x2b3727,'editorDestroyed');}['_createCommentThreadView'](_0x514302){const _0x51800f=this['context']['plugins']['get'](it),{config:_0x5e5ed3,locale:_0x4de0b9}=this['context'],_0x1c4946=pt(_0x5e5ed3['get']('locale'),_0x4de0b9);return new(0x0,(_0x5e5ed3['get']('comments'))['CommentThreadView'])(_0x4de0b9,_0x514302,_0x51800f['me'],{'editorConfig':{..._0x5e5ed3['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x5e5ed3['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x5e5ed3['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x5e5ed3['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x5e5ed3['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x1c4946,'CommentView':_0x5e5ed3['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x32fb93,channelId:_0x59ea18,resolvedAt:_0x33ccac,resolvedBy:_0x439339,isFromAdapter:_0x2e2a73}){if(!this['hasCommentThread'](_0x32fb93))throw new _0x365e72('commentsrepository-missing-comment-thread',null,{'threadId':_0x32fb93});const _0x6125a1=this['getCommentThread'](_0x32fb93);if(_0x6125a1['isResolved'])throw new _0x365e72('commentsrepository-resolved-comment-thread',null,{'threadId':_0x32fb93});const _0x4435ae=this['context']['plugins']['get'](it);if(_0x6125a1['resolvedBy']=_0x4435ae['getUser'](_0x439339),_0x6125a1['resolvedAt']=_0x33ccac,_0x2e2a73||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x5befd3=this['context']['plugins']['get']('PendingActions'),_0x2d2db5=_0x5befd3['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x59ea18,'threadId':_0x32fb93})['then'](({resolvedAt:_0x2ebe21,resolvedBy:_0x12173e})=>{_0x5befd3['remove'](_0x2d2db5),_0x6125a1['resolvedBy']['id']!==_0x12173e&&(_0x6125a1['resolvedBy']=_0x4435ae['getUser'](_0x12173e)),_0x6125a1['resolvedAt']=_0x2ebe21;})['catch'](_0x5dd920=>{throw console['error'](_0x5dd920),new _0x365e72('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x25b45b,channelId:_0x1b4471,isFromAdapter:_0x193183}){if(!this['hasCommentThread'](_0x25b45b))throw new _0x365e72('commentsrepository-missing-comment-thread',null,{'threadId':_0x25b45b});const _0x165da0=this['getCommentThread'](_0x25b45b);if(!_0x165da0['isResolved'])throw new _0x365e72('commentsrepository-reopen-comment-thread',null,{'threadId':_0x25b45b});if(_0x165da0['resolvedBy']=null,_0x165da0['resolvedAt']=null,_0x193183||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x2d4c11=this['context']['plugins']['get']('PendingActions'),_0x46025f=_0x2d4c11['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x1b4471,'threadId':_0x25b45b})['then'](()=>_0x2d4c11['remove'](_0x46025f))['catch'](_0x4544a5=>{throw console['error'](_0x4544a5),new _0x365e72('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x5bc009,isFromAdapter:_0x3649b6}){const _0x5cfffb=this['getCommentThread'](_0x5bc009);if(!_0x5cfffb)throw new _0x365e72('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x5bc009),this['_threads']['delete'](_0x5bc009),!_0x5cfffb['isSubmitted']||_0x3649b6||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x33ac94=this['context']['plugins']['get']('PendingActions'),{channelId:_0x242da6}=_0x5cfffb,_0x23c9ef=_0x33ac94['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x242da6,'threadId':_0x5bc009})['then'](()=>_0x33ac94['remove'](_0x23c9ef))['catch'](_0x10c261=>{throw console['error'](_0x10c261),new _0x365e72('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x185e17,unlinkedAt:_0x489df5,context:_0x4d68b6,attributes:_0x121f06,isFromAdapter:_0x3b1839}){if('string'!=typeof _0x185e17)throw new _0x365e72('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x185e17});if(!this['hasCommentThread'](_0x185e17))throw new _0x365e72('commentsrepository-missing-comment-thread',null,{'threadId':_0x185e17});const _0x51ce5e=this['getCommentThread'](_0x185e17);let _0x1f2ac8=!0x1;if(void 0x0!==_0x4d68b6&&_0x51ce5e['context']!==_0x4d68b6&&(_0x51ce5e['context']=_0x4d68b6,_0x1f2ac8=!0x0),void 0x0!==_0x489df5&&_0x51ce5e['unlinkedAt']!==_0x489df5&&(_0x51ce5e['unlinkedAt']=_0x489df5,_0x1f2ac8=!0x0),_0x121f06&&!At(_0x121f06,_0x51ce5e['attributes'])&&(_0x51ce5e['attributes']=_0x121f06,_0x1f2ac8=!0x0),!_0x1f2ac8)return Promise['resolve']();if(!_0x51ce5e['isSubmitted']||_0x3b1839||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x36bf0e=this['context']['plugins']['get']('PendingActions'),{channelId:_0x173de4}=_0x51ce5e,_0x21a6c8=_0x36bf0e['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x173de4,'threadId':_0x185e17,'context':_0x4d68b6,'unlinkedAt':_0x489df5,'attributes':_0x121f06})['then'](()=>_0x36bf0e['remove'](_0x21a6c8))['catch'](_0x3588b2=>{throw console['error'](_0x3588b2),new _0x365e72('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x269135){const _0x2267cb=this['context']['plugins']['get'](y),_0x13c2c9=this['getCommentThread'](_0x269135);if(_0x13c2c9['_isAttached']=!0x1,this['_threadToController']['has'](_0x13c2c9)){const _0x5cc838=this['_threadToController']['get'](_0x13c2c9),_0x4153d1=_0x5cc838['view'],_0x373110=_0x2267cb['getByInnerView'](_0x4153d1);this['_threadToController']['delete'](_0x13c2c9),this['_viewToController']['delete'](_0x4153d1),_0x373110&&_0x2267cb['remove'](_0x373110),_0x5cc838['destroy'](),_0x4153d1['destroy']()['then'](()=>{this['_unbindEditors'](_0x4153d1);});}}['_updateActiveAnnotation']({threadId:_0x4d6171,resolvedAt:_0x471ad8,unlinkedAt:_0xf1bc0}){const _0x141e6a=!!_0x471ad8,_0x24dc79=this['context']['plugins']['get'](y),_0x1704fe=this['getCommentThread'](_0x4d6171);if(this['_threadToController']['has'](_0x1704fe)){const _0x5a3bb2=this['_threadToController']['get'](_0x1704fe)['view'],_0xfb11f=_0x24dc79['getByInnerView'](_0x5a3bb2);_0xfb11f&&(_0x141e6a&&_0x24dc79['_removeActiveAnnotation'](_0xfb11f),_0xf1bc0?_0xfb11f['isVisible']=!0x1:_0xfb11f['refreshVisibility']());}}['_getExternalAuthor'](_0x47b7c4){const _0xf1b607=this['context']['plugins']['get'](it),_0x2cf46b=It('external:'+_0x47b7c4),_0x5aabe3=_0xf1b607['getUser'](_0x2cf46b);return _0x5aabe3||_0xf1b607['addUser']({'id':_0x2cf46b,'name':_0x47b7c4});}['_createNewComment']({threadId:_0x1ff5b1,commentId:_0x83cb=_0x411bc5(),content:_0x513fc9,authorId:_0x2181f0,createdAt:_0x224b55,attributes:_0x4fc2fb}){if('string'!=typeof _0x83cb)throw new _0x365e72('commentsrepository-invalid-commentid');if('string'!=typeof _0x2181f0)throw new _0x365e72('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x513fc9||!_0x513fc9['trim']())throw new _0x365e72('commentsrepository-invalid-comment-content');const _0x3b25c5=this['context']['plugins']['get'](it)['getUser'](_0x2181f0);if(!_0x3b25c5)throw new _0x365e72('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x2181f0});let _0x2fdf66=null,_0x20d682=_0x224b55;return _0x4fc2fb?.['@external']&&(_0x2fdf66=this['_getExternalAuthor'](_0x4fc2fb['@external']['authorName']),_0x20d682=new Date(_0x4fc2fb['@external']['createdAt'])),new wi(this,{'threadId':_0x1ff5b1,'id':_0x83cb,'author':_0x2fdf66||_0x3b25c5,'creator':_0x3b25c5,'content':_0x513fc9,'createdAt':_0x224b55,'authoredAt':_0x20d682,'attributes':_0x4fc2fb});}['_addComment'](_0x2e05ba){let {threadId:_0x9aab6f,content:_0x59d846,attributes:_0x37f6c7,isFromAdapter:_0x3f6204}=_0x2e05ba;const _0xee97c3=this['getCommentThread'](_0x2e05ba['threadId']);if(!_0xee97c3)throw new _0x365e72('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x5670e1=this['_createNewComment'](_0x2e05ba),{id:_0x3b7e65}=_0x5670e1;if(_0xee97c3['_add'](_0x5670e1),_0x3f6204||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0xee97c3['isSubmitted'])return Promise['resolve']();const _0x3b24f2=this['context']['plugins']['get']('PendingActions'),{channelId:_0x24ee49}=_0xee97c3,_0x2aef9a=_0x3b24f2['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x37f6c7||(_0x37f6c7={}),this['adapter']['addComment']({'channelId':_0x24ee49,'threadId':_0x9aab6f,'commentId':_0x3b7e65,'content':_0x59d846,'attributes':_0x37f6c7})['then'](_0x188940=>{_0x3b24f2['remove'](_0x2aef9a),_0x188940&&this['_updateComment']({'channelId':_0x24ee49,'threadId':_0x9aab6f,'commentId':_0x3b7e65,'createdAt':_0x188940['createdAt'],'isFromAdapter':!0x0});})['catch'](_0xac7565=>{throw console['error'](_0xac7565),new _0x365e72('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x7a72d0,commentId:_0xcb66a0,content:_0x26df50,createdAt:_0x2d1d31,attributes:_0x11762f,isFromAdapter:_0x5b6935}){if(void 0x0!==_0x26df50&&('string'!=typeof _0x26df50||!_0x26df50['trim']()['length']))throw new _0x365e72('commentsrepository-update-comment-invalid-content');const _0x538eb2=this['getCommentThread'](_0x7a72d0),_0x35469a=_0x538eb2['getComment'](_0xcb66a0);if(!_0x35469a)throw new _0x365e72('commentsrepository-update-missing-comment',this);let _0x2beb2e=!0x1;if(_0x26df50&&_0x26df50!==_0x35469a['content']&&(_0x35469a['isEditable']||_0x5b6935)&&(_0x35469a['content']=_0x26df50,_0x2beb2e=!0x0),_0x2d1d31&&_0x2d1d31!==_0x35469a['createdAt']&&(_0x35469a['createdAt']=_0x2d1d31,_0x35469a['attributes']&&_0x35469a['attributes']['@external']||(_0x35469a['authoredAt']=_0x2d1d31),_0x2beb2e=!0x0),_0x11762f&&!At(_0x11762f,_0x35469a['attributes'])&&(_0x35469a['attributes']=_0x11762f,_0x2beb2e=!0x0),!_0x2beb2e)return Promise['resolve']();if(_0x538eb2['fire']('commentUpdated'),_0x5b6935||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x9ea7b7=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4da307}=this['getCommentThread'](_0x35469a['threadId']),_0x4cd8ee=_0x9ea7b7['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x4da307,'threadId':_0x7a72d0,'commentId':_0xcb66a0,'content':_0x26df50,'attributes':_0x11762f})['then'](()=>_0x9ea7b7['remove'](_0x4cd8ee))['catch'](_0x222000=>{throw console['error'](_0x222000),new _0x365e72('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x2f0fac,commentId:_0x815f7d,isFromAdapter:_0x431c7f}){const _0x24b7cf=this['getCommentThread'](_0x2f0fac),_0x4b19d7=_0x24b7cf['getComment'](_0x815f7d);if(!_0x4b19d7)throw new _0x365e72('commentsrepository-remove-missing-comment',this);if(_0x24b7cf['_remove'](_0x4b19d7),_0x431c7f||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x4de64e=this['context']['plugins']['get']('PendingActions'),{channelId:_0x152eac}=_0x24b7cf,_0x60d662=_0x4de64e['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x152eac,'threadId':_0x2f0fac,'commentId':_0x815f7d})['then'](()=>_0x4de64e['remove'](_0x60d662))['catch'](_0x3f8363=>{throw console['error'](_0x3f8363),new _0x365e72('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
- _0x57a519(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x4deb94,_0x1aac15){super();const _0x20361e=_0x1aac15['isResolvable'];this['channelId']=_0x1aac15['channelId'],this['id']=_0x1aac15['id'],this['comments']=new _0x3a23ae(),this['_repository']=_0x4deb94,this['_isAttached']=!0x1,this['_isSubmitted']=_0x1aac15['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x4deb94,'_permissions',_0x4deb94,'_readOnlyChannels',()=>_0x4deb94['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x4deb94,'_permissions',()=>_0x4deb94['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x4deb94,'_permissions',()=>{const _0x393da0=_0x4deb94['getPermissions'](this['channelId']);return _0x393da0['write']||_0x393da0['admin'];}),this['bind']('isResolvable')['to'](_0x4deb94,'_permissions',()=>_0x20361e&&_0x4deb94['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x1aac15['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x5a0287,_0x362256)=>_0x5a0287?_0x362256?_0x5a0287<_0x362256?_0x5a0287:_0x362256:_0x5a0287:_0x362256),this['set']('unlinkedAt',_0x1aac15['unlinkedAt']||null),this['set']('resolvedAt',_0x1aac15['resolvedAt']||null),this['set']('resolvedBy',_0x1aac15['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x53e952=>!!_0x53e952),this['set']('attributes',_0x1aac15['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0xd19172,_0x46cea1)=>_0xd19172+_0x46cea1['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x5c1ad7,id:_0x40ffa9}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x5c1ad7),{'channelId':_0x5c1ad7,'threadId':_0x40ffa9});}['setUnlinkedAt'](_0x3dee15){this['_update']({'unlinkedAt':_0x3dee15});}['resolve']({resolvedAt:_0x5db6d0=new Date(),resolvedBy:_0x5e1d11='',isFromAdapter:_0x393eb2=!0x1}={}){const _0x4477d4=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0xfd13f4,id:_0x5c423a}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0xfd13f4),{'channelId':_0xfd13f4,'threadId':_0x5c423a,'resolvedAt':_0x5db6d0,'resolvedBy':_0x5e1d11||_0x4477d4['id'],'isFromAdapter':_0x393eb2});}['reopen']({isFromAdapter:_0x19251c=!0x1}={}){const {channelId:_0x2390c1,id:_0x1616ab}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x2390c1),{'channelId':_0x2390c1,'threadId':_0x1616ab,'isFromAdapter':_0x19251c});}['setContext'](_0x1ba389){this['context']||this['_update']({'context':_0x1ba389});}['setAttribute'](_0x20044b,_0x273388){const _0x21d3bc=wt(this['attributes']);yt(_0x21d3bc,_0x20044b,_0x273388),this['_update']({'attributes':_0x21d3bc});}['removeAttribute'](_0x3fb51e){const _0x17f806=wt(this['attributes']);Ct(_0x17f806,_0x3fb51e),this['_update']({'attributes':_0x17f806});}['remove']({isFromAdapter:_0x8a4fe8=!0x1}={}){const {channelId:_0x549065,id:_0x57b7b0}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x549065),{'channelId':_0x549065,'threadId':_0x57b7b0,'isFromAdapter':_0x8a4fe8});}['attachTo'](_0x34a84c){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x34a84c});}['addComment'](_0x38d9ff){const {channelId:_0x3437d4,id:_0x20149}=this;this['_repository']['fire'](Nt('addComment',_0x3437d4,_0x20149),Object['assign']({'channelId':_0x3437d4,'threadId':_0x20149},_0x38d9ff));}['getComment'](_0x59b331){if('string'!=typeof _0x59b331)throw new _0x365e72('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x59b331});return this['comments']['get'](_0x59b331);}['toJSON'](){return{'threadId':this['id'],'context':this['context'],'unlinkedAt':this['unlinkedAt'],'resolvedAt':this['resolvedAt'],'resolvedBy':this['resolvedBy']?this['resolvedBy']['id']:null,'archivedAt':this['archivedAt'],'comments':this['comments']['map'](_0x2f7585=>_0x2f7585['toJSON']()),'attributes':this['attributes']};}['_add'](_0x174030){return this['listenTo'](_0x174030,'change:authoredAt',()=>{const _0x1d09f2=this['_findOptimalIndex'](_0x174030),_0x5c8f07=this['comments'];_0x1d09f2-0x1!=_0x5c8f07['getIndex'](_0x174030)&&_0x1d09f2+0x1!=_0x5c8f07['getIndex'](_0x174030)&&(this['_remove'](_0x174030),this['_add'](_0x174030));}),this['comments']['add'](_0x174030,this['_findOptimalIndex'](_0x174030));}['_update'](_0x2376ba){const {channelId:_0x40f37a,id:_0x5e8939}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x40f37a),{..._0x2376ba,'channelId':_0x40f37a,'threadId':_0x5e8939});}['_remove'](_0x45f887){return this['stopListening'](_0x45f887),_0x45f887['destroy'](),this['comments']['remove'](_0x45f887);}['_findOptimalIndex'](_0x1b935e){const _0xfa2d08=this['comments']['find'](_0x53fd84=>new Date(_0x53fd84['authoredAt'])['getTime']()>new Date(_0x1b935e['authoredAt'])['getTime']());return _0xfa2d08?this['comments']['getIndex'](_0xfa2d08):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
- _0x57a519(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x2edeb5,_0x2a5a6f){super();const _0x471aa4=_0x2edeb5['context']['plugins']['get'](it)['me'],_0x4c3756=_0x2edeb5['getCommentThread'](_0x2a5a6f['threadId']),_0x309b8a=0x0===_0x4c3756['comments']['length'],_0x7b1acd=_0x471aa4===_0x2a5a6f['author'];this['id']=_0x2a5a6f['id'],this['threadId']=_0x2a5a6f['threadId'],this['author']=_0x2a5a6f['author'],this['creator']=_0x2a5a6f['creator'],this['isExternal']=Boolean(_0x2a5a6f['attributes']&&_0x2a5a6f['attributes']['@external']),this['set']('content',_0x2a5a6f['content']),this['createdAt']=_0x2a5a6f['createdAt']||new Date(),this['set']('authoredAt',_0x2a5a6f['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x4c3756,'resolvedAt'),this['set']('attributes',_0x2a5a6f['attributes']||{}),this['bind']('isEditable')['to'](_0x2edeb5,'_permissions',()=>{const _0x31120a=_0x2edeb5['getPermissions'](_0x4c3756['channelId'])['write'],_0x12959e=_0x2edeb5['getPermissions'](_0x4c3756['channelId'])['modifyAll'];return _0x7b1acd&&_0x31120a||!_0x7b1acd&&_0x12959e;}),this['bind']('isRemovable')['to'](_0x4c3756,'isRemovable',_0x2edeb5,'_permissions',_0x3245eb=>{const _0x10d0f1=_0x2edeb5['getPermissions'](_0x4c3756['channelId'])['write'],_0x2dd546=_0x2edeb5['getPermissions'](_0x4c3756['channelId'])['modifyAll'];return _0x7b1acd&&_0x10d0f1||_0x3245eb&&_0x309b8a||!_0x7b1acd&&_0x2dd546&&!_0x309b8a;}),this['bind']('isReadOnly')['to'](_0x4c3756,'isReadOnly'),this['_repository']=_0x2edeb5;}get['weight'](){return Math['max'](function(_0x4b4d9a){const _0x151cee=document['createElement']('div');return _0x151cee['innerHTML']=_0x4b4d9a,_0x151cee['textContent']['length'];}(this['content']),0xc8);}['update'](_0x34eb0a){const {threadId:_0x44d7ea,id:_0x3887ad}=this;if(!this['_repository']['hasCommentThread'](_0x44d7ea))throw new _0x365e72('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x46e11d}=this['_repository']['getCommentThread'](_0x44d7ea);this['_repository']['fire'](Nt('updateComment',_0x46e11d,_0x44d7ea),{'channelId':_0x46e11d,'threadId':_0x44d7ea,'commentId':_0x3887ad,..._0x34eb0a});}['setAttribute'](_0x30d8c2,_0xc1e681){const _0x21aee0=wt(this['attributes']);yt(_0x21aee0,_0x30d8c2,_0xc1e681),this['update']({'attributes':_0x21aee0});}['removeAttribute'](_0x14f0d5){const _0x3db2a6=wt(this['attributes']);Ct(_0x3db2a6,_0x14f0d5),this['update']({'attributes':_0x3db2a6});}['remove'](_0x553310={}){if(!_0x553310['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x46ce48,id:_0x1d4653}=this;if(!this['_repository']['hasCommentThread'](_0x46ce48))throw new _0x365e72('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x2d5d25}=this['_repository']['getCommentThread'](_0x46ce48);this['_repository']['fire'](Nt('removeComment',_0x2d5d25,_0x46ce48),{'channelId':_0x2d5d25,'threadId':_0x46ce48,'commentId':_0x1d4653,..._0x553310});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x68d327,..._0x592d3b){for(const _0xf2952c of _0x592d3b)void 0x0!==_0xf2952c&&(_0x68d327+=':'+String(_0xf2952c));return _0x68d327;}class ot extends _0x4812bd{constructor(_0x45a713){super(_0x45a713),this['set']('hasContent',!0x1);}['refresh'](){const _0xbf0fd=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x39bbf9 of _0xbf0fd['getRanges']())if(this['_hasContent'](_0x39bbf9))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x14360c=_0x411bc5(),ranges:_0x4a1535,comment:_0x59eb33}={}){const _0x523ee1=this['editor']['model'],_0x16aec1=_0x4a1535??Array['from'](_0x523ee1['document']['selection']['getRanges']()),_0xbd0152=[];for(const _0x1e60f1 of _0x16aec1)this['_hasContent'](_0x1e60f1)&&_0xbd0152['push'](this['_trimToContent'](_0x1e60f1));if(!_0xbd0152['length'])throw new _0x365e72('addcommentthreadcommand-incorrect-ranges',null);_0x59eb33&&this['_createCommentThread'](_0x14360c,_0x59eb33),this['_createMarkersFromRanges'](_0x14360c,_0xbd0152,!!_0x59eb33);}['_createMarkersFromRanges'](_0x1c02e1,_0x362d69,_0x3f62b2){this['editor']['model']['change'](_0x231844=>{for(const _0x4c763e of _0x362d69){const _0x1abe18=_0x411bc5()['substr'](0x1,0x5),_0x397a23='comment:'+_0x1c02e1+':'+_0x1abe18;_0x231844['addMarker'](_0x397a23,{'range':_0x4c763e,'usingOperation':_0x3f62b2,'affectsData':_0x3f62b2});}});}['_createCommentThread'](_0x1a15a2,_0x2b57b1){const _0x3caa27=this['editor']['plugins']['get']('CommentsRepository'),_0x5c378c=this['editor']['config']['get']('collaboration.channelId'),_0x2cb7f9=this['editor']['plugins']['get']('Users')['me'];if(!_0x2cb7f9)throw new _0x365e72('addcommentthreadcommand-user-not-found',null);_0x3caa27['addCommentThread']({'threadId':_0x1a15a2,'channelId':_0x5c378c,'comments':[{'authorId':_0x2cb7f9['id'],'content':_0x2b57b1,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x22ff10){for(const _0x151590 of _0x22ff10['getItems']())if(this['_itemIsContent'](_0x151590))return!0x0;return!0x1;}['_itemIsContent'](_0x5addd4){return _0x5addd4['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x5addd4)&&!_0x5addd4['is']('element','tableCell');}['_trimToContent'](_0x3314b3){const _0x1a17f0=_0x3ea98b=>!this['_itemIsContent'](_0x3ea98b['item']),_0xe7360f=_0x3314b3['start']['getLastMatchingPosition'](_0x1a17f0),_0x2df5f0=_0x3314b3['end']['getLastMatchingPosition'](_0x1a17f0,{'direction':'backward'});return this['editor']['model']['createRange'](_0xe7360f,_0x2df5f0);}}class b extends _0x2525e1{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x14fa2c){super(_0x14fa2c),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0xbef589=this['editor'],_0xd992b6=_0xbef589['model']['document']['selection'],_0x32eaa1=_0xd7f4fb(()=>this['refreshSelectedViews'](),0xa);_0xd992b6['on']('change:range',(_0x2f9ca7,_0x272d52)=>{_0x272d52['directChange']&&(_0x32eaa1['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0xbef589['editing']['view']['document'],'change:isFocused',(_0xde1c9e,_0x305473,_0x3ac1c6)=>{_0x3ac1c6&&_0x32eaa1();}),this['listenTo'](_0xbef589['ui']['focusTracker'],'change:isFocused',(_0x252ca8,_0xf6993d,_0x57eaea)=>{_0x57eaea||this['fire']('blur',{'isAnnotationTracked':_0x44f56d=>this['_editorAnnotationsData']['has'](_0x44f56d['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x267f5b){if(this['_editorAnnotations']['has'](_0x267f5b['view']))return;this['_editorAnnotations']['add'](_0x267f5b['view']),this['editor']['ui']['focusTracker']['add'](_0x267f5b['view']['element']);const _0x2ebc0b=this['editor']['plugins']['get'](y);this['listenTo'](_0x2ebc0b['collection'],'remove',(_0x4ef6a7,_0x5eccac)=>{this['editor']['ui']['focusTracker']['remove'](_0x5eccac['view']['element']),this['_editorAnnotations']['delete'](_0x5eccac['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x46bd2e){if('function'!=typeof _0x46bd2e)throw new _0x365e72('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x46bd2e);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x4b314a,annotations:_0x10e082}){const _0x1f87e6=[],_0x1c5a74=this['editor']['model']['document']['selection'],_0xfc7df7=Array['from'](_0x1c5a74['getRanges']());for(const [_0x40f502,_0x88a81f]of this['_editorAnnotationsData']){const _0x212023=_0x1beeea(_0x88a81f),_0x317e77=_0x10e082['getByInnerView'](_0x40f502);_0x212023&&_0x317e77&&_0x1f87e6['push']({'annotation':_0x317e77,'range':_0x212023});}function _0x1beeea(_0x2a3a53){for(const _0x2f52bb of _0x2a3a53)for(const _0x3f28e4 of _0xfc7df7)if(_0x2f52bb['containsRange'](_0x3f28e4,!_0x1c5a74['isCollapsed']))return _0x2f52bb;return null;}return _0x1f87e6['sort']((_0x44693e,_0x36e6bb)=>{const _0x4f2bdf=_0x44693e['range'],_0x2d2de6=_0x36e6bb['range'];if(!_0x4f2bdf['isEqual'](_0x2d2de6)){if(_0x4f2bdf['containsRange'](_0x2d2de6,!0x0))return 0x1;if(_0x2d2de6['containsRange'](_0x4f2bdf,!0x0))return-0x1;}return _0x44693e['annotation']==_0x4b314a?-0x1:_0x36e6bb['annotation']==_0x4b314a?0x1:0x0;})['map'](_0x455d51=>_0x455d51['annotation']);}get['_editorAnnotationsData'](){const _0xa70e4=new Map();for(const _0xc5a5cb of Array['from'](this['_dataCollectors']))for(const [_0x502d1f,_0x3123bf]of _0xc5a5cb())_0xa70e4['set'](_0x502d1f,_0x3123bf);return _0xa70e4;}}class st extends _0x2525e1{['afterInit'](){const _0x2265d9=this['editor'];if(!_0x2265d9['plugins']['has']('RestrictedEditingModeEditing'))return;_0x2265d9['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x2525e1{constructor(_0x1e962a){super(_0x1e962a),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x37b546=this['editor'],_0x12500a=_0x37b546['commands']['get']('importWord'),_0x35d99b=_0x37b546['plugins']['get'](it);_0x12500a&&(_0x12500a['on']('execute',(_0x486002,[,_0x27baa9])=>{_0x27baa9['collaboration_features']={'comments':!0x0,'user_id':_0x35d99b['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x12500a,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x2fe68b,_0x473a7b){const {comment_threads:_0x44f2f8}=_0x473a7b;_0x44f2f8&&_0x44f2f8['forEach'](({thread_id:_0xff3f0c,comments:_0x24cde2,is_resolved:_0xdbef92})=>{const _0x281c92=new Date(),_0x139f16=_0x24cde2['map'](({author:_0xc2da6a,content:_0x365abd,created_at:_0x1ae99f})=>({'content':_0x365abd,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x281c92,'attributes':{'@external':{'authorName':_0xc2da6a,'createdAt':_0x1ae99f?new Date(_0x1ae99f):new Date(),'source':'importWord'}}})),_0x5889f1=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x5889f1,'threadId':_0xff3f0c,'comments':_0x139f16,'resolvedAt':_0xdbef92?_0x281c92:null});});}}class at extends _0x2525e1{constructor(_0x303118){super(_0x303118),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x552828=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x552828,'contentInsertion',(_0x37fe3f,_0x203ac5)=>this['_removeMarkersWithoutThreads'](_0x203ac5['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x117f70){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x117f70;const _0x3bcacd=this['editor']['plugins']['get']('CommentsRepository');for(const _0x16fbad of _0x117f70['keys']()){const [_0x585514,_0xc2f9b0]=_0x16fbad['split'](':');'comment'!=_0x585514||_0x3bcacd['hasCommentThread'](_0xc2f9b0)||_0x117f70['delete'](_0x16fbad);}return _0x117f70;}['_registerMarkerInClipboardPipeline'](){const _0x3a6845=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x2b1528=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x2b1528&&_0x3a6845['_registerMarkerToCopy']('comment',_0x2b1528);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x1f2a24){switch(_0x1f2a24){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0x1cb4a5){const _0x5bbf2b=_0x1cb4a5['split'](':');return{'group':_0x5bbf2b[0x0],'id':_0x5bbf2b[0x1],'part':_0x5bbf2b[0x2]};}class ut extends _0x2525e1{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x5e75e7,_0x58146c)=>{if(!_0x58146c['options']['showCommentHighlights'])return null;if(_0x58146c['options']['ignoreResolvedComments']){const {id:_0x24b162}=ft(_0x5e75e7['markerName']),_0x3237f6=this['editor']['plugins']['get'](o);if(_0x3237f6['getCommentThread'](_0x24b162)?.['isResolved']&&_0x5e75e7['item'])return _0x58146c['consumable']['consume'](_0x5e75e7['item'],'addMarker:'+_0x5e75e7['markerName']),_0x58146c['consumable']['consume'](_0x5e75e7['item'],'removeMarker:'+_0x5e75e7['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x4b73a9=>{_0x4b73a9['on']('addMarker:comment',(_0x133d46,_0x3a90c9,_0x2cf2b3)=>{if(!_0x2cf2b3['options']['showCommentHighlights'])return;const _0x4b0cb8=_0x3a90c9['item'];if(!_0x4b0cb8)return;const _0x4637a3=_0x2cf2b3['mapper']['toViewElement'](_0x4b0cb8);this['editor']['model']['schema']['isObject'](_0x4b0cb8)&&_0x4637a3&&!_0x4637a3['getCustomProperty']('widget')&&_0x4637a3['is']('containerElement')&&_0x8e165b(_0x4637a3,_0x2cf2b3['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x236db3,{writer:_0x5e6adc,options:_0x498536})=>{if(!_0x498536['showCommentHighlights'])return null;const _0x3d51fa=_0x5e6adc['createContainerElement']('div'),_0x54379c=_0x5e6adc['createEmptyElement']('hr');return _0x5e6adc['addClass']('ck-horizontal-line',_0x3d51fa),_0x5e6adc['insert'](_0x5e6adc['createPositionAt'](_0x3d51fa,0x0),_0x54379c),_0x3d51fa;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x3ff440,{writer:_0x3acd64,options:_0x41f30e})=>{if(!_0x41f30e['showCommentHighlights'])return null;const _0x314f77=_0x3acd64['createContainerElement']('span'),_0x5b1228=_0x3acd64['createEmptyElement']('img');return _0x3acd64['addClass']('image-inline',_0x314f77),_0x3acd64['insert'](_0x3acd64['createPositionAt'](_0x314f77,0x0),_0x5b1228),_0x314f77;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x55a4b3,{writer:_0x19cc6e,options:_0x34f3ec})=>{if(_0x34f3ec['showCommentHighlights'])return _0x19cc6e['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x24397c,_0x4b4f99,_0x4a2499)=>{_0x4a2499['options']['showCommentHighlights']&&_0x24397c['stop']();},{'priority':'high'});}}class r extends _0x2525e1{static get['requires'](){return[o,b,it,st,ct,at,ut];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x248576){super(_0x248576),this['set']('isThreadsLoadingPaused',!0x0),_0x248576['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x3916ae,_0x55e913,_0x131602,_0x406962)=>{const _0x3a2f8a=_0x248576['plugins']['get'](o),_0x48ae56=_0x131602?ft(_0x131602)['id']:null;_0x248576['model']['change'](()=>{if(_0x48ae56){const _0x5b1035=this['getAllMarkersForId'](_0x48ae56);for(const _0x780f3b of _0x5b1035)_0x248576['editing']['reconvertMarker'](_0x780f3b);}if(_0x406962){const {id:_0x1645a2}=ft(_0x406962),_0x2666cc=_0x3a2f8a['getCommentThread'](_0x1645a2);if(_0x2666cc&&_0x2666cc['unlinkedAt'])return;if(_0x2666cc&&!_0x2666cc['isAttached'])return;const _0x11ddb3=this['getAllMarkersForId'](_0x1645a2);for(const _0x56a86f of _0x11ddb3)_0x248576['editing']['reconvertMarker'](_0x56a86f);}}),_0x48ae56&&this['scrollToThreadMarker'](_0x48ae56);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x30e8cf=this['editor'],_0x4910f0=_0x30e8cf['plugins']['get'](o),_0x41fb30=_0x30e8cf['config']['get']('collaboration.channelId'),_0x3b1a1a=_0x4910f0['getCommentThreads']()['filter'](_0x4c6b57=>_0x4c6b57['channelId']!==_0x41fb30);_0x30e8cf['commands']['add']('addCommentThread',new ot(_0x30e8cf)),this['listenTo'](_0x30e8cf,'change:isReadOnly',(_0x1f7aac,_0x35c053,_0x32c8fa)=>{_0x4910f0['switchReadOnly'](_0x32c8fa,_0x30e8cf['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x4910f0,dt('addCommentThread',_0x41fb30),(_0x1766db,{threadId:_0x18d36c})=>{const _0x122212=this['editor']['plugins']['get'](o)['getCommentThread'](_0x18d36c);_0x122212?.['unlinkedAt']&&this['_attachArchivedThread'](_0x18d36c);}),this['listenTo'](_0x4910f0,dt('removeCommentThread',_0x41fb30),(_0x1111c8,{threadId:_0x30fbb6})=>{_0x30e8cf['model']['enqueueChange']({'isUndoable':!0x1},_0x152d57=>{const _0x1dd2d0=this['getAllMarkersForId'](_0x30fbb6);for(const _0x14d2af of _0x1dd2d0)_0x152d57['removeMarker'](_0x14d2af);});}),this['listenTo'](_0x4910f0,dt('resolveCommentThread',_0x41fb30),(_0xe19d30,{threadId:_0x69408f})=>{(this['_reconvertMarkers'](_0x69408f),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x69408f)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x4910f0,dt('reopenCommentThread',_0x41fb30),(_0x1c430c,{threadId:_0xac8a54})=>{this['_reconvertMarkers'](_0xac8a54);},{'priority':'low'}),this['listenTo'](_0x4910f0,dt('addComment',_0x41fb30),(_0x3e08c5,{threadId:_0x10fc1f,isFromAdapter:_0x5bcc40})=>{const _0x41872d=this['getAllMarkersForId'](_0x10fc1f);if(_0x5bcc40||0x0==_0x41872d['length']||!_0x4910f0['hasCommentThread'](_0x10fc1f))return;0x1===_0x4910f0['getCommentThread'](_0x10fc1f)['length']&&_0x30e8cf['model']['enqueueChange']({'isUndoable':!0x1},_0x196c2f=>{for(const _0x20f792 of _0x41872d)_0x196c2f['updateMarker'](_0x20f792,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x3b1a1a);}['afterInit'](){!async function(_0x2454e5){const _0x166a1b=_0x3fde66([0x4b,0x70,0x4f,0x42,0x4a,0x47,0x4e,0x53,0x45,0x67,0x71,0x43,0x79,0x66,0x56,0x46,0x31,0x6b,0x5a,0x38,0x6c,0x62,0x6e,0x52,0x6a,0x4d,0x37,0x65,0x49,0x7a,0x41,0x73,0x44,0x51,0x48,0x77,0x39,0x61,0x54,0x68,0x75,0x36,0x72,0x63,0x59,0x69,0x30,0x35,0x55,0x6d,0x50,0x4c,0x34,0x64,0x33,0x58,0x32,0x57,0x6f,0x74,0x76,0x78]),_0x4fc739=0x73460ab3,_0xd606d1=0x734189d3^_0x4fc739,_0x1d487c=window[_0x3fde66([0x44,0x61,0x74,0x65])][_0x3fde66([0x6e,0x6f,0x77])](),_0x2f7b7f=_0x2454e5[_0x3fde66([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5b34bd=new window[(_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x121a27=>{_0x2f7b7f[_0x3fde66([0x6f,0x6e,0x63,0x65])](_0x3fde66([0x72,0x65,0x61,0x64,0x79]),_0x121a27);}),_0x2ff449={[_0x3fde66([0x6b,0x74,0x79])]:_0x3fde66([0x45,0x43]),[_0x3fde66([0x75,0x73,0x65])]:_0x3fde66([0x73,0x69,0x67]),[_0x3fde66([0x63,0x72,0x76])]:_0x3fde66([0x50,0x2d,0x32,0x35,0x36]),[_0x3fde66([0x78])]:_0x3fde66([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]),[_0x3fde66([0x79])]:_0x3fde66([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]),[_0x3fde66([0x61,0x6c,0x67])]:_0x3fde66([0x45,0x53,0x32,0x35,0x36])},_0x4a1cad=_0x2f7b7f[_0x3fde66([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3fde66([0x67,0x65,0x74])](_0x3fde66([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x56a20f(){let _0x2aacd5,_0x38c9bb=null,_0x1f7e57=null;try{if(_0x4a1cad==_0x3fde66([0x47,0x50,0x4c]))return _0x3fde66([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2aacd5=_0x3d64cb(),!_0x2aacd5)return _0x3fde66([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2aacd5[_0x3fde66([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1f7e57=_0x292e10(_0x2aacd5[_0x3fde66([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2aacd5[_0x3fde66([0x6a,0x74,0x69])])),await _0x136f30()?_0x792709()?_0x5f4c11()?_0x3fde66([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5b4310()?(_0x2aacd5[_0x3fde66([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3fde66([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x38c9bb=_0x5af6c4(_0x3fde66([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2ce0e6()):_0x3fde66([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3fde66([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3fde66([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x3fde66([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5f4c11(){const _0xf3afa4=[_0x3fde66([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3fde66([0x74,0x72,0x69,0x61,0x6c])][_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2aacd5[_0x3fde66([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x1d487c/0x3e8:0xe10*_0xd606d1;return _0x2aacd5[_0x3fde66([0x65,0x78,0x70])]<_0xf3afa4;}function _0x792709(){const _0x4c01b3=_0x2aacd5[_0x3fde66([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4c01b3)return!0x1;if(_0x4c01b3[_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3fde66([0x2a])))return!0x0;if(_0x4c01b3[_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3fde66([0x43,0x4d,0x54])))return!0x0;if(_0x4c01b3[_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3fde66([0x54,0x52,0x49,0x4c,0x49,0x55,0x4d]))&&_0x26e968())return!0x0;if(_0x4c01b3[_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3fde66([0x52,0x43,0x4d,0x54]))){if(_0x408ba0())return!0x0;if(_0x3379c2()||_0x335b99())return!0x0;}return!0x1;}function _0x5b4310(){const _0x385111=_0x2aacd5[_0x3fde66([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x385111||0x0==_0x385111[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x28f853}=new URL(window[_0x3fde66([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x385111[_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x28f853))return!0x0;const _0x18bf20=_0x28f853[_0x3fde66([0x73,0x70,0x6c,0x69,0x74])](_0x3fde66([0x2e]));return _0x385111[_0x3fde66([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5c93ec=>_0x5c93ec[_0x3fde66([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3fde66([0x2a])))[_0x3fde66([0x6d,0x61,0x70])](_0x18350a=>_0x18350a[_0x3fde66([0x73,0x70,0x6c,0x69,0x74])](_0x3fde66([0x2e])))[_0x3fde66([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2fd036=>_0x2fd036[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x18bf20[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3fde66([0x6d,0x61,0x70])](_0x19cc42=>Array(_0x18bf20[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x19cc42[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3fde66([0x66,0x69,0x6c,0x6c])](_0x19cc42[0x0]===_0x3fde66([0x2a])?_0x3fde66([0x2a]):'')[_0x3fde66([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x19cc42))[_0x3fde66([0x73,0x6f,0x6d,0x65])](_0x3107c6=>_0x18bf20[_0x3fde66([0x65,0x76,0x65,0x72,0x79])]((_0x21cc04,_0x344310)=>_0x3107c6[_0x344310]===_0x21cc04||_0x3107c6[_0x344310]===_0x3fde66([0x2a])));}function _0x2ce0e6(){return _0x38c9bb&&_0x1f7e57?new window[(_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xc3ef82,_0x4a9fe6)=>{_0x38c9bb[_0x3fde66([0x74,0x68,0x65,0x6e])](_0xc3ef82,_0x4a9fe6),_0x1f7e57[_0x3fde66([0x74,0x68,0x65,0x6e])](_0x189c4d=>{_0x189c4d!=_0x3fde66([0x56,0x61,0x6c,0x69,0x64])&&_0xc3ef82(_0x189c4d);},_0x4a9fe6);}):_0x38c9bb||_0x1f7e57||_0x3fde66([0x56,0x61,0x6c,0x69,0x64]);}}function _0x292e10(_0x3570f0,_0x2e7247){return new window[(_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4c32d5=>{if(_0x1198c7())return _0x4c32d5(_0x3fde66([0x56,0x61,0x6c,0x69,0x64]));_0x4e243f(),_0x2f7b7f[_0x3fde66([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3fde66([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x34307e=!0x1;const _0x917dd5=_0x411bc5();function _0x4f206d(_0x367a39){return!!_0x367a39&&(typeof _0x367a39===_0x3fde66([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x367a39===_0x3fde66([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x367a39[_0x3fde66([0x74,0x68,0x65,0x6e])]===_0x3fde66([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x367a39[_0x3fde66([0x63,0x61,0x74,0x63,0x68])]===_0x3fde66([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x38d69(_0x1c14cf){_0x2851f5(_0x1c14cf)[_0x3fde66([0x74,0x68,0x65,0x6e])](_0xae8af=>{if(!_0xae8af||_0xae8af[_0x3fde66([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3fde66([0x6f,0x6b]))return _0x3fde66([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x54dca8(_0x4ad20b(_0x917dd5+_0x2e7247))!=_0xae8af[_0x3fde66([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3fde66([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3fde66([0x56,0x61,0x6c,0x69,0x64]);})[_0x3fde66([0x74,0x68,0x65,0x6e])](_0x5c048b=>(_0x4e19dd(),_0x5c048b),()=>{const _0x36dd4b=_0xd8af3e();return null==_0x36dd4b?(_0x4e19dd(),_0x3fde66([0x56,0x61,0x6c,0x69,0x64])):_0x3fde66(_0x1d487c-_0x36dd4b>(0x574a8eb3^_0x4fc739)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3fde66([0x74,0x68,0x65,0x6e])](_0x4c32d5)[_0x3fde66([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4c32d5(_0x3fde66([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x356e56=0x7370e433^_0x4fc739;function _0x4e19dd(){const _0x2364a7=_0x3fde66([0x6c,0x6c,0x63,0x74,0x2d])+_0x54dca8(_0x4ad20b(_0x3570f0)),_0x38d7af=_0x267e00(_0x54dca8(window[_0x3fde66([0x4d,0x61,0x74,0x68])][_0x3fde66([0x63,0x65,0x69,0x6c])](_0x1d487c/_0x356e56)));window[_0x3fde66([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3fde66([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2364a7,_0x38d7af);}function _0xd8af3e(){const _0x213e66=_0x3fde66([0x6c,0x6c,0x63,0x74,0x2d])+_0x54dca8(_0x4ad20b(_0x3570f0)),_0x41adad=window[_0x3fde66([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3fde66([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x213e66);return _0x41adad?window[_0x3fde66([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x267e00(_0x41adad),0x10)*_0x356e56:null;}function _0x2851f5(_0x3ead95){return new window[(_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x10edd6,_0x2c1a22)=>{_0x3ead95[_0x3fde66([0x74,0x68,0x65,0x6e])](_0x10edd6,_0x2c1a22),window[_0x3fde66([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2c1a22,0x7347de73^_0x4fc739);});}}_0x2f7b7f[_0x3fde66([0x6f,0x6e])](_0x3fde66([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2980c8,_0x1ef3ff)=>{if(_0x1ef3ff[0x0]!=_0x3570f0)return _0x4c32d5(_0x3fde66([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1ef3ff[0x1]={..._0x1ef3ff[0x1],[_0x3fde66([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x917dd5};},{[_0x3fde66([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3fde66([0x68,0x69,0x67,0x68])}),_0x2f7b7f[_0x3fde66([0x6f,0x6e])](_0x3fde66([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2d6158=>{_0x4f206d(_0x2d6158[_0x3fde66([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x34307e=!0x0,_0x38d69(_0x2d6158[_0x3fde66([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3fde66([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3fde66([0x6c,0x6f,0x77])}),_0x5b34bd[_0x3fde66([0x74,0x68,0x65,0x6e])](()=>{_0x34307e||_0x4c32d5(_0x3fde66([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1198c7(){return _0x2f7b7f[_0x3fde66([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3fde66([0x76,0x69,0x65,0x77])][_0x3fde66([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3fde66([0x61,0x75,0x74,0x6f]);}function _0x4e243f(){_0x2f7b7f[_0x3fde66([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3fde66([0x76,0x69,0x65,0x77])][_0x3fde66([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3fde66([0x61,0x75,0x74,0x6f]);}}function _0x5af6c4(_0x1885c4){const _0x554635=[new window[(_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f321e=>setTimeout(_0x4f321e,0x734f347f^_0x4fc739)),_0x5b34bd[_0x3fde66([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3d3bb7=>{let _0x1a4dc4=0x0;_0x2f7b7f[_0x3fde66([0x6d,0x6f,0x64,0x65,0x6c])][_0x3fde66([0x6f,0x6e])](_0x3fde66([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x5c566f,_0x4e7b9a)=>{_0x4e7b9a[0x0][_0x3fde66([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x1a4dc4++,_0x1a4dc4==(0x73460f5b^_0x4fc739)&&(_0x3d3bb7(),_0x5c566f[_0x3fde66([0x6f,0x66,0x66])]());});}))];return window[_0x3fde66([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3fde66([0x72,0x61,0x63,0x65])](_0x554635)[_0x3fde66([0x74,0x68,0x65,0x6e])](()=>_0x1885c4);}async function _0x33c443(){await _0x5b34bd,_0x2f7b7f[_0x3fde66([0x6d,0x6f,0x64,0x65,0x6c])][_0x3fde66([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1f1c76,_0x2f7b7f[_0x3fde66([0x6d,0x6f,0x64,0x65,0x6c])][_0x3fde66([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1f1c76,_0x2f7b7f[_0x3fde66([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3fde66([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x26e968(){return window[_0x3fde66([0x67,0x6c,0x6f,0x62])]&&window[_0x3fde66([0x67,0x6c,0x6f,0x62])][_0x3fde66([0x74,0x72,0x69,0x6c,0x69,0x75,0x6d,0x56,0x65,0x72,0x73,0x69,0x6f,0x6e])];}function _0x408ba0(){return _0x16b525(_0x3fde66([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4f755f(_0x3fde66([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3fde66([0x73,0x74,0x61,0x74,0x65])]==_0x3fde66([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3379c2(){return _0x16b525(_0x3fde66([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 _0x335b99(){return _0x16b525(_0x3fde66([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x14193e(_0x187484){const _0x563839=_0x24935a();_0x2f7b7f[_0x563839]=_0x3fde66([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x187484,_0x187484!=_0x3fde66([0x56,0x61,0x6c,0x69,0x64])&&_0x33c443();}function _0x24935a(){const _0x5d64e8=window[_0x3fde66([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3fde66([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3fde66([0x6e,0x6f,0x77])]())[_0x3fde66([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3fde66([0x2e]),'');let _0x2dba54=_0x3fde66([0x4b]);for(let _0x16ddb6=0x0;_0x16ddb6<_0x5d64e8[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x16ddb6+=0x2){let _0x542252=window[_0x3fde66([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d64e8[_0x3fde66([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x16ddb6,_0x16ddb6+0x2));_0x542252>=_0x166a1b[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x542252-=_0x166a1b[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2dba54+=_0x166a1b[_0x542252];}return _0x2dba54;}function _0x3d64cb(){const _0x1223da=_0x4a1cad[_0x3fde66([0x73,0x70,0x6c,0x69,0x74])](_0x3fde66([0x2e]));if(0x3!=_0x1223da[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x540c4a(_0x1223da[0x1]);function _0x540c4a(_0x3f5515){const _0x397789=_0x3a3498(_0x3f5515);return _0x397789&&_0x165ca7()?_0x397789:null;function _0x165ca7(){const _0x38d73a=_0x397789[_0x3fde66([0x6a,0x74,0x69])],_0x4f708a=window[_0x3fde66([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x38d73a[_0x3fde66([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x38d73a[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x992db6={..._0x397789,[_0x3fde66([0x6a,0x74,0x69])]:_0x38d73a[_0x3fde66([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x38d73a[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x992db6[_0x3fde66([0x76,0x63])],_0x4ad20b(_0x992db6)==_0x4f708a;}}}async function _0x136f30(){let _0x39c3b2=!0x0;try{const _0x54e831=_0x4a1cad[_0x3fde66([0x73,0x70,0x6c,0x69,0x74])](_0x3fde66([0x2e])),[_0x82db77,_0x1925b3,_0x2dfaff]=_0x54e831;return _0x32f1c8(_0x82db77),await _0x454ea4(_0x82db77,_0x1925b3,_0x2dfaff),_0x39c3b2;}catch{return!0x1;}function _0x32f1c8(_0x14047e){const _0x45f704=_0x3a3498(_0x14047e);_0x45f704&&_0x45f704[_0x3fde66([0x61,0x6c,0x67])]==_0x3fde66([0x45,0x53,0x32,0x35,0x36])||(_0x39c3b2=!0x1);}async function _0x454ea4(_0x55e28e,_0xef604d,_0x1f8cb9){const _0x49b272=window[_0x3fde66([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3fde66([0x66,0x72,0x6f,0x6d])](_0x31f7c0(_0x1f8cb9),_0x5f2fca=>_0x5f2fca[_0x3fde66([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x353063=new window[(_0x3fde66([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3fde66([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x55e28e+_0x3fde66([0x2e])+_0xef604d),_0x2db9f5=window[_0x3fde66([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3fde66([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x2db9f5)return;const _0x3eeee4=await _0x2db9f5[_0x3fde66([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3fde66([0x6a,0x77,0x6b]),_0x2ff449,{[_0x3fde66([0x6e,0x61,0x6d,0x65])]:_0x3fde66([0x45,0x43,0x44,0x53,0x41]),[_0x3fde66([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3fde66([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3fde66([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x2db9f5[_0x3fde66([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3fde66([0x6e,0x61,0x6d,0x65])]:_0x3fde66([0x45,0x43,0x44,0x53,0x41]),[_0x3fde66([0x68,0x61,0x73,0x68])]:{[_0x3fde66([0x6e,0x61,0x6d,0x65])]:_0x3fde66([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3eeee4,_0x49b272,_0x353063)||(_0x39c3b2=!0x1);}}function _0x3a3498(_0x20aead){return _0x20aead[_0x3fde66([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3fde66([0x65,0x79]))?JSON[_0x3fde66([0x70,0x61,0x72,0x73,0x65])](_0x31f7c0(_0x20aead)):null;}function _0x31f7c0(_0x39a246){return window[_0x3fde66([0x61,0x74,0x6f,0x62])](_0x39a246[_0x3fde66([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3fde66([0x2b]))[_0x3fde66([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3fde66([0x2f])));}function _0x4ad20b(_0x38440b){let _0x44bf00=0x1505;function _0x3209a3(_0x5d93d4){for(let _0x5692f4=0x0;_0x5692f4<_0x5d93d4[_0x3fde66([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5692f4++){const _0x2ceb2e=_0x5d93d4[_0x3fde66([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5692f4);_0x44bf00=(_0x44bf00<<0x5)+_0x44bf00+_0x2ceb2e,_0x44bf00&=_0x44bf00;}}function _0x1d5bb8(_0x3934c8){Array[_0x3fde66([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3934c8)?_0x3934c8[_0x3fde66([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x1d5bb8):_0x3934c8&&typeof _0x3934c8==_0x3fde66([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3fde66([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3934c8)[_0x3fde66([0x73,0x6f,0x72,0x74])]()[_0x3fde66([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x107410,_0x1e246e])=>{_0x3209a3(_0x107410),_0x1d5bb8(_0x1e246e);}):_0x3209a3(window[_0x3fde66([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3934c8));}return _0x1d5bb8(_0x38440b),_0x44bf00>>>0x0;}function _0x54dca8(_0x1c9ed9){return _0x1c9ed9[_0x3fde66([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3fde66([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3fde66([0x30]));}function _0x267e00(_0x36b575){return _0x36b575[_0x3fde66([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3fde66([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3fde66([0x6a,0x6f,0x69,0x6e])]('');}function _0x16b525(_0x3aaa1e){return _0x2f7b7f[_0x3fde66([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3fde66([0x68,0x61,0x73])](_0x3aaa1e);}function _0x4f755f(_0x1315f9){return _0x2f7b7f[_0x3fde66([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3fde66([0x67,0x65,0x74])](_0x1315f9);}function _0x1f1c76(){}function _0x3fde66(_0x228caf){return _0x228caf['map'](_0x225166=>String['fromCharCode'](_0x225166))['join']('');}_0x14193e(await _0x56a20f());}(this);}['destroy'](){const _0x474ad3=this['editor']['plugins']['get'](o),_0xaed80c=this['editor']['config']['get']('collaboration.channelId');for(const _0xb3146f of _0x474ad3['getCommentThreads']({'channelId':_0xaed80c}))_0x474ad3['_detachCommentThread'](_0xb3146f['id']),_0x474ad3['_threads']['delete'](_0xb3146f['id']);super['destroy']();}['hasMarkerForId'](_0x72d473){return this['getAllMarkersForId'](_0x72d473)['length']>0x0;}['getAllMarkersForId'](_0x58ce05){const _0x2671e9=[];for(const _0x3d8b60 of this['editor']['model']['markers'])_0x3d8b60['name']['startsWith']('comment:'+_0x58ce05)&&_0x2671e9['push'](_0x3d8b60);return _0x2671e9;}['scrollToThreadMarker'](_0x1e43a6){setTimeout(()=>{const _0x163f9b=this['_getTargetForId'](_0x1e43a6);if(!_0x163f9b)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x1e43a6&&nt({'target':_0x163f9b[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x2523d0){this['editor']['model']['change'](()=>{for(const _0x3a2dcf of this['getAllMarkersForId'](_0x2523d0))this['editor']['editing']['reconvertMarker'](_0x3a2dcf);});}['_attachArchivedThread'](_0x2339bf){const _0x2e757a=this['editor']['plugins']['get'](o),_0x260bd4=this['editor']['plugins']['get'](b),_0xd54af6=_0x2e757a['getCommentThread'](_0x2339bf);if(!_0xd54af6['isAttached']){const _0x27546f=_0xd54af6['attachTo'](()=>this['_getTargetForId'](_0xd54af6['id']));_0x260bd4['registerAnnotation'](_0x27546f),_0xd54af6['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x58057b=this['editor'],_0x3ec336=_0x58057b['plugins']['get'](it);_0x58057b['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x450223,_0x576a6b)=>{const {id:_0x42882f}=ft(_0x450223['markerName']),_0x5508aa=_0x58057b['plugins']['get'](o)['getCommentThread'](_0x42882f),_0x53745a=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x42882f;let _0x5e4985;if(_0x5508aa&&_0x5508aa['isResolved']&&!_0x53745a&&_0x450223['item'])return _0x576a6b['consumable']['consume'](_0x450223['item'],'addMarker:'+_0x450223['markerName']),_0x576a6b['consumable']['consume'](_0x450223['item'],'removeMarker:'+_0x450223['markerName']),null;const _0x4fa6d7=['ck-comment-marker'];return _0x53745a&&_0x4fa6d7['push']('ck-comment-marker--active'),_0x5e4985=_0x5508aa?.['length']?_0x5508aa['comments']['first']['author']['id']:_0x3ec336['me']['id'],{'classes':_0x4fa6d7,'attributes':{'data-comment':_0x42882f,'data-author-id':_0x5e4985}};}}),_0x58057b['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x5d857e,{options:_0x1f8ff8})=>{if(_0x1f8ff8['showCommentHighlights'])return null;const _0x2ffeff=_0x58057b['plugins']['get'](o),_0x39ba9e=_0x58057b['model']['markers']['get'](_0x5d857e),{id:_0x19e8f3,part:_0x4d0a62}=ft(_0x5d857e);return _0x39ba9e&&!_0x39ba9e['affectsData']||_0x1f8ff8['ignoreResolvedComments']&&_0x2ffeff['getCommentThread'](_0x19e8f3)?.['isResolved']?null:{'group':'comment','name':_0x4d0a62?_0x19e8f3+':'+_0x4d0a62:_0x19e8f3};}}),_0x58057b['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x5ca2d7,{writer:_0xc7f374})=>_0xc7f374['createElement']('$marker',{'data-name':'comment:'+_0x5ca2d7['getAttribute']('id')})}),_0x58057b['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x38dc29=this['editor'],_0x322374=_0x38dc29['plugins']['get'](o),_0x173436=new Set(),_0x3dafbc=new Set();_0x38dc29['model']['document']['registerPostFixer'](_0x4546a5=>{let _0x3fd2f3=!0x1;for(const {name:_0x4fef06,data:_0x3979ec}of _0x38dc29['model']['document']['differ']['getChangedMarkers']()){const {group:_0x16104e,id:_0x500c2b}=ft(_0x4fef06);let _0x6ef82c=_0x3979ec['newRange'];if('comment'!==_0x16104e||!_0x6ef82c)continue;const _0x4c439f='$graveyard'===_0x6ef82c['root']['rootName'];_0x4c439f||(_0x6ef82c=ht(_0x6ef82c,_0x38dc29['model']),!_0x6ef82c||_0x6ef82c['isCollapsed']||!_0x3979ec['newRange']||_0x6ef82c['isEqual'](_0x3979ec['newRange']))?_0x38dc29['model']['hasContent'](_0x6ef82c)&&!_0x4c439f?this['isThreadsLoadingPaused']?_0x173436['add'](_0x4fef06):this['_handleThreadMarker'](_0x4fef06,_0x500c2b):(_0x3dafbc['add'](_0x4fef06),_0x173436['delete'](_0x4fef06),_0x4546a5['removeMarker'](_0x4fef06),_0x3fd2f3=!0x0):(_0x4546a5['updateMarker'](_0x4fef06,{'range':_0x6ef82c}),_0x3fd2f3=!0x0);}return _0x3fd2f3;}),this['on']('change:isThreadsLoadingPaused',(_0x322b83,_0x1481e3,_0x591351)=>{if(!_0x591351&&_0x173436['size'])for(const _0x21c393 of _0x173436){const {id:_0x1255d3}=ft(_0x21c393);_0x173436['delete'](_0x21c393),_0x38dc29['model']['markers']['get'](_0x21c393)&&this['_handleThreadMarker'](_0x21c393,_0x1255d3);}}),this['listenTo'](_0x38dc29['model']['document'],'change',()=>{for(const {name:_0x4da293,data:{newRange:_0x21ae77}}of _0x38dc29['model']['document']['differ']['getChangedMarkers']()){const {group:_0x13acba,id:_0x1a894d}=ft(_0x4da293);if('comment'!==_0x13acba)continue;const _0x607047=_0x322374['getCommentThread'](_0x1a894d),_0x2af6bf=this['hasMarkerForId'](_0x1a894d);_0x607047&&(!_0x607047['_hasTargetInContent']&&_0x21ae77&&_0x38dc29['editing']['view']['once']('render',()=>{const _0x49e1bf=_0x38dc29['plugins']['get'](y),_0x437cc4=_0x322374['_threadToController']['get'](_0x607047)['view'];_0x49e1bf['getByInnerView'](_0x437cc4)['refreshVisibility']();},{'priority':'low'}),_0x607047['_hasTargetInContent']=_0x2af6bf||!!_0x21ae77),_0x21ae77||(_0x3dafbc['add'](_0x4da293),_0x173436['delete'](_0x4da293));}for(const _0x44b002 of _0x3dafbc){const {id:_0x485ef2}=ft(_0x44b002),_0x2ccbbf=_0x322374['getCommentThread'](_0x485ef2);if(_0x173436['delete'](_0x44b002),!_0x2ccbbf)continue;const _0x5106c5=this['hasMarkerForId'](_0x485ef2);_0x5106c5||_0x2ccbbf['isSubmitted']?_0x5106c5||_0x2ccbbf['unlinkedAt']||_0x2ccbbf['setUnlinkedAt'](new Date()):_0x2ccbbf['remove']();}_0x3dafbc['clear']();});}['_handleInitialThreads'](_0x4a15b4){_0x4a15b4['forEach'](_0x5b4a7e=>{_0x5b4a7e['unlinkedAt']&&this['_attachArchivedThread'](_0x5b4a7e['id']);});}['_getTargetForId'](_0xc4cddc){const _0x56745f=this['editor'],_0x45e1b2=this['getAllMarkersForId'](_0xc4cddc);return et(_0x56745f['editing'],_0x45e1b2);}['_getTextContext'](_0x1817c0){const _0x45c680=this['getAllMarkersForId'](_0x1817c0);let _0x57bae3='',_0x124af5=!0x1;for(const _0x3c936b of _0x45c680){const _0x121ef5=_0x3c936b['getRange']();for(const _0x21d3bb of Array['from'](_0x121ef5['getItems']()))_0x21d3bb['is']('$textProxy')?(_0x57bae3&&_0x124af5&&(_0x57bae3+='\x20',_0x124af5=!0x1),_0x57bae3+=_0x21d3bb['data']):_0x124af5=!0x0;_0x124af5=!0x0;}return _0x57bae3['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x50c633,_0x7b1c52){const _0x74c566=this['editor'],_0x21ec41=_0x74c566['plugins']['get'](o);let _0x25b300=_0x21ec41['getCommentThread'](_0x7b1c52);const _0x371872=_0x74c566['config']['get']('collaboration.channelId'),_0x343788=_0x74c566['plugins']['get'](b);if(_0x25b300&&(_0x25b300['unlinkedAt']&&_0x25b300['setUnlinkedAt'](null),_0x25b300['isAttached']))return _0x25b300;return!this['getAllMarkersForId'](_0x7b1c52)[0x0]['managedUsingOperations']?_0x74c566['editing']['view']['once']('render',()=>{if(_0x21ec41['getCommentThread'](_0x7b1c52))return;const _0x45b298=_0x74c566['plugins']['get'](y);_0x25b300=_0x21ec41['openNewCommentThread']({'channelId':_0x371872,'threadId':_0x7b1c52,'target':()=>this['_getTargetForId'](_0x7b1c52),'context':{'type':'text','value':this['_getTextContext'](_0x7b1c52)}});const _0xd8035d=_0x21ec41['_threadToController']['get'](_0x25b300)['view'],_0x4b80bb=_0x45b298['getByInnerView'](_0xd8035d);_0x4b80bb&&_0x343788['registerAnnotation'](_0x4b80bb);},{'priority':'low'}):_0x21ec41['fetchCommentThread']({'channelId':_0x371872,'threadId':_0x7b1c52})['then'](_0x90f260=>{if('destroyed'!==_0x74c566['state']){if(_0x25b300=_0x90f260,_0x25b300&&!_0x25b300['isAttached']){const _0x40b6c5=_0x25b300['attachTo'](()=>this['_getTargetForId'](_0x7b1c52));_0x343788['registerAnnotation'](_0x40b6c5),_0x25b300['isResolved']&&this['_reconvertMarkers'](_0x7b1c52);}else{if(!_0x25b300){const _0x2df84c=this['getAllMarkersForId'](_0x7b1c52);_0x74c566['model']['change'](_0x5e1623=>{for(const _0x332771 of _0x2df84c)_0x5e1623['removeMarker'](_0x332771);});}}}}),_0x25b300;}['_handleThreadMarker'](_0x4a848f,_0x3832e2){const _0x1302bf=this['_attachMarkerToThread'](_0x4a848f,_0x3832e2);_0x1302bf&&!_0x1302bf['context']&&_0x1302bf['setContext']({'type':'text','value':this['_getTextContext'](_0x3832e2)});}['_initAriaMarkerChangeAnnouncements'](){const _0xddea94=this['editor'];rt(_0xddea94['model'],({left:_0x578312,entered:_0x3137a2})=>{for(const _0x4117fc of _0x578312)if(mt(_0x4117fc)){_0xddea94['ui']['ariaLiveAnnouncer']['announce'](N(_0xddea94['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x452749 of _0x3137a2)if(mt(_0x452749)){_0xddea94['ui']['ariaLiveAnnouncer']['announce'](N(_0xddea94['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x527b7d)));break;}});}}function dt(_0xe343d8,_0xce643e){return _0xce643e?_0xe343d8+':'+_0xce643e:_0xe343d8;}function ht(_0x103b2b,_0x543d7d){const _0x5e86f6=_0x543d7d['schema'],_0x23fb42=_0x543d7d['createRange'](_0x103b2b['start']);for(const _0x1f3b76 of _0x103b2b['getWalker']()){const {type:_0x28b09f,item:_0x54f95f,nextPosition:_0x490b39}=_0x1f3b76;if('text'===_0x28b09f||_0x5e86f6['isObject'](_0x54f95f)){const _0x2bb3fa=_0x543d7d['createPositionBefore'](_0x54f95f);_0x23fb42['isCollapsed']&&(_0x23fb42['start']=_0x2bb3fa),_0x23fb42['end']=_0x490b39;}}return _0x23fb42;}function mt(_0x30f556){return'comment'===ft(_0x30f556['name'])['group'];}class s extends _0x2525e1{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,r,b,y];}get['CommentsListView'](){return te;}get['CommentThreadInputView'](){return ie;}['init'](){const _0x48079d=this['editor'],_0x1d5061=_0x48079d['plugins']['get'](o),_0x41e522=_0x48079d['plugins']['get'](r),_0x2441b8=_0x48079d['plugins']['get'](y),_0x59d5c1=_0x48079d['plugins']['get'](b);_0x48079d['ui']['componentFactory']['add']('comment',()=>{const _0x13e135=this['_createUIButton'](_0x51cbda);return _0x13e135['tooltip']=!0x0,_0x13e135;}),_0x48079d['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x18ac0a)),_0x59d5c1['addSourceCollector'](()=>{const _0x387924=[];for(const [_0x2a64c0,_0x3d9968]of _0x1d5061['_threadToController']){const _0x134b44=_0x41e522['getAllMarkersForId'](_0x2a64c0['id']),_0x140040=_0x134b44['map'](_0xe7edb5=>_0xe7edb5['getRange']());_0x134b44['length']>0x0&&_0x387924['push']([_0x3d9968['view'],_0x140040]);}return _0x387924;}),this['listenTo'](_0x2441b8,'change:activeAnnotations',(_0x10bda4,_0x4ff625,_0x1ddc6c)=>{const _0x38b0c9=Array['from'](_0x1ddc6c)['map'](_0xbf3fb6=>_0xbf3fb6['innerView'])['find'](_0x2997a0=>_0x1d5061['_viewToController']['has'](_0x2997a0));if(!_0x38b0c9)return void(_0x41e522['activeMarker']=null);const _0x3f1686=_0x1d5061['_viewToController']['get'](_0x38b0c9)['model']['id'],_0x269601='comment:'+_0x3f1686;_0x3f1686&&_0x41e522['hasMarkerForId'](_0x3f1686)?_0x41e522['activeMarker']=_0x269601:_0x41e522['activeMarker']&&(_0x41e522['activeMarker']=null);}),this['listenTo'](_0x1d5061,'removeCommentThread',(_0x40e9ba,{threadId:_0x1965be,isFromAdapter:_0xf4dad3})=>{!_0xf4dad3&&_0x48079d['ui']['focusTracker']['isFocused']&&_0x41e522['hasMarkerForId'](_0x1965be)&&_0x48079d['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x1d5061,'addComment',(_0x90051c,{threadId:_0x4503e0,isFromAdapter:_0x4b0392})=>{if(_0x4b0392||!_0x41e522['hasMarkerForId'](_0x4503e0)||!_0x1d5061['hasCommentThread'](_0x4503e0))return;0x1===_0x1d5061['getCommentThread'](_0x4503e0)['length']&&(_0x48079d['editing']['view']['focus'](),_0x90051c['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x16175b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0xb6089b;for(const _0x42a36b in _0x16175b){const _0x411ad6=_0x42a36b,_0x29d313=_0x16175b[_0x411ad6];if('commentsLicenseKeyValid'==_0x29d313||'commentsLicenseKeyInvalid'==_0x29d313||'commentsLicenseKeyExpired'==_0x29d313||'commentsLicenseKeyDomainLimit'==_0x29d313||'commentsLicenseKeyNotAllowed'==_0x29d313||'commentsLicenseKeyEvaluationLimit'==_0x29d313||'commentsLicenseKeyUsageLimit'==_0x29d313){delete _0x16175b[_0x411ad6],_0xb6089b=_0x29d313,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0xb6089b&&_0x16175b['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0xb6089b&&_0x16175b['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0xb6089b&&_0x16175b['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0xb6089b&&_0x16175b['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0xb6089b&&_0x16175b['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyUsageLimit'==_0xb6089b&&_0x16175b['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x5183bc){const _0x5d1d5a=this['editor'],_0x1e9403=new _0x5183bc(_0x5d1d5a['locale']),_0x4c8749=_0x5d1d5a['commands']['get']('addCommentThread');return _0x1e9403['set']({'label':N(_0x5d1d5a['locale'],'Comment'),'icon':_0x12547c}),_0x1e9403['bind']('isEnabled')['to'](_0x4c8749,'isEnabled',_0x4c8749,'hasContent',(_0x5b44db,_0x13af6e)=>_0x5b44db&&_0x13af6e),this['listenTo'](_0x1e9403,'execute',()=>{_0x4c8749['execute']();}),_0x1e9403;}}class i extends _0x2525e1{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x55682c){super(_0x55682c),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x2260fc,_0xeb6ef4,_0x547565)=>{_0x547565?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x6eafb2,_0x181228]of this['editor']['commands'])_0x181228['affectsData']&&'addCommentThread'!==_0x6eafb2&&_0x181228['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('RevisionTracker'))&&this['editor']['plugins']['get']('RevisionTracker')['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x1e5bca=this['editor']['editing']['view']['document'];this['listenTo'](_0x1e5bca,'cut',_0x38527f=>_0x38527f['stop'](),{'priority':'highest'}),this['listenTo'](_0x1e5bca,'clipboardInput',_0x144da7=>_0x144da7['stop'](),{'priority':'highest'}),this['listenTo'](_0x1e5bca,'delete',_0x18f63d=>_0x18f63d['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x393367,_0x459838]of this['editor']['commands'])_0x459838['affectsData']&&'addCommentThread'!==_0x393367&&_0x459838['clearForceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['clearForceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['clearForceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['clearForceDisabled']('commentsOnlyMode'),this['stopListening'](this['editor']['editing']['view']['document']);}}class j extends _0x3905cc{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3380a3){super(_0x3380a3),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x7b3355=this['context']['plugins']['get'](y);this['listenTo'](_0x7b3355,'_activateAnnotation',(_0x2ccab0,_0x53951f)=>{for(const _0x321136 of this['activeUIs']){const _0x2c73f9=this['_uis']['get'](_0x321136);(0x0,this['uisData']['get'](_0x321136)['filter'])(_0x53951f)&&_0x2c73f9['setActiveAnnotation'](_0x53951f);}}),this['listenTo'](_0x7b3355,'_deactivateAllAnnotations',()=>{for(const _0x54b180 of this['activeUIs']){this['_uis']['get'](_0x54b180)['setActiveAnnotation'](null);}}),this['listenTo'](_0x7b3355['_visibleAnnotations'],'add',(_0x105032,_0x291c3e)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x291c3e);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x5e8a16){return this['activeUIs']['has'](_0x5e8a16);}['activate'](_0x1b1789,_0x174fdf=this['defaultFilter']){const _0x2ba509=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x1b1789))throw new _0x365e72('annotationsuis-missing-ui',this,{'uiName':_0x1b1789});this['isActive'](_0x1b1789)&&this['deactivate'](_0x1b1789),this['activeUIs']['add'](_0x1b1789);const _0x306885=new S();v({'source':_0x2ba509['_visibleAnnotations'],'target':_0x306885,'filter':_0x174fdf}),this['uisData']['set'](_0x1b1789,{'collection':_0x306885,'filter':_0x174fdf});const _0x4f645b=this['_uis']['get'](_0x1b1789);_0x4f645b['attach'](_0x306885),this['listenTo'](_0x4f645b,'change:activeAnnotation',(_0x49e977,_0x310990,_0x2b17e1,_0x5cb09e)=>{_0x5cb09e&&_0x2ba509['_removeActiveAnnotation'](_0x5cb09e),_0x2b17e1&&_0x2ba509['_addActiveAnnotation'](_0x2b17e1);});}['deactivate'](_0x5c9eec){if(this['activeUIs']['delete'](_0x5c9eec),!this['_uis']['has'](_0x5c9eec))throw new _0x365e72('annotationsuis-missing-ui',this,{'uiName':_0x5c9eec});const _0x531aa3=this['_uis']['get'](_0x5c9eec);_0x531aa3['detach'](),this['stopListening'](_0x531aa3),this['uisData']['get'](_0x5c9eec)['collection']['destroy'](),this['uisData']['delete'](_0x5c9eec);}['switchTo'](_0x429789){if(!this['_uis']['has'](_0x429789))throw new _0x365e72('annotationsuis-missing-ui',this,{'uiName':_0x429789});const _0x568047=this['context']['plugins']['get'](y),_0x5cbeef=Array['from'](_0x568047['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x429789);const _0x3e3e5f=this['_uis']['get'](_0x429789);_0x3e3e5f['setActiveAnnotation'](_0x5cbeef),_0x3e3e5f['_setSelectedAnnotations']&&_0x5cbeef&&_0x3e3e5f['_setSelectedAnnotations']([_0x5cbeef]);}['deactivateAll'](){for(const _0x35589b of this['activeUIs'])this['deactivate'](_0x35589b);}['register'](_0x38f208,_0x2908a2){if(this['_uis']['has'](_0x38f208))throw new _0x365e72('annotationsuis-register-already-registered');if('function'!=typeof _0x2908a2['attach']||'function'!=typeof _0x2908a2['detach']||'function'!=typeof _0x2908a2['setActiveAnnotation'])throw new _0x365e72('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x38f208,_0x2908a2);}['refilterAnnotations'](){const _0x297219=this['context']['plugins']['get'](y)['collection'],_0x1ed8ec=new Map(),_0x1eacdb=Array['from'](this['activeUIs']);for(const _0x2f1cec of this['activeUIs']){const _0x3ea611=this['uisData']['get'](_0x2f1cec)['collection'];for(const _0x1f4e10 of _0x3ea611)_0x1ed8ec['set'](_0x1f4e10,_0x2f1cec);}for(const _0x3de77d of _0x297219){const _0xd993b8=_0x1ed8ec['get'](_0x3de77d);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x3de77d);const _0x228427=_0x1eacdb['find'](_0x54e8b0=>this['uisData']['get'](_0x54e8b0)['filter'](_0x3de77d));_0xd993b8!==_0x228427&&(_0xd993b8&&this['uisData']['get'](_0xd993b8)['collection']['remove'](_0x3de77d),_0x228427&&this['uisData']['get'](_0x228427)['collection']['add'](_0x3de77d));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x2d30f9){const _0x4e0a68=[];for(const _0x4938e4 of this['activeUIs']){(0x0,this['uisData']['get'](_0x4938e4)['filter'])(_0x2d30f9)&&_0x4e0a68['push'](_0x4938e4);}if(_0x4e0a68['length']>0x1)throw new _0x365e72('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x4e0a68,'annotationType':_0x2d30f9['type']});}}const _i=/* #__PURE__ -- @preserve */
32
- Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x540237){super(_0x540237);const _0x3c9fef=this['bindTemplate'];this['set']('minHeight',0x0),this['set']('class',''),this['list']=this['createCollection'](),this['focusables']=this['createCollection'](),this['list']['delegate']('arrowup','arrowdown')['to'](this),this['focusTracker']=new _0x3ab247(),this['focusCycler']=new _0xab0a02({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x3c9fef['to']('class')],'style':{'minHeight':_0x3c9fef['to']('minHeight',_0x2fe807=>'number'==typeof _0x2fe807?_i(_0x2fe807+0xa):null)},'dir':_0x540237['uiLanguageDirection'],'role':'application','aria-label':N(_0x540237,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x540237,'Annotations\x20list')},'children':this['list']}]});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['focus'](){this['focusCycler']['focusFirst']();}['_setupKeyboardNavigation'](){this['list']['delegate']('change:top')['to'](this),this['on']('change:top',_0x273891=>{this['_updateItemPositionInFocusables'](_0x273891['source']);}),this['list']['forEach'](_0x2e3756=>{this['focusTracker']['add'](_0x2e3756['element']),this['_updateItemPositionInFocusables'](_0x2e3756);}),this['list']['on']('change',(_0x575e48,_0x5916f8)=>{for(const _0x591d03 of _0x5916f8['removed'])this['focusTracker']['remove'](_0x591d03['element']),this['focusables']['remove'](_0x591d03);for(const _0xc896fc of _0x5916f8['added'])this['focusTracker']['add'](_0xc896fc['element']),this['_updateItemPositionInFocusables'](_0xc896fc);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x37833a){const _0x54a9b0=this['focusables']['getIndex'](_0x37833a);let _0x3172cf,_0x30b81d;for(const _0x5253b8 of this['focusables'])if(_0x37833a['top']<_0x5253b8['top']){_0x3172cf=_0x5253b8;break;}if(_0x30b81d=_0x3172cf?this['focusables']['getIndex'](_0x3172cf):this['focusables']['length'],-0x1!==_0x54a9b0){if(_0x54a9b0===_0x30b81d-0x1)return;this['focusables']['remove'](_0x37833a),_0x30b81d=_0x3172cf?this['focusables']['getIndex'](_0x3172cf):this['focusables']['length'];}this['focusables']['add'](_0x37833a,_0x30b81d);}}const Ot=/* #__PURE__ -- @preserve */
33
- Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x2cf1e6){super(_0x2cf1e6),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x4ed28b,_0x2e971d)=>_0x4ed28b+_0x2e971d),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x55365e=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x55365e['to']('isAnimationDisabled',_0x19aeb9=>_0x19aeb9?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x55365e['to']('top',_0x43c622=>Ot(_0x43c622))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x491d12=this['element']['clientHeight'];_0x491d12&&(this['height']=_0x491d12);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x3905cc{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x250fb4){super(_0x250fb4),this['set']('_lastItem',void 0x0),this['view']=this['_createSidebarView'](),this['set']('container',null),this['_spaceBetweenItems']=0x19,this['_sidebarItemViewToAnnotation']=new Map(),this['_annotationToSidebarItemView']=new Map(),this['context']['config']['define']('sidebar.preventScrollOutOfView',!0x1),this['_annotations']=null,this['_activeAnnotation']=null,this['_recalculateBuffer']=[];}['init'](){const _0x50f9ed=this['context']['config']['get']('sidebar.container');_0x50f9ed&&this['setContainer'](_0x50f9ed);}['setContainer'](_0x2d1051){if(!g(_0x2d1051))throw new _0x365e72('sidebar-setcontainer-invalid-element');this['container']=_0x2d1051;}['_attachToContainer']({viewClass:_0x5d1d4c='',spaceBetweenItems:_0x3194de=0x19}={}){if(!g(this['container']))throw new _0x365e72('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x5d1d4c,this['_spaceBetweenItems']=_0x3194de;}['rearrange']({removedAnnotation:_0xd45b23,previousAnnotation:_0x5b3d84,nextAnnotation:_0x1452bc}){const _0x103412=this['getSidebarItemView'](_0xd45b23);this['view']['list']['remove'](_0x103412),this['_destroySidebarItemView'](_0xd45b23),_0x5b3d84&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x5b3d84)),_0x1452bc&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x1452bc)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0xe78b3b,activatedAnnotation:_0x2945ef,disableAnimationOnActivatedAnnotation:_0xdf127b}){if(this['_activeAnnotation']=_0x2945ef,_0xe78b3b){_0xe78b3b['isActive']=!0x1;const _0x285e03=this['getSidebarItemView'](_0xe78b3b);_0x285e03&&_0xdf127b&&(_0x285e03['isAnimationDisabled']=!0x1);}if(_0x2945ef){const _0x316d10=this['getSidebarItemView'](_0x2945ef);_0x316d10&&(_0x2945ef['isActive']=!0x0,_0xdf127b&&(_0x316d10['isAnimationDisabled']=!0x0,_0x316d10['top']+=0x1),this['_alignToTargetRect'](_0x316d10));}}['_detachFromContainer'](_0x1be145){if(this['view']['element']['remove'](),_0x1be145){for(const _0x117ab5 of _0x1be145)this['_destroySidebarItemView'](_0x117ab5);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x4f3198,_0x3f0e68){_0x3f0e68||(_0x3f0e68=_0x4f3198['view']);const _0x4c10d8=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x4c10d8,_0x4f3198),this['_annotationToSidebarItemView']['set'](_0x4f3198,_0x4c10d8),_0x4c10d8['content']['add'](_0x3f0e68),this['listenTo'](_0x4f3198['view'],'change:targetRect',(_0xa56ba1,_0x3c2759,_0x469d01)=>{const _0x4542b3=this['_getTargetTop'](_0x4f3198,_0x469d01);_0x4c10d8['_targetTop']!=_0x4542b3&&(_0x4c10d8['_targetTop']=_0x4542b3,this['_setItemTop'](_0x4c10d8,_0x4542b3));}),this['listenTo'](_0x4c10d8,'change:top',()=>{this['_recalculate'](_0x4c10d8,'top');}),this['listenTo'](_0x4c10d8,'change:bottom',()=>{this['_recalculate'](_0x4c10d8,'bottom');}),this['_alignToTargetRect'](_0x4c10d8);const _0x2adec9=this['_getItemBefore'](_0x4c10d8);if(_0x2adec9)this['_alignAfterItem'](_0x2adec9,_0x4c10d8)||this['_alignToTargetRect'](_0x4c10d8);else this['_alignToTargetRect'](_0x4c10d8);return this['_updateLastItem'](),this['view']['list']['add'](_0x4c10d8),_0x4c10d8;}['_alignForTopChange'](_0x2ed0f4){if(!_0x2ed0f4['content']['length'])return;const _0x19da5c=this['_getItemBefore'](_0x2ed0f4);if(!_0x19da5c)return;const _0xf7e6ec=this['_sidebarItemViewToAnnotation']['get'](_0x19da5c),_0x1de547=this['_activeAnnotation'];_0x1de547&&_0x1de547===_0xf7e6ec?this['_alignAfterItem'](_0x19da5c,_0x2ed0f4):this['_alignBeforeItem'](_0x2ed0f4,_0x19da5c);}['_alignForBottomChange'](_0xc3fca3){if(!_0xc3fca3['content']['length'])return;const _0xc8b217=this['_getItemAfter'](_0xc3fca3);if(!_0xc8b217)return;const _0x37b38e=this['_sidebarItemViewToAnnotation']['get'](_0xc8b217),_0x3889e5=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x4702db=this['_activeAnnotation'];_0x4702db&&_0x4702db===_0x37b38e&&_0x3889e5?(this['_alignBeforeItem'](_0xc8b217,_0xc3fca3),this['_alignAfterItem'](_0xc3fca3,_0xc8b217)):_0x4702db&&_0x4702db===_0x37b38e?this['_alignBeforeItem'](_0xc8b217,_0xc3fca3):this['_alignAfterItem'](_0xc3fca3,_0xc8b217);}['_recalculate'](_0x1419dd,_0x10b9ce){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x3ae260,changedProp:_0xceed2e}of this['_recalculateBuffer'])'top'===_0xceed2e?this['_alignForTopChange'](_0x3ae260):this['_alignForBottomChange'](_0x3ae260);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x1419dd,'changedProp':_0x10b9ce});}['getSidebarItemView'](_0x2cd71a){return this['_annotationToSidebarItemView']['get'](_0x2cd71a);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x1f67c9){const _0x29c9a6=this['getSidebarItemView'](_0x1f67c9);this['stopListening'](_0x29c9a6),this['stopListening'](_0x1f67c9['view']),_0x29c9a6['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x1f67c9),this['_sidebarItemViewToAnnotation']['delete'](_0x29c9a6);}['_createSidebarView'](){const _0x522301=new H(this['context']['locale']);return _0x522301['render'](),this['on']('change:_lastItem',(_0x5b15ab,_0xd1bc3c,_0x10e293,_0x3d5719)=>{_0x3d5719&&_0x522301['unbind']('minHeight'),_0x10e293?_0x522301['bind']('minHeight')['to'](_0x10e293,'bottom'):_0x522301['minHeight']=null;}),_0x522301;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x41beea){const _0xe02562=this['_sidebarItemViewToAnnotation']['get'](_0x41beea),_0x6bf41=_0xe02562&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0xe02562)-0x1);return _0x6bf41&&this['getSidebarItemView'](_0x6bf41)||null;}['_getItemAfter'](_0x4b346e){const _0x3a6865=this['_sidebarItemViewToAnnotation']['get'](_0x4b346e),_0x212e21=_0x3a6865&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x3a6865)+0x1);return _0x212e21&&this['getSidebarItemView'](_0x212e21)||null;}['_alignBeforeItem'](_0x3aac2c,_0x26c6fc){_0x3aac2c['updateHeight']();const _0x515527=G(_0x26c6fc['bottom']+this['_spaceBetweenItems'],_0x3aac2c['top']);return!!_0x515527&&(this['_setItemTop'](_0x26c6fc,_0x26c6fc['top']-_0x515527),!0x0);}['_alignAfterItem'](_0x5c42b4,_0x26b534){_0x5c42b4['updateHeight']();const _0x23ca4d=G(_0x5c42b4['bottom']+this['_spaceBetweenItems'],_0x26b534['top']);return!!_0x23ca4d&&(this['_setItemTop'](_0x26b534,_0x26b534['top']+_0x23ca4d,!0x1),!0x0);}['_alignToTargetRect'](_0x31de23){const _0x2fcdfd=this['_sidebarItemViewToAnnotation']['get'](_0x31de23);if(!_0x2fcdfd||!_0x2fcdfd['target']||!_0x2fcdfd['targetRect'])return;const _0x1170a0=this['_getTargetTop'](_0x2fcdfd,_0x2fcdfd['targetRect']);this['_setItemTop'](_0x31de23,_0x1170a0);}['_getTargetTop'](_0x4f033a,_0x568a28){if(null===_0x568a28)return 0x0;if(_0x4f033a['target']instanceof _0x1c0a3f)return _0x568a28['top'];{const _0x14c76d=new _0x1c0a3f(this['view']['element'])['top'];return _0x568a28['top']-_0x14c76d;}}['_setItemTop'](_0x52e827,_0x8b70be,_0x45e780=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x45e780&&(_0x8b70be=Math['max'](_0x8b70be,this['_getMaxAvailableTop'](_0x52e827))),_0x52e827['top']=_0x8b70be;}['_getMaxAvailableTop'](_0x384fd6){let _0x399493=this['_getItemBefore'](_0x384fd6),_0x410eeb=0x0;for(;_0x399493;)_0x399493['updateHeight'](),_0x410eeb+=this['_spaceBetweenItems']+_0x399493['height'],_0x399493=this['_getItemBefore'](_0x399493);return _0x410eeb;}}function G(_0x8c497d,_0x2d30f7){return Math['max'](_0x8c497d-_0x2d30f7,0x0);}function g(_0x46f172){return null!==_0x46f172&&'object'==typeof _0x46f172&&0x1===_0x46f172['nodeType'];}class e extends _0x3905cc{['isAttached'];['annotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,j];}static get['pluginName'](){return'WideSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x16c398){super(_0x16c398),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x3a23ae(),this['_refreshPositioningDebounced']=_0xd7f4fb(()=>{_0x16c398['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x2974ac=this['context']['plugins']['get'](j),_0x48d72e=this['context']['plugins']['get'](z);_0x2974ac['register']('wideSidebar',this),_0x48d72e['container']&&_0x2974ac['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x3e3697){if(_0x3e3697===this['activeAnnotation'])return;const _0x2992a0=this['context']['plugins']['get'](z);_0x2992a0['_activeAnnotation']=_0x3e3697;const _0x2e56bc=this['activeAnnotation'];_0x2992a0['refresh']({'blurredAnnotation':_0x2e56bc,'activatedAnnotation':_0x3e3697}),this['activeAnnotation']=_0x3e3697;}['attach'](_0x2bdb48){this['annotations']=_0x2bdb48;const _0x238c41=this['context']['plugins']['get'](z);if(_0x238c41['_annotations']=_0x2bdb48,this['isAttached'])throw new _0x365e72('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x238c41,'set:container',()=>{this['detach'](),this['listenTo'](_0x238c41,'change:container',_0x324efc=>{_0x324efc['off'](),this['attach'](_0x2bdb48);});}),_0x238c41['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x79ed2e=_0x4868d7=>{_0x4868d7['updateTargetRect'](),_0x238c41['addAnnotation'](_0x4868d7);};for(const _0x1697e6 of _0x2bdb48)_0x79ed2e(_0x1697e6);this['listenTo'](_0x2bdb48,'add',(_0x59cf53,_0x495c2f)=>{_0x79ed2e(_0x495c2f);}),this['listenTo'](_0x2bdb48,'remove',(_0x443155,_0x284c35,_0x5ade59)=>{_0x238c41['rearrange']({'removedAnnotation':_0x284c35,'previousAnnotation':_0x2bdb48['get'](_0x5ade59-0x1),'nextAnnotation':_0x2bdb48['get'](_0x5ade59+0x1)}),_0x284c35===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x2bdb48,'focus',(_0x42419e,_0x1ea5cf)=>{this['setActiveAnnotation'](_0x1ea5cf);}),this['listenTo'](_0x2bdb48,'blur',()=>{this['setActiveAnnotation'](null);});const _0x4a1412=this['context']instanceof _0x5337ad?this['context']['editors']:new _0x3a23ae([this['context']]);for(const _0xcda141 of _0x4a1412)this['_integrateWithEditorAnnotations'](_0xcda141);this['listenTo'](_0x4a1412,'add',(_0x2a31ab,_0x469bb4)=>{this['listenTo'](_0x469bb4,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x469bb4);});}),this['listenTo'](_0x4a1412,'remove',(_0x2ef3c6,_0x3822a4)=>{_0x3822a4['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x3822a4['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x365e72('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x281dde=this['context']['plugins']['get'](z);_0x281dde['_detachFromContainer'](this['annotations']),this['stopListening'](_0x281dde),this['stopListening'](this['annotations']),this['context']instanceof _0x5337ad&&this['stopListening'](this['context']['editors']);for(const _0x303936 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x303936);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x22901b){if(!_0x22901b['plugins']['has']('EditorAnnotations'))return;const _0x2041ab=_0x22901b['plugins']['get']('EditorAnnotations'),_0x68aa9e=()=>{const _0x50823a=_0x2041ab['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x50823a[0x0]||null);};this['listenTo'](_0x2041ab,'refresh',_0x68aa9e),this['listenTo'](_0x2041ab,'blur',(_0x42ad3f,{isAnnotationTracked:_0x49070e})=>{this['activeAnnotation']&&_0x49070e(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x2041ab,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0xee9d7e=>{_0x2041ab['hasDomSelection']()&&(_0x68aa9e(),_0xee9d7e['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x2041ab);}['_destroyEditorAnnotationsIntegration'](_0x3890a0){this['stopListening'](_0x3890a0),this['_editorAnnotations']['remove'](_0x3890a0);}}class C extends _0x51cbda{['counterView'];constructor(_0x1acf4f){super(_0x1acf4f);const _0x1c9953=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x1004e4,_0x23ab1c)=>_0x1004e4?'...':_0x23ab1c['toString']()),this['set']('annotationType',''),this['icon']=_0x12547c,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x1c9953['to']('annotationType',_0x21eed6=>'ck-annotation-counter__badge--'+_0x21eed6),_0x1c9953['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x1c9953['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x3905cc{['isAttached'];['annotations'];['_manuallyClosedAnnotationViews'];['_domEmitter'];['_annotationToNarrowView'];['_selectedAnnotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,j];}static get['pluginName'](){return'NarrowSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2e7b4b){super(_0x2e7b4b),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x2a9e11())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x3a23ae(),this['_refreshPositioningDebounced']=_0xd7f4fb(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x5b6aa6(this['context']['locale']),this['balloonPanelView']=new _0x239d17(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x267a11){this['annotations']=_0x267a11;const _0x2c010f=this['context']['plugins']['get'](z),_0x5af835=this['balloonPanelView'];if(_0x2c010f['_annotations']=_0x267a11,this['isAttached'])throw new _0x365e72('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x2c010f,'set:container',()=>{this['detach'](),this['listenTo'](_0x2c010f,'change:container',_0x57c9a2=>{_0x57c9a2['off'](),this['attach'](_0x267a11);});}),_0x2c010f['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x1deced=_0x512449=>{const _0x303ec4=new C(this['context']['locale']);_0x2c010f['addAnnotation'](_0x512449,_0x303ec4),this['_annotationToNarrowView']['set'](_0x512449,_0x303ec4),_0x303ec4['bind']('isDirty','annotationType','number')['to'](_0x512449['view'],'isDirty','type','length'),_0x303ec4['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x5af835['content']['first']!==_0x512449['view']?(this['_showBalloon'](_0x512449),_0x512449['view']['element']['focus'](),this['setActiveAnnotation'](_0x512449)):this['setActiveAnnotation'](null);});};for(const _0x492b48 of _0x267a11)_0x1deced(_0x492b48);this['listenTo'](_0x267a11,'add',(_0x5a90dc,_0x4046e0)=>{_0x1deced(_0x4046e0);}),this['listenTo'](_0x267a11,'remove',(_0x3fb72f,_0x2acdac,_0x1da9f3)=>{this['_annotationToNarrowView']['get'](_0x2acdac)['destroy'](),this['_annotationToNarrowView']['delete'](_0x2acdac),_0x2c010f['rearrange']({'removedAnnotation':_0x2acdac,'previousAnnotation':_0x267a11['get'](_0x1da9f3-0x1),'nextAnnotation':_0x267a11['get'](_0x1da9f3+0x1)}),_0x2acdac===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x267a11,'focus',(_0x2e7731,_0x4b7739)=>{this['setActiveAnnotation'](_0x4b7739);}),this['listenTo'](_0x267a11,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x2313fd,_0xf734d2)=>{_0xf734d2['keyCode']===_0xb3a348['esc']&&_0x5af835['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x5af835['content']['first']),this['_hideBalloon'](),_0xf734d2['stopPropagation'](),_0xf734d2['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x5dfcc4,_0x18ddfd)=>{const _0x2c29cf=_0x18ddfd['target'];_0x5af835['isVisible']&&_0x5af835['element']['contains'](_0x2c29cf)||_0x2c010f['view']['element']['contains'](_0x2c29cf)||_0x5dfcc4['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x5bb0cb=>_0x5bb0cb['contains'](_0x2c29cf))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x369cac=this['context']instanceof _0x5337ad?this['context']['editors']:new _0x3a23ae([this['context']]);for(const _0x9a70b5 of _0x369cac)this['_integrateWithEditorAnnotations'](_0x9a70b5);this['listenTo'](_0x369cac,'add',(_0x2f2625,_0x3df641)=>{this['listenTo'](_0x3df641,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x3df641);});}),this['listenTo'](_0x369cac,'remove',(_0x5be885,_0x249364)=>{_0x249364['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x249364['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x58358c){if(_0x58358c===this['activeAnnotation'])return;const _0x36de64=this['context']['plugins']['get'](z);if(_0x36de64['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x58358c,'disableAnimationOnActivatedAnnotation':!0x0}),_0x58358c)_0x36de64['getSidebarItemView'](_0x58358c)?this['_showBalloon'](_0x58358c):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x58358c;}['detach'](){if(!this['isAttached'])throw new _0x365e72('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x3218c2=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x282456=>_0x282456['destroy']()),this['_annotationToNarrowView']['clear'](),_0x3218c2['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x5337ad&&this['stopListening'](this['context']['editors']);for(const _0x5e126c of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x5e126c);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['_selectedAnnotations']=[],this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['bodyCollection']['detachFromDom']();}['_integrateWithEditorAnnotations'](_0x2694cc){if(!_0x2694cc['plugins']['has']('EditorAnnotations'))return;const _0x1acc65=_0x2694cc['plugins']['get']('EditorAnnotations'),_0x21a653=this['context']['plugins']['get'](z),_0xe15128=this['annotations'],_0x4199e9=this['balloonPanelView'],_0x270b1c=()=>{const _0x418875=_0x1acc65['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x418875),this['setActiveAnnotation'](_0x418875[0x0]||null);};this['listenTo'](_0x1acc65,'refresh',_0x270b1c),this['listenTo'](_0x1acc65,'blur',(_0x10f46c,{isAnnotationTracked:_0x42ea00})=>{this['activeAnnotation']&&_0x42ea00(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x1acc65,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0xe15128,'blur',_0x1e1577=>{_0x1acc65['hasDomSelection']()&&_0x1e1577['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x164161,_0x2d1b52)=>{const _0x2a4c11=_0x2d1b52['target'];_0x4199e9['isVisible']&&_0x4199e9['element']['contains'](_0x2a4c11)||_0x21a653['view']['element']['contains'](_0x2a4c11)||this['activeAnnotation']&&_0x1acc65['hasDomSelection']()&&(_0x270b1c(),_0x164161['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x1acc65);}['_destroyEditorAnnotationsIntegration'](_0x59f83b){_0x59f83b&&(this['stopListening'](_0x59f83b),this['_editorAnnotations']['remove'](_0x59f83b));}['_setSelectedAnnotations'](_0x360ab1){for(const _0x1db8c3 of this['_selectedAnnotations'])_0x360ab1['includes'](_0x1db8c3)||this['_manuallyClosedAnnotationViews']['delete'](_0x1db8c3['view']);this['_selectedAnnotations']=_0x360ab1;}['_refreshPositioning'](){const _0x3bfc82=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x3bfc82['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x78acf7){if(this['_manuallyClosedAnnotationViews']['has'](_0x78acf7['view']))return;const _0x250881=this['balloonPanelView']['content']['first'];_0x250881!==_0x78acf7['view']?(_0x250881&&this['_detachListeners'](_0x250881),this['_attachListeners'](_0x78acf7['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x78acf7['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x26a88d=this['balloonPanelView']['content']['first'],_0x508dee=_0x26a88d&&this['annotations']['getByView'](_0x26a88d);if(!_0x508dee||!this['_annotationToNarrowView']['has'](_0x508dee))return;const _0x689627=this['_annotationToNarrowView']['get'](_0x508dee)['element'],_0x457ba2=(function(){const _0xbbbbb1=_0x239d17['defaultPositions'];return[_0xbbbbb1['southArrowNorthEast'],_0xbbbbb1['northArrowSouthEast'],_0xbbbbb1['southArrowNorth'],_0xbbbbb1['northArrowSouth'],_0xbbbbb1['southArrowNorthWest'],_0xbbbbb1['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x689627,'positions':_0x457ba2});}['_hideBalloon'](){const _0x4dd1aa=this['balloonPanelView'],_0x426227=_0x4dd1aa['content']['first'];_0x426227&&(this['_detachListeners'](_0x426227),_0x4dd1aa['unpin'](),_0x4dd1aa['content']['clear']());}['_attachListeners'](_0x20693f){this['listenTo'](_0x20693f,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x20693f,'Esc',(_0x25949d,_0x3626b7)=>{this['_manuallyClosedAnnotationViews']['add'](_0x20693f),this['_hideBalloon'](),_0x3626b7();});}['_detachListeners'](_0x245d44){this['stopListening'](_0x245d44);}}class c extends _0x2525e1{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];['_refreshVisibilityDebounced'];static get['requires'](){return[b,_0xd457bc,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xb0413d){super(_0xb0413d),_0xb0413d['editing']['view']['addObserver'](_0x3b27aa),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0xb0413d['plugins']['get'](_0xd457bc),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1,this['_refreshVisibilityDebounced']=_0xd7f4fb(()=>{this['editor']['plugins']['get']('Annotations')['refreshVisibility']();},0xfa,{'leading':!0x1});}['init'](){const _0x1c8846=this['editor']['plugins']['get'](j);_0x1c8846['context']===this['editor']&&(_0x1c8846['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x158e81,_0x50259f)=>{const _0x3a19d4=this['_balloon'];if(this['isAttached']&&_0x3a19d4['visibleView']){const _0x3e04b5=this['annotations']['getByView'](_0x3a19d4['visibleView']);_0x3e04b5&&this['_closeAnnotation'](_0x3e04b5),_0x50259f();}}));}['afterInit'](){const _0x37f708=this['editor']['plugins']['get'](j);_0x37f708['context']===this['editor']&&(_0x37f708['hasActive']()||_0x37f708['switchTo']('inline'));}['setActiveAnnotation'](_0x4a1d3f){_0x4a1d3f!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x4a1d3f&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x4a1d3f)&&this['_addAnnotationToBalloon'](_0x4a1d3f,!0x0),_0x4a1d3f['isActive']=!0x0),_0x4a1d3f||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x4a1d3f);}['attach'](_0x5ad4f9){this['annotations']=_0x5ad4f9;const _0x51b851=this['editor']['plugins']['get'](j),_0x1b1ede=this['_balloon'];if(this['isAttached'])throw new _0x365e72('inlineannotations-attach-already-attached',this);if(_0x51b851['context']!==this['editor'])throw new _0x365e72('inlineannotations-not-allowed-with-context',this);const _0x1b98c3=this['editor']['plugins']['get'](b);this['listenTo'](_0x1b98c3,'refresh',()=>{const _0x369064=_0x1b98c3['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x1a7167,_0x4a7be5;!this['_forceRefresh']&&(_0x1a7167=_0x369064,_0x4a7be5=this['_selectedAnnotations'],_0x1a7167['length']===_0x4a7be5['length']&&_0x1a7167['every'](_0xa7b104=>_0x4a7be5['includes'](_0xa7b104)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x369064),this['setActiveAnnotation'](_0x369064[0x0]||null));}),this['listenTo'](_0x1b98c3,'blur',(_0x361c27,{isAnnotationTracked:_0x1f7529})=>{this['activeAnnotation']&&_0x1f7529(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x1b98c3,'uiUpdate',()=>{this['_refreshVisibilityDebounced']();}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0xf79f61,_0xb19862,_0x3e9edf)=>{_0x3e9edf||this['setActiveAnnotation'](null);}),this['listenTo'](_0x5ad4f9,'remove',(_0x1c5bff,_0x4ca853)=>{this['_removeAnnotationFromBalloon'](_0x4ca853),_0x4ca853===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x1b1ede,'change:visibleView',(_0x463b02,_0xfa7cf3,_0x8cede1,_0x522991)=>{_0x522991&&this['stopListening'](_0x522991);const _0x1f0547=_0x5ad4f9['getByView'](_0x8cede1);_0x8cede1&&_0x1f0547&&(this['listenTo'](_0x8cede1,'change:height',()=>{_0x1b1ede['updatePosition']();}),this['listenTo'](_0x8cede1,'Esc',()=>{this['_closeAnnotation'](_0x1f0547),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x1f0547&&this['setActiveAnnotation'](_0x1f0547));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x1b1ede['visibleView']&&(_0x5ad4f9['getByView'](_0x1b1ede['visibleView'])&&_0x1b1ede['updatePosition']());}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',()=>{this['_forceRefresh']=!0x0,this['_manuallyClosed']['clear']();}),this['editor']['editing']['view']['document']['selection']['editableElement']&&this['editor']['editing']['view']['focus'](),this['isAttached']=!0x0;}['detach'](){if(!this['isAttached'])throw new _0x365e72('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x1a8b32 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x1a8b32);this['_refreshVisibilityDebounced']['cancel'](),this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['_refreshVisibilityDebounced']['cancel']();}['_setSelectedAnnotations'](_0x2c9256){for(const _0x401968 of this['_selectedAnnotations'])_0x2c9256['includes'](_0x401968)||this['_manuallyClosed']['delete'](_0x401968);for(const _0x2c081e of this['annotations'])_0x2c9256['includes'](_0x2c081e)||this['_removeAnnotationFromBalloon'](_0x2c081e);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x3776f3 of _0x2c9256)this['_addAnnotationToBalloon'](_0x3776f3);}this['_selectedAnnotations']=_0x2c9256;}['_addAnnotationToBalloon'](_0x413f9f,_0x3fb3a0=!0x1){this['_manuallyClosed']['has'](_0x413f9f)||(this['_addedAnnotations']['has'](_0x413f9f)||this['_balloon']['hasView'](_0x413f9f['view'])||(this['_addedAnnotations']['add'](_0x413f9f),this['_balloon']['add']({'stackId':_0x413f9f['view']['id'],'view':_0x413f9f['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x413f9f)}})),_0x3fb3a0&&this['_balloon']['showStack'](_0x413f9f['view']['id']));}['_getBalloonTargetForAnnotation'](_0xab966a){const _0x3f70f6=_0xab966a['target'],_0xbba8f9=this['editor']['editing']['view'],_0x24488d=_0xbba8f9['document']['selection']['getFirstRange'](),_0x14b3f9=_0xbba8f9['domConverter']['viewRangeToDom'](_0x24488d);if(_0x14b3f9['collapse'](!0x0),_0x3f70f6){if(_0x3f70f6 instanceof _0x1c0a3f)return _0x3f70f6;let _0x20367d=[];for(const _0x2ae68b of _0x3f70f6)_0x20367d['push'](...F(_0x2ae68b['getClientRects']()));_0x20367d=function(_0x496f6d){const _0x1d1c77=[];let _0xad4fc3=_0x496f6d[0x0];for(let _0xd0dea2=0x1;_0xd0dea2<_0x496f6d['length'];_0xd0dea2++)P(_0xad4fc3,_0x496f6d[_0xd0dea2])?_0xad4fc3['width']+=_0x496f6d[_0xd0dea2]['width']:(_0x1d1c77['push'](_0xad4fc3),_0xad4fc3=_0x496f6d[_0xd0dea2]);return _0x1d1c77['push'](_0xad4fc3),_0x1d1c77;}(_0x20367d);const _0x15db0=_0x14b3f9['getBoundingClientRect']();return _0x20367d['find'](_0x1f10fd=>_0x1f10fd['top']<=_0x15db0['top']&&_0x1f10fd['bottom']>=_0x15db0['bottom']&&_0x1f10fd['left']<=_0x15db0['left']&&_0x1f10fd['right']>=_0x15db0['right'])||_0x20367d[0x0];}return _0xab966a['targetRect']||_0x14b3f9;}['_removeAnnotationFromBalloon'](_0x35bc7b){this['_addedAnnotations']['has'](_0x35bc7b)&&this['_balloon']['hasView'](_0x35bc7b['view'])&&(this['_addedAnnotations']['delete'](_0x35bc7b),this['_balloon']['remove'](_0x35bc7b['view']));}['_closeAnnotation'](_0x4eba3d){this['_manuallyClosed']['add'](_0x4eba3d),this['_removeAnnotationFromBalloon'](_0x4eba3d);}}function F(_0x1dd36d){return Array['from'](_0x1dd36d)['map'](DOMRect['fromRect']);}function P(_0x2b302b,_0x1cae8b){return _0x2b302b['top']===_0x1cae8b['top']&&_0x2b302b['bottom']===_0x1cae8b['bottom']&&_0x2b302b['right']===_0x1cae8b['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x4106f3,_0x28c18e){super(_0x4106f3),this['set']('isEmpty',!_0x28c18e['length']),this['focusTracker']=new _0x3ab247(),this['_annotationViews']=_0x28c18e,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0xab0a02({'focusables':_0x28c18e,'focusTracker':this['focusTracker']}),this['listenTo'](_0x28c18e,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x28c18e,'remove',(_0x2cbdde,_0x5832f2)=>{_0x5832f2['isActive']&&this['focus'](),_0x28c18e['length']||(this['isEmpty']=!0x0);});const _0x1c77a5=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x4106f3,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x28c18e},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x1c77a5['if']('isEmpty','ck-hidden',_0x129ce6=>!_0x129ce6)]},'children':[{'text':N(_0x4106f3,'EMPTY_COMMENTS_ARCHIVE')}]}]}]});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['destroy'](){super['destroy'](),this['focusTracker']['destroy']();}['focus'](){this['focusCycler']['first']?this['focusCycler']['focusFirst']():this['element']['focus']();}['_setupKeyboardNavigation'](){for(const _0x3e0069 of this['_annotationViews'])this['focusTracker']['add'](_0x3e0069['element']);this['_annotationViews']['on']('change',(_0x4506a,{added:_0x37c62b,removed:_0x291a72})=>{for(const _0x84f558 of _0x37c62b)this['focusTracker']['add'](_0x84f558['element']);for(const _0x1358ef of _0x291a72)this['focusTracker']['remove'](_0x1358ef['element']);});}}class p extends _0x3905cc{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0xa5c8fe){super(_0xa5c8fe),this['archivedThreads']=new _0x3a23ae();}['init'](){const _0x4f1ac9=this['context'],_0x51db6d=_0x4f1ac9['plugins']['get'](o),_0x2aad10=_0x4f1ac9['plugins']['get'](y);this['listenTo'](_0x51db6d,'addCommentThread',(_0x12ae63,{threadId:_0x26a736})=>{const _0x2a84f0=_0x51db6d['getCommentThread'](_0x26a736);_0x2a84f0['archivedAt']&&this['archivedThreads']['add'](_0x2a84f0,this['_calculatePosition'](_0x2a84f0['archivedAt'])),this['listenTo'](_0x2a84f0,'change:archivedAt',(_0x267471,_0x2ed84b,_0x3406c3)=>{_0x3406c3?this['archivedThreads']['has'](_0x2a84f0)||this['archivedThreads']['add'](_0x2a84f0,this['_calculatePosition'](_0x2a84f0['archivedAt'])):this['archivedThreads']['has'](_0x2a84f0)&&this['archivedThreads']['remove'](_0x2a84f0);});}),this['listenTo'](_0x51db6d,'removeCommentThread',(_0x447db6,{threadId:_0x4b235e})=>{const _0x27c399=_0x51db6d['getCommentThread'](_0x4b235e);this['stopListening'](_0x27c399),this['archivedThreads']['has'](_0x27c399)&&this['archivedThreads']['remove'](_0x27c399);},{'priority':'highest'}),this['listenTo'](_0x2aad10['collection'],'focus',(_0x225fb8,_0x16b117)=>{_0x16b117['isVisible']||(_0x16b117['isActive']=!0x0,_0x2aad10['activate'](_0x16b117));});}['_calculatePosition'](_0x2bef5b){const _0x5e3d47=[...this['archivedThreads']]['findIndex'](_0x5adb32=>_0x5adb32['archivedAt']<_0x2bef5b);return _0x5e3d47>-0x1?_0x5e3d47:this['archivedThreads']['length'];}}class a extends _0x2525e1{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x62a5ed];}constructor(_0x297bc6){super(_0x297bc6),this['annotationViews']=new _0x189f83(),this['_pendingThreads']=[];}['init'](){const _0x105075=this['editor'],_0x5734f5=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x105075['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x51cbda,!0x0)),_0x105075['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x314f35=this['_createCommentsArchiveButton'](_0x18ac0a);return _0x314f35['set']({'role':'menuitemcheckbox'}),_0x314f35;});const _0x5a6df7=_0x105075['plugins']['get'](p),_0x3001fb=_0x105075['plugins']['get']('Annotations'),_0x332f9e=_0x105075['plugins']['get']('CommentsRepository');_0x5a6df7['archivedThreads']['forEach'](_0x2db44c=>{this['_handleNewThread'](_0x2db44c);}),this['listenTo'](_0x5a6df7['archivedThreads'],'add',(_0x583457,_0x3e5028)=>{this['_handleNewThread'](_0x3e5028);}),this['listenTo'](_0x3001fb['collection'],'add',(_0x39036e,_0x4163d5)=>{const _0x522e0e=this['_pendingThreads']['find'](_0xa217d3=>{const _0x303bf1=_0x332f9e['_threadToController']['get'](_0xa217d3);return _0x303bf1&&_0x4163d5['innerView']===_0x303bf1['view'];});if(_0x522e0e){const _0x3fe670=this['_calculatePosition'](_0x522e0e['archivedAt']);this['_addAnnotationToArchive'](_0x4163d5,_0x3fe670),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x522e0e),0x1);}}),this['listenTo'](_0x5a6df7['archivedThreads'],'remove',(_0x45c9bb,_0x299cdc)=>{const _0x2467fd=_0x105075['config']['get']('collaboration.channelId');if(!_0x2467fd||_0x299cdc['channelId']===_0x2467fd){if(this['_pendingThreads']['includes'](_0x299cdc))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x299cdc),0x1);else{const _0x48cc84=_0x332f9e['_threadToController']['get'](_0x299cdc),_0xb4b311=_0x3001fb['getByInnerView'](_0x48cc84['view']);this['annotationViews']['remove'](_0xb4b311['view']),this['stopListening'](_0xb4b311),this['stopListening'](_0xb4b311['focusableElements']);}}}),this['listenTo'](_0x3001fb['collection'],'add',(_0x10eb85,_0x22678f)=>{this['listenTo'](_0x22678f,'escape',_0x5734f5);}),this['listenTo'](_0x3001fb['collection'],'remove',(_0x34c7b2,_0x44e6a0)=>{this['stopListening'](_0x44e6a0,'escape',_0x5734f5);});}['_addAnnotationToArchive'](_0x53b569,_0x3350ed){this['listenTo'](_0x53b569,'set:isVisible',_0x1918ea=>{_0x1918ea['return']=!0x1,_0x1918ea['stop']();}),this['annotationViews']['add'](_0x53b569['view'],_0x3350ed);}['_handleNewThread'](_0x246b84){const _0x263fa9=this['editor']['plugins']['get']('CommentsRepository'),_0x2198f2=this['editor']['plugins']['get']('Annotations'),_0x43e6fc=this['editor']['config']['get']('collaboration.channelId');if(!_0x43e6fc||_0x246b84['channelId']===_0x43e6fc){const _0x41f04b=_0x263fa9['_threadToController']['get'](_0x246b84);if(!_0x41f04b)return void this['_pendingThreads']['push'](_0x246b84);const _0x371d05=this['_calculatePosition'](_0x246b84['archivedAt']),_0x1d095c=_0x2198f2['getByInnerView'](_0x41f04b['view']);_0x1d095c['isVisible']&&_0x2198f2['_visibleAnnotations']['remove'](_0x1d095c),this['_addAnnotationToArchive'](_0x1d095c,_0x371d05);}}['_calculatePosition'](_0x2d1472){const _0x16820c=this['editor']['config']['get']('collaboration.channelId'),_0x437db8=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0xc3e8b0=>_0xc3e8b0['channelId']===_0x16820c)['findIndex'](_0x481d4f=>_0x481d4f['archivedAt']<_0x2d1472);return _0x437db8<0x0||_0x437db8>this['annotationViews']['length']?this['annotationViews']['length']:_0x437db8-0x1;}['_toggleDialog'](){const _0x55a9af=this['editor'],_0x53c1b1=_0x55a9af['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x55a9af['locale'],this['annotationViews'])),'commentsArchive'===_0x53c1b1['id']?_0x53c1b1['hide']():_0x53c1b1['show']({'id':'commentsArchive','title':N(_0x55a9af['locale'],'COMMENTS_ARCHIVE'),'icon':_0x5604ad,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x2aabed['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x56711d,_0x2de5e2=!0x1){const _0x244e47=this['editor']['locale'],_0x5b0a0a=this['editor']['plugins']['get']('Dialog'),_0xf46e3e=new _0x56711d(_0x244e47);return _0xf46e3e['bind']('isEnabled')['to'](this,'isEnabled'),_0xf46e3e['bind']('isOn')['to'](_0x5b0a0a,'id',_0x2f3c45=>'commentsArchive'===_0x2f3c45),_0xf46e3e['set']({'label':N(_0x244e47,'COMMENTS_ARCHIVE'),'icon':_0x5604ad,'isToggleable':!0x0}),_0x2de5e2&&(_0xf46e3e['tooltip']=!0x0),this['listenTo'](_0xf46e3e,'execute',()=>this['_toggleDialog']()),_0xf46e3e;}['_hideDialogOnAnnotationEscape']=_0x3a1f24=>{const _0x4d3c41=_0x3a1f24['source'];if(!this['annotationViews']['has'](_0x4d3c41['view']))return;const _0x34ae71=this['editor']['plugins']['get']('Dialog');_0x34ae71['isOpen']&&'commentsArchive'===_0x34ae71['id']&&(_0x34ae71['hide'](),_0x3a1f24['stop']());};}class gi extends _0x2525e1{static get['requires'](){return[o,r,s,p,a,i,e,n,c];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{ot as AddCommentThreadCommand,T as Annotation,S as AnnotationCollection,C as AnnotationCounterButtonView,E as AnnotationView,y as Annotations,R as AnnotationsSidebarItemView,H as AnnotationsSidebarView,j as AnnotationsUIs,si as BaseCommentThreadView,di as BaseCommentView,wi as Comment,pi as CommentThread,vt as CommentThreadController,ie as CommentThreadInputView,gt as CommentThreadView,Tt as CommentView,gi as Comments,p as CommentsArchive,a as CommentsArchiveUI,r as CommentsEditing,te as CommentsListView,i as CommentsOnly,o as CommentsRepository,s as CommentsUI,b as EditorAnnotations,c as InlineAnnotations,n as NarrowSidebar,z as Sidebar,e as WideSidebar,v as bindAnnotationCollections};
23
+ import{Editor as _0x11077e,ContextPlugin as _0x2a0d5d,PendingActions as lt,Command as _0x400ce4,Plugin as _0xbebcb7,Context as _0x18cd9d}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x3d9b87,uid as _0x38f1c9,KeystrokeHandler as jt,FocusTracker as _0x49912b,diff as _0x5895cc,Collection as _0x2a090d,Rect as _0x3ab659,CKEditorError as _0x405026,first as _0x4e4912,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x354fdb,keyCodes as _0x7decd5}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x20e975,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x5d8ac5,trimHtml as ts,LateFocusDropdownButtonView as _0x1f83ac,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x1f5de0}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x2ecd68}from'es-toolkit/compat';import{IconUndo as _0x4b9f73,IconCheck as _0x2883ac,IconPencil as _0x1d2750,IconRemoveComment as _0x8ef166,IconThreeVerticalDots as _0x1d1820,IconAddComment as _0x2676b4,IconCommentsArchive as _0x3fba8a}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as $t,InlineEditableUIView as Vt,EditorUI as Ut,View as kt,FocusCycler as _0x5eb73d,ButtonView as _0x55c6d4,ViewCollection as _0x3253be,createDropdown as _0x358bf8,ListView as _0x270c6d,focusChildOnDropdownOpen as _0x1db7e5,ListItemView as _0xbff8e4,MenuBarMenuListItemButtonView as _0x28e15f,BodyCollection as _0x399258,BalloonPanelView as _0x3a5644,ContextualBalloon as _0x5d8a44,Dialog as _0x573447,DialogViewPosition as _0x1a4f5c}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as St,enableViewPlaceholder as Ft,MouseObserver as _0x5ee80d}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as qt,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as zt,ShiftEnter as Bt}from'@ckeditor/ckeditor5-enter/dist/index.js';import{SelectAll as Gt}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as Jt}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as Kt}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as Lt}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x3edcd3}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x57a79f}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
+ _0x3d9b87(){['model'];['view'];constructor(_0xb9740,_0x5a8f00){super(),this['model']=_0xb9740,this['model']['_isAttached']=!0x0,this['view']=_0x5a8f00,this['listenTo'](_0x5a8f00,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x5a8f00,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x5a8f00,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x5a8f00,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x5a8f00,'addComment',(_0x4fdf9c,_0x361066)=>this['addComment'](_0x361066)),this['listenTo'](_0x5a8f00,'updateComment',(_0x1a6a60,_0x62c08b,_0x1f2a5f)=>this['updateComment'](_0x62c08b,_0x1f2a5f)),this['listenTo'](_0x5a8f00,'removeComment',(_0x2908f4,_0x23034b)=>this['removeComment'](_0x23034b));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0xba87d3){this['model']['addComment']({'content':_0xba87d3,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x55774a,_0x3fdb01){this['model']['getComment'](_0x55774a)['update']({'content':_0x3fdb01});}['removeComment'](_0x2e9754){this['model']['getComment'](_0x2e9754)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0xd6737d,_0x4d686a,_0x202249){const t=_0xd6737d['t'];switch(_0x4d686a){case'PENDING_ACTION_COMMENT_THREAD':return t({'string':'Unsaved\x20change\x20in\x20comment\x20thread.','id':'PENDING_ACTION_COMMENT_THREAD'});case'Comment':return t('Comment');case'Reply...':return t('Reply...');case'Reply\x20to\x20reopen\x20discussion...':return t('Reply\x20to\x20reopen\x20discussion...');case'Write\x20a\x20comment...':return t('Write\x20a\x20comment...');case'Comment\x20was\x20made\x20on\x20an\x20element':return t('Comment\x20was\x20made\x20on\x20an\x20element');case'Comment\x20editor':return t('Comment\x20editor');case'Delete\x20comment\x20thread?':return t('Delete\x20comment\x20thread?');case'Delete\x20comment?':return t('Delete\x20comment?');case'Marked\x20as\x20resolved':return t('Marked\x20as\x20resolved');case'Show\x20more\x20items':return t('Show\x20more\x20items');case'Cancel':return t('Cancel');case'Edit':return t('Edit');case'Resolve':return t('Resolve');case'Reopen':return t('Reopen');case'Remove':return t('Remove');case'Reply':return t('Reply');case'Save':return t('Save');case'Annotations\x20sidebar':return t('Annotations\x20sidebar');case'Annotations\x20list':return t('Annotations\x20list');case'Thread\x20comments':return t('Thread\x20comments');case'THREAD_CONTEXT_LABEL':return t({'string':'Thread\x20context:\x20%0','id':'THREAD_CONTEXT_LABEL'},_0x202249);case'COMMENT_THREAD_LABEL':return t({'string':'Comment\x20thread\x20by\x20%1.\x20%1\x20reply.','plural':'Comment\x20thread\x20by\x20%1.\x20%0\x20replies.','id':'COMMENT_THREAD_LABEL'},_0x202249);case'COMMENT_THREAD_DESCRIPTION':return t({'string':'Press\x20Enter\x20for\x20more\x20options.\x20Press\x20Escape\x20to\x20exit.','id':'COMMENT_THREAD_DESCRIPTION'});case'COMMENT_ARIA_LABEL':return t({'string':'Comment\x20by\x20%0.\x20Created\x20on\x20%1.\x20%2.\x20%3','id':'COMMENT_ARIA_LABEL'},_0x202249);case'LEAVE_COMMENT_ANNOUNCEMENT':return t({'string':'Leaving\x20a\x20content\x20with\x20comments.','id':'LEAVE_COMMENT_ANNOUNCEMENT'});case'ENTER_COMMENT_ANNOUNCEMENT':return t({'string':'Entering\x20a\x20content\x20with\x20comments.\x20Press\x20%0\x20to\x20go\x20to\x20the\x20discussion.','id':'ENTER_COMMENT_ANNOUNCEMENT'},_0x202249);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x202249);case'TOO_LONG_COMMENT_ALERT':return t({'string':'Comment\x20content\x20is\x20too\x20long.\x20Your\x20comment\x20has\x20%0\x20characters\x20but\x20the\x20limit\x20is\x20%1\x20characters.','id':'TOO_LONG_COMMENT_ALERT'},_0x202249);case'EXTERNAL_COMMENT':return t({'string':'This\x20comment\x20comes\x20from\x20an\x20external\x20source.','id':'EXTERNAL_COMMENT'});case'EXTERNAL_IMPORT_WORD_COMMENT':return t({'string':'This\x20comment\x20comes\x20from\x20an\x20imported\x20Word\x20file.','id':'EXTERNAL_IMPORT_WORD_COMMENT'});case'EXTERNAL_AVATAR':return t({'string':'Displayed\x20author\x20name\x20comes\x20from\x20external\x20source\x20(added\x20by\x20%0)','id':'EXTERNAL_AVATAR'},_0x202249);case'EXTERNAL_IMPORT_WORD_AVATAR':return t({'string':'Displayed\x20author\x20name\x20comes\x20from\x20a\x20Word\x20document\x20imported\x20by\x20%0','id':'EXTERNAL_IMPORT_WORD_AVATAR'},_0x202249);case'COMMENTS_ARCHIVE':return t({'string':'Comments\x20archive','id':'COMMENTS_ARCHIVE'});case'EMPTY_COMMENTS_ARCHIVE':return t({'string':'There\x20are\x20no\x20archived\x20comment\x20threads.','id':'EMPTY_COMMENTS_ARCHIVE'});case'COMMENTS_ARCHIVE_LIST_LABEL':return t({'string':'List\x20of\x20comments','id':'COMMENTS_ARCHIVE_LIST_LABEL'});case'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP':return t({'string':'Keystrokes\x20for\x20interacting\x20with\x20annotation\x20threads\x20(e.g.\x20comments,\x20track\x20changes\x20suggestions)','id':'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'});case'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO':return t({'string':'Move\x20focus\x20to\x20the\x20thread\x20when\x20the\x20selection\x20is\x20anchored\x20in\x20its\x20marker','id':'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'});case'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT':return t({'string':'Exit\x20the\x20annotation\x20and\x20move\x20focus\x20back\x20to\x20the\x20edited\x20content','id':'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER':return t({'string':'Browse\x20the\x20focused\x20annotation\x20thread\x20or\x20thread\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'});case'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS':return t({'string':'Move\x20across\x20internals\x20of\x20the\x20annotation\x20thread','id':'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'});case'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT':return t({'string':'Submit\x20the\x20reply\x20while\x20writing\x20a\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS':return t({'string':'Move\x20to\x20the\x20previous\x20or\x20next\x20thread\x20in\x20the\x20annotations\x20sidebar\x20or\x20comments\x20archive','id':'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'});default:return'';}}class Rt extends $t{['main'];['editable'];constructor(_0x2f7ada,_0x4c1d9f){super(_0x2f7ada);const _0x2c5ea6=_0x38f1c9();this['main']=this['createCollection'](),this['editable']=new Vt(_0x2f7ada,_0x4c1d9f,void 0x0,{'label':()=>N(_0x2f7ada,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x2f7ada['uiLanguageDirection'],'lang':_0x2f7ada['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x2c5ea6},'children':[{'tag':'div','attributes':{'class':'ck-editor__main','role':'presentation'},'children':this['main']}]});}['render'](){super['render'](),this['main']['add'](this['editable']);}['focus'](){this['editable']['element']['focus']();}}class Et extends Ut{['view'];constructor(_0x4309c4){super(_0x4309c4),this['view']=new Rt(_0x4309c4['locale'],_0x4309c4['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0xc6ad12=this['editor']['editing']['view'],_0x28c8f9=this['view']['editable'],_0xec0311=_0xc6ad12['document']['getRoot']();_0x28c8f9['name']=_0xec0311['rootName'],this['view']['render']();const _0x5243d2=_0x28c8f9['element'];this['setEditableElement'](_0x28c8f9['name'],_0x5243d2),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0xc6ad12['attachDomRoot'](_0x5243d2),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[qt,zt,Bt,Gt,Jt,Kt,Lt];class hs extends/* #__PURE__ -- @preserve */
25
+ _0x3d9b87(_0x11077e){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
+ ((()=>Qt)());constructor(_0x11e182={}){function _0x4c9a1b(_0x407f79){return _0x407f79['map'](_0x549a43=>String['fromCharCode'](_0x549a43))['join']('');}(_0x11e182=Object['assign']({},_0x11e182))['plugins']||(_0x11e182['plugins']=hs['defaultPlugins']),super(_0x11e182),this['ui']=new Et(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x4c9a1b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4c9a1b([0x76,0x69,0x65,0x77])][_0x4c9a1b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4c9a1b([0x61,0x75,0x74,0x6f]),this[_0x4c9a1b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x4c9a1b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4c9a1b([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x4c9a1b([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x4c9a1b([0x6f,0x6b])});}['create'](){const _0x456907=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x456907))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x43dae6=>{const _0x17f1e9=this['model']['document']['getRoot'](),_0x26b2c1=_0x17f1e9&&_0x17f1e9['getChild'](_0x17f1e9['childCount']-0x1);_0x43dae6['setSelection'](_0x26b2c1,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x589282=this['editing']['view'],_0x5ee816=_0x589282['document']['getRoot'](),_0x426e06=_0x5ee816['getChild'](0x0);_0x5ee816['childCount']>0x1||!_0x426e06||'p'!=_0x426e06['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x589282,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x426e06['placeholder']=this['placeholder']),Ft({'view':_0x589282,'element':_0x426e06,'keepOnFocus':!0x0}),this['placeholderElement']=_0x426e06);}}class es extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x5f22da,_0x2dfb5d={}){super(_0x5f22da),this['editor']=null,this['_editorConfig']=_0x2dfb5d,this['set']('value',_0x2dfb5d['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x5f22da,'Reply...')),this['set']('submitLabel',N(_0x5f22da,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x49912b(),this['focusCycler']=new _0x5eb73d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-comment__input-wrapper']},'children':[{'tag':'div','attributes':{'class':['ck-comment__input-actions',this['bindTemplate']['if']('showButtons','ck-comment__input-actions--active')]},'children':[this['submitButtonView'],this['cancelButtonView']]}]}),this['keystrokes']['set']('Esc',(_0x3a241b,_0x348b45)=>{this['cancelButtonView']['fire']('execute'),_0x348b45();}),this['keystrokes']['set']('Ctrl+Enter',(_0x3586e2,_0xf9bc8)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0xf9bc8());}),this['on']('submit',(_0x32d028,_0x134579)=>{_0x134579['length']>0xfde8?(alert(N(_0x5f22da,'TOO_LONG_COMMENT_ALERT',[_0x134579['length'],0xfde8])),_0x32d028['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new hs(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x1072e9=this['editor'];this['element']['insertBefore'](_0x1072e9['ui']['element'],this['element']['firstChild']),_0x1072e9['model']['document']['on']('change',()=>this['value']=_0x1072e9['getData']()),_0x1072e9['bind']('placeholder')['to'](this),this['focusables']['add'](_0x1072e9['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x11b629){-0x1===_0x11b629?(this['focusCycler']['focusFirst'](),this['focusCycler']['focusLast']()):this['focusCycler']['focusFirst']();}async['destroy'](){this['_isDestroyed']||(this['_isDestroyed']=!0x0,this['editor']&&(await this['_editorCreationPromise'],await this['editor']['destroy'](),this['fire']('editorDestroyed',this['editor'])),await super['destroy']());}['_createSubmitButton'](){const {locale:_0x11f274}=this,_0x505db3=new _0x55c6d4(_0x11f274);return _0x505db3['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x505db3['withText']=!0x0,_0x505db3['bind']('label')['to'](this,'submitLabel'),_0x505db3['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x505db3['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x1d0de2,_0x458fe8)=>!_0x458fe8&&!!_0x1d0de2['trim']()),_0x505db3;}['_createCancelButton'](){const {locale:_0x7980b4}=this,_0x58ff08=new _0x55c6d4(_0x7980b4);return _0x58ff08['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x58ff08['label']=N(_0x7980b4,'Cancel'),_0x58ff08['withText']=!0x0,_0x58ff08['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x58ff08;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x5e242f=>{this['focusTracker']['add'](_0x5e242f['element']);}),this['focusables']['on']('change',(_0x1d3d56,_0x2a34bc)=>{for(const _0x3fac45 of Array['from'](_0x2a34bc['added'])['reverse']())this['focusTracker']['add'](_0x3fac45['element']);});}}class ie extends kt{constructor(_0x50b1fd,_0x1b5204,_0x4f1ce8){super(_0x50b1fd),this['commentInputView']=new es(_0x50b1fd,_0x4f1ce8),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x24d955,_0x4454c2)=>_0x24d955||!!_0x4454c2),this['set']('showInput',!0x1),this['on']('change:showInput',()=>{this['showInput']&&!this['commentInputView']['editor']&&this['commentInputView']['createEditor']();}),this['commentInputView']['delegate']('editorReady')['to'](this),this['commentInputView']['delegate']('editorDestroyed')['to'](this),this['userView']=new _0x20e975(_0x50b1fd,_0x1b5204),this['userView']['extendTemplate']({'attributes':{'class':'ck-thread__user','aria-hidden':!0x0}}),this['commentInputView']['extendTemplate']({'attributes':{'class':'ck-thread__input'}}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-comment__input-container',this['bindTemplate']['if']('showInput','ck-comment__input-container--active')]},'children':[this['userView'],this['commentInputView']]});}['render'](){super['render'](),this['_focusOnNonInteractiveMouseDown']();}['destroy'](){return this['commentInputView']['destroy']()['then'](()=>super['destroy']());}['focus'](_0x82b3d2){this['commentInputView']['focus'](_0x82b3d2);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x195c3a,_0x3e5325)=>{const {submitButtonView:_0x25f913,cancelButtonView:_0x4824bc,editor:_0x26adc1}=this['commentInputView'];[_0x25f913['element'],_0x4824bc['element'],_0x26adc1?_0x26adc1['editing']['view']['getDomRoot']():null]['filter'](_0x7b5717=>_0x7b5717)['some'](_0x59deb5=>_0x59deb5['contains'](_0x3e5325['target']))||(this['focus'](),_0x3e5325['preventDefault']());});}}class rs extends kt{constructor(_0x3b4127){super(_0x3b4127);const _0x290df2=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x290df2['to']('count',_0x5da430=>N(_0x3b4127,'NUMBER_OF_COMMENTS',_0x5da430))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x203742,_0x271f5a,_0x27b22b){super(_0x203742);const _0x26414c=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x271f5a['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x271f5a,this['_config']=_0x27b22b,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x49912b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x5eb73d({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x594a20=>this['commentViews']['map'](_0x70d84b=>_0x70d84b['element'])['includes'](_0x594a20['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x203742),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x552a5c=>_0x552a5c-this['_config']['maxCommentsWhenCollapsed']);for(const _0x3321dd of _0x271f5a['comments'])this['_handleNewCommentModel'](_0x3321dd);this['_handleInfoComment'](),this['listenTo'](_0x271f5a['comments'],'add',(_0x82a9de,_0x328c41)=>{const _0x186656=this['_calculatePosition'](_0x328c41);this['length']++,this['_handleNewCommentModel'](_0x328c41,_0x186656),this['refreshVisibleViews']();}),this['listenTo'](_0x271f5a['comments'],'remove',(_0x552a36,_0x53800a)=>{this['length']--,this['_handleRemoveCommentModel'](_0x53800a),this['refreshVisibleViews']();}),this['listenTo'](_0x271f5a,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x271f5a,'change:isResolved',()=>this['_handleInfoComment']()),this['on']('change:isActive',()=>this['refreshVisibleViews']()),this['on']('change:hasDirtyComment',()=>this['refreshVisibleViews']()),this['setTemplate']({'tag':'ul','attributes':{'class':['ck-thread__comments',_0x26414c['if']('length','ck-hidden',_0x21836a=>!_0x21836a)],'aria-label':N(_0x203742,'Thread\x20comments')},'children':this['visibleViews']});}get['_shouldCollapse'](){return this['_model']['weight']>this['_config']['maxThreadTotalWeight']&&!this['isActive']&&!this['hasDirtyComment'];}['render'](){super['render'](),this['refreshVisibleViews'](),this['_setupKeyboardNavigation']();}['focus'](_0x192da8){-0x1===_0x192da8?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x52bf3e of this['commentViews'])_0x52bf3e['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x22a41a,_0x5a89b6){const _0x26c8b0=new this['_config']['CommentView'](this['locale'],_0x22a41a,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x26c8b0['viewUid']=_0x22a41a['id'],_0x26c8b0['delegate']('removeComment')['to'](this),_0x26c8b0['delegate']('updateComment')['to'](this),_0x26c8b0['delegate']('resolveCommentThread')['to'](this),_0x26c8b0['delegate']('editorReady')['to'](this),_0x26c8b0['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x26c8b0,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x26c8b0,_0x5a89b6);}['_calculatePosition'](_0xa932e){const _0x2eec7b=this['_model']['_findOptimalIndex'](_0xa932e);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0xa932e['authoredAt']?_0x2eec7b-0x1:_0x2eec7b:_0x2eec7b-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x13881c={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':N(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x13881c,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x13881c));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x11756e){const _0x15a4ed=this['commentViews']['remove'](_0x11756e['id']);this['stopListening'](_0x15a4ed),_0x15a4ed['isEditMode']&&this['_updateHasDirtyComment'](),_0x15a4ed['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x37ff11=>_0x37ff11['isEditMode']);}['_rearrangeCollapse'](){const _0x5b4500=function(_0x3ef186){const _0x5b8ed9=new _0x2a090d();for(const _0x108075 of _0x3ef186)_0x5b8ed9['add'](_0x108075);return _0x5b8ed9;}(this['commentViews']),_0x419116=this['_collapsedCommentsView']['count'];for(let _0xd3e67d=0x1;_0xd3e67d<=_0x419116;_0xd3e67d++)_0x5b4500['remove'](0x1);for(const _0x5c7397 of _0x5b4500)_0x5c7397['collapse']();_0x419116>0x0&&_0x5b4500['add'](this['_collapsedCommentsView'],0x1),ns(_0x5895cc(Array['from'](this['visibleViews']),Array['from'](_0x5b4500)),this['visibleViews'],_0x5b4500);}['_rearrangeExpand'](){ns(_0x5895cc(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x5cd807 of this['visibleViews'])_0x5cd807['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x2724a4=>{this['focusTracker']['add'](_0x2724a4['element']),this['keystrokes']['listenTo'](_0x2724a4['element']);}),this['commentViews']['on']('change',(_0xac4847,_0x5effd9)=>{for(const _0x50c557 of _0x5effd9['removed'])this['focusTracker']['remove'](_0x50c557['element']),this['keystrokes']['stopListening'](_0x50c557['element']);for(const _0x2bb20a of Array['from'](_0x5effd9['added'])['reverse']())this['focusTracker']['add'](_0x2bb20a['element']),this['keystrokes']['listenTo'](_0x2bb20a['element']);});}}function ns(_0x12153c,_0x4bfdb0,_0x2bac14){let _0x12f08a=0x0;for(const _0x180c62 of _0x12153c)switch(_0x180c62){case'insert':_0x4bfdb0['add'](_0x2bac14['get'](_0x12f08a),_0x12f08a),_0x12f08a++;break;case'delete':_0x4bfdb0['remove'](_0x12f08a);break;case'equal':_0x12f08a++;}}class oe extends kt{constructor(_0x1fde5b){super(_0x1fde5b);const _0x204825=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x204825['to']('contextValue',_0x51c3ca=>N(_0x1fde5b,'THREAD_CONTEXT_LABEL',_0x51c3ca)),'tabindex':-0x1},'children':[{'text':_0x204825['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x3f1366,_0x506565){super(_0x3f1366);const _0x4606c7=this['bindTemplate'];this['_model']=_0x506565,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x49912b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x5eb73d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x51620b=>!!_0x51620b),this['bind']('contextValue')['to'](this['_model'],'context',_0x5d5f3f=>_0x5d5f3f&&_0x5d5f3f['value']?this['_trimContextValue'](_0x5d5f3f['value']):N(this['locale'],'Comment\x20was\x20made\x20on\x20an\x20element')),this['setTemplate']({'tag':'div','attributes':{'class':['ck-thread__header']},'children':[{'tag':'div','attributes':{'class':['ck-context-wrapper']},'children':[{'tag':'div','attributes':{'class':['ck-context',_0x4606c7['if']('hasContext','ck-context--quotes')]},'children':[this['contextView']]}]},{'tag':'div','attributes':{'class':['ck-annotation__actions']},'children':[this['reopenButtonView']]}]});}['render'](){super['render'](),this['_attachContextActions'](),this['_setupKeyboardNavigation']();}['focus'](){this['focusCycler']['focusFirst']();}['_createReopenButton'](){const _0x46af70=new _0x55c6d4(this['locale']);return _0x46af70['label']=N(this['locale'],'Reopen'),_0x46af70['tooltip']=N(this['locale'],'Reopen'),_0x46af70['icon']=_0x4b9f73,_0x46af70['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0xfcb1ab=>!_0xfcb1ab),_0x46af70['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x550727,_0x35be30)=>_0x550727&&_0x35be30),_0x46af70['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x46af70;}['_trimContextValue'](_0x294435){if(_0x294435['length']<0x96)return _0x294435;const _0x28e6e3=_0x294435['lastIndexOf']('\x20',0x93);return _0x294435['substring'](0x0,_0x28e6e3>-0x1?_0x28e6e3:0x93)+'...';}['_attachContextActions'](){const _0x1ea4ae=this['element']['querySelector']('.ck-context'),_0x387329=_0x1ea4ae['querySelector']('.ck-context__value');this['listenTo'](_0x1ea4ae,'mouseenter',()=>{_0x387329['offsetWidth']<_0x387329['scrollWidth']&&_0x1ea4ae['classList']['add']('overlay');}),this['listenTo'](_0x1ea4ae,'mouseleave',()=>{_0x1ea4ae['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x39d0f2 of this['focusables'])this['focusTracker']['add'](_0x39d0f2['element']),this['keystrokes']['listenTo'](_0x39d0f2['element']);}['_createContextView'](){const _0x25473d=new oe(this['locale']);return _0x25473d['bind']('contextValue')['to'](this),_0x25473d;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x152bc6,_0x2e54b9,_0x2caaec,_0x38fecb){super(_0x152bc6),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x2e54b9,this['_localUser']=_0x2caaec,this['_config']=_0x38fecb,this['commentThreadHeaderView']=new Xt(_0x152bc6,_0x2e54b9),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x152bc6,N(_0x152bc6,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x152bc6,_0x2e54b9,Object['assign']({'CommentView':this['_config']['CommentView']},_0x38fecb)),this['commentsListView']['delegate']('removeComment')['to'](this),this['commentsListView']['delegate']('updateComment')['to'](this),this['commentsListView']['delegate']('resolveCommentThread')['to'](this),this['commentsListView']['delegate']('editorReady')['to'](this),this['commentsListView']['delegate']('editorDestroyed')['to'](this),this['commentsListView']['bind']('isActive')['to'](this),this['listenTo'](this,'resolveCommentThread',()=>{this['focus']();}),this['set']('length',this['commentsListView']['length']),this['bind']('length')['to'](this['commentsListView'],'length'),this['commentThreadInputView']=this['_createCommentThreadInputView'](),this['commentThreadInputView']['delegate']('editorReady')['to'](this),this['commentThreadInputView']['delegate']('editorDestroyed')['to'](this),this['on']('removeComment',()=>this['focus']()),this['bind']('isDirty')['to'](this['commentsListView'],'hasDirtyComment',this['commentThreadInputView']['commentInputView'],'value',(_0xfe6484,_0x40985e)=>_0xfe6484||!!_0x40985e),this['bind']('isUnlinked')['to'](_0x2e54b9,'unlinkedAt',_0x45e499=>!!_0x45e499),this['bind']('ariaLabel')['to'](this,'length',_0x5daed7=>{const _0x5b48c7=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x5daed7,_0x5b48c7]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x49912b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x5eb73d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x991a20=>_0x991a20['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),Zt(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x332a1e=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x56eb5b=_0x332a1e['commentInputView'];return _0x332a1e['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x56eb5b,'value',(_0x2c9f78,_0x562875,_0xe9d61,_0x14bd38,_0x4ff096)=>!!_0x4ff096||!!_0x14bd38&&_0xe9d61&&!_0x562875||_0x2c9f78&&_0xe9d61&&!_0x562875),_0x56eb5b['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x4dac53,_0x533bc6,_0x140f06)=>{let _0x37b3c9;return _0x37b3c9=_0x140f06&&_0x533bc6?'Reply\x20to\x20reopen\x20discussion...':_0x4dac53?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x37b3c9);}),_0x56eb5b['bind']('submitLabel')['to'](this,'length',_0x28bab7=>N(this['locale'],_0x28bab7?'Reply':'Comment')),_0x56eb5b['on']('submit',(_0x3c4455,_0x5595c6)=>{this['fire']('addComment',_0x5595c6),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x56eb5b['on']('cancel',()=>{this['focus']();}),_0x56eb5b['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x56eb5b['on']('cancel',_0x161675=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x161675['stop']());}),this['on']('change:isActive',(_0x4a7ec4,_0x526c7f,_0x16e70e)=>{_0x16e70e||this['length']||_0x56eb5b['value']||this['fire']('removeCommentThread');}),_0x332a1e;}}class gt extends/* #__PURE__ -- @preserve */
27
+ ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x4d85d7,_0x4d9172,_0x5bb619,_0x2285ef){super(_0x4d85d7,_0x4d9172,_0x5bb619,_0x2285ef),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x4d85d7,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x5a80a4,_0x56636f,_0x2203e0)=>{_0x2203e0||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x374be1,_0x13a8ec,_0x511d94)=>{_0x511d94&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x93c499=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x93c499['if']('isActive','ck-thread--active'),_0x93c499['if']('isUnlinked','ck-thread--unlinked'),_0x93c499['to']('actionIndicator',_0x3e4557=>_0x3e4557?'ck-thread--'+_0x3e4557:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x93c499['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id']},'children':[{'tag':'div','attributes':{'class':'ck-thread__container'},'children':this['commentThreadChildren']}]};}['render'](){super['render'](),this['containerElement']=this['element']['querySelector']('.ck-thread__container'),this['_model']['on']('change:archivedAt',()=>{this['_updateArchivedThreadHeader']();}),this['_updateArchivedThreadHeader']();}['_cancelAllConfirms'](){this['cancelConfirm']();for(const _0x2c98a0 of this['commentsListView']['commentViews'])_0x2c98a0['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x25726d}=this,_0xf9a89e=this['commentsListView']['commentViews']['get'](0x0);_0xf9a89e===this['_boundFirstCommentView']||_0xf9a89e['isSystemComment']||(this['_boundFirstCommentView']=_0xf9a89e,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0xf9a89e,'actionIndicator',_0x54ded0=>'remove'===_0x54ded0?'remove':null),_0xf9a89e['placeholder']=N(_0x25726d,'Write\x20a\x20comment...'),_0xf9a89e['removeButton']['on']('execute',_0x115116=>{_0x115116['stop'](),this['showConfirm'](N(_0x25726d,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0xf9a89e['focus']();}),_0xf9a89e['actionBar']['add'](this['resolveButton'],0x0),_0xf9a89e['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x18cf18=new _0x5d8ac5(this['locale']);return _0x18cf18['label']=N(this['locale'],'Resolve'),_0x18cf18['tooltip']=N(this['locale'],'Resolve'),_0x18cf18['icon']=_0x2883ac,_0x18cf18['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x18cf18['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x18e93b=>!_0x18e93b),_0x18cf18['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x550daa,_0x46adad)=>_0x550daa&&!_0x46adad),_0x18cf18['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x18cf18;}['_updateArchivedThreadHeader'](){this['_model']['archivedAt']?this['commentThreadChildren']['has'](this['commentThreadHeaderView'])||(this['commentThreadChildren']['add'](this['commentThreadHeaderView'],0x0),this['focusables']['add'](this['commentThreadHeaderView'],0x0)):this['commentThreadChildren']['has'](this['commentThreadHeaderView'])&&(this['commentThreadChildren']['remove'](this['commentThreadHeaderView']),this['focusables']['remove'](this['commentThreadHeaderView']));}}class is extends kt{constructor(_0x2d6441){super(_0x2d6441),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x582729,_0x452c6a,_0x339311)=>{this['element']['innerHTML']=_0x339311;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x4b2ff3,_0x120f65,_0x142ecd){super(_0x4b2ff3),this['_model']=_0x120f65,this['_config']=_0x142ecd,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x120f65,'content',_0x120f65,'authoredAt',(_0x14234b,_0x398323)=>N(_0x4b2ff3,'COMMENT_ARIA_LABEL',[_0x120f65['author']['name'],_0x142ecd['formatDateTime'](_0x398323),new DOMParser()['parseFromString'](_0x14234b,'text/html')['body']['textContent'],_0x120f65['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x4b2ff3,N(_0x4b2ff3,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x3253be(),this['focusTracker']=new _0x49912b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x5eb73d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5818db=>_0x5818db['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['expand'](){this['isCollapsed']=!0x1;}['collapse'](){this['isEditMode']||(this['isCollapsed']=!0x0);}['focus'](){this['element']['focus']();}['render'](){super['render'](),this['_setupKeyboardNavigation']();}async['destroy'](){await this['visibleView']['get'](0x0)['destroy'](),super['destroy']();}['switchToEditMode'](){this['isEditMode']||(this['isEditMode']=!0x0,this['visibleView']['remove'](0x0)['destroy'](),this['visibleView']['add'](this['_createCommentInputView']()));}['switchToDisplayMode'](){this['isEditMode']&&(this['isEditMode']=!0x1,this['visibleView']['remove'](0x0)['destroy'](),this['visibleView']['add'](this['_createCommentContentView']()));}['getExternalCommentNote'](){return'importWord'===this['_model']['attributes']['@external']['source']?N(this['locale'],'EXTERNAL_IMPORT_WORD_COMMENT'):N(this['locale'],'EXTERNAL_COMMENT');}['getUserViewNotificationText'](){return this['_model']['isExternal']?'importWord'===this['_model']['attributes']['@external']['source']?N(this['locale'],'EXTERNAL_IMPORT_WORD_AVATAR',this['_model']['creator']['name']):N(this['locale'],'EXTERNAL_AVATAR',this['_model']['creator']['name']):null;}['_createCommentContentView'](){const _0x204d9c=new is(this['locale']);return _0x204d9c['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x452fa4,_0x5e7309)=>_0x5e7309?ts(_0x452fa4,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x452fa4),_0x204d9c;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x2eed78=new es(this['locale'],this['_config']['editorConfig']);return _0x2eed78['value']=this['_model']['content'],_0x2eed78['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x2eed78['submitLabel']=N(this['locale'],'Save'),_0x2eed78['on']('submit',(_0x3167e6,_0x383f5f)=>{this['fire']('updateComment',this['_model']['id'],_0x383f5f),this['switchToDisplayMode'](),this['focus']();}),_0x2eed78['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x2eed78['once']('editorReady',()=>{_0x2eed78['focus']();}),_0x2eed78['createEditor'](),_0x2eed78['delegate']('editorReady')['to'](this),_0x2eed78['delegate']('editorDestroyed')['to'](this),_0x2eed78;}['_setupKeyboardNavigation'](){const _0x3ce41d=this['element'];this['keystrokes']['listenTo'](_0x3ce41d);for(const _0x22218d of this['focusables'])this['focusTracker']['add'](_0x22218d['element']),this['keystrokes']['listenTo'](_0x22218d['element']);this['focusables']['on']('change',(_0x3b49e0,_0xce968d)=>{for(const _0x1ffdc1 of _0xce968d['removed'])this['focusTracker']['remove'](_0x1ffdc1['element']),this['keystrokes']['stopListening'](_0x1ffdc1['element']);for(const _0x3a526a of _0xce968d['added'])this['focusTracker']['add'](_0x3a526a['element']),this['keystrokes']['listenTo'](_0x3a526a['element']);}),this['keystrokes']['set']('enter',(_0x3ec2c1,_0x4dd264)=>{_0x3ce41d===_0x3ec2c1['target']&&(this['focusCycler']['focusFirst'](),_0x4dd264());}),this['keystrokes']['set']('esc',(_0x2d1ade,_0x1ca6ee)=>{_0x3ce41d!==_0x2d1ade['target']&&(this['focus'](),_0x1ca6ee());});}}class Tt extends/* #__PURE__ -- @preserve */
28
+ ti(di){['actionBar'];['userView'];constructor(_0x4d1510,_0xea7b61,_0x5ce22b){super(_0x4d1510,_0xea7b61,_0x5ce22b),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x4d1510,'Reply...')),this['bind']('authoredAt')['to'](_0xea7b61),this['bind']('resolvedAt')['to'](_0xea7b61),this['actionBar']=this['createCollection'](),this['isSystemComment']||(this['editButton']=this['_createEditButton'](),this['removeButton']=this['_createRemoveButton'](),this['items']=this['createCollection'](),this['items']['addMany']([this['editButton'],this['removeButton']]),this['dropdown']=this['_createDropdown'](),this['actionBar']['add'](this['dropdown']),this['focusables']['add'](this['dropdown'])),this['userView']=new _0x20e975(_0x4d1510,_0xea7b61['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0xea7b61,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x4f239c=this['bindTemplate'],_0x2dacdd=[{'tag':'div','attributes':{'class':['ck-comment__info','ck-annotation__info']},'children':[{'tag':'span','children':[{'text':this['userView']['name']}],'attributes':{'class':['ck-comment__info-name','ck-annotation__info-name'],'data-cke-tooltip-text':this['userView']['name']}},{'tag':'time','attributes':{'datetime':_0x4f239c['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x4f239c['to']('authoredAt',_0x2bbedc=>this['_config']['formatDateTime'](_0x2bbedc))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x4f239c['if']('isEditMode','ck-comment__actions--hidden'),_0x4f239c['if']('isEditMode','ck-annotation__actions--hidden')]},'children':this['actionBar']},{'tag':'div','attributes':{'class':['ck-annotation__content-wrapper']},'children':this['visibleView']},this['ariaDescriptionView']];return this['_model']['isExternal']&&_0x2dacdd['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper'],'tabindex':-0x1,'aria-label':_0x4f239c['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x4f239c['if']('isEditMode','ck-comment--edit'),_0x4f239c['if']('isSystemComment','ck-comment--info'),_0x4f239c['to']('actionIndicator',_0x1b9b8f=>_0x1b9b8f?'ck-comment--'+_0x1b9b8f:'')],'data-author-id':this['_model']['author']['id'],'data-comment-id':this['_model']['id'],'role':'group'},'children':[this['userView'],{'tag':'div','attributes':{'class':['ck-comment__main','ck-annotation__main']},'children':_0x2dacdd}]}]};}['_createEditButton'](){const _0xf64f28=new _0x55c6d4(this['locale']);return _0xf64f28['label']=N(this['locale'],'Edit'),_0xf64f28['icon']=_0x1d2750,_0xf64f28['withText']=!0x0,_0xf64f28['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0xf64f28['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1896a8=>!_0x1896a8),_0xf64f28['bind']('isVisible')['to'](this['_model'],'isEditable'),_0xf64f28['on']('execute',()=>this['switchToEditMode']()),_0xf64f28;}['_createRemoveButton'](){const _0xf0eaf5=new _0x55c6d4(this['locale']);return _0xf0eaf5['label']=N(this['locale'],'Remove'),_0xf0eaf5['icon']=_0x8ef166,_0xf0eaf5['withText']=!0x0,_0xf0eaf5['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0xf0eaf5['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x4af615=>!_0x4af615),_0xf0eaf5['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0xf0eaf5['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0xf0eaf5;}['_createDropdown'](){const _0x35c731=_0x358bf8(this['locale'],_0x1f83ac),_0x62957a=_0x35c731['panelView']['children'],_0x56987d=new _0x270c6d(this['locale']),_0x5ecd08=_0x35c731['bindTemplate'];_0x1db7e5(_0x35c731,()=>this['items']['find'](_0x293f5e=>_0x293f5e['isVisible'])),_0x35c731['extendTemplate']({'attributes':{'class':[_0x5ecd08['if']('isVisible','ck-hidden',_0x5f2a73=>!_0x5f2a73)]}});const _0x404e54=(_0x334f52,_0x164344=-0x1)=>{const _0x4f2104=new _0xbff8e4(this['locale']);_0x4f2104['children']['add'](_0x334f52);const _0x5d0716=_0x164344>-0x1?_0x164344:_0x56987d['items']['length'];_0x56987d['items']['add'](_0x4f2104,_0x5d0716);const _0x51505e=Array['from'](this['items']);_0x35c731['unbind']('isEnabled','isVisible'),_0x35c731['bind']('isEnabled')['toMany'](_0x51505e,'isEnabled',(..._0x4a4076)=>_0x4a4076['some'](_0x386b1d=>_0x386b1d)),_0x35c731['bind']('isVisible')['toMany'](_0x51505e,'isVisible',(..._0x4b91e0)=>_0x4b91e0['some'](_0x2f3f7b=>_0x2f3f7b));};_0x35c731['panelPosition']='sw',_0x35c731['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x1d1820});for(const _0x445c59 of this['items'])_0x404e54(_0x445c59);return _0x62957a['add'](_0x56987d),_0x35c731['listenTo'](this['items'],'add',(_0x1e238b,_0x2a3eb8,_0x38baf7)=>{_0x404e54(_0x2a3eb8,_0x38baf7);}),_0x35c731['listenTo'](this['items'],'remove',(_0x4aa514,_0x1a2e71,_0x2533ab)=>{_0x56987d['items']['remove'](_0x2533ab);}),_0x35c731;}['_attachActions'](_0x170d1f,_0x13c6a0){const _0x39c948=_0x170d1f&&_0x170d1f['element'];_0x39c948&&(this['listenTo'](_0x39c948,'mouseenter',()=>this['actionIndicator']=_0x13c6a0),this['listenTo'](_0x39c948,'focus',()=>this['actionIndicator']=_0x13c6a0),this['listenTo'](_0x39c948,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x39c948,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x812a94=super['_createCommentInputView']();return _0x812a94['bind']('placeholder')['to'](this),_0x812a94;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x30c1de){const _0x5246e6=Dt(_0x30c1de,0x1e),_0x32202b=new MutationObserver(_0x15e1ba=>{for(const _0x313415 of _0x15e1ba)('attributes'==_0x313415['type']&&'class'==_0x313415['attributeName']||'childList'==_0x313415['type']||'characterData'==_0x313415['type'])&&_0x5246e6();});return{'attach'(_0x177f8c){_0x32202b['observe'](_0x177f8c,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x32202b['disconnect'](),_0x5246e6['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x3b3ce3,_0x49b302){super(_0x3b3ce3),this['id']=_0x38f1c9(),this['focusTracker']=new _0x49912b(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x5873e5,_0x170599)=>this['fire']('Esc',_0x170599)),this['set']('targetRect',{'top':0x0,'right':0x0,'bottom':0x0,'left':0x0}),this['set']('height',0x0),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['set']('length',0x0),this['set']('type',''),this['_mutationObserver']=xt(()=>this['_updateHeight']()),this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this),this['content']['add'](_0x49b302),this['mainView']=_0x49b302;const _0x559bc6=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x559bc6['if']('isActive','ck-annotation-wrapper--active')],'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['focusTracker']['add'](this['element']),this['keystrokes']['listenTo'](this['element']),this['_mutationObserver']['attach'](this['element']);}['destroy'](){this['content']['clear'](),this['keystrokes']['destroy'](),this['focusTracker']['destroy'](),this['_mutationObserver']['detach'](),super['destroy']();}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['_updateHeight'](){const _0x3e2315=this['element']['clientHeight'];_0x3e2315&&(this['height']=_0x3e2315);}}class T extends/* #__PURE__ -- @preserve */
29
+ _0x3d9b87(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x3a6de4,target:_0x2ca92a,type:_0x5e8907,isVisible:_0x5d987c=!0x0}){super(),this['view']=_0x3a6de4,this['view']['element']||this['view']['render'](),this['_type']=_0x5e8907,this['_target']=_0x2ca92a,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x2a090d([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x5329b1,_0x12235d)=>{this['view']['focusTracker']['add'](_0x12235d);}),this['focusableElements']['on']('remove',(_0x48371c,_0x294f54)=>{this['view']['focusTracker']['remove'](_0x294f54);}),this['set']('isVisible',_0x5d987c);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x43c17e=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x43c17e),_0x43c17e;}get['targetRect'](){const _0x433605=this['target'];if(null===_0x433605)return null;if(_0x433605 instanceof _0x3ab659)return _0x433605;const _0x263f96=_0x433605['filter'](_0x317c99=>function(_0x42912e){const _0x35d747=_0x42912e['offsetParent'];if(_0x35d747)return!0x0;const _0x2d7fbc=_0x42912e['getClientRects']()['item'](0x0);return!!_0x2d7fbc;}(_0x317c99));return 0x0===_0x263f96['length']?null:new _0x3ab659(_0x263f96[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x5cf41a){this['view']['isActive']=_0x5cf41a,this['view']['mainView']['isActive']=_0x5cf41a;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x238fe8){if(!(null===_0x238fe8||_0x238fe8 instanceof _0x3ab659||Array['isArray'](_0x238fe8)&&_0x238fe8['every'](_0x50b6e6=>fi(_0x50b6e6))))throw new _0x405026('annotation-invalid-target',null,{'target':_0x238fe8});}['_getNormalizedTarget'](){const _0x39dbb0='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0x39dbb0)?[_0x39dbb0]:_0x39dbb0;}}function fi(_0x50302f){return null!==_0x50302f&&'object'==typeof _0x50302f&&'nodeType'in _0x50302f&&0x1===_0x50302f['nodeType'];}class S extends _0x2a090d{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x38fc32=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x49912b(),this['_focusTracker']['on']('change:isFocused',(_0x494b4a,_0x3a1b3f,_0x507fe3)=>{_0x507fe3||this['fire']('blur');});for(const _0x3cd03e of _0x38fc32)this['add'](_0x3cd03e);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x150c0f){if(this['has'](_0x150c0f))throw new _0x405026('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x150c0f['innerView'],_0x150c0f),this['_viewToAnnotation']['set'](_0x150c0f['view'],_0x150c0f);for(const _0x22ab08 of _0x150c0f['focusableElements'])this['_focusTracker']['add'](_0x22ab08);this['listenTo'](_0x150c0f['focusableElements'],'add',(_0x5597de,_0x2f6a6b)=>{this['_focusTracker']['add'](_0x2f6a6b);}),this['listenTo'](_0x150c0f['focusableElements'],'remove',(_0xab8b99,_0x44e4a4)=>{this['_focusTracker']['remove'](_0x44e4a4);}),this['listenTo'](_0x150c0f['view']['focusTracker'],'change:isFocused',(_0x4d8e55,_0x2106d5,_0x40014e)=>{_0x40014e&&this['fire']('focus',_0x150c0f);}),_0x150c0f['updateTargetRect']();const _0x57fdce=this['_getOrderInContent'](_0x150c0f['view']['targetRect']);return super['add'](_0x150c0f,_0x57fdce);}['remove'](_0x3ae2c9){if(!this['has'](_0x3ae2c9))throw new _0x405026('annotationcollection-not-existing-item',null);this['stopListening'](_0x3ae2c9['view']['focusTracker']),this['stopListening'](_0x3ae2c9['focusableElements']);for(const _0x595fba of _0x3ae2c9['focusableElements'])this['_focusTracker']['remove'](_0x595fba);return this['_viewToAnnotation']['delete'](_0x3ae2c9['view']),this['_innerViewToAnnotation']['delete'](_0x3ae2c9['innerView']),super['remove'](_0x3ae2c9);}['getByInnerView'](_0x1dedba){return this['_innerViewToAnnotation']['get'](_0x1dedba);}['getByView'](_0x200130){return this['_viewToAnnotation']['get'](_0x200130);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x29bef5 of this)_0x29bef5['updateTargetRect']();this['_sort']();}['_sort'](){const _0x33b6a8=Array['from'](this)['sort']((_0x99dd12,_0x3acd98)=>w(_0x99dd12['view']['targetRect'],_0x3acd98['view']['targetRect']));for(let _0x2c37b9=_0x33b6a8['length']-0x1;_0x2c37b9>0x0;_0x2c37b9--){const _0x275d66=_0x33b6a8[_0x2c37b9];_0x2c37b9!==this['getIndex'](_0x275d66)&&(this['remove'](_0x275d66),this['add'](_0x275d66));}}['_getOrderInContent'](_0x496022){let _0x41a699=0x0;if(!_0x496022)return this['length'];for(const _0x27d01b of this){const _0xf31585=_0x27d01b['view']['targetRect'];if(_0xf31585){if(w(_0x496022,_0xf31585)<0x0)return _0x41a699;_0x41a699++;}}return _0x41a699;}}function v({source:_0x53b66f,target:_0x3390d8,filter:_0x4564e4}){for(const _0x897cbb of _0x53b66f)_0x4564e4(_0x897cbb)&&_0x3390d8['add'](_0x897cbb);_0x3390d8['listenTo'](_0x53b66f,'add',(_0x55a4ec,_0x2ec5a2)=>{_0x4564e4(_0x2ec5a2)&&_0x3390d8['add'](_0x2ec5a2);}),_0x3390d8['listenTo'](_0x53b66f,'remove',(_0x181df8,_0x4c346e)=>{_0x3390d8['has'](_0x4c346e)&&_0x3390d8['remove'](_0x4c346e);});}function w(_0x7506cd,_0x481e30){if(null===_0x7506cd&&null===_0x481e30)return 0x0;if(null===_0x7506cd)return-0x1;if(null===_0x481e30)return 0x1;const _0x4dbe02=_0x7506cd['top']-_0x481e30['top'];return 0x0==_0x4dbe02?_0x7506cd['left']-_0x481e30['left']:_0x4dbe02;}class y extends _0x2a0d5d{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x528234){if(super(_0x528234),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x528234 instanceof _0x11077e){const _0xd83749=_0x528234['locale'];_0x528234['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0xd83749,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x55020b){this['collection']['add'](_0x55020b);}['remove'](_0x2ab062){this['collection']['remove'](_0x2ab062),_0x2ab062['destroy']();}['refreshVisibility'](){for(const _0x2b590c of this['collection'])_0x2b590c['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x3913e5){return this['collection']['getByInnerView'](_0x3913e5);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0xa12eef of this['collection'])_0xa12eef['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x2e94ab){this['fire']('_activateAnnotation',_0x2e94ab);}['createAnnotation'](_0x1756d8){return new T(_0x1756d8);}['createAnnotationView'](_0x425259,_0x3934d4){return new E(_0x425259,_0x3934d4);}['_addActiveAnnotation'](_0x5ee913){const _0x4a8b51=new Set(this['activeAnnotations']);_0x4a8b51['add'](_0x5ee913),this['activeAnnotations']=_0x4a8b51;}['_removeActiveAnnotation'](_0x2db12d){const _0x1b17f6=new Set(this['activeAnnotations']);_0x1b17f6['delete'](_0x2db12d),this['activeAnnotations']=_0x1b17f6;}['_bindAnnotationsToVisibleAnnotations'](){const _0x211ad0=this['collection'],_0x4a18b0=this['_visibleAnnotations'];function _0x219379(_0x24368b){const _0x1195fb=_0x24368b['source'];_0x1195fb['isVisible']&&!_0x4a18b0['has'](_0x1195fb)?_0x4a18b0['add'](_0x1195fb):!_0x1195fb['isVisible']&&_0x4a18b0['has'](_0x1195fb)&&_0x4a18b0['remove'](_0x1195fb),_0x1195fb['view']['focusTracker']['remove'](_0x1195fb['view']['element']),_0x1195fb['view']['focusTracker']['add'](_0x1195fb['view']['element']);}this['listenTo'](_0x211ad0,'add',(_0x274169,_0x57d3c0)=>{_0x57d3c0['isVisible']&&_0x4a18b0['add'](_0x57d3c0),this['listenTo'](_0x57d3c0,'change:isVisible',_0x219379);}),this['listenTo'](_0x211ad0,'remove',(_0x417661,_0x16a96e)=>{_0x4a18b0['has'](_0x16a96e)&&_0x4a18b0['remove'](_0x16a96e),this['stopListening'](_0x16a96e,'change:isVisible',_0x219379);});}['_setupEnterAnnotationKeystroke'](){const _0x21eccf=_0x28868e=>{_0x28868e['on']('ready',()=>{_0x28868e['keystrokes']['set'](_0x3edcd3,(_0x216487,_0x476ead)=>{const _0x1c2526=_0x4e4912(this['activeAnnotations']['values']());_0x1c2526&&(_0x1c2526['view']['focus'](),_0x476ead());});});};this['context']instanceof _0x11077e?_0x21eccf(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x331734,_0x13ea82)=>{_0x21eccf(_0x13ea82);});}['_setupEscapeAnnotationHandling'](){const _0x1e2e89=_0x1b3e79=>{const _0x41a234=_0x1b3e79['source'],_0x2f847f=[];let _0x3e5334;if(Array['isArray'](_0x41a234['target'])){_0x3e5334=_0x41a234['target'][0x0],this['context']instanceof _0x11077e?_0x2f847f['push'](this['context']):this['context']['editors']&&_0x2f847f['push'](...this['context']['editors']);for(const _0xbaf4f8 of _0x2f847f)for(const _0x4da4a9 of _0xbaf4f8['editing']['view']['domRoots']['values']())if(_0x4da4a9['contains'](_0x3e5334))return void _0xbaf4f8['editing']['view']['focus']();_0x3e5334['focus']();}};this['listenTo'](this['collection'],'add',(_0xff446e,_0x3a7bcf)=>{this['listenTo'](_0x3a7bcf,'escape',_0x1e2e89,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x1add35,_0x1a324e)=>{this['stopListening'](_0x1a324e,'escape',_0x1e2e89);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x2a0d5d{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[y,lt,it];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xf92ae4){super(_0xf92ae4),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x3c498a=this['context']['config'];_0x3c498a['define']('comments.maxCommentsWhenCollapsed',0x2),_0x3c498a['define']('comments.maxThreadTotalWeight',0x1f4),_0x3c498a['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x3c498a['define']('comments.CommentThreadView',gt),_0x3c498a['define']('comments.CommentView',Tt),_0x3c498a['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x45a560=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x4809bf,_0x1fc391)=>this['_addCommentThread'](_0x1fc391)),this['on']('submitCommentThread',(_0x3f619b,_0x76fbe4)=>this['_submitCommentThread'](_0x76fbe4)),this['on']('resolveCommentThread',(_0x272d11,_0x324946)=>this['_resolveCommentThread'](_0x324946)),this['on']('resolveCommentThread',(_0x3fefaf,_0x514592)=>this['_updateActiveAnnotation'](_0x514592),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x4b5f3f,_0x57f662)=>this['_reopenCommentThread'](_0x57f662)),this['on']('reopenCommentThread',(_0x1397fe,_0x5865be)=>this['_updateActiveAnnotation'](_0x5865be),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x6730a5,_0x56740e)=>this['_removeCommentThread'](_0x56740e)),this['on']('updateCommentThread',(_0x3c062e,_0x421b9d)=>this['_updateCommentThread'](_0x421b9d)),this['on']('updateCommentThread',(_0xb97c43,_0x4e2713)=>this['_updateActiveAnnotation'](_0x4e2713),{'priority':'lowest'}),this['on']('addComment',(_0x39c398,_0x157148)=>this['_addComment'](_0x157148)),this['on']('updateComment',(_0x5a8f58,_0x37d5b1)=>this['_updateComment'](_0x37d5b1)),this['on']('removeComment',(_0x7191bc,_0x298486)=>this['_removeComment'](_0x298486)),this['on']('addComment',(_0x16ed34,{threadId:_0x4426e4,isFromAdapter:_0x126fb2})=>{if(_0x126fb2)return;const _0x4997c8=this['getCommentThread'](_0x4426e4),_0x5ebfb2=_0x4997c8&&this['_threadToController']['get'](_0x4997c8);_0x5ebfb2&&_0x5ebfb2['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x45a560,'change:activeAnnotations',(_0x5ab37e,_0x860c00,_0x565b21)=>{const _0x4845c8=Array['from'](_0x565b21)['map'](_0x55e46f=>this['_viewToController']['get'](_0x55e46f['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x4845c8?_0x4845c8['model']:null;});}set['adapter'](_0x374c06){if(this['_adapter'])throw new _0x405026('commentsrepository-adapter-already-set');this['_adapter']=_0x374c06;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x1bdbb4=_t,threadId:_0x4df5c9=_0x38f1c9(),comments:_0x5254ac=[],unlinkedAt:_0x29a616=null,resolvedAt:_0x495ef7=null,resolvedBy:_0x2e68d6=null,target:_0xe76516=null,context:_0x1ad9a0=null,attributes:_0x2ecf21={},isResolvable:_0x3068ab=!0x0,isSubmitted:_0x57347f=!0x1,isFromAdapter:_0x103f5e=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x1bdbb4),{'channelId':_0x1bdbb4,'threadId':_0x4df5c9,'comments':_0x5254ac,'unlinkedAt':_0x29a616,'resolvedAt':_0x495ef7,'resolvedBy':_0x2e68d6,'target':_0xe76516,'context':_0x1ad9a0,'attributes':_0x2ecf21,'isFromAdapter':_0x103f5e,'isResolvable':_0x3068ab,'isSubmitted':_0x57347f}),this['getCommentThread'](_0x4df5c9);}['openNewCommentThread']({channelId:_0x2b415a=_t,threadId:_0x2e0421=_0x38f1c9(),target:_0x26f8ad,context:_0x499062=null,isResolvable:_0x4669e8=!0x0}){if(this['_readOnlyChannels']['has'](_0x2b415a)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x26f8ad)throw new _0x405026('commentsrepository-missing-target');const _0x16be5d=this['addCommentThread']({'channelId':_0x2b415a,'threadId':_0x2e0421,'target':_0x26f8ad,'context':_0x499062,'isResolvable':_0x4669e8});if(!_0x16be5d)return null;const _0x2210ad=this['_threadToController']['get'](_0x16be5d),_0x2cbe83=_0x2210ad['view']['commentThreadInputView']['commentInputView'],_0x1dc0c6=this['context']['plugins']['get'](y),_0xd08e17=_0x1dc0c6['getByInnerView'](_0x2210ad['view']);return _0x1dc0c6['activate'](_0xd08e17),_0x2cbe83['once']('editorReady',()=>_0x2cbe83['focus']()),_0x16be5d;}['hasCommentThread'](_0xc604b6){if('string'!=typeof _0xc604b6)throw new _0x405026('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0xc604b6);}['updateCommentThread']({channelId:_0x25a17d=_t,threadId:_0x403a21,context:_0x26cb65,unlinkedAt:_0x19fcde,attributes:_0x54e3ae,isFromAdapter:_0x10d2c2=!0x1}){return this['fire'](Nt('updateCommentThread',_0x25a17d),{'channelId':_0x25a17d,'threadId':_0x403a21,'context':_0x26cb65,'unlinkedAt':_0x19fcde,'attributes':_0x54e3ae,'isFromAdapter':_0x10d2c2}),this['getCommentThread'](_0x403a21);}['getCommentThread'](_0x4bdbad){if('string'!=typeof _0x4bdbad)throw new _0x405026('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x4bdbad);}['fetchCommentThread']({channelId:_0x51c37e,threadId:_0x15d68a}={}){const _0x42b4c8=this['getCommentThread'](_0x15d68a);if(_0x42b4c8)return Promise['resolve'](_0x42b4c8);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x405026('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x51c37e,'threadId':_0x15d68a})['then'](_0x5b4822=>this['hasCommentThread'](_0x15d68a)?this['getCommentThread'](_0x15d68a):_0x5b4822?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x51c37e},_0x5b4822)):void 0x0)['catch'](_0x404bcd=>{throw console['error'](_0x404bcd),new _0x405026('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x320a66,skipNotAttached:_0x36de38=!0x1,skipEmpty:_0x5071a7=!0x1,toJSON:_0x252bf1=!0x1}={}){const _0x538cca=[];for(const _0x35e489 of this['_threads']['values']())_0x320a66&&_0x35e489['channelId']!==_0x320a66||_0x36de38&&!_0x35e489['isAttached']||_0x5071a7&&0x0===_0x35e489['length']||_0x538cca['push'](_0x35e489);return _0x252bf1?_0x538cca['map'](_0x13249d=>_0x13249d['toJSON']()):_0x538cca;}['getAnnotationForCommentThread'](_0x3fd3d7){const _0x29a14c=this['_threadToController']['get'](_0x3fd3d7);if(!_0x29a14c)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x29a14c['view'])||null;}['getCommentThreadForAnnotation'](_0x5ed255){const _0x5ec3ba=this['_viewToController']['get'](_0x5ed255['innerView']);return _0x5ec3ba?_0x5ec3ba['model']:null;}['setActiveCommentThread'](_0x9a2262){const _0x4bc660=this['context']['plugins']['get'](y);if(!_0x9a2262)return void(this['activeCommentThread']&&_0x4bc660['deactivateAll']());const _0x5796da=this['getCommentThread'](_0x9a2262);if(!_0x5796da)throw new _0x405026('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x9a2262});if(!this['_threadToController']['has'](_0x5796da))throw new _0x405026('commentsrepository-active-not-attached',null,{'threadId':_0x9a2262});const _0x5b6da0=_0x4bc660['getByInnerView'](this['_threadToController']['get'](_0x5796da)['view']);_0x4bc660['activate'](_0x5b6da0);}['switchReadOnly'](_0x54011a,_0x4c9b48){_0x54011a?this['_readOnlyChannels']['add'](_0x4c9b48):this['_readOnlyChannels']['delete'](_0x4c9b48),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x3bbbfd){return this['_readOnlyChannels']['has'](_0x3bbbfd)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x3390b9,_0xc5c327){return new vt(_0x3390b9,_0xc5c327);}['setPermissions'](_0x46f432,_0x27b7ae=_t){this['_permissions']['set'](_0x27b7ae,_0x46f432),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x1199ba=_t){return this['_permissions']['has'](_0x1199ba)?this['_permissions']['get'](_0x1199ba):bt;}['_addCommentThread']({channelId:_0xbadc57,threadId:_0x15444c,comments:_0x249b18,unlinkedAt:_0xbe0e31,resolvedAt:_0x28e093,resolvedBy:_0x2c8fb3,target:_0x38abbd,context:_0x54b74a,attributes:_0x131b22,isFromAdapter:_0x44fc14,isResolvable:_0x34efe4,isSubmitted:_0x271ffe}){if('string'!=typeof _0x15444c)throw new _0x405026('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x15444c});if(this['hasCommentThread'](_0x15444c))throw new _0x405026('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x15444c});const _0x3051fa=new pi(this,{'channelId':_0xbadc57,'id':_0x15444c,'context':_0x54b74a,'attributes':_0x131b22,'unlinkedAt':_0xbe0e31,'resolvedAt':_0x28e093,'resolvedBy':_0x2c8fb3?this['context']['plugins']['get'](it)['getUser'](_0x2c8fb3):null,'isResolvable':_0x34efe4,'isSubmitted':_0x271ffe||_0x44fc14});this['_threads']['set'](_0x15444c,_0x3051fa);for(const _0x4bf116 of _0x249b18)_0x3051fa['_add'](this['_createNewComment']({'threadId':_0x15444c,..._0x4bf116}));return _0x38abbd&&_0x3051fa['attachTo'](_0x38abbd),_0x44fc14||!_0x3051fa['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0xbadc57,'threadId':_0x15444c});}['_submitCommentThread']({channelId:_0x4ad863,threadId:_0x268891}){if(!this['hasCommentThread'](_0x268891))throw new _0x405026('commentsrepository-missing-comment-thread',this);const _0x5c87e3=this['getCommentThread'](_0x268891);if(_0x5c87e3['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0xdcb55c,comments:_0x70a850,resolvedAt:_0x303dd1,resolvedBy:_0x212cf5,context:_0x279e6e,attributes:_0x18d102}=_0x5c87e3,_0x586831=this['context']['plugins']['get']('PendingActions'),_0x15dbdf=_0x586831['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x4ad863,'threadId':_0xdcb55c,'comments':_0x70a850['map'](_0x3e8177=>_0x3e8177['toJSON']()),'resolvedAt':_0x303dd1,'resolvedBy':_0x212cf5?_0x212cf5['id']:_0x212cf5,'context':_0x279e6e,'attributes':_0x18d102})['then'](({comments:_0x1b433e})=>{_0x586831['remove'](_0x15dbdf);for(const _0x43872d of _0x1b433e)this['_updateComment']({'channelId':_0x4ad863,'threadId':_0x268891,'commentId':_0x43872d['commentId'],'createdAt':_0x43872d['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x51ca33=>{throw console['error'](_0x51ca33),new _0x405026('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x25c748,target:_0x5770e3}){const _0x13f3ba=this['getCommentThread'](_0x25c748);if(!_0x13f3ba)throw new _0x405026('commentsrepository-attach-missing-comment-thread',this);const _0x560ebc=this['context']['plugins']['get']('PendingActions'),_0x21b79f=this['context']['plugins']['get'](y),_0x11d8fe=this['_createCommentThreadView'](_0x13f3ba),_0x25319a=new vt(_0x13f3ba,_0x11d8fe);let _0x2907bb=null;_0x11d8fe['on']('change:isDirty',(_0x583ac1,_0x1dd14b,_0x14e8ac)=>{_0x14e8ac?_0x2907bb=_0x560ebc['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x2907bb&&(_0x560ebc['remove'](_0x2907bb),_0x2907bb=null);}),this['_threadToController']['set'](_0x13f3ba,_0x25319a),this['_viewToController']['set'](_0x11d8fe,_0x25319a);const _0x282fbb=new E(this['context']['locale'],_0x11d8fe);_0x282fbb['bind']('length')['to'](_0x11d8fe),_0x282fbb['bind']('isDirty')['to'](_0x11d8fe,'isDirty',_0x11d8fe,'length',(_0x5bdd3b,_0xce1d95)=>_0x5bdd3b||!_0xce1d95),_0x282fbb['bind']('isActive')['to'](_0x11d8fe),_0x282fbb['type']='comment';const _0x88d8b8=new T({'view':_0x282fbb,'target':_0x5770e3,'type':'comment','isVisible':!_0x13f3ba['archivedAt']&&!!('function'==typeof _0x5770e3?_0x5770e3():_0x5770e3)});return _0x11d8fe['on']('escape',()=>{_0x88d8b8['fire']('escape');}),this['_bindAnnotationToEditors'](_0x11d8fe,_0x88d8b8),_0x21b79f['add'](_0x88d8b8),_0x88d8b8;}['_bindAnnotationToEditors'](_0x219c2d,_0x47e89f){this['listenTo'](_0x219c2d,'editorReady',(_0x1acb5e,_0x298c4f)=>{const _0x1ad7e4=_0x298c4f['ui']['view']['body']['bodyCollectionContainer'];_0x47e89f['focusableElements']['add'](_0x1ad7e4),this['context']instanceof _0x11077e&&this['context']['ui']['focusTracker']['add'](_0x1ad7e4);},{'priority':'highest'}),this['listenTo'](_0x219c2d,'editorDestroyed',(_0xdbfa6c,_0xa92c5c)=>{const _0x15ba47=_0xa92c5c['ui']['view']['body']['bodyCollectionContainer'];_0x47e89f['focusableElements']['has'](_0x15ba47)&&_0x47e89f['focusableElements']['remove'](_0x15ba47),this['context']instanceof _0x11077e&&this['context']['ui']['focusTracker']['remove'](_0x15ba47);});}['_unbindEditors'](_0x5792c1){this['stopListening'](_0x5792c1,'editorReady'),this['stopListening'](_0x5792c1,'editorDestroyed');}['_createCommentThreadView'](_0x2d4ffe){const _0x4e9b4a=this['context']['plugins']['get'](it),{config:_0x4741d7,locale:_0x13e837}=this['context'],_0x2392c7=pt(_0x4741d7['get']('locale'),_0x13e837);return new(0x0,(_0x4741d7['get']('comments'))['CommentThreadView'])(_0x13e837,_0x2d4ffe,_0x4e9b4a['me'],{'editorConfig':{..._0x4741d7['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x4741d7['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x4741d7['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x4741d7['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x4741d7['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x2392c7,'CommentView':_0x4741d7['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0xc27912,channelId:_0xf92b6b,resolvedAt:_0x4e5c3d,resolvedBy:_0xb1415d,isFromAdapter:_0x1d1e13}){if(!this['hasCommentThread'](_0xc27912))throw new _0x405026('commentsrepository-missing-comment-thread',null,{'threadId':_0xc27912});const _0x4443ef=this['getCommentThread'](_0xc27912);if(_0x4443ef['isResolved'])throw new _0x405026('commentsrepository-resolved-comment-thread',null,{'threadId':_0xc27912});const _0x3248c9=this['context']['plugins']['get'](it);if(_0x4443ef['resolvedBy']=_0x3248c9['getUser'](_0xb1415d),_0x4443ef['resolvedAt']=_0x4e5c3d,_0x1d1e13||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x3f0379=this['context']['plugins']['get']('PendingActions'),_0x224dd5=_0x3f0379['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0xf92b6b,'threadId':_0xc27912})['then'](({resolvedAt:_0x41e49c,resolvedBy:_0x5a78d8})=>{_0x3f0379['remove'](_0x224dd5),_0x4443ef['resolvedBy']['id']!==_0x5a78d8&&(_0x4443ef['resolvedBy']=_0x3248c9['getUser'](_0x5a78d8)),_0x4443ef['resolvedAt']=_0x41e49c;})['catch'](_0x43d2b3=>{throw console['error'](_0x43d2b3),new _0x405026('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0xc0769e,channelId:_0x5b3095,isFromAdapter:_0x58e7ae}){if(!this['hasCommentThread'](_0xc0769e))throw new _0x405026('commentsrepository-missing-comment-thread',null,{'threadId':_0xc0769e});const _0x5e40a6=this['getCommentThread'](_0xc0769e);if(!_0x5e40a6['isResolved'])throw new _0x405026('commentsrepository-reopen-comment-thread',null,{'threadId':_0xc0769e});if(_0x5e40a6['resolvedBy']=null,_0x5e40a6['resolvedAt']=null,_0x58e7ae||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x310ebe=this['context']['plugins']['get']('PendingActions'),_0x6ca92c=_0x310ebe['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x5b3095,'threadId':_0xc0769e})['then'](()=>_0x310ebe['remove'](_0x6ca92c))['catch'](_0x423964=>{throw console['error'](_0x423964),new _0x405026('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x3ea827,isFromAdapter:_0xe5180a}){const _0x4ffacc=this['getCommentThread'](_0x3ea827);if(!_0x4ffacc)throw new _0x405026('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x3ea827),this['_threads']['delete'](_0x3ea827),!_0x4ffacc['isSubmitted']||_0xe5180a||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x3ecbae=this['context']['plugins']['get']('PendingActions'),{channelId:_0xff2c22}=_0x4ffacc,_0xafb43=_0x3ecbae['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0xff2c22,'threadId':_0x3ea827})['then'](()=>_0x3ecbae['remove'](_0xafb43))['catch'](_0x36ea72=>{throw console['error'](_0x36ea72),new _0x405026('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x26c041,unlinkedAt:_0x3509df,context:_0x8900ad,attributes:_0x269f98,isFromAdapter:_0x2c6574}){if('string'!=typeof _0x26c041)throw new _0x405026('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x26c041});if(!this['hasCommentThread'](_0x26c041))throw new _0x405026('commentsrepository-missing-comment-thread',null,{'threadId':_0x26c041});const _0x4ed436=this['getCommentThread'](_0x26c041);let _0x2b0eb5=!0x1;if(void 0x0!==_0x8900ad&&_0x4ed436['context']!==_0x8900ad&&(_0x4ed436['context']=_0x8900ad,_0x2b0eb5=!0x0),void 0x0!==_0x3509df&&_0x4ed436['unlinkedAt']!==_0x3509df&&(_0x4ed436['unlinkedAt']=_0x3509df,_0x2b0eb5=!0x0),_0x269f98&&!At(_0x269f98,_0x4ed436['attributes'])&&(_0x4ed436['attributes']=_0x269f98,_0x2b0eb5=!0x0),!_0x2b0eb5)return Promise['resolve']();if(!_0x4ed436['isSubmitted']||_0x2c6574||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x137676=this['context']['plugins']['get']('PendingActions'),{channelId:_0x516a3e}=_0x4ed436,_0x26a682=_0x137676['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x516a3e,'threadId':_0x26c041,'context':_0x8900ad,'unlinkedAt':_0x3509df,'attributes':_0x269f98})['then'](()=>_0x137676['remove'](_0x26a682))['catch'](_0x36b12c=>{throw console['error'](_0x36b12c),new _0x405026('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x25c437){const _0x9f5430=this['context']['plugins']['get'](y),_0x9f5c3e=this['getCommentThread'](_0x25c437);if(_0x9f5c3e['_isAttached']=!0x1,this['_threadToController']['has'](_0x9f5c3e)){const _0x277e9c=this['_threadToController']['get'](_0x9f5c3e),_0x1807b1=_0x277e9c['view'],_0x24059f=_0x9f5430['getByInnerView'](_0x1807b1);this['_threadToController']['delete'](_0x9f5c3e),this['_viewToController']['delete'](_0x1807b1),_0x24059f&&_0x9f5430['remove'](_0x24059f),_0x277e9c['destroy'](),_0x1807b1['destroy']()['then'](()=>{this['_unbindEditors'](_0x1807b1);});}}['_updateActiveAnnotation']({threadId:_0x53165f,resolvedAt:_0x2b3b2c,unlinkedAt:_0x16fcc1}){const _0x2bf590=!!_0x2b3b2c,_0x29379c=this['context']['plugins']['get'](y),_0x2adc5a=this['getCommentThread'](_0x53165f);if(this['_threadToController']['has'](_0x2adc5a)){const _0x243e30=this['_threadToController']['get'](_0x2adc5a)['view'],_0x5ec4de=_0x29379c['getByInnerView'](_0x243e30);_0x5ec4de&&(_0x2bf590&&_0x29379c['_removeActiveAnnotation'](_0x5ec4de),_0x16fcc1?_0x5ec4de['isVisible']=!0x1:_0x5ec4de['refreshVisibility']());}}['_getExternalAuthor'](_0x4c5ebb){const _0x11a4b2=this['context']['plugins']['get'](it),_0x56353a=It('external:'+_0x4c5ebb),_0x49798c=_0x11a4b2['getUser'](_0x56353a);return _0x49798c||_0x11a4b2['addUser']({'id':_0x56353a,'name':_0x4c5ebb});}['_createNewComment']({threadId:_0x2c6863,commentId:_0x19b7a8=_0x38f1c9(),content:_0xecaa58,authorId:_0x269de6,createdAt:_0x37402f,attributes:_0x1d6554}){if('string'!=typeof _0x19b7a8)throw new _0x405026('commentsrepository-invalid-commentid');if('string'!=typeof _0x269de6)throw new _0x405026('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0xecaa58||!_0xecaa58['trim']())throw new _0x405026('commentsrepository-invalid-comment-content');const _0x2eea6a=this['context']['plugins']['get'](it)['getUser'](_0x269de6);if(!_0x2eea6a)throw new _0x405026('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x269de6});let _0x2572d5=null,_0x1833f8=_0x37402f;return _0x1d6554?.['@external']&&(_0x2572d5=this['_getExternalAuthor'](_0x1d6554['@external']['authorName']),_0x1833f8=new Date(_0x1d6554['@external']['createdAt'])),new wi(this,{'threadId':_0x2c6863,'id':_0x19b7a8,'author':_0x2572d5||_0x2eea6a,'creator':_0x2eea6a,'content':_0xecaa58,'createdAt':_0x37402f,'authoredAt':_0x1833f8,'attributes':_0x1d6554});}['_addComment'](_0x2b2172){let {threadId:_0x30742c,content:_0x5141ea,attributes:_0xd304bd,isFromAdapter:_0x87b4b9}=_0x2b2172;const _0x3e88c1=this['getCommentThread'](_0x2b2172['threadId']);if(!_0x3e88c1)throw new _0x405026('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x14f34e=this['_createNewComment'](_0x2b2172),{id:_0xef6562}=_0x14f34e;if(_0x3e88c1['_add'](_0x14f34e),_0x87b4b9||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x3e88c1['isSubmitted'])return Promise['resolve']();const _0xe1b579=this['context']['plugins']['get']('PendingActions'),{channelId:_0x52ef74}=_0x3e88c1,_0x3b2409=_0xe1b579['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0xd304bd||(_0xd304bd={}),this['adapter']['addComment']({'channelId':_0x52ef74,'threadId':_0x30742c,'commentId':_0xef6562,'content':_0x5141ea,'attributes':_0xd304bd})['then'](_0x23e90a=>{_0xe1b579['remove'](_0x3b2409),_0x23e90a&&this['_updateComment']({'channelId':_0x52ef74,'threadId':_0x30742c,'commentId':_0xef6562,'createdAt':_0x23e90a['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x11ca8c=>{throw console['error'](_0x11ca8c),new _0x405026('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x544c43,commentId:_0x24acc3,content:_0x55e4e1,createdAt:_0x5aabcd,attributes:_0x303d04,isFromAdapter:_0x7fb19e}){if(void 0x0!==_0x55e4e1&&('string'!=typeof _0x55e4e1||!_0x55e4e1['trim']()['length']))throw new _0x405026('commentsrepository-update-comment-invalid-content');const _0xb3e08=this['getCommentThread'](_0x544c43),_0x2e7cb6=_0xb3e08['getComment'](_0x24acc3);if(!_0x2e7cb6)throw new _0x405026('commentsrepository-update-missing-comment',this);let _0x34a568=!0x1;if(_0x55e4e1&&_0x55e4e1!==_0x2e7cb6['content']&&(_0x2e7cb6['isEditable']||_0x7fb19e)&&(_0x2e7cb6['content']=_0x55e4e1,_0x34a568=!0x0),_0x5aabcd&&_0x5aabcd!==_0x2e7cb6['createdAt']&&(_0x2e7cb6['createdAt']=_0x5aabcd,_0x2e7cb6['attributes']&&_0x2e7cb6['attributes']['@external']||(_0x2e7cb6['authoredAt']=_0x5aabcd),_0x34a568=!0x0),_0x303d04&&!At(_0x303d04,_0x2e7cb6['attributes'])&&(_0x2e7cb6['attributes']=_0x303d04,_0x34a568=!0x0),!_0x34a568)return Promise['resolve']();if(_0xb3e08['fire']('commentUpdated'),_0x7fb19e||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x3a9cdb=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4c43e9}=this['getCommentThread'](_0x2e7cb6['threadId']),_0x535396=_0x3a9cdb['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x4c43e9,'threadId':_0x544c43,'commentId':_0x24acc3,'content':_0x55e4e1,'attributes':_0x303d04})['then'](()=>_0x3a9cdb['remove'](_0x535396))['catch'](_0x501acd=>{throw console['error'](_0x501acd),new _0x405026('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x237851,commentId:_0x60dfca,isFromAdapter:_0x3537ec}){const _0x4df7ff=this['getCommentThread'](_0x237851),_0x3ed416=_0x4df7ff['getComment'](_0x60dfca);if(!_0x3ed416)throw new _0x405026('commentsrepository-remove-missing-comment',this);if(_0x4df7ff['_remove'](_0x3ed416),_0x3537ec||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x562b63=this['context']['plugins']['get']('PendingActions'),{channelId:_0x49e812}=_0x4df7ff,_0x2526aa=_0x562b63['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x49e812,'threadId':_0x237851,'commentId':_0x60dfca})['then'](()=>_0x562b63['remove'](_0x2526aa))['catch'](_0x5ef71a=>{throw console['error'](_0x5ef71a),new _0x405026('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
+ _0x3d9b87(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x364f6c,_0x4b2a32){super();const _0x4baf27=_0x4b2a32['isResolvable'];this['channelId']=_0x4b2a32['channelId'],this['id']=_0x4b2a32['id'],this['comments']=new _0x2a090d(),this['_repository']=_0x364f6c,this['_isAttached']=!0x1,this['_isSubmitted']=_0x4b2a32['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x364f6c,'_permissions',_0x364f6c,'_readOnlyChannels',()=>_0x364f6c['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x364f6c,'_permissions',()=>_0x364f6c['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x364f6c,'_permissions',()=>{const _0x41d105=_0x364f6c['getPermissions'](this['channelId']);return _0x41d105['write']||_0x41d105['admin'];}),this['bind']('isResolvable')['to'](_0x364f6c,'_permissions',()=>_0x4baf27&&_0x364f6c['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x4b2a32['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x3401b3,_0x5d2784)=>_0x3401b3?_0x5d2784?_0x3401b3<_0x5d2784?_0x3401b3:_0x5d2784:_0x3401b3:_0x5d2784),this['set']('unlinkedAt',_0x4b2a32['unlinkedAt']||null),this['set']('resolvedAt',_0x4b2a32['resolvedAt']||null),this['set']('resolvedBy',_0x4b2a32['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x50479e=>!!_0x50479e),this['set']('attributes',_0x4b2a32['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x42085a,_0x372502)=>_0x42085a+_0x372502['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x5accc3,id:_0x22add1}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x5accc3),{'channelId':_0x5accc3,'threadId':_0x22add1});}['setUnlinkedAt'](_0x1cff3a){this['_update']({'unlinkedAt':_0x1cff3a});}['resolve']({resolvedAt:_0x19767d=new Date(),resolvedBy:_0x532fc7='',isFromAdapter:_0x1b55fc=!0x1}={}){const _0x392f10=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x5cc5a5,id:_0x330de3}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x5cc5a5),{'channelId':_0x5cc5a5,'threadId':_0x330de3,'resolvedAt':_0x19767d,'resolvedBy':_0x532fc7||_0x392f10['id'],'isFromAdapter':_0x1b55fc});}['reopen']({isFromAdapter:_0x2a293f=!0x1}={}){const {channelId:_0x166cc8,id:_0x44ca16}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x166cc8),{'channelId':_0x166cc8,'threadId':_0x44ca16,'isFromAdapter':_0x2a293f});}['setContext'](_0x1a002f){this['context']||this['_update']({'context':_0x1a002f});}['setAttribute'](_0x57f853,_0x5daf1f){const _0xf0cd64=wt(this['attributes']);yt(_0xf0cd64,_0x57f853,_0x5daf1f),this['_update']({'attributes':_0xf0cd64});}['removeAttribute'](_0x3534a0){const _0x4e9e6e=wt(this['attributes']);Ct(_0x4e9e6e,_0x3534a0),this['_update']({'attributes':_0x4e9e6e});}['remove']({isFromAdapter:_0x117bc9=!0x1}={}){const {channelId:_0x15a4bd,id:_0xe94706}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x15a4bd),{'channelId':_0x15a4bd,'threadId':_0xe94706,'isFromAdapter':_0x117bc9});}['attachTo'](_0x173f9f){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x173f9f});}['addComment'](_0x2e2d59){const {channelId:_0x3b5580,id:_0x775053}=this;this['_repository']['fire'](Nt('addComment',_0x3b5580,_0x775053),Object['assign']({'channelId':_0x3b5580,'threadId':_0x775053},_0x2e2d59));}['getComment'](_0x2bc253){if('string'!=typeof _0x2bc253)throw new _0x405026('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x2bc253});return this['comments']['get'](_0x2bc253);}['toJSON'](){return{'threadId':this['id'],'context':this['context'],'unlinkedAt':this['unlinkedAt'],'resolvedAt':this['resolvedAt'],'resolvedBy':this['resolvedBy']?this['resolvedBy']['id']:null,'archivedAt':this['archivedAt'],'comments':this['comments']['map'](_0xb0aa09=>_0xb0aa09['toJSON']()),'attributes':this['attributes']};}['_add'](_0xf35e36){return this['listenTo'](_0xf35e36,'change:authoredAt',()=>{const _0x14df05=this['_findOptimalIndex'](_0xf35e36),_0x2517a3=this['comments'];_0x14df05-0x1!=_0x2517a3['getIndex'](_0xf35e36)&&_0x14df05+0x1!=_0x2517a3['getIndex'](_0xf35e36)&&(this['_remove'](_0xf35e36),this['_add'](_0xf35e36));}),this['comments']['add'](_0xf35e36,this['_findOptimalIndex'](_0xf35e36));}['_update'](_0xc86209){const {channelId:_0x48a0d5,id:_0x1659af}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x48a0d5),{..._0xc86209,'channelId':_0x48a0d5,'threadId':_0x1659af});}['_remove'](_0x677df6){return this['stopListening'](_0x677df6),_0x677df6['destroy'](),this['comments']['remove'](_0x677df6);}['_findOptimalIndex'](_0x4510b3){const _0x2cffd5=this['comments']['find'](_0x502587=>new Date(_0x502587['authoredAt'])['getTime']()>new Date(_0x4510b3['authoredAt'])['getTime']());return _0x2cffd5?this['comments']['getIndex'](_0x2cffd5):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
+ _0x3d9b87(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x13bb73,_0x92047e){super();const _0x3a04e3=_0x13bb73['context']['plugins']['get'](it)['me'],_0x10889d=_0x13bb73['getCommentThread'](_0x92047e['threadId']),_0x2a780b=0x0===_0x10889d['comments']['length'],_0x5a22d6=_0x3a04e3===_0x92047e['author'];this['id']=_0x92047e['id'],this['threadId']=_0x92047e['threadId'],this['author']=_0x92047e['author'],this['creator']=_0x92047e['creator'],this['isExternal']=Boolean(_0x92047e['attributes']&&_0x92047e['attributes']['@external']),this['set']('content',_0x92047e['content']),this['createdAt']=_0x92047e['createdAt']||new Date(),this['set']('authoredAt',_0x92047e['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x10889d,'resolvedAt'),this['set']('attributes',_0x92047e['attributes']||{}),this['bind']('isEditable')['to'](_0x13bb73,'_permissions',()=>{const _0x444d6a=_0x13bb73['getPermissions'](_0x10889d['channelId'])['write'],_0xd3d4ca=_0x13bb73['getPermissions'](_0x10889d['channelId'])['modifyAll'];return _0x5a22d6&&_0x444d6a||!_0x5a22d6&&_0xd3d4ca;}),this['bind']('isRemovable')['to'](_0x10889d,'isRemovable',_0x13bb73,'_permissions',_0x295cc8=>{const _0x514a89=_0x13bb73['getPermissions'](_0x10889d['channelId'])['write'],_0x4eb059=_0x13bb73['getPermissions'](_0x10889d['channelId'])['modifyAll'];return _0x5a22d6&&_0x514a89||_0x295cc8&&_0x2a780b||!_0x5a22d6&&_0x4eb059&&!_0x2a780b;}),this['bind']('isReadOnly')['to'](_0x10889d,'isReadOnly'),this['_repository']=_0x13bb73;}get['weight'](){return Math['max'](function(_0x1b2ecd){const _0x208cdb=document['createElement']('div');return _0x208cdb['innerHTML']=_0x1b2ecd,_0x208cdb['textContent']['length'];}(this['content']),0xc8);}['update'](_0x459421){const {threadId:_0x38a505,id:_0x52dfe6}=this;if(!this['_repository']['hasCommentThread'](_0x38a505))throw new _0x405026('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x12e974}=this['_repository']['getCommentThread'](_0x38a505);this['_repository']['fire'](Nt('updateComment',_0x12e974,_0x38a505),{'channelId':_0x12e974,'threadId':_0x38a505,'commentId':_0x52dfe6,..._0x459421});}['setAttribute'](_0x58cc87,_0x3fbcee){const _0x2f369d=wt(this['attributes']);yt(_0x2f369d,_0x58cc87,_0x3fbcee),this['update']({'attributes':_0x2f369d});}['removeAttribute'](_0x522a47){const _0x143524=wt(this['attributes']);Ct(_0x143524,_0x522a47),this['update']({'attributes':_0x143524});}['remove'](_0x39b7b2={}){if(!_0x39b7b2['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x56b0df,id:_0x2d3ce9}=this;if(!this['_repository']['hasCommentThread'](_0x56b0df))throw new _0x405026('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x1cd2e0}=this['_repository']['getCommentThread'](_0x56b0df);this['_repository']['fire'](Nt('removeComment',_0x1cd2e0,_0x56b0df),{'channelId':_0x1cd2e0,'threadId':_0x56b0df,'commentId':_0x2d3ce9,..._0x39b7b2});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x182738,..._0x30f86d){for(const _0x834b1a of _0x30f86d)void 0x0!==_0x834b1a&&(_0x182738+=':'+String(_0x834b1a));return _0x182738;}class ot extends _0x400ce4{constructor(_0x8cbb0c){super(_0x8cbb0c),this['set']('hasContent',!0x1);}['refresh'](){const _0x28bfba=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x90e274 of _0x28bfba['getRanges']())if(this['_hasContent'](_0x90e274))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x513987=_0x38f1c9(),ranges:_0x5d44e1,comment:_0x488b67}={}){const _0x519172=this['editor']['model'],_0x28cfc2=_0x5d44e1??Array['from'](_0x519172['document']['selection']['getRanges']()),_0x1dbe81=[];for(const _0x36adf6 of _0x28cfc2)this['_hasContent'](_0x36adf6)&&_0x1dbe81['push'](this['_trimToContent'](_0x36adf6));if(!_0x1dbe81['length'])throw new _0x405026('addcommentthreadcommand-incorrect-ranges',null);_0x488b67&&this['_createCommentThread'](_0x513987,_0x488b67),this['_createMarkersFromRanges'](_0x513987,_0x1dbe81,!!_0x488b67);}['_createMarkersFromRanges'](_0x45bf4d,_0x5881b6,_0x5e4228){this['editor']['model']['change'](_0x377edd=>{for(const _0x19a2b2 of _0x5881b6){const _0xdc8ea4=_0x38f1c9()['substr'](0x1,0x5),_0x1368e3='comment:'+_0x45bf4d+':'+_0xdc8ea4;_0x377edd['addMarker'](_0x1368e3,{'range':_0x19a2b2,'usingOperation':_0x5e4228,'affectsData':_0x5e4228});}});}['_createCommentThread'](_0x39b0b7,_0x2df393){const _0x5c5699=this['editor']['plugins']['get']('CommentsRepository'),_0x157577=this['editor']['config']['get']('collaboration.channelId'),_0x2911e8=this['editor']['plugins']['get']('Users')['me'];if(!_0x2911e8)throw new _0x405026('addcommentthreadcommand-user-not-found',null);_0x5c5699['addCommentThread']({'threadId':_0x39b0b7,'channelId':_0x157577,'comments':[{'authorId':_0x2911e8['id'],'content':_0x2df393,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x26ad31){for(const _0x2099e9 of _0x26ad31['getItems']())if(this['_itemIsContent'](_0x2099e9))return!0x0;return!0x1;}['_itemIsContent'](_0x27ac14){return _0x27ac14['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x27ac14)&&!_0x27ac14['is']('element','tableCell');}['_trimToContent'](_0x34bdb8){const _0x5a1b89=_0x17bcc9=>!this['_itemIsContent'](_0x17bcc9['item']),_0x66c948=_0x34bdb8['start']['getLastMatchingPosition'](_0x5a1b89),_0x41e988=_0x34bdb8['end']['getLastMatchingPosition'](_0x5a1b89,{'direction':'backward'});return this['editor']['model']['createRange'](_0x66c948,_0x41e988);}}class b extends _0xbebcb7{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4cb0ac){super(_0x4cb0ac),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x52cb96=this['editor'],_0xfc816a=_0x52cb96['model']['document']['selection'],_0xc8d7a=_0x2ecd68(()=>this['refreshSelectedViews'](),0xa);_0xfc816a['on']('change:range',(_0x478bdd,_0x14842e)=>{_0x14842e['directChange']&&(_0xc8d7a['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x52cb96['editing']['view']['document'],'change:isFocused',(_0x5af809,_0x95fe12,_0x2a672e)=>{_0x2a672e&&_0xc8d7a();}),this['listenTo'](_0x52cb96['ui']['focusTracker'],'change:isFocused',(_0x5c0ea5,_0x7dcf73,_0x56ddd8)=>{_0x56ddd8||this['fire']('blur',{'isAnnotationTracked':_0x283c05=>this['_editorAnnotationsData']['has'](_0x283c05['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x56a7b3){if(this['_editorAnnotations']['has'](_0x56a7b3['view']))return;this['_editorAnnotations']['add'](_0x56a7b3['view']),this['editor']['ui']['focusTracker']['add'](_0x56a7b3['view']['element']);const _0x3ee81e=this['editor']['plugins']['get'](y);this['listenTo'](_0x3ee81e['collection'],'remove',(_0x1273e8,_0x51c0e4)=>{this['editor']['ui']['focusTracker']['remove'](_0x51c0e4['view']['element']),this['_editorAnnotations']['delete'](_0x51c0e4['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x5ec3c3){if('function'!=typeof _0x5ec3c3)throw new _0x405026('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x5ec3c3);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x2e6ec6,annotations:_0x2a7046}){const _0x1fd5aa=[],_0x144e48=this['editor']['model']['document']['selection'],_0x11eab5=Array['from'](_0x144e48['getRanges']());for(const [_0x3ac833,_0x2a0ea8]of this['_editorAnnotationsData']){const _0x2dd133=_0x1f7e18(_0x2a0ea8),_0x246cd4=_0x2a7046['getByInnerView'](_0x3ac833);_0x2dd133&&_0x246cd4&&_0x1fd5aa['push']({'annotation':_0x246cd4,'range':_0x2dd133});}function _0x1f7e18(_0x1311de){for(const _0x3c8ef3 of _0x1311de)for(const _0x175ffc of _0x11eab5)if(_0x3c8ef3['containsRange'](_0x175ffc,!_0x144e48['isCollapsed']))return _0x3c8ef3;return null;}return _0x1fd5aa['sort']((_0x126090,_0x2d103e)=>{const _0x6d3e92=_0x126090['range'],_0x825b=_0x2d103e['range'];if(!_0x6d3e92['isEqual'](_0x825b)){if(_0x6d3e92['containsRange'](_0x825b,!0x0))return 0x1;if(_0x825b['containsRange'](_0x6d3e92,!0x0))return-0x1;}return _0x126090['annotation']==_0x2e6ec6?-0x1:_0x2d103e['annotation']==_0x2e6ec6?0x1:0x0;})['map'](_0xc2e613=>_0xc2e613['annotation']);}get['_editorAnnotationsData'](){const _0x5bf032=new Map();for(const _0x99e114 of Array['from'](this['_dataCollectors']))for(const [_0x4cd89c,_0x370ec8]of _0x99e114())_0x5bf032['set'](_0x4cd89c,_0x370ec8);return _0x5bf032;}}class st extends _0xbebcb7{['afterInit'](){const _0x530da3=this['editor'];if(!_0x530da3['plugins']['has']('RestrictedEditingModeEditing'))return;_0x530da3['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0xbebcb7{constructor(_0x46a4a5){super(_0x46a4a5),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x172173=this['editor'],_0x3bb10e=_0x172173['commands']['get']('importWord'),_0x3b2e3d=_0x172173['plugins']['get'](it);_0x3bb10e&&(_0x3bb10e['on']('execute',(_0x28718f,[,_0x8fb908])=>{_0x8fb908['collaboration_features']={'comments':!0x0,'user_id':_0x3b2e3d['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x3bb10e,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x462ecd,_0x466d10){const {comment_threads:_0x37c9dc}=_0x466d10;_0x37c9dc&&_0x37c9dc['forEach'](({thread_id:_0x7fac94,comments:_0x54b9eb,is_resolved:_0x47de62})=>{const _0x4d8dd1=new Date(),_0x590558=_0x54b9eb['map'](({author:_0x4dc2fd,content:_0x5387f4,created_at:_0x3a9890})=>({'content':_0x5387f4,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x4d8dd1,'attributes':{'@external':{'authorName':_0x4dc2fd,'createdAt':_0x3a9890?new Date(_0x3a9890):new Date(),'source':'importWord'}}})),_0xa4922=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0xa4922,'threadId':_0x7fac94,'comments':_0x590558,'resolvedAt':_0x47de62?_0x4d8dd1:null});});}}class at extends _0xbebcb7{constructor(_0x1c33f2){super(_0x1c33f2),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x304588=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x304588,'contentInsertion',(_0x1d0d9b,_0x3b638f)=>this['_removeMarkersWithoutThreads'](_0x3b638f['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x3d334d){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x3d334d;const _0x40907b=this['editor']['plugins']['get']('CommentsRepository');for(const _0x3e7f9f of _0x3d334d['keys']()){const [_0x1be578,_0x26bd9c]=_0x3e7f9f['split'](':');'comment'!=_0x1be578||_0x40907b['hasCommentThread'](_0x26bd9c)||_0x3d334d['delete'](_0x3e7f9f);}return _0x3d334d;}['_registerMarkerInClipboardPipeline'](){const _0x1d4b7e=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x3ef68e=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x3ef68e&&_0x1d4b7e['_registerMarkerToCopy']('comment',_0x3ef68e);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x98f228){switch(_0x98f228){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0xc76574){const _0x12d7b6=_0xc76574['split'](':');return{'group':_0x12d7b6[0x0],'id':_0x12d7b6[0x1],'part':_0x12d7b6[0x2]};}class ut extends _0xbebcb7{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x4891f2,_0x1eccef)=>{if(!_0x1eccef['options']['showCommentHighlights'])return null;if(_0x1eccef['options']['ignoreResolvedComments']){const {id:_0x147501}=ft(_0x4891f2['markerName']),_0x32b594=this['editor']['plugins']['get'](o);if(_0x32b594['getCommentThread'](_0x147501)?.['isResolved']&&_0x4891f2['item'])return _0x1eccef['consumable']['consume'](_0x4891f2['item'],'addMarker:'+_0x4891f2['markerName']),_0x1eccef['consumable']['consume'](_0x4891f2['item'],'removeMarker:'+_0x4891f2['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x4fbb79=>{_0x4fbb79['on']('addMarker:comment',(_0x2573c3,_0x3df28b,_0x23c1f9)=>{if(!_0x23c1f9['options']['showCommentHighlights'])return;const _0x27a4cc=_0x3df28b['item'];if(!_0x27a4cc)return;const _0x340a7b=_0x23c1f9['mapper']['toViewElement'](_0x27a4cc);this['editor']['model']['schema']['isObject'](_0x27a4cc)&&_0x340a7b&&!_0x340a7b['getCustomProperty']('widget')&&_0x340a7b['is']('containerElement')&&_0x57a79f(_0x340a7b,_0x23c1f9['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x527f98,{writer:_0x4a756e,options:_0x2c683a})=>{if(!_0x2c683a['showCommentHighlights'])return null;const _0x3a107d=_0x4a756e['createContainerElement']('div'),_0x2ca36a=_0x4a756e['createEmptyElement']('hr');return _0x4a756e['addClass']('ck-horizontal-line',_0x3a107d),_0x4a756e['insert'](_0x4a756e['createPositionAt'](_0x3a107d,0x0),_0x2ca36a),_0x3a107d;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x326189,{writer:_0x1d251a,options:_0x48535b})=>{if(!_0x48535b['showCommentHighlights'])return null;const _0x38e3c9=_0x1d251a['createContainerElement']('span'),_0x49af5a=_0x1d251a['createEmptyElement']('img');return _0x1d251a['addClass']('image-inline',_0x38e3c9),_0x1d251a['insert'](_0x1d251a['createPositionAt'](_0x38e3c9,0x0),_0x49af5a),_0x38e3c9;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x140f88,{writer:_0x5b8c61,options:_0x523404})=>{if(_0x523404['showCommentHighlights'])return _0x5b8c61['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x1c00d4,_0xfb2874,_0x40109c)=>{_0x40109c['options']['showCommentHighlights']&&_0x1c00d4['stop']();},{'priority':'high'});}}class r extends _0xbebcb7{static get['requires'](){return[o,b,it,st,ct,at,ut];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x138dee){super(_0x138dee),this['set']('isThreadsLoadingPaused',!0x0),_0x138dee['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x24478e,_0x423de7,_0x2adc1e,_0x3b59ec)=>{const _0x592cbb=_0x138dee['plugins']['get'](o),_0x126148=_0x2adc1e?ft(_0x2adc1e)['id']:null;_0x138dee['model']['change'](()=>{if(_0x126148){const _0x22e39b=this['getAllMarkersForId'](_0x126148);for(const _0x4398d7 of _0x22e39b)_0x138dee['editing']['reconvertMarker'](_0x4398d7);}if(_0x3b59ec){const {id:_0x409c57}=ft(_0x3b59ec),_0x16a48b=_0x592cbb['getCommentThread'](_0x409c57);if(_0x16a48b&&_0x16a48b['unlinkedAt'])return;if(_0x16a48b&&!_0x16a48b['isAttached'])return;const _0x1b1ca3=this['getAllMarkersForId'](_0x409c57);for(const _0x29ca67 of _0x1b1ca3)_0x138dee['editing']['reconvertMarker'](_0x29ca67);}}),_0x126148&&this['scrollToThreadMarker'](_0x126148);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x34d441=this['editor'],_0x5ca732=_0x34d441['plugins']['get'](o),_0x47970d=_0x34d441['config']['get']('collaboration.channelId'),_0x50d9ec=_0x5ca732['getCommentThreads']()['filter'](_0x62aa47=>_0x62aa47['channelId']!==_0x47970d);_0x34d441['commands']['add']('addCommentThread',new ot(_0x34d441)),this['listenTo'](_0x34d441,'change:isReadOnly',(_0x33275e,_0x4a924d,_0x5c521c)=>{_0x5ca732['switchReadOnly'](_0x5c521c,_0x34d441['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x5ca732,dt('addCommentThread',_0x47970d),(_0x525675,{threadId:_0x4fe70d})=>{const _0x42b152=this['editor']['plugins']['get'](o)['getCommentThread'](_0x4fe70d);_0x42b152?.['unlinkedAt']&&this['_attachArchivedThread'](_0x4fe70d);}),this['listenTo'](_0x5ca732,dt('removeCommentThread',_0x47970d),(_0x5ece4f,{threadId:_0x123bfb})=>{_0x34d441['model']['enqueueChange']({'isUndoable':!0x1},_0x287e12=>{const _0x59481e=this['getAllMarkersForId'](_0x123bfb);for(const _0x9ffbe4 of _0x59481e)_0x287e12['removeMarker'](_0x9ffbe4);});}),this['listenTo'](_0x5ca732,dt('resolveCommentThread',_0x47970d),(_0x308833,{threadId:_0x502dfa})=>{(this['_reconvertMarkers'](_0x502dfa),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x502dfa)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x5ca732,dt('reopenCommentThread',_0x47970d),(_0x2f1b0e,{threadId:_0x30d4ff})=>{this['_reconvertMarkers'](_0x30d4ff);},{'priority':'low'}),this['listenTo'](_0x5ca732,dt('addComment',_0x47970d),(_0x5cc5ef,{threadId:_0x1ed79c,isFromAdapter:_0x24156d})=>{const _0x194d50=this['getAllMarkersForId'](_0x1ed79c);if(_0x24156d||0x0==_0x194d50['length']||!_0x5ca732['hasCommentThread'](_0x1ed79c))return;0x1===_0x5ca732['getCommentThread'](_0x1ed79c)['length']&&_0x34d441['model']['enqueueChange']({'isUndoable':!0x1},_0x3ea0e6=>{for(const _0x4bba91 of _0x194d50)_0x3ea0e6['updateMarker'](_0x4bba91,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x50d9ec);}['afterInit'](){!async function(_0x5d0209){const _0x2c2460=_0x4a0a1d([0x4b,0x70,0x4f,0x42,0x4a,0x47,0x4e,0x53,0x45,0x67,0x71,0x43,0x79,0x66,0x56,0x46,0x31,0x6b,0x5a,0x38,0x6c,0x62,0x6e,0x52,0x6a,0x4d,0x37,0x65,0x49,0x7a,0x41,0x73,0x44,0x51,0x48,0x77,0x39,0x61,0x54,0x68,0x75,0x36,0x72,0x63,0x59,0x69,0x30,0x35,0x55,0x6d,0x50,0x4c,0x34,0x64,0x33,0x58,0x32,0x57,0x6f,0x74,0x76,0x78]),_0x207de6=0x73460ab3,_0x3419b8=0x734189d3^_0x207de6,_0x59d8a0=window[_0x4a0a1d([0x44,0x61,0x74,0x65])][_0x4a0a1d([0x6e,0x6f,0x77])](),_0x163652=_0x5d0209[_0x4a0a1d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x41299f=new window[(_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3320fc=>{_0x163652[_0x4a0a1d([0x6f,0x6e,0x63,0x65])](_0x4a0a1d([0x72,0x65,0x61,0x64,0x79]),_0x3320fc);}),_0x368212={[_0x4a0a1d([0x6b,0x74,0x79])]:_0x4a0a1d([0x45,0x43]),[_0x4a0a1d([0x75,0x73,0x65])]:_0x4a0a1d([0x73,0x69,0x67]),[_0x4a0a1d([0x63,0x72,0x76])]:_0x4a0a1d([0x50,0x2d,0x32,0x35,0x36]),[_0x4a0a1d([0x78])]:_0x4a0a1d([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]),[_0x4a0a1d([0x79])]:_0x4a0a1d([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]),[_0x4a0a1d([0x61,0x6c,0x67])]:_0x4a0a1d([0x45,0x53,0x32,0x35,0x36])},_0x5832c3=_0x163652[_0x4a0a1d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4a0a1d([0x67,0x65,0x74])](_0x4a0a1d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x87848e(){let _0x35b279,_0x44d5fd=null,_0x30c2e2=null;try{if(_0x5832c3==_0x4a0a1d([0x47,0x50,0x4c]))return _0x4a0a1d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x35b279=_0x166add(),!_0x35b279)return _0x4a0a1d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x35b279[_0x4a0a1d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x30c2e2=_0x300654(_0x35b279[_0x4a0a1d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x35b279[_0x4a0a1d([0x6a,0x74,0x69])])),await _0x4418bf()?_0x4737ea()?_0x5427d0()?_0x4a0a1d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3cbc30()?(_0x35b279[_0x4a0a1d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a0a1d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x44d5fd=_0x4f2826(_0x4a0a1d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x33d35c()):_0x4a0a1d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4a0a1d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4a0a1d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4a0a1d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5427d0(){const _0x1d1fa3=[_0x4a0a1d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4a0a1d([0x74,0x72,0x69,0x61,0x6c])][_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x35b279[_0x4a0a1d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x59d8a0/0x3e8:0xe10*_0x3419b8;return _0x35b279[_0x4a0a1d([0x65,0x78,0x70])]<_0x1d1fa3;}function _0x4737ea(){const _0x51ab48=_0x35b279[_0x4a0a1d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x51ab48)return!0x1;if(_0x51ab48[_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a0a1d([0x2a])))return!0x0;if(_0x51ab48[_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a0a1d([0x43,0x4d,0x54])))return!0x0;if(_0x51ab48[_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a0a1d([0x54,0x52,0x49,0x4c,0x49,0x55,0x4d]))&&_0x383447())return!0x0;if(_0x51ab48[_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a0a1d([0x52,0x43,0x4d,0x54]))){if(_0x552fa4())return!0x0;if(_0x389420()||_0x388214())return!0x0;}return!0x1;}function _0x3cbc30(){const _0x12ca49=_0x35b279[_0x4a0a1d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x12ca49||0x0==_0x12ca49[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xc56ce2}=new URL(window[_0x4a0a1d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x12ca49[_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc56ce2))return!0x0;const _0x409c4c=_0xc56ce2[_0x4a0a1d([0x73,0x70,0x6c,0x69,0x74])](_0x4a0a1d([0x2e]));return _0x12ca49[_0x4a0a1d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x777582=>_0x777582[_0x4a0a1d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a0a1d([0x2a])))[_0x4a0a1d([0x6d,0x61,0x70])](_0x717fcf=>_0x717fcf[_0x4a0a1d([0x73,0x70,0x6c,0x69,0x74])](_0x4a0a1d([0x2e])))[_0x4a0a1d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x140164=>_0x140164[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x409c4c[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4a0a1d([0x6d,0x61,0x70])](_0x5892a0=>Array(_0x409c4c[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5892a0[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4a0a1d([0x66,0x69,0x6c,0x6c])](_0x5892a0[0x0]===_0x4a0a1d([0x2a])?_0x4a0a1d([0x2a]):'')[_0x4a0a1d([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5892a0))[_0x4a0a1d([0x73,0x6f,0x6d,0x65])](_0x2a26ad=>_0x409c4c[_0x4a0a1d([0x65,0x76,0x65,0x72,0x79])]((_0x320ca4,_0x4b8581)=>_0x2a26ad[_0x4b8581]===_0x320ca4||_0x2a26ad[_0x4b8581]===_0x4a0a1d([0x2a])));}function _0x33d35c(){return _0x44d5fd&&_0x30c2e2?new window[(_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x537017,_0x33fc40)=>{_0x44d5fd[_0x4a0a1d([0x74,0x68,0x65,0x6e])](_0x537017,_0x33fc40),_0x30c2e2[_0x4a0a1d([0x74,0x68,0x65,0x6e])](_0x1911b0=>{_0x1911b0!=_0x4a0a1d([0x56,0x61,0x6c,0x69,0x64])&&_0x537017(_0x1911b0);},_0x33fc40);}):_0x44d5fd||_0x30c2e2||_0x4a0a1d([0x56,0x61,0x6c,0x69,0x64]);}}function _0x300654(_0x73f427,_0x3c0a72){return new window[(_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2057a5=>{if(_0x3088bb())return _0x2057a5(_0x4a0a1d([0x56,0x61,0x6c,0x69,0x64]));_0x411850(),_0x163652[_0x4a0a1d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4a0a1d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1a8a3b=!0x1;const _0x102312=_0x38f1c9();function _0x534c40(_0x935e17){return!!_0x935e17&&(typeof _0x935e17===_0x4a0a1d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x935e17===_0x4a0a1d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x935e17[_0x4a0a1d([0x74,0x68,0x65,0x6e])]===_0x4a0a1d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x935e17[_0x4a0a1d([0x63,0x61,0x74,0x63,0x68])]===_0x4a0a1d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x139f83(_0x1b3349){_0x55585a(_0x1b3349)[_0x4a0a1d([0x74,0x68,0x65,0x6e])](_0x395476=>{if(!_0x395476||_0x395476[_0x4a0a1d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4a0a1d([0x6f,0x6b]))return _0x4a0a1d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x37c263(_0x2f492c(_0x102312+_0x3c0a72))!=_0x395476[_0x4a0a1d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4a0a1d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4a0a1d([0x56,0x61,0x6c,0x69,0x64]);})[_0x4a0a1d([0x74,0x68,0x65,0x6e])](_0x4bc1d1=>(_0x4e37df(),_0x4bc1d1),()=>{const _0x43f56d=_0x461ea0();return null==_0x43f56d?(_0x4e37df(),_0x4a0a1d([0x56,0x61,0x6c,0x69,0x64])):_0x4a0a1d(_0x59d8a0-_0x43f56d>(0x574a8eb3^_0x207de6)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4a0a1d([0x74,0x68,0x65,0x6e])](_0x2057a5)[_0x4a0a1d([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2057a5(_0x4a0a1d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1a930f=0x7370e433^_0x207de6;function _0x4e37df(){const _0x510d3d=_0x4a0a1d([0x6c,0x6c,0x63,0x74,0x2d])+_0x37c263(_0x2f492c(_0x73f427)),_0x31882a=_0x46ff8f(_0x37c263(window[_0x4a0a1d([0x4d,0x61,0x74,0x68])][_0x4a0a1d([0x63,0x65,0x69,0x6c])](_0x59d8a0/_0x1a930f)));window[_0x4a0a1d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a0a1d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x510d3d,_0x31882a);}function _0x461ea0(){const _0x5aea3c=_0x4a0a1d([0x6c,0x6c,0x63,0x74,0x2d])+_0x37c263(_0x2f492c(_0x73f427)),_0x325769=window[_0x4a0a1d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a0a1d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5aea3c);return _0x325769?window[_0x4a0a1d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x46ff8f(_0x325769),0x10)*_0x1a930f:null;}function _0x55585a(_0x44fcf7){return new window[(_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3bde10,_0x511aad)=>{_0x44fcf7[_0x4a0a1d([0x74,0x68,0x65,0x6e])](_0x3bde10,_0x511aad),window[_0x4a0a1d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x511aad,0x7347de73^_0x207de6);});}}_0x163652[_0x4a0a1d([0x6f,0x6e])](_0x4a0a1d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5ee338,_0x317674)=>{if(_0x317674[0x0]!=_0x73f427)return _0x2057a5(_0x4a0a1d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x317674[0x1]={..._0x317674[0x1],[_0x4a0a1d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x102312};},{[_0x4a0a1d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a0a1d([0x68,0x69,0x67,0x68])}),_0x163652[_0x4a0a1d([0x6f,0x6e])](_0x4a0a1d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3deb43=>{_0x534c40(_0x3deb43[_0x4a0a1d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1a8a3b=!0x0,_0x139f83(_0x3deb43[_0x4a0a1d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4a0a1d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a0a1d([0x6c,0x6f,0x77])}),_0x41299f[_0x4a0a1d([0x74,0x68,0x65,0x6e])](()=>{_0x1a8a3b||_0x2057a5(_0x4a0a1d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3088bb(){return _0x163652[_0x4a0a1d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a0a1d([0x76,0x69,0x65,0x77])][_0x4a0a1d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4a0a1d([0x61,0x75,0x74,0x6f]);}function _0x411850(){_0x163652[_0x4a0a1d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a0a1d([0x76,0x69,0x65,0x77])][_0x4a0a1d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4a0a1d([0x61,0x75,0x74,0x6f]);}}function _0x4f2826(_0x28a4ae){const _0x16566c=[new window[(_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22a99a=>setTimeout(_0x22a99a,0x734f347f^_0x207de6)),_0x41299f[_0x4a0a1d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1acc58=>{let _0x233d06=0x0;_0x163652[_0x4a0a1d([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a0a1d([0x6f,0x6e])](_0x4a0a1d([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x3725ee,_0x178075)=>{_0x178075[0x0][_0x4a0a1d([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x233d06++,_0x233d06==(0x73460f5b^_0x207de6)&&(_0x1acc58(),_0x3725ee[_0x4a0a1d([0x6f,0x66,0x66])]());});}))];return window[_0x4a0a1d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4a0a1d([0x72,0x61,0x63,0x65])](_0x16566c)[_0x4a0a1d([0x74,0x68,0x65,0x6e])](()=>_0x28a4ae);}async function _0x2af08b(){await _0x41299f,_0x163652[_0x4a0a1d([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a0a1d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x34cd8c,_0x163652[_0x4a0a1d([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a0a1d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x34cd8c,_0x163652[_0x4a0a1d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4a0a1d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x383447(){return window[_0x4a0a1d([0x67,0x6c,0x6f,0x62])]&&window[_0x4a0a1d([0x67,0x6c,0x6f,0x62])][_0x4a0a1d([0x74,0x72,0x69,0x6c,0x69,0x75,0x6d,0x56,0x65,0x72,0x73,0x69,0x6f,0x6e])];}function _0x552fa4(){return _0x154d4b(_0x4a0a1d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x10ba64(_0x4a0a1d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4a0a1d([0x73,0x74,0x61,0x74,0x65])]==_0x4a0a1d([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x389420(){return _0x154d4b(_0x4a0a1d([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 _0x388214(){return _0x154d4b(_0x4a0a1d([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1fe820(_0x393a77){const _0x28d9c4=_0x2e93b2();_0x163652[_0x28d9c4]=_0x4a0a1d([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x393a77,_0x393a77!=_0x4a0a1d([0x56,0x61,0x6c,0x69,0x64])&&_0x2af08b();}function _0x2e93b2(){const _0x5191b2=window[_0x4a0a1d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4a0a1d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4a0a1d([0x6e,0x6f,0x77])]())[_0x4a0a1d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4a0a1d([0x2e]),'');let _0x15e328=_0x4a0a1d([0x4b]);for(let _0x1984f7=0x0;_0x1984f7<_0x5191b2[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1984f7+=0x2){let _0xffe1a2=window[_0x4a0a1d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5191b2[_0x4a0a1d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1984f7,_0x1984f7+0x2));_0xffe1a2>=_0x2c2460[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xffe1a2-=_0x2c2460[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x15e328+=_0x2c2460[_0xffe1a2];}return _0x15e328;}function _0x166add(){const _0x4b60ca=_0x5832c3[_0x4a0a1d([0x73,0x70,0x6c,0x69,0x74])](_0x4a0a1d([0x2e]));if(0x3!=_0x4b60ca[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x36f205(_0x4b60ca[0x1]);function _0x36f205(_0xbfb4c5){const _0x1634af=_0x45097e(_0xbfb4c5);return _0x1634af&&_0xa1198d()?_0x1634af:null;function _0xa1198d(){const _0x5a22f6=_0x1634af[_0x4a0a1d([0x6a,0x74,0x69])],_0x2ffd7f=window[_0x4a0a1d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5a22f6[_0x4a0a1d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5a22f6[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5628a8={..._0x1634af,[_0x4a0a1d([0x6a,0x74,0x69])]:_0x5a22f6[_0x4a0a1d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5a22f6[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5628a8[_0x4a0a1d([0x76,0x63])],_0x2f492c(_0x5628a8)==_0x2ffd7f;}}}async function _0x4418bf(){let _0x1ef062=!0x0;try{const _0x28e2dc=_0x5832c3[_0x4a0a1d([0x73,0x70,0x6c,0x69,0x74])](_0x4a0a1d([0x2e])),[_0x49a28d,_0x3dec54,_0xd3939]=_0x28e2dc;return _0x104d0f(_0x49a28d),await _0x75edcc(_0x49a28d,_0x3dec54,_0xd3939),_0x1ef062;}catch{return!0x1;}function _0x104d0f(_0x2e7127){const _0x5293c6=_0x45097e(_0x2e7127);_0x5293c6&&_0x5293c6[_0x4a0a1d([0x61,0x6c,0x67])]==_0x4a0a1d([0x45,0x53,0x32,0x35,0x36])||(_0x1ef062=!0x1);}async function _0x75edcc(_0x214aab,_0x50afcb,_0x59b928){const _0x294763=window[_0x4a0a1d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4a0a1d([0x66,0x72,0x6f,0x6d])](_0x178b5f(_0x59b928),_0x887c02=>_0x887c02[_0x4a0a1d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x141489=new window[(_0x4a0a1d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4a0a1d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x214aab+_0x4a0a1d([0x2e])+_0x50afcb),_0x3a3688=window[_0x4a0a1d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4a0a1d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3a3688)return;const _0x1515d6=await _0x3a3688[_0x4a0a1d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4a0a1d([0x6a,0x77,0x6b]),_0x368212,{[_0x4a0a1d([0x6e,0x61,0x6d,0x65])]:_0x4a0a1d([0x45,0x43,0x44,0x53,0x41]),[_0x4a0a1d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4a0a1d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4a0a1d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3a3688[_0x4a0a1d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4a0a1d([0x6e,0x61,0x6d,0x65])]:_0x4a0a1d([0x45,0x43,0x44,0x53,0x41]),[_0x4a0a1d([0x68,0x61,0x73,0x68])]:{[_0x4a0a1d([0x6e,0x61,0x6d,0x65])]:_0x4a0a1d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x1515d6,_0x294763,_0x141489)||(_0x1ef062=!0x1);}}function _0x45097e(_0xf83099){return _0xf83099[_0x4a0a1d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4a0a1d([0x65,0x79]))?JSON[_0x4a0a1d([0x70,0x61,0x72,0x73,0x65])](_0x178b5f(_0xf83099)):null;}function _0x178b5f(_0x4f84c6){return window[_0x4a0a1d([0x61,0x74,0x6f,0x62])](_0x4f84c6[_0x4a0a1d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4a0a1d([0x2b]))[_0x4a0a1d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4a0a1d([0x2f])));}function _0x2f492c(_0x10d335){let _0x119c2a=0x1505;function _0x42777b(_0x1eb533){for(let _0x4f053a=0x0;_0x4f053a<_0x1eb533[_0x4a0a1d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4f053a++){const _0x2f62d0=_0x1eb533[_0x4a0a1d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4f053a);_0x119c2a=(_0x119c2a<<0x5)+_0x119c2a+_0x2f62d0,_0x119c2a&=_0x119c2a;}}function _0x3766ef(_0x4867df){Array[_0x4a0a1d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4867df)?_0x4867df[_0x4a0a1d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3766ef):_0x4867df&&typeof _0x4867df==_0x4a0a1d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4a0a1d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4867df)[_0x4a0a1d([0x73,0x6f,0x72,0x74])]()[_0x4a0a1d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4b9af6,_0x301ea4])=>{_0x42777b(_0x4b9af6),_0x3766ef(_0x301ea4);}):_0x42777b(window[_0x4a0a1d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4867df));}return _0x3766ef(_0x10d335),_0x119c2a>>>0x0;}function _0x37c263(_0x42761f){return _0x42761f[_0x4a0a1d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4a0a1d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4a0a1d([0x30]));}function _0x46ff8f(_0x421bf9){return _0x421bf9[_0x4a0a1d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4a0a1d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4a0a1d([0x6a,0x6f,0x69,0x6e])]('');}function _0x154d4b(_0xb609f6){return _0x163652[_0x4a0a1d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a0a1d([0x68,0x61,0x73])](_0xb609f6);}function _0x10ba64(_0x44d4e4){return _0x163652[_0x4a0a1d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a0a1d([0x67,0x65,0x74])](_0x44d4e4);}function _0x34cd8c(){}function _0x4a0a1d(_0x1a0cda){return _0x1a0cda['map'](_0x3196fe=>String['fromCharCode'](_0x3196fe))['join']('');}_0x1fe820(await _0x87848e());}(this);}['destroy'](){const _0x2c63b5=this['editor']['plugins']['get'](o),_0x54d160=this['editor']['config']['get']('collaboration.channelId');for(const _0x4f8c9a of _0x2c63b5['getCommentThreads']({'channelId':_0x54d160}))_0x2c63b5['_detachCommentThread'](_0x4f8c9a['id']),_0x2c63b5['_threads']['delete'](_0x4f8c9a['id']);super['destroy']();}['hasMarkerForId'](_0x1b8452){return this['getAllMarkersForId'](_0x1b8452)['length']>0x0;}['getAllMarkersForId'](_0x362b99){const _0x3f2ff2=[];for(const _0x4da893 of this['editor']['model']['markers'])_0x4da893['name']['startsWith']('comment:'+_0x362b99)&&_0x3f2ff2['push'](_0x4da893);return _0x3f2ff2;}['scrollToThreadMarker'](_0x4207ad){setTimeout(()=>{const _0x30ec79=this['_getTargetForId'](_0x4207ad);if(!_0x30ec79)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x4207ad&&nt({'target':_0x30ec79[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x5acf7d){this['editor']['model']['change'](()=>{for(const _0x151196 of this['getAllMarkersForId'](_0x5acf7d))this['editor']['editing']['reconvertMarker'](_0x151196);});}['_attachArchivedThread'](_0x261f97){const _0x3d7fa8=this['editor']['plugins']['get'](o),_0x30203c=this['editor']['plugins']['get'](b),_0x3f8465=_0x3d7fa8['getCommentThread'](_0x261f97);if(!_0x3f8465['isAttached']){const _0x2e0cde=_0x3f8465['attachTo'](()=>this['_getTargetForId'](_0x3f8465['id']));_0x30203c['registerAnnotation'](_0x2e0cde),_0x3f8465['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x56dde6=this['editor'],_0xc2e17c=_0x56dde6['plugins']['get'](it);_0x56dde6['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x515934,_0x5c765d)=>{const {id:_0x58ecc3}=ft(_0x515934['markerName']),_0x2313a9=_0x56dde6['plugins']['get'](o)['getCommentThread'](_0x58ecc3),_0xcde2fe=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x58ecc3;let _0x4bd41a;if(_0x2313a9&&_0x2313a9['isResolved']&&!_0xcde2fe&&_0x515934['item'])return _0x5c765d['consumable']['consume'](_0x515934['item'],'addMarker:'+_0x515934['markerName']),_0x5c765d['consumable']['consume'](_0x515934['item'],'removeMarker:'+_0x515934['markerName']),null;const _0x45698c=['ck-comment-marker'];return _0xcde2fe&&_0x45698c['push']('ck-comment-marker--active'),_0x4bd41a=_0x2313a9?.['length']?_0x2313a9['comments']['first']['author']['id']:_0xc2e17c['me']['id'],{'classes':_0x45698c,'attributes':{'data-comment':_0x58ecc3,'data-author-id':_0x4bd41a}};}}),_0x56dde6['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x505d9f,{options:_0xc528ba})=>{if(_0xc528ba['showCommentHighlights'])return null;const _0x4041c3=_0x56dde6['plugins']['get'](o),_0x55f266=_0x56dde6['model']['markers']['get'](_0x505d9f),{id:_0x1a638b,part:_0x472c17}=ft(_0x505d9f);return _0x55f266&&!_0x55f266['affectsData']||_0xc528ba['ignoreResolvedComments']&&_0x4041c3['getCommentThread'](_0x1a638b)?.['isResolved']?null:{'group':'comment','name':_0x472c17?_0x1a638b+':'+_0x472c17:_0x1a638b};}}),_0x56dde6['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x74ac8a,{writer:_0x3ae37c})=>_0x3ae37c['createElement']('$marker',{'data-name':'comment:'+_0x74ac8a['getAttribute']('id')})}),_0x56dde6['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x11244d=this['editor'],_0x576618=_0x11244d['plugins']['get'](o),_0x2c6691=new Set(),_0x14c10c=new Set();_0x11244d['model']['document']['registerPostFixer'](_0x57103a=>{let _0x448440=!0x1;for(const {name:_0x41592a,data:_0x44dd3e}of _0x11244d['model']['document']['differ']['getChangedMarkers']()){const {group:_0x598732,id:_0x590fdf}=ft(_0x41592a);let _0x45c0fd=_0x44dd3e['newRange'];if('comment'!==_0x598732||!_0x45c0fd)continue;const _0x311475='$graveyard'===_0x45c0fd['root']['rootName'];_0x311475||(_0x45c0fd=ht(_0x45c0fd,_0x11244d['model']),!_0x45c0fd||_0x45c0fd['isCollapsed']||!_0x44dd3e['newRange']||_0x45c0fd['isEqual'](_0x44dd3e['newRange']))?_0x11244d['model']['hasContent'](_0x45c0fd)&&!_0x311475?this['isThreadsLoadingPaused']?_0x2c6691['add'](_0x41592a):this['_handleThreadMarker'](_0x41592a,_0x590fdf):(_0x14c10c['add'](_0x41592a),_0x2c6691['delete'](_0x41592a),_0x57103a['removeMarker'](_0x41592a),_0x448440=!0x0):(_0x57103a['updateMarker'](_0x41592a,{'range':_0x45c0fd}),_0x448440=!0x0);}return _0x448440;}),this['on']('change:isThreadsLoadingPaused',(_0x5d23f6,_0x4cdb84,_0x5705a7)=>{if(!_0x5705a7&&_0x2c6691['size'])for(const _0x3ec4c1 of _0x2c6691){const {id:_0x17b61a}=ft(_0x3ec4c1);_0x2c6691['delete'](_0x3ec4c1),_0x11244d['model']['markers']['get'](_0x3ec4c1)&&this['_handleThreadMarker'](_0x3ec4c1,_0x17b61a);}}),this['listenTo'](_0x11244d['model']['document'],'change',()=>{for(const {name:_0x50b906,data:{newRange:_0x3c29c1}}of _0x11244d['model']['document']['differ']['getChangedMarkers']()){const {group:_0x264cf3,id:_0x52508d}=ft(_0x50b906);if('comment'!==_0x264cf3)continue;const _0x32079a=_0x576618['getCommentThread'](_0x52508d),_0x5b7294=this['hasMarkerForId'](_0x52508d);_0x32079a&&(!_0x32079a['_hasTargetInContent']&&_0x3c29c1&&_0x11244d['editing']['view']['once']('render',()=>{const _0x30b5a3=_0x11244d['plugins']['get'](y),_0x5b1461=_0x576618['_threadToController']['get'](_0x32079a)['view'];_0x30b5a3['getByInnerView'](_0x5b1461)['refreshVisibility']();},{'priority':'low'}),_0x32079a['_hasTargetInContent']=_0x5b7294||!!_0x3c29c1),_0x3c29c1||(_0x14c10c['add'](_0x50b906),_0x2c6691['delete'](_0x50b906));}for(const _0xcf1338 of _0x14c10c){const {id:_0x43542e}=ft(_0xcf1338),_0x5bc36=_0x576618['getCommentThread'](_0x43542e);if(_0x2c6691['delete'](_0xcf1338),!_0x5bc36)continue;const _0xfed31a=this['hasMarkerForId'](_0x43542e);_0xfed31a||_0x5bc36['isSubmitted']?_0xfed31a||_0x5bc36['unlinkedAt']||_0x5bc36['setUnlinkedAt'](new Date()):_0x5bc36['remove']();}_0x14c10c['clear']();});}['_handleInitialThreads'](_0x5e199b){_0x5e199b['forEach'](_0x4f74c3=>{_0x4f74c3['unlinkedAt']&&this['_attachArchivedThread'](_0x4f74c3['id']);});}['_getTargetForId'](_0x1c7acc){const _0x54b2c6=this['editor'],_0x2bfd66=this['getAllMarkersForId'](_0x1c7acc);return et(_0x54b2c6['editing'],_0x2bfd66);}['_getTextContext'](_0x1d3aca){const _0x3a732c=this['getAllMarkersForId'](_0x1d3aca);let _0x54cb97='',_0x3916a7=!0x1;for(const _0x51f76d of _0x3a732c){const _0x607db4=_0x51f76d['getRange']();for(const _0x37b9e8 of Array['from'](_0x607db4['getItems']()))_0x37b9e8['is']('$textProxy')?(_0x54cb97&&_0x3916a7&&(_0x54cb97+='\x20',_0x3916a7=!0x1),_0x54cb97+=_0x37b9e8['data']):_0x3916a7=!0x0;_0x3916a7=!0x0;}return _0x54cb97['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x268e17,_0x5802c7){const _0x2b413e=this['editor'],_0xc3c37=_0x2b413e['plugins']['get'](o);let _0x25e124=_0xc3c37['getCommentThread'](_0x5802c7);const _0x26e718=_0x2b413e['config']['get']('collaboration.channelId'),_0x4b0de1=_0x2b413e['plugins']['get'](b);if(_0x25e124&&(_0x25e124['unlinkedAt']&&_0x25e124['setUnlinkedAt'](null),_0x25e124['isAttached']))return _0x25e124;return!this['getAllMarkersForId'](_0x5802c7)[0x0]['managedUsingOperations']?_0x2b413e['editing']['view']['once']('render',()=>{if(_0xc3c37['getCommentThread'](_0x5802c7))return;const _0x3747cd=_0x2b413e['plugins']['get'](y);_0x25e124=_0xc3c37['openNewCommentThread']({'channelId':_0x26e718,'threadId':_0x5802c7,'target':()=>this['_getTargetForId'](_0x5802c7),'context':{'type':'text','value':this['_getTextContext'](_0x5802c7)}});const _0x5a3ca1=_0xc3c37['_threadToController']['get'](_0x25e124)['view'],_0x3d1ed0=_0x3747cd['getByInnerView'](_0x5a3ca1);_0x3d1ed0&&_0x4b0de1['registerAnnotation'](_0x3d1ed0);},{'priority':'low'}):_0xc3c37['fetchCommentThread']({'channelId':_0x26e718,'threadId':_0x5802c7})['then'](_0x1d1470=>{if('destroyed'!==_0x2b413e['state']){if(_0x25e124=_0x1d1470,_0x25e124&&!_0x25e124['isAttached']){const _0x2f90a9=_0x25e124['attachTo'](()=>this['_getTargetForId'](_0x5802c7));_0x4b0de1['registerAnnotation'](_0x2f90a9),_0x25e124['isResolved']&&this['_reconvertMarkers'](_0x5802c7);}else{if(!_0x25e124){const _0x1c3f53=this['getAllMarkersForId'](_0x5802c7);_0x2b413e['model']['change'](_0x52f54b=>{for(const _0x4b30bc of _0x1c3f53)_0x52f54b['removeMarker'](_0x4b30bc);});}}}}),_0x25e124;}['_handleThreadMarker'](_0x1520ba,_0x29d97f){const _0xde14d2=this['_attachMarkerToThread'](_0x1520ba,_0x29d97f);_0xde14d2&&!_0xde14d2['context']&&_0xde14d2['setContext']({'type':'text','value':this['_getTextContext'](_0x29d97f)});}['_initAriaMarkerChangeAnnouncements'](){const _0x153f5e=this['editor'];rt(_0x153f5e['model'],({left:_0x32cfaa,entered:_0x57b476})=>{for(const _0x5df176 of _0x32cfaa)if(mt(_0x5df176)){_0x153f5e['ui']['ariaLiveAnnouncer']['announce'](N(_0x153f5e['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x3dc6d2 of _0x57b476)if(mt(_0x3dc6d2)){_0x153f5e['ui']['ariaLiveAnnouncer']['announce'](N(_0x153f5e['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x1f5de0)));break;}});}}function dt(_0x217e58,_0x6947ad){return _0x6947ad?_0x217e58+':'+_0x6947ad:_0x217e58;}function ht(_0x33b277,_0x4ff4a1){const _0x3bb430=_0x4ff4a1['schema'],_0x4c06d4=_0x4ff4a1['createRange'](_0x33b277['start']);for(const _0x53c17b of _0x33b277['getWalker']()){const {type:_0x4f64dd,item:_0xebd378,nextPosition:_0x51e78f}=_0x53c17b;if('text'===_0x4f64dd||_0x3bb430['isObject'](_0xebd378)){const _0x467193=_0x4ff4a1['createPositionBefore'](_0xebd378);_0x4c06d4['isCollapsed']&&(_0x4c06d4['start']=_0x467193),_0x4c06d4['end']=_0x51e78f;}}return _0x4c06d4;}function mt(_0x2a9bf1){return'comment'===ft(_0x2a9bf1['name'])['group'];}class s extends _0xbebcb7{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,r,b,y];}get['CommentsListView'](){return te;}get['CommentThreadInputView'](){return ie;}['init'](){const _0x493624=this['editor'],_0x2095cd=_0x493624['plugins']['get'](o),_0x2abdd3=_0x493624['plugins']['get'](r),_0xee7c55=_0x493624['plugins']['get'](y),_0x106894=_0x493624['plugins']['get'](b);_0x493624['ui']['componentFactory']['add']('comment',()=>{const _0x31cdc8=this['_createUIButton'](_0x55c6d4);return _0x31cdc8['tooltip']=!0x0,_0x31cdc8;}),_0x493624['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x28e15f)),_0x106894['addSourceCollector'](()=>{const _0x6c6436=[];for(const [_0x14ef32,_0x292ac3]of _0x2095cd['_threadToController']){const _0x23cede=_0x2abdd3['getAllMarkersForId'](_0x14ef32['id']),_0x5e9fff=_0x23cede['map'](_0x5b8c06=>_0x5b8c06['getRange']());_0x23cede['length']>0x0&&_0x6c6436['push']([_0x292ac3['view'],_0x5e9fff]);}return _0x6c6436;}),this['listenTo'](_0xee7c55,'change:activeAnnotations',(_0xe15002,_0x1ace18,_0x477724)=>{const _0xd9364a=Array['from'](_0x477724)['map'](_0x3c6dd5=>_0x3c6dd5['innerView'])['find'](_0x27d741=>_0x2095cd['_viewToController']['has'](_0x27d741));if(!_0xd9364a)return void(_0x2abdd3['activeMarker']=null);const _0x29378c=_0x2095cd['_viewToController']['get'](_0xd9364a)['model']['id'],_0x4dff80='comment:'+_0x29378c;_0x29378c&&_0x2abdd3['hasMarkerForId'](_0x29378c)?_0x2abdd3['activeMarker']=_0x4dff80:_0x2abdd3['activeMarker']&&(_0x2abdd3['activeMarker']=null);}),this['listenTo'](_0x2095cd,'removeCommentThread',(_0x232523,{threadId:_0x275aff,isFromAdapter:_0x1be117})=>{!_0x1be117&&_0x493624['ui']['focusTracker']['isFocused']&&_0x2abdd3['hasMarkerForId'](_0x275aff)&&_0x493624['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x2095cd,'addComment',(_0x227296,{threadId:_0xd787d,isFromAdapter:_0x12783c})=>{if(_0x12783c||!_0x2abdd3['hasMarkerForId'](_0xd787d)||!_0x2095cd['hasCommentThread'](_0xd787d))return;0x1===_0x2095cd['getCommentThread'](_0xd787d)['length']&&(_0x493624['editing']['view']['focus'](),_0x227296['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x347af6=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4e77f5;for(const _0x46b4d9 in _0x347af6){const _0x1911a2=_0x46b4d9,_0x32fc70=_0x347af6[_0x1911a2];if('commentsLicenseKeyValid'==_0x32fc70||'commentsLicenseKeyInvalid'==_0x32fc70||'commentsLicenseKeyExpired'==_0x32fc70||'commentsLicenseKeyDomainLimit'==_0x32fc70||'commentsLicenseKeyNotAllowed'==_0x32fc70||'commentsLicenseKeyEvaluationLimit'==_0x32fc70||'commentsLicenseKeyUsageLimit'==_0x32fc70){delete _0x347af6[_0x1911a2],_0x4e77f5=_0x32fc70,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x4e77f5&&_0x347af6['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x4e77f5&&_0x347af6['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x4e77f5&&_0x347af6['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x4e77f5&&_0x347af6['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x4e77f5&&_0x347af6['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyUsageLimit'==_0x4e77f5&&_0x347af6['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x38b144){const _0x2dc791=this['editor'],_0x30a515=new _0x38b144(_0x2dc791['locale']),_0x28f158=_0x2dc791['commands']['get']('addCommentThread');return _0x30a515['set']({'label':N(_0x2dc791['locale'],'Comment'),'icon':_0x2676b4}),_0x30a515['bind']('isEnabled')['to'](_0x28f158,'isEnabled',_0x28f158,'hasContent',(_0x3811b8,_0x15447a)=>_0x3811b8&&_0x15447a),this['listenTo'](_0x30a515,'execute',()=>{_0x28f158['execute']();}),_0x30a515;}}class i extends _0xbebcb7{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x25f973){super(_0x25f973),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x39b461,_0x284fc3,_0x196b39)=>{_0x196b39?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x9e3d86,_0x43e4d7]of this['editor']['commands'])_0x43e4d7['affectsData']&&'addCommentThread'!==_0x9e3d86&&_0x43e4d7['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('RevisionTracker'))&&this['editor']['plugins']['get']('RevisionTracker')['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x358d18=this['editor']['editing']['view']['document'];this['listenTo'](_0x358d18,'cut',_0x11ae8d=>_0x11ae8d['stop'](),{'priority':'highest'}),this['listenTo'](_0x358d18,'clipboardInput',_0x314472=>_0x314472['stop'](),{'priority':'highest'}),this['listenTo'](_0x358d18,'delete',_0x49e26a=>_0x49e26a['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x3ab447,_0x4fdbcf]of this['editor']['commands'])_0x4fdbcf['affectsData']&&'addCommentThread'!==_0x3ab447&&_0x4fdbcf['clearForceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['clearForceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['clearForceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['clearForceDisabled']('commentsOnlyMode'),this['stopListening'](this['editor']['editing']['view']['document']);}}class j extends _0x2a0d5d{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2f7daf){super(_0x2f7daf),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0xb5bb58=this['context']['plugins']['get'](y);this['listenTo'](_0xb5bb58,'_activateAnnotation',(_0x354dcd,_0x6401bf)=>{for(const _0x32fb71 of this['activeUIs']){const _0x1bfec6=this['_uis']['get'](_0x32fb71);(0x0,this['uisData']['get'](_0x32fb71)['filter'])(_0x6401bf)&&_0x1bfec6['setActiveAnnotation'](_0x6401bf);}}),this['listenTo'](_0xb5bb58,'_deactivateAllAnnotations',()=>{for(const _0xf74007 of this['activeUIs']){this['_uis']['get'](_0xf74007)['setActiveAnnotation'](null);}}),this['listenTo'](_0xb5bb58['_visibleAnnotations'],'add',(_0x245096,_0x1427af)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x1427af);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x37e416){return this['activeUIs']['has'](_0x37e416);}['activate'](_0x422566,_0x529550=this['defaultFilter']){const _0x42aed7=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x422566))throw new _0x405026('annotationsuis-missing-ui',this,{'uiName':_0x422566});this['isActive'](_0x422566)&&this['deactivate'](_0x422566),this['activeUIs']['add'](_0x422566);const _0x3fd1cd=new S();v({'source':_0x42aed7['_visibleAnnotations'],'target':_0x3fd1cd,'filter':_0x529550}),this['uisData']['set'](_0x422566,{'collection':_0x3fd1cd,'filter':_0x529550});const _0x532edd=this['_uis']['get'](_0x422566);_0x532edd['attach'](_0x3fd1cd),this['listenTo'](_0x532edd,'change:activeAnnotation',(_0x4623ba,_0x161c65,_0x47cdbc,_0x2b0b6a)=>{_0x2b0b6a&&_0x42aed7['_removeActiveAnnotation'](_0x2b0b6a),_0x47cdbc&&_0x42aed7['_addActiveAnnotation'](_0x47cdbc);});}['deactivate'](_0xa536b8){if(this['activeUIs']['delete'](_0xa536b8),!this['_uis']['has'](_0xa536b8))throw new _0x405026('annotationsuis-missing-ui',this,{'uiName':_0xa536b8});const _0x2cbf00=this['_uis']['get'](_0xa536b8);_0x2cbf00['detach'](),this['stopListening'](_0x2cbf00),this['uisData']['get'](_0xa536b8)['collection']['destroy'](),this['uisData']['delete'](_0xa536b8);}['switchTo'](_0x148218){if(!this['_uis']['has'](_0x148218))throw new _0x405026('annotationsuis-missing-ui',this,{'uiName':_0x148218});const _0x3a0770=this['context']['plugins']['get'](y),_0x2b76a7=Array['from'](_0x3a0770['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x148218);const _0x110f40=this['_uis']['get'](_0x148218);_0x110f40['setActiveAnnotation'](_0x2b76a7),_0x110f40['_setSelectedAnnotations']&&_0x2b76a7&&_0x110f40['_setSelectedAnnotations']([_0x2b76a7]);}['deactivateAll'](){for(const _0x982d11 of this['activeUIs'])this['deactivate'](_0x982d11);}['register'](_0x1e3b4b,_0x5c015d){if(this['_uis']['has'](_0x1e3b4b))throw new _0x405026('annotationsuis-register-already-registered');if('function'!=typeof _0x5c015d['attach']||'function'!=typeof _0x5c015d['detach']||'function'!=typeof _0x5c015d['setActiveAnnotation'])throw new _0x405026('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x1e3b4b,_0x5c015d);}['refilterAnnotations'](){const _0x364a2f=this['context']['plugins']['get'](y)['collection'],_0x11c480=new Map(),_0x535886=Array['from'](this['activeUIs']);for(const _0x48c490 of this['activeUIs']){const _0x51fc75=this['uisData']['get'](_0x48c490)['collection'];for(const _0x6905b6 of _0x51fc75)_0x11c480['set'](_0x6905b6,_0x48c490);}for(const _0x5499c5 of _0x364a2f){const _0x215a07=_0x11c480['get'](_0x5499c5);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x5499c5);const _0x3e502b=_0x535886['find'](_0x568407=>this['uisData']['get'](_0x568407)['filter'](_0x5499c5));_0x215a07!==_0x3e502b&&(_0x215a07&&this['uisData']['get'](_0x215a07)['collection']['remove'](_0x5499c5),_0x3e502b&&this['uisData']['get'](_0x3e502b)['collection']['add'](_0x5499c5));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x2ee94c){const _0x25e27c=[];for(const _0x34a33d of this['activeUIs']){(0x0,this['uisData']['get'](_0x34a33d)['filter'])(_0x2ee94c)&&_0x25e27c['push'](_0x34a33d);}if(_0x25e27c['length']>0x1)throw new _0x405026('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x25e27c,'annotationType':_0x2ee94c['type']});}}const _i=/* #__PURE__ -- @preserve */
32
+ Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x247e64){super(_0x247e64);const _0x2da73f=this['bindTemplate'];this['set']('minHeight',0x0),this['set']('class',''),this['list']=this['createCollection'](),this['focusables']=this['createCollection'](),this['list']['delegate']('arrowup','arrowdown')['to'](this),this['focusTracker']=new _0x49912b(),this['focusCycler']=new _0x5eb73d({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x2da73f['to']('class')],'style':{'minHeight':_0x2da73f['to']('minHeight',_0x5c89bb=>'number'==typeof _0x5c89bb?_i(_0x5c89bb+0xa):null)},'dir':_0x247e64['uiLanguageDirection'],'role':'application','aria-label':N(_0x247e64,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x247e64,'Annotations\x20list')},'children':this['list']}]});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['focus'](){this['focusCycler']['focusFirst']();}['_setupKeyboardNavigation'](){this['list']['delegate']('change:top')['to'](this),this['on']('change:top',_0x34ee2f=>{this['_updateItemPositionInFocusables'](_0x34ee2f['source']);}),this['list']['forEach'](_0xee648d=>{this['focusTracker']['add'](_0xee648d['element']),this['_updateItemPositionInFocusables'](_0xee648d);}),this['list']['on']('change',(_0xfbae01,_0x29098d)=>{for(const _0x23785f of _0x29098d['removed'])this['focusTracker']['remove'](_0x23785f['element']),this['focusables']['remove'](_0x23785f);for(const _0x50b278 of _0x29098d['added'])this['focusTracker']['add'](_0x50b278['element']),this['_updateItemPositionInFocusables'](_0x50b278);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x28f08a){const _0x1f55d5=this['focusables']['getIndex'](_0x28f08a);let _0x1238e7,_0x381d64;for(const _0x285665 of this['focusables'])if(_0x28f08a['top']<_0x285665['top']){_0x1238e7=_0x285665;break;}if(_0x381d64=_0x1238e7?this['focusables']['getIndex'](_0x1238e7):this['focusables']['length'],-0x1!==_0x1f55d5){if(_0x1f55d5===_0x381d64-0x1)return;this['focusables']['remove'](_0x28f08a),_0x381d64=_0x1238e7?this['focusables']['getIndex'](_0x1238e7):this['focusables']['length'];}this['focusables']['add'](_0x28f08a,_0x381d64);}}const Ot=/* #__PURE__ -- @preserve */
33
+ Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x286313){super(_0x286313),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x1c6fbf,_0x4276d0)=>_0x1c6fbf+_0x4276d0),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x5a20dd=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x5a20dd['to']('isAnimationDisabled',_0x278f29=>_0x278f29?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x5a20dd['to']('top',_0x38b46c=>Ot(_0x38b46c))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x767ccf=this['element']['clientHeight'];_0x767ccf&&(this['height']=_0x767ccf);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x2a0d5d{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3aa72d){super(_0x3aa72d),this['set']('_lastItem',void 0x0),this['view']=this['_createSidebarView'](),this['set']('container',null),this['_spaceBetweenItems']=0x19,this['_sidebarItemViewToAnnotation']=new Map(),this['_annotationToSidebarItemView']=new Map(),this['context']['config']['define']('sidebar.preventScrollOutOfView',!0x1),this['_annotations']=null,this['_activeAnnotation']=null,this['_recalculateBuffer']=[];}['init'](){const _0x988834=this['context']['config']['get']('sidebar.container');_0x988834&&this['setContainer'](_0x988834);}['setContainer'](_0x3568d0){if(!g(_0x3568d0))throw new _0x405026('sidebar-setcontainer-invalid-element');this['container']=_0x3568d0;}['_attachToContainer']({viewClass:_0x3a5473='',spaceBetweenItems:_0x230a82=0x19}={}){if(!g(this['container']))throw new _0x405026('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x3a5473,this['_spaceBetweenItems']=_0x230a82;}['rearrange']({removedAnnotation:_0x4d1117,previousAnnotation:_0x4aaa7b,nextAnnotation:_0x22f47e}){const _0x301e61=this['getSidebarItemView'](_0x4d1117);this['view']['list']['remove'](_0x301e61),this['_destroySidebarItemView'](_0x4d1117),_0x4aaa7b&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x4aaa7b)),_0x22f47e&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x22f47e)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x334eaf,activatedAnnotation:_0x55870c,disableAnimationOnActivatedAnnotation:_0x583acc}){if(this['_activeAnnotation']=_0x55870c,_0x334eaf){_0x334eaf['isActive']=!0x1;const _0x2827f9=this['getSidebarItemView'](_0x334eaf);_0x2827f9&&_0x583acc&&(_0x2827f9['isAnimationDisabled']=!0x1);}if(_0x55870c){const _0x390692=this['getSidebarItemView'](_0x55870c);_0x390692&&(_0x55870c['isActive']=!0x0,_0x583acc&&(_0x390692['isAnimationDisabled']=!0x0,_0x390692['top']+=0x1),this['_alignToTargetRect'](_0x390692));}}['_detachFromContainer'](_0x519a2f){if(this['view']['element']['remove'](),_0x519a2f){for(const _0xade0d9 of _0x519a2f)this['_destroySidebarItemView'](_0xade0d9);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x11fd46,_0x39a5bd){_0x39a5bd||(_0x39a5bd=_0x11fd46['view']);const _0x4aa965=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x4aa965,_0x11fd46),this['_annotationToSidebarItemView']['set'](_0x11fd46,_0x4aa965),_0x4aa965['content']['add'](_0x39a5bd),this['listenTo'](_0x11fd46['view'],'change:targetRect',(_0x25095e,_0x430dac,_0x332c07)=>{const _0x5ebcfb=this['_getTargetTop'](_0x11fd46,_0x332c07);_0x4aa965['_targetTop']!=_0x5ebcfb&&(_0x4aa965['_targetTop']=_0x5ebcfb,this['_setItemTop'](_0x4aa965,_0x5ebcfb));}),this['listenTo'](_0x4aa965,'change:top',()=>{this['_recalculate'](_0x4aa965,'top');}),this['listenTo'](_0x4aa965,'change:bottom',()=>{this['_recalculate'](_0x4aa965,'bottom');}),this['_alignToTargetRect'](_0x4aa965);const _0x39d689=this['_getItemBefore'](_0x4aa965);if(_0x39d689)this['_alignAfterItem'](_0x39d689,_0x4aa965)||this['_alignToTargetRect'](_0x4aa965);else this['_alignToTargetRect'](_0x4aa965);return this['_updateLastItem'](),this['view']['list']['add'](_0x4aa965),_0x4aa965;}['_alignForTopChange'](_0x378be4){if(!_0x378be4['content']['length'])return;const _0x4508b1=this['_getItemBefore'](_0x378be4);if(!_0x4508b1)return;const _0x397aae=this['_sidebarItemViewToAnnotation']['get'](_0x4508b1),_0xb5073a=this['_activeAnnotation'];_0xb5073a&&_0xb5073a===_0x397aae?this['_alignAfterItem'](_0x4508b1,_0x378be4):this['_alignBeforeItem'](_0x378be4,_0x4508b1);}['_alignForBottomChange'](_0x41a0db){if(!_0x41a0db['content']['length'])return;const _0x547c3d=this['_getItemAfter'](_0x41a0db);if(!_0x547c3d)return;const _0x5878c7=this['_sidebarItemViewToAnnotation']['get'](_0x547c3d),_0x3e3f05=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x51da7c=this['_activeAnnotation'];_0x51da7c&&_0x51da7c===_0x5878c7&&_0x3e3f05?(this['_alignBeforeItem'](_0x547c3d,_0x41a0db),this['_alignAfterItem'](_0x41a0db,_0x547c3d)):_0x51da7c&&_0x51da7c===_0x5878c7?this['_alignBeforeItem'](_0x547c3d,_0x41a0db):this['_alignAfterItem'](_0x41a0db,_0x547c3d);}['_recalculate'](_0xe9007c,_0x5516ad){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x3322e9,changedProp:_0x55811d}of this['_recalculateBuffer'])'top'===_0x55811d?this['_alignForTopChange'](_0x3322e9):this['_alignForBottomChange'](_0x3322e9);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0xe9007c,'changedProp':_0x5516ad});}['getSidebarItemView'](_0x13ca2){return this['_annotationToSidebarItemView']['get'](_0x13ca2);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x4c506a){const _0x5bef77=this['getSidebarItemView'](_0x4c506a);this['stopListening'](_0x5bef77),this['stopListening'](_0x4c506a['view']),_0x5bef77['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x4c506a),this['_sidebarItemViewToAnnotation']['delete'](_0x5bef77);}['_createSidebarView'](){const _0x58dd85=new H(this['context']['locale']);return _0x58dd85['render'](),this['on']('change:_lastItem',(_0x8e7459,_0x267e0d,_0x39a4c3,_0x502522)=>{_0x502522&&_0x58dd85['unbind']('minHeight'),_0x39a4c3?_0x58dd85['bind']('minHeight')['to'](_0x39a4c3,'bottom'):_0x58dd85['minHeight']=null;}),_0x58dd85;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x239784){const _0xa862b3=this['_sidebarItemViewToAnnotation']['get'](_0x239784),_0x251777=_0xa862b3&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0xa862b3)-0x1);return _0x251777&&this['getSidebarItemView'](_0x251777)||null;}['_getItemAfter'](_0x3cc9fe){const _0x3fa2ce=this['_sidebarItemViewToAnnotation']['get'](_0x3cc9fe),_0x3c8429=_0x3fa2ce&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x3fa2ce)+0x1);return _0x3c8429&&this['getSidebarItemView'](_0x3c8429)||null;}['_alignBeforeItem'](_0x52b3a6,_0x2fa080){_0x52b3a6['updateHeight']();const _0x5ef9e3=G(_0x2fa080['bottom']+this['_spaceBetweenItems'],_0x52b3a6['top']);return!!_0x5ef9e3&&(this['_setItemTop'](_0x2fa080,_0x2fa080['top']-_0x5ef9e3),!0x0);}['_alignAfterItem'](_0x407eac,_0x592fe8){_0x407eac['updateHeight']();const _0xe0d836=G(_0x407eac['bottom']+this['_spaceBetweenItems'],_0x592fe8['top']);return!!_0xe0d836&&(this['_setItemTop'](_0x592fe8,_0x592fe8['top']+_0xe0d836,!0x1),!0x0);}['_alignToTargetRect'](_0x1f66b2){const _0x411957=this['_sidebarItemViewToAnnotation']['get'](_0x1f66b2);if(!_0x411957||!_0x411957['target']||!_0x411957['targetRect'])return;const _0x3852f0=this['_getTargetTop'](_0x411957,_0x411957['targetRect']);this['_setItemTop'](_0x1f66b2,_0x3852f0);}['_getTargetTop'](_0x5a8f67,_0x2ad2f4){if(null===_0x2ad2f4)return 0x0;if(_0x5a8f67['target']instanceof _0x3ab659)return _0x2ad2f4['top'];{const _0x7904ed=new _0x3ab659(this['view']['element'])['top'];return _0x2ad2f4['top']-_0x7904ed;}}['_setItemTop'](_0x17a713,_0x55d650,_0x5eee10=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x5eee10&&(_0x55d650=Math['max'](_0x55d650,this['_getMaxAvailableTop'](_0x17a713))),_0x17a713['top']=_0x55d650;}['_getMaxAvailableTop'](_0x219457){let _0x2c2bd1=this['_getItemBefore'](_0x219457),_0x4b547a=0x0;for(;_0x2c2bd1;)_0x2c2bd1['updateHeight'](),_0x4b547a+=this['_spaceBetweenItems']+_0x2c2bd1['height'],_0x2c2bd1=this['_getItemBefore'](_0x2c2bd1);return _0x4b547a;}}function G(_0x456d80,_0x1a7a20){return Math['max'](_0x456d80-_0x1a7a20,0x0);}function g(_0x479b20){return null!==_0x479b20&&'object'==typeof _0x479b20&&0x1===_0x479b20['nodeType'];}class e extends _0x2a0d5d{['isAttached'];['annotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,j];}static get['pluginName'](){return'WideSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2cc788){super(_0x2cc788),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x2a090d(),this['_refreshPositioningDebounced']=_0x2ecd68(()=>{_0x2cc788['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x4fd36d=this['context']['plugins']['get'](j),_0x45b036=this['context']['plugins']['get'](z);_0x4fd36d['register']('wideSidebar',this),_0x45b036['container']&&_0x4fd36d['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x5b19a0){if(_0x5b19a0===this['activeAnnotation'])return;const _0x140944=this['context']['plugins']['get'](z);_0x140944['_activeAnnotation']=_0x5b19a0;const _0x26ec4e=this['activeAnnotation'];_0x140944['refresh']({'blurredAnnotation':_0x26ec4e,'activatedAnnotation':_0x5b19a0}),this['activeAnnotation']=_0x5b19a0;}['attach'](_0x197f36){this['annotations']=_0x197f36;const _0x1d9342=this['context']['plugins']['get'](z);if(_0x1d9342['_annotations']=_0x197f36,this['isAttached'])throw new _0x405026('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x1d9342,'set:container',()=>{this['detach'](),this['listenTo'](_0x1d9342,'change:container',_0x1b8bc2=>{_0x1b8bc2['off'](),this['attach'](_0x197f36);});}),_0x1d9342['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x552702=_0x3e38ff=>{_0x3e38ff['updateTargetRect'](),_0x1d9342['addAnnotation'](_0x3e38ff);};for(const _0x3f4245 of _0x197f36)_0x552702(_0x3f4245);this['listenTo'](_0x197f36,'add',(_0x1a161d,_0x5d024e)=>{_0x552702(_0x5d024e);}),this['listenTo'](_0x197f36,'remove',(_0x31a2d0,_0x4f1583,_0x2e7c28)=>{_0x1d9342['rearrange']({'removedAnnotation':_0x4f1583,'previousAnnotation':_0x197f36['get'](_0x2e7c28-0x1),'nextAnnotation':_0x197f36['get'](_0x2e7c28+0x1)}),_0x4f1583===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x197f36,'focus',(_0x4361ed,_0x3bead4)=>{this['setActiveAnnotation'](_0x3bead4);}),this['listenTo'](_0x197f36,'blur',()=>{this['setActiveAnnotation'](null);});const _0x1e6346=this['context']instanceof _0x18cd9d?this['context']['editors']:new _0x2a090d([this['context']]);for(const _0x1e6851 of _0x1e6346)this['_integrateWithEditorAnnotations'](_0x1e6851);this['listenTo'](_0x1e6346,'add',(_0x6c3d9c,_0x553bf0)=>{this['listenTo'](_0x553bf0,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x553bf0);});}),this['listenTo'](_0x1e6346,'remove',(_0x515af3,_0x2f03f2)=>{_0x2f03f2['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x2f03f2['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x405026('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x337328=this['context']['plugins']['get'](z);_0x337328['_detachFromContainer'](this['annotations']),this['stopListening'](_0x337328),this['stopListening'](this['annotations']),this['context']instanceof _0x18cd9d&&this['stopListening'](this['context']['editors']);for(const _0x570bcc of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x570bcc);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x3cc61f){if(!_0x3cc61f['plugins']['has']('EditorAnnotations'))return;const _0x2ab50c=_0x3cc61f['plugins']['get']('EditorAnnotations'),_0x329cb3=()=>{const _0x1aa68f=_0x2ab50c['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x1aa68f[0x0]||null);};this['listenTo'](_0x2ab50c,'refresh',_0x329cb3),this['listenTo'](_0x2ab50c,'blur',(_0x2cbe6c,{isAnnotationTracked:_0x31706c})=>{this['activeAnnotation']&&_0x31706c(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x2ab50c,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x510bdd=>{_0x2ab50c['hasDomSelection']()&&(_0x329cb3(),_0x510bdd['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x2ab50c);}['_destroyEditorAnnotationsIntegration'](_0xc337e9){this['stopListening'](_0xc337e9),this['_editorAnnotations']['remove'](_0xc337e9);}}class C extends _0x55c6d4{['counterView'];constructor(_0x5498b7){super(_0x5498b7);const _0x362db8=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x1ad9f2,_0x18737d)=>_0x1ad9f2?'...':_0x18737d['toString']()),this['set']('annotationType',''),this['icon']=_0x2676b4,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x362db8['to']('annotationType',_0x4a7e6f=>'ck-annotation-counter__badge--'+_0x4a7e6f),_0x362db8['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x362db8['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x2a0d5d{['isAttached'];['annotations'];['_manuallyClosedAnnotationViews'];['_domEmitter'];['_annotationToNarrowView'];['_selectedAnnotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,j];}static get['pluginName'](){return'NarrowSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x34a253){super(_0x34a253),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x354fdb())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x2a090d(),this['_refreshPositioningDebounced']=_0x2ecd68(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x399258(this['context']['locale']),this['balloonPanelView']=new _0x3a5644(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x462b13){this['annotations']=_0x462b13;const _0x2824cd=this['context']['plugins']['get'](z),_0x4857fb=this['balloonPanelView'];if(_0x2824cd['_annotations']=_0x462b13,this['isAttached'])throw new _0x405026('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x2824cd,'set:container',()=>{this['detach'](),this['listenTo'](_0x2824cd,'change:container',_0x2f65f9=>{_0x2f65f9['off'](),this['attach'](_0x462b13);});}),_0x2824cd['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x3e75ca=_0x1d7e2f=>{const _0x5f2f64=new C(this['context']['locale']);_0x2824cd['addAnnotation'](_0x1d7e2f,_0x5f2f64),this['_annotationToNarrowView']['set'](_0x1d7e2f,_0x5f2f64),_0x5f2f64['bind']('isDirty','annotationType','number')['to'](_0x1d7e2f['view'],'isDirty','type','length'),_0x5f2f64['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x4857fb['content']['first']!==_0x1d7e2f['view']?(this['_showBalloon'](_0x1d7e2f),_0x1d7e2f['view']['element']['focus'](),this['setActiveAnnotation'](_0x1d7e2f)):this['setActiveAnnotation'](null);});};for(const _0x165703 of _0x462b13)_0x3e75ca(_0x165703);this['listenTo'](_0x462b13,'add',(_0x196d1c,_0x142dc8)=>{_0x3e75ca(_0x142dc8);}),this['listenTo'](_0x462b13,'remove',(_0x5b5a8d,_0x286da7,_0x261e81)=>{this['_annotationToNarrowView']['get'](_0x286da7)['destroy'](),this['_annotationToNarrowView']['delete'](_0x286da7),_0x2824cd['rearrange']({'removedAnnotation':_0x286da7,'previousAnnotation':_0x462b13['get'](_0x261e81-0x1),'nextAnnotation':_0x462b13['get'](_0x261e81+0x1)}),_0x286da7===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x462b13,'focus',(_0x4de37c,_0x4a367e)=>{this['setActiveAnnotation'](_0x4a367e);}),this['listenTo'](_0x462b13,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x4d50ea,_0x493fcf)=>{_0x493fcf['keyCode']===_0x7decd5['esc']&&_0x4857fb['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x4857fb['content']['first']),this['_hideBalloon'](),_0x493fcf['stopPropagation'](),_0x493fcf['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x3da58c,_0x48e4a7)=>{const _0x18eaea=_0x48e4a7['target'];_0x4857fb['isVisible']&&_0x4857fb['element']['contains'](_0x18eaea)||_0x2824cd['view']['element']['contains'](_0x18eaea)||_0x3da58c['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x5203d8=>_0x5203d8['contains'](_0x18eaea))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x1cd784=this['context']instanceof _0x18cd9d?this['context']['editors']:new _0x2a090d([this['context']]);for(const _0x243c97 of _0x1cd784)this['_integrateWithEditorAnnotations'](_0x243c97);this['listenTo'](_0x1cd784,'add',(_0xfc46d2,_0x29a425)=>{this['listenTo'](_0x29a425,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x29a425);});}),this['listenTo'](_0x1cd784,'remove',(_0x35efde,_0x2a441e)=>{_0x2a441e['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x2a441e['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x441c61){if(_0x441c61===this['activeAnnotation'])return;const _0xacaefa=this['context']['plugins']['get'](z);if(_0xacaefa['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x441c61,'disableAnimationOnActivatedAnnotation':!0x0}),_0x441c61)_0xacaefa['getSidebarItemView'](_0x441c61)?this['_showBalloon'](_0x441c61):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x441c61;}['detach'](){if(!this['isAttached'])throw new _0x405026('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x4c5312=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x1ba53e=>_0x1ba53e['destroy']()),this['_annotationToNarrowView']['clear'](),_0x4c5312['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x18cd9d&&this['stopListening'](this['context']['editors']);for(const _0x32581d of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x32581d);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['_selectedAnnotations']=[],this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['bodyCollection']['detachFromDom']();}['_integrateWithEditorAnnotations'](_0x54c5a3){if(!_0x54c5a3['plugins']['has']('EditorAnnotations'))return;const _0x238d9a=_0x54c5a3['plugins']['get']('EditorAnnotations'),_0x2d59ca=this['context']['plugins']['get'](z),_0x5557c7=this['annotations'],_0x5f2cd3=this['balloonPanelView'],_0x57354c=()=>{const _0x5353ec=_0x238d9a['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x5353ec),this['setActiveAnnotation'](_0x5353ec[0x0]||null);};this['listenTo'](_0x238d9a,'refresh',_0x57354c),this['listenTo'](_0x238d9a,'blur',(_0x47c4d3,{isAnnotationTracked:_0x4dd711})=>{this['activeAnnotation']&&_0x4dd711(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x238d9a,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x5557c7,'blur',_0x4515ab=>{_0x238d9a['hasDomSelection']()&&_0x4515ab['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x5000fb,_0x21cd86)=>{const _0x96affc=_0x21cd86['target'];_0x5f2cd3['isVisible']&&_0x5f2cd3['element']['contains'](_0x96affc)||_0x2d59ca['view']['element']['contains'](_0x96affc)||this['activeAnnotation']&&_0x238d9a['hasDomSelection']()&&(_0x57354c(),_0x5000fb['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x238d9a);}['_destroyEditorAnnotationsIntegration'](_0x23963a){_0x23963a&&(this['stopListening'](_0x23963a),this['_editorAnnotations']['remove'](_0x23963a));}['_setSelectedAnnotations'](_0x27e45c){for(const _0x47cf39 of this['_selectedAnnotations'])_0x27e45c['includes'](_0x47cf39)||this['_manuallyClosedAnnotationViews']['delete'](_0x47cf39['view']);this['_selectedAnnotations']=_0x27e45c;}['_refreshPositioning'](){const _0x30431b=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x30431b['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x5cacc2){if(this['_manuallyClosedAnnotationViews']['has'](_0x5cacc2['view']))return;const _0x556136=this['balloonPanelView']['content']['first'];_0x556136!==_0x5cacc2['view']?(_0x556136&&this['_detachListeners'](_0x556136),this['_attachListeners'](_0x5cacc2['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x5cacc2['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x59097a=this['balloonPanelView']['content']['first'],_0x3078f1=_0x59097a&&this['annotations']['getByView'](_0x59097a);if(!_0x3078f1||!this['_annotationToNarrowView']['has'](_0x3078f1))return;const _0x408269=this['_annotationToNarrowView']['get'](_0x3078f1)['element'],_0x21b825=(function(){const _0x40c98f=_0x3a5644['defaultPositions'];return[_0x40c98f['southArrowNorthEast'],_0x40c98f['northArrowSouthEast'],_0x40c98f['southArrowNorth'],_0x40c98f['northArrowSouth'],_0x40c98f['southArrowNorthWest'],_0x40c98f['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x408269,'positions':_0x21b825});}['_hideBalloon'](){const _0x1398ed=this['balloonPanelView'],_0x3b00bf=_0x1398ed['content']['first'];_0x3b00bf&&(this['_detachListeners'](_0x3b00bf),_0x1398ed['unpin'](),_0x1398ed['content']['clear']());}['_attachListeners'](_0x5bf9bc){this['listenTo'](_0x5bf9bc,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x5bf9bc,'Esc',(_0x261c76,_0x42f8db)=>{this['_manuallyClosedAnnotationViews']['add'](_0x5bf9bc),this['_hideBalloon'](),_0x42f8db();});}['_detachListeners'](_0x2111e7){this['stopListening'](_0x2111e7);}}class c extends _0xbebcb7{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];['_refreshVisibilityDebounced'];static get['requires'](){return[b,_0x5d8a44,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x444809){super(_0x444809),_0x444809['editing']['view']['addObserver'](_0x5ee80d),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x444809['plugins']['get'](_0x5d8a44),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1,this['_refreshVisibilityDebounced']=_0x2ecd68(()=>{this['editor']['plugins']['get']('Annotations')['refreshVisibility']();},0xfa,{'leading':!0x1});}['init'](){const _0x1fff7e=this['editor']['plugins']['get'](j);_0x1fff7e['context']===this['editor']&&(_0x1fff7e['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x4ee583,_0x43e281)=>{const _0x63ed00=this['_balloon'];if(this['isAttached']&&_0x63ed00['visibleView']){const _0x36b339=this['annotations']['getByView'](_0x63ed00['visibleView']);_0x36b339&&this['_closeAnnotation'](_0x36b339),_0x43e281();}}));}['afterInit'](){const _0x5c16b3=this['editor']['plugins']['get'](j);_0x5c16b3['context']===this['editor']&&(_0x5c16b3['hasActive']()||_0x5c16b3['switchTo']('inline'));}['setActiveAnnotation'](_0x1d3073){_0x1d3073!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x1d3073&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x1d3073)&&this['_addAnnotationToBalloon'](_0x1d3073,!0x0),_0x1d3073['isActive']=!0x0),_0x1d3073||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x1d3073);}['attach'](_0x243573){this['annotations']=_0x243573;const _0x5fabe6=this['editor']['plugins']['get'](j),_0x1e2c80=this['_balloon'];if(this['isAttached'])throw new _0x405026('inlineannotations-attach-already-attached',this);if(_0x5fabe6['context']!==this['editor'])throw new _0x405026('inlineannotations-not-allowed-with-context',this);const _0x5039f1=this['editor']['plugins']['get'](b);this['listenTo'](_0x5039f1,'refresh',()=>{const _0x84af52=_0x5039f1['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x5b71da,_0x5ca53d;!this['_forceRefresh']&&(_0x5b71da=_0x84af52,_0x5ca53d=this['_selectedAnnotations'],_0x5b71da['length']===_0x5ca53d['length']&&_0x5b71da['every'](_0x5e908c=>_0x5ca53d['includes'](_0x5e908c)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x84af52),this['setActiveAnnotation'](_0x84af52[0x0]||null));}),this['listenTo'](_0x5039f1,'blur',(_0x493922,{isAnnotationTracked:_0x418967})=>{this['activeAnnotation']&&_0x418967(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x5039f1,'uiUpdate',()=>{this['_refreshVisibilityDebounced']();}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x1b1d2b,_0x2b2fc3,_0x3576e8)=>{_0x3576e8||this['setActiveAnnotation'](null);}),this['listenTo'](_0x243573,'remove',(_0x323790,_0x5605a3)=>{this['_removeAnnotationFromBalloon'](_0x5605a3),_0x5605a3===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x1e2c80,'change:visibleView',(_0x4a798b,_0x3a0b76,_0x173881,_0x194b74)=>{_0x194b74&&this['stopListening'](_0x194b74);const _0x330c6e=_0x243573['getByView'](_0x173881);_0x173881&&_0x330c6e&&(this['listenTo'](_0x173881,'change:height',()=>{_0x1e2c80['updatePosition']();}),this['listenTo'](_0x173881,'Esc',()=>{this['_closeAnnotation'](_0x330c6e),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x330c6e&&this['setActiveAnnotation'](_0x330c6e));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x1e2c80['visibleView']&&(_0x243573['getByView'](_0x1e2c80['visibleView'])&&_0x1e2c80['updatePosition']());}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',()=>{this['_forceRefresh']=!0x0,this['_manuallyClosed']['clear']();}),this['editor']['editing']['view']['document']['selection']['editableElement']&&this['editor']['editing']['view']['focus'](),this['isAttached']=!0x0;}['detach'](){if(!this['isAttached'])throw new _0x405026('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x1a17e0 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x1a17e0);this['_refreshVisibilityDebounced']['cancel'](),this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['_refreshVisibilityDebounced']['cancel']();}['_setSelectedAnnotations'](_0x51c824){for(const _0x375758 of this['_selectedAnnotations'])_0x51c824['includes'](_0x375758)||this['_manuallyClosed']['delete'](_0x375758);for(const _0x1a2403 of this['annotations'])_0x51c824['includes'](_0x1a2403)||this['_removeAnnotationFromBalloon'](_0x1a2403);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x3394fb of _0x51c824)this['_addAnnotationToBalloon'](_0x3394fb);}this['_selectedAnnotations']=_0x51c824;}['_addAnnotationToBalloon'](_0x5f26d0,_0x3c2c43=!0x1){this['_manuallyClosed']['has'](_0x5f26d0)||(this['_addedAnnotations']['has'](_0x5f26d0)||this['_balloon']['hasView'](_0x5f26d0['view'])||(this['_addedAnnotations']['add'](_0x5f26d0),this['_balloon']['add']({'stackId':_0x5f26d0['view']['id'],'view':_0x5f26d0['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x5f26d0)}})),_0x3c2c43&&this['_balloon']['showStack'](_0x5f26d0['view']['id']));}['_getBalloonTargetForAnnotation'](_0x385a77){const _0x2f62a0=_0x385a77['target'],_0x52508b=this['editor']['editing']['view'],_0x5302c9=_0x52508b['document']['selection']['getFirstRange'](),_0x5def9a=_0x52508b['domConverter']['viewRangeToDom'](_0x5302c9);if(_0x5def9a['collapse'](!0x0),_0x2f62a0){if(_0x2f62a0 instanceof _0x3ab659)return _0x2f62a0;let _0x285ca3=[];for(const _0x3514b7 of _0x2f62a0)_0x285ca3['push'](...F(_0x3514b7['getClientRects']()));_0x285ca3=function(_0x1cc9e7){const _0x5e2b98=[];let _0x375016=_0x1cc9e7[0x0];for(let _0x47e006=0x1;_0x47e006<_0x1cc9e7['length'];_0x47e006++)P(_0x375016,_0x1cc9e7[_0x47e006])?_0x375016['width']+=_0x1cc9e7[_0x47e006]['width']:(_0x5e2b98['push'](_0x375016),_0x375016=_0x1cc9e7[_0x47e006]);return _0x5e2b98['push'](_0x375016),_0x5e2b98;}(_0x285ca3);const _0x978666=_0x5def9a['getBoundingClientRect']();return _0x285ca3['find'](_0x41c7c7=>_0x41c7c7['top']<=_0x978666['top']&&_0x41c7c7['bottom']>=_0x978666['bottom']&&_0x41c7c7['left']<=_0x978666['left']&&_0x41c7c7['right']>=_0x978666['right'])||_0x285ca3[0x0];}return _0x385a77['targetRect']||_0x5def9a;}['_removeAnnotationFromBalloon'](_0x3046cd){this['_addedAnnotations']['has'](_0x3046cd)&&this['_balloon']['hasView'](_0x3046cd['view'])&&(this['_addedAnnotations']['delete'](_0x3046cd),this['_balloon']['remove'](_0x3046cd['view']));}['_closeAnnotation'](_0xbcb49c){this['_manuallyClosed']['add'](_0xbcb49c),this['_removeAnnotationFromBalloon'](_0xbcb49c);}}function F(_0x207dbe){return Array['from'](_0x207dbe)['map'](DOMRect['fromRect']);}function P(_0x39b62b,_0x197a0d){return _0x39b62b['top']===_0x197a0d['top']&&_0x39b62b['bottom']===_0x197a0d['bottom']&&_0x39b62b['right']===_0x197a0d['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x2f0cdb,_0x1f92db){super(_0x2f0cdb),this['set']('isEmpty',!_0x1f92db['length']),this['focusTracker']=new _0x49912b(),this['_annotationViews']=_0x1f92db,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x5eb73d({'focusables':_0x1f92db,'focusTracker':this['focusTracker']}),this['listenTo'](_0x1f92db,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x1f92db,'remove',(_0xac19fd,_0x3311ca)=>{_0x3311ca['isActive']&&this['focus'](),_0x1f92db['length']||(this['isEmpty']=!0x0);});const _0x877cfe=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x2f0cdb,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x1f92db},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x877cfe['if']('isEmpty','ck-hidden',_0x53c20a=>!_0x53c20a)]},'children':[{'text':N(_0x2f0cdb,'EMPTY_COMMENTS_ARCHIVE')}]}]}]});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['destroy'](){super['destroy'](),this['focusTracker']['destroy']();}['focus'](){this['focusCycler']['first']?this['focusCycler']['focusFirst']():this['element']['focus']();}['_setupKeyboardNavigation'](){for(const _0x501270 of this['_annotationViews'])this['focusTracker']['add'](_0x501270['element']);this['_annotationViews']['on']('change',(_0x58f738,{added:_0x20bf36,removed:_0x370b1e})=>{for(const _0x115e26 of _0x20bf36)this['focusTracker']['add'](_0x115e26['element']);for(const _0x35f6a6 of _0x370b1e)this['focusTracker']['remove'](_0x35f6a6['element']);});}}class p extends _0x2a0d5d{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x1dc63f){super(_0x1dc63f),this['archivedThreads']=new _0x2a090d();}['init'](){const _0xe34415=this['context'],_0x322b68=_0xe34415['plugins']['get'](o),_0x2a072b=_0xe34415['plugins']['get'](y);this['listenTo'](_0x322b68,'addCommentThread',(_0xdf9eae,{threadId:_0xf73859})=>{const _0x35d6c4=_0x322b68['getCommentThread'](_0xf73859);_0x35d6c4['archivedAt']&&this['archivedThreads']['add'](_0x35d6c4,this['_calculatePosition'](_0x35d6c4['archivedAt'])),this['listenTo'](_0x35d6c4,'change:archivedAt',(_0x16f415,_0x16ca2e,_0x22a1a5)=>{_0x22a1a5?this['archivedThreads']['has'](_0x35d6c4)||this['archivedThreads']['add'](_0x35d6c4,this['_calculatePosition'](_0x35d6c4['archivedAt'])):this['archivedThreads']['has'](_0x35d6c4)&&this['archivedThreads']['remove'](_0x35d6c4);});}),this['listenTo'](_0x322b68,'removeCommentThread',(_0x319968,{threadId:_0x12470c})=>{const _0x50b039=_0x322b68['getCommentThread'](_0x12470c);this['stopListening'](_0x50b039),this['archivedThreads']['has'](_0x50b039)&&this['archivedThreads']['remove'](_0x50b039);},{'priority':'highest'}),this['listenTo'](_0x2a072b['collection'],'focus',(_0x3645d7,_0x69137d)=>{_0x69137d['isVisible']||(_0x69137d['isActive']=!0x0,_0x2a072b['activate'](_0x69137d));});}['_calculatePosition'](_0x53de3c){const _0x29817f=[...this['archivedThreads']]['findIndex'](_0x3ab3a9=>_0x3ab3a9['archivedAt']<_0x53de3c);return _0x29817f>-0x1?_0x29817f:this['archivedThreads']['length'];}}class a extends _0xbebcb7{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x573447];}constructor(_0x8f8af){super(_0x8f8af),this['annotationViews']=new _0x3253be(),this['_pendingThreads']=[];}['init'](){const _0x5654ad=this['editor'],_0x5d4650=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x5654ad['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x55c6d4,!0x0)),_0x5654ad['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x5863d2=this['_createCommentsArchiveButton'](_0x28e15f);return _0x5863d2['set']({'role':'menuitemcheckbox'}),_0x5863d2;});const _0x554787=_0x5654ad['plugins']['get'](p),_0x15510d=_0x5654ad['plugins']['get']('Annotations'),_0x2352e1=_0x5654ad['plugins']['get']('CommentsRepository');_0x554787['archivedThreads']['forEach'](_0x3cddab=>{this['_handleNewThread'](_0x3cddab);}),this['listenTo'](_0x554787['archivedThreads'],'add',(_0x4f6824,_0x5a3aeb)=>{this['_handleNewThread'](_0x5a3aeb);}),this['listenTo'](_0x15510d['collection'],'add',(_0x352f7b,_0x2e5236)=>{const _0x1b86aa=this['_pendingThreads']['find'](_0x1be48b=>{const _0x3872fc=_0x2352e1['_threadToController']['get'](_0x1be48b);return _0x3872fc&&_0x2e5236['innerView']===_0x3872fc['view'];});if(_0x1b86aa){const _0x2e134f=this['_calculatePosition'](_0x1b86aa['archivedAt']);this['_addAnnotationToArchive'](_0x2e5236,_0x2e134f),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x1b86aa),0x1);}}),this['listenTo'](_0x554787['archivedThreads'],'remove',(_0x10c6e5,_0x9126eb)=>{const _0x18fe70=_0x5654ad['config']['get']('collaboration.channelId');if(!_0x18fe70||_0x9126eb['channelId']===_0x18fe70){if(this['_pendingThreads']['includes'](_0x9126eb))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x9126eb),0x1);else{const _0x30c7d5=_0x2352e1['_threadToController']['get'](_0x9126eb),_0x3c5826=_0x15510d['getByInnerView'](_0x30c7d5['view']);this['annotationViews']['remove'](_0x3c5826['view']),this['stopListening'](_0x3c5826),this['stopListening'](_0x3c5826['focusableElements']);}}}),this['listenTo'](_0x15510d['collection'],'add',(_0x542497,_0x3970cc)=>{this['listenTo'](_0x3970cc,'escape',_0x5d4650);}),this['listenTo'](_0x15510d['collection'],'remove',(_0x43d27a,_0x1a76b3)=>{this['stopListening'](_0x1a76b3,'escape',_0x5d4650);});}['_addAnnotationToArchive'](_0x526cf8,_0x529a38){this['listenTo'](_0x526cf8,'set:isVisible',_0x303deb=>{_0x303deb['return']=!0x1,_0x303deb['stop']();}),this['annotationViews']['add'](_0x526cf8['view'],_0x529a38);}['_handleNewThread'](_0x195a2b){const _0x33b476=this['editor']['plugins']['get']('CommentsRepository'),_0x4c6427=this['editor']['plugins']['get']('Annotations'),_0x577c5=this['editor']['config']['get']('collaboration.channelId');if(!_0x577c5||_0x195a2b['channelId']===_0x577c5){const _0x310d7c=_0x33b476['_threadToController']['get'](_0x195a2b);if(!_0x310d7c)return void this['_pendingThreads']['push'](_0x195a2b);const _0x364ad8=this['_calculatePosition'](_0x195a2b['archivedAt']),_0x17c032=_0x4c6427['getByInnerView'](_0x310d7c['view']);_0x17c032['isVisible']&&_0x4c6427['_visibleAnnotations']['remove'](_0x17c032),this['_addAnnotationToArchive'](_0x17c032,_0x364ad8);}}['_calculatePosition'](_0x4d348b){const _0x4da943=this['editor']['config']['get']('collaboration.channelId'),_0x243ca0=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0x290cf7=>_0x290cf7['channelId']===_0x4da943)['findIndex'](_0x2a7e4b=>_0x2a7e4b['archivedAt']<_0x4d348b);return _0x243ca0<0x0||_0x243ca0>this['annotationViews']['length']?this['annotationViews']['length']:_0x243ca0-0x1;}['_toggleDialog'](){const _0x350a60=this['editor'],_0x3ec411=_0x350a60['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x350a60['locale'],this['annotationViews'])),'commentsArchive'===_0x3ec411['id']?_0x3ec411['hide']():_0x3ec411['show']({'id':'commentsArchive','title':N(_0x350a60['locale'],'COMMENTS_ARCHIVE'),'icon':_0x3fba8a,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x1a4f5c['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x4795f3,_0x14c50b=!0x1){const _0x329068=this['editor']['locale'],_0x2c7238=this['editor']['plugins']['get']('Dialog'),_0x2a1192=new _0x4795f3(_0x329068);return _0x2a1192['bind']('isEnabled')['to'](this,'isEnabled'),_0x2a1192['bind']('isOn')['to'](_0x2c7238,'id',_0x198927=>'commentsArchive'===_0x198927),_0x2a1192['set']({'label':N(_0x329068,'COMMENTS_ARCHIVE'),'icon':_0x3fba8a,'isToggleable':!0x0}),_0x14c50b&&(_0x2a1192['tooltip']=!0x0),this['listenTo'](_0x2a1192,'execute',()=>this['_toggleDialog']()),_0x2a1192;}['_hideDialogOnAnnotationEscape']=_0x65242b=>{const _0x4788b9=_0x65242b['source'];if(!this['annotationViews']['has'](_0x4788b9['view']))return;const _0x30c88e=this['editor']['plugins']['get']('Dialog');_0x30c88e['isOpen']&&'commentsArchive'===_0x30c88e['id']&&(_0x30c88e['hide'](),_0x65242b['stop']());};}class gi extends _0xbebcb7{static get['requires'](){return[o,r,s,p,a,i,e,n,c];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{ot as AddCommentThreadCommand,T as Annotation,S as AnnotationCollection,C as AnnotationCounterButtonView,E as AnnotationView,y as Annotations,R as AnnotationsSidebarItemView,H as AnnotationsSidebarView,j as AnnotationsUIs,si as BaseCommentThreadView,di as BaseCommentView,wi as Comment,pi as CommentThread,vt as CommentThreadController,ie as CommentThreadInputView,gt as CommentThreadView,Tt as CommentView,gi as Comments,p as CommentsArchive,a as CommentsArchiveUI,r as CommentsEditing,te as CommentsListView,i as CommentsOnly,o as CommentsRepository,s as CommentsUI,b as EditorAnnotations,c as InlineAnnotations,n as NarrowSidebar,z as Sidebar,e as WideSidebar,v as bindAnnotationCollections};