@ckeditor/ckeditor5-comments 46.0.1-alpha.1 → 46.0.1-alpha.11

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 +18 -18
  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 _0x5c5264,ContextPlugin as _0x4ce48a,PendingActions as lt,Command as _0xc21960,Plugin as _0x2a31b7,Context as _0x4ff59a}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x3068a3,uid as _0x2c4187,KeystrokeHandler as jt,FocusTracker as _0x27e202,diff as _0x5bbd98,Collection as _0x3b6a04,Rect as _0x4a16d0,CKEditorError as _0x49f2d8,first as _0x118483,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x431721,keyCodes as _0x4cec55}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x134246,AriaDescriptionView as Zt,setupThreadKeyboardNavigation as ts,ConfirmMixin as ti,LateFocusButtonView as _0x291e94,trimHtml as _0x2ccf20,LateFocusDropdownButtonView as _0x8016,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x2bb940}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x33ca38}from'es-toolkit/compat';import{IconUndo as _0x2e8de7,IconCheck as _0x2f7825,IconPencil as _0x51e299,IconRemoveComment as _0x2224e0,IconThreeVerticalDots as _0x17c379,IconAddComment as _0x200eaa,IconCommentsArchive as _0x345262}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as Xt,InlineEditableUIView as $t,EditorUI as Ut,View as kt,FocusCycler as _0x113be5,ButtonView as _0x75d40c,ViewCollection as _0x1378ee,createDropdown as _0x217ca1,ListView as _0x5e72ff,focusChildOnDropdownOpen as _0x477df8,ListItemView as _0x1a34a5,MenuBarMenuListItemButtonView as _0x900133,BodyCollection as _0xeb5ffa,BalloonPanelView as _0x55cc35,ContextualBalloon as _0x3c0d23,Dialog as _0x40be78,DialogViewPosition as _0x303166}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as qt,enableViewPlaceholder as St,MouseObserver as _0x2a5d01}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as zt,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as Bt,ShiftEnter as Et}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 _0x5ad51f}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x19d947}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
- _0x3068a3(){['model'];['view'];constructor(_0x58e8dd,_0x2bbf1d){super(),this['model']=_0x58e8dd,this['model']['_isAttached']=!0x0,this['view']=_0x2bbf1d,this['listenTo'](_0x2bbf1d,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x2bbf1d,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x2bbf1d,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x2bbf1d,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x2bbf1d,'addComment',(_0x65b2ef,_0x250283)=>this['addComment'](_0x250283)),this['listenTo'](_0x2bbf1d,'updateComment',(_0x1523c4,_0x53c46b,_0x11e9c8)=>this['updateComment'](_0x53c46b,_0x11e9c8)),this['listenTo'](_0x2bbf1d,'removeComment',(_0x309011,_0x299de4)=>this['removeComment'](_0x299de4));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x2aa532){this['model']['addComment']({'content':_0x2aa532,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x326642,_0x202ea6){this['model']['getComment'](_0x326642)['update']({'content':_0x202ea6});}['removeComment'](_0x13a1f0){this['model']['getComment'](_0x13a1f0)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x53f82a,_0x55c5f1,_0x40afd1){const t=_0x53f82a['t'];switch(_0x55c5f1){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'},_0x40afd1);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'},_0x40afd1);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'},_0x40afd1);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'},_0x40afd1);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x40afd1);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'},_0x40afd1);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'},_0x40afd1);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'},_0x40afd1);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 Vt extends Xt{['main'];['editable'];constructor(_0x25150c,_0x5d6790){super(_0x25150c);const _0x1b9cab=_0x2c4187();this['main']=this['createCollection'](),this['editable']=new $t(_0x25150c,_0x5d6790,void 0x0,{'label':()=>N(_0x25150c,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x25150c['uiLanguageDirection'],'lang':_0x25150c['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x1b9cab},'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 Ft extends Ut{['view'];constructor(_0x55b386){super(_0x55b386),this['view']=new Vt(_0x55b386['locale'],_0x55b386['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x30ba4b=this['editor']['editing']['view'],_0x356ba6=this['view']['editable'],_0x5c69ab=_0x30ba4b['document']['getRoot']();_0x356ba6['name']=_0x5c69ab['rootName'],this['view']['render']();const _0x52d67c=_0x356ba6['element'];this['setEditableElement'](_0x356ba6['name'],_0x52d67c),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x30ba4b['attachDomRoot'](_0x52d67c),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[zt,Bt,Et,Gt,Jt,Kt,Lt];class Rt extends/* #__PURE__ -- @preserve */
25
- _0x3068a3(_0x5c5264){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
- ((()=>Qt)());constructor(_0xed4415={}){function _0x1ff00a(_0x23ba90){return _0x23ba90['map'](_0x135896=>String['fromCharCode'](_0x135896))['join']('');}(_0xed4415=Object['assign']({},_0xed4415))['plugins']||(_0xed4415['plugins']=Rt['defaultPlugins']),super(_0xed4415),this['ui']=new Ft(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x1ff00a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1ff00a([0x76,0x69,0x65,0x77])][_0x1ff00a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1ff00a([0x61,0x75,0x74,0x6f]),this[_0x1ff00a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1ff00a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1ff00a([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1ff00a([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1ff00a([0x6f,0x6b])});}['create'](){const _0x1fd2b1=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x1fd2b1))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x1c2f60=>{const _0x7e1314=this['model']['document']['getRoot'](),_0x458990=_0x7e1314&&_0x7e1314['getChild'](_0x7e1314['childCount']-0x1);_0x1c2f60['setSelection'](_0x458990,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x4334f5=this['editing']['view'],_0x1bfcd4=_0x4334f5['document']['getRoot'](),_0x309580=_0x1bfcd4['getChild'](0x0);_0x1bfcd4['childCount']>0x1||!_0x309580||'p'!=_0x309580['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(qt(_0x4334f5,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x309580['placeholder']=this['placeholder']),St({'view':_0x4334f5,'element':_0x309580,'keepOnFocus':!0x0}),this['placeholderElement']=_0x309580);}}class os extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0xd744ca,_0x3ddeb2={}){super(_0xd744ca),this['editor']=null,this['_editorConfig']=_0x3ddeb2,this['set']('value',_0x3ddeb2['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0xd744ca,'Reply...')),this['set']('submitLabel',N(_0xd744ca,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x27e202(),this['focusCycler']=new _0x113be5({'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',(_0x4c90e0,_0x4132ec)=>{this['cancelButtonView']['fire']('execute'),_0x4132ec();}),this['keystrokes']['set']('Ctrl+Enter',(_0x1fc394,_0x22afa8)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x22afa8());}),this['on']('submit',(_0x2d7e75,_0x6497c5)=>{_0x6497c5['length']>0xfde8?(alert(N(_0xd744ca,'TOO_LONG_COMMENT_ALERT',[_0x6497c5['length'],0xfde8])),_0x2d7e75['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Rt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x5bb63f=this['editor'];this['element']['insertBefore'](_0x5bb63f['ui']['element'],this['element']['firstChild']),_0x5bb63f['model']['document']['on']('change',()=>this['value']=_0x5bb63f['getData']()),_0x5bb63f['bind']('placeholder')['to'](this),this['focusables']['add'](_0x5bb63f['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x2718e3){-0x1===_0x2718e3?(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:_0x14bdb5}=this,_0x259256=new _0x75d40c(_0x14bdb5);return _0x259256['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x259256['withText']=!0x0,_0x259256['bind']('label')['to'](this,'submitLabel'),_0x259256['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x259256['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x232788,_0x42e640)=>!_0x42e640&&!!_0x232788['trim']()),_0x259256;}['_createCancelButton'](){const {locale:_0xc73c60}=this,_0x413aeb=new _0x75d40c(_0xc73c60);return _0x413aeb['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x413aeb['label']=N(_0xc73c60,'Cancel'),_0x413aeb['withText']=!0x0,_0x413aeb['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x413aeb;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x524680=>{this['focusTracker']['add'](_0x524680['element']);}),this['focusables']['on']('change',(_0x429bfd,_0x4b8f70)=>{for(const _0x21ec86 of Array['from'](_0x4b8f70['added'])['reverse']())this['focusTracker']['add'](_0x21ec86['element']);});}}class ie extends kt{constructor(_0x2a1237,_0x1c6041,_0x4ca19c){super(_0x2a1237),this['commentInputView']=new os(_0x2a1237,_0x4ca19c),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x14b240,_0x4aa97a)=>_0x14b240||!!_0x4aa97a),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 _0x134246(_0x2a1237,_0x1c6041),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'](_0x381cbd){this['commentInputView']['focus'](_0x381cbd);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0xcfc4e5,_0xbd2807)=>{const {submitButtonView:_0x1c8be5,cancelButtonView:_0x5d6a99,editor:_0x5b1bf7}=this['commentInputView'];[_0x1c8be5['element'],_0x5d6a99['element'],_0x5b1bf7?_0x5b1bf7['editing']['view']['getDomRoot']():null]['filter'](_0x3da5af=>_0x3da5af)['some'](_0x5dfb1a=>_0x5dfb1a['contains'](_0xbd2807['target']))||(this['focus'](),_0xbd2807['preventDefault']());});}}class rs extends kt{constructor(_0xcdcd53){super(_0xcdcd53);const _0x4fc04a=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x4fc04a['to']('count',_0x280c1f=>N(_0xcdcd53,'NUMBER_OF_COMMENTS',_0x280c1f))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x1f4a39,_0x3f5bd2,_0x1b3a53){super(_0x1f4a39);const _0x449e4a=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x3f5bd2['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x3f5bd2,this['_config']=_0x1b3a53,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x27e202(),this['keystrokes']=new jt(),this['focusCycler']=new _0x113be5({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x351bc6=>this['commentViews']['map'](_0x42d3e4=>_0x42d3e4['element'])['includes'](_0x351bc6['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x1f4a39),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0xb679a3=>_0xb679a3-this['_config']['maxCommentsWhenCollapsed']);for(const _0x523dc0 of _0x3f5bd2['comments'])this['_handleNewCommentModel'](_0x523dc0);this['_handleInfoComment'](),this['listenTo'](_0x3f5bd2['comments'],'add',(_0x568ec0,_0x1c1192)=>{const _0x410465=this['_calculatePosition'](_0x1c1192);this['length']++,this['_handleNewCommentModel'](_0x1c1192,_0x410465),this['refreshVisibleViews']();}),this['listenTo'](_0x3f5bd2['comments'],'remove',(_0x589b64,_0x2bd000)=>{this['length']--,this['_handleRemoveCommentModel'](_0x2bd000),this['refreshVisibleViews']();}),this['listenTo'](_0x3f5bd2,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x3f5bd2,'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',_0x449e4a['if']('length','ck-hidden',_0x4d9c48=>!_0x4d9c48)],'aria-label':N(_0x1f4a39,'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'](_0x2f784c){-0x1===_0x2f784c?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0xde1ae8 of this['commentViews'])_0xde1ae8['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x2020eb,_0x5c7aac){const _0x4dbac7=new this['_config']['CommentView'](this['locale'],_0x2020eb,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x4dbac7['viewUid']=_0x2020eb['id'],_0x4dbac7['delegate']('removeComment')['to'](this),_0x4dbac7['delegate']('updateComment')['to'](this),_0x4dbac7['delegate']('resolveCommentThread')['to'](this),_0x4dbac7['delegate']('editorReady')['to'](this),_0x4dbac7['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x4dbac7,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x4dbac7,_0x5c7aac);}['_calculatePosition'](_0x20c417){const _0x33d0e5=this['_model']['_findOptimalIndex'](_0x20c417);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x20c417['authoredAt']?_0x33d0e5-0x1:_0x33d0e5:_0x33d0e5-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0xf8f909={'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'],_0xf8f909,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0xf8f909));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x3d1a0d){const _0x25a29d=this['commentViews']['remove'](_0x3d1a0d['id']);this['stopListening'](_0x25a29d),_0x25a29d['isEditMode']&&this['_updateHasDirtyComment'](),_0x25a29d['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x11781a=>_0x11781a['isEditMode']);}['_rearrangeCollapse'](){const _0x32fb6a=function(_0xa6cffc){const _0x1a528c=new _0x3b6a04();for(const _0x430fc0 of _0xa6cffc)_0x1a528c['add'](_0x430fc0);return _0x1a528c;}(this['commentViews']),_0x19b90e=this['_collapsedCommentsView']['count'];for(let _0x1a26e8=0x1;_0x1a26e8<=_0x19b90e;_0x1a26e8++)_0x32fb6a['remove'](0x1);for(const _0x1eb967 of _0x32fb6a)_0x1eb967['collapse']();_0x19b90e>0x0&&_0x32fb6a['add'](this['_collapsedCommentsView'],0x1),ns(_0x5bbd98(Array['from'](this['visibleViews']),Array['from'](_0x32fb6a)),this['visibleViews'],_0x32fb6a);}['_rearrangeExpand'](){ns(_0x5bbd98(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x1389f9 of this['visibleViews'])_0x1389f9['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x2f5117=>{this['focusTracker']['add'](_0x2f5117['element']),this['keystrokes']['listenTo'](_0x2f5117['element']);}),this['commentViews']['on']('change',(_0x39761d,_0xf58f03)=>{for(const _0x3b70f5 of _0xf58f03['removed'])this['focusTracker']['remove'](_0x3b70f5['element']),this['keystrokes']['stopListening'](_0x3b70f5['element']);for(const _0x5ca00e of Array['from'](_0xf58f03['added'])['reverse']())this['focusTracker']['add'](_0x5ca00e['element']),this['keystrokes']['listenTo'](_0x5ca00e['element']);});}}function ns(_0x367c38,_0x1d3461,_0x3d6661){let _0x57b6eb=0x0;for(const _0x4a3a43 of _0x367c38)switch(_0x4a3a43){case'insert':_0x1d3461['add'](_0x3d6661['get'](_0x57b6eb),_0x57b6eb),_0x57b6eb++;break;case'delete':_0x1d3461['remove'](_0x57b6eb);break;case'equal':_0x57b6eb++;}}class oe extends kt{constructor(_0x1d8304){super(_0x1d8304);const _0xebbf97=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0xebbf97['to']('contextValue',_0x233ff7=>N(_0x1d8304,'THREAD_CONTEXT_LABEL',_0x233ff7)),'tabindex':-0x1},'children':[{'text':_0xebbf97['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Yt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x318cea,_0x713275){super(_0x318cea);const _0x4ce604=this['bindTemplate'];this['_model']=_0x713275,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x27e202(),this['keystrokes']=new jt(),this['focusCycler']=new _0x113be5({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x2437c7=>!!_0x2437c7),this['bind']('contextValue')['to'](this['_model'],'context',_0x175f64=>_0x175f64&&_0x175f64['value']?this['_trimContextValue'](_0x175f64['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',_0x4ce604['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 _0x53f88e=new _0x75d40c(this['locale']);return _0x53f88e['label']=N(this['locale'],'Reopen'),_0x53f88e['tooltip']=N(this['locale'],'Reopen'),_0x53f88e['icon']=_0x2e8de7,_0x53f88e['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x4ebcfd=>!_0x4ebcfd),_0x53f88e['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x5a996c,_0x5342e0)=>_0x5a996c&&_0x5342e0),_0x53f88e['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x53f88e;}['_trimContextValue'](_0x3304eb){if(_0x3304eb['length']<0x96)return _0x3304eb;const _0x2ce473=_0x3304eb['lastIndexOf']('\x20',0x93);return _0x3304eb['substring'](0x0,_0x2ce473>-0x1?_0x2ce473:0x93)+'...';}['_attachContextActions'](){const _0x1af5ae=this['element']['querySelector']('.ck-context'),_0x3d9999=_0x1af5ae['querySelector']('.ck-context__value');this['listenTo'](_0x1af5ae,'mouseenter',()=>{_0x3d9999['offsetWidth']<_0x3d9999['scrollWidth']&&_0x1af5ae['classList']['add']('overlay');}),this['listenTo'](_0x1af5ae,'mouseleave',()=>{_0x1af5ae['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x1da6e7 of this['focusables'])this['focusTracker']['add'](_0x1da6e7['element']),this['keystrokes']['listenTo'](_0x1da6e7['element']);}['_createContextView'](){const _0x46cc55=new oe(this['locale']);return _0x46cc55['bind']('contextValue')['to'](this),_0x46cc55;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x21a98d,_0x46f016,_0x1221a3,_0x5bff81){super(_0x21a98d),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x46f016,this['_localUser']=_0x1221a3,this['_config']=_0x5bff81,this['commentThreadHeaderView']=new Yt(_0x21a98d,_0x46f016),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Zt(_0x21a98d,N(_0x21a98d,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x21a98d,_0x46f016,Object['assign']({'CommentView':this['_config']['CommentView']},_0x5bff81)),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',(_0x19485a,_0x17931e)=>_0x19485a||!!_0x17931e),this['bind']('isUnlinked')['to'](_0x46f016,'unlinkedAt',_0x4482cc=>!!_0x4482cc),this['bind']('ariaLabel')['to'](this,'length',_0x3fdd91=>{const _0x1db2fc=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x3fdd91,_0x1db2fc]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x27e202(),this['keystrokes']=new jt(),this['focusCycler']=new _0x113be5({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x1c52f9=>_0x1c52f9['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),ts(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x2af046=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x58bac6=_0x2af046['commentInputView'];return _0x2af046['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x58bac6,'value',(_0x4969e8,_0x991778,_0x159c8e,_0x3b182b,_0x9a3293)=>!!_0x9a3293||!!_0x3b182b&&_0x159c8e&&!_0x991778||_0x4969e8&&_0x159c8e&&!_0x991778),_0x58bac6['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x138849,_0x4ca834,_0x190a35)=>{let _0x322ff8;return _0x322ff8=_0x190a35&&_0x4ca834?'Reply\x20to\x20reopen\x20discussion...':_0x138849?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x322ff8);}),_0x58bac6['bind']('submitLabel')['to'](this,'length',_0x2a0243=>N(this['locale'],_0x2a0243?'Reply':'Comment')),_0x58bac6['on']('submit',(_0x131d86,_0x3ce30e)=>{this['fire']('addComment',_0x3ce30e),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x58bac6['on']('cancel',()=>{this['focus']();}),_0x58bac6['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x58bac6['on']('cancel',_0x45b78a=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x45b78a['stop']());}),this['on']('change:isActive',(_0x2ff5eb,_0x4c0929,_0x3a1ef7)=>{_0x3a1ef7||this['length']||_0x58bac6['value']||this['fire']('removeCommentThread');}),_0x2af046;}}class gt extends/* #__PURE__ -- @preserve */
27
- ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x445936,_0x14570a,_0x3f1183,_0x367cfa){super(_0x445936,_0x14570a,_0x3f1183,_0x367cfa),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x445936,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x20c5fb,_0xd4a584,_0x53e31e)=>{_0x53e31e||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x4a2d14,_0x38fc91,_0x285c9f)=>{_0x285c9f&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x540854=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x540854['if']('isActive','ck-thread--active'),_0x540854['if']('isUnlinked','ck-thread--unlinked'),_0x540854['if']('isConfirm','ck-thread--remove-confirmation'),_0x540854['to']('actionIndicator',_0xfe933d=>_0xfe933d?'ck-thread--'+_0xfe933d:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x540854['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 _0x428c59 of this['commentsListView']['commentViews'])_0x428c59['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x2ce2fa}=this,_0x10bbbf=this['commentsListView']['commentViews']['get'](0x0);_0x10bbbf===this['_boundFirstCommentView']||_0x10bbbf['isSystemComment']||(this['_boundFirstCommentView']=_0x10bbbf,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x10bbbf,'actionIndicator',_0x3f3713=>'remove'===_0x3f3713?'remove':null),_0x10bbbf['placeholder']=N(_0x2ce2fa,'Write\x20a\x20comment...'),_0x10bbbf['removeButton']['on']('execute',_0xfc703b=>{_0xfc703b['stop'](),this['showConfirm'](N(_0x2ce2fa,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x10bbbf['focus']();}),_0x10bbbf['actionBar']['add'](this['resolveButton'],0x0),_0x10bbbf['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x12e8fa=new _0x291e94(this['locale']);return _0x12e8fa['label']=N(this['locale'],'Resolve'),_0x12e8fa['tooltip']=N(this['locale'],'Resolve'),_0x12e8fa['icon']=_0x2f7825,_0x12e8fa['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x12e8fa['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x80fce5=>!_0x80fce5),_0x12e8fa['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x5ceab0,_0x51117a)=>_0x5ceab0&&!_0x51117a),_0x12e8fa['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x12e8fa;}['_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 es extends kt{constructor(_0x4d4576){super(_0x4d4576),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0xd2458d,_0xc5da59,_0x28608e)=>{this['element']['innerHTML']=_0x28608e;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x1fd159,_0x1a0846,_0x192b3e){super(_0x1fd159),this['_model']=_0x1a0846,this['_config']=_0x192b3e,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x1a0846,'content',_0x1a0846,'authoredAt',(_0x106b9a,_0x517201)=>N(_0x1fd159,'COMMENT_ARIA_LABEL',[_0x1a0846['author']['name'],_0x192b3e['formatDateTime'](_0x517201),new DOMParser()['parseFromString'](_0x106b9a,'text/html')['body']['textContent'],_0x1a0846['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Zt(_0x1fd159,N(_0x1fd159,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x1378ee(),this['focusTracker']=new _0x27e202(),this['keystrokes']=new jt(),this['focusCycler']=new _0x113be5({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5bb6ab=>_0x5bb6ab['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 _0x202644=new es(this['locale']);return _0x202644['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x50bb40,_0x20961e)=>_0x20961e?_0x2ccf20(_0x50bb40,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x50bb40),_0x202644;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x297f18=new os(this['locale'],this['_config']['editorConfig']);return _0x297f18['value']=this['_model']['content'],_0x297f18['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x297f18['submitLabel']=N(this['locale'],'Save'),_0x297f18['on']('submit',(_0x5031e6,_0x42f2a0)=>{this['fire']('updateComment',this['_model']['id'],_0x42f2a0),this['switchToDisplayMode'](),this['focus']();}),_0x297f18['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x297f18['once']('editorReady',()=>{_0x297f18['focus']();}),_0x297f18['createEditor'](),_0x297f18['delegate']('editorReady')['to'](this),_0x297f18['delegate']('editorDestroyed')['to'](this),_0x297f18;}['_setupKeyboardNavigation'](){const _0x30854e=this['element'];this['keystrokes']['listenTo'](_0x30854e);for(const _0x5a1f2d of this['focusables'])this['focusTracker']['add'](_0x5a1f2d['element']),this['keystrokes']['listenTo'](_0x5a1f2d['element']);this['focusables']['on']('change',(_0x34ca72,_0x129672)=>{for(const _0x713564 of _0x129672['removed'])this['focusTracker']['remove'](_0x713564['element']),this['keystrokes']['stopListening'](_0x713564['element']);for(const _0x4677ef of _0x129672['added'])this['focusTracker']['add'](_0x4677ef['element']),this['keystrokes']['listenTo'](_0x4677ef['element']);}),this['keystrokes']['set']('enter',(_0x503300,_0x25f4ae)=>{_0x30854e===_0x503300['target']&&(this['focusCycler']['focusFirst'](),_0x25f4ae());}),this['keystrokes']['set']('esc',(_0x1370d6,_0x3b0a76)=>{_0x30854e!==_0x1370d6['target']&&(this['focus'](),_0x3b0a76());});}}class Tt extends/* #__PURE__ -- @preserve */
28
- ti(di){['actionBar'];['userView'];constructor(_0xda61b3,_0x169333,_0x55a3ca){super(_0xda61b3,_0x169333,_0x55a3ca),this['set']('actionIndicator',null),this['set']('placeholder',N(_0xda61b3,'Reply...')),this['bind']('authoredAt')['to'](_0x169333),this['bind']('resolvedAt')['to'](_0x169333),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 _0x134246(_0xda61b3,_0x169333['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x169333,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x3d4883=this['bindTemplate'],_0x5365ff=[{'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':_0x3d4883['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x3d4883['to']('authoredAt',_0x126545=>this['_config']['formatDateTime'](_0x126545))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x3d4883['if']('isEditMode','ck-comment__actions--hidden'),_0x3d4883['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']&&_0x5365ff['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x3d4883['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x3d4883['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x3d4883['if']('isEditMode','ck-comment--edit'),_0x3d4883['if']('isSystemComment','ck-comment--info'),_0x3d4883['to']('actionIndicator',_0x11d5cf=>_0x11d5cf?'ck-comment--'+_0x11d5cf:'')],'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':_0x5365ff}]}]};}['_createEditButton'](){const _0x2b2713=new _0x75d40c(this['locale']);return _0x2b2713['label']=N(this['locale'],'Edit'),_0x2b2713['icon']=_0x51e299,_0x2b2713['withText']=!0x0,_0x2b2713['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x2b2713['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x2d6212=>!_0x2d6212),_0x2b2713['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x2b2713['on']('execute',()=>this['switchToEditMode']()),_0x2b2713;}['_createRemoveButton'](){const _0x5508c1=new _0x75d40c(this['locale']);return _0x5508c1['label']=N(this['locale'],'Remove'),_0x5508c1['icon']=_0x2224e0,_0x5508c1['withText']=!0x0,_0x5508c1['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x5508c1['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0xbb830b=>!_0xbb830b),_0x5508c1['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x5508c1['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x5508c1;}['_createDropdown'](){const _0x2bd928=_0x217ca1(this['locale'],_0x8016),_0x1ef231=_0x2bd928['panelView']['children'],_0x27c05f=new _0x5e72ff(this['locale']),_0x3a19b4=_0x2bd928['bindTemplate'];_0x477df8(_0x2bd928,()=>this['items']['find'](_0x3ae513=>_0x3ae513['isVisible'])),_0x2bd928['extendTemplate']({'attributes':{'class':[_0x3a19b4['if']('isVisible','ck-hidden',_0x484fd3=>!_0x484fd3)]}});const _0x2a47ec=(_0x26baab,_0x44500a=-0x1)=>{const _0x546e2a=new _0x1a34a5(this['locale']);_0x546e2a['children']['add'](_0x26baab);const _0x494846=_0x44500a>-0x1?_0x44500a:_0x27c05f['items']['length'];_0x27c05f['items']['add'](_0x546e2a,_0x494846);const _0xa4f8eb=Array['from'](this['items']);_0x2bd928['unbind']('isEnabled','isVisible'),_0x2bd928['bind']('isEnabled')['toMany'](_0xa4f8eb,'isEnabled',(..._0x54ae6c)=>_0x54ae6c['some'](_0x475a38=>_0x475a38)),_0x2bd928['bind']('isVisible')['toMany'](_0xa4f8eb,'isVisible',(..._0x3cc3f3)=>_0x3cc3f3['some'](_0x3ba2ef=>_0x3ba2ef));};_0x2bd928['panelPosition']='sw',_0x2bd928['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x17c379});for(const _0x1076fd of this['items'])_0x2a47ec(_0x1076fd);return _0x1ef231['add'](_0x27c05f),_0x2bd928['listenTo'](this['items'],'add',(_0x302e2a,_0x284501,_0x456bd6)=>{_0x2a47ec(_0x284501,_0x456bd6);}),_0x2bd928['listenTo'](this['items'],'remove',(_0x1b502a,_0x178d3b,_0x14ce3e)=>{_0x27c05f['items']['remove'](_0x14ce3e);}),_0x2bd928;}['_attachActions'](_0x436161,_0x2f618a){const _0x35fd30=_0x436161&&_0x436161['element'];_0x35fd30&&(this['listenTo'](_0x35fd30,'mouseenter',()=>this['actionIndicator']=_0x2f618a),this['listenTo'](_0x35fd30,'focus',()=>this['actionIndicator']=_0x2f618a),this['listenTo'](_0x35fd30,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x35fd30,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x5bc6d7=super['_createCommentInputView']();return _0x5bc6d7['bind']('placeholder')['to'](this),_0x5bc6d7;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x17ed12){const _0x132eef=Dt(_0x17ed12,0x1e),_0x39119e=new MutationObserver(_0x195360=>{for(const _0x33b9d8 of _0x195360)('attributes'==_0x33b9d8['type']&&'class'==_0x33b9d8['attributeName']||'childList'==_0x33b9d8['type']||'characterData'==_0x33b9d8['type'])&&_0x132eef();});return{'attach'(_0x4035a1){_0x39119e['observe'](_0x4035a1,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x39119e['disconnect'](),_0x132eef['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x2e6310,_0x121b30){super(_0x2e6310),this['id']=_0x2c4187(),this['focusTracker']=new _0x27e202(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x50b61c,_0x1cc5c4)=>this['fire']('Esc',_0x1cc5c4)),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'](_0x121b30),this['mainView']=_0x121b30;const _0x5b7ab5=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x5b7ab5['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 _0x4566d1=this['element']['clientHeight'];_0x4566d1&&(this['height']=_0x4566d1);}}class T extends/* #__PURE__ -- @preserve */
29
- _0x3068a3(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0xc089f1,target:_0xe17f9,type:_0x2acf3e,isVisible:_0x5ab073=!0x0}){super(),this['view']=_0xc089f1,this['view']['element']||this['view']['render'](),this['_type']=_0x2acf3e,this['_target']=_0xe17f9,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x3b6a04([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x248d1d,_0x10c1a8)=>{this['view']['focusTracker']['add'](_0x10c1a8);}),this['focusableElements']['on']('remove',(_0x21bcd3,_0x41eff1)=>{this['view']['focusTracker']['remove'](_0x41eff1);}),this['set']('isVisible',_0x5ab073);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x576a8c=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x576a8c),_0x576a8c;}get['targetRect'](){const _0x549c27=this['target'];if(null===_0x549c27)return null;if(_0x549c27 instanceof _0x4a16d0)return _0x549c27;const _0x2e3633=_0x549c27['filter'](_0x3ebf0e=>function(_0x198af0){const _0x1e5132=_0x198af0['offsetParent'];if(_0x1e5132)return!0x0;const _0x5046f6=_0x198af0['getClientRects']()['item'](0x0);return!!_0x5046f6;}(_0x3ebf0e));return 0x0===_0x2e3633['length']?null:new _0x4a16d0(_0x2e3633[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x4c8854){this['view']['isActive']=_0x4c8854,this['view']['mainView']['isActive']=_0x4c8854;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x23c3dc){if(!(null===_0x23c3dc||_0x23c3dc instanceof _0x4a16d0||Array['isArray'](_0x23c3dc)&&_0x23c3dc['every'](_0x3d55e6=>fi(_0x3d55e6))))throw new _0x49f2d8('annotation-invalid-target',null,{'target':_0x23c3dc});}['_getNormalizedTarget'](){const _0x3a2b26='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0x3a2b26)?[_0x3a2b26]:_0x3a2b26;}}function fi(_0x213cd5){return null!==_0x213cd5&&'object'==typeof _0x213cd5&&'nodeType'in _0x213cd5&&0x1===_0x213cd5['nodeType'];}class S extends _0x3b6a04{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x1f74bb=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x27e202(),this['_focusTracker']['on']('change:isFocused',(_0x48c25f,_0x5bd956,_0x39f527)=>{_0x39f527||this['fire']('blur');});for(const _0x272c7c of _0x1f74bb)this['add'](_0x272c7c);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x3ec47a){if(this['has'](_0x3ec47a))throw new _0x49f2d8('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x3ec47a['innerView'],_0x3ec47a),this['_viewToAnnotation']['set'](_0x3ec47a['view'],_0x3ec47a);for(const _0x564652 of _0x3ec47a['focusableElements'])this['_focusTracker']['add'](_0x564652);this['listenTo'](_0x3ec47a['focusableElements'],'add',(_0x7d4dd5,_0x40f0a4)=>{this['_focusTracker']['add'](_0x40f0a4);}),this['listenTo'](_0x3ec47a['focusableElements'],'remove',(_0x3e0db2,_0x21bb35)=>{this['_focusTracker']['remove'](_0x21bb35);}),this['listenTo'](_0x3ec47a['view']['focusTracker'],'change:isFocused',(_0x92b3f7,_0x391eec,_0x52d15a)=>{_0x52d15a&&this['fire']('focus',_0x3ec47a);}),_0x3ec47a['updateTargetRect']();const _0x61d265=this['_getOrderInContent'](_0x3ec47a['view']['targetRect']);return super['add'](_0x3ec47a,_0x61d265);}['remove'](_0x97fa89){if(!this['has'](_0x97fa89))throw new _0x49f2d8('annotationcollection-not-existing-item',null);this['stopListening'](_0x97fa89['view']['focusTracker']),this['stopListening'](_0x97fa89['focusableElements']);for(const _0xae7a55 of _0x97fa89['focusableElements'])this['_focusTracker']['remove'](_0xae7a55);return this['_viewToAnnotation']['delete'](_0x97fa89['view']),this['_innerViewToAnnotation']['delete'](_0x97fa89['innerView']),super['remove'](_0x97fa89);}['getByInnerView'](_0x445871){return this['_innerViewToAnnotation']['get'](_0x445871);}['getByView'](_0x1b79fd){return this['_viewToAnnotation']['get'](_0x1b79fd);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x5721e9 of this)_0x5721e9['updateTargetRect']();this['_sort']();}['_sort'](){const _0x2f62d3=Array['from'](this)['sort']((_0x581ba8,_0x33527f)=>w(_0x581ba8['view']['targetRect'],_0x33527f['view']['targetRect']));for(let _0x683c1b=_0x2f62d3['length']-0x1;_0x683c1b>0x0;_0x683c1b--){const _0x2b38f1=_0x2f62d3[_0x683c1b];_0x683c1b!==this['getIndex'](_0x2b38f1)&&(this['remove'](_0x2b38f1),this['add'](_0x2b38f1));}}['_getOrderInContent'](_0x2126a7){let _0x3b900f=0x0;if(!_0x2126a7)return this['length'];for(const _0x496858 of this){const _0x34453b=_0x496858['view']['targetRect'];if(_0x34453b){if(w(_0x2126a7,_0x34453b)<0x0)return _0x3b900f;_0x3b900f++;}}return _0x3b900f;}}function v({source:_0x564b58,target:_0x346790,filter:_0x340250}){for(const _0x551a76 of _0x564b58)_0x340250(_0x551a76)&&_0x346790['add'](_0x551a76);_0x346790['listenTo'](_0x564b58,'add',(_0x3a3d0d,_0x37fe2d)=>{_0x340250(_0x37fe2d)&&_0x346790['add'](_0x37fe2d);}),_0x346790['listenTo'](_0x564b58,'remove',(_0x171df7,_0x9614d4)=>{_0x346790['has'](_0x9614d4)&&_0x346790['remove'](_0x9614d4);});}function w(_0x3cc193,_0x40e9dd){if(null===_0x3cc193&&null===_0x40e9dd)return 0x0;if(null===_0x3cc193)return-0x1;if(null===_0x40e9dd)return 0x1;const _0x1199a0=_0x3cc193['top']-_0x40e9dd['top'];return 0x0==_0x1199a0?_0x3cc193['left']-_0x40e9dd['left']:_0x1199a0;}class y extends _0x4ce48a{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2349ea){if(super(_0x2349ea),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x2349ea instanceof _0x5c5264){const _0x2350fe=_0x2349ea['locale'];_0x2349ea['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x2350fe,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x52e8f0){this['collection']['add'](_0x52e8f0);}['remove'](_0x46f2c3){this['collection']['remove'](_0x46f2c3),_0x46f2c3['destroy']();}['refreshVisibility'](){for(const _0x23e5da of this['collection'])_0x23e5da['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x9c7af9){return this['collection']['getByInnerView'](_0x9c7af9);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x20fee1 of this['collection'])_0x20fee1['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x41dfba){this['fire']('_activateAnnotation',_0x41dfba);}['createAnnotation'](_0x13b69e){return new T(_0x13b69e);}['createAnnotationView'](_0xa55b0,_0x5ac97c){return new E(_0xa55b0,_0x5ac97c);}['_addActiveAnnotation'](_0x2b84e3){const _0x50e2b2=new Set(this['activeAnnotations']);_0x50e2b2['add'](_0x2b84e3),this['activeAnnotations']=_0x50e2b2;}['_removeActiveAnnotation'](_0x412fa5){const _0x4898dc=new Set(this['activeAnnotations']);_0x4898dc['delete'](_0x412fa5),this['activeAnnotations']=_0x4898dc;}['_bindAnnotationsToVisibleAnnotations'](){const _0x1a7607=this['collection'],_0x58dc8e=this['_visibleAnnotations'];function _0x291eeb(_0x2f602f){const _0x1fb16f=_0x2f602f['source'];_0x1fb16f['isVisible']&&!_0x58dc8e['has'](_0x1fb16f)?_0x58dc8e['add'](_0x1fb16f):!_0x1fb16f['isVisible']&&_0x58dc8e['has'](_0x1fb16f)&&_0x58dc8e['remove'](_0x1fb16f),_0x1fb16f['view']['focusTracker']['remove'](_0x1fb16f['view']['element']),_0x1fb16f['view']['focusTracker']['add'](_0x1fb16f['view']['element']);}this['listenTo'](_0x1a7607,'add',(_0x4445ef,_0x731824)=>{_0x731824['isVisible']&&_0x58dc8e['add'](_0x731824),this['listenTo'](_0x731824,'change:isVisible',_0x291eeb);}),this['listenTo'](_0x1a7607,'remove',(_0x13004c,_0x21ede2)=>{_0x58dc8e['has'](_0x21ede2)&&_0x58dc8e['remove'](_0x21ede2),this['stopListening'](_0x21ede2,'change:isVisible',_0x291eeb);});}['_setupEnterAnnotationKeystroke'](){const _0x49d0f2=_0x4dae1e=>{_0x4dae1e['on']('ready',()=>{_0x4dae1e['keystrokes']['set'](_0x5ad51f,(_0x236be7,_0x2ce941)=>{const _0x9c942d=_0x118483(this['activeAnnotations']['values']());_0x9c942d&&(_0x9c942d['view']['focus'](),_0x2ce941());});});};this['context']instanceof _0x5c5264?_0x49d0f2(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x27ae4a,_0x435c63)=>{_0x49d0f2(_0x435c63);});}['_setupEscapeAnnotationHandling'](){const _0x13a1a9=_0xe3c602=>{const _0x1b5e99=_0xe3c602['source'],_0x224570=[];let _0x276b2a;if(Array['isArray'](_0x1b5e99['target'])){_0x276b2a=_0x1b5e99['target'][0x0],this['context']instanceof _0x5c5264?_0x224570['push'](this['context']):this['context']['editors']&&_0x224570['push'](...this['context']['editors']);for(const _0x448905 of _0x224570)for(const _0x1dbc53 of _0x448905['editing']['view']['domRoots']['values']())if(_0x1dbc53['contains'](_0x276b2a))return void _0x448905['editing']['view']['focus']();_0x276b2a['focus']();}};this['listenTo'](this['collection'],'add',(_0x3e1cbb,_0x394d16)=>{this['listenTo'](_0x394d16,'escape',_0x13a1a9,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x968a0b,_0x1ec749)=>{this['stopListening'](_0x1ec749,'escape',_0x13a1a9);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x4ce48a{['_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(_0x5e1341){super(_0x5e1341),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x5a24ac=this['context']['config'];_0x5a24ac['define']('comments.maxCommentsWhenCollapsed',0x2),_0x5a24ac['define']('comments.maxThreadTotalWeight',0x1f4),_0x5a24ac['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x5a24ac['define']('comments.CommentThreadView',gt),_0x5a24ac['define']('comments.CommentView',Tt),_0x5a24ac['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x3fd4f9=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x59ea16,_0x49b1c4)=>this['_addCommentThread'](_0x49b1c4)),this['on']('submitCommentThread',(_0x118941,_0x25f72c)=>this['_submitCommentThread'](_0x25f72c)),this['on']('resolveCommentThread',(_0x302203,_0x14c5c1)=>this['_resolveCommentThread'](_0x14c5c1)),this['on']('resolveCommentThread',(_0x5ee8ce,_0x13415f)=>this['_updateActiveAnnotation'](_0x13415f),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x474642,_0x2e6d14)=>this['_reopenCommentThread'](_0x2e6d14)),this['on']('reopenCommentThread',(_0x404f66,_0x16edbf)=>this['_updateActiveAnnotation'](_0x16edbf),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x4445e9,_0x5854b5)=>this['_removeCommentThread'](_0x5854b5)),this['on']('updateCommentThread',(_0x19d62f,_0x3dbddf)=>this['_updateCommentThread'](_0x3dbddf)),this['on']('updateCommentThread',(_0x37f3d5,_0x270f23)=>this['_updateActiveAnnotation'](_0x270f23),{'priority':'lowest'}),this['on']('addComment',(_0x13e68e,_0x269f18)=>this['_addComment'](_0x269f18)),this['on']('updateComment',(_0x340839,_0x39f51b)=>this['_updateComment'](_0x39f51b)),this['on']('removeComment',(_0x269b47,_0x13e7f3)=>this['_removeComment'](_0x13e7f3)),this['on']('addComment',(_0x55b243,{threadId:_0x55e5ea,isFromAdapter:_0x5c67a9})=>{if(_0x5c67a9)return;const _0x39b706=this['getCommentThread'](_0x55e5ea),_0x54f0b4=_0x39b706&&this['_threadToController']['get'](_0x39b706);_0x54f0b4&&_0x54f0b4['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x3fd4f9,'change:activeAnnotations',(_0x2c2814,_0x5af797,_0x11299f)=>{const _0x416fbc=Array['from'](_0x11299f)['map'](_0x3db3c7=>this['_viewToController']['get'](_0x3db3c7['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x416fbc?_0x416fbc['model']:null;});}set['adapter'](_0x256aae){if(this['_adapter'])throw new _0x49f2d8('commentsrepository-adapter-already-set');this['_adapter']=_0x256aae;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x2415cb=_t,threadId:_0x555a5c=_0x2c4187(),comments:_0x4745c0=[],unlinkedAt:_0x22f447=null,resolvedAt:_0x5e3a71=null,resolvedBy:_0x22fae3=null,target:_0x35b06d=null,context:_0x4dceeb=null,attributes:_0x97b7e6={},isResolvable:_0x50d2ce=!0x0,isSubmitted:_0x528b72=!0x1,isFromAdapter:_0x121182=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x2415cb),{'channelId':_0x2415cb,'threadId':_0x555a5c,'comments':_0x4745c0,'unlinkedAt':_0x22f447,'resolvedAt':_0x5e3a71,'resolvedBy':_0x22fae3,'target':_0x35b06d,'context':_0x4dceeb,'attributes':_0x97b7e6,'isFromAdapter':_0x121182,'isResolvable':_0x50d2ce,'isSubmitted':_0x528b72}),this['getCommentThread'](_0x555a5c);}['openNewCommentThread']({channelId:_0x2fea8d=_t,threadId:_0x3230c6=_0x2c4187(),target:_0x1d80ee,context:_0x4b3c45=null,isResolvable:_0x475697=!0x0}){if(this['_readOnlyChannels']['has'](_0x2fea8d)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x1d80ee)throw new _0x49f2d8('commentsrepository-missing-target');const _0x406035=this['addCommentThread']({'channelId':_0x2fea8d,'threadId':_0x3230c6,'target':_0x1d80ee,'context':_0x4b3c45,'isResolvable':_0x475697});if(!_0x406035)return null;const _0x4eefa4=this['_threadToController']['get'](_0x406035),_0x1c3ebc=_0x4eefa4['view']['commentThreadInputView']['commentInputView'],_0x591f2b=this['context']['plugins']['get'](y),_0x114a83=_0x591f2b['getByInnerView'](_0x4eefa4['view']);return _0x591f2b['activate'](_0x114a83),_0x1c3ebc['once']('editorReady',()=>_0x1c3ebc['focus']()),_0x406035;}['hasCommentThread'](_0x34974b){if('string'!=typeof _0x34974b)throw new _0x49f2d8('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x34974b);}['updateCommentThread']({channelId:_0x235109=_t,threadId:_0x20471d,context:_0x1c5da8,unlinkedAt:_0xc1d834,attributes:_0x5d627f,isFromAdapter:_0x3111db=!0x1}){return this['fire'](Nt('updateCommentThread',_0x235109),{'channelId':_0x235109,'threadId':_0x20471d,'context':_0x1c5da8,'unlinkedAt':_0xc1d834,'attributes':_0x5d627f,'isFromAdapter':_0x3111db}),this['getCommentThread'](_0x20471d);}['getCommentThread'](_0x1a3356){if('string'!=typeof _0x1a3356)throw new _0x49f2d8('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x1a3356);}['fetchCommentThread']({channelId:_0x86b96f,threadId:_0x4e661f}={}){const _0x36d1fd=this['getCommentThread'](_0x4e661f);if(_0x36d1fd)return Promise['resolve'](_0x36d1fd);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x49f2d8('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x86b96f,'threadId':_0x4e661f})['then'](_0xbd6b9f=>this['hasCommentThread'](_0x4e661f)?this['getCommentThread'](_0x4e661f):_0xbd6b9f?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x86b96f},_0xbd6b9f)):void 0x0)['catch'](_0x5869fc=>{throw console['error'](_0x5869fc),new _0x49f2d8('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x4a606b,skipNotAttached:_0x157979=!0x1,skipEmpty:_0x1373a4=!0x1,toJSON:_0x2815ad=!0x1}={}){const _0x5f224c=[];for(const _0x4ab251 of this['_threads']['values']())_0x4a606b&&_0x4ab251['channelId']!==_0x4a606b||_0x157979&&!_0x4ab251['isAttached']||_0x1373a4&&0x0===_0x4ab251['length']||_0x5f224c['push'](_0x4ab251);return _0x2815ad?_0x5f224c['map'](_0x356331=>_0x356331['toJSON']()):_0x5f224c;}['getAnnotationForCommentThread'](_0x40a204){const _0x46e685=this['_threadToController']['get'](_0x40a204);if(!_0x46e685)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x46e685['view'])||null;}['getCommentThreadForAnnotation'](_0xa3e800){const _0xf72138=this['_viewToController']['get'](_0xa3e800['innerView']);return _0xf72138?_0xf72138['model']:null;}['setActiveCommentThread'](_0x112272){const _0x28c0c1=this['context']['plugins']['get'](y);if(!_0x112272)return void(this['activeCommentThread']&&_0x28c0c1['deactivateAll']());const _0x4901a2=this['getCommentThread'](_0x112272);if(!_0x4901a2)throw new _0x49f2d8('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x112272});if(!this['_threadToController']['has'](_0x4901a2))throw new _0x49f2d8('commentsrepository-active-not-attached',null,{'threadId':_0x112272});const _0x439845=_0x28c0c1['getByInnerView'](this['_threadToController']['get'](_0x4901a2)['view']);_0x28c0c1['activate'](_0x439845);}['switchReadOnly'](_0x529c60,_0xbcbdd9){_0x529c60?this['_readOnlyChannels']['add'](_0xbcbdd9):this['_readOnlyChannels']['delete'](_0xbcbdd9),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x5a3fcc){return this['_readOnlyChannels']['has'](_0x5a3fcc)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x57607d,_0x511dbb){return new vt(_0x57607d,_0x511dbb);}['setPermissions'](_0x440ab6,_0x4bde45=_t){this['_permissions']['set'](_0x4bde45,_0x440ab6),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x335355=_t){return this['_permissions']['has'](_0x335355)?this['_permissions']['get'](_0x335355):bt;}['_addCommentThread']({channelId:_0x1b356e,threadId:_0x105607,comments:_0x3ae93b,unlinkedAt:_0x219ee2,resolvedAt:_0x3f38f5,resolvedBy:_0x9d1a5b,target:_0x196bde,context:_0x45573e,attributes:_0xf4a45b,isFromAdapter:_0x380bed,isResolvable:_0x3240cc,isSubmitted:_0x47f04f}){if('string'!=typeof _0x105607)throw new _0x49f2d8('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x105607});if(this['hasCommentThread'](_0x105607))throw new _0x49f2d8('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x105607});const _0x3f4c1d=new pi(this,{'channelId':_0x1b356e,'id':_0x105607,'context':_0x45573e,'attributes':_0xf4a45b,'unlinkedAt':_0x219ee2,'resolvedAt':_0x3f38f5,'resolvedBy':_0x9d1a5b?this['context']['plugins']['get'](it)['getUser'](_0x9d1a5b):null,'isResolvable':_0x3240cc,'isSubmitted':_0x47f04f||_0x380bed});this['_threads']['set'](_0x105607,_0x3f4c1d);for(const _0x8b23fb of _0x3ae93b)_0x3f4c1d['_add'](this['_createNewComment']({'threadId':_0x105607,..._0x8b23fb}));return _0x196bde&&_0x3f4c1d['attachTo'](_0x196bde),_0x380bed||!_0x3f4c1d['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x1b356e,'threadId':_0x105607});}['_submitCommentThread']({channelId:_0x5cf41f,threadId:_0x1b5365}){if(!this['hasCommentThread'](_0x1b5365))throw new _0x49f2d8('commentsrepository-missing-comment-thread',this);const _0x449991=this['getCommentThread'](_0x1b5365);if(_0x449991['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x559002,comments:_0x10a3a2,resolvedAt:_0x27979c,resolvedBy:_0xe61f99,context:_0x515737,attributes:_0xe3bcc3}=_0x449991,_0x1be1af=this['context']['plugins']['get']('PendingActions'),_0x2bca6b=_0x1be1af['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x5cf41f,'threadId':_0x559002,'comments':_0x10a3a2['map'](_0x363e55=>_0x363e55['toJSON']()),'resolvedAt':_0x27979c,'resolvedBy':_0xe61f99?_0xe61f99['id']:_0xe61f99,'context':_0x515737,'attributes':_0xe3bcc3})['then'](({comments:_0x49b6b3})=>{_0x1be1af['remove'](_0x2bca6b);for(const _0x4d12b8 of _0x49b6b3)this['_updateComment']({'channelId':_0x5cf41f,'threadId':_0x1b5365,'commentId':_0x4d12b8['commentId'],'createdAt':_0x4d12b8['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x24e50c=>{throw console['error'](_0x24e50c),new _0x49f2d8('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x3d0123,target:_0x185be2}){const _0xb86c85=this['getCommentThread'](_0x3d0123);if(!_0xb86c85)throw new _0x49f2d8('commentsrepository-attach-missing-comment-thread',this);const _0x106a62=this['context']['plugins']['get']('PendingActions'),_0xa51a26=this['context']['plugins']['get'](y),_0x1ef922=this['_createCommentThreadView'](_0xb86c85),_0x248cf3=new vt(_0xb86c85,_0x1ef922);let _0x49ab2b=null;_0x1ef922['on']('change:isDirty',(_0x9437ec,_0x867445,_0x37e005)=>{_0x37e005?_0x49ab2b=_0x106a62['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x49ab2b&&(_0x106a62['remove'](_0x49ab2b),_0x49ab2b=null);}),this['_threadToController']['set'](_0xb86c85,_0x248cf3),this['_viewToController']['set'](_0x1ef922,_0x248cf3);const _0x1230bf=new E(this['context']['locale'],_0x1ef922);_0x1230bf['bind']('length')['to'](_0x1ef922),_0x1230bf['bind']('isDirty')['to'](_0x1ef922,'isDirty',_0x1ef922,'length',(_0x4fdaeb,_0x5335a5)=>_0x4fdaeb||!_0x5335a5),_0x1230bf['bind']('isActive')['to'](_0x1ef922),_0x1230bf['type']='comment';const _0x31c013=new T({'view':_0x1230bf,'target':_0x185be2,'type':'comment','isVisible':!_0xb86c85['archivedAt']&&!!('function'==typeof _0x185be2?_0x185be2():_0x185be2)});return _0x1ef922['on']('escape',()=>{_0x31c013['fire']('escape');}),this['_bindAnnotationToEditors'](_0x1ef922,_0x31c013),_0xa51a26['add'](_0x31c013),_0x31c013;}['_bindAnnotationToEditors'](_0x2277b7,_0x120269){this['listenTo'](_0x2277b7,'editorReady',(_0x5e07b0,_0x4a5f08)=>{const _0x1506d2=_0x4a5f08['ui']['view']['body']['bodyCollectionContainer'];_0x120269['focusableElements']['add'](_0x1506d2),this['context']instanceof _0x5c5264&&this['context']['ui']['focusTracker']['add'](_0x1506d2);},{'priority':'highest'}),this['listenTo'](_0x2277b7,'editorDestroyed',(_0x19119b,_0xb54b5a)=>{const _0x2f5254=_0xb54b5a['ui']['view']['body']['bodyCollectionContainer'];_0x120269['focusableElements']['has'](_0x2f5254)&&_0x120269['focusableElements']['remove'](_0x2f5254),this['context']instanceof _0x5c5264&&this['context']['ui']['focusTracker']['remove'](_0x2f5254);});}['_unbindEditors'](_0xacad15){this['stopListening'](_0xacad15,'editorReady'),this['stopListening'](_0xacad15,'editorDestroyed');}['_createCommentThreadView'](_0x3c87b0){const _0xb58dc0=this['context']['plugins']['get'](it),{config:_0x24d9f0,locale:_0x53673e}=this['context'],_0x2a2cbf=pt(_0x24d9f0['get']('locale'),_0x53673e);return new(0x0,(_0x24d9f0['get']('comments'))['CommentThreadView'])(_0x53673e,_0x3c87b0,_0xb58dc0['me'],{'editorConfig':{..._0x24d9f0['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x24d9f0['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x24d9f0['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x24d9f0['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x24d9f0['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x2a2cbf,'CommentView':_0x24d9f0['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x5dbd2e,channelId:_0x246f50,resolvedAt:_0x4d25c9,resolvedBy:_0x206e55,isFromAdapter:_0x5e1863}){if(!this['hasCommentThread'](_0x5dbd2e))throw new _0x49f2d8('commentsrepository-missing-comment-thread',null,{'threadId':_0x5dbd2e});const _0x16dae8=this['getCommentThread'](_0x5dbd2e);if(_0x16dae8['isResolved'])throw new _0x49f2d8('commentsrepository-resolved-comment-thread',null,{'threadId':_0x5dbd2e});const _0x470db4=this['context']['plugins']['get'](it);if(_0x16dae8['resolvedBy']=_0x470db4['getUser'](_0x206e55),_0x16dae8['resolvedAt']=_0x4d25c9,_0x5e1863||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x12c6ff=this['context']['plugins']['get']('PendingActions'),_0x500632=_0x12c6ff['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x246f50,'threadId':_0x5dbd2e})['then'](({resolvedAt:_0x40ab88,resolvedBy:_0x232217})=>{_0x12c6ff['remove'](_0x500632),_0x16dae8['resolvedBy']['id']!==_0x232217&&(_0x16dae8['resolvedBy']=_0x470db4['getUser'](_0x232217)),_0x16dae8['resolvedAt']=_0x40ab88;})['catch'](_0x3b7280=>{throw console['error'](_0x3b7280),new _0x49f2d8('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x523d87,channelId:_0x14d2e5,isFromAdapter:_0x1fdf29}){if(!this['hasCommentThread'](_0x523d87))throw new _0x49f2d8('commentsrepository-missing-comment-thread',null,{'threadId':_0x523d87});const _0x517eed=this['getCommentThread'](_0x523d87);if(!_0x517eed['isResolved'])throw new _0x49f2d8('commentsrepository-reopen-comment-thread',null,{'threadId':_0x523d87});if(_0x517eed['resolvedBy']=null,_0x517eed['resolvedAt']=null,_0x1fdf29||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0xf55a56=this['context']['plugins']['get']('PendingActions'),_0x10da43=_0xf55a56['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x14d2e5,'threadId':_0x523d87})['then'](()=>_0xf55a56['remove'](_0x10da43))['catch'](_0x585eaa=>{throw console['error'](_0x585eaa),new _0x49f2d8('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x5d30df,isFromAdapter:_0x1572c3}){const _0x4abe19=this['getCommentThread'](_0x5d30df);if(!_0x4abe19)throw new _0x49f2d8('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x5d30df),this['_threads']['delete'](_0x5d30df),!_0x4abe19['isSubmitted']||_0x1572c3||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x3d50dd=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4235b4}=_0x4abe19,_0xf62b47=_0x3d50dd['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x4235b4,'threadId':_0x5d30df})['then'](()=>_0x3d50dd['remove'](_0xf62b47))['catch'](_0x49ae57=>{throw console['error'](_0x49ae57),new _0x49f2d8('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0xbccbbd,unlinkedAt:_0x9ba586,context:_0xf98ef1,attributes:_0x386004,isFromAdapter:_0x5df5f6}){if('string'!=typeof _0xbccbbd)throw new _0x49f2d8('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0xbccbbd});if(!this['hasCommentThread'](_0xbccbbd))throw new _0x49f2d8('commentsrepository-missing-comment-thread',null,{'threadId':_0xbccbbd});const _0x25cc51=this['getCommentThread'](_0xbccbbd);let _0x2b8818=!0x1;if(void 0x0!==_0xf98ef1&&_0x25cc51['context']!==_0xf98ef1&&(_0x25cc51['context']=_0xf98ef1,_0x2b8818=!0x0),void 0x0!==_0x9ba586&&_0x25cc51['unlinkedAt']!==_0x9ba586&&(_0x25cc51['unlinkedAt']=_0x9ba586,_0x2b8818=!0x0),_0x386004&&!At(_0x386004,_0x25cc51['attributes'])&&(_0x25cc51['attributes']=_0x386004,_0x2b8818=!0x0),!_0x2b8818)return Promise['resolve']();if(!_0x25cc51['isSubmitted']||_0x5df5f6||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x305cdc=this['context']['plugins']['get']('PendingActions'),{channelId:_0x9e1c02}=_0x25cc51,_0x38ef16=_0x305cdc['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x9e1c02,'threadId':_0xbccbbd,'context':_0xf98ef1,'unlinkedAt':_0x9ba586,'attributes':_0x386004})['then'](()=>_0x305cdc['remove'](_0x38ef16))['catch'](_0x5e81f1=>{throw console['error'](_0x5e81f1),new _0x49f2d8('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x1ba6fb){const _0x5e252f=this['context']['plugins']['get'](y),_0x5163fa=this['getCommentThread'](_0x1ba6fb);if(_0x5163fa['_isAttached']=!0x1,this['_threadToController']['has'](_0x5163fa)){const _0x7ef675=this['_threadToController']['get'](_0x5163fa),_0x5339ac=_0x7ef675['view'],_0x39041f=_0x5e252f['getByInnerView'](_0x5339ac);this['_threadToController']['delete'](_0x5163fa),this['_viewToController']['delete'](_0x5339ac),_0x39041f&&_0x5e252f['remove'](_0x39041f),_0x7ef675['destroy'](),_0x5339ac['destroy']()['then'](()=>{this['_unbindEditors'](_0x5339ac);});}}['_updateActiveAnnotation']({threadId:_0x6210b8,resolvedAt:_0x2ccfb0,unlinkedAt:_0x140e84}){const _0x3518aa=!!_0x2ccfb0,_0x2a581e=this['context']['plugins']['get'](y),_0x8a21a5=this['getCommentThread'](_0x6210b8);if(this['_threadToController']['has'](_0x8a21a5)){const _0xe8aff3=this['_threadToController']['get'](_0x8a21a5)['view'],_0x2f54a9=_0x2a581e['getByInnerView'](_0xe8aff3);_0x2f54a9&&(_0x3518aa&&_0x2a581e['_removeActiveAnnotation'](_0x2f54a9),_0x140e84?_0x2f54a9['isVisible']=!0x1:_0x2f54a9['refreshVisibility']());}}['_getExternalAuthor'](_0x56c9c4){const _0x172f30=this['context']['plugins']['get'](it),_0xea372b=It('external:'+_0x56c9c4),_0x39543b=_0x172f30['getUser'](_0xea372b);return _0x39543b||_0x172f30['addUser']({'id':_0xea372b,'name':_0x56c9c4});}['_createNewComment']({threadId:_0x539132,commentId:_0x1de5ee=_0x2c4187(),content:_0x4231aa,authorId:_0x4ef6cd,createdAt:_0x592310,attributes:_0x4b79d7}){if('string'!=typeof _0x1de5ee)throw new _0x49f2d8('commentsrepository-invalid-commentid');if('string'!=typeof _0x4ef6cd)throw new _0x49f2d8('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x4231aa||!_0x4231aa['trim']())throw new _0x49f2d8('commentsrepository-invalid-comment-content');const _0x971028=this['context']['plugins']['get'](it)['getUser'](_0x4ef6cd);if(!_0x971028)throw new _0x49f2d8('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x4ef6cd});let _0x58c01e=null,_0x1f63ef=_0x592310;return _0x4b79d7?.['@external']&&(_0x58c01e=this['_getExternalAuthor'](_0x4b79d7['@external']['authorName']),_0x1f63ef=new Date(_0x4b79d7['@external']['createdAt'])),new wi(this,{'threadId':_0x539132,'id':_0x1de5ee,'author':_0x58c01e||_0x971028,'creator':_0x971028,'content':_0x4231aa,'createdAt':_0x592310,'authoredAt':_0x1f63ef,'attributes':_0x4b79d7});}['_addComment'](_0x58c849){let {threadId:_0x41ae27,content:_0xdca0e8,attributes:_0x13f8c7,isFromAdapter:_0x1c9944}=_0x58c849;const _0xf5ec39=this['getCommentThread'](_0x58c849['threadId']);if(!_0xf5ec39)throw new _0x49f2d8('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x1abee8=this['_createNewComment'](_0x58c849),{id:_0xfaf6d0}=_0x1abee8;if(_0xf5ec39['_add'](_0x1abee8),_0x1c9944||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0xf5ec39['isSubmitted'])return Promise['resolve']();const _0x1b5bbe=this['context']['plugins']['get']('PendingActions'),{channelId:_0x537a55}=_0xf5ec39,_0x1519a0=_0x1b5bbe['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x13f8c7||(_0x13f8c7={}),this['adapter']['addComment']({'channelId':_0x537a55,'threadId':_0x41ae27,'commentId':_0xfaf6d0,'content':_0xdca0e8,'attributes':_0x13f8c7})['then'](_0x82c9ab=>{_0x1b5bbe['remove'](_0x1519a0),_0x82c9ab&&this['_updateComment']({'channelId':_0x537a55,'threadId':_0x41ae27,'commentId':_0xfaf6d0,'createdAt':_0x82c9ab['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x32e232=>{throw console['error'](_0x32e232),new _0x49f2d8('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x317be4,commentId:_0x44cae0,content:_0x264361,createdAt:_0x3b019e,attributes:_0x386f69,isFromAdapter:_0x534867}){if(void 0x0!==_0x264361&&('string'!=typeof _0x264361||!_0x264361['trim']()['length']))throw new _0x49f2d8('commentsrepository-update-comment-invalid-content');const _0x5511cb=this['getCommentThread'](_0x317be4),_0xa7c86d=_0x5511cb['getComment'](_0x44cae0);if(!_0xa7c86d)throw new _0x49f2d8('commentsrepository-update-missing-comment',this);let _0x19c5ee=!0x1;if(_0x264361&&_0x264361!==_0xa7c86d['content']&&(_0xa7c86d['isEditable']||_0x534867)&&(_0xa7c86d['content']=_0x264361,_0x19c5ee=!0x0),_0x3b019e&&_0x3b019e!==_0xa7c86d['createdAt']&&(_0xa7c86d['createdAt']=_0x3b019e,_0xa7c86d['attributes']&&_0xa7c86d['attributes']['@external']||(_0xa7c86d['authoredAt']=_0x3b019e),_0x19c5ee=!0x0),_0x386f69&&!At(_0x386f69,_0xa7c86d['attributes'])&&(_0xa7c86d['attributes']=_0x386f69,_0x19c5ee=!0x0),!_0x19c5ee)return Promise['resolve']();if(_0x5511cb['fire']('commentUpdated'),_0x534867||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x4639b7=this['context']['plugins']['get']('PendingActions'),{channelId:_0x17f92c}=this['getCommentThread'](_0xa7c86d['threadId']),_0xe7dc9b=_0x4639b7['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x17f92c,'threadId':_0x317be4,'commentId':_0x44cae0,'content':_0x264361,'attributes':_0x386f69})['then'](()=>_0x4639b7['remove'](_0xe7dc9b))['catch'](_0x24e8fd=>{throw console['error'](_0x24e8fd),new _0x49f2d8('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x42553b,commentId:_0x436da3,isFromAdapter:_0x25c142}){const _0x34e9b0=this['getCommentThread'](_0x42553b),_0x189ebf=_0x34e9b0['getComment'](_0x436da3);if(!_0x189ebf)throw new _0x49f2d8('commentsrepository-remove-missing-comment',this);if(_0x34e9b0['_remove'](_0x189ebf),_0x25c142||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x1cec13=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5a45f1}=_0x34e9b0,_0x347955=_0x1cec13['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x5a45f1,'threadId':_0x42553b,'commentId':_0x436da3})['then'](()=>_0x1cec13['remove'](_0x347955))['catch'](_0x1d8677=>{throw console['error'](_0x1d8677),new _0x49f2d8('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
- _0x3068a3(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x522237,_0x528a64){super();const _0x41b568=_0x528a64['isResolvable'];this['channelId']=_0x528a64['channelId'],this['id']=_0x528a64['id'],this['comments']=new _0x3b6a04(),this['_repository']=_0x522237,this['_isAttached']=!0x1,this['_isSubmitted']=_0x528a64['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x522237,'_permissions',_0x522237,'_readOnlyChannels',()=>_0x522237['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x522237,'_permissions',()=>_0x522237['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x522237,'_permissions',()=>{const _0xd30303=_0x522237['getPermissions'](this['channelId']);return _0xd30303['write']||_0xd30303['admin'];}),this['bind']('isResolvable')['to'](_0x522237,'_permissions',()=>_0x41b568&&_0x522237['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x528a64['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x117e79,_0x57b0d5)=>_0x117e79?_0x57b0d5?_0x117e79<_0x57b0d5?_0x117e79:_0x57b0d5:_0x117e79:_0x57b0d5),this['set']('unlinkedAt',_0x528a64['unlinkedAt']||null),this['set']('resolvedAt',_0x528a64['resolvedAt']||null),this['set']('resolvedBy',_0x528a64['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x4708da=>!!_0x4708da),this['set']('attributes',_0x528a64['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x4aae4d,_0x14af77)=>_0x4aae4d+_0x14af77['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x5eb65c,id:_0x3a704e}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x5eb65c),{'channelId':_0x5eb65c,'threadId':_0x3a704e});}['setUnlinkedAt'](_0x401b5a){this['_update']({'unlinkedAt':_0x401b5a});}['resolve']({resolvedAt:_0x43585e=new Date(),resolvedBy:_0x5b4a6e=null,isFromAdapter:_0x4480e2=!0x1}={}){const _0x141013=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x508e08,id:_0x10ac65}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x508e08),{'channelId':_0x508e08,'threadId':_0x10ac65,'resolvedAt':_0x43585e,'resolvedBy':_0x5b4a6e||_0x141013['id'],'isFromAdapter':_0x4480e2});}['reopen']({isFromAdapter:_0x1ce2e1=!0x1}={}){const {channelId:_0x53ab15,id:_0x352e75}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x53ab15),{'channelId':_0x53ab15,'threadId':_0x352e75,'isFromAdapter':_0x1ce2e1});}['setContext'](_0x9ce881){this['context']||this['_update']({'context':_0x9ce881});}['setAttribute'](_0x467498,_0x123652){const _0x497d87=wt(this['attributes']);yt(_0x497d87,_0x467498,_0x123652),this['_update']({'attributes':_0x497d87});}['removeAttribute'](_0x1c9118){const _0x5f1d01=wt(this['attributes']);Ct(_0x5f1d01,_0x1c9118),this['_update']({'attributes':_0x5f1d01});}['remove']({isFromAdapter:_0x317a2a=!0x1}={}){const {channelId:_0x131465,id:_0xcd5a4b}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x131465),{'channelId':_0x131465,'threadId':_0xcd5a4b,'isFromAdapter':_0x317a2a});}['attachTo'](_0x31d09c){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x31d09c});}['addComment'](_0xda73a4){const {channelId:_0x406fd6,id:_0x4cd512}=this;this['_repository']['fire'](Nt('addComment',_0x406fd6,_0x4cd512),Object['assign']({'channelId':_0x406fd6,'threadId':_0x4cd512},_0xda73a4));}['getComment'](_0x290e18){if('string'!=typeof _0x290e18)throw new _0x49f2d8('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x290e18});return this['comments']['get'](_0x290e18);}['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'](_0x4465c6=>_0x4465c6['toJSON']()),'attributes':this['attributes']};}['_add'](_0x83a82e){return this['listenTo'](_0x83a82e,'change:authoredAt',()=>{const _0x5406e1=this['_findOptimalIndex'](_0x83a82e),_0x43cff1=this['comments'];_0x5406e1-0x1!=_0x43cff1['getIndex'](_0x83a82e)&&_0x5406e1+0x1!=_0x43cff1['getIndex'](_0x83a82e)&&(this['_remove'](_0x83a82e),this['_add'](_0x83a82e));}),this['comments']['add'](_0x83a82e,this['_findOptimalIndex'](_0x83a82e));}['_update'](_0x3edd29){const {channelId:_0x1476da,id:_0x613bb4}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x1476da),{..._0x3edd29,'channelId':_0x1476da,'threadId':_0x613bb4});}['_remove'](_0x39f12e){return this['stopListening'](_0x39f12e),_0x39f12e['destroy'](),this['comments']['remove'](_0x39f12e);}['_findOptimalIndex'](_0x262fd1){const _0x1e8387=this['comments']['find'](_0x39d211=>new Date(_0x39d211['authoredAt'])['getTime']()>new Date(_0x262fd1['authoredAt'])['getTime']());return _0x1e8387?this['comments']['getIndex'](_0x1e8387):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
- _0x3068a3(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x1c3bf2,_0x1039dd){super();const _0x515d06=_0x1c3bf2['context']['plugins']['get'](it)['me'],_0x4f4775=_0x1c3bf2['getCommentThread'](_0x1039dd['threadId']),_0x5b6edb=0x0===_0x4f4775['comments']['length'],_0x401430=_0x515d06===_0x1039dd['author'];this['id']=_0x1039dd['id'],this['threadId']=_0x1039dd['threadId'],this['author']=_0x1039dd['author'],this['creator']=_0x1039dd['creator'],this['isExternal']=Boolean(_0x1039dd['attributes']&&_0x1039dd['attributes']['@external']),this['set']('content',_0x1039dd['content']),this['createdAt']=_0x1039dd['createdAt']||new Date(),this['set']('authoredAt',_0x1039dd['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x4f4775,'resolvedAt'),this['set']('attributes',_0x1039dd['attributes']||{}),this['bind']('isEditable')['to'](_0x1c3bf2,'_permissions',()=>{const _0x32f996=_0x1c3bf2['getPermissions'](_0x4f4775['channelId'])['write'],_0x260bdd=_0x1c3bf2['getPermissions'](_0x4f4775['channelId'])['modifyAll'];return _0x401430&&_0x32f996||!_0x401430&&_0x260bdd;}),this['bind']('isRemovable')['to'](_0x4f4775,'isRemovable',_0x1c3bf2,'_permissions',_0x28bb25=>{const _0x37c939=_0x1c3bf2['getPermissions'](_0x4f4775['channelId'])['write'],_0x1fd78a=_0x1c3bf2['getPermissions'](_0x4f4775['channelId'])['modifyAll'];return _0x401430&&_0x37c939||_0x28bb25&&_0x5b6edb||!_0x401430&&_0x1fd78a&&!_0x5b6edb;}),this['bind']('isReadOnly')['to'](_0x4f4775,'isReadOnly'),this['_repository']=_0x1c3bf2;}get['weight'](){return Math['max'](function(_0xcdcaf9){const _0x3408c9=document['createElement']('div');return _0x3408c9['innerHTML']=_0xcdcaf9,_0x3408c9['textContent']['length'];}(this['content']),0xc8);}['update'](_0xd784b4){const {threadId:_0x4571ee,id:_0x5e744c}=this;if(!this['_repository']['hasCommentThread'](_0x4571ee))throw new _0x49f2d8('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x199621}=this['_repository']['getCommentThread'](_0x4571ee);this['_repository']['fire'](Nt('updateComment',_0x199621,_0x4571ee),{'channelId':_0x199621,'threadId':_0x4571ee,'commentId':_0x5e744c,..._0xd784b4});}['setAttribute'](_0x54f7e9,_0x2df4ff){const _0x2e2016=wt(this['attributes']);yt(_0x2e2016,_0x54f7e9,_0x2df4ff),this['update']({'attributes':_0x2e2016});}['removeAttribute'](_0x3eecdc){const _0x2523d5=wt(this['attributes']);Ct(_0x2523d5,_0x3eecdc),this['update']({'attributes':_0x2523d5});}['remove'](_0x1ce2fb={}){if(!_0x1ce2fb['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x49ba3e,id:_0x2df85e}=this;if(!this['_repository']['hasCommentThread'](_0x49ba3e))throw new _0x49f2d8('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x5d9420}=this['_repository']['getCommentThread'](_0x49ba3e);this['_repository']['fire'](Nt('removeComment',_0x5d9420,_0x49ba3e),{'channelId':_0x5d9420,'threadId':_0x49ba3e,'commentId':_0x2df85e,..._0x1ce2fb});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x27b6f7,..._0x179999){for(const _0x55d7d2 of _0x179999)void 0x0!==_0x55d7d2&&(_0x27b6f7+=':'+String(_0x55d7d2));return _0x27b6f7;}class ot extends _0xc21960{constructor(_0x1e98e4){super(_0x1e98e4),this['set']('hasContent',!0x1);}['refresh'](){const _0x43eac3=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x256362 of _0x43eac3['getRanges']())if(this['_hasContent'](_0x256362))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x667814=_0x2c4187(),ranges:_0x4ddd8a,comment:_0x3e3228}={}){const _0x205feb=this['editor']['model'],_0x4cd169=_0x4ddd8a??Array['from'](_0x205feb['document']['selection']['getRanges']()),_0x3e0de6=[];for(const _0x1c462e of _0x4cd169)this['_hasContent'](_0x1c462e)&&_0x3e0de6['push'](this['_trimToContent'](_0x1c462e));if(!_0x3e0de6['length'])throw new _0x49f2d8('addcommentthreadcommand-incorrect-ranges',null);_0x3e3228&&this['_createCommentThread'](_0x667814,_0x3e3228),this['_createMarkersFromRanges'](_0x667814,_0x3e0de6,!!_0x3e3228);}['_createMarkersFromRanges'](_0x59236d,_0x52fb74,_0x395fdb){this['editor']['model']['change'](_0x350275=>{for(const _0x292cd8 of _0x52fb74){const _0x411f10=_0x2c4187()['substr'](0x1,0x5),_0x30dab6='comment:'+_0x59236d+':'+_0x411f10;_0x350275['addMarker'](_0x30dab6,{'range':_0x292cd8,'usingOperation':_0x395fdb,'affectsData':_0x395fdb});}});}['_createCommentThread'](_0x2a203d,_0xf0016a){const _0x58ffaa=this['editor']['plugins']['get']('CommentsRepository'),_0x3ad2b7=this['editor']['config']['get']('collaboration.channelId'),_0xa51a1d=this['editor']['plugins']['get']('Users')['me'];if(!_0xa51a1d)throw new _0x49f2d8('addcommentthreadcommand-user-not-found',null);_0x58ffaa['addCommentThread']({'threadId':_0x2a203d,'channelId':_0x3ad2b7,'comments':[{'authorId':_0xa51a1d['id'],'content':_0xf0016a,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x48d0e0){for(const _0xb78e5e of _0x48d0e0['getItems']())if(this['_itemIsContent'](_0xb78e5e))return!0x0;return!0x1;}['_itemIsContent'](_0x1f7b79){return _0x1f7b79['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x1f7b79)&&!_0x1f7b79['is']('element','tableCell');}['_trimToContent'](_0x3f050c){const _0x163da3=_0x215948=>!this['_itemIsContent'](_0x215948['item']),_0x566ecd=_0x3f050c['start']['getLastMatchingPosition'](_0x163da3),_0x421e48=_0x3f050c['end']['getLastMatchingPosition'](_0x163da3,{'direction':'backward'});return this['editor']['model']['createRange'](_0x566ecd,_0x421e48);}}class b extends _0x2a31b7{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x33b784){super(_0x33b784),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x3418ee=this['editor'],_0x239ecf=_0x3418ee['model']['document']['selection'],_0x636fed=_0x33ca38(()=>this['refreshSelectedViews'](),0xa);_0x239ecf['on']('change:range',(_0x547ff2,_0x2388ef)=>{_0x2388ef['directChange']&&(_0x636fed['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x3418ee['editing']['view']['document'],'change:isFocused',(_0x2e44c4,_0xdd2e57,_0xc3b87f)=>{_0xc3b87f&&_0x636fed();}),this['listenTo'](_0x3418ee['ui']['focusTracker'],'change:isFocused',(_0x192e32,_0x57e64a,_0x53106d)=>{_0x53106d||this['fire']('blur',{'isAnnotationTracked':_0x38796d=>this['_editorAnnotationsData']['has'](_0x38796d['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x25789d){if(this['_editorAnnotations']['has'](_0x25789d['view']))return;this['_editorAnnotations']['add'](_0x25789d['view']),this['editor']['ui']['focusTracker']['add'](_0x25789d['view']['element']);const _0x5cd53e=this['editor']['plugins']['get'](y);this['listenTo'](_0x5cd53e['collection'],'remove',(_0x1e6ead,_0x1b4e48)=>{this['editor']['ui']['focusTracker']['remove'](_0x1b4e48['view']['element']),this['_editorAnnotations']['delete'](_0x1b4e48['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x4addd9){if('function'!=typeof _0x4addd9)throw new _0x49f2d8('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x4addd9);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x4b4428,annotations:_0x15480b}){const _0xfc1ed2=[],_0x5a5771=this['editor']['model']['document']['selection'],_0x11f458=Array['from'](_0x5a5771['getRanges']());for(const [_0x9cd7a2,_0x1a6609]of this['_editorAnnotationsData']){const _0x1a1e55=_0x5c4ada(_0x1a6609),_0xc099b5=_0x15480b['getByInnerView'](_0x9cd7a2);_0x1a1e55&&_0xc099b5&&_0xfc1ed2['push']({'annotation':_0xc099b5,'range':_0x1a1e55});}function _0x5c4ada(_0xfa0af){for(const _0x233a09 of _0xfa0af)for(const _0x1b46ee of _0x11f458)if(_0x233a09['containsRange'](_0x1b46ee,!_0x5a5771['isCollapsed']))return _0x233a09;return null;}return _0xfc1ed2['sort']((_0x4efd0a,_0x36dce5)=>{const _0x1f9545=_0x4efd0a['range'],_0x2be32a=_0x36dce5['range'];if(!_0x1f9545['isEqual'](_0x2be32a)){if(_0x1f9545['containsRange'](_0x2be32a,!0x0))return 0x1;if(_0x2be32a['containsRange'](_0x1f9545,!0x0))return-0x1;}return _0x4efd0a['annotation']==_0x4b4428?-0x1:_0x36dce5['annotation']==_0x4b4428?0x1:0x0;})['map'](_0x488005=>_0x488005['annotation']);}get['_editorAnnotationsData'](){const _0x4f4ba7=new Map();for(const _0x3f629c of Array['from'](this['_dataCollectors']))for(const [_0x10d4d5,_0x405a30]of _0x3f629c())_0x4f4ba7['set'](_0x10d4d5,_0x405a30);return _0x4f4ba7;}}class st extends _0x2a31b7{['afterInit'](){const _0x3c6772=this['editor'];if(!_0x3c6772['plugins']['has']('RestrictedEditingModeEditing'))return;_0x3c6772['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x2a31b7{constructor(_0x357c0b){super(_0x357c0b),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x3ddbae=this['editor'],_0x1d6ef7=_0x3ddbae['commands']['get']('importWord'),_0x318a77=_0x3ddbae['plugins']['get'](it);_0x1d6ef7&&(_0x1d6ef7['on']('execute',(_0xe9ec2a,[,_0x32c1a4])=>{_0x32c1a4['collaboration_features']={'comments':!0x0,'user_id':_0x318a77['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x1d6ef7,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x3e773b,_0x593541){const {comment_threads:_0x5b639d}=_0x593541;_0x5b639d&&_0x5b639d['forEach'](({thread_id:_0x54b32b,comments:_0x35c737,is_resolved:_0xbea4af})=>{const _0x518b95=new Date(),_0xdd5407=_0x35c737['map'](({author:_0xc6621d,content:_0x4ed6c8,created_at:_0x42a7fb})=>({'content':_0x4ed6c8,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x518b95,'attributes':{'@external':{'authorName':_0xc6621d,'createdAt':_0x42a7fb?new Date(_0x42a7fb):new Date(),'source':'importWord'}}})),_0x340e16=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x340e16,'threadId':_0x54b32b,'comments':_0xdd5407,'resolvedAt':_0xbea4af?_0x518b95:null});});}}class at extends _0x2a31b7{constructor(_0x416a55){super(_0x416a55),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x45cb23=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x45cb23,'contentInsertion',(_0x2e8362,_0x104b81)=>this['_removeMarkersWithoutThreads'](_0x104b81['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x1d63ee){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x1d63ee;const _0x4cf09d=this['editor']['plugins']['get']('CommentsRepository');for(const _0x466d64 of _0x1d63ee['keys']()){const [_0x5eab16,_0x2dcc74]=_0x466d64['split'](':');'comment'!=_0x5eab16||_0x4cf09d['hasCommentThread'](_0x2dcc74)||_0x1d63ee['delete'](_0x466d64);}return _0x1d63ee;}['_registerMarkerInClipboardPipeline'](){const _0x51546d=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0xab3f9f=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0xab3f9f&&_0x51546d['_registerMarkerToCopy']('comment',_0xab3f9f);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0xff934e){switch(_0xff934e){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0x573364){const _0x4fd999=_0x573364['split'](':');return{'group':_0x4fd999[0x0],'id':_0x4fd999[0x1],'part':_0x4fd999[0x2]};}class ut extends _0x2a31b7{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x2b269e,_0x22aab6)=>{if(!_0x22aab6['options']['showCommentHighlights'])return null;if(_0x22aab6['options']['ignoreResolvedComments']){const {id:_0x4dcc98}=ft(_0x2b269e['markerName']),_0x25dff6=this['editor']['plugins']['get'](o);if(_0x25dff6['getCommentThread'](_0x4dcc98)?.['isResolved']&&_0x2b269e['item'])return _0x22aab6['consumable']['consume'](_0x2b269e['item'],'addMarker:'+_0x2b269e['markerName']),_0x22aab6['consumable']['consume'](_0x2b269e['item'],'removeMarker:'+_0x2b269e['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5a6b85=>{_0x5a6b85['on']('addMarker:comment',(_0x36994b,_0x49f041,_0x33a1f8)=>{if(!_0x33a1f8['options']['showCommentHighlights'])return;const _0x2c79d1=_0x49f041['item'];if(!_0x2c79d1)return;const _0x265d50=_0x33a1f8['mapper']['toViewElement'](_0x2c79d1);this['editor']['model']['schema']['isObject'](_0x2c79d1)&&_0x265d50&&!_0x265d50['getCustomProperty']('widget')&&_0x265d50['is']('containerElement')&&_0x19d947(_0x265d50,_0x33a1f8['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x1ed167,{writer:_0x3de669,options:_0x42f378})=>{if(!_0x42f378['showCommentHighlights'])return null;const _0x179a8e=_0x3de669['createContainerElement']('div'),_0x4cc53a=_0x3de669['createEmptyElement']('hr');return _0x3de669['addClass']('ck-horizontal-line',_0x179a8e),_0x3de669['insert'](_0x3de669['createPositionAt'](_0x179a8e,0x0),_0x4cc53a),_0x179a8e;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x37d456,{writer:_0x5ad791,options:_0x2e0120})=>{if(!_0x2e0120['showCommentHighlights'])return null;const _0x2af401=_0x5ad791['createContainerElement']('span'),_0x1dbb3b=_0x5ad791['createEmptyElement']('img');return _0x5ad791['addClass']('image-inline',_0x2af401),_0x5ad791['insert'](_0x5ad791['createPositionAt'](_0x2af401,0x0),_0x1dbb3b),_0x2af401;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x7bbb2f,{writer:_0x589b83,options:_0x38172c})=>{if(_0x38172c['showCommentHighlights'])return _0x589b83['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x2d3263,_0x182a64,_0x3040a2)=>{_0x3040a2['options']['showCommentHighlights']&&_0x2d3263['stop']();},{'priority':'high'});}}class r extends _0x2a31b7{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(_0x9fe94d){super(_0x9fe94d),this['set']('isThreadsLoadingPaused',!0x0),_0x9fe94d['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x132e5f,_0x207094,_0x1f7a02,_0x1078ee)=>{const _0x159476=_0x9fe94d['plugins']['get'](o),_0x4ef5ce=_0x1f7a02?ft(_0x1f7a02)['id']:null;_0x9fe94d['model']['change'](()=>{if(_0x4ef5ce){const _0x6c5876=this['getAllMarkersForId'](_0x4ef5ce);for(const _0x53eeba of _0x6c5876)_0x9fe94d['editing']['reconvertMarker'](_0x53eeba);}if(_0x1078ee){const {id:_0x198f22}=ft(_0x1078ee),_0x140032=_0x159476['getCommentThread'](_0x198f22);if(_0x140032&&_0x140032['unlinkedAt'])return;if(_0x140032&&!_0x140032['isAttached'])return;const _0x481cf9=this['getAllMarkersForId'](_0x198f22);for(const _0x10f0e2 of _0x481cf9)_0x9fe94d['editing']['reconvertMarker'](_0x10f0e2);}}),_0x4ef5ce&&this['scrollToThreadMarker'](_0x4ef5ce);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x3e4d18=this['editor'],_0x1025ed=_0x3e4d18['plugins']['get'](o),_0x4b8d1e=_0x3e4d18['config']['get']('collaboration.channelId'),_0x350882=_0x1025ed['getCommentThreads']()['filter'](_0x579655=>_0x579655['channelId']!==_0x4b8d1e);_0x3e4d18['commands']['add']('addCommentThread',new ot(_0x3e4d18)),this['listenTo'](_0x3e4d18,'change:isReadOnly',(_0x1a6dd2,_0x2b7b8c,_0xb5bcb4)=>{_0x1025ed['switchReadOnly'](_0xb5bcb4,_0x3e4d18['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x1025ed,dt('addCommentThread',_0x4b8d1e),(_0x1a5edb,{threadId:_0x402640})=>{const _0x591eaf=this['editor']['plugins']['get'](o)['getCommentThread'](_0x402640);_0x591eaf?.['unlinkedAt']&&this['_attachArchivedThread'](_0x402640);}),this['listenTo'](_0x1025ed,dt('removeCommentThread',_0x4b8d1e),(_0x32a00b,{threadId:_0x57358d})=>{_0x3e4d18['model']['enqueueChange']({'isUndoable':!0x1},_0x396b3e=>{const _0x45e7af=this['getAllMarkersForId'](_0x57358d);for(const _0x5b1561 of _0x45e7af)_0x396b3e['removeMarker'](_0x5b1561);});}),this['listenTo'](_0x1025ed,dt('resolveCommentThread',_0x4b8d1e),(_0x46c17c,{threadId:_0x1434bf})=>{(this['_reconvertMarkers'](_0x1434bf),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x1434bf)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x1025ed,dt('reopenCommentThread',_0x4b8d1e),(_0x4c3ec9,{threadId:_0x54f7dd})=>{this['_reconvertMarkers'](_0x54f7dd);},{'priority':'low'}),this['listenTo'](_0x1025ed,dt('addComment',_0x4b8d1e),(_0x4a9191,{threadId:_0x296b24,isFromAdapter:_0x2f58d6})=>{const _0xadd1ce=this['getAllMarkersForId'](_0x296b24);if(_0x2f58d6||0x0==_0xadd1ce['length']||!_0x1025ed['hasCommentThread'](_0x296b24))return;0x1===_0x1025ed['getCommentThread'](_0x296b24)['length']&&_0x3e4d18['model']['enqueueChange']({'isUndoable':!0x1},_0x5a61dc=>{for(const _0x24786f of _0xadd1ce)_0x5a61dc['updateMarker'](_0x24786f,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x350882);}['afterInit'](){!async function(_0x3c5874){const _0x2239d5=_0x4811d1([0x4c,0x6b,0x50,0x37,0x61,0x69,0x65,0x44,0x6a,0x76,0x46,0x32,0x68,0x33,0x75,0x63,0x51,0x39,0x55,0x6e,0x67,0x42,0x47,0x4a,0x45,0x56,0x35,0x7a,0x70,0x4d,0x41,0x62,0x4b,0x4e,0x4f,0x58,0x64,0x77,0x38,0x43,0x73,0x6d,0x49,0x71,0x48,0x31,0x72,0x57,0x34,0x6f,0x59,0x53,0x54,0x30,0x52,0x66,0x5a,0x79,0x78,0x6c,0x36,0x74]),_0xef3ca1=0x43adf80c,_0x2bf575=0x43aa972c^_0xef3ca1,_0x55dab6=window[_0x4811d1([0x44,0x61,0x74,0x65])][_0x4811d1([0x6e,0x6f,0x77])](),_0x8bba3b=_0x3c5874[_0x4811d1([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x19b4da=new window[(_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x31c56c=>{_0x8bba3b[_0x4811d1([0x6f,0x6e,0x63,0x65])](_0x4811d1([0x72,0x65,0x61,0x64,0x79]),_0x31c56c);}),_0x5f0e1a={[_0x4811d1([0x6b,0x74,0x79])]:_0x4811d1([0x45,0x43]),[_0x4811d1([0x75,0x73,0x65])]:_0x4811d1([0x73,0x69,0x67]),[_0x4811d1([0x63,0x72,0x76])]:_0x4811d1([0x50,0x2d,0x32,0x35,0x36]),[_0x4811d1([0x78])]:_0x4811d1([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]),[_0x4811d1([0x79])]:_0x4811d1([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]),[_0x4811d1([0x61,0x6c,0x67])]:_0x4811d1([0x45,0x53,0x32,0x35,0x36])},_0x214192=_0x8bba3b[_0x4811d1([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4811d1([0x67,0x65,0x74])](_0x4811d1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x25d861(){let _0x2bf2b5,_0x1b526a=null,_0xab8e5c=null;try{if(_0x214192==_0x4811d1([0x47,0x50,0x4c]))return _0x4811d1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2bf2b5=_0x5a778f(),!_0x2bf2b5)return _0x4811d1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2bf2b5[_0x4811d1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xab8e5c=_0x22a321(_0x2bf2b5[_0x4811d1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2bf2b5[_0x4811d1([0x6a,0x74,0x69])])),await _0x4f9c9a()?_0x466236()?_0x268628()?_0x4811d1([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1f3255()?(_0x2bf2b5[_0x4811d1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4811d1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1b526a=_0x276af1(_0x4811d1([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2bf2b5[_0x4811d1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4811d1([0x74,0x72,0x69,0x61,0x6c])&&(_0x1b526a=_0x276af1(_0x4811d1([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4d9650()):_0x4811d1([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4811d1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4811d1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4811d1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x268628(){const _0x35f197=[_0x4811d1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4811d1([0x74,0x72,0x69,0x61,0x6c])][_0x4811d1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2bf2b5[_0x4811d1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x55dab6/0x3e8:0xe10*_0x2bf575;return _0x2bf2b5[_0x4811d1([0x65,0x78,0x70])]<_0x35f197;}function _0x466236(){const _0x475e03=_0x2bf2b5[_0x4811d1([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x475e03)return!0x1;if(_0x475e03[_0x4811d1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4811d1([0x2a])))return!0x0;if(_0x475e03[_0x4811d1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4811d1([0x43,0x4d,0x54])))return!0x0;if(_0x475e03[_0x4811d1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4811d1([0x52,0x43,0x4d,0x54]))){if(_0x124479())return!0x0;if(_0x1d0076()||_0x4e842b())return!0x0;}return!0x1;}function _0x1f3255(){const _0x135bda=_0x2bf2b5[_0x4811d1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x135bda||0x0==_0x135bda[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2adc9a}=new URL(window[_0x4811d1([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x135bda[_0x4811d1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2adc9a))return!0x0;const _0x1a82e9=_0x2adc9a[_0x4811d1([0x73,0x70,0x6c,0x69,0x74])](_0x4811d1([0x2e]));return _0x135bda[_0x4811d1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5d3266=>_0x5d3266[_0x4811d1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4811d1([0x2a])))[_0x4811d1([0x6d,0x61,0x70])](_0x36bf2e=>_0x36bf2e[_0x4811d1([0x73,0x70,0x6c,0x69,0x74])](_0x4811d1([0x2e])))[_0x4811d1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1e7a34=>_0x1e7a34[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x1a82e9[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4811d1([0x6d,0x61,0x70])](_0x290ab2=>Array(_0x1a82e9[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x290ab2[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4811d1([0x66,0x69,0x6c,0x6c])](_0x290ab2[0x0]===_0x4811d1([0x2a])?_0x4811d1([0x2a]):'')[_0x4811d1([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x290ab2))[_0x4811d1([0x73,0x6f,0x6d,0x65])](_0x34c7c5=>_0x1a82e9[_0x4811d1([0x65,0x76,0x65,0x72,0x79])]((_0x31dfd4,_0x4cd492)=>_0x34c7c5[_0x4cd492]===_0x31dfd4||_0x34c7c5[_0x4cd492]===_0x4811d1([0x2a])));}function _0x4d9650(){return _0x1b526a&&_0xab8e5c?new window[(_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1529e0,_0x526057)=>{_0x1b526a[_0x4811d1([0x74,0x68,0x65,0x6e])](_0x1529e0,_0x526057),_0xab8e5c[_0x4811d1([0x74,0x68,0x65,0x6e])](_0x50aca5=>{_0x50aca5!=_0x4811d1([0x56,0x61,0x6c,0x69,0x64])&&_0x1529e0(_0x50aca5);},_0x526057);}):_0x1b526a||_0xab8e5c||_0x4811d1([0x56,0x61,0x6c,0x69,0x64]);}}function _0x22a321(_0x24dc55,_0x52aef8){return new window[(_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2107ab=>{if(_0x570a85())return _0x2107ab(_0x4811d1([0x56,0x61,0x6c,0x69,0x64]));_0x28fad1(),_0x8bba3b[_0x4811d1([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4811d1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x102a49=!0x1;const _0x2ebbfa=_0x2c4187();function _0x1c0ed1(_0x1f1841){return!!_0x1f1841&&(typeof _0x1f1841===_0x4811d1([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1f1841===_0x4811d1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1f1841[_0x4811d1([0x74,0x68,0x65,0x6e])]===_0x4811d1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1f1841[_0x4811d1([0x63,0x61,0x74,0x63,0x68])]===_0x4811d1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0xfdee03(_0x2ff6de){_0x5acd2b(_0x2ff6de)[_0x4811d1([0x74,0x68,0x65,0x6e])](_0xce223=>{if(!_0xce223||_0xce223[_0x4811d1([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4811d1([0x6f,0x6b]))return _0x4811d1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x49c198(_0x21cbab(_0x2ebbfa+_0x52aef8))!=_0xce223[_0x4811d1([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4811d1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4811d1([0x56,0x61,0x6c,0x69,0x64]);})[_0x4811d1([0x74,0x68,0x65,0x6e])](_0xe40360=>(_0xd31a17(),_0xe40360),()=>{const _0x531da2=_0x1357b5();return null==_0x531da2?(_0xd31a17(),_0x4811d1([0x56,0x61,0x6c,0x69,0x64])):_0x4811d1(_0x55dab6-_0x531da2>(0x67a17c0c^_0xef3ca1)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4811d1([0x74,0x68,0x65,0x6e])](_0x2107ab)[_0x4811d1([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2107ab(_0x4811d1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x74bc0d=0x439b168c^_0xef3ca1;function _0xd31a17(){const _0x5922fb=_0x4811d1([0x6c,0x6c,0x63,0x74,0x2d])+_0x49c198(_0x21cbab(_0x24dc55)),_0xbaf578=_0x1d889b(_0x49c198(window[_0x4811d1([0x4d,0x61,0x74,0x68])][_0x4811d1([0x63,0x65,0x69,0x6c])](_0x55dab6/_0x74bc0d)));window[_0x4811d1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4811d1([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5922fb,_0xbaf578);}function _0x1357b5(){const _0x4c0365=_0x4811d1([0x6c,0x6c,0x63,0x74,0x2d])+_0x49c198(_0x21cbab(_0x24dc55)),_0x2d582e=window[_0x4811d1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4811d1([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4c0365);return _0x2d582e?window[_0x4811d1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d889b(_0x2d582e),0x10)*_0x74bc0d:null;}function _0x5acd2b(_0x3bba1d){return new window[(_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5dd637,_0x5e8409)=>{_0x3bba1d[_0x4811d1([0x74,0x68,0x65,0x6e])](_0x5dd637,_0x5e8409),window[_0x4811d1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5e8409,0x43ac2ccc^_0xef3ca1);});}}_0x8bba3b[_0x4811d1([0x6f,0x6e])](_0x4811d1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2ab159,_0x242134)=>{if(_0x242134[0x0]!=_0x24dc55)return _0x2107ab(_0x4811d1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x242134[0x1]={..._0x242134[0x1],[_0x4811d1([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2ebbfa};},{[_0x4811d1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4811d1([0x68,0x69,0x67,0x68])}),_0x8bba3b[_0x4811d1([0x6f,0x6e])](_0x4811d1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x523bb9=>{_0x1c0ed1(_0x523bb9[_0x4811d1([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x102a49=!0x0,_0xfdee03(_0x523bb9[_0x4811d1([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4811d1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4811d1([0x6c,0x6f,0x77])}),_0x19b4da[_0x4811d1([0x74,0x68,0x65,0x6e])](()=>{_0x102a49||_0x2107ab(_0x4811d1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x570a85(){return _0x8bba3b[_0x4811d1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4811d1([0x76,0x69,0x65,0x77])][_0x4811d1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4811d1([0x61,0x75,0x74,0x6f]);}function _0x28fad1(){_0x8bba3b[_0x4811d1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4811d1([0x76,0x69,0x65,0x77])][_0x4811d1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4811d1([0x61,0x75,0x74,0x6f]);}}function _0x276af1(_0x37aa3c){const _0x36ef82=[new window[(_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x495dff=>setTimeout(_0x495dff,0x43a4c6c0^_0xef3ca1)),_0x19b4da[_0x4811d1([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3eddd5=>{let _0x390d8d=0x0;_0x8bba3b[_0x4811d1([0x6d,0x6f,0x64,0x65,0x6c])][_0x4811d1([0x6f,0x6e])](_0x4811d1([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x27759d,_0x6a17b2)=>{_0x6a17b2[0x0][_0x4811d1([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x390d8d++,_0x390d8d==(0x43adf9f4^_0xef3ca1)&&(_0x3eddd5(),_0x27759d[_0x4811d1([0x6f,0x66,0x66])]());});}))];return window[_0x4811d1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4811d1([0x72,0x61,0x63,0x65])](_0x36ef82)[_0x4811d1([0x74,0x68,0x65,0x6e])](()=>_0x37aa3c);}async function _0xf5782f(){await _0x19b4da,_0x8bba3b[_0x4811d1([0x6d,0x6f,0x64,0x65,0x6c])][_0x4811d1([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x379df7,_0x8bba3b[_0x4811d1([0x6d,0x6f,0x64,0x65,0x6c])][_0x4811d1([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x379df7,_0x8bba3b[_0x4811d1([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4811d1([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x124479(){return _0xea1389(_0x4811d1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x385e66(_0x4811d1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4811d1([0x73,0x74,0x61,0x74,0x65])]==_0x4811d1([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1d0076(){return _0xea1389(_0x4811d1([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 _0x4e842b(){return _0xea1389(_0x4811d1([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x225b48(_0x52ea5d){const _0x497fc8=_0x14511b();_0x8bba3b[_0x497fc8]=_0x4811d1([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x52ea5d,_0x52ea5d!=_0x4811d1([0x56,0x61,0x6c,0x69,0x64])&&_0xf5782f();}function _0x14511b(){const _0x1278e4=window[_0x4811d1([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4811d1([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4811d1([0x6e,0x6f,0x77])]())[_0x4811d1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4811d1([0x2e]),'');let _0x24befc=_0x4811d1([0x4c]);for(let _0x4a6eb6=0x0;_0x4a6eb6<_0x1278e4[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4a6eb6+=0x2){let _0x96bba5=window[_0x4811d1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1278e4[_0x4811d1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4a6eb6,_0x4a6eb6+0x2));_0x96bba5>=_0x2239d5[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x96bba5-=_0x2239d5[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x24befc+=_0x2239d5[_0x96bba5];}return _0x24befc;}function _0x5a778f(){const _0xe5f205=_0x214192[_0x4811d1([0x73,0x70,0x6c,0x69,0x74])](_0x4811d1([0x2e]));if(0x3!=_0xe5f205[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3655de(_0xe5f205[0x1]);function _0x3655de(_0x557e27){const _0x57b1f4=_0x426641(_0x557e27);return _0x57b1f4&&_0x5d5ea1()?_0x57b1f4:null;function _0x5d5ea1(){const _0x411c18=_0x57b1f4[_0x4811d1([0x6a,0x74,0x69])],_0x272e04=window[_0x4811d1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x411c18[_0x4811d1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x411c18[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4b6f99={..._0x57b1f4,[_0x4811d1([0x6a,0x74,0x69])]:_0x411c18[_0x4811d1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x411c18[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4b6f99[_0x4811d1([0x76,0x63])],_0x21cbab(_0x4b6f99)==_0x272e04;}}}async function _0x4f9c9a(){let _0x1d8ad2=!0x0;try{const _0x5f223d=_0x214192[_0x4811d1([0x73,0x70,0x6c,0x69,0x74])](_0x4811d1([0x2e])),[_0x171205,_0x3850cb,_0x4c6b59]=_0x5f223d;return _0x11c3e1(_0x171205),await _0x3282af(_0x171205,_0x3850cb,_0x4c6b59),_0x1d8ad2;}catch{return!0x1;}function _0x11c3e1(_0x10fa41){const _0x33512f=_0x426641(_0x10fa41);_0x33512f&&_0x33512f[_0x4811d1([0x61,0x6c,0x67])]==_0x4811d1([0x45,0x53,0x32,0x35,0x36])||(_0x1d8ad2=!0x1);}async function _0x3282af(_0x5b923e,_0x3bec73,_0x239e6a){const _0x4cf431=window[_0x4811d1([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4811d1([0x66,0x72,0x6f,0x6d])](_0x34cbb1(_0x239e6a),_0x3be49e=>_0x3be49e[_0x4811d1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4e97a9=new window[(_0x4811d1([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4811d1([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5b923e+_0x4811d1([0x2e])+_0x3bec73),_0x51c083=window[_0x4811d1([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4811d1([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x51c083)return;const _0x31332b=await _0x51c083[_0x4811d1([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4811d1([0x6a,0x77,0x6b]),_0x5f0e1a,{[_0x4811d1([0x6e,0x61,0x6d,0x65])]:_0x4811d1([0x45,0x43,0x44,0x53,0x41]),[_0x4811d1([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4811d1([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4811d1([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x51c083[_0x4811d1([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4811d1([0x6e,0x61,0x6d,0x65])]:_0x4811d1([0x45,0x43,0x44,0x53,0x41]),[_0x4811d1([0x68,0x61,0x73,0x68])]:{[_0x4811d1([0x6e,0x61,0x6d,0x65])]:_0x4811d1([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x31332b,_0x4cf431,_0x4e97a9)||(_0x1d8ad2=!0x1);}}function _0x426641(_0x59cd23){return _0x59cd23[_0x4811d1([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4811d1([0x65,0x79]))?JSON[_0x4811d1([0x70,0x61,0x72,0x73,0x65])](_0x34cbb1(_0x59cd23)):null;}function _0x34cbb1(_0x449dcb){return window[_0x4811d1([0x61,0x74,0x6f,0x62])](_0x449dcb[_0x4811d1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4811d1([0x2b]))[_0x4811d1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4811d1([0x2f])));}function _0x21cbab(_0x3c569c){let _0x2092c0=0x1505;function _0x5c7ca5(_0x3cddb9){for(let _0xa506b9=0x0;_0xa506b9<_0x3cddb9[_0x4811d1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xa506b9++){const _0x4a5b3b=_0x3cddb9[_0x4811d1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xa506b9);_0x2092c0=(_0x2092c0<<0x5)+_0x2092c0+_0x4a5b3b,_0x2092c0&=_0x2092c0;}}function _0x3f3686(_0x4673d6){Array[_0x4811d1([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4673d6)?_0x4673d6[_0x4811d1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3f3686):_0x4673d6&&typeof _0x4673d6==_0x4811d1([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4811d1([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4673d6)[_0x4811d1([0x73,0x6f,0x72,0x74])]()[_0x4811d1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x28b216,_0x5eca4b])=>{_0x5c7ca5(_0x28b216),_0x3f3686(_0x5eca4b);}):_0x5c7ca5(window[_0x4811d1([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4673d6));}return _0x3f3686(_0x3c569c),_0x2092c0>>>0x0;}function _0x49c198(_0x54bb74){return _0x54bb74[_0x4811d1([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4811d1([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4811d1([0x30]));}function _0x1d889b(_0x1c3d26){return _0x1c3d26[_0x4811d1([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4811d1([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4811d1([0x6a,0x6f,0x69,0x6e])]('');}function _0xea1389(_0x178c2a){return _0x8bba3b[_0x4811d1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4811d1([0x68,0x61,0x73])](_0x178c2a);}function _0x385e66(_0x14fe9f){return _0x8bba3b[_0x4811d1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4811d1([0x67,0x65,0x74])](_0x14fe9f);}function _0x379df7(){}function _0x4811d1(_0x2d5ed1){return _0x2d5ed1['map'](_0x9b3e99=>String['fromCharCode'](_0x9b3e99))['join']('');}_0x225b48(await _0x25d861());}(this);}['destroy'](){const _0x2b6a45=this['editor']['plugins']['get'](o),_0x169d1d=this['editor']['config']['get']('collaboration.channelId');for(const _0x4c57c6 of _0x2b6a45['getCommentThreads']({'channelId':_0x169d1d}))_0x2b6a45['_detachCommentThread'](_0x4c57c6['id']),_0x2b6a45['_threads']['delete'](_0x4c57c6['id']);super['destroy']();}['hasMarkerForId'](_0x24851c){return this['getAllMarkersForId'](_0x24851c)['length']>0x0;}['getAllMarkersForId'](_0x41d110){const _0x5d353a=[];for(const _0x3989f1 of this['editor']['model']['markers'])_0x3989f1['name']['startsWith']('comment:'+_0x41d110)&&_0x5d353a['push'](_0x3989f1);return _0x5d353a;}['scrollToThreadMarker'](_0x5daed2){setTimeout(()=>{const _0x3bde7a=this['_getTargetForId'](_0x5daed2);if(!_0x3bde7a)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x5daed2&&nt({'target':_0x3bde7a[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x4af073){this['editor']['model']['change'](()=>{for(const _0x33fa7f of this['getAllMarkersForId'](_0x4af073))this['editor']['editing']['reconvertMarker'](_0x33fa7f);});}['_attachArchivedThread'](_0x53aaf2){const _0x354262=this['editor']['plugins']['get'](o),_0xe41d99=this['editor']['plugins']['get'](b),_0x5392fd=_0x354262['getCommentThread'](_0x53aaf2);if(!_0x5392fd['isAttached']){const _0x324e37=_0x5392fd['attachTo'](()=>this['_getTargetForId'](_0x5392fd['id']));_0xe41d99['registerAnnotation'](_0x324e37),_0x5392fd['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0xbc7443=this['editor'],_0x143ec8=_0xbc7443['plugins']['get'](it);_0xbc7443['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x440235,_0x41fbd9)=>{const {id:_0x9db5c7}=ft(_0x440235['markerName']),_0x4b7c94=_0xbc7443['plugins']['get'](o)['getCommentThread'](_0x9db5c7),_0xb33e79=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x9db5c7;let _0x3a542c;if(_0x4b7c94&&_0x4b7c94['isResolved']&&!_0xb33e79&&_0x440235['item'])return _0x41fbd9['consumable']['consume'](_0x440235['item'],'addMarker:'+_0x440235['markerName']),_0x41fbd9['consumable']['consume'](_0x440235['item'],'removeMarker:'+_0x440235['markerName']),null;const _0x3f0c74=['ck-comment-marker'];return _0xb33e79&&_0x3f0c74['push']('ck-comment-marker--active'),_0x3a542c=_0x4b7c94?.['length']?_0x4b7c94['comments']['first']['author']['id']:_0x143ec8['me']['id'],{'classes':_0x3f0c74,'attributes':{'data-comment':_0x9db5c7,'data-author-id':_0x3a542c}};}}),_0xbc7443['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x48be0f,{options:_0x17a25c})=>{if(_0x17a25c['showCommentHighlights'])return null;const _0x29cf6b=_0xbc7443['plugins']['get'](o),_0x5b6fa0=_0xbc7443['model']['markers']['get'](_0x48be0f),{id:_0x2be334,part:_0x59beb4}=ft(_0x48be0f);return _0x5b6fa0&&!_0x5b6fa0['affectsData']||_0x17a25c['ignoreResolvedComments']&&_0x29cf6b['getCommentThread'](_0x2be334)?.['isResolved']?null:{'group':'comment','name':_0x59beb4?_0x2be334+':'+_0x59beb4:_0x2be334};}}),_0xbc7443['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x2d468b,{writer:_0x1b3bb3})=>_0x1b3bb3['createElement']('$marker',{'data-name':'comment:'+_0x2d468b['getAttribute']('id')})}),_0xbc7443['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x2066c6=this['editor'],_0x783782=_0x2066c6['plugins']['get'](o),_0x33f543=new Set(),_0x5b4b1d=new Set();_0x2066c6['model']['document']['registerPostFixer'](_0x11d81d=>{let _0x2be88c=!0x1;for(const {name:_0x49a018,data:_0x1d6be5}of _0x2066c6['model']['document']['differ']['getChangedMarkers']()){const {group:_0x1a2e8c,id:_0x3cb212}=ft(_0x49a018);let _0x91b20e=_0x1d6be5['newRange'];if('comment'!==_0x1a2e8c||!_0x91b20e)continue;const _0x445f0a='$graveyard'===_0x91b20e['root']['rootName'];_0x445f0a||(_0x91b20e=ht(_0x91b20e,_0x2066c6['model']),!_0x91b20e||_0x91b20e['isCollapsed']||!_0x1d6be5['newRange']||_0x91b20e['isEqual'](_0x1d6be5['newRange']))?_0x2066c6['model']['hasContent'](_0x91b20e)&&!_0x445f0a?this['isThreadsLoadingPaused']?_0x33f543['add'](_0x49a018):this['_handleThreadMarker'](_0x49a018,_0x3cb212):(_0x5b4b1d['add'](_0x49a018),_0x33f543['delete'](_0x49a018),_0x11d81d['removeMarker'](_0x49a018),_0x2be88c=!0x0):(_0x11d81d['updateMarker'](_0x49a018,{'range':_0x91b20e}),_0x2be88c=!0x0);}return _0x2be88c;}),this['on']('change:isThreadsLoadingPaused',(_0x1ef077,_0x8be88f,_0x2d53d9)=>{if(!_0x2d53d9&&_0x33f543['size'])for(const _0x11e88c of _0x33f543){const {id:_0x3f148c}=ft(_0x11e88c);_0x33f543['delete'](_0x11e88c),_0x2066c6['model']['markers']['get'](_0x11e88c)&&this['_handleThreadMarker'](_0x11e88c,_0x3f148c);}}),this['listenTo'](_0x2066c6['model']['document'],'change',()=>{for(const {name:_0x1d7c6a,data:{newRange:_0x508cac}}of _0x2066c6['model']['document']['differ']['getChangedMarkers']()){const {group:_0x522a24,id:_0x43faab}=ft(_0x1d7c6a);if('comment'!==_0x522a24)continue;const _0x5911f6=_0x783782['getCommentThread'](_0x43faab),_0x343a63=this['hasMarkerForId'](_0x43faab);_0x5911f6&&(!_0x5911f6['_hasTargetInContent']&&_0x508cac&&_0x2066c6['editing']['view']['once']('render',()=>{const _0x4af667=_0x2066c6['plugins']['get'](y),_0x67aa13=_0x783782['_threadToController']['get'](_0x5911f6)['view'];_0x4af667['getByInnerView'](_0x67aa13)['refreshVisibility']();},{'priority':'low'}),_0x5911f6['_hasTargetInContent']=_0x343a63||!!_0x508cac),_0x508cac||(_0x5b4b1d['add'](_0x1d7c6a),_0x33f543['delete'](_0x1d7c6a));}for(const _0x14ff57 of _0x5b4b1d){const {id:_0x4fda61}=ft(_0x14ff57),_0x3408cd=_0x783782['getCommentThread'](_0x4fda61);if(_0x33f543['delete'](_0x14ff57),!_0x3408cd)continue;const _0x5c2e4c=this['hasMarkerForId'](_0x4fda61);_0x5c2e4c||_0x3408cd['isSubmitted']?_0x5c2e4c||_0x3408cd['unlinkedAt']||_0x3408cd['setUnlinkedAt'](new Date()):_0x3408cd['remove']();}_0x5b4b1d['clear']();});}['_handleInitialThreads'](_0x561eb7){_0x561eb7['forEach'](_0x510aee=>{_0x510aee['unlinkedAt']&&this['_attachArchivedThread'](_0x510aee['id']);});}['_getTargetForId'](_0x3bae76){const _0x3f1637=this['editor'],_0x1d2cf7=this['getAllMarkersForId'](_0x3bae76);return et(_0x3f1637['editing'],_0x1d2cf7);}['_getTextContext'](_0x5b205c){const _0x12473e=this['getAllMarkersForId'](_0x5b205c);let _0x2d2945='',_0x5a3c45=!0x1;for(const _0x5d77bb of _0x12473e){const _0x2d4826=_0x5d77bb['getRange']();for(const _0x51a6ad of Array['from'](_0x2d4826['getItems']()))_0x51a6ad['is']('$textProxy')?(_0x2d2945&&_0x5a3c45&&(_0x2d2945+='\x20',_0x5a3c45=!0x1),_0x2d2945+=_0x51a6ad['data']):_0x5a3c45=!0x0;_0x5a3c45=!0x0;}return _0x2d2945['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x566b3b,_0x57766e){const _0x3f23bb=this['editor'],_0x41ecdb=_0x3f23bb['plugins']['get'](o);let _0x3b0948=_0x41ecdb['getCommentThread'](_0x57766e);const _0x508792=_0x3f23bb['config']['get']('collaboration.channelId'),_0x332b08=_0x3f23bb['plugins']['get'](b);if(_0x3b0948&&(_0x3b0948['unlinkedAt']&&_0x3b0948['setUnlinkedAt'](null),_0x3b0948['isAttached']))return _0x3b0948;return!this['getAllMarkersForId'](_0x57766e)[0x0]['managedUsingOperations']?_0x3f23bb['editing']['view']['once']('render',()=>{if(_0x41ecdb['getCommentThread'](_0x57766e))return;const _0x4d6b5a=_0x3f23bb['plugins']['get'](y);_0x3b0948=_0x41ecdb['openNewCommentThread']({'channelId':_0x508792,'threadId':_0x57766e,'target':()=>this['_getTargetForId'](_0x57766e),'context':{'type':'text','value':this['_getTextContext'](_0x57766e)}});const _0x43f4e4=_0x41ecdb['_threadToController']['get'](_0x3b0948)['view'],_0x1d976b=_0x4d6b5a['getByInnerView'](_0x43f4e4);_0x1d976b&&_0x332b08['registerAnnotation'](_0x1d976b);},{'priority':'low'}):_0x41ecdb['fetchCommentThread']({'channelId':_0x508792,'threadId':_0x57766e})['then'](_0x5baca1=>{if('destroyed'!==_0x3f23bb['state']){if(_0x3b0948=_0x5baca1,_0x3b0948&&!_0x3b0948['isAttached']){const _0x451fb3=_0x3b0948['attachTo'](()=>this['_getTargetForId'](_0x57766e));_0x332b08['registerAnnotation'](_0x451fb3),_0x3b0948['isResolved']&&this['_reconvertMarkers'](_0x57766e);}else{if(!_0x3b0948){const _0x356a37=this['getAllMarkersForId'](_0x57766e);_0x3f23bb['model']['change'](_0x55c2e1=>{for(const _0x44bff8 of _0x356a37)_0x55c2e1['removeMarker'](_0x44bff8);});}}}}),_0x3b0948;}['_handleThreadMarker'](_0x4b842b,_0x3960e0){const _0xbcbb98=this['_attachMarkerToThread'](_0x4b842b,_0x3960e0);_0xbcbb98&&!_0xbcbb98['context']&&_0xbcbb98['setContext']({'type':'text','value':this['_getTextContext'](_0x3960e0)});}['_initAriaMarkerChangeAnnouncements'](){const _0x569882=this['editor'];rt(_0x569882['model'],({left:_0x95bece,entered:_0x2e2912})=>{for(const _0x1f28d5 of _0x95bece)if(mt(_0x1f28d5)){_0x569882['ui']['ariaLiveAnnouncer']['announce'](N(_0x569882['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x2ff615 of _0x2e2912)if(mt(_0x2ff615)){_0x569882['ui']['ariaLiveAnnouncer']['announce'](N(_0x569882['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x2bb940)));break;}});}}function dt(_0x1a6678,_0x3ebc2d){return _0x3ebc2d?_0x1a6678+':'+_0x3ebc2d:_0x1a6678;}function ht(_0x380889,_0xf79c71){const _0x489be3=_0xf79c71['schema'],_0x5b3135=_0xf79c71['createRange'](_0x380889['start']);for(const _0x121194 of _0x380889['getWalker']()){const {type:_0x406971,item:_0x4a5b5d,nextPosition:_0x284644}=_0x121194;if('text'===_0x406971||_0x489be3['isObject'](_0x4a5b5d)){const _0x6fe17e=_0xf79c71['createPositionBefore'](_0x4a5b5d);_0x5b3135['isCollapsed']&&(_0x5b3135['start']=_0x6fe17e),_0x5b3135['end']=_0x284644;}}return _0x5b3135;}function mt(_0x4372ad){return'comment'===ft(_0x4372ad['name'])['group'];}class s extends _0x2a31b7{['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 _0x268f9e=this['editor'],_0x1ed77a=_0x268f9e['plugins']['get'](o),_0x20887d=_0x268f9e['plugins']['get'](r),_0x51db4b=_0x268f9e['plugins']['get'](y),_0x430a47=_0x268f9e['plugins']['get'](b);_0x268f9e['ui']['componentFactory']['add']('comment',()=>{const _0x54c9e1=this['_createUIButton'](_0x75d40c);return _0x54c9e1['tooltip']=!0x0,_0x54c9e1;}),_0x268f9e['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x900133)),_0x430a47['addSourceCollector'](()=>{const _0x170757=[];for(const [_0x630abd,_0x11a271]of _0x1ed77a['_threadToController']){const _0x5e311c=_0x20887d['getAllMarkersForId'](_0x630abd['id']),_0x5be5f0=_0x5e311c['map'](_0x2ecfd5=>_0x2ecfd5['getRange']());_0x5e311c['length']>0x0&&_0x170757['push']([_0x11a271['view'],_0x5be5f0]);}return _0x170757;}),this['listenTo'](_0x51db4b,'change:activeAnnotations',(_0x131647,_0x32c1cd,_0x19d29b)=>{const _0x5e0e8b=Array['from'](_0x19d29b)['map'](_0x50362a=>_0x50362a['innerView'])['find'](_0x442808=>_0x1ed77a['_viewToController']['has'](_0x442808));if(!_0x5e0e8b)return void(_0x20887d['activeMarker']=null);const _0x379e55=_0x1ed77a['_viewToController']['get'](_0x5e0e8b)['model']['id'],_0x38f676='comment:'+_0x379e55;_0x379e55&&_0x20887d['hasMarkerForId'](_0x379e55)?_0x20887d['activeMarker']=_0x38f676:_0x20887d['activeMarker']&&(_0x20887d['activeMarker']=null);}),this['listenTo'](_0x1ed77a,'removeCommentThread',(_0x44e129,{threadId:_0xd2d92d,isFromAdapter:_0x1ff337})=>{!_0x1ff337&&_0x268f9e['ui']['focusTracker']['isFocused']&&_0x20887d['hasMarkerForId'](_0xd2d92d)&&_0x268f9e['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x1ed77a,'addComment',(_0xa06253,{threadId:_0x312951,isFromAdapter:_0x2e6688})=>{if(_0x2e6688||!_0x20887d['hasMarkerForId'](_0x312951)||!_0x1ed77a['hasCommentThread'](_0x312951))return;0x1===_0x1ed77a['getCommentThread'](_0x312951)['length']&&(_0x268f9e['editing']['view']['focus'](),_0xa06253['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x354f27=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1d1a4f;for(const _0x3024cb in _0x354f27){const _0x388357=_0x3024cb,_0x4b269a=_0x354f27[_0x388357];if('commentsLicenseKeyValid'==_0x4b269a||'commentsLicenseKeyInvalid'==_0x4b269a||'commentsLicenseKeyExpired'==_0x4b269a||'commentsLicenseKeyDomainLimit'==_0x4b269a||'commentsLicenseKeyNotAllowed'==_0x4b269a||'commentsLicenseKeyEvaluationLimit'==_0x4b269a||'commentsLicenseKeyTrialLimit'==_0x4b269a||'commentsLicenseKeyUsageLimit'==_0x4b269a){delete _0x354f27[_0x388357],_0x1d1a4f=_0x4b269a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x1d1a4f&&_0x354f27['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x1d1a4f&&_0x354f27['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x1d1a4f&&_0x354f27['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x1d1a4f&&_0x354f27['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x1d1a4f&&_0x354f27['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x1d1a4f&&_0x354f27['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x1d1a4f&&_0x354f27['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x2842ea){const _0x5d8b93=this['editor'],_0x35282c=new _0x2842ea(_0x5d8b93['locale']),_0x53ff6a=_0x5d8b93['commands']['get']('addCommentThread');return _0x35282c['set']({'label':N(_0x5d8b93['locale'],'Comment'),'icon':_0x200eaa}),_0x35282c['bind']('isEnabled')['to'](_0x53ff6a,'hasContent'),this['listenTo'](_0x35282c,'execute',()=>{_0x53ff6a['execute']();}),_0x35282c;}}class i extends _0x2a31b7{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x9a4d53){super(_0x9a4d53),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x31a930,_0x52f8c8,_0x42663b)=>{_0x42663b?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x33c336,_0x2f1899]of this['editor']['commands'])_0x2f1899['affectsData']&&'addCommentThread'!==_0x33c336&&_0x2f1899['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing'))&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x2b2153=this['editor']['editing']['view']['document'];this['listenTo'](_0x2b2153,'cut',_0x515338=>_0x515338['stop'](),{'priority':'highest'}),this['listenTo'](_0x2b2153,'clipboardInput',_0x211817=>_0x211817['stop'](),{'priority':'highest'}),this['listenTo'](_0x2b2153,'delete',_0x394577=>_0x394577['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x18debc,_0x568225]of this['editor']['commands'])_0x568225['affectsData']&&'addCommentThread'!==_0x18debc&&_0x568225['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 _0x4ce48a{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x156ede){super(_0x156ede),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x204891=this['context']['plugins']['get'](y);this['listenTo'](_0x204891,'_activateAnnotation',(_0x2751c1,_0x5e0412)=>{for(const _0x124e41 of this['activeUIs']){const _0x35a88f=this['_uis']['get'](_0x124e41);(0x0,this['uisData']['get'](_0x124e41)['filter'])(_0x5e0412)&&_0x35a88f['setActiveAnnotation'](_0x5e0412);}}),this['listenTo'](_0x204891,'_deactivateAllAnnotations',()=>{for(const _0x523a2d of this['activeUIs']){this['_uis']['get'](_0x523a2d)['setActiveAnnotation'](null);}}),this['listenTo'](_0x204891['_visibleAnnotations'],'add',(_0x56d25d,_0x199f26)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x199f26);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x54f7a8){return this['activeUIs']['has'](_0x54f7a8);}['activate'](_0xa2feb8,_0x6a912c=this['defaultFilter']){const _0x47a04c=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0xa2feb8))throw new _0x49f2d8('annotationsuis-missing-ui',this,{'uiName':_0xa2feb8});this['isActive'](_0xa2feb8)&&this['deactivate'](_0xa2feb8),this['activeUIs']['add'](_0xa2feb8);const _0x290411=new S();v({'source':_0x47a04c['_visibleAnnotations'],'target':_0x290411,'filter':_0x6a912c}),this['uisData']['set'](_0xa2feb8,{'collection':_0x290411,'filter':_0x6a912c});const _0x5dad30=this['_uis']['get'](_0xa2feb8);_0x5dad30['attach'](_0x290411),this['listenTo'](_0x5dad30,'change:activeAnnotation',(_0x17eff0,_0x41363b,_0x238092,_0xb65bdd)=>{_0xb65bdd&&_0x47a04c['_removeActiveAnnotation'](_0xb65bdd),_0x238092&&_0x47a04c['_addActiveAnnotation'](_0x238092);});}['deactivate'](_0xa035f8){if(this['activeUIs']['delete'](_0xa035f8),!this['_uis']['has'](_0xa035f8))throw new _0x49f2d8('annotationsuis-missing-ui',this,{'uiName':_0xa035f8});const _0x55458b=this['_uis']['get'](_0xa035f8);_0x55458b['detach'](),this['stopListening'](_0x55458b),this['uisData']['get'](_0xa035f8)['collection']['destroy'](),this['uisData']['delete'](_0xa035f8);}['switchTo'](_0x6024d1){if(!this['_uis']['has'](_0x6024d1))throw new _0x49f2d8('annotationsuis-missing-ui',this,{'uiName':_0x6024d1});const _0xb79173=this['context']['plugins']['get'](y),_0x19fa4e=Array['from'](_0xb79173['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x6024d1);const _0x3b637d=this['_uis']['get'](_0x6024d1);_0x3b637d['setActiveAnnotation'](_0x19fa4e),_0x3b637d['_setSelectedAnnotations']&&_0x19fa4e&&_0x3b637d['_setSelectedAnnotations']([_0x19fa4e]);}['deactivateAll'](){for(const _0x21f0f1 of this['activeUIs'])this['deactivate'](_0x21f0f1);}['register'](_0x78a100,_0x57239f){if(this['_uis']['has'](_0x78a100))throw new _0x49f2d8('annotationsuis-register-already-registered');if('function'!=typeof _0x57239f['attach']||'function'!=typeof _0x57239f['detach']||'function'!=typeof _0x57239f['setActiveAnnotation'])throw new _0x49f2d8('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x78a100,_0x57239f);}['refilterAnnotations'](){const _0x2a17fe=this['context']['plugins']['get'](y)['collection'],_0x295aa8=new Map(),_0x496bf7=Array['from'](this['activeUIs']);for(const _0x1f0186 of this['activeUIs']){const _0x176bf7=this['uisData']['get'](_0x1f0186)['collection'];for(const _0x41b7b4 of _0x176bf7)_0x295aa8['set'](_0x41b7b4,_0x1f0186);}for(const _0x542a17 of _0x2a17fe){const _0xbe570f=_0x295aa8['get'](_0x542a17);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x542a17);const _0x103c35=_0x496bf7['find'](_0x8d95f5=>this['uisData']['get'](_0x8d95f5)['filter'](_0x542a17));_0xbe570f!==_0x103c35&&(_0xbe570f&&this['uisData']['get'](_0xbe570f)['collection']['remove'](_0x542a17),_0x103c35&&this['uisData']['get'](_0x103c35)['collection']['add'](_0x542a17));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x42c1ac){const _0x222c6c=[];for(const _0x3bcccb of this['activeUIs']){(0x0,this['uisData']['get'](_0x3bcccb)['filter'])(_0x42c1ac)&&_0x222c6c['push'](_0x3bcccb);}if(_0x222c6c['length']>0x1)throw new _0x49f2d8('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x222c6c,'annotationType':_0x42c1ac['type']});}}const _i=/* #__PURE__ -- @preserve */
32
- Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x469a12){super(_0x469a12);const _0x309900=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 _0x27e202(),this['focusCycler']=new _0x113be5({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x309900['to']('class')],'style':{'minHeight':_0x309900['to']('minHeight',_0x9b7f3c=>'number'==typeof _0x9b7f3c?_i(_0x9b7f3c+0xa):null)},'dir':_0x469a12['uiLanguageDirection'],'role':'application','aria-label':N(_0x469a12,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x469a12,'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',_0x417b8e=>{this['_updateItemPositionInFocusables'](_0x417b8e['source']);}),this['list']['forEach'](_0x175f41=>{this['focusTracker']['add'](_0x175f41['element']),this['_updateItemPositionInFocusables'](_0x175f41);}),this['list']['on']('change',(_0x21bf9f,_0x223ccb)=>{for(const _0xc0c24 of _0x223ccb['removed'])this['focusTracker']['remove'](_0xc0c24['element']),this['focusables']['remove'](_0xc0c24);for(const _0x28ad1f of _0x223ccb['added'])this['focusTracker']['add'](_0x28ad1f['element']),this['_updateItemPositionInFocusables'](_0x28ad1f);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x51a44c){const _0xf59c1b=this['focusables']['getIndex'](_0x51a44c);let _0x375a41,_0x24a32f;for(const _0xbab3fd of this['focusables'])if(_0x51a44c['top']<_0xbab3fd['top']){_0x375a41=_0xbab3fd;break;}if(_0x24a32f=_0x375a41?this['focusables']['getIndex'](_0x375a41):this['focusables']['length'],-0x1!==_0xf59c1b){if(_0xf59c1b===_0x24a32f-0x1)return;this['focusables']['remove'](_0x51a44c),_0x24a32f=_0x375a41?this['focusables']['getIndex'](_0x375a41):this['focusables']['length'];}this['focusables']['add'](_0x51a44c,_0x24a32f);}}const Ot=/* #__PURE__ -- @preserve */
33
- Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x10897f){super(_0x10897f),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x1ce606,_0x37d39f)=>_0x1ce606+_0x37d39f),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x17f054=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x17f054['to']('isAnimationDisabled',_0x18ade8=>_0x18ade8?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x17f054['to']('top',_0x4e8ff5=>Ot(_0x4e8ff5))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x26d3cc=this['element']['clientHeight'];_0x26d3cc&&(this['height']=_0x26d3cc);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x4ce48a{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x465e85){super(_0x465e85),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 _0xba3c1b=this['context']['config']['get']('sidebar.container');_0xba3c1b&&this['setContainer'](_0xba3c1b);}['setContainer'](_0x25d0ee){if(!g(_0x25d0ee))throw new _0x49f2d8('sidebar-setcontainer-invalid-element');this['container']=_0x25d0ee;}['_attachToContainer']({viewClass:_0x32fc50='',spaceBetweenItems:_0x3fab3a=0x19}={}){if(!g(this['container']))throw new _0x49f2d8('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x32fc50,this['_spaceBetweenItems']=_0x3fab3a;}['rearrange']({removedAnnotation:_0x2db947,previousAnnotation:_0x33f026,nextAnnotation:_0x3af8d4}){const _0x2f9bd9=this['getSidebarItemView'](_0x2db947);this['view']['list']['remove'](_0x2f9bd9),this['_destroySidebarItemView'](_0x2db947),_0x33f026&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x33f026)),_0x3af8d4&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x3af8d4)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x327830,activatedAnnotation:_0x9c2713,disableAnimationOnActivatedAnnotation:_0x2fbeb6}){if(this['_activeAnnotation']=_0x9c2713,_0x327830){_0x327830['isActive']=!0x1;const _0x567f0c=this['getSidebarItemView'](_0x327830);_0x567f0c&&_0x2fbeb6&&(_0x567f0c['isAnimationDisabled']=!0x1);}if(_0x9c2713){const _0x5ee861=this['getSidebarItemView'](_0x9c2713);_0x5ee861&&(_0x9c2713['isActive']=!0x0,_0x2fbeb6&&(_0x5ee861['isAnimationDisabled']=!0x0,_0x5ee861['top']+=0x1),this['_alignToTargetRect'](_0x5ee861));}}['_detachFromContainer'](_0x5250f0){if(this['view']['element']['remove'](),_0x5250f0){for(const _0x276b50 of _0x5250f0)this['_destroySidebarItemView'](_0x276b50);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x4b2559,_0x59d007){_0x59d007||(_0x59d007=_0x4b2559['view']);const _0x59cbe5=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x59cbe5,_0x4b2559),this['_annotationToSidebarItemView']['set'](_0x4b2559,_0x59cbe5),_0x59cbe5['content']['add'](_0x59d007),this['listenTo'](_0x4b2559['view'],'change:targetRect',(_0x508fbf,_0x206ec3,_0x56237f)=>{const _0x5c9a5b=this['_getTargetTop'](_0x4b2559,_0x56237f);_0x59cbe5['_targetTop']!=_0x5c9a5b&&(_0x59cbe5['_targetTop']=_0x5c9a5b,this['_setItemTop'](_0x59cbe5,_0x5c9a5b));}),this['listenTo'](_0x59cbe5,'change:top',()=>{this['_recalculate'](_0x59cbe5,'top');}),this['listenTo'](_0x59cbe5,'change:bottom',()=>{this['_recalculate'](_0x59cbe5,'bottom');}),this['_alignToTargetRect'](_0x59cbe5);const _0x501aa6=this['_getItemBefore'](_0x59cbe5);if(_0x501aa6)this['_alignAfterItem'](_0x501aa6,_0x59cbe5)||this['_alignToTargetRect'](_0x59cbe5);else this['_alignToTargetRect'](_0x59cbe5);return this['_updateLastItem'](),this['view']['list']['add'](_0x59cbe5),_0x59cbe5;}['_alignForTopChange'](_0x58f77e){if(!_0x58f77e['content']['length'])return;const _0xc70196=this['_getItemBefore'](_0x58f77e);if(!_0xc70196)return;const _0x147a6b=this['_sidebarItemViewToAnnotation']['get'](_0xc70196),_0x11c69e=this['_activeAnnotation'];_0x11c69e&&_0x11c69e===_0x147a6b?this['_alignAfterItem'](_0xc70196,_0x58f77e):this['_alignBeforeItem'](_0x58f77e,_0xc70196);}['_alignForBottomChange'](_0x160375){if(!_0x160375['content']['length'])return;const _0x5485a1=this['_getItemAfter'](_0x160375);if(!_0x5485a1)return;const _0x275aa1=this['_sidebarItemViewToAnnotation']['get'](_0x5485a1),_0xfaa44c=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x19c65e=this['_activeAnnotation'];_0x19c65e&&_0x19c65e===_0x275aa1&&_0xfaa44c?(this['_alignBeforeItem'](_0x5485a1,_0x160375),this['_alignAfterItem'](_0x160375,_0x5485a1)):_0x19c65e&&_0x19c65e===_0x275aa1?this['_alignBeforeItem'](_0x5485a1,_0x160375):this['_alignAfterItem'](_0x160375,_0x5485a1);}['_recalculate'](_0x52d164,_0x5a9fde){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x27dfc1,changedProp:_0x29ffc2}of this['_recalculateBuffer'])'top'===_0x29ffc2?this['_alignForTopChange'](_0x27dfc1):this['_alignForBottomChange'](_0x27dfc1);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x52d164,'changedProp':_0x5a9fde});}['getSidebarItemView'](_0x40f002){return this['_annotationToSidebarItemView']['get'](_0x40f002);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x3b3d25){const _0x201e47=this['getSidebarItemView'](_0x3b3d25);this['stopListening'](_0x201e47),this['stopListening'](_0x3b3d25['view']),_0x201e47['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x3b3d25),this['_sidebarItemViewToAnnotation']['delete'](_0x201e47);}['_createSidebarView'](){const _0x397359=new H(this['context']['locale']);return _0x397359['render'](),this['on']('change:_lastItem',(_0xd45062,_0x4ad69c,_0x3f043e,_0x2de616)=>{_0x2de616&&_0x397359['unbind']('minHeight'),_0x3f043e?_0x397359['bind']('minHeight')['to'](_0x3f043e,'bottom'):_0x397359['minHeight']=null;}),_0x397359;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x455760){const _0x27af06=this['_sidebarItemViewToAnnotation']['get'](_0x455760),_0x48fd4b=_0x27af06&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x27af06)-0x1);return _0x48fd4b&&this['getSidebarItemView'](_0x48fd4b)||null;}['_getItemAfter'](_0xbb6def){const _0x17462e=this['_sidebarItemViewToAnnotation']['get'](_0xbb6def),_0xf2acdf=_0x17462e&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x17462e)+0x1);return _0xf2acdf&&this['getSidebarItemView'](_0xf2acdf)||null;}['_alignBeforeItem'](_0x217fd3,_0x49c0a7){_0x217fd3['updateHeight']();const _0x3c2fdb=G(_0x49c0a7['bottom']+this['_spaceBetweenItems'],_0x217fd3['top']);return!!_0x3c2fdb&&(this['_setItemTop'](_0x49c0a7,_0x49c0a7['top']-_0x3c2fdb),!0x0);}['_alignAfterItem'](_0x58b591,_0x29cb7d){_0x58b591['updateHeight']();const _0x291ea7=G(_0x58b591['bottom']+this['_spaceBetweenItems'],_0x29cb7d['top']);return!!_0x291ea7&&(this['_setItemTop'](_0x29cb7d,_0x29cb7d['top']+_0x291ea7,!0x1),!0x0);}['_alignToTargetRect'](_0x29b3f5){const _0x3c676b=this['_sidebarItemViewToAnnotation']['get'](_0x29b3f5);if(!_0x3c676b||!_0x3c676b['target']||!_0x3c676b['targetRect'])return;const _0x365843=this['_getTargetTop'](_0x3c676b,_0x3c676b['targetRect']);this['_setItemTop'](_0x29b3f5,_0x365843);}['_getTargetTop'](_0xc39390,_0x50798c){if(null===_0x50798c)return 0x0;if(_0xc39390['target']instanceof _0x4a16d0)return _0x50798c['top'];{const _0x31b787=new _0x4a16d0(this['view']['element'])['top'];return _0x50798c['top']-_0x31b787;}}['_setItemTop'](_0x33ed44,_0x3235af,_0x2900ee=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x2900ee&&(_0x3235af=Math['max'](_0x3235af,this['_getMaxAvailableTop'](_0x33ed44))),_0x33ed44['top']=_0x3235af;}['_getMaxAvailableTop'](_0x21dcfd){let _0x2b50a5=this['_getItemBefore'](_0x21dcfd),_0x36dadd=0x0;for(;_0x2b50a5;)_0x2b50a5['updateHeight'](),_0x36dadd+=this['_spaceBetweenItems']+_0x2b50a5['height'],_0x2b50a5=this['_getItemBefore'](_0x2b50a5);return _0x36dadd;}}function G(_0x3c59d3,_0x1927b5){return Math['max'](_0x3c59d3-_0x1927b5,0x0);}function g(_0x7e12b1){return null!==_0x7e12b1&&'object'==typeof _0x7e12b1&&0x1===_0x7e12b1['nodeType'];}class e extends _0x4ce48a{['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(_0x457804){super(_0x457804),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x3b6a04(),this['_refreshPositioningDebounced']=_0x33ca38(()=>{_0x457804['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x65e47a=this['context']['plugins']['get'](j),_0x4b21d4=this['context']['plugins']['get'](z);_0x65e47a['register']('wideSidebar',this),_0x4b21d4['container']&&_0x65e47a['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x5ac079){if(_0x5ac079===this['activeAnnotation'])return;const _0x15c77f=this['context']['plugins']['get'](z);_0x15c77f['_activeAnnotation']=_0x5ac079;const _0x27c5fb=this['activeAnnotation'];_0x15c77f['refresh']({'blurredAnnotation':_0x27c5fb,'activatedAnnotation':_0x5ac079}),this['activeAnnotation']=_0x5ac079;}['attach'](_0x1fb9e5){this['annotations']=_0x1fb9e5;const _0xd60eab=this['context']['plugins']['get'](z);if(_0xd60eab['_annotations']=_0x1fb9e5,this['isAttached'])throw new _0x49f2d8('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0xd60eab,'set:container',()=>{this['detach'](),this['listenTo'](_0xd60eab,'change:container',_0x2f747c=>{_0x2f747c['off'](),this['attach'](_0x1fb9e5);});}),_0xd60eab['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x44c84b=_0x2eb2f5=>{_0x2eb2f5['updateTargetRect'](),_0xd60eab['addAnnotation'](_0x2eb2f5);};for(const _0x3922f7 of _0x1fb9e5)_0x44c84b(_0x3922f7);this['listenTo'](_0x1fb9e5,'add',(_0x14f8d8,_0x195aaf)=>{_0x44c84b(_0x195aaf);}),this['listenTo'](_0x1fb9e5,'remove',(_0x5856b1,_0x54836d,_0xd5ae64)=>{_0xd60eab['rearrange']({'removedAnnotation':_0x54836d,'previousAnnotation':_0x1fb9e5['get'](_0xd5ae64-0x1),'nextAnnotation':_0x1fb9e5['get'](_0xd5ae64+0x1)}),_0x54836d===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x1fb9e5,'focus',(_0xc84f12,_0x561db5)=>{this['setActiveAnnotation'](_0x561db5);}),this['listenTo'](_0x1fb9e5,'blur',()=>{this['setActiveAnnotation'](null);});const _0x59dab9=this['context']instanceof _0x4ff59a?this['context']['editors']:new _0x3b6a04([this['context']]);for(const _0x89c2c2 of _0x59dab9)this['_integrateWithEditorAnnotations'](_0x89c2c2);this['listenTo'](_0x59dab9,'add',(_0x4d6a6c,_0x4b6db7)=>{this['listenTo'](_0x4b6db7,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x4b6db7);});}),this['listenTo'](_0x59dab9,'remove',(_0x3e5c76,_0x1ae106)=>{_0x1ae106['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x1ae106['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x49f2d8('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x5cee26=this['context']['plugins']['get'](z);_0x5cee26['_detachFromContainer'](this['annotations']),this['stopListening'](_0x5cee26),this['stopListening'](this['annotations']),this['context']instanceof _0x4ff59a&&this['stopListening'](this['context']['editors']);for(const _0x4cb890 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x4cb890);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x458a36){if(!_0x458a36['plugins']['has']('EditorAnnotations'))return;const _0x424b82=_0x458a36['plugins']['get']('EditorAnnotations'),_0x4ff0d5=()=>{const _0x281fe9=_0x424b82['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x281fe9[0x0]||null);};this['listenTo'](_0x424b82,'refresh',_0x4ff0d5),this['listenTo'](_0x424b82,'blur',(_0xd9b9d4,{isAnnotationTracked:_0x50e390})=>{this['activeAnnotation']&&_0x50e390(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x424b82,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x5b2cc8=>{_0x424b82['hasDomSelection']()&&(_0x4ff0d5(),_0x5b2cc8['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x424b82);}['_destroyEditorAnnotationsIntegration'](_0x5c6950){this['stopListening'](_0x5c6950),this['_editorAnnotations']['remove'](_0x5c6950);}}class C extends _0x75d40c{['counterView'];constructor(_0xad3042){super(_0xad3042);const _0x5a2813=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x5d98fd,_0x1e52c0)=>_0x5d98fd?'...':_0x1e52c0['toString']()),this['set']('annotationType',''),this['icon']=_0x200eaa,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x5a2813['to']('annotationType',_0x4bf88f=>'ck-annotation-counter__badge--'+_0x4bf88f),_0x5a2813['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x5a2813['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x4ce48a{['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(_0x55b697){super(_0x55b697),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x431721())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x3b6a04(),this['_refreshPositioningDebounced']=_0x33ca38(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0xeb5ffa(this['context']['locale']),this['balloonPanelView']=new _0x55cc35(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x5d95ed){this['annotations']=_0x5d95ed;const _0x2b7032=this['context']['plugins']['get'](z),_0x1e706d=this['balloonPanelView'];if(_0x2b7032['_annotations']=_0x5d95ed,this['isAttached'])throw new _0x49f2d8('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x2b7032,'set:container',()=>{this['detach'](),this['listenTo'](_0x2b7032,'change:container',_0xf2d149=>{_0xf2d149['off'](),this['attach'](_0x5d95ed);});}),_0x2b7032['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x52752d=_0x358b48=>{const _0x2e560b=new C(this['context']['locale']);_0x2b7032['addAnnotation'](_0x358b48,_0x2e560b),this['_annotationToNarrowView']['set'](_0x358b48,_0x2e560b),_0x2e560b['bind']('isDirty','annotationType','number')['to'](_0x358b48['view'],'isDirty','type','length'),_0x2e560b['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x1e706d['content']['first']!==_0x358b48['view']?(this['_showBalloon'](_0x358b48),_0x358b48['view']['element']['focus'](),this['setActiveAnnotation'](_0x358b48)):this['setActiveAnnotation'](null);});};for(const _0x1378a8 of _0x5d95ed)_0x52752d(_0x1378a8);this['listenTo'](_0x5d95ed,'add',(_0x2c4300,_0x5121d8)=>{_0x52752d(_0x5121d8);}),this['listenTo'](_0x5d95ed,'remove',(_0x2f40a7,_0x997e41,_0x5cefa3)=>{this['_annotationToNarrowView']['get'](_0x997e41)['destroy'](),this['_annotationToNarrowView']['delete'](_0x997e41),_0x2b7032['rearrange']({'removedAnnotation':_0x997e41,'previousAnnotation':_0x5d95ed['get'](_0x5cefa3-0x1),'nextAnnotation':_0x5d95ed['get'](_0x5cefa3+0x1)}),_0x997e41===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x5d95ed,'focus',(_0x349874,_0xc59660)=>{this['setActiveAnnotation'](_0xc59660);}),this['listenTo'](_0x5d95ed,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x116af4,_0x2bd04c)=>{_0x2bd04c['keyCode']===_0x4cec55['esc']&&_0x1e706d['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x1e706d['content']['first']),this['_hideBalloon'](),_0x2bd04c['stopPropagation'](),_0x2bd04c['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x49c82e,_0x2935b3)=>{const _0x3f1a9b=_0x2935b3['target'];_0x1e706d['isVisible']&&_0x1e706d['element']['contains'](_0x3f1a9b)||_0x2b7032['view']['element']['contains'](_0x3f1a9b)||_0x49c82e['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x101501=>_0x101501['contains'](_0x3f1a9b))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x15bf52=this['context']instanceof _0x4ff59a?this['context']['editors']:new _0x3b6a04([this['context']]);for(const _0x3a3437 of _0x15bf52)this['_integrateWithEditorAnnotations'](_0x3a3437);this['listenTo'](_0x15bf52,'add',(_0x1f1c18,_0x3ddc90)=>{this['listenTo'](_0x3ddc90,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x3ddc90);});}),this['listenTo'](_0x15bf52,'remove',(_0x598823,_0x3cd16f)=>{_0x3cd16f['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x3cd16f['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x1a1dfd){if(_0x1a1dfd===this['activeAnnotation'])return;const _0x48ad9a=this['context']['plugins']['get'](z);if(_0x48ad9a['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x1a1dfd,'disableAnimationOnActivatedAnnotation':!0x0}),_0x1a1dfd)_0x48ad9a['getSidebarItemView'](_0x1a1dfd)?this['_showBalloon'](_0x1a1dfd):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x1a1dfd;}['detach'](){if(!this['isAttached'])throw new _0x49f2d8('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x46ce8b=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x373df8=>_0x373df8['destroy']()),this['_annotationToNarrowView']['clear'](),_0x46ce8b['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x4ff59a&&this['stopListening'](this['context']['editors']);for(const _0x414872 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x414872);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'](_0x1d13cf){if(!_0x1d13cf['plugins']['has']('EditorAnnotations'))return;const _0x104f77=_0x1d13cf['plugins']['get']('EditorAnnotations'),_0x3c4c86=this['context']['plugins']['get'](z),_0x3c5e16=this['annotations'],_0x3e2fa6=this['balloonPanelView'],_0x55e714=()=>{const _0x187145=_0x104f77['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x187145),this['setActiveAnnotation'](_0x187145[0x0]||null);};this['listenTo'](_0x104f77,'refresh',_0x55e714),this['listenTo'](_0x104f77,'blur',(_0x3c7499,{isAnnotationTracked:_0x43e075})=>{this['activeAnnotation']&&_0x43e075(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x104f77,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x3c5e16,'blur',_0x4ed071=>{_0x104f77['hasDomSelection']()&&_0x4ed071['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x54cac1,_0x583fcc)=>{const _0x366cab=_0x583fcc['target'];_0x3e2fa6['isVisible']&&_0x3e2fa6['element']['contains'](_0x366cab)||_0x3c4c86['view']['element']['contains'](_0x366cab)||this['activeAnnotation']&&_0x104f77['hasDomSelection']()&&(_0x55e714(),_0x54cac1['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x104f77);}['_destroyEditorAnnotationsIntegration'](_0x491565){_0x491565&&(this['stopListening'](_0x491565),this['_editorAnnotations']['remove'](_0x491565));}['_setSelectedAnnotations'](_0x4f8297){for(const _0x3f46dc of this['_selectedAnnotations'])_0x4f8297['includes'](_0x3f46dc)||this['_manuallyClosedAnnotationViews']['delete'](_0x3f46dc['view']);this['_selectedAnnotations']=_0x4f8297;}['_refreshPositioning'](){const _0x576c46=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x576c46['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0xe65fd9){if(this['_manuallyClosedAnnotationViews']['has'](_0xe65fd9['view']))return;const _0x4b5b5a=this['balloonPanelView']['content']['first'];_0x4b5b5a!==_0xe65fd9['view']?(_0x4b5b5a&&this['_detachListeners'](_0x4b5b5a),this['_attachListeners'](_0xe65fd9['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0xe65fd9['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x456aa9=this['balloonPanelView']['content']['first'],_0x4d647d=_0x456aa9&&this['annotations']['getByView'](_0x456aa9);if(!_0x4d647d||!this['_annotationToNarrowView']['has'](_0x4d647d))return;const _0x51b813=this['_annotationToNarrowView']['get'](_0x4d647d)['element'],_0xfdeb4d=(function(){const _0x6d1da9=_0x55cc35['defaultPositions'];return[_0x6d1da9['southArrowNorthEast'],_0x6d1da9['northArrowSouthEast'],_0x6d1da9['southArrowNorth'],_0x6d1da9['northArrowSouth'],_0x6d1da9['southArrowNorthWest'],_0x6d1da9['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x51b813,'positions':_0xfdeb4d});}['_hideBalloon'](){const _0x5d9f2f=this['balloonPanelView'],_0x1ef437=_0x5d9f2f['content']['first'];_0x1ef437&&(this['_detachListeners'](_0x1ef437),_0x5d9f2f['unpin'](),_0x5d9f2f['content']['clear']());}['_attachListeners'](_0x221704){this['listenTo'](_0x221704,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x221704,'Esc',(_0x1b2722,_0x385e54)=>{this['_manuallyClosedAnnotationViews']['add'](_0x221704),this['_hideBalloon'](),_0x385e54();});}['_detachListeners'](_0x5171bf){this['stopListening'](_0x5171bf);}}class c extends _0x2a31b7{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[b,_0x3c0d23,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4a43a7){super(_0x4a43a7),_0x4a43a7['editing']['view']['addObserver'](_0x2a5d01),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x4a43a7['plugins']['get'](_0x3c0d23),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0xfb7e53=this['editor']['plugins']['get'](j);_0xfb7e53['context']===this['editor']&&(_0xfb7e53['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x345220,_0x22a6e3)=>{const _0x3e1c8f=this['_balloon'];if(this['isAttached']&&_0x3e1c8f['visibleView']){const _0x5b1061=this['annotations']['getByView'](_0x3e1c8f['visibleView']);_0x5b1061&&this['_closeAnnotation'](_0x5b1061),_0x22a6e3();}}));}['afterInit'](){const _0x99ad5b=this['editor']['plugins']['get'](j);_0x99ad5b['context']===this['editor']&&(_0x99ad5b['hasActive']()||_0x99ad5b['switchTo']('inline'));}['setActiveAnnotation'](_0x12d9e6){_0x12d9e6!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x12d9e6&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x12d9e6)&&this['_addAnnotationToBalloon'](_0x12d9e6,!0x0),_0x12d9e6['isActive']=!0x0),_0x12d9e6||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x12d9e6);}['attach'](_0x30603d){this['annotations']=_0x30603d;const _0x39021f=this['editor']['plugins']['get'](j),_0x2307cc=this['_balloon'];if(this['isAttached'])throw new _0x49f2d8('inlineannotations-attach-already-attached',this);if(_0x39021f['context']!==this['editor'])throw new _0x49f2d8('inlineannotations-not-allowed-with-context',this);const _0x38d6d1=this['editor']['plugins']['get'](b);this['listenTo'](_0x38d6d1,'refresh',()=>{const _0x13ce35=_0x38d6d1['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x6e9b10,_0x18c9a2;!this['_forceRefresh']&&(_0x6e9b10=_0x13ce35,_0x18c9a2=this['_selectedAnnotations'],_0x6e9b10['length']===_0x18c9a2['length']&&_0x6e9b10['every'](_0x1c4ff7=>_0x18c9a2['includes'](_0x1c4ff7)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x13ce35),this['setActiveAnnotation'](_0x13ce35[0x0]||null));}),this['listenTo'](_0x38d6d1,'blur',(_0x3d21a6,{isAnnotationTracked:_0x36c78b})=>{this['activeAnnotation']&&_0x36c78b(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x5e1b64,_0x253f8d,_0x46d9a7)=>{_0x46d9a7||this['setActiveAnnotation'](null);}),this['listenTo'](_0x30603d,'remove',(_0x315e32,_0x392061)=>{this['_removeAnnotationFromBalloon'](_0x392061),_0x392061===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x2307cc,'change:visibleView',(_0xdf44bd,_0x4770dd,_0x2d0116,_0x295836)=>{_0x295836&&this['stopListening'](_0x295836);const _0x343aca=_0x30603d['getByView'](_0x2d0116);_0x2d0116&&_0x343aca&&(this['listenTo'](_0x2d0116,'change:height',()=>{_0x2307cc['updatePosition']();}),this['listenTo'](_0x2d0116,'Esc',()=>{this['_closeAnnotation'](_0x343aca),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x343aca&&this['setActiveAnnotation'](_0x343aca));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x2307cc['visibleView']&&(_0x30603d['getByView'](_0x2307cc['visibleView'])&&_0x2307cc['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 _0x49f2d8('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0xdc647f of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0xdc647f);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x4c075b){for(const _0x23633e of this['_selectedAnnotations'])_0x4c075b['includes'](_0x23633e)||this['_manuallyClosed']['delete'](_0x23633e);for(const _0x2bbf7f of this['annotations'])_0x4c075b['includes'](_0x2bbf7f)||this['_removeAnnotationFromBalloon'](_0x2bbf7f);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x17eb2a of _0x4c075b)this['_addAnnotationToBalloon'](_0x17eb2a);}this['_selectedAnnotations']=_0x4c075b;}['_addAnnotationToBalloon'](_0x1c7e08,_0x1411cc=!0x1){this['_manuallyClosed']['has'](_0x1c7e08)||(this['_addedAnnotations']['has'](_0x1c7e08)||this['_balloon']['hasView'](_0x1c7e08['view'])||(this['_addedAnnotations']['add'](_0x1c7e08),this['_balloon']['add']({'stackId':_0x1c7e08['view']['id'],'view':_0x1c7e08['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x1c7e08)}})),_0x1411cc&&this['_balloon']['showStack'](_0x1c7e08['view']['id']));}['_getBalloonTargetForAnnotation'](_0x4dd9e8){const _0x307129=_0x4dd9e8['target'],_0x50369e=this['editor']['editing']['view'],_0x2308fe=_0x50369e['document']['selection']['getFirstRange'](),_0x1492d6=_0x50369e['domConverter']['viewRangeToDom'](_0x2308fe);if(_0x1492d6['collapse'](!0x0),_0x307129){if(_0x307129 instanceof _0x4a16d0)return _0x307129;let _0x120e53=[];for(const _0x36a504 of _0x307129)_0x120e53['push'](...F(_0x36a504['getClientRects']()));_0x120e53=function(_0x401956){const _0x4a957a=[];let _0x231bed=_0x401956[0x0];for(let _0x98878c=0x1;_0x98878c<_0x401956['length'];_0x98878c++)P(_0x231bed,_0x401956[_0x98878c])?_0x231bed['width']+=_0x401956[_0x98878c]['width']:(_0x4a957a['push'](_0x231bed),_0x231bed=_0x401956[_0x98878c]);return _0x4a957a['push'](_0x231bed),_0x4a957a;}(_0x120e53);const _0x43ab12=_0x1492d6['getBoundingClientRect']();return _0x120e53['find'](_0x281ad9=>_0x281ad9['top']<=_0x43ab12['top']&&_0x281ad9['bottom']>=_0x43ab12['bottom']&&_0x281ad9['left']<=_0x43ab12['left']&&_0x281ad9['right']>=_0x43ab12['right'])||_0x120e53[0x0];}return _0x4dd9e8['targetRect']||_0x1492d6;}['_removeAnnotationFromBalloon'](_0x58c4c7){this['_addedAnnotations']['has'](_0x58c4c7)&&this['_balloon']['hasView'](_0x58c4c7['view'])&&(this['_addedAnnotations']['delete'](_0x58c4c7),this['_balloon']['remove'](_0x58c4c7['view']));}['_closeAnnotation'](_0x597aca){this['_manuallyClosed']['add'](_0x597aca),this['_removeAnnotationFromBalloon'](_0x597aca);}}function F(_0x220410){return Array['from'](_0x220410)['map'](DOMRect['fromRect']);}function P(_0x5759e7,_0x55a849){return _0x5759e7['top']===_0x55a849['top']&&_0x5759e7['bottom']===_0x55a849['bottom']&&_0x5759e7['right']===_0x55a849['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x4dde8f,_0x1be381){super(_0x4dde8f),this['set']('isEmpty',!_0x1be381['length']),this['focusTracker']=new _0x27e202(),this['_annotationViews']=_0x1be381,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x113be5({'focusables':_0x1be381,'focusTracker':this['focusTracker']}),this['listenTo'](_0x1be381,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x1be381,'remove',(_0x2c016e,_0x1dc622)=>{_0x1dc622['isActive']&&this['focus'](),_0x1be381['length']||(this['isEmpty']=!0x0);});const _0x4d5f7c=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x4dde8f,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x1be381},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x4d5f7c['if']('isEmpty','ck-hidden',_0x2ee415=>!_0x2ee415)]},'children':[{'text':N(_0x4dde8f,'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 _0x1172f2 of this['_annotationViews'])this['focusTracker']['add'](_0x1172f2['element']);this['_annotationViews']['on']('change',(_0x181cbe,{added:_0xc8795b,removed:_0x5842f5})=>{for(const _0x56ba54 of _0xc8795b)this['focusTracker']['add'](_0x56ba54['element']);for(const _0x118ca8 of _0x5842f5)this['focusTracker']['remove'](_0x118ca8['element']);});}}class p extends _0x4ce48a{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x221abe){super(_0x221abe),this['archivedThreads']=new _0x3b6a04();}['init'](){const _0x2f0af2=this['context'],_0x38caab=_0x2f0af2['plugins']['get'](o),_0x48a05c=_0x2f0af2['plugins']['get'](y);this['listenTo'](_0x38caab,'addCommentThread',(_0x3b9753,{threadId:_0x30e71f})=>{const _0x304303=_0x38caab['getCommentThread'](_0x30e71f);_0x304303['archivedAt']&&this['archivedThreads']['add'](_0x304303,this['_calculatePosition'](_0x304303['archivedAt'])),this['listenTo'](_0x304303,'change:archivedAt',(_0x3356eb,_0x1f0f5e,_0x1875be)=>{_0x1875be?this['archivedThreads']['has'](_0x304303)||this['archivedThreads']['add'](_0x304303,this['_calculatePosition'](_0x304303['archivedAt'])):this['archivedThreads']['has'](_0x304303)&&this['archivedThreads']['remove'](_0x304303);});}),this['listenTo'](_0x38caab,'removeCommentThread',(_0x469f78,{threadId:_0x2a4ffe})=>{const _0x1c576f=_0x38caab['getCommentThread'](_0x2a4ffe);this['stopListening'](_0x1c576f),this['archivedThreads']['has'](_0x1c576f)&&this['archivedThreads']['remove'](_0x1c576f);},{'priority':'highest'}),this['listenTo'](_0x48a05c['collection'],'focus',(_0x9be4aa,_0x1b64f6)=>{_0x1b64f6['isVisible']||(_0x1b64f6['isActive']=!0x0,_0x48a05c['activate'](_0x1b64f6));});}['_calculatePosition'](_0x53fbe8){const _0x16dc1d=[...this['archivedThreads']]['findIndex'](_0x20d98f=>_0x20d98f['archivedAt']<_0x53fbe8);return _0x16dc1d>-0x1?_0x16dc1d:this['archivedThreads']['length'];}}class a extends _0x2a31b7{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x40be78];}constructor(_0x895735){super(_0x895735),this['annotationViews']=new _0x1378ee(),this['_pendingThreads']=[];}['init'](){const _0x4cf494=this['editor'],_0x318425=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x4cf494['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x75d40c,!0x0)),_0x4cf494['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0xfefdc1=this['_createCommentsArchiveButton'](_0x900133);return _0xfefdc1['set']({'role':'menuitemcheckbox'}),_0xfefdc1;});const _0x12f029=_0x4cf494['plugins']['get'](p),_0x383a68=_0x4cf494['plugins']['get']('Annotations'),_0x59b44f=_0x4cf494['plugins']['get']('CommentsRepository');_0x12f029['archivedThreads']['forEach'](_0x548891=>{this['_handleNewThread'](_0x548891);}),this['listenTo'](_0x12f029['archivedThreads'],'add',(_0x4291d9,_0x100d97)=>{this['_handleNewThread'](_0x100d97);}),this['listenTo'](_0x383a68['collection'],'add',(_0x3e0da4,_0x2c71ba)=>{const _0x5d5eaa=this['_pendingThreads']['find'](_0x2faed5=>{const _0x91e252=_0x59b44f['_threadToController']['get'](_0x2faed5);return _0x91e252&&_0x2c71ba['innerView']===_0x91e252['view'];});if(_0x5d5eaa){const _0x67f4c9=this['_calculatePosition'](_0x5d5eaa['archivedAt']);this['annotationViews']['add'](_0x2c71ba['view'],_0x67f4c9),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x5d5eaa),0x1);}}),this['listenTo'](_0x12f029['archivedThreads'],'remove',(_0x3e99d4,_0x50e83e)=>{const _0x53c5b5=_0x4cf494['config']['get']('collaboration.channelId');if(!_0x53c5b5||_0x50e83e['channelId']===_0x53c5b5){if(this['_pendingThreads']['includes'](_0x50e83e))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x50e83e),0x1);else{const _0xe63368=_0x59b44f['_threadToController']['get'](_0x50e83e),_0x135b0a=_0x383a68['getByInnerView'](_0xe63368['view']);this['annotationViews']['remove'](_0x135b0a['view']),this['stopListening'](_0x135b0a['focusableElements']);}}}),this['listenTo'](_0x383a68['collection'],'add',(_0x5e1d04,_0x3e924e)=>{this['listenTo'](_0x3e924e,'escape',_0x318425);}),this['listenTo'](_0x383a68['collection'],'remove',(_0x3a0222,_0x516f6f)=>{this['stopListening'](_0x516f6f,'escape',_0x318425);});}['_handleNewThread'](_0x47d7f3){const _0xd77fe3=this['editor']['plugins']['get']('CommentsRepository'),_0x26931e=this['editor']['plugins']['get']('Annotations'),_0x3fdeb9=this['editor']['config']['get']('collaboration.channelId');if(!_0x3fdeb9||_0x47d7f3['channelId']===_0x3fdeb9){const _0x48aaf3=_0xd77fe3['_threadToController']['get'](_0x47d7f3);if(!_0x48aaf3)return void this['_pendingThreads']['push'](_0x47d7f3);const _0x1d5463=this['_calculatePosition'](_0x47d7f3['archivedAt']),_0x41b9b5=_0x26931e['getByInnerView'](_0x48aaf3['view']);_0x41b9b5['isVisible']&&_0x26931e['_visibleAnnotations']['remove'](_0x41b9b5),this['annotationViews']['add'](_0x41b9b5['view'],_0x1d5463);}}['_calculatePosition'](_0x235656){const _0x21d2f0=this['editor']['config']['get']('collaboration.channelId'),_0x21159a=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0x3eb903=>_0x3eb903['channelId']===_0x21d2f0)['findIndex'](_0x2cbd98=>_0x2cbd98['archivedAt']<_0x235656);return _0x21159a<0x0||_0x21159a>this['annotationViews']['length']?this['annotationViews']['length']:_0x21159a-0x1;}['_toggleDialog'](){const _0x2f8e52=this['editor'],_0x3cd627=_0x2f8e52['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x2f8e52['locale'],this['annotationViews'])),'commentsArchive'===_0x3cd627['id']?_0x3cd627['hide']():_0x3cd627['show']({'id':'commentsArchive','title':N(_0x2f8e52['locale'],'COMMENTS_ARCHIVE'),'icon':_0x345262,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x303166['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0xd5f939,_0x257d8d=!0x1){const _0x23a465=this['editor']['locale'],_0x5baca3=this['editor']['plugins']['get']('Dialog'),_0x200dab=new _0xd5f939(_0x23a465);return _0x200dab['bind']('isEnabled')['to'](this,'isEnabled'),_0x200dab['bind']('isOn')['to'](_0x5baca3,'id',_0x3307ff=>'commentsArchive'===_0x3307ff),_0x200dab['set']({'label':N(_0x23a465,'COMMENTS_ARCHIVE'),'icon':_0x345262,'isToggleable':!0x0}),_0x257d8d&&(_0x200dab['tooltip']=!0x0),this['listenTo'](_0x200dab,'execute',()=>this['_toggleDialog']()),_0x200dab;}['_hideDialogOnAnnotationEscape']=_0x40ba8c=>{const _0x3efb23=_0x40ba8c['source'];if(!this['annotationViews']['has'](_0x3efb23['view']))return;const _0x583dd5=this['editor']['plugins']['get']('Dialog');_0x583dd5['isOpen']&&'commentsArchive'===_0x583dd5['id']&&(_0x583dd5['hide'](),_0x40ba8c['stop']());};}class gi extends _0x2a31b7{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 _0x74e6ba,ContextPlugin as _0x2228db,PendingActions as lt,Command as _0x164c61,Plugin as _0x41aca7,Context as _0xb420e9}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x2f7441,uid as _0x2388d3,KeystrokeHandler as jt,FocusTracker as _0x19913b,diff as _0x334924,Collection as _0x2a8245,Rect as _0x3fbc4e,CKEditorError as _0x2e6f8f,first as _0x4dfbcc,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x5cce27,keyCodes as _0x3fe5b7}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x3be5f0,AriaDescriptionView as Zt,setupThreadKeyboardNavigation as ts,ConfirmMixin as ti,LateFocusButtonView as _0xa36bed,trimHtml as _0x3c0b88,LateFocusDropdownButtonView as _0x2fdf7f,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x1d9801}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x49b0b7}from'es-toolkit/compat';import{IconUndo as _0x23f74c,IconCheck as _0x19b11d,IconPencil as _0x1747b0,IconRemoveComment as _0x28f460,IconThreeVerticalDots as _0x508d6d,IconAddComment as _0x482462,IconCommentsArchive as _0x37db05}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as Xt,InlineEditableUIView as $t,EditorUI as Ut,View as kt,FocusCycler as _0x7bfb99,ButtonView as _0x3c4ac3,ViewCollection as _0x5e227b,createDropdown as _0x53105e,ListView as _0xfedfda,focusChildOnDropdownOpen as _0x5c6167,ListItemView as _0x287548,MenuBarMenuListItemButtonView as _0x27f8f3,BodyCollection as _0x3b1e98,BalloonPanelView as _0x5ae522,ContextualBalloon as _0x300697,Dialog as _0x4c9c9e,DialogViewPosition as _0x2b4a03}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as qt,enableViewPlaceholder as St,MouseObserver as _0x2b71be}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as zt,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as Bt,ShiftEnter as Et}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 _0x4ddf4f}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x54dc86}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
+ _0x2f7441(){['model'];['view'];constructor(_0x2dbcc6,_0x44245e){super(),this['model']=_0x2dbcc6,this['model']['_isAttached']=!0x0,this['view']=_0x44245e,this['listenTo'](_0x44245e,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x44245e,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x44245e,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x44245e,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x44245e,'addComment',(_0x5735c9,_0x206b9e)=>this['addComment'](_0x206b9e)),this['listenTo'](_0x44245e,'updateComment',(_0x15e0a5,_0x4199b3,_0x3b075e)=>this['updateComment'](_0x4199b3,_0x3b075e)),this['listenTo'](_0x44245e,'removeComment',(_0x5124f1,_0x14769c)=>this['removeComment'](_0x14769c));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x13188c){this['model']['addComment']({'content':_0x13188c,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x39002e,_0x849e0b){this['model']['getComment'](_0x39002e)['update']({'content':_0x849e0b});}['removeComment'](_0x5982ae){this['model']['getComment'](_0x5982ae)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x5c2419,_0x37180e,_0x18803b){const t=_0x5c2419['t'];switch(_0x37180e){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'},_0x18803b);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'},_0x18803b);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'},_0x18803b);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'},_0x18803b);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x18803b);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'},_0x18803b);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'},_0x18803b);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'},_0x18803b);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 Vt extends Xt{['main'];['editable'];constructor(_0x4d00e7,_0x596067){super(_0x4d00e7);const _0x4b69d8=_0x2388d3();this['main']=this['createCollection'](),this['editable']=new $t(_0x4d00e7,_0x596067,void 0x0,{'label':()=>N(_0x4d00e7,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x4d00e7['uiLanguageDirection'],'lang':_0x4d00e7['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x4b69d8},'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 Ft extends Ut{['view'];constructor(_0x1e7835){super(_0x1e7835),this['view']=new Vt(_0x1e7835['locale'],_0x1e7835['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x424091=this['editor']['editing']['view'],_0x5b275c=this['view']['editable'],_0x12a9de=_0x424091['document']['getRoot']();_0x5b275c['name']=_0x12a9de['rootName'],this['view']['render']();const _0x38f79e=_0x5b275c['element'];this['setEditableElement'](_0x5b275c['name'],_0x38f79e),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x424091['attachDomRoot'](_0x38f79e),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[zt,Bt,Et,Gt,Jt,Kt,Lt];class Rt extends/* #__PURE__ -- @preserve */
25
+ _0x2f7441(_0x74e6ba){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
+ ((()=>Qt)());constructor(_0x4315dd={}){function _0x347e76(_0x3150c5){return _0x3150c5['map'](_0x58d0d0=>String['fromCharCode'](_0x58d0d0))['join']('');}(_0x4315dd=Object['assign']({},_0x4315dd))['plugins']||(_0x4315dd['plugins']=Rt['defaultPlugins']),super(_0x4315dd),this['ui']=new Ft(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x347e76([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x347e76([0x76,0x69,0x65,0x77])][_0x347e76([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x347e76([0x61,0x75,0x74,0x6f]),this[_0x347e76([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x347e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x347e76([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x347e76([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x347e76([0x6f,0x6b])});}['create'](){const _0x154050=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x154050))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0xa0d664=>{const _0x3ed495=this['model']['document']['getRoot'](),_0xc8a2f9=_0x3ed495&&_0x3ed495['getChild'](_0x3ed495['childCount']-0x1);_0xa0d664['setSelection'](_0xc8a2f9,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x47f8a1=this['editing']['view'],_0x373cc1=_0x47f8a1['document']['getRoot'](),_0x287348=_0x373cc1['getChild'](0x0);_0x373cc1['childCount']>0x1||!_0x287348||'p'!=_0x287348['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(qt(_0x47f8a1,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x287348['placeholder']=this['placeholder']),St({'view':_0x47f8a1,'element':_0x287348,'keepOnFocus':!0x0}),this['placeholderElement']=_0x287348);}}class os extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x56e579,_0x579230={}){super(_0x56e579),this['editor']=null,this['_editorConfig']=_0x579230,this['set']('value',_0x579230['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x56e579,'Reply...')),this['set']('submitLabel',N(_0x56e579,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x19913b(),this['focusCycler']=new _0x7bfb99({'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',(_0x2d1fd7,_0x578778)=>{this['cancelButtonView']['fire']('execute'),_0x578778();}),this['keystrokes']['set']('Ctrl+Enter',(_0x481a66,_0x394ec9)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x394ec9());}),this['on']('submit',(_0x18c919,_0x37ada8)=>{_0x37ada8['length']>0xfde8?(alert(N(_0x56e579,'TOO_LONG_COMMENT_ALERT',[_0x37ada8['length'],0xfde8])),_0x18c919['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Rt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x4e8c5c=this['editor'];this['element']['insertBefore'](_0x4e8c5c['ui']['element'],this['element']['firstChild']),_0x4e8c5c['model']['document']['on']('change',()=>this['value']=_0x4e8c5c['getData']()),_0x4e8c5c['bind']('placeholder')['to'](this),this['focusables']['add'](_0x4e8c5c['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x1886bc){-0x1===_0x1886bc?(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:_0x209b1a}=this,_0x28264b=new _0x3c4ac3(_0x209b1a);return _0x28264b['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x28264b['withText']=!0x0,_0x28264b['bind']('label')['to'](this,'submitLabel'),_0x28264b['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x28264b['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x2c857a,_0x5a89fa)=>!_0x5a89fa&&!!_0x2c857a['trim']()),_0x28264b;}['_createCancelButton'](){const {locale:_0x222455}=this,_0x3c8893=new _0x3c4ac3(_0x222455);return _0x3c8893['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x3c8893['label']=N(_0x222455,'Cancel'),_0x3c8893['withText']=!0x0,_0x3c8893['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x3c8893;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x165f44=>{this['focusTracker']['add'](_0x165f44['element']);}),this['focusables']['on']('change',(_0x3819e6,_0x5bcfd2)=>{for(const _0x4d6942 of Array['from'](_0x5bcfd2['added'])['reverse']())this['focusTracker']['add'](_0x4d6942['element']);});}}class ie extends kt{constructor(_0x5d21f3,_0x3f69aa,_0x260ad9){super(_0x5d21f3),this['commentInputView']=new os(_0x5d21f3,_0x260ad9),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x4703a5,_0x471a3c)=>_0x4703a5||!!_0x471a3c),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 _0x3be5f0(_0x5d21f3,_0x3f69aa),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'](_0x483b9b){this['commentInputView']['focus'](_0x483b9b);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x2deb1e,_0x1cf6a9)=>{const {submitButtonView:_0x54c060,cancelButtonView:_0x42f1df,editor:_0x3462dc}=this['commentInputView'];[_0x54c060['element'],_0x42f1df['element'],_0x3462dc?_0x3462dc['editing']['view']['getDomRoot']():null]['filter'](_0xf9fbce=>_0xf9fbce)['some'](_0x2221fa=>_0x2221fa['contains'](_0x1cf6a9['target']))||(this['focus'](),_0x1cf6a9['preventDefault']());});}}class rs extends kt{constructor(_0x4f23cf){super(_0x4f23cf);const _0x4259c5=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x4259c5['to']('count',_0x5840dd=>N(_0x4f23cf,'NUMBER_OF_COMMENTS',_0x5840dd))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x127335,_0x44c68d,_0x20b30a){super(_0x127335);const _0x546257=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x44c68d['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x44c68d,this['_config']=_0x20b30a,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x19913b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x7bfb99({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x3a29e4=>this['commentViews']['map'](_0x3d4cb4=>_0x3d4cb4['element'])['includes'](_0x3a29e4['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x127335),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0xf400a3=>_0xf400a3-this['_config']['maxCommentsWhenCollapsed']);for(const _0xe79666 of _0x44c68d['comments'])this['_handleNewCommentModel'](_0xe79666);this['_handleInfoComment'](),this['listenTo'](_0x44c68d['comments'],'add',(_0x270877,_0x8cec45)=>{const _0x3aff8d=this['_calculatePosition'](_0x8cec45);this['length']++,this['_handleNewCommentModel'](_0x8cec45,_0x3aff8d),this['refreshVisibleViews']();}),this['listenTo'](_0x44c68d['comments'],'remove',(_0x47c6a0,_0x4cfe4e)=>{this['length']--,this['_handleRemoveCommentModel'](_0x4cfe4e),this['refreshVisibleViews']();}),this['listenTo'](_0x44c68d,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x44c68d,'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',_0x546257['if']('length','ck-hidden',_0x59e9c1=>!_0x59e9c1)],'aria-label':N(_0x127335,'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'](_0x2ad449){-0x1===_0x2ad449?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x2531d8 of this['commentViews'])_0x2531d8['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x136f70,_0x449985){const _0x4cadcd=new this['_config']['CommentView'](this['locale'],_0x136f70,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x4cadcd['viewUid']=_0x136f70['id'],_0x4cadcd['delegate']('removeComment')['to'](this),_0x4cadcd['delegate']('updateComment')['to'](this),_0x4cadcd['delegate']('resolveCommentThread')['to'](this),_0x4cadcd['delegate']('editorReady')['to'](this),_0x4cadcd['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x4cadcd,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x4cadcd,_0x449985);}['_calculatePosition'](_0x83780d){const _0x151af7=this['_model']['_findOptimalIndex'](_0x83780d);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x83780d['authoredAt']?_0x151af7-0x1:_0x151af7:_0x151af7-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x2646da={'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'],_0x2646da,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x2646da));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0xa419f3){const _0x31f0f4=this['commentViews']['remove'](_0xa419f3['id']);this['stopListening'](_0x31f0f4),_0x31f0f4['isEditMode']&&this['_updateHasDirtyComment'](),_0x31f0f4['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x5da521=>_0x5da521['isEditMode']);}['_rearrangeCollapse'](){const _0x586b07=function(_0x9e51b6){const _0x513052=new _0x2a8245();for(const _0xe741c2 of _0x9e51b6)_0x513052['add'](_0xe741c2);return _0x513052;}(this['commentViews']),_0x3c1c6c=this['_collapsedCommentsView']['count'];for(let _0x1bc6d3=0x1;_0x1bc6d3<=_0x3c1c6c;_0x1bc6d3++)_0x586b07['remove'](0x1);for(const _0x25e15c of _0x586b07)_0x25e15c['collapse']();_0x3c1c6c>0x0&&_0x586b07['add'](this['_collapsedCommentsView'],0x1),ns(_0x334924(Array['from'](this['visibleViews']),Array['from'](_0x586b07)),this['visibleViews'],_0x586b07);}['_rearrangeExpand'](){ns(_0x334924(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x5193f5 of this['visibleViews'])_0x5193f5['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x4f22e0=>{this['focusTracker']['add'](_0x4f22e0['element']),this['keystrokes']['listenTo'](_0x4f22e0['element']);}),this['commentViews']['on']('change',(_0x3b8ee0,_0x197a68)=>{for(const _0x5b1332 of _0x197a68['removed'])this['focusTracker']['remove'](_0x5b1332['element']),this['keystrokes']['stopListening'](_0x5b1332['element']);for(const _0xa22e3e of Array['from'](_0x197a68['added'])['reverse']())this['focusTracker']['add'](_0xa22e3e['element']),this['keystrokes']['listenTo'](_0xa22e3e['element']);});}}function ns(_0x424f59,_0x11190b,_0x186c22){let _0x215aef=0x0;for(const _0x489733 of _0x424f59)switch(_0x489733){case'insert':_0x11190b['add'](_0x186c22['get'](_0x215aef),_0x215aef),_0x215aef++;break;case'delete':_0x11190b['remove'](_0x215aef);break;case'equal':_0x215aef++;}}class oe extends kt{constructor(_0x51903f){super(_0x51903f);const _0x2461a0=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x2461a0['to']('contextValue',_0x9fb5f7=>N(_0x51903f,'THREAD_CONTEXT_LABEL',_0x9fb5f7)),'tabindex':-0x1},'children':[{'text':_0x2461a0['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Yt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x24aec4,_0x54748b){super(_0x24aec4);const _0x429b77=this['bindTemplate'];this['_model']=_0x54748b,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x19913b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x7bfb99({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x52481f=>!!_0x52481f),this['bind']('contextValue')['to'](this['_model'],'context',_0x3afd4f=>_0x3afd4f&&_0x3afd4f['value']?this['_trimContextValue'](_0x3afd4f['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',_0x429b77['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 _0x1715ca=new _0x3c4ac3(this['locale']);return _0x1715ca['label']=N(this['locale'],'Reopen'),_0x1715ca['tooltip']=N(this['locale'],'Reopen'),_0x1715ca['icon']=_0x23f74c,_0x1715ca['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x2fa785=>!_0x2fa785),_0x1715ca['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x32bd0b,_0x374b1c)=>_0x32bd0b&&_0x374b1c),_0x1715ca['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x1715ca;}['_trimContextValue'](_0x23379f){if(_0x23379f['length']<0x96)return _0x23379f;const _0x388965=_0x23379f['lastIndexOf']('\x20',0x93);return _0x23379f['substring'](0x0,_0x388965>-0x1?_0x388965:0x93)+'...';}['_attachContextActions'](){const _0x2597e8=this['element']['querySelector']('.ck-context'),_0x27c38d=_0x2597e8['querySelector']('.ck-context__value');this['listenTo'](_0x2597e8,'mouseenter',()=>{_0x27c38d['offsetWidth']<_0x27c38d['scrollWidth']&&_0x2597e8['classList']['add']('overlay');}),this['listenTo'](_0x2597e8,'mouseleave',()=>{_0x2597e8['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x46c93 of this['focusables'])this['focusTracker']['add'](_0x46c93['element']),this['keystrokes']['listenTo'](_0x46c93['element']);}['_createContextView'](){const _0x178047=new oe(this['locale']);return _0x178047['bind']('contextValue')['to'](this),_0x178047;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x43e697,_0x41a787,_0x2db3c7,_0x382431){super(_0x43e697),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x41a787,this['_localUser']=_0x2db3c7,this['_config']=_0x382431,this['commentThreadHeaderView']=new Yt(_0x43e697,_0x41a787),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Zt(_0x43e697,N(_0x43e697,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x43e697,_0x41a787,Object['assign']({'CommentView':this['_config']['CommentView']},_0x382431)),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',(_0x37bbb8,_0x5c557a)=>_0x37bbb8||!!_0x5c557a),this['bind']('isUnlinked')['to'](_0x41a787,'unlinkedAt',_0x23cc22=>!!_0x23cc22),this['bind']('ariaLabel')['to'](this,'length',_0x561784=>{const _0x5b61f1=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x561784,_0x5b61f1]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x19913b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x7bfb99({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0xde034b=>_0xde034b['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),ts(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x5c843a=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x19413a=_0x5c843a['commentInputView'];return _0x5c843a['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x19413a,'value',(_0x11560f,_0x53a41d,_0xdbc059,_0x508c89,_0x5ba9e4)=>!!_0x5ba9e4||!!_0x508c89&&_0xdbc059&&!_0x53a41d||_0x11560f&&_0xdbc059&&!_0x53a41d),_0x19413a['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x34b641,_0x2f1127,_0x1a88c1)=>{let _0x1c15a4;return _0x1c15a4=_0x1a88c1&&_0x2f1127?'Reply\x20to\x20reopen\x20discussion...':_0x34b641?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x1c15a4);}),_0x19413a['bind']('submitLabel')['to'](this,'length',_0xe65446=>N(this['locale'],_0xe65446?'Reply':'Comment')),_0x19413a['on']('submit',(_0x32a640,_0x1c2676)=>{this['fire']('addComment',_0x1c2676),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x19413a['on']('cancel',()=>{this['focus']();}),_0x19413a['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x19413a['on']('cancel',_0x4ee972=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x4ee972['stop']());}),this['on']('change:isActive',(_0x3753a7,_0x1f47b5,_0x2a8cf5)=>{_0x2a8cf5||this['length']||_0x19413a['value']||this['fire']('removeCommentThread');}),_0x5c843a;}}class gt extends/* #__PURE__ -- @preserve */
27
+ ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x5d0409,_0x4014bf,_0x5a199b,_0x1358c5){super(_0x5d0409,_0x4014bf,_0x5a199b,_0x1358c5),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x5d0409,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x5f1b37,_0xa08936,_0x2dceb1)=>{_0x2dceb1||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x4b7d7b,_0x4909f4,_0xd01f9)=>{_0xd01f9&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x4f9765=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x4f9765['if']('isActive','ck-thread--active'),_0x4f9765['if']('isUnlinked','ck-thread--unlinked'),_0x4f9765['if']('isConfirm','ck-thread--remove-confirmation'),_0x4f9765['to']('actionIndicator',_0x299006=>_0x299006?'ck-thread--'+_0x299006:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x4f9765['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 _0x3e7bc5 of this['commentsListView']['commentViews'])_0x3e7bc5['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x25e6ba}=this,_0x1d6516=this['commentsListView']['commentViews']['get'](0x0);_0x1d6516===this['_boundFirstCommentView']||_0x1d6516['isSystemComment']||(this['_boundFirstCommentView']=_0x1d6516,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x1d6516,'actionIndicator',_0x5c6671=>'remove'===_0x5c6671?'remove':null),_0x1d6516['placeholder']=N(_0x25e6ba,'Write\x20a\x20comment...'),_0x1d6516['removeButton']['on']('execute',_0x26528d=>{_0x26528d['stop'](),this['showConfirm'](N(_0x25e6ba,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x1d6516['focus']();}),_0x1d6516['actionBar']['add'](this['resolveButton'],0x0),_0x1d6516['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x57d69b=new _0xa36bed(this['locale']);return _0x57d69b['label']=N(this['locale'],'Resolve'),_0x57d69b['tooltip']=N(this['locale'],'Resolve'),_0x57d69b['icon']=_0x19b11d,_0x57d69b['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x57d69b['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1a5657=>!_0x1a5657),_0x57d69b['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x46546c,_0x519cb5)=>_0x46546c&&!_0x519cb5),_0x57d69b['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x57d69b;}['_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 es extends kt{constructor(_0x5b03e5){super(_0x5b03e5),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x129d55,_0x2b2e1a,_0x267afd)=>{this['element']['innerHTML']=_0x267afd;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x1ac88a,_0x10a83c,_0x44dd3e){super(_0x1ac88a),this['_model']=_0x10a83c,this['_config']=_0x44dd3e,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x10a83c,'content',_0x10a83c,'authoredAt',(_0x45cfd0,_0x14353b)=>N(_0x1ac88a,'COMMENT_ARIA_LABEL',[_0x10a83c['author']['name'],_0x44dd3e['formatDateTime'](_0x14353b),new DOMParser()['parseFromString'](_0x45cfd0,'text/html')['body']['textContent'],_0x10a83c['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Zt(_0x1ac88a,N(_0x1ac88a,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x5e227b(),this['focusTracker']=new _0x19913b(),this['keystrokes']=new jt(),this['focusCycler']=new _0x7bfb99({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5250eb=>_0x5250eb['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 _0x329b44=new es(this['locale']);return _0x329b44['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x586de6,_0x561468)=>_0x561468?_0x3c0b88(_0x586de6,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x586de6),_0x329b44;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x2debe5=new os(this['locale'],this['_config']['editorConfig']);return _0x2debe5['value']=this['_model']['content'],_0x2debe5['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x2debe5['submitLabel']=N(this['locale'],'Save'),_0x2debe5['on']('submit',(_0x37b44f,_0x4d4b57)=>{this['fire']('updateComment',this['_model']['id'],_0x4d4b57),this['switchToDisplayMode'](),this['focus']();}),_0x2debe5['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x2debe5['once']('editorReady',()=>{_0x2debe5['focus']();}),_0x2debe5['createEditor'](),_0x2debe5['delegate']('editorReady')['to'](this),_0x2debe5['delegate']('editorDestroyed')['to'](this),_0x2debe5;}['_setupKeyboardNavigation'](){const _0x92cdb6=this['element'];this['keystrokes']['listenTo'](_0x92cdb6);for(const _0x2e93a8 of this['focusables'])this['focusTracker']['add'](_0x2e93a8['element']),this['keystrokes']['listenTo'](_0x2e93a8['element']);this['focusables']['on']('change',(_0x236117,_0xfff914)=>{for(const _0x3adb0f of _0xfff914['removed'])this['focusTracker']['remove'](_0x3adb0f['element']),this['keystrokes']['stopListening'](_0x3adb0f['element']);for(const _0x514cef of _0xfff914['added'])this['focusTracker']['add'](_0x514cef['element']),this['keystrokes']['listenTo'](_0x514cef['element']);}),this['keystrokes']['set']('enter',(_0xc2dc62,_0x165229)=>{_0x92cdb6===_0xc2dc62['target']&&(this['focusCycler']['focusFirst'](),_0x165229());}),this['keystrokes']['set']('esc',(_0xaf5690,_0x4bcb4a)=>{_0x92cdb6!==_0xaf5690['target']&&(this['focus'](),_0x4bcb4a());});}}class Tt extends/* #__PURE__ -- @preserve */
28
+ ti(di){['actionBar'];['userView'];constructor(_0x11886b,_0xaae130,_0x530cfb){super(_0x11886b,_0xaae130,_0x530cfb),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x11886b,'Reply...')),this['bind']('authoredAt')['to'](_0xaae130),this['bind']('resolvedAt')['to'](_0xaae130),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 _0x3be5f0(_0x11886b,_0xaae130['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0xaae130,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x30e4f5=this['bindTemplate'],_0x44b386=[{'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':_0x30e4f5['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x30e4f5['to']('authoredAt',_0x2a47b4=>this['_config']['formatDateTime'](_0x2a47b4))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x30e4f5['if']('isEditMode','ck-comment__actions--hidden'),_0x30e4f5['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']&&_0x44b386['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x30e4f5['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x30e4f5['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x30e4f5['if']('isEditMode','ck-comment--edit'),_0x30e4f5['if']('isSystemComment','ck-comment--info'),_0x30e4f5['to']('actionIndicator',_0x1044be=>_0x1044be?'ck-comment--'+_0x1044be:'')],'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':_0x44b386}]}]};}['_createEditButton'](){const _0x2f03d6=new _0x3c4ac3(this['locale']);return _0x2f03d6['label']=N(this['locale'],'Edit'),_0x2f03d6['icon']=_0x1747b0,_0x2f03d6['withText']=!0x0,_0x2f03d6['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x2f03d6['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x469748=>!_0x469748),_0x2f03d6['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x2f03d6['on']('execute',()=>this['switchToEditMode']()),_0x2f03d6;}['_createRemoveButton'](){const _0x5cfd58=new _0x3c4ac3(this['locale']);return _0x5cfd58['label']=N(this['locale'],'Remove'),_0x5cfd58['icon']=_0x28f460,_0x5cfd58['withText']=!0x0,_0x5cfd58['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x5cfd58['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x598ca7=>!_0x598ca7),_0x5cfd58['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x5cfd58['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x5cfd58;}['_createDropdown'](){const _0x5c8238=_0x53105e(this['locale'],_0x2fdf7f),_0x3ee5ee=_0x5c8238['panelView']['children'],_0x3e8178=new _0xfedfda(this['locale']),_0x4b5b54=_0x5c8238['bindTemplate'];_0x5c6167(_0x5c8238,()=>this['items']['find'](_0x490458=>_0x490458['isVisible'])),_0x5c8238['extendTemplate']({'attributes':{'class':[_0x4b5b54['if']('isVisible','ck-hidden',_0x2d98b0=>!_0x2d98b0)]}});const _0x1bb74a=(_0x323391,_0x4761e0=-0x1)=>{const _0x3d9dc7=new _0x287548(this['locale']);_0x3d9dc7['children']['add'](_0x323391);const _0x23eed0=_0x4761e0>-0x1?_0x4761e0:_0x3e8178['items']['length'];_0x3e8178['items']['add'](_0x3d9dc7,_0x23eed0);const _0x3a8726=Array['from'](this['items']);_0x5c8238['unbind']('isEnabled','isVisible'),_0x5c8238['bind']('isEnabled')['toMany'](_0x3a8726,'isEnabled',(..._0x43cad9)=>_0x43cad9['some'](_0x4e8faf=>_0x4e8faf)),_0x5c8238['bind']('isVisible')['toMany'](_0x3a8726,'isVisible',(..._0x164b58)=>_0x164b58['some'](_0x5a6393=>_0x5a6393));};_0x5c8238['panelPosition']='sw',_0x5c8238['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x508d6d});for(const _0x57bb57 of this['items'])_0x1bb74a(_0x57bb57);return _0x3ee5ee['add'](_0x3e8178),_0x5c8238['listenTo'](this['items'],'add',(_0x34e350,_0x562513,_0x11fa4c)=>{_0x1bb74a(_0x562513,_0x11fa4c);}),_0x5c8238['listenTo'](this['items'],'remove',(_0xf8240a,_0xadbcf2,_0x2ae508)=>{_0x3e8178['items']['remove'](_0x2ae508);}),_0x5c8238;}['_attachActions'](_0x94daa6,_0x290d75){const _0x1f07ce=_0x94daa6&&_0x94daa6['element'];_0x1f07ce&&(this['listenTo'](_0x1f07ce,'mouseenter',()=>this['actionIndicator']=_0x290d75),this['listenTo'](_0x1f07ce,'focus',()=>this['actionIndicator']=_0x290d75),this['listenTo'](_0x1f07ce,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x1f07ce,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0xcaa048=super['_createCommentInputView']();return _0xcaa048['bind']('placeholder')['to'](this),_0xcaa048;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x5a311d){const _0x2d813e=Dt(_0x5a311d,0x1e),_0x446b3a=new MutationObserver(_0x58acd3=>{for(const _0x11fe01 of _0x58acd3)('attributes'==_0x11fe01['type']&&'class'==_0x11fe01['attributeName']||'childList'==_0x11fe01['type']||'characterData'==_0x11fe01['type'])&&_0x2d813e();});return{'attach'(_0x27c66c){_0x446b3a['observe'](_0x27c66c,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x446b3a['disconnect'](),_0x2d813e['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x47e1bb,_0x302309){super(_0x47e1bb),this['id']=_0x2388d3(),this['focusTracker']=new _0x19913b(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x334494,_0x2b3b1c)=>this['fire']('Esc',_0x2b3b1c)),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'](_0x302309),this['mainView']=_0x302309;const _0x294812=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x294812['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 _0x595e01=this['element']['clientHeight'];_0x595e01&&(this['height']=_0x595e01);}}class T extends/* #__PURE__ -- @preserve */
29
+ _0x2f7441(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x379c36,target:_0x459357,type:_0x1c7bd2,isVisible:_0x5ed618=!0x0}){super(),this['view']=_0x379c36,this['view']['element']||this['view']['render'](),this['_type']=_0x1c7bd2,this['_target']=_0x459357,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x2a8245([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x4fe7ee,_0x56dbae)=>{this['view']['focusTracker']['add'](_0x56dbae);}),this['focusableElements']['on']('remove',(_0x11c5bc,_0x4a1270)=>{this['view']['focusTracker']['remove'](_0x4a1270);}),this['set']('isVisible',_0x5ed618);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x3388e0=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x3388e0),_0x3388e0;}get['targetRect'](){const _0x38b9f1=this['target'];if(null===_0x38b9f1)return null;if(_0x38b9f1 instanceof _0x3fbc4e)return _0x38b9f1;const _0x1209f3=_0x38b9f1['filter'](_0x4de2ca=>function(_0x5053fe){const _0x31fd98=_0x5053fe['offsetParent'];if(_0x31fd98)return!0x0;const _0x5a7558=_0x5053fe['getClientRects']()['item'](0x0);return!!_0x5a7558;}(_0x4de2ca));return 0x0===_0x1209f3['length']?null:new _0x3fbc4e(_0x1209f3[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x30ee53){this['view']['isActive']=_0x30ee53,this['view']['mainView']['isActive']=_0x30ee53;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0xfdbe9c){if(!(null===_0xfdbe9c||_0xfdbe9c instanceof _0x3fbc4e||Array['isArray'](_0xfdbe9c)&&_0xfdbe9c['every'](_0x41e58f=>fi(_0x41e58f))))throw new _0x2e6f8f('annotation-invalid-target',null,{'target':_0xfdbe9c});}['_getNormalizedTarget'](){const _0x2101d9='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0x2101d9)?[_0x2101d9]:_0x2101d9;}}function fi(_0xb37bda){return null!==_0xb37bda&&'object'==typeof _0xb37bda&&'nodeType'in _0xb37bda&&0x1===_0xb37bda['nodeType'];}class S extends _0x2a8245{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x3ebd06=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x19913b(),this['_focusTracker']['on']('change:isFocused',(_0x155df6,_0x52c8d2,_0x5a3a90)=>{_0x5a3a90||this['fire']('blur');});for(const _0x49663b of _0x3ebd06)this['add'](_0x49663b);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0xdd3961){if(this['has'](_0xdd3961))throw new _0x2e6f8f('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0xdd3961['innerView'],_0xdd3961),this['_viewToAnnotation']['set'](_0xdd3961['view'],_0xdd3961);for(const _0x4d7062 of _0xdd3961['focusableElements'])this['_focusTracker']['add'](_0x4d7062);this['listenTo'](_0xdd3961['focusableElements'],'add',(_0xc13dc5,_0x3af9cc)=>{this['_focusTracker']['add'](_0x3af9cc);}),this['listenTo'](_0xdd3961['focusableElements'],'remove',(_0x4d90c7,_0x3a7138)=>{this['_focusTracker']['remove'](_0x3a7138);}),this['listenTo'](_0xdd3961['view']['focusTracker'],'change:isFocused',(_0x7dcc1f,_0xcbea1e,_0x4a8abb)=>{_0x4a8abb&&this['fire']('focus',_0xdd3961);}),_0xdd3961['updateTargetRect']();const _0xfbfdd3=this['_getOrderInContent'](_0xdd3961['view']['targetRect']);return super['add'](_0xdd3961,_0xfbfdd3);}['remove'](_0xed1a7d){if(!this['has'](_0xed1a7d))throw new _0x2e6f8f('annotationcollection-not-existing-item',null);this['stopListening'](_0xed1a7d['view']['focusTracker']),this['stopListening'](_0xed1a7d['focusableElements']);for(const _0x4d8d93 of _0xed1a7d['focusableElements'])this['_focusTracker']['remove'](_0x4d8d93);return this['_viewToAnnotation']['delete'](_0xed1a7d['view']),this['_innerViewToAnnotation']['delete'](_0xed1a7d['innerView']),super['remove'](_0xed1a7d);}['getByInnerView'](_0x31c0f6){return this['_innerViewToAnnotation']['get'](_0x31c0f6);}['getByView'](_0x19da9f){return this['_viewToAnnotation']['get'](_0x19da9f);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x16bc63 of this)_0x16bc63['updateTargetRect']();this['_sort']();}['_sort'](){const _0x5e7a2a=Array['from'](this)['sort']((_0x456c12,_0x4eddde)=>w(_0x456c12['view']['targetRect'],_0x4eddde['view']['targetRect']));for(let _0x3770d3=_0x5e7a2a['length']-0x1;_0x3770d3>0x0;_0x3770d3--){const _0x1e8e1e=_0x5e7a2a[_0x3770d3];_0x3770d3!==this['getIndex'](_0x1e8e1e)&&(this['remove'](_0x1e8e1e),this['add'](_0x1e8e1e));}}['_getOrderInContent'](_0x167685){let _0x2bc353=0x0;if(!_0x167685)return this['length'];for(const _0x219505 of this){const _0x3ebe42=_0x219505['view']['targetRect'];if(_0x3ebe42){if(w(_0x167685,_0x3ebe42)<0x0)return _0x2bc353;_0x2bc353++;}}return _0x2bc353;}}function v({source:_0x5cf0e4,target:_0x3e7858,filter:_0x2b4a8f}){for(const _0x8916e6 of _0x5cf0e4)_0x2b4a8f(_0x8916e6)&&_0x3e7858['add'](_0x8916e6);_0x3e7858['listenTo'](_0x5cf0e4,'add',(_0x28bcb8,_0xe60868)=>{_0x2b4a8f(_0xe60868)&&_0x3e7858['add'](_0xe60868);}),_0x3e7858['listenTo'](_0x5cf0e4,'remove',(_0x346e39,_0x208f4b)=>{_0x3e7858['has'](_0x208f4b)&&_0x3e7858['remove'](_0x208f4b);});}function w(_0x2e49a7,_0xcd13c6){if(null===_0x2e49a7&&null===_0xcd13c6)return 0x0;if(null===_0x2e49a7)return-0x1;if(null===_0xcd13c6)return 0x1;const _0x54329d=_0x2e49a7['top']-_0xcd13c6['top'];return 0x0==_0x54329d?_0x2e49a7['left']-_0xcd13c6['left']:_0x54329d;}class y extends _0x2228db{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x163f48){if(super(_0x163f48),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x163f48 instanceof _0x74e6ba){const _0x2d971b=_0x163f48['locale'];_0x163f48['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x2d971b,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x2144cb){this['collection']['add'](_0x2144cb);}['remove'](_0x22ed17){this['collection']['remove'](_0x22ed17),_0x22ed17['destroy']();}['refreshVisibility'](){for(const _0x422218 of this['collection'])_0x422218['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x32b724){return this['collection']['getByInnerView'](_0x32b724);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x16565c of this['collection'])_0x16565c['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x29897b){this['fire']('_activateAnnotation',_0x29897b);}['createAnnotation'](_0x17c1ec){return new T(_0x17c1ec);}['createAnnotationView'](_0x7bf4f6,_0x9808df){return new E(_0x7bf4f6,_0x9808df);}['_addActiveAnnotation'](_0x25f920){const _0x581995=new Set(this['activeAnnotations']);_0x581995['add'](_0x25f920),this['activeAnnotations']=_0x581995;}['_removeActiveAnnotation'](_0x156c75){const _0x2e85b2=new Set(this['activeAnnotations']);_0x2e85b2['delete'](_0x156c75),this['activeAnnotations']=_0x2e85b2;}['_bindAnnotationsToVisibleAnnotations'](){const _0xc12bce=this['collection'],_0x9d7908=this['_visibleAnnotations'];function _0x56fd56(_0x34188d){const _0x4149f6=_0x34188d['source'];_0x4149f6['isVisible']&&!_0x9d7908['has'](_0x4149f6)?_0x9d7908['add'](_0x4149f6):!_0x4149f6['isVisible']&&_0x9d7908['has'](_0x4149f6)&&_0x9d7908['remove'](_0x4149f6),_0x4149f6['view']['focusTracker']['remove'](_0x4149f6['view']['element']),_0x4149f6['view']['focusTracker']['add'](_0x4149f6['view']['element']);}this['listenTo'](_0xc12bce,'add',(_0x410ae1,_0x3855c8)=>{_0x3855c8['isVisible']&&_0x9d7908['add'](_0x3855c8),this['listenTo'](_0x3855c8,'change:isVisible',_0x56fd56);}),this['listenTo'](_0xc12bce,'remove',(_0x21c20b,_0x4166b7)=>{_0x9d7908['has'](_0x4166b7)&&_0x9d7908['remove'](_0x4166b7),this['stopListening'](_0x4166b7,'change:isVisible',_0x56fd56);});}['_setupEnterAnnotationKeystroke'](){const _0x5744a8=_0x5cc570=>{_0x5cc570['on']('ready',()=>{_0x5cc570['keystrokes']['set'](_0x4ddf4f,(_0x31d67c,_0x2083c5)=>{const _0x2097f8=_0x4dfbcc(this['activeAnnotations']['values']());_0x2097f8&&(_0x2097f8['view']['focus'](),_0x2083c5());});});};this['context']instanceof _0x74e6ba?_0x5744a8(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x30b874,_0x53a79c)=>{_0x5744a8(_0x53a79c);});}['_setupEscapeAnnotationHandling'](){const _0x2a9c18=_0x24c33a=>{const _0x3519e7=_0x24c33a['source'],_0x1ed572=[];let _0x313c92;if(Array['isArray'](_0x3519e7['target'])){_0x313c92=_0x3519e7['target'][0x0],this['context']instanceof _0x74e6ba?_0x1ed572['push'](this['context']):this['context']['editors']&&_0x1ed572['push'](...this['context']['editors']);for(const _0x397cbf of _0x1ed572)for(const _0x35c87f of _0x397cbf['editing']['view']['domRoots']['values']())if(_0x35c87f['contains'](_0x313c92))return void _0x397cbf['editing']['view']['focus']();_0x313c92['focus']();}};this['listenTo'](this['collection'],'add',(_0x342612,_0x31877d)=>{this['listenTo'](_0x31877d,'escape',_0x2a9c18,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x459451,_0x237508)=>{this['stopListening'](_0x237508,'escape',_0x2a9c18);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x2228db{['_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(_0x2f6094){super(_0x2f6094),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x580000=this['context']['config'];_0x580000['define']('comments.maxCommentsWhenCollapsed',0x2),_0x580000['define']('comments.maxThreadTotalWeight',0x1f4),_0x580000['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x580000['define']('comments.CommentThreadView',gt),_0x580000['define']('comments.CommentView',Tt),_0x580000['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x217a0a=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x2c43ed,_0x164ba8)=>this['_addCommentThread'](_0x164ba8)),this['on']('submitCommentThread',(_0x59c2e3,_0x5980fb)=>this['_submitCommentThread'](_0x5980fb)),this['on']('resolveCommentThread',(_0x5e602f,_0x47e127)=>this['_resolveCommentThread'](_0x47e127)),this['on']('resolveCommentThread',(_0x4c93b2,_0x49a4ee)=>this['_updateActiveAnnotation'](_0x49a4ee),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x141eca,_0x12a5b8)=>this['_reopenCommentThread'](_0x12a5b8)),this['on']('reopenCommentThread',(_0x4afc7c,_0x29d1c8)=>this['_updateActiveAnnotation'](_0x29d1c8),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x167922,_0x2efdf7)=>this['_removeCommentThread'](_0x2efdf7)),this['on']('updateCommentThread',(_0x38474d,_0x3c4a6a)=>this['_updateCommentThread'](_0x3c4a6a)),this['on']('updateCommentThread',(_0x204d47,_0x280f8f)=>this['_updateActiveAnnotation'](_0x280f8f),{'priority':'lowest'}),this['on']('addComment',(_0xfeb222,_0x5be59e)=>this['_addComment'](_0x5be59e)),this['on']('updateComment',(_0x5b442a,_0x4ecab7)=>this['_updateComment'](_0x4ecab7)),this['on']('removeComment',(_0x5f3ddd,_0x24a2e0)=>this['_removeComment'](_0x24a2e0)),this['on']('addComment',(_0x2b5204,{threadId:_0x1abb7d,isFromAdapter:_0xfac848})=>{if(_0xfac848)return;const _0xf358ab=this['getCommentThread'](_0x1abb7d),_0x33e281=_0xf358ab&&this['_threadToController']['get'](_0xf358ab);_0x33e281&&_0x33e281['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x217a0a,'change:activeAnnotations',(_0xf301c7,_0x5af6af,_0x2398f1)=>{const _0x20569d=Array['from'](_0x2398f1)['map'](_0x4626b5=>this['_viewToController']['get'](_0x4626b5['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x20569d?_0x20569d['model']:null;});}set['adapter'](_0x51a67b){if(this['_adapter'])throw new _0x2e6f8f('commentsrepository-adapter-already-set');this['_adapter']=_0x51a67b;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x2063b6=_t,threadId:_0x5656b0=_0x2388d3(),comments:_0x3d3baf=[],unlinkedAt:_0x3737bc=null,resolvedAt:_0x113b35=null,resolvedBy:_0x1c7b6f=null,target:_0x5b6933=null,context:_0x445a4d=null,attributes:_0x49fb63={},isResolvable:_0x3049e1=!0x0,isSubmitted:_0x362e75=!0x1,isFromAdapter:_0x1b5869=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x2063b6),{'channelId':_0x2063b6,'threadId':_0x5656b0,'comments':_0x3d3baf,'unlinkedAt':_0x3737bc,'resolvedAt':_0x113b35,'resolvedBy':_0x1c7b6f,'target':_0x5b6933,'context':_0x445a4d,'attributes':_0x49fb63,'isFromAdapter':_0x1b5869,'isResolvable':_0x3049e1,'isSubmitted':_0x362e75}),this['getCommentThread'](_0x5656b0);}['openNewCommentThread']({channelId:_0x29c7c9=_t,threadId:_0x5d07d5=_0x2388d3(),target:_0x20a21a,context:_0x58c33d=null,isResolvable:_0x4f4ce6=!0x0}){if(this['_readOnlyChannels']['has'](_0x29c7c9)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x20a21a)throw new _0x2e6f8f('commentsrepository-missing-target');const _0xc153b6=this['addCommentThread']({'channelId':_0x29c7c9,'threadId':_0x5d07d5,'target':_0x20a21a,'context':_0x58c33d,'isResolvable':_0x4f4ce6});if(!_0xc153b6)return null;const _0x3c98b0=this['_threadToController']['get'](_0xc153b6),_0x2b22eb=_0x3c98b0['view']['commentThreadInputView']['commentInputView'],_0x306fe9=this['context']['plugins']['get'](y),_0x2202b6=_0x306fe9['getByInnerView'](_0x3c98b0['view']);return _0x306fe9['activate'](_0x2202b6),_0x2b22eb['once']('editorReady',()=>_0x2b22eb['focus']()),_0xc153b6;}['hasCommentThread'](_0x435373){if('string'!=typeof _0x435373)throw new _0x2e6f8f('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x435373);}['updateCommentThread']({channelId:_0x50c285=_t,threadId:_0xf9184e,context:_0x442628,unlinkedAt:_0xcd1a37,attributes:_0x4179ec,isFromAdapter:_0x10c4b8=!0x1}){return this['fire'](Nt('updateCommentThread',_0x50c285),{'channelId':_0x50c285,'threadId':_0xf9184e,'context':_0x442628,'unlinkedAt':_0xcd1a37,'attributes':_0x4179ec,'isFromAdapter':_0x10c4b8}),this['getCommentThread'](_0xf9184e);}['getCommentThread'](_0x18fcb3){if('string'!=typeof _0x18fcb3)throw new _0x2e6f8f('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x18fcb3);}['fetchCommentThread']({channelId:_0x50c03a,threadId:_0x4c919c}={}){const _0x5d9369=this['getCommentThread'](_0x4c919c);if(_0x5d9369)return Promise['resolve'](_0x5d9369);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x2e6f8f('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x50c03a,'threadId':_0x4c919c})['then'](_0x3c9795=>this['hasCommentThread'](_0x4c919c)?this['getCommentThread'](_0x4c919c):_0x3c9795?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x50c03a},_0x3c9795)):void 0x0)['catch'](_0x568634=>{throw console['error'](_0x568634),new _0x2e6f8f('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x4b3e59,skipNotAttached:_0x35981a=!0x1,skipEmpty:_0x1682e2=!0x1,toJSON:_0x281d9e=!0x1}={}){const _0x33ad7d=[];for(const _0x959a1f of this['_threads']['values']())_0x4b3e59&&_0x959a1f['channelId']!==_0x4b3e59||_0x35981a&&!_0x959a1f['isAttached']||_0x1682e2&&0x0===_0x959a1f['length']||_0x33ad7d['push'](_0x959a1f);return _0x281d9e?_0x33ad7d['map'](_0xe9e23=>_0xe9e23['toJSON']()):_0x33ad7d;}['getAnnotationForCommentThread'](_0x42b34a){const _0xa081f0=this['_threadToController']['get'](_0x42b34a);if(!_0xa081f0)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0xa081f0['view'])||null;}['getCommentThreadForAnnotation'](_0x533537){const _0x22e196=this['_viewToController']['get'](_0x533537['innerView']);return _0x22e196?_0x22e196['model']:null;}['setActiveCommentThread'](_0x4b02e5){const _0x36697a=this['context']['plugins']['get'](y);if(!_0x4b02e5)return void(this['activeCommentThread']&&_0x36697a['deactivateAll']());const _0x350d4e=this['getCommentThread'](_0x4b02e5);if(!_0x350d4e)throw new _0x2e6f8f('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x4b02e5});if(!this['_threadToController']['has'](_0x350d4e))throw new _0x2e6f8f('commentsrepository-active-not-attached',null,{'threadId':_0x4b02e5});const _0x4ffcbc=_0x36697a['getByInnerView'](this['_threadToController']['get'](_0x350d4e)['view']);_0x36697a['activate'](_0x4ffcbc);}['switchReadOnly'](_0x33b539,_0x387d27){_0x33b539?this['_readOnlyChannels']['add'](_0x387d27):this['_readOnlyChannels']['delete'](_0x387d27),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x33fc3f){return this['_readOnlyChannels']['has'](_0x33fc3f)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x35d8c0,_0x5c4967){return new vt(_0x35d8c0,_0x5c4967);}['setPermissions'](_0xad6efe,_0x9754dd=_t){this['_permissions']['set'](_0x9754dd,_0xad6efe),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x2399c4=_t){return this['_permissions']['has'](_0x2399c4)?this['_permissions']['get'](_0x2399c4):bt;}['_addCommentThread']({channelId:_0x14709e,threadId:_0x1583bb,comments:_0x111653,unlinkedAt:_0x16b923,resolvedAt:_0x31ebd3,resolvedBy:_0xba6b7a,target:_0x177031,context:_0x620bc8,attributes:_0x191ca8,isFromAdapter:_0x4451b4,isResolvable:_0x36cd7b,isSubmitted:_0x38310b}){if('string'!=typeof _0x1583bb)throw new _0x2e6f8f('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x1583bb});if(this['hasCommentThread'](_0x1583bb))throw new _0x2e6f8f('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x1583bb});const _0x64cdfd=new pi(this,{'channelId':_0x14709e,'id':_0x1583bb,'context':_0x620bc8,'attributes':_0x191ca8,'unlinkedAt':_0x16b923,'resolvedAt':_0x31ebd3,'resolvedBy':_0xba6b7a?this['context']['plugins']['get'](it)['getUser'](_0xba6b7a):null,'isResolvable':_0x36cd7b,'isSubmitted':_0x38310b||_0x4451b4});this['_threads']['set'](_0x1583bb,_0x64cdfd);for(const _0x4536c7 of _0x111653)_0x64cdfd['_add'](this['_createNewComment']({'threadId':_0x1583bb,..._0x4536c7}));return _0x177031&&_0x64cdfd['attachTo'](_0x177031),_0x4451b4||!_0x64cdfd['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x14709e,'threadId':_0x1583bb});}['_submitCommentThread']({channelId:_0x111a51,threadId:_0x4f636a}){if(!this['hasCommentThread'](_0x4f636a))throw new _0x2e6f8f('commentsrepository-missing-comment-thread',this);const _0x5159cf=this['getCommentThread'](_0x4f636a);if(_0x5159cf['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x4b98e1,comments:_0x4e0c5e,resolvedAt:_0x3a5f23,resolvedBy:_0x56f025,context:_0x90e2c9,attributes:_0x4e2a7b}=_0x5159cf,_0x34b143=this['context']['plugins']['get']('PendingActions'),_0x3fcecf=_0x34b143['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x111a51,'threadId':_0x4b98e1,'comments':_0x4e0c5e['map'](_0x253fc3=>_0x253fc3['toJSON']()),'resolvedAt':_0x3a5f23,'resolvedBy':_0x56f025?_0x56f025['id']:_0x56f025,'context':_0x90e2c9,'attributes':_0x4e2a7b})['then'](({comments:_0x4a8a5d})=>{_0x34b143['remove'](_0x3fcecf);for(const _0x5bff2d of _0x4a8a5d)this['_updateComment']({'channelId':_0x111a51,'threadId':_0x4f636a,'commentId':_0x5bff2d['commentId'],'createdAt':_0x5bff2d['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x235a83=>{throw console['error'](_0x235a83),new _0x2e6f8f('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x416f23,target:_0x3e2706}){const _0x4634e=this['getCommentThread'](_0x416f23);if(!_0x4634e)throw new _0x2e6f8f('commentsrepository-attach-missing-comment-thread',this);const _0x3e7269=this['context']['plugins']['get']('PendingActions'),_0x517323=this['context']['plugins']['get'](y),_0x3ebabd=this['_createCommentThreadView'](_0x4634e),_0x425138=new vt(_0x4634e,_0x3ebabd);let _0x5789d7=null;_0x3ebabd['on']('change:isDirty',(_0x48dd8a,_0x4f5cdd,_0x4172e0)=>{_0x4172e0?_0x5789d7=_0x3e7269['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x5789d7&&(_0x3e7269['remove'](_0x5789d7),_0x5789d7=null);}),this['_threadToController']['set'](_0x4634e,_0x425138),this['_viewToController']['set'](_0x3ebabd,_0x425138);const _0x3dc0a3=new E(this['context']['locale'],_0x3ebabd);_0x3dc0a3['bind']('length')['to'](_0x3ebabd),_0x3dc0a3['bind']('isDirty')['to'](_0x3ebabd,'isDirty',_0x3ebabd,'length',(_0x8e923a,_0x2c2274)=>_0x8e923a||!_0x2c2274),_0x3dc0a3['bind']('isActive')['to'](_0x3ebabd),_0x3dc0a3['type']='comment';const _0x4c7da8=new T({'view':_0x3dc0a3,'target':_0x3e2706,'type':'comment','isVisible':!_0x4634e['archivedAt']&&!!('function'==typeof _0x3e2706?_0x3e2706():_0x3e2706)});return _0x3ebabd['on']('escape',()=>{_0x4c7da8['fire']('escape');}),this['_bindAnnotationToEditors'](_0x3ebabd,_0x4c7da8),_0x517323['add'](_0x4c7da8),_0x4c7da8;}['_bindAnnotationToEditors'](_0xf0f272,_0x5b56a6){this['listenTo'](_0xf0f272,'editorReady',(_0x133be8,_0x119bfc)=>{const _0x560a3e=_0x119bfc['ui']['view']['body']['bodyCollectionContainer'];_0x5b56a6['focusableElements']['add'](_0x560a3e),this['context']instanceof _0x74e6ba&&this['context']['ui']['focusTracker']['add'](_0x560a3e);},{'priority':'highest'}),this['listenTo'](_0xf0f272,'editorDestroyed',(_0x239554,_0x338213)=>{const _0x179494=_0x338213['ui']['view']['body']['bodyCollectionContainer'];_0x5b56a6['focusableElements']['has'](_0x179494)&&_0x5b56a6['focusableElements']['remove'](_0x179494),this['context']instanceof _0x74e6ba&&this['context']['ui']['focusTracker']['remove'](_0x179494);});}['_unbindEditors'](_0x463ee5){this['stopListening'](_0x463ee5,'editorReady'),this['stopListening'](_0x463ee5,'editorDestroyed');}['_createCommentThreadView'](_0x36a39c){const _0x1fc30e=this['context']['plugins']['get'](it),{config:_0x23cb62,locale:_0x6e8d47}=this['context'],_0xf8ccc6=pt(_0x23cb62['get']('locale'),_0x6e8d47);return new(0x0,(_0x23cb62['get']('comments'))['CommentThreadView'])(_0x6e8d47,_0x36a39c,_0x1fc30e['me'],{'editorConfig':{..._0x23cb62['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x23cb62['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x23cb62['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x23cb62['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x23cb62['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0xf8ccc6,'CommentView':_0x23cb62['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x29b360,channelId:_0x42c4eb,resolvedAt:_0x114622,resolvedBy:_0x15ca86,isFromAdapter:_0x503ed8}){if(!this['hasCommentThread'](_0x29b360))throw new _0x2e6f8f('commentsrepository-missing-comment-thread',null,{'threadId':_0x29b360});const _0x49feec=this['getCommentThread'](_0x29b360);if(_0x49feec['isResolved'])throw new _0x2e6f8f('commentsrepository-resolved-comment-thread',null,{'threadId':_0x29b360});const _0x9018f0=this['context']['plugins']['get'](it);if(_0x49feec['resolvedBy']=_0x9018f0['getUser'](_0x15ca86),_0x49feec['resolvedAt']=_0x114622,_0x503ed8||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x385e69=this['context']['plugins']['get']('PendingActions'),_0x2b4f69=_0x385e69['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x42c4eb,'threadId':_0x29b360})['then'](({resolvedAt:_0x5ced5e,resolvedBy:_0xbeb7b4})=>{_0x385e69['remove'](_0x2b4f69),_0x49feec['resolvedBy']['id']!==_0xbeb7b4&&(_0x49feec['resolvedBy']=_0x9018f0['getUser'](_0xbeb7b4)),_0x49feec['resolvedAt']=_0x5ced5e;})['catch'](_0x2faad0=>{throw console['error'](_0x2faad0),new _0x2e6f8f('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x2e5149,channelId:_0x574417,isFromAdapter:_0x475b6e}){if(!this['hasCommentThread'](_0x2e5149))throw new _0x2e6f8f('commentsrepository-missing-comment-thread',null,{'threadId':_0x2e5149});const _0x46b781=this['getCommentThread'](_0x2e5149);if(!_0x46b781['isResolved'])throw new _0x2e6f8f('commentsrepository-reopen-comment-thread',null,{'threadId':_0x2e5149});if(_0x46b781['resolvedBy']=null,_0x46b781['resolvedAt']=null,_0x475b6e||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x3b1c40=this['context']['plugins']['get']('PendingActions'),_0xb88f83=_0x3b1c40['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x574417,'threadId':_0x2e5149})['then'](()=>_0x3b1c40['remove'](_0xb88f83))['catch'](_0x91cd6e=>{throw console['error'](_0x91cd6e),new _0x2e6f8f('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x49f204,isFromAdapter:_0x330e35}){const _0x3fb527=this['getCommentThread'](_0x49f204);if(!_0x3fb527)throw new _0x2e6f8f('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x49f204),this['_threads']['delete'](_0x49f204),!_0x3fb527['isSubmitted']||_0x330e35||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x1b2821=this['context']['plugins']['get']('PendingActions'),{channelId:_0x417af2}=_0x3fb527,_0x39573c=_0x1b2821['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x417af2,'threadId':_0x49f204})['then'](()=>_0x1b2821['remove'](_0x39573c))['catch'](_0x341fb8=>{throw console['error'](_0x341fb8),new _0x2e6f8f('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x4d56d0,unlinkedAt:_0x4d839c,context:_0x2a7341,attributes:_0x38a92a,isFromAdapter:_0x55f244}){if('string'!=typeof _0x4d56d0)throw new _0x2e6f8f('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x4d56d0});if(!this['hasCommentThread'](_0x4d56d0))throw new _0x2e6f8f('commentsrepository-missing-comment-thread',null,{'threadId':_0x4d56d0});const _0x6c5797=this['getCommentThread'](_0x4d56d0);let _0x3c4a7a=!0x1;if(void 0x0!==_0x2a7341&&_0x6c5797['context']!==_0x2a7341&&(_0x6c5797['context']=_0x2a7341,_0x3c4a7a=!0x0),void 0x0!==_0x4d839c&&_0x6c5797['unlinkedAt']!==_0x4d839c&&(_0x6c5797['unlinkedAt']=_0x4d839c,_0x3c4a7a=!0x0),_0x38a92a&&!At(_0x38a92a,_0x6c5797['attributes'])&&(_0x6c5797['attributes']=_0x38a92a,_0x3c4a7a=!0x0),!_0x3c4a7a)return Promise['resolve']();if(!_0x6c5797['isSubmitted']||_0x55f244||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x2264ed=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5276e6}=_0x6c5797,_0x102400=_0x2264ed['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x5276e6,'threadId':_0x4d56d0,'context':_0x2a7341,'unlinkedAt':_0x4d839c,'attributes':_0x38a92a})['then'](()=>_0x2264ed['remove'](_0x102400))['catch'](_0x469c36=>{throw console['error'](_0x469c36),new _0x2e6f8f('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x31feae){const _0x4489d4=this['context']['plugins']['get'](y),_0x4a3a23=this['getCommentThread'](_0x31feae);if(_0x4a3a23['_isAttached']=!0x1,this['_threadToController']['has'](_0x4a3a23)){const _0x32cd10=this['_threadToController']['get'](_0x4a3a23),_0x301dbe=_0x32cd10['view'],_0x4ee05e=_0x4489d4['getByInnerView'](_0x301dbe);this['_threadToController']['delete'](_0x4a3a23),this['_viewToController']['delete'](_0x301dbe),_0x4ee05e&&_0x4489d4['remove'](_0x4ee05e),_0x32cd10['destroy'](),_0x301dbe['destroy']()['then'](()=>{this['_unbindEditors'](_0x301dbe);});}}['_updateActiveAnnotation']({threadId:_0x5628fa,resolvedAt:_0x14f0a9,unlinkedAt:_0x484335}){const _0x443d25=!!_0x14f0a9,_0x1cb9aa=this['context']['plugins']['get'](y),_0x35a974=this['getCommentThread'](_0x5628fa);if(this['_threadToController']['has'](_0x35a974)){const _0x46916c=this['_threadToController']['get'](_0x35a974)['view'],_0xb3d785=_0x1cb9aa['getByInnerView'](_0x46916c);_0xb3d785&&(_0x443d25&&_0x1cb9aa['_removeActiveAnnotation'](_0xb3d785),_0x484335?_0xb3d785['isVisible']=!0x1:_0xb3d785['refreshVisibility']());}}['_getExternalAuthor'](_0x41124f){const _0x1aadbe=this['context']['plugins']['get'](it),_0x9f0563=It('external:'+_0x41124f),_0x116c1a=_0x1aadbe['getUser'](_0x9f0563);return _0x116c1a||_0x1aadbe['addUser']({'id':_0x9f0563,'name':_0x41124f});}['_createNewComment']({threadId:_0x1815b0,commentId:_0x54ed88=_0x2388d3(),content:_0x9dde95,authorId:_0x826325,createdAt:_0x4048c8,attributes:_0x110f5f}){if('string'!=typeof _0x54ed88)throw new _0x2e6f8f('commentsrepository-invalid-commentid');if('string'!=typeof _0x826325)throw new _0x2e6f8f('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x9dde95||!_0x9dde95['trim']())throw new _0x2e6f8f('commentsrepository-invalid-comment-content');const _0x10a2e0=this['context']['plugins']['get'](it)['getUser'](_0x826325);if(!_0x10a2e0)throw new _0x2e6f8f('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x826325});let _0x4adf45=null,_0x3eb132=_0x4048c8;return _0x110f5f?.['@external']&&(_0x4adf45=this['_getExternalAuthor'](_0x110f5f['@external']['authorName']),_0x3eb132=new Date(_0x110f5f['@external']['createdAt'])),new wi(this,{'threadId':_0x1815b0,'id':_0x54ed88,'author':_0x4adf45||_0x10a2e0,'creator':_0x10a2e0,'content':_0x9dde95,'createdAt':_0x4048c8,'authoredAt':_0x3eb132,'attributes':_0x110f5f});}['_addComment'](_0x1da4eb){let {threadId:_0x137710,content:_0x182919,attributes:_0x5214dd,isFromAdapter:_0x40c52b}=_0x1da4eb;const _0x23198c=this['getCommentThread'](_0x1da4eb['threadId']);if(!_0x23198c)throw new _0x2e6f8f('commentsrepository-add-comment-to-missing-comment-thread',this);const _0xd726cd=this['_createNewComment'](_0x1da4eb),{id:_0x411d26}=_0xd726cd;if(_0x23198c['_add'](_0xd726cd),_0x40c52b||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x23198c['isSubmitted'])return Promise['resolve']();const _0x1bb58a=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5d3323}=_0x23198c,_0x55f1a8=_0x1bb58a['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x5214dd||(_0x5214dd={}),this['adapter']['addComment']({'channelId':_0x5d3323,'threadId':_0x137710,'commentId':_0x411d26,'content':_0x182919,'attributes':_0x5214dd})['then'](_0x678a73=>{_0x1bb58a['remove'](_0x55f1a8),_0x678a73&&this['_updateComment']({'channelId':_0x5d3323,'threadId':_0x137710,'commentId':_0x411d26,'createdAt':_0x678a73['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x17d69e=>{throw console['error'](_0x17d69e),new _0x2e6f8f('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x16f14b,commentId:_0x5ba669,content:_0x3edd23,createdAt:_0x29be55,attributes:_0x444275,isFromAdapter:_0x22fa23}){if(void 0x0!==_0x3edd23&&('string'!=typeof _0x3edd23||!_0x3edd23['trim']()['length']))throw new _0x2e6f8f('commentsrepository-update-comment-invalid-content');const _0x1182ad=this['getCommentThread'](_0x16f14b),_0x785633=_0x1182ad['getComment'](_0x5ba669);if(!_0x785633)throw new _0x2e6f8f('commentsrepository-update-missing-comment',this);let _0x2ce331=!0x1;if(_0x3edd23&&_0x3edd23!==_0x785633['content']&&(_0x785633['isEditable']||_0x22fa23)&&(_0x785633['content']=_0x3edd23,_0x2ce331=!0x0),_0x29be55&&_0x29be55!==_0x785633['createdAt']&&(_0x785633['createdAt']=_0x29be55,_0x785633['attributes']&&_0x785633['attributes']['@external']||(_0x785633['authoredAt']=_0x29be55),_0x2ce331=!0x0),_0x444275&&!At(_0x444275,_0x785633['attributes'])&&(_0x785633['attributes']=_0x444275,_0x2ce331=!0x0),!_0x2ce331)return Promise['resolve']();if(_0x1182ad['fire']('commentUpdated'),_0x22fa23||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x558d69=this['context']['plugins']['get']('PendingActions'),{channelId:_0x96bc44}=this['getCommentThread'](_0x785633['threadId']),_0xab0332=_0x558d69['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x96bc44,'threadId':_0x16f14b,'commentId':_0x5ba669,'content':_0x3edd23,'attributes':_0x444275})['then'](()=>_0x558d69['remove'](_0xab0332))['catch'](_0x14e0ca=>{throw console['error'](_0x14e0ca),new _0x2e6f8f('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x40f74e,commentId:_0x53c77e,isFromAdapter:_0x15df4e}){const _0x4a754a=this['getCommentThread'](_0x40f74e),_0x5b457d=_0x4a754a['getComment'](_0x53c77e);if(!_0x5b457d)throw new _0x2e6f8f('commentsrepository-remove-missing-comment',this);if(_0x4a754a['_remove'](_0x5b457d),_0x15df4e||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x4fb2c1=this['context']['plugins']['get']('PendingActions'),{channelId:_0x50068c}=_0x4a754a,_0x587969=_0x4fb2c1['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x50068c,'threadId':_0x40f74e,'commentId':_0x53c77e})['then'](()=>_0x4fb2c1['remove'](_0x587969))['catch'](_0xed74ef=>{throw console['error'](_0xed74ef),new _0x2e6f8f('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
+ _0x2f7441(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x4edec1,_0x171a94){super();const _0x3b8662=_0x171a94['isResolvable'];this['channelId']=_0x171a94['channelId'],this['id']=_0x171a94['id'],this['comments']=new _0x2a8245(),this['_repository']=_0x4edec1,this['_isAttached']=!0x1,this['_isSubmitted']=_0x171a94['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x4edec1,'_permissions',_0x4edec1,'_readOnlyChannels',()=>_0x4edec1['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x4edec1,'_permissions',()=>_0x4edec1['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x4edec1,'_permissions',()=>{const _0x17a44d=_0x4edec1['getPermissions'](this['channelId']);return _0x17a44d['write']||_0x17a44d['admin'];}),this['bind']('isResolvable')['to'](_0x4edec1,'_permissions',()=>_0x3b8662&&_0x4edec1['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x171a94['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x2d964a,_0x7d9a2b)=>_0x2d964a?_0x7d9a2b?_0x2d964a<_0x7d9a2b?_0x2d964a:_0x7d9a2b:_0x2d964a:_0x7d9a2b),this['set']('unlinkedAt',_0x171a94['unlinkedAt']||null),this['set']('resolvedAt',_0x171a94['resolvedAt']||null),this['set']('resolvedBy',_0x171a94['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x27468b=>!!_0x27468b),this['set']('attributes',_0x171a94['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x1bae46,_0x2fd13e)=>_0x1bae46+_0x2fd13e['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x19cc85,id:_0x5e1310}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x19cc85),{'channelId':_0x19cc85,'threadId':_0x5e1310});}['setUnlinkedAt'](_0x4fe559){this['_update']({'unlinkedAt':_0x4fe559});}['resolve']({resolvedAt:_0x337477=new Date(),resolvedBy:_0x121374=null,isFromAdapter:_0x2220a9=!0x1}={}){const _0x298797=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x5954ee,id:_0x2870df}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x5954ee),{'channelId':_0x5954ee,'threadId':_0x2870df,'resolvedAt':_0x337477,'resolvedBy':_0x121374||_0x298797['id'],'isFromAdapter':_0x2220a9});}['reopen']({isFromAdapter:_0x598589=!0x1}={}){const {channelId:_0x13d98c,id:_0x3c3e0e}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x13d98c),{'channelId':_0x13d98c,'threadId':_0x3c3e0e,'isFromAdapter':_0x598589});}['setContext'](_0xe219d6){this['context']||this['_update']({'context':_0xe219d6});}['setAttribute'](_0x558e21,_0x40072f){const _0x120f7a=wt(this['attributes']);yt(_0x120f7a,_0x558e21,_0x40072f),this['_update']({'attributes':_0x120f7a});}['removeAttribute'](_0x424ca9){const _0x4c4457=wt(this['attributes']);Ct(_0x4c4457,_0x424ca9),this['_update']({'attributes':_0x4c4457});}['remove']({isFromAdapter:_0x37258e=!0x1}={}){const {channelId:_0x34ec20,id:_0x2ffaf5}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x34ec20),{'channelId':_0x34ec20,'threadId':_0x2ffaf5,'isFromAdapter':_0x37258e});}['attachTo'](_0x24deed){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x24deed});}['addComment'](_0x43091a){const {channelId:_0x39686a,id:_0x382a73}=this;this['_repository']['fire'](Nt('addComment',_0x39686a,_0x382a73),Object['assign']({'channelId':_0x39686a,'threadId':_0x382a73},_0x43091a));}['getComment'](_0x405d2b){if('string'!=typeof _0x405d2b)throw new _0x2e6f8f('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x405d2b});return this['comments']['get'](_0x405d2b);}['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'](_0x24e28a=>_0x24e28a['toJSON']()),'attributes':this['attributes']};}['_add'](_0x1d9747){return this['listenTo'](_0x1d9747,'change:authoredAt',()=>{const _0x297d99=this['_findOptimalIndex'](_0x1d9747),_0x4bdf29=this['comments'];_0x297d99-0x1!=_0x4bdf29['getIndex'](_0x1d9747)&&_0x297d99+0x1!=_0x4bdf29['getIndex'](_0x1d9747)&&(this['_remove'](_0x1d9747),this['_add'](_0x1d9747));}),this['comments']['add'](_0x1d9747,this['_findOptimalIndex'](_0x1d9747));}['_update'](_0x55c355){const {channelId:_0x4d96d8,id:_0x3c2c69}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x4d96d8),{..._0x55c355,'channelId':_0x4d96d8,'threadId':_0x3c2c69});}['_remove'](_0x4c1a37){return this['stopListening'](_0x4c1a37),_0x4c1a37['destroy'](),this['comments']['remove'](_0x4c1a37);}['_findOptimalIndex'](_0x4fbf2c){const _0x4aa1a5=this['comments']['find'](_0x595921=>new Date(_0x595921['authoredAt'])['getTime']()>new Date(_0x4fbf2c['authoredAt'])['getTime']());return _0x4aa1a5?this['comments']['getIndex'](_0x4aa1a5):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
+ _0x2f7441(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x1bc3ae,_0x228c62){super();const _0x38a5b2=_0x1bc3ae['context']['plugins']['get'](it)['me'],_0x5cdba0=_0x1bc3ae['getCommentThread'](_0x228c62['threadId']),_0x339305=0x0===_0x5cdba0['comments']['length'],_0x535d2c=_0x38a5b2===_0x228c62['author'];this['id']=_0x228c62['id'],this['threadId']=_0x228c62['threadId'],this['author']=_0x228c62['author'],this['creator']=_0x228c62['creator'],this['isExternal']=Boolean(_0x228c62['attributes']&&_0x228c62['attributes']['@external']),this['set']('content',_0x228c62['content']),this['createdAt']=_0x228c62['createdAt']||new Date(),this['set']('authoredAt',_0x228c62['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x5cdba0,'resolvedAt'),this['set']('attributes',_0x228c62['attributes']||{}),this['bind']('isEditable')['to'](_0x1bc3ae,'_permissions',()=>{const _0xf6326a=_0x1bc3ae['getPermissions'](_0x5cdba0['channelId'])['write'],_0x20e579=_0x1bc3ae['getPermissions'](_0x5cdba0['channelId'])['modifyAll'];return _0x535d2c&&_0xf6326a||!_0x535d2c&&_0x20e579;}),this['bind']('isRemovable')['to'](_0x5cdba0,'isRemovable',_0x1bc3ae,'_permissions',_0x9f2867=>{const _0x2935e7=_0x1bc3ae['getPermissions'](_0x5cdba0['channelId'])['write'],_0x20929c=_0x1bc3ae['getPermissions'](_0x5cdba0['channelId'])['modifyAll'];return _0x535d2c&&_0x2935e7||_0x9f2867&&_0x339305||!_0x535d2c&&_0x20929c&&!_0x339305;}),this['bind']('isReadOnly')['to'](_0x5cdba0,'isReadOnly'),this['_repository']=_0x1bc3ae;}get['weight'](){return Math['max'](function(_0x5b9fce){const _0x5bb85c=document['createElement']('div');return _0x5bb85c['innerHTML']=_0x5b9fce,_0x5bb85c['textContent']['length'];}(this['content']),0xc8);}['update'](_0x34aadb){const {threadId:_0x511557,id:_0x6c0a99}=this;if(!this['_repository']['hasCommentThread'](_0x511557))throw new _0x2e6f8f('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x43a0e9}=this['_repository']['getCommentThread'](_0x511557);this['_repository']['fire'](Nt('updateComment',_0x43a0e9,_0x511557),{'channelId':_0x43a0e9,'threadId':_0x511557,'commentId':_0x6c0a99,..._0x34aadb});}['setAttribute'](_0x1fc197,_0x3f6947){const _0xbaa232=wt(this['attributes']);yt(_0xbaa232,_0x1fc197,_0x3f6947),this['update']({'attributes':_0xbaa232});}['removeAttribute'](_0x4ec170){const _0xc7c60=wt(this['attributes']);Ct(_0xc7c60,_0x4ec170),this['update']({'attributes':_0xc7c60});}['remove'](_0x34074b={}){if(!_0x34074b['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x689a42,id:_0x5e9539}=this;if(!this['_repository']['hasCommentThread'](_0x689a42))throw new _0x2e6f8f('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x25ebd2}=this['_repository']['getCommentThread'](_0x689a42);this['_repository']['fire'](Nt('removeComment',_0x25ebd2,_0x689a42),{'channelId':_0x25ebd2,'threadId':_0x689a42,'commentId':_0x5e9539,..._0x34074b});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x105475,..._0x1c5e1b){for(const _0x352ddf of _0x1c5e1b)void 0x0!==_0x352ddf&&(_0x105475+=':'+String(_0x352ddf));return _0x105475;}class ot extends _0x164c61{constructor(_0x5a0fc4){super(_0x5a0fc4),this['set']('hasContent',!0x1);}['refresh'](){const _0x24bb07=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x364255 of _0x24bb07['getRanges']())if(this['_hasContent'](_0x364255))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x5064b7=_0x2388d3(),ranges:_0xecfe57,comment:_0x7c4fa8}={}){const _0x15eb1c=this['editor']['model'],_0x4d9036=_0xecfe57??Array['from'](_0x15eb1c['document']['selection']['getRanges']()),_0x5c6439=[];for(const _0x193f9a of _0x4d9036)this['_hasContent'](_0x193f9a)&&_0x5c6439['push'](this['_trimToContent'](_0x193f9a));if(!_0x5c6439['length'])throw new _0x2e6f8f('addcommentthreadcommand-incorrect-ranges',null);_0x7c4fa8&&this['_createCommentThread'](_0x5064b7,_0x7c4fa8),this['_createMarkersFromRanges'](_0x5064b7,_0x5c6439,!!_0x7c4fa8);}['_createMarkersFromRanges'](_0x455ad0,_0x2330e8,_0x1b1ec0){this['editor']['model']['change'](_0x3ac4bd=>{for(const _0x3d137b of _0x2330e8){const _0x31fc54=_0x2388d3()['substr'](0x1,0x5),_0x2016e='comment:'+_0x455ad0+':'+_0x31fc54;_0x3ac4bd['addMarker'](_0x2016e,{'range':_0x3d137b,'usingOperation':_0x1b1ec0,'affectsData':_0x1b1ec0});}});}['_createCommentThread'](_0x113ee0,_0x2c7118){const _0x218300=this['editor']['plugins']['get']('CommentsRepository'),_0x3102de=this['editor']['config']['get']('collaboration.channelId'),_0x31ecd8=this['editor']['plugins']['get']('Users')['me'];if(!_0x31ecd8)throw new _0x2e6f8f('addcommentthreadcommand-user-not-found',null);_0x218300['addCommentThread']({'threadId':_0x113ee0,'channelId':_0x3102de,'comments':[{'authorId':_0x31ecd8['id'],'content':_0x2c7118,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x3a3908){for(const _0x413310 of _0x3a3908['getItems']())if(this['_itemIsContent'](_0x413310))return!0x0;return!0x1;}['_itemIsContent'](_0x4aa5e8){return _0x4aa5e8['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x4aa5e8)&&!_0x4aa5e8['is']('element','tableCell');}['_trimToContent'](_0x375212){const _0xcb8b46=_0x86f866=>!this['_itemIsContent'](_0x86f866['item']),_0x23c51b=_0x375212['start']['getLastMatchingPosition'](_0xcb8b46),_0x5d4cce=_0x375212['end']['getLastMatchingPosition'](_0xcb8b46,{'direction':'backward'});return this['editor']['model']['createRange'](_0x23c51b,_0x5d4cce);}}class b extends _0x41aca7{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x10c84f){super(_0x10c84f),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x1bcc99=this['editor'],_0x2d034b=_0x1bcc99['model']['document']['selection'],_0x5a63f3=_0x49b0b7(()=>this['refreshSelectedViews'](),0xa);_0x2d034b['on']('change:range',(_0x14e17d,_0x2d2364)=>{_0x2d2364['directChange']&&(_0x5a63f3['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x1bcc99['editing']['view']['document'],'change:isFocused',(_0x30c886,_0x595a4e,_0x327999)=>{_0x327999&&_0x5a63f3();}),this['listenTo'](_0x1bcc99['ui']['focusTracker'],'change:isFocused',(_0x7a0a5,_0x459cd9,_0x28bf53)=>{_0x28bf53||this['fire']('blur',{'isAnnotationTracked':_0x1f4231=>this['_editorAnnotationsData']['has'](_0x1f4231['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x3bd57a){if(this['_editorAnnotations']['has'](_0x3bd57a['view']))return;this['_editorAnnotations']['add'](_0x3bd57a['view']),this['editor']['ui']['focusTracker']['add'](_0x3bd57a['view']['element']);const _0x2b1919=this['editor']['plugins']['get'](y);this['listenTo'](_0x2b1919['collection'],'remove',(_0xcf22a0,_0x47644b)=>{this['editor']['ui']['focusTracker']['remove'](_0x47644b['view']['element']),this['_editorAnnotations']['delete'](_0x47644b['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x4c53e2){if('function'!=typeof _0x4c53e2)throw new _0x2e6f8f('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x4c53e2);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x575846,annotations:_0x3fe532}){const _0x3dd8b1=[],_0x52da32=this['editor']['model']['document']['selection'],_0x5f43d0=Array['from'](_0x52da32['getRanges']());for(const [_0x4a7781,_0x59dccc]of this['_editorAnnotationsData']){const _0x25c4a2=_0x3abf21(_0x59dccc),_0x2eace3=_0x3fe532['getByInnerView'](_0x4a7781);_0x25c4a2&&_0x2eace3&&_0x3dd8b1['push']({'annotation':_0x2eace3,'range':_0x25c4a2});}function _0x3abf21(_0x331cce){for(const _0x653715 of _0x331cce)for(const _0x3a8738 of _0x5f43d0)if(_0x653715['containsRange'](_0x3a8738,!_0x52da32['isCollapsed']))return _0x653715;return null;}return _0x3dd8b1['sort']((_0xd67d1e,_0x50adcb)=>{const _0x219fc0=_0xd67d1e['range'],_0x72b8e=_0x50adcb['range'];if(!_0x219fc0['isEqual'](_0x72b8e)){if(_0x219fc0['containsRange'](_0x72b8e,!0x0))return 0x1;if(_0x72b8e['containsRange'](_0x219fc0,!0x0))return-0x1;}return _0xd67d1e['annotation']==_0x575846?-0x1:_0x50adcb['annotation']==_0x575846?0x1:0x0;})['map'](_0x3a91c7=>_0x3a91c7['annotation']);}get['_editorAnnotationsData'](){const _0x3aa83a=new Map();for(const _0x1b9333 of Array['from'](this['_dataCollectors']))for(const [_0x26e1ff,_0x4be67e]of _0x1b9333())_0x3aa83a['set'](_0x26e1ff,_0x4be67e);return _0x3aa83a;}}class st extends _0x41aca7{['afterInit'](){const _0x26ccce=this['editor'];if(!_0x26ccce['plugins']['has']('RestrictedEditingModeEditing'))return;_0x26ccce['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x41aca7{constructor(_0x476684){super(_0x476684),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x2c1e77=this['editor'],_0x213524=_0x2c1e77['commands']['get']('importWord'),_0x2f5b78=_0x2c1e77['plugins']['get'](it);_0x213524&&(_0x213524['on']('execute',(_0x5120df,[,_0x3aedd7])=>{_0x3aedd7['collaboration_features']={'comments':!0x0,'user_id':_0x2f5b78['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x213524,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x321a06,_0x1f19d3){const {comment_threads:_0x1ce19c}=_0x1f19d3;_0x1ce19c&&_0x1ce19c['forEach'](({thread_id:_0x37df72,comments:_0x524764,is_resolved:_0x5d6490})=>{const _0x2184af=new Date(),_0x5e5ff4=_0x524764['map'](({author:_0x4adebd,content:_0x5658ed,created_at:_0x1f63a9})=>({'content':_0x5658ed,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x2184af,'attributes':{'@external':{'authorName':_0x4adebd,'createdAt':_0x1f63a9?new Date(_0x1f63a9):new Date(),'source':'importWord'}}})),_0xc87345=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0xc87345,'threadId':_0x37df72,'comments':_0x5e5ff4,'resolvedAt':_0x5d6490?_0x2184af:null});});}}class at extends _0x41aca7{constructor(_0x461bd6){super(_0x461bd6),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x5e4007=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x5e4007,'contentInsertion',(_0x44a3d5,_0x55b6b6)=>this['_removeMarkersWithoutThreads'](_0x55b6b6['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x225334){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x225334;const _0x3ebf4c=this['editor']['plugins']['get']('CommentsRepository');for(const _0xd75493 of _0x225334['keys']()){const [_0x3b4246,_0x2f84a9]=_0xd75493['split'](':');'comment'!=_0x3b4246||_0x3ebf4c['hasCommentThread'](_0x2f84a9)||_0x225334['delete'](_0xd75493);}return _0x225334;}['_registerMarkerInClipboardPipeline'](){const _0x50cf17=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x1a6c4c=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x1a6c4c&&_0x50cf17['_registerMarkerToCopy']('comment',_0x1a6c4c);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x10ea41){switch(_0x10ea41){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0x48db6c){const _0x27c2c9=_0x48db6c['split'](':');return{'group':_0x27c2c9[0x0],'id':_0x27c2c9[0x1],'part':_0x27c2c9[0x2]};}class ut extends _0x41aca7{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x550566,_0x3a4f7a)=>{if(!_0x3a4f7a['options']['showCommentHighlights'])return null;if(_0x3a4f7a['options']['ignoreResolvedComments']){const {id:_0x540d8c}=ft(_0x550566['markerName']),_0x34b300=this['editor']['plugins']['get'](o);if(_0x34b300['getCommentThread'](_0x540d8c)?.['isResolved']&&_0x550566['item'])return _0x3a4f7a['consumable']['consume'](_0x550566['item'],'addMarker:'+_0x550566['markerName']),_0x3a4f7a['consumable']['consume'](_0x550566['item'],'removeMarker:'+_0x550566['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x31100f=>{_0x31100f['on']('addMarker:comment',(_0x316e3b,_0x25c908,_0x5bc82d)=>{if(!_0x5bc82d['options']['showCommentHighlights'])return;const _0x23176d=_0x25c908['item'];if(!_0x23176d)return;const _0x49eadd=_0x5bc82d['mapper']['toViewElement'](_0x23176d);this['editor']['model']['schema']['isObject'](_0x23176d)&&_0x49eadd&&!_0x49eadd['getCustomProperty']('widget')&&_0x49eadd['is']('containerElement')&&_0x54dc86(_0x49eadd,_0x5bc82d['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x21d2e1,{writer:_0x5d084b,options:_0x589cc9})=>{if(!_0x589cc9['showCommentHighlights'])return null;const _0x522040=_0x5d084b['createContainerElement']('div'),_0x3f1906=_0x5d084b['createEmptyElement']('hr');return _0x5d084b['addClass']('ck-horizontal-line',_0x522040),_0x5d084b['insert'](_0x5d084b['createPositionAt'](_0x522040,0x0),_0x3f1906),_0x522040;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x54f390,{writer:_0x60ecaa,options:_0x245133})=>{if(!_0x245133['showCommentHighlights'])return null;const _0x2ef52e=_0x60ecaa['createContainerElement']('span'),_0x4925af=_0x60ecaa['createEmptyElement']('img');return _0x60ecaa['addClass']('image-inline',_0x2ef52e),_0x60ecaa['insert'](_0x60ecaa['createPositionAt'](_0x2ef52e,0x0),_0x4925af),_0x2ef52e;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x1b2cfe,{writer:_0x3cc0b6,options:_0x591039})=>{if(_0x591039['showCommentHighlights'])return _0x3cc0b6['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x2a6251,_0x3541c4,_0x39b64b)=>{_0x39b64b['options']['showCommentHighlights']&&_0x2a6251['stop']();},{'priority':'high'});}}class r extends _0x41aca7{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(_0x5babc0){super(_0x5babc0),this['set']('isThreadsLoadingPaused',!0x0),_0x5babc0['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x5d5e53,_0x199b84,_0x540a61,_0x4a6b70)=>{const _0x2ef206=_0x5babc0['plugins']['get'](o),_0x5a7dc3=_0x540a61?ft(_0x540a61)['id']:null;_0x5babc0['model']['change'](()=>{if(_0x5a7dc3){const _0x5d6dd3=this['getAllMarkersForId'](_0x5a7dc3);for(const _0x46a209 of _0x5d6dd3)_0x5babc0['editing']['reconvertMarker'](_0x46a209);}if(_0x4a6b70){const {id:_0xd98974}=ft(_0x4a6b70),_0x39faf6=_0x2ef206['getCommentThread'](_0xd98974);if(_0x39faf6&&_0x39faf6['unlinkedAt'])return;if(_0x39faf6&&!_0x39faf6['isAttached'])return;const _0x9b42a4=this['getAllMarkersForId'](_0xd98974);for(const _0x13e4ff of _0x9b42a4)_0x5babc0['editing']['reconvertMarker'](_0x13e4ff);}}),_0x5a7dc3&&this['scrollToThreadMarker'](_0x5a7dc3);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x141ccf=this['editor'],_0x43a146=_0x141ccf['plugins']['get'](o),_0xc20b4e=_0x141ccf['config']['get']('collaboration.channelId'),_0x2efe1a=_0x43a146['getCommentThreads']()['filter'](_0x5a3d03=>_0x5a3d03['channelId']!==_0xc20b4e);_0x141ccf['commands']['add']('addCommentThread',new ot(_0x141ccf)),this['listenTo'](_0x141ccf,'change:isReadOnly',(_0x56feb9,_0x2a09b9,_0x2e3d39)=>{_0x43a146['switchReadOnly'](_0x2e3d39,_0x141ccf['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x43a146,dt('addCommentThread',_0xc20b4e),(_0x46406b,{threadId:_0x5c4778})=>{const _0xd64171=this['editor']['plugins']['get'](o)['getCommentThread'](_0x5c4778);_0xd64171?.['unlinkedAt']&&this['_attachArchivedThread'](_0x5c4778);}),this['listenTo'](_0x43a146,dt('removeCommentThread',_0xc20b4e),(_0x1fae0f,{threadId:_0x561cc7})=>{_0x141ccf['model']['enqueueChange']({'isUndoable':!0x1},_0x411f56=>{const _0x27f017=this['getAllMarkersForId'](_0x561cc7);for(const _0x22c121 of _0x27f017)_0x411f56['removeMarker'](_0x22c121);});}),this['listenTo'](_0x43a146,dt('resolveCommentThread',_0xc20b4e),(_0xb04747,{threadId:_0x1fe134})=>{(this['_reconvertMarkers'](_0x1fe134),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x1fe134)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x43a146,dt('reopenCommentThread',_0xc20b4e),(_0x5e2977,{threadId:_0x391642})=>{this['_reconvertMarkers'](_0x391642);},{'priority':'low'}),this['listenTo'](_0x43a146,dt('addComment',_0xc20b4e),(_0x20aeb5,{threadId:_0x547613,isFromAdapter:_0x47cf7b})=>{const _0x1f6266=this['getAllMarkersForId'](_0x547613);if(_0x47cf7b||0x0==_0x1f6266['length']||!_0x43a146['hasCommentThread'](_0x547613))return;0x1===_0x43a146['getCommentThread'](_0x547613)['length']&&_0x141ccf['model']['enqueueChange']({'isUndoable':!0x1},_0x856bb4=>{for(const _0x35fd80 of _0x1f6266)_0x856bb4['updateMarker'](_0x35fd80,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x2efe1a);}['afterInit'](){!async function(_0xf59ddc){const _0x4d1eab=_0x4ee43f([0x63,0x34,0x4d,0x31,0x57,0x52,0x68,0x36,0x75,0x41,0x43,0x4f,0x6d,0x35,0x55,0x54,0x49,0x4b,0x46,0x39,0x37,0x74,0x45,0x59,0x4c,0x48,0x66,0x51,0x78,0x5a,0x7a,0x6c,0x50,0x6b,0x4e,0x56,0x38,0x6e,0x70,0x6a,0x44,0x72,0x62,0x47,0x4a,0x65,0x77,0x71,0x73,0x76,0x61,0x58,0x79,0x67,0x69,0x64,0x53,0x32,0x33,0x42,0x30,0x6f]),_0xe0d733=0x3852b933,_0x1d9bb5=0x3855d6d3^_0xe0d733,_0x32fda1=window[_0x4ee43f([0x44,0x61,0x74,0x65])][_0x4ee43f([0x6e,0x6f,0x77])](),_0x30a814=_0xf59ddc[_0x4ee43f([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x452262=new window[(_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2db9a9=>{_0x30a814[_0x4ee43f([0x6f,0x6e,0x63,0x65])](_0x4ee43f([0x72,0x65,0x61,0x64,0x79]),_0x2db9a9);}),_0x4f4847={[_0x4ee43f([0x6b,0x74,0x79])]:_0x4ee43f([0x45,0x43]),[_0x4ee43f([0x75,0x73,0x65])]:_0x4ee43f([0x73,0x69,0x67]),[_0x4ee43f([0x63,0x72,0x76])]:_0x4ee43f([0x50,0x2d,0x32,0x35,0x36]),[_0x4ee43f([0x78])]:_0x4ee43f([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]),[_0x4ee43f([0x79])]:_0x4ee43f([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]),[_0x4ee43f([0x61,0x6c,0x67])]:_0x4ee43f([0x45,0x53,0x32,0x35,0x36])},_0x391cc4=_0x30a814[_0x4ee43f([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4ee43f([0x67,0x65,0x74])](_0x4ee43f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x479458(){let _0x18186d,_0xf4ae74=null,_0x841866=null;try{if(_0x391cc4==_0x4ee43f([0x47,0x50,0x4c]))return _0x4ee43f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x18186d=_0x27c61f(),!_0x18186d)return _0x4ee43f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x18186d[_0x4ee43f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x841866=_0x55752e(_0x18186d[_0x4ee43f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x18186d[_0x4ee43f([0x6a,0x74,0x69])])),await _0x599a1a()?_0x2122ac()?_0x39bab5()?_0x4ee43f([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x8a7d89()?(_0x18186d[_0x4ee43f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4ee43f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xf4ae74=_0xba1435(_0x4ee43f([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x18186d[_0x4ee43f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4ee43f([0x74,0x72,0x69,0x61,0x6c])&&(_0xf4ae74=_0xba1435(_0x4ee43f([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x242524()):_0x4ee43f([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4ee43f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4ee43f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4ee43f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x39bab5(){const _0x43fb90=[_0x4ee43f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4ee43f([0x74,0x72,0x69,0x61,0x6c])][_0x4ee43f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x18186d[_0x4ee43f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x32fda1/0x3e8:0xe10*_0x1d9bb5;return _0x18186d[_0x4ee43f([0x65,0x78,0x70])]<_0x43fb90;}function _0x2122ac(){const _0x21bbd9=_0x18186d[_0x4ee43f([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x21bbd9)return!0x1;if(_0x21bbd9[_0x4ee43f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ee43f([0x2a])))return!0x0;if(_0x21bbd9[_0x4ee43f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ee43f([0x43,0x4d,0x54])))return!0x0;if(_0x21bbd9[_0x4ee43f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ee43f([0x52,0x43,0x4d,0x54]))){if(_0x48725e())return!0x0;if(_0x3cee5d()||_0x1bd447())return!0x0;}return!0x1;}function _0x8a7d89(){const _0x4c3ecb=_0x18186d[_0x4ee43f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x4c3ecb||0x0==_0x4c3ecb[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x38a0b4}=new URL(window[_0x4ee43f([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x4c3ecb[_0x4ee43f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38a0b4))return!0x0;const _0x201b8c=_0x38a0b4[_0x4ee43f([0x73,0x70,0x6c,0x69,0x74])](_0x4ee43f([0x2e]));return _0x4c3ecb[_0x4ee43f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1e8731=>_0x1e8731[_0x4ee43f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ee43f([0x2a])))[_0x4ee43f([0x6d,0x61,0x70])](_0x3ec9ef=>_0x3ec9ef[_0x4ee43f([0x73,0x70,0x6c,0x69,0x74])](_0x4ee43f([0x2e])))[_0x4ee43f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1e799c=>_0x1e799c[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x201b8c[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4ee43f([0x6d,0x61,0x70])](_0x5540b7=>Array(_0x201b8c[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5540b7[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4ee43f([0x66,0x69,0x6c,0x6c])](_0x5540b7[0x0]===_0x4ee43f([0x2a])?_0x4ee43f([0x2a]):'')[_0x4ee43f([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5540b7))[_0x4ee43f([0x73,0x6f,0x6d,0x65])](_0x28d015=>_0x201b8c[_0x4ee43f([0x65,0x76,0x65,0x72,0x79])]((_0x348916,_0x23ed55)=>_0x28d015[_0x23ed55]===_0x348916||_0x28d015[_0x23ed55]===_0x4ee43f([0x2a])));}function _0x242524(){return _0xf4ae74&&_0x841866?new window[(_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2860dc,_0x3cc6be)=>{_0xf4ae74[_0x4ee43f([0x74,0x68,0x65,0x6e])](_0x2860dc,_0x3cc6be),_0x841866[_0x4ee43f([0x74,0x68,0x65,0x6e])](_0x381c26=>{_0x381c26!=_0x4ee43f([0x56,0x61,0x6c,0x69,0x64])&&_0x2860dc(_0x381c26);},_0x3cc6be);}):_0xf4ae74||_0x841866||_0x4ee43f([0x56,0x61,0x6c,0x69,0x64]);}}function _0x55752e(_0x2b539c,_0x275983){return new window[(_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1260d3=>{if(_0x241b85())return _0x1260d3(_0x4ee43f([0x56,0x61,0x6c,0x69,0x64]));_0x46dc35(),_0x30a814[_0x4ee43f([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4ee43f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x6318c0=!0x1;const _0x55b063=_0x2388d3();function _0x1eb6a6(_0x23650e){return!!_0x23650e&&(typeof _0x23650e===_0x4ee43f([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x23650e===_0x4ee43f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x23650e[_0x4ee43f([0x74,0x68,0x65,0x6e])]===_0x4ee43f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x23650e[_0x4ee43f([0x63,0x61,0x74,0x63,0x68])]===_0x4ee43f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0xbd5608(_0x2cb2d4){_0x52120f(_0x2cb2d4)[_0x4ee43f([0x74,0x68,0x65,0x6e])](_0x447dc1=>{if(!_0x447dc1||_0x447dc1[_0x4ee43f([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4ee43f([0x6f,0x6b]))return _0x4ee43f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x4d315c(_0x620ca5(_0x55b063+_0x275983))!=_0x447dc1[_0x4ee43f([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4ee43f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4ee43f([0x56,0x61,0x6c,0x69,0x64]);})[_0x4ee43f([0x74,0x68,0x65,0x6e])](_0x3a4e2d=>(_0x29a795(),_0x3a4e2d),()=>{const _0x5e2e72=_0x34cb3b();return null==_0x5e2e72?(_0x29a795(),_0x4ee43f([0x56,0x61,0x6c,0x69,0x64])):_0x4ee43f(_0x32fda1-_0x5e2e72>(0x1c5e3d33^_0xe0d733)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4ee43f([0x74,0x68,0x65,0x6e])](_0x1260d3)[_0x4ee43f([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1260d3(_0x4ee43f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x65816a=0x386457b3^_0xe0d733;function _0x29a795(){const _0x4428da=_0x4ee43f([0x6c,0x6c,0x63,0x74,0x2d])+_0x4d315c(_0x620ca5(_0x2b539c)),_0x3e9402=_0x33aa94(_0x4d315c(window[_0x4ee43f([0x4d,0x61,0x74,0x68])][_0x4ee43f([0x63,0x65,0x69,0x6c])](_0x32fda1/_0x65816a)));window[_0x4ee43f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4ee43f([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4428da,_0x3e9402);}function _0x34cb3b(){const _0x20cea6=_0x4ee43f([0x6c,0x6c,0x63,0x74,0x2d])+_0x4d315c(_0x620ca5(_0x2b539c)),_0x3f651d=window[_0x4ee43f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4ee43f([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x20cea6);return _0x3f651d?window[_0x4ee43f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x33aa94(_0x3f651d),0x10)*_0x65816a:null;}function _0x52120f(_0x52c159){return new window[(_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x57bd89,_0x63d07a)=>{_0x52c159[_0x4ee43f([0x74,0x68,0x65,0x6e])](_0x57bd89,_0x63d07a),window[_0x4ee43f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x63d07a,0x38536df3^_0xe0d733);});}}_0x30a814[_0x4ee43f([0x6f,0x6e])](_0x4ee43f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x280259,_0x47c07e)=>{if(_0x47c07e[0x0]!=_0x2b539c)return _0x1260d3(_0x4ee43f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x47c07e[0x1]={..._0x47c07e[0x1],[_0x4ee43f([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x55b063};},{[_0x4ee43f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4ee43f([0x68,0x69,0x67,0x68])}),_0x30a814[_0x4ee43f([0x6f,0x6e])](_0x4ee43f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x382a43=>{_0x1eb6a6(_0x382a43[_0x4ee43f([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x6318c0=!0x0,_0xbd5608(_0x382a43[_0x4ee43f([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4ee43f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4ee43f([0x6c,0x6f,0x77])}),_0x452262[_0x4ee43f([0x74,0x68,0x65,0x6e])](()=>{_0x6318c0||_0x1260d3(_0x4ee43f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x241b85(){return _0x30a814[_0x4ee43f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4ee43f([0x76,0x69,0x65,0x77])][_0x4ee43f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4ee43f([0x61,0x75,0x74,0x6f]);}function _0x46dc35(){_0x30a814[_0x4ee43f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4ee43f([0x76,0x69,0x65,0x77])][_0x4ee43f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4ee43f([0x61,0x75,0x74,0x6f]);}}function _0xba1435(_0x57549a){const _0x529e0d=[new window[(_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x213543=>setTimeout(_0x213543,0x385b87ff^_0xe0d733)),_0x452262[_0x4ee43f([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x485fdc=>{let _0x42af6a=0x0;_0x30a814[_0x4ee43f([0x6d,0x6f,0x64,0x65,0x6c])][_0x4ee43f([0x6f,0x6e])](_0x4ee43f([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x3b617b,_0x5b6307)=>{_0x5b6307[0x0][_0x4ee43f([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x42af6a++,_0x42af6a==(0x3852b8cb^_0xe0d733)&&(_0x485fdc(),_0x3b617b[_0x4ee43f([0x6f,0x66,0x66])]());});}))];return window[_0x4ee43f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4ee43f([0x72,0x61,0x63,0x65])](_0x529e0d)[_0x4ee43f([0x74,0x68,0x65,0x6e])](()=>_0x57549a);}async function _0x5bcdf6(){await _0x452262,_0x30a814[_0x4ee43f([0x6d,0x6f,0x64,0x65,0x6c])][_0x4ee43f([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x54a0d6,_0x30a814[_0x4ee43f([0x6d,0x6f,0x64,0x65,0x6c])][_0x4ee43f([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x54a0d6,_0x30a814[_0x4ee43f([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4ee43f([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x48725e(){return _0x1a294e(_0x4ee43f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x118aac(_0x4ee43f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4ee43f([0x73,0x74,0x61,0x74,0x65])]==_0x4ee43f([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3cee5d(){return _0x1a294e(_0x4ee43f([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 _0x1bd447(){return _0x1a294e(_0x4ee43f([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4dfc93(_0x11af88){const _0x249a15=_0x380e34();_0x30a814[_0x249a15]=_0x4ee43f([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x11af88,_0x11af88!=_0x4ee43f([0x56,0x61,0x6c,0x69,0x64])&&_0x5bcdf6();}function _0x380e34(){const _0x389406=window[_0x4ee43f([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4ee43f([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4ee43f([0x6e,0x6f,0x77])]())[_0x4ee43f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4ee43f([0x2e]),'');let _0x113f08=_0x4ee43f([0x63]);for(let _0x401eae=0x0;_0x401eae<_0x389406[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x401eae+=0x2){let _0x3ab284=window[_0x4ee43f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x389406[_0x4ee43f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x401eae,_0x401eae+0x2));_0x3ab284>=_0x4d1eab[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3ab284-=_0x4d1eab[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x113f08+=_0x4d1eab[_0x3ab284];}return _0x113f08;}function _0x27c61f(){const _0x27b625=_0x391cc4[_0x4ee43f([0x73,0x70,0x6c,0x69,0x74])](_0x4ee43f([0x2e]));if(0x3!=_0x27b625[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x128b4b(_0x27b625[0x1]);function _0x128b4b(_0x1b725b){const _0x4b7ca4=_0x35d233(_0x1b725b);return _0x4b7ca4&&_0x412ec8()?_0x4b7ca4:null;function _0x412ec8(){const _0x2762ba=_0x4b7ca4[_0x4ee43f([0x6a,0x74,0x69])],_0x59c474=window[_0x4ee43f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2762ba[_0x4ee43f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2762ba[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2cdbef={..._0x4b7ca4,[_0x4ee43f([0x6a,0x74,0x69])]:_0x2762ba[_0x4ee43f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x2762ba[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2cdbef[_0x4ee43f([0x76,0x63])],_0x620ca5(_0x2cdbef)==_0x59c474;}}}async function _0x599a1a(){let _0x1950af=!0x0;try{const _0x337311=_0x391cc4[_0x4ee43f([0x73,0x70,0x6c,0x69,0x74])](_0x4ee43f([0x2e])),[_0x114eaf,_0x2f4bfc,_0x92e105]=_0x337311;return _0x5d012c(_0x114eaf),await _0x4a9a2b(_0x114eaf,_0x2f4bfc,_0x92e105),_0x1950af;}catch{return!0x1;}function _0x5d012c(_0x1487a2){const _0xd49e8e=_0x35d233(_0x1487a2);_0xd49e8e&&_0xd49e8e[_0x4ee43f([0x61,0x6c,0x67])]==_0x4ee43f([0x45,0x53,0x32,0x35,0x36])||(_0x1950af=!0x1);}async function _0x4a9a2b(_0x574211,_0x592727,_0x172fbe){const _0x5de3ac=window[_0x4ee43f([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4ee43f([0x66,0x72,0x6f,0x6d])](_0x2e4411(_0x172fbe),_0x332836=>_0x332836[_0x4ee43f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x220303=new window[(_0x4ee43f([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4ee43f([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x574211+_0x4ee43f([0x2e])+_0x592727),_0x9cd898=window[_0x4ee43f([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4ee43f([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x9cd898)return;const _0x2dd61f=await _0x9cd898[_0x4ee43f([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4ee43f([0x6a,0x77,0x6b]),_0x4f4847,{[_0x4ee43f([0x6e,0x61,0x6d,0x65])]:_0x4ee43f([0x45,0x43,0x44,0x53,0x41]),[_0x4ee43f([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4ee43f([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4ee43f([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x9cd898[_0x4ee43f([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4ee43f([0x6e,0x61,0x6d,0x65])]:_0x4ee43f([0x45,0x43,0x44,0x53,0x41]),[_0x4ee43f([0x68,0x61,0x73,0x68])]:{[_0x4ee43f([0x6e,0x61,0x6d,0x65])]:_0x4ee43f([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2dd61f,_0x5de3ac,_0x220303)||(_0x1950af=!0x1);}}function _0x35d233(_0x3505c3){return _0x3505c3[_0x4ee43f([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4ee43f([0x65,0x79]))?JSON[_0x4ee43f([0x70,0x61,0x72,0x73,0x65])](_0x2e4411(_0x3505c3)):null;}function _0x2e4411(_0x1d7c6b){return window[_0x4ee43f([0x61,0x74,0x6f,0x62])](_0x1d7c6b[_0x4ee43f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4ee43f([0x2b]))[_0x4ee43f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4ee43f([0x2f])));}function _0x620ca5(_0xd6256e){let _0xa909c1=0x1505;function _0x116d60(_0x311ead){for(let _0x5e5f9f=0x0;_0x5e5f9f<_0x311ead[_0x4ee43f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5e5f9f++){const _0x18bd5b=_0x311ead[_0x4ee43f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5e5f9f);_0xa909c1=(_0xa909c1<<0x5)+_0xa909c1+_0x18bd5b,_0xa909c1&=_0xa909c1;}}function _0xaa5c4a(_0x12ddd4){Array[_0x4ee43f([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x12ddd4)?_0x12ddd4[_0x4ee43f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0xaa5c4a):_0x12ddd4&&typeof _0x12ddd4==_0x4ee43f([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4ee43f([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x12ddd4)[_0x4ee43f([0x73,0x6f,0x72,0x74])]()[_0x4ee43f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2e7b96,_0x392f12])=>{_0x116d60(_0x2e7b96),_0xaa5c4a(_0x392f12);}):_0x116d60(window[_0x4ee43f([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x12ddd4));}return _0xaa5c4a(_0xd6256e),_0xa909c1>>>0x0;}function _0x4d315c(_0x33f22c){return _0x33f22c[_0x4ee43f([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4ee43f([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4ee43f([0x30]));}function _0x33aa94(_0x188b76){return _0x188b76[_0x4ee43f([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4ee43f([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4ee43f([0x6a,0x6f,0x69,0x6e])]('');}function _0x1a294e(_0xc804fd){return _0x30a814[_0x4ee43f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4ee43f([0x68,0x61,0x73])](_0xc804fd);}function _0x118aac(_0x25bfa1){return _0x30a814[_0x4ee43f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4ee43f([0x67,0x65,0x74])](_0x25bfa1);}function _0x54a0d6(){}function _0x4ee43f(_0x4e5c46){return _0x4e5c46['map'](_0x34cf60=>String['fromCharCode'](_0x34cf60))['join']('');}_0x4dfc93(await _0x479458());}(this);}['destroy'](){const _0x167a05=this['editor']['plugins']['get'](o),_0x260237=this['editor']['config']['get']('collaboration.channelId');for(const _0xf87708 of _0x167a05['getCommentThreads']({'channelId':_0x260237}))_0x167a05['_detachCommentThread'](_0xf87708['id']),_0x167a05['_threads']['delete'](_0xf87708['id']);super['destroy']();}['hasMarkerForId'](_0x602cf7){return this['getAllMarkersForId'](_0x602cf7)['length']>0x0;}['getAllMarkersForId'](_0x185739){const _0x38729d=[];for(const _0x416a2a of this['editor']['model']['markers'])_0x416a2a['name']['startsWith']('comment:'+_0x185739)&&_0x38729d['push'](_0x416a2a);return _0x38729d;}['scrollToThreadMarker'](_0x2ebd5b){setTimeout(()=>{const _0x384fbe=this['_getTargetForId'](_0x2ebd5b);if(!_0x384fbe)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x2ebd5b&&nt({'target':_0x384fbe[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x4d19f0){this['editor']['model']['change'](()=>{for(const _0x3578ed of this['getAllMarkersForId'](_0x4d19f0))this['editor']['editing']['reconvertMarker'](_0x3578ed);});}['_attachArchivedThread'](_0x1f3d9e){const _0x2217b8=this['editor']['plugins']['get'](o),_0x201a4e=this['editor']['plugins']['get'](b),_0x1cde5c=_0x2217b8['getCommentThread'](_0x1f3d9e);if(!_0x1cde5c['isAttached']){const _0x5e88b7=_0x1cde5c['attachTo'](()=>this['_getTargetForId'](_0x1cde5c['id']));_0x201a4e['registerAnnotation'](_0x5e88b7),_0x1cde5c['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x410e13=this['editor'],_0x56c76a=_0x410e13['plugins']['get'](it);_0x410e13['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x598a0f,_0xe46338)=>{const {id:_0x4a529f}=ft(_0x598a0f['markerName']),_0x10e4d6=_0x410e13['plugins']['get'](o)['getCommentThread'](_0x4a529f),_0xdeb722=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x4a529f;let _0x5e3e6f;if(_0x10e4d6&&_0x10e4d6['isResolved']&&!_0xdeb722&&_0x598a0f['item'])return _0xe46338['consumable']['consume'](_0x598a0f['item'],'addMarker:'+_0x598a0f['markerName']),_0xe46338['consumable']['consume'](_0x598a0f['item'],'removeMarker:'+_0x598a0f['markerName']),null;const _0xae937e=['ck-comment-marker'];return _0xdeb722&&_0xae937e['push']('ck-comment-marker--active'),_0x5e3e6f=_0x10e4d6?.['length']?_0x10e4d6['comments']['first']['author']['id']:_0x56c76a['me']['id'],{'classes':_0xae937e,'attributes':{'data-comment':_0x4a529f,'data-author-id':_0x5e3e6f}};}}),_0x410e13['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x204aa6,{options:_0x338088})=>{if(_0x338088['showCommentHighlights'])return null;const _0x2fe656=_0x410e13['plugins']['get'](o),_0x5cfb2c=_0x410e13['model']['markers']['get'](_0x204aa6),{id:_0x43894c,part:_0x576557}=ft(_0x204aa6);return _0x5cfb2c&&!_0x5cfb2c['affectsData']||_0x338088['ignoreResolvedComments']&&_0x2fe656['getCommentThread'](_0x43894c)?.['isResolved']?null:{'group':'comment','name':_0x576557?_0x43894c+':'+_0x576557:_0x43894c};}}),_0x410e13['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x5deb7c,{writer:_0x1a8f30})=>_0x1a8f30['createElement']('$marker',{'data-name':'comment:'+_0x5deb7c['getAttribute']('id')})}),_0x410e13['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x9efea=this['editor'],_0x4b5632=_0x9efea['plugins']['get'](o),_0x439de3=new Set(),_0x34b346=new Set();_0x9efea['model']['document']['registerPostFixer'](_0x53e0c4=>{let _0x105237=!0x1;for(const {name:_0x41154a,data:_0x5e3d5b}of _0x9efea['model']['document']['differ']['getChangedMarkers']()){const {group:_0x29e734,id:_0x227a83}=ft(_0x41154a);let _0x2d24af=_0x5e3d5b['newRange'];if('comment'!==_0x29e734||!_0x2d24af)continue;const _0x4973bd='$graveyard'===_0x2d24af['root']['rootName'];_0x4973bd||(_0x2d24af=ht(_0x2d24af,_0x9efea['model']),!_0x2d24af||_0x2d24af['isCollapsed']||!_0x5e3d5b['newRange']||_0x2d24af['isEqual'](_0x5e3d5b['newRange']))?_0x9efea['model']['hasContent'](_0x2d24af)&&!_0x4973bd?this['isThreadsLoadingPaused']?_0x439de3['add'](_0x41154a):this['_handleThreadMarker'](_0x41154a,_0x227a83):(_0x34b346['add'](_0x41154a),_0x439de3['delete'](_0x41154a),_0x53e0c4['removeMarker'](_0x41154a),_0x105237=!0x0):(_0x53e0c4['updateMarker'](_0x41154a,{'range':_0x2d24af}),_0x105237=!0x0);}return _0x105237;}),this['on']('change:isThreadsLoadingPaused',(_0x1631ca,_0x19aed4,_0x11df91)=>{if(!_0x11df91&&_0x439de3['size'])for(const _0x51487c of _0x439de3){const {id:_0x470886}=ft(_0x51487c);_0x439de3['delete'](_0x51487c),_0x9efea['model']['markers']['get'](_0x51487c)&&this['_handleThreadMarker'](_0x51487c,_0x470886);}}),this['listenTo'](_0x9efea['model']['document'],'change',()=>{for(const {name:_0x49bbd4,data:{newRange:_0x11838d}}of _0x9efea['model']['document']['differ']['getChangedMarkers']()){const {group:_0x4ce88b,id:_0x2dc090}=ft(_0x49bbd4);if('comment'!==_0x4ce88b)continue;const _0x2c5a92=_0x4b5632['getCommentThread'](_0x2dc090),_0x132295=this['hasMarkerForId'](_0x2dc090);_0x2c5a92&&(!_0x2c5a92['_hasTargetInContent']&&_0x11838d&&_0x9efea['editing']['view']['once']('render',()=>{const _0xd17bbd=_0x9efea['plugins']['get'](y),_0x10f06f=_0x4b5632['_threadToController']['get'](_0x2c5a92)['view'];_0xd17bbd['getByInnerView'](_0x10f06f)['refreshVisibility']();},{'priority':'low'}),_0x2c5a92['_hasTargetInContent']=_0x132295||!!_0x11838d),_0x11838d||(_0x34b346['add'](_0x49bbd4),_0x439de3['delete'](_0x49bbd4));}for(const _0x2c8540 of _0x34b346){const {id:_0x312429}=ft(_0x2c8540),_0x4d7133=_0x4b5632['getCommentThread'](_0x312429);if(_0x439de3['delete'](_0x2c8540),!_0x4d7133)continue;const _0x5aa2b5=this['hasMarkerForId'](_0x312429);_0x5aa2b5||_0x4d7133['isSubmitted']?_0x5aa2b5||_0x4d7133['unlinkedAt']||_0x4d7133['setUnlinkedAt'](new Date()):_0x4d7133['remove']();}_0x34b346['clear']();});}['_handleInitialThreads'](_0x84a88a){_0x84a88a['forEach'](_0xd42103=>{_0xd42103['unlinkedAt']&&this['_attachArchivedThread'](_0xd42103['id']);});}['_getTargetForId'](_0x3ffa79){const _0x2b6cc5=this['editor'],_0x114934=this['getAllMarkersForId'](_0x3ffa79);return et(_0x2b6cc5['editing'],_0x114934);}['_getTextContext'](_0x51a8f1){const _0x3d9efc=this['getAllMarkersForId'](_0x51a8f1);let _0x17a589='',_0x26d25c=!0x1;for(const _0x56c569 of _0x3d9efc){const _0x2edc56=_0x56c569['getRange']();for(const _0x4810b1 of Array['from'](_0x2edc56['getItems']()))_0x4810b1['is']('$textProxy')?(_0x17a589&&_0x26d25c&&(_0x17a589+='\x20',_0x26d25c=!0x1),_0x17a589+=_0x4810b1['data']):_0x26d25c=!0x0;_0x26d25c=!0x0;}return _0x17a589['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x4fd92d,_0x1dcfb6){const _0x5647d5=this['editor'],_0x47347d=_0x5647d5['plugins']['get'](o);let _0x5e5ed1=_0x47347d['getCommentThread'](_0x1dcfb6);const _0x485193=_0x5647d5['config']['get']('collaboration.channelId'),_0x3e5b9a=_0x5647d5['plugins']['get'](b);if(_0x5e5ed1&&(_0x5e5ed1['unlinkedAt']&&_0x5e5ed1['setUnlinkedAt'](null),_0x5e5ed1['isAttached']))return _0x5e5ed1;return!this['getAllMarkersForId'](_0x1dcfb6)[0x0]['managedUsingOperations']?_0x5647d5['editing']['view']['once']('render',()=>{if(_0x47347d['getCommentThread'](_0x1dcfb6))return;const _0x3953a7=_0x5647d5['plugins']['get'](y);_0x5e5ed1=_0x47347d['openNewCommentThread']({'channelId':_0x485193,'threadId':_0x1dcfb6,'target':()=>this['_getTargetForId'](_0x1dcfb6),'context':{'type':'text','value':this['_getTextContext'](_0x1dcfb6)}});const _0x52d2f9=_0x47347d['_threadToController']['get'](_0x5e5ed1)['view'],_0x25dfe5=_0x3953a7['getByInnerView'](_0x52d2f9);_0x25dfe5&&_0x3e5b9a['registerAnnotation'](_0x25dfe5);},{'priority':'low'}):_0x47347d['fetchCommentThread']({'channelId':_0x485193,'threadId':_0x1dcfb6})['then'](_0x4c8e20=>{if('destroyed'!==_0x5647d5['state']){if(_0x5e5ed1=_0x4c8e20,_0x5e5ed1&&!_0x5e5ed1['isAttached']){const _0x3a6e09=_0x5e5ed1['attachTo'](()=>this['_getTargetForId'](_0x1dcfb6));_0x3e5b9a['registerAnnotation'](_0x3a6e09),_0x5e5ed1['isResolved']&&this['_reconvertMarkers'](_0x1dcfb6);}else{if(!_0x5e5ed1){const _0x3d1613=this['getAllMarkersForId'](_0x1dcfb6);_0x5647d5['model']['change'](_0x452263=>{for(const _0x49f102 of _0x3d1613)_0x452263['removeMarker'](_0x49f102);});}}}}),_0x5e5ed1;}['_handleThreadMarker'](_0x4edae1,_0xfc9fa1){const _0xf971ba=this['_attachMarkerToThread'](_0x4edae1,_0xfc9fa1);_0xf971ba&&!_0xf971ba['context']&&_0xf971ba['setContext']({'type':'text','value':this['_getTextContext'](_0xfc9fa1)});}['_initAriaMarkerChangeAnnouncements'](){const _0xefebfe=this['editor'];rt(_0xefebfe['model'],({left:_0xb8c3e0,entered:_0x22e26a})=>{for(const _0x2687ba of _0xb8c3e0)if(mt(_0x2687ba)){_0xefebfe['ui']['ariaLiveAnnouncer']['announce'](N(_0xefebfe['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x424128 of _0x22e26a)if(mt(_0x424128)){_0xefebfe['ui']['ariaLiveAnnouncer']['announce'](N(_0xefebfe['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x1d9801)));break;}});}}function dt(_0x2c922a,_0x8b2dac){return _0x8b2dac?_0x2c922a+':'+_0x8b2dac:_0x2c922a;}function ht(_0x37cd80,_0x497b61){const _0x301297=_0x497b61['schema'],_0x37fafb=_0x497b61['createRange'](_0x37cd80['start']);for(const _0x123054 of _0x37cd80['getWalker']()){const {type:_0x231649,item:_0x42382e,nextPosition:_0x477673}=_0x123054;if('text'===_0x231649||_0x301297['isObject'](_0x42382e)){const _0x5b90af=_0x497b61['createPositionBefore'](_0x42382e);_0x37fafb['isCollapsed']&&(_0x37fafb['start']=_0x5b90af),_0x37fafb['end']=_0x477673;}}return _0x37fafb;}function mt(_0xd57e2d){return'comment'===ft(_0xd57e2d['name'])['group'];}class s extends _0x41aca7{['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 _0x1045ab=this['editor'],_0x4f6b62=_0x1045ab['plugins']['get'](o),_0x4b090c=_0x1045ab['plugins']['get'](r),_0x233e1b=_0x1045ab['plugins']['get'](y),_0x42279e=_0x1045ab['plugins']['get'](b);_0x1045ab['ui']['componentFactory']['add']('comment',()=>{const _0x2914a4=this['_createUIButton'](_0x3c4ac3);return _0x2914a4['tooltip']=!0x0,_0x2914a4;}),_0x1045ab['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x27f8f3)),_0x42279e['addSourceCollector'](()=>{const _0x201b43=[];for(const [_0x200a38,_0x275207]of _0x4f6b62['_threadToController']){const _0x346a9c=_0x4b090c['getAllMarkersForId'](_0x200a38['id']),_0x49ada2=_0x346a9c['map'](_0x2037f3=>_0x2037f3['getRange']());_0x346a9c['length']>0x0&&_0x201b43['push']([_0x275207['view'],_0x49ada2]);}return _0x201b43;}),this['listenTo'](_0x233e1b,'change:activeAnnotations',(_0x57a0f5,_0x1b7036,_0x3ca815)=>{const _0x30ac8a=Array['from'](_0x3ca815)['map'](_0x496c14=>_0x496c14['innerView'])['find'](_0x4a92e6=>_0x4f6b62['_viewToController']['has'](_0x4a92e6));if(!_0x30ac8a)return void(_0x4b090c['activeMarker']=null);const _0xede30c=_0x4f6b62['_viewToController']['get'](_0x30ac8a)['model']['id'],_0x4f392c='comment:'+_0xede30c;_0xede30c&&_0x4b090c['hasMarkerForId'](_0xede30c)?_0x4b090c['activeMarker']=_0x4f392c:_0x4b090c['activeMarker']&&(_0x4b090c['activeMarker']=null);}),this['listenTo'](_0x4f6b62,'removeCommentThread',(_0x4f95db,{threadId:_0x3f07f6,isFromAdapter:_0x38dc6e})=>{!_0x38dc6e&&_0x1045ab['ui']['focusTracker']['isFocused']&&_0x4b090c['hasMarkerForId'](_0x3f07f6)&&_0x1045ab['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x4f6b62,'addComment',(_0x3b8fe5,{threadId:_0x4fc60c,isFromAdapter:_0x3c8c01})=>{if(_0x3c8c01||!_0x4b090c['hasMarkerForId'](_0x4fc60c)||!_0x4f6b62['hasCommentThread'](_0x4fc60c))return;0x1===_0x4f6b62['getCommentThread'](_0x4fc60c)['length']&&(_0x1045ab['editing']['view']['focus'](),_0x3b8fe5['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x45828e=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x53590a;for(const _0x12dc8c in _0x45828e){const _0x58e996=_0x12dc8c,_0x334524=_0x45828e[_0x58e996];if('commentsLicenseKeyValid'==_0x334524||'commentsLicenseKeyInvalid'==_0x334524||'commentsLicenseKeyExpired'==_0x334524||'commentsLicenseKeyDomainLimit'==_0x334524||'commentsLicenseKeyNotAllowed'==_0x334524||'commentsLicenseKeyEvaluationLimit'==_0x334524||'commentsLicenseKeyTrialLimit'==_0x334524||'commentsLicenseKeyUsageLimit'==_0x334524){delete _0x45828e[_0x58e996],_0x53590a=_0x334524,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x53590a&&_0x45828e['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x53590a&&_0x45828e['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x53590a&&_0x45828e['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x53590a&&_0x45828e['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x53590a&&_0x45828e['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x53590a&&_0x45828e['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x53590a&&_0x45828e['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x1f5a94){const _0x18f440=this['editor'],_0xc2b6e9=new _0x1f5a94(_0x18f440['locale']),_0x50febc=_0x18f440['commands']['get']('addCommentThread');return _0xc2b6e9['set']({'label':N(_0x18f440['locale'],'Comment'),'icon':_0x482462}),_0xc2b6e9['bind']('isEnabled')['to'](_0x50febc,'hasContent'),this['listenTo'](_0xc2b6e9,'execute',()=>{_0x50febc['execute']();}),_0xc2b6e9;}}class i extends _0x41aca7{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x35dd80){super(_0x35dd80),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x3c94c9,_0x211782,_0x44c2df)=>{_0x44c2df?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x4619a2,_0x509eaf]of this['editor']['commands'])_0x509eaf['affectsData']&&'addCommentThread'!==_0x4619a2&&_0x509eaf['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing'))&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x338b58=this['editor']['editing']['view']['document'];this['listenTo'](_0x338b58,'cut',_0x360f68=>_0x360f68['stop'](),{'priority':'highest'}),this['listenTo'](_0x338b58,'clipboardInput',_0x56dd3c=>_0x56dd3c['stop'](),{'priority':'highest'}),this['listenTo'](_0x338b58,'delete',_0x967cef=>_0x967cef['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x43d148,_0x2d51b9]of this['editor']['commands'])_0x2d51b9['affectsData']&&'addCommentThread'!==_0x43d148&&_0x2d51b9['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 _0x2228db{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5b5125){super(_0x5b5125),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x5114e0=this['context']['plugins']['get'](y);this['listenTo'](_0x5114e0,'_activateAnnotation',(_0x261e05,_0x46da01)=>{for(const _0x1ba77f of this['activeUIs']){const _0x187a2c=this['_uis']['get'](_0x1ba77f);(0x0,this['uisData']['get'](_0x1ba77f)['filter'])(_0x46da01)&&_0x187a2c['setActiveAnnotation'](_0x46da01);}}),this['listenTo'](_0x5114e0,'_deactivateAllAnnotations',()=>{for(const _0x1ac3d6 of this['activeUIs']){this['_uis']['get'](_0x1ac3d6)['setActiveAnnotation'](null);}}),this['listenTo'](_0x5114e0['_visibleAnnotations'],'add',(_0x34c58f,_0xdc6f2d)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0xdc6f2d);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x4cdfff){return this['activeUIs']['has'](_0x4cdfff);}['activate'](_0x13fbd1,_0x4d431a=this['defaultFilter']){const _0x206bb8=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x13fbd1))throw new _0x2e6f8f('annotationsuis-missing-ui',this,{'uiName':_0x13fbd1});this['isActive'](_0x13fbd1)&&this['deactivate'](_0x13fbd1),this['activeUIs']['add'](_0x13fbd1);const _0x24d714=new S();v({'source':_0x206bb8['_visibleAnnotations'],'target':_0x24d714,'filter':_0x4d431a}),this['uisData']['set'](_0x13fbd1,{'collection':_0x24d714,'filter':_0x4d431a});const _0x42d839=this['_uis']['get'](_0x13fbd1);_0x42d839['attach'](_0x24d714),this['listenTo'](_0x42d839,'change:activeAnnotation',(_0x52f1f8,_0x50e2e0,_0x1dddbc,_0x12d211)=>{_0x12d211&&_0x206bb8['_removeActiveAnnotation'](_0x12d211),_0x1dddbc&&_0x206bb8['_addActiveAnnotation'](_0x1dddbc);});}['deactivate'](_0x1d93af){if(this['activeUIs']['delete'](_0x1d93af),!this['_uis']['has'](_0x1d93af))throw new _0x2e6f8f('annotationsuis-missing-ui',this,{'uiName':_0x1d93af});const _0x1eafb0=this['_uis']['get'](_0x1d93af);_0x1eafb0['detach'](),this['stopListening'](_0x1eafb0),this['uisData']['get'](_0x1d93af)['collection']['destroy'](),this['uisData']['delete'](_0x1d93af);}['switchTo'](_0xa2cbe2){if(!this['_uis']['has'](_0xa2cbe2))throw new _0x2e6f8f('annotationsuis-missing-ui',this,{'uiName':_0xa2cbe2});const _0x1058b1=this['context']['plugins']['get'](y),_0x34be61=Array['from'](_0x1058b1['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0xa2cbe2);const _0xbcae0a=this['_uis']['get'](_0xa2cbe2);_0xbcae0a['setActiveAnnotation'](_0x34be61),_0xbcae0a['_setSelectedAnnotations']&&_0x34be61&&_0xbcae0a['_setSelectedAnnotations']([_0x34be61]);}['deactivateAll'](){for(const _0x29e026 of this['activeUIs'])this['deactivate'](_0x29e026);}['register'](_0x149946,_0x536bf1){if(this['_uis']['has'](_0x149946))throw new _0x2e6f8f('annotationsuis-register-already-registered');if('function'!=typeof _0x536bf1['attach']||'function'!=typeof _0x536bf1['detach']||'function'!=typeof _0x536bf1['setActiveAnnotation'])throw new _0x2e6f8f('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x149946,_0x536bf1);}['refilterAnnotations'](){const _0x54a50e=this['context']['plugins']['get'](y)['collection'],_0x1a3e9e=new Map(),_0x2fe9d2=Array['from'](this['activeUIs']);for(const _0x156579 of this['activeUIs']){const _0x5b2789=this['uisData']['get'](_0x156579)['collection'];for(const _0x240be9 of _0x5b2789)_0x1a3e9e['set'](_0x240be9,_0x156579);}for(const _0x46d67f of _0x54a50e){const _0x3d472a=_0x1a3e9e['get'](_0x46d67f);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x46d67f);const _0xca8b5d=_0x2fe9d2['find'](_0x4e382e=>this['uisData']['get'](_0x4e382e)['filter'](_0x46d67f));_0x3d472a!==_0xca8b5d&&(_0x3d472a&&this['uisData']['get'](_0x3d472a)['collection']['remove'](_0x46d67f),_0xca8b5d&&this['uisData']['get'](_0xca8b5d)['collection']['add'](_0x46d67f));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x25f549){const _0x12762f=[];for(const _0x19e990 of this['activeUIs']){(0x0,this['uisData']['get'](_0x19e990)['filter'])(_0x25f549)&&_0x12762f['push'](_0x19e990);}if(_0x12762f['length']>0x1)throw new _0x2e6f8f('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x12762f,'annotationType':_0x25f549['type']});}}const _i=/* #__PURE__ -- @preserve */
32
+ Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x4965c6){super(_0x4965c6);const _0x323c87=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 _0x19913b(),this['focusCycler']=new _0x7bfb99({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x323c87['to']('class')],'style':{'minHeight':_0x323c87['to']('minHeight',_0x502f82=>'number'==typeof _0x502f82?_i(_0x502f82+0xa):null)},'dir':_0x4965c6['uiLanguageDirection'],'role':'application','aria-label':N(_0x4965c6,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x4965c6,'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',_0x5711dd=>{this['_updateItemPositionInFocusables'](_0x5711dd['source']);}),this['list']['forEach'](_0x4a2931=>{this['focusTracker']['add'](_0x4a2931['element']),this['_updateItemPositionInFocusables'](_0x4a2931);}),this['list']['on']('change',(_0x367a99,_0x52a356)=>{for(const _0x1eb4ab of _0x52a356['removed'])this['focusTracker']['remove'](_0x1eb4ab['element']),this['focusables']['remove'](_0x1eb4ab);for(const _0x1aa8fc of _0x52a356['added'])this['focusTracker']['add'](_0x1aa8fc['element']),this['_updateItemPositionInFocusables'](_0x1aa8fc);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x257fd3){const _0x361402=this['focusables']['getIndex'](_0x257fd3);let _0x2f9b8f,_0x1ec45b;for(const _0x5925e3 of this['focusables'])if(_0x257fd3['top']<_0x5925e3['top']){_0x2f9b8f=_0x5925e3;break;}if(_0x1ec45b=_0x2f9b8f?this['focusables']['getIndex'](_0x2f9b8f):this['focusables']['length'],-0x1!==_0x361402){if(_0x361402===_0x1ec45b-0x1)return;this['focusables']['remove'](_0x257fd3),_0x1ec45b=_0x2f9b8f?this['focusables']['getIndex'](_0x2f9b8f):this['focusables']['length'];}this['focusables']['add'](_0x257fd3,_0x1ec45b);}}const Ot=/* #__PURE__ -- @preserve */
33
+ Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x27e4b4){super(_0x27e4b4),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x3651e8,_0x189d82)=>_0x3651e8+_0x189d82),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x485473=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x485473['to']('isAnimationDisabled',_0x4ca70d=>_0x4ca70d?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x485473['to']('top',_0x39fb55=>Ot(_0x39fb55))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x3922d5=this['element']['clientHeight'];_0x3922d5&&(this['height']=_0x3922d5);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x2228db{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x49f531){super(_0x49f531),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 _0x3d6916=this['context']['config']['get']('sidebar.container');_0x3d6916&&this['setContainer'](_0x3d6916);}['setContainer'](_0x4a962c){if(!g(_0x4a962c))throw new _0x2e6f8f('sidebar-setcontainer-invalid-element');this['container']=_0x4a962c;}['_attachToContainer']({viewClass:_0x3c9362='',spaceBetweenItems:_0x1002fd=0x19}={}){if(!g(this['container']))throw new _0x2e6f8f('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x3c9362,this['_spaceBetweenItems']=_0x1002fd;}['rearrange']({removedAnnotation:_0x5b5051,previousAnnotation:_0x1c98bb,nextAnnotation:_0x1425f0}){const _0x4cc05b=this['getSidebarItemView'](_0x5b5051);this['view']['list']['remove'](_0x4cc05b),this['_destroySidebarItemView'](_0x5b5051),_0x1c98bb&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x1c98bb)),_0x1425f0&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x1425f0)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x536137,activatedAnnotation:_0x156372,disableAnimationOnActivatedAnnotation:_0x1c0bc5}){if(this['_activeAnnotation']=_0x156372,_0x536137){_0x536137['isActive']=!0x1;const _0x222b2d=this['getSidebarItemView'](_0x536137);_0x222b2d&&_0x1c0bc5&&(_0x222b2d['isAnimationDisabled']=!0x1);}if(_0x156372){const _0x4a9168=this['getSidebarItemView'](_0x156372);_0x4a9168&&(_0x156372['isActive']=!0x0,_0x1c0bc5&&(_0x4a9168['isAnimationDisabled']=!0x0,_0x4a9168['top']+=0x1),this['_alignToTargetRect'](_0x4a9168));}}['_detachFromContainer'](_0x12448a){if(this['view']['element']['remove'](),_0x12448a){for(const _0x513ae9 of _0x12448a)this['_destroySidebarItemView'](_0x513ae9);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x346c9b,_0x41ddab){_0x41ddab||(_0x41ddab=_0x346c9b['view']);const _0xec83b1=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0xec83b1,_0x346c9b),this['_annotationToSidebarItemView']['set'](_0x346c9b,_0xec83b1),_0xec83b1['content']['add'](_0x41ddab),this['listenTo'](_0x346c9b['view'],'change:targetRect',(_0x5a104f,_0x47e70f,_0xb7859f)=>{const _0x2f8fed=this['_getTargetTop'](_0x346c9b,_0xb7859f);_0xec83b1['_targetTop']!=_0x2f8fed&&(_0xec83b1['_targetTop']=_0x2f8fed,this['_setItemTop'](_0xec83b1,_0x2f8fed));}),this['listenTo'](_0xec83b1,'change:top',()=>{this['_recalculate'](_0xec83b1,'top');}),this['listenTo'](_0xec83b1,'change:bottom',()=>{this['_recalculate'](_0xec83b1,'bottom');}),this['_alignToTargetRect'](_0xec83b1);const _0x2397c3=this['_getItemBefore'](_0xec83b1);if(_0x2397c3)this['_alignAfterItem'](_0x2397c3,_0xec83b1)||this['_alignToTargetRect'](_0xec83b1);else this['_alignToTargetRect'](_0xec83b1);return this['_updateLastItem'](),this['view']['list']['add'](_0xec83b1),_0xec83b1;}['_alignForTopChange'](_0x2c8f0a){if(!_0x2c8f0a['content']['length'])return;const _0x46dca6=this['_getItemBefore'](_0x2c8f0a);if(!_0x46dca6)return;const _0x4ae7fa=this['_sidebarItemViewToAnnotation']['get'](_0x46dca6),_0x1c8cde=this['_activeAnnotation'];_0x1c8cde&&_0x1c8cde===_0x4ae7fa?this['_alignAfterItem'](_0x46dca6,_0x2c8f0a):this['_alignBeforeItem'](_0x2c8f0a,_0x46dca6);}['_alignForBottomChange'](_0x2d549a){if(!_0x2d549a['content']['length'])return;const _0x4c2a71=this['_getItemAfter'](_0x2d549a);if(!_0x4c2a71)return;const _0x3c3a1d=this['_sidebarItemViewToAnnotation']['get'](_0x4c2a71),_0x3d0928=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0xb40a87=this['_activeAnnotation'];_0xb40a87&&_0xb40a87===_0x3c3a1d&&_0x3d0928?(this['_alignBeforeItem'](_0x4c2a71,_0x2d549a),this['_alignAfterItem'](_0x2d549a,_0x4c2a71)):_0xb40a87&&_0xb40a87===_0x3c3a1d?this['_alignBeforeItem'](_0x4c2a71,_0x2d549a):this['_alignAfterItem'](_0x2d549a,_0x4c2a71);}['_recalculate'](_0x1e05c9,_0x26db66){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0xbc48e6,changedProp:_0x29a0be}of this['_recalculateBuffer'])'top'===_0x29a0be?this['_alignForTopChange'](_0xbc48e6):this['_alignForBottomChange'](_0xbc48e6);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x1e05c9,'changedProp':_0x26db66});}['getSidebarItemView'](_0x331866){return this['_annotationToSidebarItemView']['get'](_0x331866);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x343f93){const _0x38cf2b=this['getSidebarItemView'](_0x343f93);this['stopListening'](_0x38cf2b),this['stopListening'](_0x343f93['view']),_0x38cf2b['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x343f93),this['_sidebarItemViewToAnnotation']['delete'](_0x38cf2b);}['_createSidebarView'](){const _0x42ba38=new H(this['context']['locale']);return _0x42ba38['render'](),this['on']('change:_lastItem',(_0x503b1e,_0x59f2d5,_0x8a07ea,_0x558094)=>{_0x558094&&_0x42ba38['unbind']('minHeight'),_0x8a07ea?_0x42ba38['bind']('minHeight')['to'](_0x8a07ea,'bottom'):_0x42ba38['minHeight']=null;}),_0x42ba38;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x187b62){const _0x42bfc2=this['_sidebarItemViewToAnnotation']['get'](_0x187b62),_0x312272=_0x42bfc2&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x42bfc2)-0x1);return _0x312272&&this['getSidebarItemView'](_0x312272)||null;}['_getItemAfter'](_0x31632f){const _0x501646=this['_sidebarItemViewToAnnotation']['get'](_0x31632f),_0x4b1ea4=_0x501646&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x501646)+0x1);return _0x4b1ea4&&this['getSidebarItemView'](_0x4b1ea4)||null;}['_alignBeforeItem'](_0x330b93,_0x5a1627){_0x330b93['updateHeight']();const _0x12a58b=G(_0x5a1627['bottom']+this['_spaceBetweenItems'],_0x330b93['top']);return!!_0x12a58b&&(this['_setItemTop'](_0x5a1627,_0x5a1627['top']-_0x12a58b),!0x0);}['_alignAfterItem'](_0x5acdce,_0x447b7a){_0x5acdce['updateHeight']();const _0x49d558=G(_0x5acdce['bottom']+this['_spaceBetweenItems'],_0x447b7a['top']);return!!_0x49d558&&(this['_setItemTop'](_0x447b7a,_0x447b7a['top']+_0x49d558,!0x1),!0x0);}['_alignToTargetRect'](_0x2ba304){const _0x104422=this['_sidebarItemViewToAnnotation']['get'](_0x2ba304);if(!_0x104422||!_0x104422['target']||!_0x104422['targetRect'])return;const _0x50c41b=this['_getTargetTop'](_0x104422,_0x104422['targetRect']);this['_setItemTop'](_0x2ba304,_0x50c41b);}['_getTargetTop'](_0x10c1f3,_0x4c2425){if(null===_0x4c2425)return 0x0;if(_0x10c1f3['target']instanceof _0x3fbc4e)return _0x4c2425['top'];{const _0x1e841a=new _0x3fbc4e(this['view']['element'])['top'];return _0x4c2425['top']-_0x1e841a;}}['_setItemTop'](_0x17eb44,_0x56bad1,_0x569e81=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x569e81&&(_0x56bad1=Math['max'](_0x56bad1,this['_getMaxAvailableTop'](_0x17eb44))),_0x17eb44['top']=_0x56bad1;}['_getMaxAvailableTop'](_0x20f04a){let _0x4f739e=this['_getItemBefore'](_0x20f04a),_0x54ba57=0x0;for(;_0x4f739e;)_0x4f739e['updateHeight'](),_0x54ba57+=this['_spaceBetweenItems']+_0x4f739e['height'],_0x4f739e=this['_getItemBefore'](_0x4f739e);return _0x54ba57;}}function G(_0x4867e9,_0x4d1a80){return Math['max'](_0x4867e9-_0x4d1a80,0x0);}function g(_0x5b0295){return null!==_0x5b0295&&'object'==typeof _0x5b0295&&0x1===_0x5b0295['nodeType'];}class e extends _0x2228db{['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(_0x1671b3){super(_0x1671b3),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x2a8245(),this['_refreshPositioningDebounced']=_0x49b0b7(()=>{_0x1671b3['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0xe21196=this['context']['plugins']['get'](j),_0xbb4b67=this['context']['plugins']['get'](z);_0xe21196['register']('wideSidebar',this),_0xbb4b67['container']&&_0xe21196['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x5ae8f9){if(_0x5ae8f9===this['activeAnnotation'])return;const _0x32df38=this['context']['plugins']['get'](z);_0x32df38['_activeAnnotation']=_0x5ae8f9;const _0x4c77bf=this['activeAnnotation'];_0x32df38['refresh']({'blurredAnnotation':_0x4c77bf,'activatedAnnotation':_0x5ae8f9}),this['activeAnnotation']=_0x5ae8f9;}['attach'](_0x22ccbb){this['annotations']=_0x22ccbb;const _0x284b98=this['context']['plugins']['get'](z);if(_0x284b98['_annotations']=_0x22ccbb,this['isAttached'])throw new _0x2e6f8f('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x284b98,'set:container',()=>{this['detach'](),this['listenTo'](_0x284b98,'change:container',_0x345e55=>{_0x345e55['off'](),this['attach'](_0x22ccbb);});}),_0x284b98['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x3e5004=_0x5fe509=>{_0x5fe509['updateTargetRect'](),_0x284b98['addAnnotation'](_0x5fe509);};for(const _0x4b42ee of _0x22ccbb)_0x3e5004(_0x4b42ee);this['listenTo'](_0x22ccbb,'add',(_0x2703f6,_0x231d28)=>{_0x3e5004(_0x231d28);}),this['listenTo'](_0x22ccbb,'remove',(_0x590dc8,_0x2f11b8,_0x21f1bd)=>{_0x284b98['rearrange']({'removedAnnotation':_0x2f11b8,'previousAnnotation':_0x22ccbb['get'](_0x21f1bd-0x1),'nextAnnotation':_0x22ccbb['get'](_0x21f1bd+0x1)}),_0x2f11b8===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x22ccbb,'focus',(_0x389728,_0x4ecec2)=>{this['setActiveAnnotation'](_0x4ecec2);}),this['listenTo'](_0x22ccbb,'blur',()=>{this['setActiveAnnotation'](null);});const _0x25ecd1=this['context']instanceof _0xb420e9?this['context']['editors']:new _0x2a8245([this['context']]);for(const _0x3115c8 of _0x25ecd1)this['_integrateWithEditorAnnotations'](_0x3115c8);this['listenTo'](_0x25ecd1,'add',(_0x2740ed,_0x2bf9e0)=>{this['listenTo'](_0x2bf9e0,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x2bf9e0);});}),this['listenTo'](_0x25ecd1,'remove',(_0x196c49,_0x4a80b2)=>{_0x4a80b2['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x4a80b2['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x2e6f8f('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x1a78fb=this['context']['plugins']['get'](z);_0x1a78fb['_detachFromContainer'](this['annotations']),this['stopListening'](_0x1a78fb),this['stopListening'](this['annotations']),this['context']instanceof _0xb420e9&&this['stopListening'](this['context']['editors']);for(const _0x215bad of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x215bad);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x5f41b0){if(!_0x5f41b0['plugins']['has']('EditorAnnotations'))return;const _0x4f08b0=_0x5f41b0['plugins']['get']('EditorAnnotations'),_0x29e604=()=>{const _0x8f77d=_0x4f08b0['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x8f77d[0x0]||null);};this['listenTo'](_0x4f08b0,'refresh',_0x29e604),this['listenTo'](_0x4f08b0,'blur',(_0x4633ff,{isAnnotationTracked:_0x3cdbf9})=>{this['activeAnnotation']&&_0x3cdbf9(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x4f08b0,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x49a7be=>{_0x4f08b0['hasDomSelection']()&&(_0x29e604(),_0x49a7be['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x4f08b0);}['_destroyEditorAnnotationsIntegration'](_0x1b8f0c){this['stopListening'](_0x1b8f0c),this['_editorAnnotations']['remove'](_0x1b8f0c);}}class C extends _0x3c4ac3{['counterView'];constructor(_0x1634eb){super(_0x1634eb);const _0x53aeb0=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x1393cc,_0x1cbded)=>_0x1393cc?'...':_0x1cbded['toString']()),this['set']('annotationType',''),this['icon']=_0x482462,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x53aeb0['to']('annotationType',_0x11a3b7=>'ck-annotation-counter__badge--'+_0x11a3b7),_0x53aeb0['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x53aeb0['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x2228db{['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(_0x25b00d){super(_0x25b00d),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x5cce27())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x2a8245(),this['_refreshPositioningDebounced']=_0x49b0b7(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x3b1e98(this['context']['locale']),this['balloonPanelView']=new _0x5ae522(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x4bf8ea){this['annotations']=_0x4bf8ea;const _0x46d1b2=this['context']['plugins']['get'](z),_0x44ab4e=this['balloonPanelView'];if(_0x46d1b2['_annotations']=_0x4bf8ea,this['isAttached'])throw new _0x2e6f8f('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x46d1b2,'set:container',()=>{this['detach'](),this['listenTo'](_0x46d1b2,'change:container',_0x581564=>{_0x581564['off'](),this['attach'](_0x4bf8ea);});}),_0x46d1b2['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x99f12f=_0x501540=>{const _0x412d06=new C(this['context']['locale']);_0x46d1b2['addAnnotation'](_0x501540,_0x412d06),this['_annotationToNarrowView']['set'](_0x501540,_0x412d06),_0x412d06['bind']('isDirty','annotationType','number')['to'](_0x501540['view'],'isDirty','type','length'),_0x412d06['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x44ab4e['content']['first']!==_0x501540['view']?(this['_showBalloon'](_0x501540),_0x501540['view']['element']['focus'](),this['setActiveAnnotation'](_0x501540)):this['setActiveAnnotation'](null);});};for(const _0x2a30a5 of _0x4bf8ea)_0x99f12f(_0x2a30a5);this['listenTo'](_0x4bf8ea,'add',(_0x710ef9,_0x15786a)=>{_0x99f12f(_0x15786a);}),this['listenTo'](_0x4bf8ea,'remove',(_0x21e6e7,_0x44e805,_0x46ec15)=>{this['_annotationToNarrowView']['get'](_0x44e805)['destroy'](),this['_annotationToNarrowView']['delete'](_0x44e805),_0x46d1b2['rearrange']({'removedAnnotation':_0x44e805,'previousAnnotation':_0x4bf8ea['get'](_0x46ec15-0x1),'nextAnnotation':_0x4bf8ea['get'](_0x46ec15+0x1)}),_0x44e805===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x4bf8ea,'focus',(_0x4068d7,_0x4ce917)=>{this['setActiveAnnotation'](_0x4ce917);}),this['listenTo'](_0x4bf8ea,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x1791c1,_0x463188)=>{_0x463188['keyCode']===_0x3fe5b7['esc']&&_0x44ab4e['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x44ab4e['content']['first']),this['_hideBalloon'](),_0x463188['stopPropagation'](),_0x463188['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x3faa67,_0x4d2dc1)=>{const _0x277da5=_0x4d2dc1['target'];_0x44ab4e['isVisible']&&_0x44ab4e['element']['contains'](_0x277da5)||_0x46d1b2['view']['element']['contains'](_0x277da5)||_0x3faa67['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x3d0990=>_0x3d0990['contains'](_0x277da5))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x370793=this['context']instanceof _0xb420e9?this['context']['editors']:new _0x2a8245([this['context']]);for(const _0x3efc9a of _0x370793)this['_integrateWithEditorAnnotations'](_0x3efc9a);this['listenTo'](_0x370793,'add',(_0x25b71a,_0x55a7ce)=>{this['listenTo'](_0x55a7ce,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x55a7ce);});}),this['listenTo'](_0x370793,'remove',(_0x19e713,_0x59f1f7)=>{_0x59f1f7['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x59f1f7['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x1b3e26){if(_0x1b3e26===this['activeAnnotation'])return;const _0x3cdd8e=this['context']['plugins']['get'](z);if(_0x3cdd8e['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x1b3e26,'disableAnimationOnActivatedAnnotation':!0x0}),_0x1b3e26)_0x3cdd8e['getSidebarItemView'](_0x1b3e26)?this['_showBalloon'](_0x1b3e26):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x1b3e26;}['detach'](){if(!this['isAttached'])throw new _0x2e6f8f('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x26306e=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x36544e=>_0x36544e['destroy']()),this['_annotationToNarrowView']['clear'](),_0x26306e['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0xb420e9&&this['stopListening'](this['context']['editors']);for(const _0x3e2758 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x3e2758);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'](_0x37eed5){if(!_0x37eed5['plugins']['has']('EditorAnnotations'))return;const _0x3db97b=_0x37eed5['plugins']['get']('EditorAnnotations'),_0x1adef5=this['context']['plugins']['get'](z),_0x57c8b5=this['annotations'],_0x579e91=this['balloonPanelView'],_0x262abe=()=>{const _0x4918d4=_0x3db97b['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x4918d4),this['setActiveAnnotation'](_0x4918d4[0x0]||null);};this['listenTo'](_0x3db97b,'refresh',_0x262abe),this['listenTo'](_0x3db97b,'blur',(_0x2eb4e8,{isAnnotationTracked:_0x9c063b})=>{this['activeAnnotation']&&_0x9c063b(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x3db97b,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x57c8b5,'blur',_0x5d275b=>{_0x3db97b['hasDomSelection']()&&_0x5d275b['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x122397,_0xc9bd61)=>{const _0x4ca4ca=_0xc9bd61['target'];_0x579e91['isVisible']&&_0x579e91['element']['contains'](_0x4ca4ca)||_0x1adef5['view']['element']['contains'](_0x4ca4ca)||this['activeAnnotation']&&_0x3db97b['hasDomSelection']()&&(_0x262abe(),_0x122397['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x3db97b);}['_destroyEditorAnnotationsIntegration'](_0x2e2bcc){_0x2e2bcc&&(this['stopListening'](_0x2e2bcc),this['_editorAnnotations']['remove'](_0x2e2bcc));}['_setSelectedAnnotations'](_0x17f5b8){for(const _0x3c1ffb of this['_selectedAnnotations'])_0x17f5b8['includes'](_0x3c1ffb)||this['_manuallyClosedAnnotationViews']['delete'](_0x3c1ffb['view']);this['_selectedAnnotations']=_0x17f5b8;}['_refreshPositioning'](){const _0x6b3b8d=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x6b3b8d['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x2a9f51){if(this['_manuallyClosedAnnotationViews']['has'](_0x2a9f51['view']))return;const _0x3d964f=this['balloonPanelView']['content']['first'];_0x3d964f!==_0x2a9f51['view']?(_0x3d964f&&this['_detachListeners'](_0x3d964f),this['_attachListeners'](_0x2a9f51['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x2a9f51['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x2182a6=this['balloonPanelView']['content']['first'],_0x11f6c6=_0x2182a6&&this['annotations']['getByView'](_0x2182a6);if(!_0x11f6c6||!this['_annotationToNarrowView']['has'](_0x11f6c6))return;const _0x335f01=this['_annotationToNarrowView']['get'](_0x11f6c6)['element'],_0x2186b8=(function(){const _0x4dd8c4=_0x5ae522['defaultPositions'];return[_0x4dd8c4['southArrowNorthEast'],_0x4dd8c4['northArrowSouthEast'],_0x4dd8c4['southArrowNorth'],_0x4dd8c4['northArrowSouth'],_0x4dd8c4['southArrowNorthWest'],_0x4dd8c4['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x335f01,'positions':_0x2186b8});}['_hideBalloon'](){const _0x36981f=this['balloonPanelView'],_0x598581=_0x36981f['content']['first'];_0x598581&&(this['_detachListeners'](_0x598581),_0x36981f['unpin'](),_0x36981f['content']['clear']());}['_attachListeners'](_0x4bddbf){this['listenTo'](_0x4bddbf,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x4bddbf,'Esc',(_0x5f0d32,_0x45e49a)=>{this['_manuallyClosedAnnotationViews']['add'](_0x4bddbf),this['_hideBalloon'](),_0x45e49a();});}['_detachListeners'](_0x10b6a1){this['stopListening'](_0x10b6a1);}}class c extends _0x41aca7{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[b,_0x300697,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x213cf1){super(_0x213cf1),_0x213cf1['editing']['view']['addObserver'](_0x2b71be),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x213cf1['plugins']['get'](_0x300697),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x180d0c=this['editor']['plugins']['get'](j);_0x180d0c['context']===this['editor']&&(_0x180d0c['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x36a04f,_0x2a8cc4)=>{const _0x5d76d4=this['_balloon'];if(this['isAttached']&&_0x5d76d4['visibleView']){const _0x2ac1e4=this['annotations']['getByView'](_0x5d76d4['visibleView']);_0x2ac1e4&&this['_closeAnnotation'](_0x2ac1e4),_0x2a8cc4();}}));}['afterInit'](){const _0x3c151a=this['editor']['plugins']['get'](j);_0x3c151a['context']===this['editor']&&(_0x3c151a['hasActive']()||_0x3c151a['switchTo']('inline'));}['setActiveAnnotation'](_0x1cc925){_0x1cc925!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x1cc925&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x1cc925)&&this['_addAnnotationToBalloon'](_0x1cc925,!0x0),_0x1cc925['isActive']=!0x0),_0x1cc925||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x1cc925);}['attach'](_0x29174f){this['annotations']=_0x29174f;const _0xb2ca41=this['editor']['plugins']['get'](j),_0x23066f=this['_balloon'];if(this['isAttached'])throw new _0x2e6f8f('inlineannotations-attach-already-attached',this);if(_0xb2ca41['context']!==this['editor'])throw new _0x2e6f8f('inlineannotations-not-allowed-with-context',this);const _0x52596f=this['editor']['plugins']['get'](b);this['listenTo'](_0x52596f,'refresh',()=>{const _0x58f50c=_0x52596f['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x346c4e,_0x47e905;!this['_forceRefresh']&&(_0x346c4e=_0x58f50c,_0x47e905=this['_selectedAnnotations'],_0x346c4e['length']===_0x47e905['length']&&_0x346c4e['every'](_0x4969c0=>_0x47e905['includes'](_0x4969c0)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x58f50c),this['setActiveAnnotation'](_0x58f50c[0x0]||null));}),this['listenTo'](_0x52596f,'blur',(_0x11d196,{isAnnotationTracked:_0x524f4e})=>{this['activeAnnotation']&&_0x524f4e(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x1a8f96,_0x37def5,_0x116af9)=>{_0x116af9||this['setActiveAnnotation'](null);}),this['listenTo'](_0x29174f,'remove',(_0x44b2e0,_0x58e578)=>{this['_removeAnnotationFromBalloon'](_0x58e578),_0x58e578===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x23066f,'change:visibleView',(_0x3312a5,_0x1cbc8e,_0x49f27a,_0x18c564)=>{_0x18c564&&this['stopListening'](_0x18c564);const _0x294272=_0x29174f['getByView'](_0x49f27a);_0x49f27a&&_0x294272&&(this['listenTo'](_0x49f27a,'change:height',()=>{_0x23066f['updatePosition']();}),this['listenTo'](_0x49f27a,'Esc',()=>{this['_closeAnnotation'](_0x294272),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x294272&&this['setActiveAnnotation'](_0x294272));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x23066f['visibleView']&&(_0x29174f['getByView'](_0x23066f['visibleView'])&&_0x23066f['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 _0x2e6f8f('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x52a444 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x52a444);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x16e912){for(const _0x1215db of this['_selectedAnnotations'])_0x16e912['includes'](_0x1215db)||this['_manuallyClosed']['delete'](_0x1215db);for(const _0x2bd44f of this['annotations'])_0x16e912['includes'](_0x2bd44f)||this['_removeAnnotationFromBalloon'](_0x2bd44f);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x1dd0fd of _0x16e912)this['_addAnnotationToBalloon'](_0x1dd0fd);}this['_selectedAnnotations']=_0x16e912;}['_addAnnotationToBalloon'](_0x4acb15,_0x1ee029=!0x1){this['_manuallyClosed']['has'](_0x4acb15)||(this['_addedAnnotations']['has'](_0x4acb15)||this['_balloon']['hasView'](_0x4acb15['view'])||(this['_addedAnnotations']['add'](_0x4acb15),this['_balloon']['add']({'stackId':_0x4acb15['view']['id'],'view':_0x4acb15['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x4acb15)}})),_0x1ee029&&this['_balloon']['showStack'](_0x4acb15['view']['id']));}['_getBalloonTargetForAnnotation'](_0x2fefe4){const _0x1f8330=_0x2fefe4['target'],_0x2e2300=this['editor']['editing']['view'],_0x486243=_0x2e2300['document']['selection']['getFirstRange'](),_0xb6235b=_0x2e2300['domConverter']['viewRangeToDom'](_0x486243);if(_0xb6235b['collapse'](!0x0),_0x1f8330){if(_0x1f8330 instanceof _0x3fbc4e)return _0x1f8330;let _0x19c965=[];for(const _0x53bf0d of _0x1f8330)_0x19c965['push'](...F(_0x53bf0d['getClientRects']()));_0x19c965=function(_0x258605){const _0x48f0e2=[];let _0x2974e9=_0x258605[0x0];for(let _0x231bed=0x1;_0x231bed<_0x258605['length'];_0x231bed++)P(_0x2974e9,_0x258605[_0x231bed])?_0x2974e9['width']+=_0x258605[_0x231bed]['width']:(_0x48f0e2['push'](_0x2974e9),_0x2974e9=_0x258605[_0x231bed]);return _0x48f0e2['push'](_0x2974e9),_0x48f0e2;}(_0x19c965);const _0x353eb9=_0xb6235b['getBoundingClientRect']();return _0x19c965['find'](_0x176c20=>_0x176c20['top']<=_0x353eb9['top']&&_0x176c20['bottom']>=_0x353eb9['bottom']&&_0x176c20['left']<=_0x353eb9['left']&&_0x176c20['right']>=_0x353eb9['right'])||_0x19c965[0x0];}return _0x2fefe4['targetRect']||_0xb6235b;}['_removeAnnotationFromBalloon'](_0x4278cc){this['_addedAnnotations']['has'](_0x4278cc)&&this['_balloon']['hasView'](_0x4278cc['view'])&&(this['_addedAnnotations']['delete'](_0x4278cc),this['_balloon']['remove'](_0x4278cc['view']));}['_closeAnnotation'](_0x4327f4){this['_manuallyClosed']['add'](_0x4327f4),this['_removeAnnotationFromBalloon'](_0x4327f4);}}function F(_0xb3316e){return Array['from'](_0xb3316e)['map'](DOMRect['fromRect']);}function P(_0x3156e1,_0x4737ba){return _0x3156e1['top']===_0x4737ba['top']&&_0x3156e1['bottom']===_0x4737ba['bottom']&&_0x3156e1['right']===_0x4737ba['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x4cf704,_0x5cac8e){super(_0x4cf704),this['set']('isEmpty',!_0x5cac8e['length']),this['focusTracker']=new _0x19913b(),this['_annotationViews']=_0x5cac8e,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x7bfb99({'focusables':_0x5cac8e,'focusTracker':this['focusTracker']}),this['listenTo'](_0x5cac8e,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x5cac8e,'remove',(_0x13a545,_0x88bcd1)=>{_0x88bcd1['isActive']&&this['focus'](),_0x5cac8e['length']||(this['isEmpty']=!0x0);});const _0x5576c0=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x4cf704,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x5cac8e},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x5576c0['if']('isEmpty','ck-hidden',_0x26f27c=>!_0x26f27c)]},'children':[{'text':N(_0x4cf704,'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 _0x514783 of this['_annotationViews'])this['focusTracker']['add'](_0x514783['element']);this['_annotationViews']['on']('change',(_0xbae1bb,{added:_0x445a37,removed:_0x49dea5})=>{for(const _0x5a792d of _0x445a37)this['focusTracker']['add'](_0x5a792d['element']);for(const _0x4275a5 of _0x49dea5)this['focusTracker']['remove'](_0x4275a5['element']);});}}class p extends _0x2228db{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x42b085){super(_0x42b085),this['archivedThreads']=new _0x2a8245();}['init'](){const _0x1a5411=this['context'],_0x29d562=_0x1a5411['plugins']['get'](o),_0x6a89ce=_0x1a5411['plugins']['get'](y);this['listenTo'](_0x29d562,'addCommentThread',(_0x330650,{threadId:_0x211c70})=>{const _0x149596=_0x29d562['getCommentThread'](_0x211c70);_0x149596['archivedAt']&&this['archivedThreads']['add'](_0x149596,this['_calculatePosition'](_0x149596['archivedAt'])),this['listenTo'](_0x149596,'change:archivedAt',(_0x5c122a,_0x4ac44f,_0x5bb6fc)=>{_0x5bb6fc?this['archivedThreads']['has'](_0x149596)||this['archivedThreads']['add'](_0x149596,this['_calculatePosition'](_0x149596['archivedAt'])):this['archivedThreads']['has'](_0x149596)&&this['archivedThreads']['remove'](_0x149596);});}),this['listenTo'](_0x29d562,'removeCommentThread',(_0x59810e,{threadId:_0x4fbbfd})=>{const _0x34bbca=_0x29d562['getCommentThread'](_0x4fbbfd);this['stopListening'](_0x34bbca),this['archivedThreads']['has'](_0x34bbca)&&this['archivedThreads']['remove'](_0x34bbca);},{'priority':'highest'}),this['listenTo'](_0x6a89ce['collection'],'focus',(_0x2b7477,_0x9f40ab)=>{_0x9f40ab['isVisible']||(_0x9f40ab['isActive']=!0x0,_0x6a89ce['activate'](_0x9f40ab));});}['_calculatePosition'](_0x22c321){const _0x44208d=[...this['archivedThreads']]['findIndex'](_0x418018=>_0x418018['archivedAt']<_0x22c321);return _0x44208d>-0x1?_0x44208d:this['archivedThreads']['length'];}}class a extends _0x41aca7{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x4c9c9e];}constructor(_0x4e82ed){super(_0x4e82ed),this['annotationViews']=new _0x5e227b(),this['_pendingThreads']=[];}['init'](){const _0x6a355f=this['editor'],_0xd3c448=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x6a355f['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x3c4ac3,!0x0)),_0x6a355f['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x2d84d9=this['_createCommentsArchiveButton'](_0x27f8f3);return _0x2d84d9['set']({'role':'menuitemcheckbox'}),_0x2d84d9;});const _0x362957=_0x6a355f['plugins']['get'](p),_0x283e8e=_0x6a355f['plugins']['get']('Annotations'),_0xa9e51e=_0x6a355f['plugins']['get']('CommentsRepository');_0x362957['archivedThreads']['forEach'](_0x4e0cf2=>{this['_handleNewThread'](_0x4e0cf2);}),this['listenTo'](_0x362957['archivedThreads'],'add',(_0x430af9,_0x208475)=>{this['_handleNewThread'](_0x208475);}),this['listenTo'](_0x283e8e['collection'],'add',(_0x1b6be5,_0x8c9fa4)=>{const _0x54a684=this['_pendingThreads']['find'](_0x1cc9b2=>{const _0x10961e=_0xa9e51e['_threadToController']['get'](_0x1cc9b2);return _0x10961e&&_0x8c9fa4['innerView']===_0x10961e['view'];});if(_0x54a684){const _0x1dd7d2=this['_calculatePosition'](_0x54a684['archivedAt']);this['annotationViews']['add'](_0x8c9fa4['view'],_0x1dd7d2),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x54a684),0x1);}}),this['listenTo'](_0x362957['archivedThreads'],'remove',(_0x337fd7,_0x1af30f)=>{const _0x509307=_0x6a355f['config']['get']('collaboration.channelId');if(!_0x509307||_0x1af30f['channelId']===_0x509307){if(this['_pendingThreads']['includes'](_0x1af30f))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x1af30f),0x1);else{const _0x354733=_0xa9e51e['_threadToController']['get'](_0x1af30f),_0x23019e=_0x283e8e['getByInnerView'](_0x354733['view']);this['annotationViews']['remove'](_0x23019e['view']),this['stopListening'](_0x23019e['focusableElements']);}}}),this['listenTo'](_0x283e8e['collection'],'add',(_0x4e830e,_0x5007b6)=>{this['listenTo'](_0x5007b6,'escape',_0xd3c448);}),this['listenTo'](_0x283e8e['collection'],'remove',(_0x252b79,_0x1eb96e)=>{this['stopListening'](_0x1eb96e,'escape',_0xd3c448);});}['_handleNewThread'](_0x33bb9a){const _0x34704b=this['editor']['plugins']['get']('CommentsRepository'),_0x2ea861=this['editor']['plugins']['get']('Annotations'),_0x314fc0=this['editor']['config']['get']('collaboration.channelId');if(!_0x314fc0||_0x33bb9a['channelId']===_0x314fc0){const _0x2dc6bd=_0x34704b['_threadToController']['get'](_0x33bb9a);if(!_0x2dc6bd)return void this['_pendingThreads']['push'](_0x33bb9a);const _0x529c00=this['_calculatePosition'](_0x33bb9a['archivedAt']),_0x6419f4=_0x2ea861['getByInnerView'](_0x2dc6bd['view']);_0x6419f4['isVisible']&&_0x2ea861['_visibleAnnotations']['remove'](_0x6419f4),this['annotationViews']['add'](_0x6419f4['view'],_0x529c00);}}['_calculatePosition'](_0x362247){const _0x128ac7=this['editor']['config']['get']('collaboration.channelId'),_0x432948=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0xfc74a1=>_0xfc74a1['channelId']===_0x128ac7)['findIndex'](_0x569c65=>_0x569c65['archivedAt']<_0x362247);return _0x432948<0x0||_0x432948>this['annotationViews']['length']?this['annotationViews']['length']:_0x432948-0x1;}['_toggleDialog'](){const _0x36a56f=this['editor'],_0x20c41a=_0x36a56f['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x36a56f['locale'],this['annotationViews'])),'commentsArchive'===_0x20c41a['id']?_0x20c41a['hide']():_0x20c41a['show']({'id':'commentsArchive','title':N(_0x36a56f['locale'],'COMMENTS_ARCHIVE'),'icon':_0x37db05,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x2b4a03['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x1b017b,_0x56af73=!0x1){const _0x5bcbf2=this['editor']['locale'],_0x1fb88f=this['editor']['plugins']['get']('Dialog'),_0xd9c7b9=new _0x1b017b(_0x5bcbf2);return _0xd9c7b9['bind']('isEnabled')['to'](this,'isEnabled'),_0xd9c7b9['bind']('isOn')['to'](_0x1fb88f,'id',_0x2058f1=>'commentsArchive'===_0x2058f1),_0xd9c7b9['set']({'label':N(_0x5bcbf2,'COMMENTS_ARCHIVE'),'icon':_0x37db05,'isToggleable':!0x0}),_0x56af73&&(_0xd9c7b9['tooltip']=!0x0),this['listenTo'](_0xd9c7b9,'execute',()=>this['_toggleDialog']()),_0xd9c7b9;}['_hideDialogOnAnnotationEscape']=_0x4bb102=>{const _0x5db3aa=_0x4bb102['source'];if(!this['annotationViews']['has'](_0x5db3aa['view']))return;const _0x4875be=this['editor']['plugins']['get']('Dialog');_0x4875be['isOpen']&&'commentsArchive'===_0x4875be['id']&&(_0x4875be['hide'](),_0x4bb102['stop']());};}class gi extends _0x41aca7{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};