@ckeditor/ckeditor5-comments 46.1.1 → 47.0.0-alpha.1

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 (201) hide show
  1. package/build/comments.js +1 -1
  2. package/dist/index-editor.css +2 -46
  3. package/dist/index.css +2 -48
  4. package/dist/index.js +11 -11
  5. package/dist/translations/af.js +1 -1
  6. package/dist/translations/af.umd.js +1 -1
  7. package/dist/translations/ar.js +1 -1
  8. package/dist/translations/ar.umd.js +1 -1
  9. package/dist/translations/ast.js +1 -1
  10. package/dist/translations/ast.umd.js +1 -1
  11. package/dist/translations/az.js +1 -1
  12. package/dist/translations/az.umd.js +1 -1
  13. package/dist/translations/be.js +1 -1
  14. package/dist/translations/be.umd.js +1 -1
  15. package/dist/translations/bg.js +1 -1
  16. package/dist/translations/bg.umd.js +1 -1
  17. package/dist/translations/bn.js +1 -1
  18. package/dist/translations/bn.umd.js +1 -1
  19. package/dist/translations/bs.js +1 -1
  20. package/dist/translations/bs.umd.js +1 -1
  21. package/dist/translations/ca.js +1 -1
  22. package/dist/translations/ca.umd.js +1 -1
  23. package/dist/translations/cs.js +1 -1
  24. package/dist/translations/cs.umd.js +1 -1
  25. package/dist/translations/da.js +1 -1
  26. package/dist/translations/da.umd.js +1 -1
  27. package/dist/translations/de-ch.js +1 -1
  28. package/dist/translations/de-ch.umd.js +1 -1
  29. package/dist/translations/de.js +1 -1
  30. package/dist/translations/de.umd.js +1 -1
  31. package/dist/translations/el.js +1 -1
  32. package/dist/translations/el.umd.js +1 -1
  33. package/dist/translations/en-au.js +1 -1
  34. package/dist/translations/en-au.umd.js +1 -1
  35. package/dist/translations/en-gb.js +1 -1
  36. package/dist/translations/en-gb.umd.js +1 -1
  37. package/dist/translations/en.js +1 -1
  38. package/dist/translations/en.umd.js +1 -1
  39. package/dist/translations/eo.js +1 -1
  40. package/dist/translations/eo.umd.js +1 -1
  41. package/dist/translations/es-co.js +1 -1
  42. package/dist/translations/es-co.umd.js +1 -1
  43. package/dist/translations/es.js +1 -1
  44. package/dist/translations/es.umd.js +1 -1
  45. package/dist/translations/et.js +1 -1
  46. package/dist/translations/et.umd.js +1 -1
  47. package/dist/translations/eu.js +1 -1
  48. package/dist/translations/eu.umd.js +1 -1
  49. package/dist/translations/fa.js +1 -1
  50. package/dist/translations/fa.umd.js +1 -1
  51. package/dist/translations/fi.js +1 -1
  52. package/dist/translations/fi.umd.js +1 -1
  53. package/dist/translations/fr.js +1 -1
  54. package/dist/translations/fr.umd.js +1 -1
  55. package/dist/translations/gl.js +1 -1
  56. package/dist/translations/gl.umd.js +1 -1
  57. package/dist/translations/gu.js +1 -1
  58. package/dist/translations/gu.umd.js +1 -1
  59. package/dist/translations/he.js +1 -1
  60. package/dist/translations/he.umd.js +1 -1
  61. package/dist/translations/hi.js +1 -1
  62. package/dist/translations/hi.umd.js +1 -1
  63. package/dist/translations/hr.js +1 -1
  64. package/dist/translations/hr.umd.js +1 -1
  65. package/dist/translations/hu.js +1 -1
  66. package/dist/translations/hu.umd.js +1 -1
  67. package/dist/translations/hy.js +1 -1
  68. package/dist/translations/hy.umd.js +1 -1
  69. package/dist/translations/id.js +1 -1
  70. package/dist/translations/id.umd.js +1 -1
  71. package/dist/translations/it.js +1 -1
  72. package/dist/translations/it.umd.js +1 -1
  73. package/dist/translations/ja.js +1 -1
  74. package/dist/translations/ja.umd.js +1 -1
  75. package/dist/translations/jv.js +1 -1
  76. package/dist/translations/jv.umd.js +1 -1
  77. package/dist/translations/kk.js +1 -1
  78. package/dist/translations/kk.umd.js +1 -1
  79. package/dist/translations/km.js +1 -1
  80. package/dist/translations/km.umd.js +1 -1
  81. package/dist/translations/kn.js +1 -1
  82. package/dist/translations/kn.umd.js +1 -1
  83. package/dist/translations/ko.js +1 -1
  84. package/dist/translations/ko.umd.js +1 -1
  85. package/dist/translations/ku.js +1 -1
  86. package/dist/translations/ku.umd.js +1 -1
  87. package/dist/translations/lt.js +1 -1
  88. package/dist/translations/lt.umd.js +1 -1
  89. package/dist/translations/lv.js +1 -1
  90. package/dist/translations/lv.umd.js +1 -1
  91. package/dist/translations/ms.js +1 -1
  92. package/dist/translations/ms.umd.js +1 -1
  93. package/dist/translations/nb.js +1 -1
  94. package/dist/translations/nb.umd.js +1 -1
  95. package/dist/translations/ne.js +1 -1
  96. package/dist/translations/ne.umd.js +1 -1
  97. package/dist/translations/nl.js +1 -1
  98. package/dist/translations/nl.umd.js +1 -1
  99. package/dist/translations/no.js +1 -1
  100. package/dist/translations/no.umd.js +1 -1
  101. package/dist/translations/oc.js +1 -1
  102. package/dist/translations/oc.umd.js +1 -1
  103. package/dist/translations/pl.js +1 -1
  104. package/dist/translations/pl.umd.js +1 -1
  105. package/dist/translations/pt-br.js +1 -1
  106. package/dist/translations/pt-br.umd.js +1 -1
  107. package/dist/translations/pt.js +1 -1
  108. package/dist/translations/pt.umd.js +1 -1
  109. package/dist/translations/ro.js +1 -1
  110. package/dist/translations/ro.umd.js +1 -1
  111. package/dist/translations/ru.js +1 -1
  112. package/dist/translations/ru.umd.js +1 -1
  113. package/dist/translations/si.js +1 -1
  114. package/dist/translations/si.umd.js +1 -1
  115. package/dist/translations/sk.js +1 -1
  116. package/dist/translations/sk.umd.js +1 -1
  117. package/dist/translations/sl.js +1 -1
  118. package/dist/translations/sl.umd.js +1 -1
  119. package/dist/translations/sq.js +1 -1
  120. package/dist/translations/sq.umd.js +1 -1
  121. package/dist/translations/sr-latn.js +1 -1
  122. package/dist/translations/sr-latn.umd.js +1 -1
  123. package/dist/translations/sr.js +1 -1
  124. package/dist/translations/sr.umd.js +1 -1
  125. package/dist/translations/sv.js +1 -1
  126. package/dist/translations/sv.umd.js +1 -1
  127. package/dist/translations/th.js +1 -1
  128. package/dist/translations/th.umd.js +1 -1
  129. package/dist/translations/ti.js +1 -1
  130. package/dist/translations/ti.umd.js +1 -1
  131. package/dist/translations/tk.js +1 -1
  132. package/dist/translations/tk.umd.js +1 -1
  133. package/dist/translations/tr.js +1 -1
  134. package/dist/translations/tr.umd.js +1 -1
  135. package/dist/translations/tt.js +1 -1
  136. package/dist/translations/tt.umd.js +1 -1
  137. package/dist/translations/ug.js +1 -1
  138. package/dist/translations/ug.umd.js +1 -1
  139. package/dist/translations/uk.js +1 -1
  140. package/dist/translations/uk.umd.js +1 -1
  141. package/dist/translations/ur.js +1 -1
  142. package/dist/translations/ur.umd.js +1 -1
  143. package/dist/translations/uz.js +1 -1
  144. package/dist/translations/uz.umd.js +1 -1
  145. package/dist/translations/vi.js +1 -1
  146. package/dist/translations/vi.umd.js +1 -1
  147. package/dist/translations/zh-cn.js +1 -1
  148. package/dist/translations/zh-cn.umd.js +1 -1
  149. package/dist/translations/zh.js +1 -1
  150. package/dist/translations/zh.umd.js +1 -1
  151. package/package.json +18 -18
  152. package/src/annotations/annotation.js +2 -2
  153. package/src/annotations/annotationcollection.js +1 -1
  154. package/src/annotations/annotations.js +1 -1
  155. package/src/annotations/annotationsuis.js +1 -1
  156. package/src/annotations/editorannotations.js +1 -1
  157. package/src/annotations/inlineannotations.js +1 -1
  158. package/src/annotations/narrowsidebar.js +1 -1
  159. package/src/annotations/sidebar.js +1 -1
  160. package/src/annotations/view/annotationcounterbuttonview.js +1 -1
  161. package/src/annotations/view/annotationview.js +1 -1
  162. package/src/annotations/view/sidebaritemview.js +2 -2
  163. package/src/annotations/view/sidebarview.js +2 -2
  164. package/src/annotations/widesidebar.js +1 -1
  165. package/src/comments/addcommentthreadcommand.js +1 -1
  166. package/src/comments/commentsarchive.js +1 -1
  167. package/src/comments/commentsarchiveui.js +1 -1
  168. package/src/comments/commentsediting.js +1 -1
  169. package/src/comments/commentsrepository.d.ts +1 -1
  170. package/src/comments/commentsrepository.js +3 -3
  171. package/src/comments/commentsui.js +1 -1
  172. package/src/comments/integrations/clipboard.js +1 -1
  173. package/src/comments/integrations/commentsrestrictededitingmode.js +1 -1
  174. package/src/comments/integrations/importword.js +1 -1
  175. package/src/comments/integrations/showcommenthighlights.js +1 -1
  176. package/src/comments/ui/commenteditor/commenteditor.js +2 -2
  177. package/src/comments/ui/commenteditor/commenteditorui.js +1 -1
  178. package/src/comments/ui/commenteditor/commenteditoruiview.js +1 -1
  179. package/src/comments/ui/commentthreadcontroller.js +2 -2
  180. package/src/comments/ui/view/basecommentthreadview.js +1 -1
  181. package/src/comments/ui/view/basecommentview.js +1 -1
  182. package/src/comments/ui/view/collapsedcommentsview.js +1 -1
  183. package/src/comments/ui/view/commentcontentview.js +1 -1
  184. package/src/comments/ui/view/commentinputview.js +1 -1
  185. package/src/comments/ui/view/commentsarchiveview.js +1 -1
  186. package/src/comments/ui/view/commentslistview.js +1 -1
  187. package/src/comments/ui/view/commentthreadheadercontextview.js +1 -1
  188. package/src/comments/ui/view/commentthreadheaderview.js +1 -1
  189. package/src/comments/ui/view/commentthreadinputview.js +1 -1
  190. package/src/comments/ui/view/commentthreadview.d.ts +0 -2
  191. package/src/comments/ui/view/commentthreadview.js +2 -2
  192. package/src/comments/ui/view/commentview.d.ts +1 -5
  193. package/src/comments/ui/view/commentview.js +2 -2
  194. package/src/comments.js +1 -1
  195. package/src/commentsonly.js +1 -1
  196. package/src/index.js +1 -1
  197. package/src/utils/common-translations.js +1 -1
  198. package/src/utils/createmutationobserver.js +1 -1
  199. package/src/utils/splitmarkername.js +1 -1
  200. package/theme/comment.css +0 -12
  201. package/theme/commentthread.css +2 -38
package/dist/index.js CHANGED
@@ -20,14 +20,14 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Editor as _0x500d72,ContextPlugin as _0x5d2528,PendingActions as lt,Command as _0x324d2c,Plugin as _0x347641,Context as _0x3a1751}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x40f554,uid as _0x1f2855,KeystrokeHandler as jt,FocusTracker as _0x2d3c14,diff as qt,Collection as _0x294a7b,Rect as _0x3e5e72,CKEditorError as _0x4e095a,first as _0x7a1387,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0xfe978c,keyCodes as _0x3263c4}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as Ft,AriaDescriptionView as Et,setupThreadKeyboardNavigation as Vt,ConfirmMixin as $t,LateFocusButtonView as Jt,trimHtml as Lt,LateFocusDropdownButtonView as _0x2de17b,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x56008a}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x44a384}from'es-toolkit/compat';import{IconUndo as Gt,IconCheck as Qt,IconPencil as ti,IconRemoveComment as Zt,IconThreeVerticalDots as _0x14cf40,IconAddComment as _0x5474b9,IconCommentsArchive as _0x2ce601}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as _0x4fb4a6,InlineEditableUIView as _0x2a7ab5,EditorUI as ts,View as kt,FocusCycler as _0x58c694,ButtonView as _0x55680e,ViewCollection as _0x58b265,createDropdown as _0x1cbde8,ListView as _0x358ded,focusChildOnDropdownOpen as _0x1d97d8,ListItemView as _0x51603e,MenuBarMenuListItemButtonView as _0x5f2010,BodyCollection as _0x4bf118,BalloonPanelView as _0x28f2bd,ContextualBalloon as _0x1c40ce,Dialog as _0x247bd7,DialogViewPosition as _0x277bfc}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as _0x440a24,enableViewPlaceholder as _0x3825f1,MouseObserver as _0x2497b2}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as _0x282aa3,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as _0x2f28c6,ShiftEnter as _0x360144}from'@ckeditor/ckeditor5-enter/dist/index.js';import{SelectAll as _0x43f90d}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as _0x7c3585}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as _0xf3b8a9}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as _0x2b1ed9}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x55b371}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x4c4665}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
- _0x40f554(){['model'];['view'];constructor(_0x280004,_0x49059b){super(),this['model']=_0x280004,this['model']['_isAttached']=!0x0,this['view']=_0x49059b,this['listenTo'](_0x49059b,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x49059b,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x49059b,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x49059b,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x49059b,'addComment',(_0x18c6d6,_0x4a6426)=>this['addComment'](_0x4a6426)),this['listenTo'](_0x49059b,'updateComment',(_0x12bfeb,_0x3f05a6,_0x3d907e)=>this['updateComment'](_0x3f05a6,_0x3d907e)),this['listenTo'](_0x49059b,'removeComment',(_0x5cdf44,_0x5e20a2)=>this['removeComment'](_0x5e20a2));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x2caf2b){this['model']['addComment']({'content':_0x2caf2b,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x2bc3dc,_0x45c48e){this['model']['getComment'](_0x2bc3dc)['update']({'content':_0x45c48e});}['removeComment'](_0x26a887){this['model']['getComment'](_0x26a887)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x50e893,_0x3dbff1,_0x16dd45){const t=_0x50e893['t'];switch(_0x3dbff1){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'},_0x16dd45);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'},_0x16dd45);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'},_0x16dd45);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'},_0x16dd45);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x16dd45);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'},_0x16dd45);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'},_0x16dd45);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'},_0x16dd45);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 is extends _0x4fb4a6{['main'];['editable'];constructor(_0x352c88,_0x336f6f){super(_0x352c88);const _0x3a5777=_0x1f2855();this['main']=this['createCollection'](),this['editable']=new _0x2a7ab5(_0x352c88,_0x336f6f,void 0x0,{'label':()=>N(_0x352c88,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x352c88['uiLanguageDirection'],'lang':_0x352c88['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x3a5777},'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 ri extends ts{['view'];constructor(_0x12baf5){super(_0x12baf5),this['view']=new is(_0x12baf5['locale'],_0x12baf5['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0xf745d0=this['editor']['editing']['view'],_0x2ce3b7=this['view']['editable'],_0x1221c2=_0xf745d0['document']['getRoot']();_0x2ce3b7['name']=_0x1221c2['rootName'],this['view']['render']();const _0x4ad588=_0x2ce3b7['element'];this['setEditableElement'](_0x2ce3b7['name'],_0x4ad588),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0xf745d0['attachDomRoot'](_0x4ad588),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const gi=[_0x282aa3,_0x2f28c6,_0x360144,_0x43f90d,_0x7c3585,_0xf3b8a9,_0x2b1ed9];class Bt extends/* #__PURE__ -- @preserve */
25
- _0x40f554(_0x500d72){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
- ((()=>gi)());constructor(_0x356b13={}){function _0x571ff9(_0x490f1b){return _0x490f1b['map'](_0xfe6e52=>String['fromCharCode'](_0xfe6e52))['join']('');}(_0x356b13=Object['assign']({},_0x356b13))['plugins']||(_0x356b13['plugins']=Bt['defaultPlugins']),super(_0x356b13),this['ui']=new ri(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x571ff9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x571ff9([0x76,0x69,0x65,0x77])][_0x571ff9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x571ff9([0x61,0x75,0x74,0x6f]),this[_0x571ff9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x571ff9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x571ff9([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x571ff9([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x571ff9([0x6f,0x6b])});}['create'](){const _0x1dc330=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x1dc330))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x5ebe7a=>{const _0x5b9f79=this['model']['document']['getRoot'](),_0x34276d=_0x5b9f79&&_0x5b9f79['getChild'](_0x5b9f79['childCount']-0x1);_0x5ebe7a['setSelection'](_0x34276d,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x4e374f=this['editing']['view'],_0x12936e=_0x4e374f['document']['getRoot'](),_0x241979=_0x12936e['getChild'](0x0);_0x12936e['childCount']>0x1||!_0x241979||'p'!=_0x241979['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(_0x440a24(_0x4e374f,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x241979['placeholder']=this['placeholder']),_0x3825f1({'view':_0x4e374f,'element':_0x241979,'keepOnFocus':!0x0}),this['placeholderElement']=_0x241979);}}class St extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x4a804b,_0x5362d9={}){super(_0x4a804b),this['editor']=null,this['_editorConfig']=_0x5362d9,this['set']('value',_0x5362d9['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x4a804b,'Reply...')),this['set']('submitLabel',N(_0x4a804b,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x2d3c14(),this['focusCycler']=new _0x58c694({'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',(_0x1a2915,_0x30dbd8)=>{this['cancelButtonView']['fire']('execute'),_0x30dbd8();}),this['keystrokes']['set']('Ctrl+Enter',(_0x1cbdd5,_0x40fdaa)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x40fdaa());}),this['on']('submit',(_0x412a01,_0xb9ad91)=>{_0xb9ad91['length']>0xfde8?(alert(N(_0x4a804b,'TOO_LONG_COMMENT_ALERT',[_0xb9ad91['length'],0xfde8])),_0x412a01['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Bt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x6abb50=this['editor'];this['element']['insertBefore'](_0x6abb50['ui']['element'],this['element']['firstChild']),_0x6abb50['model']['document']['on']('change',()=>this['value']=_0x6abb50['getData']()),_0x6abb50['bind']('placeholder')['to'](this),this['focusables']['add'](_0x6abb50['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x422acf){-0x1===_0x422acf?(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:_0x90204e}=this,_0x161ab5=new _0x55680e(_0x90204e);return _0x161ab5['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x161ab5['withText']=!0x0,_0x161ab5['bind']('label')['to'](this,'submitLabel'),_0x161ab5['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x161ab5['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x483102,_0x17195e)=>!_0x17195e&&!!_0x483102['trim']()),_0x161ab5;}['_createCancelButton'](){const {locale:_0x5b66af}=this,_0x1f482b=new _0x55680e(_0x5b66af);return _0x1f482b['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x1f482b['label']=N(_0x5b66af,'Cancel'),_0x1f482b['withText']=!0x0,_0x1f482b['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x1f482b;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0xc88379=>{this['focusTracker']['add'](_0xc88379['element']);}),this['focusables']['on']('change',(_0x583e63,_0x4d419f)=>{for(const _0x466891 of Array['from'](_0x4d419f['added'])['reverse']())this['focusTracker']['add'](_0x466891['element']);});}}class ie extends kt{constructor(_0x1c915f,_0x3ebd31,_0x59e61f){super(_0x1c915f),this['commentInputView']=new St(_0x1c915f,_0x59e61f),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x1d1a73,_0x4063cc)=>_0x1d1a73||!!_0x4063cc),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 Ft(_0x1c915f,_0x3ebd31),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'](_0x99ee6e){this['commentInputView']['focus'](_0x99ee6e);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x288455,_0x31955d)=>{const {submitButtonView:_0x11ee6e,cancelButtonView:_0x56a48e,editor:_0x348e28}=this['commentInputView'];[_0x11ee6e['element'],_0x56a48e['element'],_0x348e28?_0x348e28['editing']['view']['getDomRoot']():null]['filter'](_0x164923=>_0x164923)['some'](_0x395a36=>_0x395a36['contains'](_0x31955d['target']))||(this['focus'](),_0x31955d['preventDefault']());});}}class Kt extends kt{constructor(_0x55b159){super(_0x55b159);const _0x241721=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x241721['to']('count',_0x50049e=>N(_0x55b159,'NUMBER_OF_COMMENTS',_0x50049e))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x4e2264,_0x23b9bb,_0x4f04ed){super(_0x4e2264);const _0x596518=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x23b9bb['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x23b9bb,this['_config']=_0x4f04ed,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x2d3c14(),this['keystrokes']=new jt(),this['focusCycler']=new _0x58c694({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x26e01e=>this['commentViews']['map'](_0x411a68=>_0x411a68['element'])['includes'](_0x26e01e['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new Kt(_0x4e2264),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x234c0f=>_0x234c0f-this['_config']['maxCommentsWhenCollapsed']);for(const _0x220e91 of _0x23b9bb['comments'])this['_handleNewCommentModel'](_0x220e91);this['_handleInfoComment'](),this['listenTo'](_0x23b9bb['comments'],'add',(_0x4ac6ee,_0x150f66)=>{const _0x1237c9=this['_calculatePosition'](_0x150f66);this['length']++,this['_handleNewCommentModel'](_0x150f66,_0x1237c9),this['refreshVisibleViews']();}),this['listenTo'](_0x23b9bb['comments'],'remove',(_0x2da089,_0x46f1e4)=>{this['length']--,this['_handleRemoveCommentModel'](_0x46f1e4),this['refreshVisibleViews']();}),this['listenTo'](_0x23b9bb,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x23b9bb,'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',_0x596518['if']('length','ck-hidden',_0xd06de5=>!_0xd06de5)],'aria-label':N(_0x4e2264,'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'](_0x347854){-0x1===_0x347854?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x5b1731 of this['commentViews'])_0x5b1731['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x466abf,_0x3fc9df){const _0x157f25=new this['_config']['CommentView'](this['locale'],_0x466abf,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x157f25['viewUid']=_0x466abf['id'],_0x157f25['delegate']('removeComment')['to'](this),_0x157f25['delegate']('updateComment')['to'](this),_0x157f25['delegate']('resolveCommentThread')['to'](this),_0x157f25['delegate']('editorReady')['to'](this),_0x157f25['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x157f25,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x157f25,_0x3fc9df);}['_calculatePosition'](_0x4b5523){const _0x2473f5=this['_model']['_findOptimalIndex'](_0x4b5523);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x4b5523['authoredAt']?_0x2473f5-0x1:_0x2473f5:_0x2473f5-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x4d5292={'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'],_0x4d5292,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x4d5292));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x6c96c2){const _0x3eb7a0=this['commentViews']['remove'](_0x6c96c2['id']);this['stopListening'](_0x3eb7a0),_0x3eb7a0['isEditMode']&&this['_updateHasDirtyComment'](),_0x3eb7a0['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x34c5a4=>_0x34c5a4['isEditMode']);}['_rearrangeCollapse'](){const _0x996a80=function(_0x25f5c7){const _0x450c41=new _0x294a7b();for(const _0x129fa4 of _0x25f5c7)_0x450c41['add'](_0x129fa4);return _0x450c41;}(this['commentViews']),_0x93b822=this['_collapsedCommentsView']['count'];for(let _0x2f30a0=0x1;_0x2f30a0<=_0x93b822;_0x2f30a0++)_0x996a80['remove'](0x1);for(const _0x380b9e of _0x996a80)_0x380b9e['collapse']();_0x93b822>0x0&&_0x996a80['add'](this['_collapsedCommentsView'],0x1),Ut(qt(Array['from'](this['visibleViews']),Array['from'](_0x996a80)),this['visibleViews'],_0x996a80);}['_rearrangeExpand'](){Ut(qt(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x524edd of this['visibleViews'])_0x524edd['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x2a31af=>{this['focusTracker']['add'](_0x2a31af['element']),this['keystrokes']['listenTo'](_0x2a31af['element']);}),this['commentViews']['on']('change',(_0x53753e,_0x35c27e)=>{for(const _0x4d8af7 of _0x35c27e['removed'])this['focusTracker']['remove'](_0x4d8af7['element']),this['keystrokes']['stopListening'](_0x4d8af7['element']);for(const _0x3a34c2 of Array['from'](_0x35c27e['added'])['reverse']())this['focusTracker']['add'](_0x3a34c2['element']),this['keystrokes']['listenTo'](_0x3a34c2['element']);});}}function Ut(_0x414edc,_0x405b90,_0x248866){let _0x14b1ac=0x0;for(const _0x2aaf15 of _0x414edc)switch(_0x2aaf15){case'insert':_0x405b90['add'](_0x248866['get'](_0x14b1ac),_0x14b1ac),_0x14b1ac++;break;case'delete':_0x405b90['remove'](_0x14b1ac);break;case'equal':_0x14b1ac++;}}class zt extends kt{constructor(_0x3c15be){super(_0x3c15be);const _0x2098cc=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x2098cc['to']('contextValue',_0x5eba3f=>N(_0x3c15be,'THREAD_CONTEXT_LABEL',_0x5eba3f)),'tabindex':-0x1},'children':[{'text':_0x2098cc['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Rt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x256459,_0x38a367){super(_0x256459);const _0x23d590=this['bindTemplate'];this['_model']=_0x38a367,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x2d3c14(),this['keystrokes']=new jt(),this['focusCycler']=new _0x58c694({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0xbc6f70=>!!_0xbc6f70),this['bind']('contextValue')['to'](this['_model'],'context',_0x50d1cd=>_0x50d1cd&&_0x50d1cd['value']?this['_trimContextValue'](_0x50d1cd['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',_0x23d590['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 _0x13bb46=new _0x55680e(this['locale']);return _0x13bb46['label']=N(this['locale'],'Reopen'),_0x13bb46['tooltip']=N(this['locale'],'Reopen'),_0x13bb46['icon']=Gt,_0x13bb46['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x7c4dba=>!_0x7c4dba),_0x13bb46['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x58af1b,_0x333884)=>_0x58af1b&&_0x333884),_0x13bb46['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x13bb46;}['_trimContextValue'](_0x343044){if(_0x343044['length']<0x96)return _0x343044;const _0x3ebf75=_0x343044['lastIndexOf']('\x20',0x93);return _0x343044['substring'](0x0,_0x3ebf75>-0x1?_0x3ebf75:0x93)+'...';}['_attachContextActions'](){const _0x4793f9=this['element']['querySelector']('.ck-context'),_0x542aaa=_0x4793f9['querySelector']('.ck-context__value');this['listenTo'](_0x4793f9,'mouseenter',()=>{_0x542aaa['offsetWidth']<_0x542aaa['scrollWidth']&&_0x4793f9['classList']['add']('overlay');}),this['listenTo'](_0x4793f9,'mouseleave',()=>{_0x4793f9['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x3d2321 of this['focusables'])this['focusTracker']['add'](_0x3d2321['element']),this['keystrokes']['listenTo'](_0x3d2321['element']);}['_createContextView'](){const _0x10102f=new zt(this['locale']);return _0x10102f['bind']('contextValue')['to'](this),_0x10102f;}}class Yt extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x3d6bb1,_0x54f801,_0x53a98e,_0x1255f2){super(_0x3d6bb1),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x54f801,this['_localUser']=_0x53a98e,this['_config']=_0x1255f2,this['commentThreadHeaderView']=new Rt(_0x3d6bb1,_0x54f801),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Et(_0x3d6bb1,N(_0x3d6bb1,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x3d6bb1,_0x54f801,Object['assign']({'CommentView':this['_config']['CommentView']},_0x1255f2)),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',(_0x5c77ff,_0xb4edeb)=>_0x5c77ff||!!_0xb4edeb),this['bind']('isUnlinked')['to'](_0x54f801,'unlinkedAt',_0x4605fe=>!!_0x4605fe),this['bind']('ariaLabel')['to'](this,'length',_0x59bad5=>{const _0x18f0c1=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x59bad5,_0x18f0c1]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x2d3c14(),this['keystrokes']=new jt(),this['focusCycler']=new _0x58c694({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x1adfbb=>_0x1adfbb['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),Vt(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x5431d6=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0xb3a4f7=_0x5431d6['commentInputView'];return _0x5431d6['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0xb3a4f7,'value',(_0x23a0aa,_0x2489c2,_0x129053,_0x49ee28,_0x6041a)=>!!_0x6041a||!!_0x49ee28&&_0x129053&&!_0x2489c2||_0x23a0aa&&_0x129053&&!_0x2489c2),_0xb3a4f7['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x3c49c0,_0x470630,_0x444eff)=>{let _0x130c78;return _0x130c78=_0x444eff&&_0x470630?'Reply\x20to\x20reopen\x20discussion...':_0x3c49c0?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x130c78);}),_0xb3a4f7['bind']('submitLabel')['to'](this,'length',_0x589c97=>N(this['locale'],_0x589c97?'Reply':'Comment')),_0xb3a4f7['on']('submit',(_0x40c4f0,_0x597fd6)=>{this['fire']('addComment',_0x597fd6),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0xb3a4f7['on']('cancel',()=>{this['focus']();}),_0xb3a4f7['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0xb3a4f7['on']('cancel',_0x27a612=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x27a612['stop']());}),this['on']('change:isActive',(_0x162304,_0x2f0c9b,_0x7ec49c)=>{_0x7ec49c||this['length']||_0xb3a4f7['value']||this['fire']('removeCommentThread');}),_0x5431d6;}}class gt extends/* #__PURE__ -- @preserve */
27
- $t(Yt){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x2db7ac,_0x4a9278,_0x1aee43,_0x16fd67){super(_0x2db7ac,_0x4a9278,_0x1aee43,_0x16fd67),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x2db7ac,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x25fcb0,_0xc48d27,_0x32038c)=>{_0x32038c||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x3cd410,_0x164a21,_0x107a71)=>{_0x107a71&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x149983=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x149983['if']('isActive','ck-thread--active'),_0x149983['if']('isUnlinked','ck-thread--unlinked'),_0x149983['if']('isConfirm','ck-thread--remove-confirmation'),_0x149983['to']('actionIndicator',_0x240332=>_0x240332?'ck-thread--'+_0x240332:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x149983['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 _0x2043e7 of this['commentsListView']['commentViews'])_0x2043e7['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x31b532}=this,_0x1ba2df=this['commentsListView']['commentViews']['get'](0x0);_0x1ba2df===this['_boundFirstCommentView']||_0x1ba2df['isSystemComment']||(this['_boundFirstCommentView']=_0x1ba2df,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x1ba2df,'actionIndicator',_0x43d363=>'remove'===_0x43d363?'remove':null),_0x1ba2df['placeholder']=N(_0x31b532,'Write\x20a\x20comment...'),_0x1ba2df['removeButton']['on']('execute',_0x229eb1=>{_0x229eb1['stop'](),this['showConfirm'](N(_0x31b532,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x1ba2df['focus']();}),_0x1ba2df['actionBar']['add'](this['resolveButton'],0x0),_0x1ba2df['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x4b82e5=new Jt(this['locale']);return _0x4b82e5['label']=N(this['locale'],'Resolve'),_0x4b82e5['tooltip']=N(this['locale'],'Resolve'),_0x4b82e5['icon']=Qt,_0x4b82e5['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x4b82e5['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1fd5b8=>!_0x1fd5b8),_0x4b82e5['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x5bb7d6,_0xbfe439)=>_0x5bb7d6&&!_0xbfe439),_0x4b82e5['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x4b82e5;}['_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 Xt extends kt{constructor(_0x4bd476){super(_0x4bd476),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x197f77,_0x243dd0,_0x4e21b2)=>{this['element']['innerHTML']=_0x4e21b2;}),this['element']['innerHTML']=this['content'];}}class ci extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x22d6b7,_0x3d4c67,_0x1314ee){super(_0x22d6b7),this['_model']=_0x3d4c67,this['_config']=_0x1314ee,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x3d4c67,'content',_0x3d4c67,'authoredAt',(_0x361c7e,_0x3c108d)=>N(_0x22d6b7,'COMMENT_ARIA_LABEL',[_0x3d4c67['author']['name'],_0x1314ee['formatDateTime'](_0x3c108d),new DOMParser()['parseFromString'](_0x361c7e,'text/html')['body']['textContent'],_0x3d4c67['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Et(_0x22d6b7,N(_0x22d6b7,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x58b265(),this['focusTracker']=new _0x2d3c14(),this['keystrokes']=new jt(),this['focusCycler']=new _0x58c694({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5549ba=>_0x5549ba['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 _0x11920b=new Xt(this['locale']);return _0x11920b['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x3ec406,_0x401101)=>_0x401101?Lt(_0x3ec406,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x3ec406),_0x11920b;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0xf3a738=new St(this['locale'],this['_config']['editorConfig']);return _0xf3a738['value']=this['_model']['content'],_0xf3a738['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0xf3a738['submitLabel']=N(this['locale'],'Save'),_0xf3a738['on']('submit',(_0x24e95e,_0x965fda)=>{this['fire']('updateComment',this['_model']['id'],_0x965fda),this['switchToDisplayMode'](),this['focus']();}),_0xf3a738['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0xf3a738['once']('editorReady',()=>{_0xf3a738['focus']();}),_0xf3a738['createEditor'](),_0xf3a738['delegate']('editorReady')['to'](this),_0xf3a738['delegate']('editorDestroyed')['to'](this),_0xf3a738;}['_setupKeyboardNavigation'](){const _0x399949=this['element'];this['keystrokes']['listenTo'](_0x399949);for(const _0x2bb5b8 of this['focusables'])this['focusTracker']['add'](_0x2bb5b8['element']),this['keystrokes']['listenTo'](_0x2bb5b8['element']);this['focusables']['on']('change',(_0x2a9fdf,_0x5f505a)=>{for(const _0x404e41 of _0x5f505a['removed'])this['focusTracker']['remove'](_0x404e41['element']),this['keystrokes']['stopListening'](_0x404e41['element']);for(const _0x14ad70 of _0x5f505a['added'])this['focusTracker']['add'](_0x14ad70['element']),this['keystrokes']['listenTo'](_0x14ad70['element']);}),this['keystrokes']['set']('enter',(_0x3134e5,_0x55a8b5)=>{_0x399949===_0x3134e5['target']&&(this['focusCycler']['focusFirst'](),_0x55a8b5());}),this['keystrokes']['set']('esc',(_0x1c2a21,_0x51ee08)=>{_0x399949!==_0x1c2a21['target']&&(this['focus'](),_0x51ee08());});}}class Tt extends/* #__PURE__ -- @preserve */
28
- $t(ci){['actionBar'];['userView'];constructor(_0x56ccec,_0x123486,_0x4268bc){super(_0x56ccec,_0x123486,_0x4268bc),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x56ccec,'Reply...')),this['bind']('authoredAt')['to'](_0x123486),this['bind']('resolvedAt')['to'](_0x123486),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 Ft(_0x56ccec,_0x123486['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x123486,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x2d0229=this['bindTemplate'],_0x203a0d=[{'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':_0x2d0229['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x2d0229['to']('authoredAt',_0x412bac=>this['_config']['formatDateTime'](_0x412bac))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x2d0229['if']('isEditMode','ck-comment__actions--hidden'),_0x2d0229['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']&&_0x203a0d['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x2d0229['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x2d0229['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x2d0229['if']('isEditMode','ck-comment--edit'),_0x2d0229['if']('isSystemComment','ck-comment--info'),_0x2d0229['to']('actionIndicator',_0x1fa8dc=>_0x1fa8dc?'ck-comment--'+_0x1fa8dc:'')],'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':_0x203a0d}]}]};}['_createEditButton'](){const _0x397e56=new _0x55680e(this['locale']);return _0x397e56['label']=N(this['locale'],'Edit'),_0x397e56['icon']=ti,_0x397e56['withText']=!0x0,_0x397e56['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x397e56['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x12b452=>!_0x12b452),_0x397e56['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x397e56['on']('execute',()=>this['switchToEditMode']()),_0x397e56;}['_createRemoveButton'](){const _0x27c1e9=new _0x55680e(this['locale']);return _0x27c1e9['label']=N(this['locale'],'Remove'),_0x27c1e9['icon']=Zt,_0x27c1e9['withText']=!0x0,_0x27c1e9['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x27c1e9['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x158f22=>!_0x158f22),_0x27c1e9['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x27c1e9['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x27c1e9;}['_createDropdown'](){const _0x33ccce=_0x1cbde8(this['locale'],_0x2de17b),_0x1dd194=_0x33ccce['panelView']['children'],_0x4b9205=new _0x358ded(this['locale']),_0x43bce4=_0x33ccce['bindTemplate'];_0x1d97d8(_0x33ccce,()=>this['items']['find'](_0x45d0e2=>_0x45d0e2['isVisible'])),_0x33ccce['extendTemplate']({'attributes':{'class':[_0x43bce4['if']('isVisible','ck-hidden',_0x4396bf=>!_0x4396bf)]}});const _0xfc1436=(_0x20cdba,_0x1b616c=-0x1)=>{const _0x2e97a6=new _0x51603e(this['locale']);_0x2e97a6['children']['add'](_0x20cdba);const _0x1b1c31=_0x1b616c>-0x1?_0x1b616c:_0x4b9205['items']['length'];_0x4b9205['items']['add'](_0x2e97a6,_0x1b1c31);const _0x417858=Array['from'](this['items']);_0x33ccce['unbind']('isEnabled','isVisible'),_0x33ccce['bind']('isEnabled')['toMany'](_0x417858,'isEnabled',(..._0x40bd6a)=>_0x40bd6a['some'](_0x1eec68=>_0x1eec68)),_0x33ccce['bind']('isVisible')['toMany'](_0x417858,'isVisible',(..._0x24ae94)=>_0x24ae94['some'](_0x6e2591=>_0x6e2591));};_0x33ccce['panelPosition']='sw',_0x33ccce['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x14cf40});for(const _0x14c1b9 of this['items'])_0xfc1436(_0x14c1b9);return _0x1dd194['add'](_0x4b9205),_0x33ccce['listenTo'](this['items'],'add',(_0x57a11f,_0x289526,_0x2b747d)=>{_0xfc1436(_0x289526,_0x2b747d);}),_0x33ccce['listenTo'](this['items'],'remove',(_0x36b28e,_0x5bef17,_0x4ba96f)=>{_0x4b9205['items']['remove'](_0x4ba96f);}),_0x33ccce;}['_attachActions'](_0x2c52c7,_0x2ece7f){const _0x1a422e=_0x2c52c7&&_0x2c52c7['element'];_0x1a422e&&(this['listenTo'](_0x1a422e,'mouseenter',()=>this['actionIndicator']=_0x2ece7f),this['listenTo'](_0x1a422e,'focus',()=>this['actionIndicator']=_0x2ece7f),this['listenTo'](_0x1a422e,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x1a422e,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x4f40eb=super['_createCommentInputView']();return _0x4f40eb['bind']('placeholder')['to'](this),_0x4f40eb;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x253182){const _0x36a4ca=Dt(_0x253182,0x1e),_0x5bdb88=new MutationObserver(_0x11ef8a=>{for(const _0x190737 of _0x11ef8a)('attributes'==_0x190737['type']&&'class'==_0x190737['attributeName']||'childList'==_0x190737['type']||'characterData'==_0x190737['type'])&&_0x36a4ca();});return{'attach'(_0x3034c1){_0x5bdb88['observe'](_0x3034c1,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x5bdb88['disconnect'](),_0x36a4ca['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x41b5ee,_0x2e3bc0){super(_0x41b5ee),this['id']=_0x1f2855(),this['focusTracker']=new _0x2d3c14(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x3dc00b,_0x54dc6e)=>this['fire']('Esc',_0x54dc6e)),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'](_0x2e3bc0),this['mainView']=_0x2e3bc0;const _0x2a5a1e=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x2a5a1e['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 _0x3275d3=this['element']['clientHeight'];_0x3275d3&&(this['height']=_0x3275d3);}}class T extends/* #__PURE__ -- @preserve */
29
- _0x40f554(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x202d68,target:_0x1f28f4,type:_0x49e739,isVisible:_0x32e3f5=!0x0}){super(),this['view']=_0x202d68,this['view']['element']||this['view']['render'](),this['_type']=_0x49e739,this['_target']=_0x1f28f4,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x294a7b([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x454723,_0x5356fa)=>{this['view']['focusTracker']['add'](_0x5356fa);}),this['focusableElements']['on']('remove',(_0x5b3e77,_0x40c6c8)=>{this['view']['focusTracker']['remove'](_0x40c6c8);}),this['set']('isVisible',_0x32e3f5);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x4c4c07=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x4c4c07),_0x4c4c07;}get['targetRect'](){const _0x583005=this['target'];if(null===_0x583005)return null;if(_0x583005 instanceof _0x3e5e72)return _0x583005;const _0x43e4f6=_0x583005['filter'](_0x5806e1=>function(_0x186c15){const _0x483096=_0x186c15['offsetParent'];if(_0x483096)return!0x0;const _0x528339=_0x186c15['getClientRects']()['item'](0x0);return!!_0x528339;}(_0x5806e1));return 0x0===_0x43e4f6['length']?null:new _0x3e5e72(_0x43e4f6[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x158388){this['view']['isActive']=_0x158388,this['view']['mainView']['isActive']=_0x158388;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x192a45){if(!(null===_0x192a45||_0x192a45 instanceof _0x3e5e72||Array['isArray'](_0x192a45)&&_0x192a45['every'](_0x43994b=>Ai(_0x43994b))))throw new _0x4e095a('annotation-invalid-target',null,{'target':_0x192a45});}['_getNormalizedTarget'](){const _0x38d182='function'==typeof this['_target']?this['_target']():this['_target'];return Ai(_0x38d182)?[_0x38d182]:_0x38d182;}}function Ai(_0x171da3){return null!==_0x171da3&&'object'==typeof _0x171da3&&'nodeType'in _0x171da3&&0x1===_0x171da3['nodeType'];}class S extends _0x294a7b{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x3a0ebd=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x2d3c14(),this['_focusTracker']['on']('change:isFocused',(_0x41a287,_0x10d2dc,_0x4bf7f0)=>{_0x4bf7f0||this['fire']('blur');});for(const _0x59b98c of _0x3a0ebd)this['add'](_0x59b98c);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x1c987c){if(this['has'](_0x1c987c))throw new _0x4e095a('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x1c987c['innerView'],_0x1c987c),this['_viewToAnnotation']['set'](_0x1c987c['view'],_0x1c987c);for(const _0x315b9c of _0x1c987c['focusableElements'])this['_focusTracker']['add'](_0x315b9c);this['listenTo'](_0x1c987c['focusableElements'],'add',(_0x120ccb,_0x593e13)=>{this['_focusTracker']['add'](_0x593e13);}),this['listenTo'](_0x1c987c['focusableElements'],'remove',(_0x10f649,_0x536a68)=>{this['_focusTracker']['remove'](_0x536a68);}),this['listenTo'](_0x1c987c['view']['focusTracker'],'change:isFocused',(_0x866666,_0x216d7d,_0x5a5f5f)=>{_0x5a5f5f&&this['fire']('focus',_0x1c987c);}),_0x1c987c['updateTargetRect']();const _0x1276ce=this['_getOrderInContent'](_0x1c987c['view']['targetRect']);return super['add'](_0x1c987c,_0x1276ce);}['remove'](_0x31584e){if(!this['has'](_0x31584e))throw new _0x4e095a('annotationcollection-not-existing-item',null);this['stopListening'](_0x31584e['view']['focusTracker']),this['stopListening'](_0x31584e['focusableElements']);for(const _0x1811d4 of _0x31584e['focusableElements'])this['_focusTracker']['remove'](_0x1811d4);return this['_viewToAnnotation']['delete'](_0x31584e['view']),this['_innerViewToAnnotation']['delete'](_0x31584e['innerView']),super['remove'](_0x31584e);}['getByInnerView'](_0x58f8b2){return this['_innerViewToAnnotation']['get'](_0x58f8b2);}['getByView'](_0x233b01){return this['_viewToAnnotation']['get'](_0x233b01);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x515054 of this)_0x515054['updateTargetRect']();this['_sort']();}['_sort'](){const _0x49dff4=Array['from'](this)['sort']((_0x3f5905,_0x1f6613)=>w(_0x3f5905['view']['targetRect'],_0x1f6613['view']['targetRect']));for(let _0x1bd135=_0x49dff4['length']-0x1;_0x1bd135>0x0;_0x1bd135--){const _0x4036e1=_0x49dff4[_0x1bd135];_0x1bd135!==this['getIndex'](_0x4036e1)&&(this['remove'](_0x4036e1),this['add'](_0x4036e1));}}['_getOrderInContent'](_0x3eb044){let _0x5e6c87=0x0;if(!_0x3eb044)return this['length'];for(const _0x4d2909 of this){const _0x2b6079=_0x4d2909['view']['targetRect'];if(_0x2b6079){if(w(_0x3eb044,_0x2b6079)<0x0)return _0x5e6c87;_0x5e6c87++;}}return _0x5e6c87;}}function v({source:_0xaffe09,target:_0x2ef9d2,filter:_0x37dbc1}){for(const _0x3b289f of _0xaffe09)_0x37dbc1(_0x3b289f)&&_0x2ef9d2['add'](_0x3b289f);_0x2ef9d2['listenTo'](_0xaffe09,'add',(_0x447c79,_0x21baff)=>{_0x37dbc1(_0x21baff)&&_0x2ef9d2['add'](_0x21baff);}),_0x2ef9d2['listenTo'](_0xaffe09,'remove',(_0x2194ab,_0x80d78b)=>{_0x2ef9d2['has'](_0x80d78b)&&_0x2ef9d2['remove'](_0x80d78b);});}function w(_0x59a6f7,_0x204fab){if(null===_0x59a6f7&&null===_0x204fab)return 0x0;if(null===_0x59a6f7)return-0x1;if(null===_0x204fab)return 0x1;const _0x333b7d=_0x59a6f7['top']-_0x204fab['top'];return 0x0==_0x333b7d?_0x59a6f7['left']-_0x204fab['left']:_0x333b7d;}class y extends _0x5d2528{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x14c247){if(super(_0x14c247),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x14c247 instanceof _0x500d72){const _0x209d75=_0x14c247['locale'];_0x14c247['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x209d75,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x41be3b){this['collection']['add'](_0x41be3b);}['remove'](_0x2af6b4){this['collection']['remove'](_0x2af6b4),_0x2af6b4['destroy']();}['refreshVisibility'](){for(const _0xfd0fcf of this['collection'])_0xfd0fcf['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x18f7b0){return this['collection']['getByInnerView'](_0x18f7b0);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x31dd1b of this['collection'])_0x31dd1b['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x343b61){this['fire']('_activateAnnotation',_0x343b61);}['createAnnotation'](_0x17ea69){return new T(_0x17ea69);}['createAnnotationView'](_0x4d3999,_0x4f89aa){return new E(_0x4d3999,_0x4f89aa);}['_addActiveAnnotation'](_0x5c6177){const _0x2b1f39=new Set(this['activeAnnotations']);_0x2b1f39['add'](_0x5c6177),this['activeAnnotations']=_0x2b1f39;}['_removeActiveAnnotation'](_0x3d1a89){const _0x30f119=new Set(this['activeAnnotations']);_0x30f119['delete'](_0x3d1a89),this['activeAnnotations']=_0x30f119;}['_bindAnnotationsToVisibleAnnotations'](){const _0x220c6c=this['collection'],_0x3f7f9e=this['_visibleAnnotations'];function _0x19f895(_0x8c27f3){const _0x3b0333=_0x8c27f3['source'];_0x3b0333['isVisible']&&!_0x3f7f9e['has'](_0x3b0333)?_0x3f7f9e['add'](_0x3b0333):!_0x3b0333['isVisible']&&_0x3f7f9e['has'](_0x3b0333)&&_0x3f7f9e['remove'](_0x3b0333),_0x3b0333['view']['focusTracker']['remove'](_0x3b0333['view']['element']),_0x3b0333['view']['focusTracker']['add'](_0x3b0333['view']['element']);}this['listenTo'](_0x220c6c,'add',(_0x2b7fab,_0x1edb73)=>{_0x1edb73['isVisible']&&_0x3f7f9e['add'](_0x1edb73),this['listenTo'](_0x1edb73,'change:isVisible',_0x19f895);}),this['listenTo'](_0x220c6c,'remove',(_0x201fee,_0x1f7fa7)=>{_0x3f7f9e['has'](_0x1f7fa7)&&_0x3f7f9e['remove'](_0x1f7fa7),this['stopListening'](_0x1f7fa7,'change:isVisible',_0x19f895);});}['_setupEnterAnnotationKeystroke'](){const _0x45eace=_0x2ab14b=>{_0x2ab14b['on']('ready',()=>{_0x2ab14b['keystrokes']['set'](_0x55b371,(_0x17bc72,_0xf38ef4)=>{const _0x20022a=_0x7a1387(this['activeAnnotations']['values']());_0x20022a&&(_0x20022a['view']['focus'](),_0xf38ef4());});});};this['context']instanceof _0x500d72?_0x45eace(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x4ecf77,_0x23015a)=>{_0x45eace(_0x23015a);});}['_setupEscapeAnnotationHandling'](){const _0x58f996=_0x54e189=>{const _0x235f6f=_0x54e189['source'],_0x238707=[];let _0x29ae51;if(Array['isArray'](_0x235f6f['target'])){_0x29ae51=_0x235f6f['target'][0x0],this['context']instanceof _0x500d72?_0x238707['push'](this['context']):this['context']['editors']&&_0x238707['push'](...this['context']['editors']);for(const _0x2a464a of _0x238707)for(const _0x5bd8ee of _0x2a464a['editing']['view']['domRoots']['values']())if(_0x5bd8ee['contains'](_0x29ae51))return void _0x2a464a['editing']['view']['focus']();_0x29ae51['focus']();}};this['listenTo'](this['collection'],'add',(_0x1f25d9,_0x17eb1c)=>{this['listenTo'](_0x17eb1c,'escape',_0x58f996,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x523280,_0x5b1826)=>{this['stopListening'](_0x5b1826,'escape',_0x58f996);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x5d2528{['_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(_0x34d5bc){super(_0x34d5bc),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x4520bd=this['context']['config'];_0x4520bd['define']('comments.maxCommentsWhenCollapsed',0x2),_0x4520bd['define']('comments.maxThreadTotalWeight',0x1f4),_0x4520bd['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x4520bd['define']('comments.CommentThreadView',gt),_0x4520bd['define']('comments.CommentView',Tt),_0x4520bd['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x2907e2=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x3505c8,_0x5a8b14)=>this['_addCommentThread'](_0x5a8b14)),this['on']('submitCommentThread',(_0xab735c,_0xa70950)=>this['_submitCommentThread'](_0xa70950)),this['on']('resolveCommentThread',(_0x179392,_0x16c686)=>this['_resolveCommentThread'](_0x16c686)),this['on']('resolveCommentThread',(_0x17b682,_0x4afc37)=>this['_updateActiveAnnotation'](_0x4afc37),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x66bfd7,_0x5031a5)=>this['_reopenCommentThread'](_0x5031a5)),this['on']('reopenCommentThread',(_0x43cd11,_0x45f34c)=>this['_updateActiveAnnotation'](_0x45f34c),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x526ec2,_0x7cd6b3)=>this['_removeCommentThread'](_0x7cd6b3)),this['on']('updateCommentThread',(_0x149e96,_0x38f031)=>this['_updateCommentThread'](_0x38f031)),this['on']('updateCommentThread',(_0x4b585d,_0x2defe5)=>this['_updateActiveAnnotation'](_0x2defe5),{'priority':'lowest'}),this['on']('addComment',(_0x26ae3a,_0xc14854)=>this['_addComment'](_0xc14854)),this['on']('updateComment',(_0x19400d,_0x20aa03)=>this['_updateComment'](_0x20aa03)),this['on']('removeComment',(_0x68bf52,_0x17973e)=>this['_removeComment'](_0x17973e)),this['on']('addComment',(_0x57ebd0,{threadId:_0x11a9fa,isFromAdapter:_0x59373b})=>{if(_0x59373b)return;const _0x158986=this['getCommentThread'](_0x11a9fa),_0x261998=_0x158986&&this['_threadToController']['get'](_0x158986);_0x261998&&_0x261998['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x2907e2,'change:activeAnnotations',(_0x590255,_0x26a61a,_0x2f1807)=>{const _0x9f82c3=Array['from'](_0x2f1807)['map'](_0x121415=>this['_viewToController']['get'](_0x121415['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x9f82c3?_0x9f82c3['model']:null;});}set['adapter'](_0x438f3f){if(this['_adapter'])throw new _0x4e095a('commentsrepository-adapter-already-set');this['_adapter']=_0x438f3f;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x57d584=_t,threadId:_0x23590b=_0x1f2855(),comments:_0x4b00f7=[],unlinkedAt:_0x9aaf75=null,resolvedAt:_0x55df94=null,resolvedBy:_0x27f851=null,target:_0x27e89b=null,context:_0xae7004=null,attributes:_0xdb385={},isResolvable:_0x233fa9=!0x0,isSubmitted:_0x4cb926=!0x1,isFromAdapter:_0xde35f4=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x57d584),{'channelId':_0x57d584,'threadId':_0x23590b,'comments':_0x4b00f7,'unlinkedAt':_0x9aaf75,'resolvedAt':_0x55df94,'resolvedBy':_0x27f851,'target':_0x27e89b,'context':_0xae7004,'attributes':_0xdb385,'isFromAdapter':_0xde35f4,'isResolvable':_0x233fa9,'isSubmitted':_0x4cb926}),this['getCommentThread'](_0x23590b);}['openNewCommentThread']({channelId:_0x133c56=_t,threadId:_0x3b1aac=_0x1f2855(),target:_0x4f2c30,context:_0x4a8e71=null,isResolvable:_0x5bf98f=!0x0}){if(this['_readOnlyChannels']['has'](_0x133c56)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x4f2c30)throw new _0x4e095a('commentsrepository-missing-target');const _0x19b128=this['addCommentThread']({'channelId':_0x133c56,'threadId':_0x3b1aac,'target':_0x4f2c30,'context':_0x4a8e71,'isResolvable':_0x5bf98f});if(!_0x19b128)return null;const _0x5d0c4d=this['_threadToController']['get'](_0x19b128),_0x105565=_0x5d0c4d['view']['commentThreadInputView']['commentInputView'],_0x33a5df=this['context']['plugins']['get'](y),_0x181233=_0x33a5df['getByInnerView'](_0x5d0c4d['view']);return _0x33a5df['activate'](_0x181233),_0x105565['once']('editorReady',()=>_0x105565['focus']()),_0x19b128;}['hasCommentThread'](_0x3aef08){if('string'!=typeof _0x3aef08)throw new _0x4e095a('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x3aef08);}['updateCommentThread']({channelId:_0x234724=_t,threadId:_0x21caac,context:_0x4190cc,unlinkedAt:_0x488d82,attributes:_0x1b1d77,isFromAdapter:_0x3fd25=!0x1}){return this['fire'](Nt('updateCommentThread',_0x234724),{'channelId':_0x234724,'threadId':_0x21caac,'context':_0x4190cc,'unlinkedAt':_0x488d82,'attributes':_0x1b1d77,'isFromAdapter':_0x3fd25}),this['getCommentThread'](_0x21caac);}['getCommentThread'](_0x28730c){if('string'!=typeof _0x28730c)throw new _0x4e095a('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x28730c);}['fetchCommentThread']({channelId:_0x2fa0b8,threadId:_0xded13d}={}){const _0x24e764=this['getCommentThread'](_0xded13d);if(_0x24e764)return Promise['resolve'](_0x24e764);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x4e095a('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x2fa0b8,'threadId':_0xded13d})['then'](_0x56fbb0=>this['hasCommentThread'](_0xded13d)?this['getCommentThread'](_0xded13d):_0x56fbb0?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x2fa0b8},_0x56fbb0)):void 0x0)['catch'](_0x4921ea=>{throw console['error'](_0x4921ea),new _0x4e095a('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x349614,skipNotAttached:_0x353a1d=!0x1,skipEmpty:_0x54f94b=!0x1,toJSON:_0x2aff80=!0x1}={}){const _0x23ba54=[];for(const _0x224b50 of this['_threads']['values']())_0x349614&&_0x224b50['channelId']!==_0x349614||_0x353a1d&&!_0x224b50['isAttached']||_0x54f94b&&0x0===_0x224b50['length']||_0x23ba54['push'](_0x224b50);return _0x2aff80?_0x23ba54['map'](_0x3fdb30=>_0x3fdb30['toJSON']()):_0x23ba54;}['getAnnotationForCommentThread'](_0x1a310f){const _0x1b0ab7=this['_threadToController']['get'](_0x1a310f);if(!_0x1b0ab7)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x1b0ab7['view'])||null;}['getCommentThreadForAnnotation'](_0x4d1866){const _0xb224e0=this['_viewToController']['get'](_0x4d1866['innerView']);return _0xb224e0?_0xb224e0['model']:null;}['setActiveCommentThread'](_0x4efd50){const _0x2a3369=this['context']['plugins']['get'](y);if(!_0x4efd50)return void(this['activeCommentThread']&&_0x2a3369['deactivateAll']());const _0x368736=this['getCommentThread'](_0x4efd50);if(!_0x368736)throw new _0x4e095a('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x4efd50});if(!this['_threadToController']['has'](_0x368736))throw new _0x4e095a('commentsrepository-active-not-attached',null,{'threadId':_0x4efd50});const _0x5a3ce5=_0x2a3369['getByInnerView'](this['_threadToController']['get'](_0x368736)['view']);_0x2a3369['activate'](_0x5a3ce5);}['switchReadOnly'](_0x2bb31b,_0x153e1a){_0x2bb31b?this['_readOnlyChannels']['add'](_0x153e1a):this['_readOnlyChannels']['delete'](_0x153e1a),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x7782e3){return this['_readOnlyChannels']['has'](_0x7782e3)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x3c39bd,_0x4ce140){return new vt(_0x3c39bd,_0x4ce140);}['setPermissions'](_0x2dbb3f,_0xb56ea7=_t){this['_permissions']['set'](_0xb56ea7,_0x2dbb3f),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x590a04=_t){return this['_permissions']['has'](_0x590a04)?this['_permissions']['get'](_0x590a04):bt;}['_addCommentThread']({channelId:_0x34a1ce,threadId:_0x3f17c4,comments:_0x3fbe7e,unlinkedAt:_0x34c7c1,resolvedAt:_0x22b08b,resolvedBy:_0x7d33e1,target:_0x86c488,context:_0x330437,attributes:_0x47a562,isFromAdapter:_0x35b0df,isResolvable:_0x4ef914,isSubmitted:_0x3b525a}){if('string'!=typeof _0x3f17c4)throw new _0x4e095a('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x3f17c4});if(this['hasCommentThread'](_0x3f17c4))throw new _0x4e095a('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x3f17c4});const _0x5afec3=new Ti(this,{'channelId':_0x34a1ce,'id':_0x3f17c4,'context':_0x330437,'attributes':_0x47a562,'unlinkedAt':_0x34c7c1,'resolvedAt':_0x22b08b,'resolvedBy':_0x7d33e1?this['context']['plugins']['get'](it)['getUser'](_0x7d33e1):null,'isResolvable':_0x4ef914,'isSubmitted':_0x3b525a||_0x35b0df});this['_threads']['set'](_0x3f17c4,_0x5afec3);for(const _0x22ba73 of _0x3fbe7e)_0x5afec3['_add'](this['_createNewComment']({'threadId':_0x3f17c4,..._0x22ba73}));return _0x86c488&&_0x5afec3['attachTo'](_0x86c488),_0x35b0df||!_0x5afec3['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x34a1ce,'threadId':_0x3f17c4});}['_submitCommentThread']({channelId:_0x156fd5,threadId:_0x48a8a3}){if(!this['hasCommentThread'](_0x48a8a3))throw new _0x4e095a('commentsrepository-missing-comment-thread',this);const _0x2f5b9f=this['getCommentThread'](_0x48a8a3);if(_0x2f5b9f['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x3d7ea4,comments:_0x9f818c,resolvedAt:_0x11641a,resolvedBy:_0x2aa6e1,context:_0x4734d7,attributes:_0x34d511}=_0x2f5b9f,_0x15fb3b=this['context']['plugins']['get']('PendingActions'),_0x25b0d3=_0x15fb3b['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x156fd5,'threadId':_0x3d7ea4,'comments':_0x9f818c['map'](_0x3acf71=>_0x3acf71['toJSON']()),'resolvedAt':_0x11641a,'resolvedBy':_0x2aa6e1?_0x2aa6e1['id']:_0x2aa6e1,'context':_0x4734d7,'attributes':_0x34d511})['then'](({comments:_0x4df5c4})=>{_0x15fb3b['remove'](_0x25b0d3);for(const _0x5dcd60 of _0x4df5c4)this['_updateComment']({'channelId':_0x156fd5,'threadId':_0x48a8a3,'commentId':_0x5dcd60['commentId'],'createdAt':_0x5dcd60['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x1670b3=>{throw console['error'](_0x1670b3),new _0x4e095a('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x4031b4,target:_0x30fa14}){const _0x3436b5=this['getCommentThread'](_0x4031b4);if(!_0x3436b5)throw new _0x4e095a('commentsrepository-attach-missing-comment-thread',this);const _0x457202=this['context']['plugins']['get']('PendingActions'),_0x6d3c68=this['context']['plugins']['get'](y),_0x5b161e=this['_createCommentThreadView'](_0x3436b5),_0x347f91=new vt(_0x3436b5,_0x5b161e);let _0xde641e=null;_0x5b161e['on']('change:isDirty',(_0x137728,_0x4ab65,_0x1f59de)=>{_0x1f59de?_0xde641e=_0x457202['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0xde641e&&(_0x457202['remove'](_0xde641e),_0xde641e=null);}),this['_threadToController']['set'](_0x3436b5,_0x347f91),this['_viewToController']['set'](_0x5b161e,_0x347f91);const _0x24bddd=new E(this['context']['locale'],_0x5b161e);_0x24bddd['bind']('length')['to'](_0x5b161e),_0x24bddd['bind']('isDirty')['to'](_0x5b161e,'isDirty',_0x5b161e,'length',(_0x2f960b,_0x12ad73)=>_0x2f960b||!_0x12ad73),_0x24bddd['bind']('isActive')['to'](_0x5b161e),_0x24bddd['type']='comment';const _0x1424e2=new T({'view':_0x24bddd,'target':_0x30fa14,'type':'comment','isVisible':!_0x3436b5['archivedAt']&&!!('function'==typeof _0x30fa14?_0x30fa14():_0x30fa14)});return _0x5b161e['on']('escape',()=>{_0x1424e2['fire']('escape');}),this['_bindAnnotationToEditors'](_0x5b161e,_0x1424e2),_0x6d3c68['add'](_0x1424e2),_0x1424e2;}['_bindAnnotationToEditors'](_0x4dcbc4,_0x468c6b){this['listenTo'](_0x4dcbc4,'editorReady',(_0x3e5367,_0x30f20a)=>{const _0x564e7e=_0x30f20a['ui']['view']['body']['bodyCollectionContainer'];_0x468c6b['focusableElements']['add'](_0x564e7e),this['context']instanceof _0x500d72&&this['context']['ui']['focusTracker']['add'](_0x564e7e);},{'priority':'highest'}),this['listenTo'](_0x4dcbc4,'editorDestroyed',(_0x5c21be,_0x4a3802)=>{const _0x1ce225=_0x4a3802['ui']['view']['body']['bodyCollectionContainer'];_0x468c6b['focusableElements']['has'](_0x1ce225)&&_0x468c6b['focusableElements']['remove'](_0x1ce225),this['context']instanceof _0x500d72&&this['context']['ui']['focusTracker']['remove'](_0x1ce225);});}['_unbindEditors'](_0x498ab8){this['stopListening'](_0x498ab8,'editorReady'),this['stopListening'](_0x498ab8,'editorDestroyed');}['_createCommentThreadView'](_0x36ce55){const _0x35e619=this['context']['plugins']['get'](it),{config:_0x18bbaf,locale:_0x5b1f98}=this['context'],_0x314960=pt(_0x18bbaf['get']('locale'),_0x5b1f98);return new(0x0,(_0x18bbaf['get']('comments'))['CommentThreadView'])(_0x5b1f98,_0x36ce55,_0x35e619['me'],{'editorConfig':{..._0x18bbaf['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x18bbaf['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x18bbaf['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x18bbaf['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x18bbaf['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x314960,'CommentView':_0x18bbaf['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x5a0297,channelId:_0x50e1cd,resolvedAt:_0x1e618a,resolvedBy:_0x38c1c2,isFromAdapter:_0x265147}){if(!this['hasCommentThread'](_0x5a0297))throw new _0x4e095a('commentsrepository-missing-comment-thread',null,{'threadId':_0x5a0297});const _0x31ea8f=this['getCommentThread'](_0x5a0297);if(_0x31ea8f['isResolved'])throw new _0x4e095a('commentsrepository-resolved-comment-thread',null,{'threadId':_0x5a0297});const _0x3bc6ec=this['context']['plugins']['get'](it);if(_0x31ea8f['resolvedBy']=_0x3bc6ec['getUser'](_0x38c1c2),_0x31ea8f['resolvedAt']=_0x1e618a,_0x265147||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x3cb0e1=this['context']['plugins']['get']('PendingActions'),_0x193443=_0x3cb0e1['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x50e1cd,'threadId':_0x5a0297})['then'](({resolvedAt:_0x2af2b3,resolvedBy:_0x163fbf})=>{_0x3cb0e1['remove'](_0x193443),_0x31ea8f['resolvedBy']['id']!==_0x163fbf&&(_0x31ea8f['resolvedBy']=_0x3bc6ec['getUser'](_0x163fbf)),_0x31ea8f['resolvedAt']=_0x2af2b3;})['catch'](_0x4742ae=>{throw console['error'](_0x4742ae),new _0x4e095a('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x5bdfb0,channelId:_0x411b97,isFromAdapter:_0x205b29}){if(!this['hasCommentThread'](_0x5bdfb0))throw new _0x4e095a('commentsrepository-missing-comment-thread',null,{'threadId':_0x5bdfb0});const _0x9d775b=this['getCommentThread'](_0x5bdfb0);if(!_0x9d775b['isResolved'])throw new _0x4e095a('commentsrepository-reopen-comment-thread',null,{'threadId':_0x5bdfb0});if(_0x9d775b['resolvedBy']=null,_0x9d775b['resolvedAt']=null,_0x205b29||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x4071dc=this['context']['plugins']['get']('PendingActions'),_0x234659=_0x4071dc['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x411b97,'threadId':_0x5bdfb0})['then'](()=>_0x4071dc['remove'](_0x234659))['catch'](_0x1a5dfd=>{throw console['error'](_0x1a5dfd),new _0x4e095a('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x5c863a,isFromAdapter:_0x50b04f}){const _0x32474d=this['getCommentThread'](_0x5c863a);if(!_0x32474d)throw new _0x4e095a('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x5c863a),this['_threads']['delete'](_0x5c863a),!_0x32474d['isSubmitted']||_0x50b04f||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x1b2100=this['context']['plugins']['get']('PendingActions'),{channelId:_0x1a601b}=_0x32474d,_0x945f08=_0x1b2100['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x1a601b,'threadId':_0x5c863a})['then'](()=>_0x1b2100['remove'](_0x945f08))['catch'](_0x279e73=>{throw console['error'](_0x279e73),new _0x4e095a('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x145cd3,unlinkedAt:_0xeba155,context:_0x2282a3,attributes:_0xb045c0,isFromAdapter:_0x180e38}){if('string'!=typeof _0x145cd3)throw new _0x4e095a('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x145cd3});if(!this['hasCommentThread'](_0x145cd3))throw new _0x4e095a('commentsrepository-missing-comment-thread',null,{'threadId':_0x145cd3});const _0x5c3007=this['getCommentThread'](_0x145cd3);let _0x4bb665=!0x1;if(void 0x0!==_0x2282a3&&_0x5c3007['context']!==_0x2282a3&&(_0x5c3007['context']=_0x2282a3,_0x4bb665=!0x0),void 0x0!==_0xeba155&&_0x5c3007['unlinkedAt']!==_0xeba155&&(_0x5c3007['unlinkedAt']=_0xeba155,_0x4bb665=!0x0),_0xb045c0&&!At(_0xb045c0,_0x5c3007['attributes'])&&(_0x5c3007['attributes']=_0xb045c0,_0x4bb665=!0x0),!_0x4bb665)return Promise['resolve']();if(!_0x5c3007['isSubmitted']||_0x180e38||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x2a22ac=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3beef0}=_0x5c3007,_0x46e2ea=_0x2a22ac['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x3beef0,'threadId':_0x145cd3,'context':_0x2282a3,'unlinkedAt':_0xeba155,'attributes':_0xb045c0})['then'](()=>_0x2a22ac['remove'](_0x46e2ea))['catch'](_0x117f27=>{throw console['error'](_0x117f27),new _0x4e095a('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x493506){const _0x1e0f85=this['context']['plugins']['get'](y),_0x4d85d1=this['getCommentThread'](_0x493506);if(_0x4d85d1['_isAttached']=!0x1,this['_threadToController']['has'](_0x4d85d1)){const _0x53c9f4=this['_threadToController']['get'](_0x4d85d1),_0x19af67=_0x53c9f4['view'],_0x4c3480=_0x1e0f85['getByInnerView'](_0x19af67);this['_threadToController']['delete'](_0x4d85d1),this['_viewToController']['delete'](_0x19af67),_0x4c3480&&_0x1e0f85['remove'](_0x4c3480),_0x53c9f4['destroy'](),_0x19af67['destroy']()['then'](()=>{this['_unbindEditors'](_0x19af67);});}}['_updateActiveAnnotation']({threadId:_0x5a6683,resolvedAt:_0x45c072,unlinkedAt:_0x125981}){const _0x2a133a=!!_0x45c072,_0x5a706f=this['context']['plugins']['get'](y),_0x400a8f=this['getCommentThread'](_0x5a6683);if(this['_threadToController']['has'](_0x400a8f)){const _0x210707=this['_threadToController']['get'](_0x400a8f)['view'],_0x21a2a6=_0x5a706f['getByInnerView'](_0x210707);_0x21a2a6&&(_0x2a133a&&_0x5a706f['_removeActiveAnnotation'](_0x21a2a6),_0x125981?_0x21a2a6['isVisible']=!0x1:_0x21a2a6['refreshVisibility']());}}['_getExternalAuthor'](_0xe033a4){const _0x3882e3=this['context']['plugins']['get'](it),_0x312781=It('external:'+_0xe033a4),_0x372493=_0x3882e3['getUser'](_0x312781);return _0x372493||_0x3882e3['addUser']({'id':_0x312781,'name':_0xe033a4});}['_createNewComment']({threadId:_0x10ad84,commentId:_0x297828=_0x1f2855(),content:_0x166ea0,authorId:_0x262272,createdAt:_0x3a6104,attributes:_0x3bf77f}){if('string'!=typeof _0x297828)throw new _0x4e095a('commentsrepository-invalid-commentid');if('string'!=typeof _0x262272)throw new _0x4e095a('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x166ea0||!_0x166ea0['trim']())throw new _0x4e095a('commentsrepository-invalid-comment-content');const _0x407fcd=this['context']['plugins']['get'](it)['getUser'](_0x262272);if(!_0x407fcd)throw new _0x4e095a('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x262272});let _0x2849e5=null,_0x4836ea=_0x3a6104;return _0x3bf77f?.['@external']&&(_0x2849e5=this['_getExternalAuthor'](_0x3bf77f['@external']['authorName']),_0x4836ea=new Date(_0x3bf77f['@external']['createdAt'])),new yi(this,{'threadId':_0x10ad84,'id':_0x297828,'author':_0x2849e5||_0x407fcd,'creator':_0x407fcd,'content':_0x166ea0,'createdAt':_0x3a6104,'authoredAt':_0x4836ea,'attributes':_0x3bf77f});}['_addComment'](_0x2d107c){let {threadId:_0x244fa2,content:_0x58c8e7,attributes:_0x1d52c0,isFromAdapter:_0x3d06bb}=_0x2d107c;const _0x6dcc41=this['getCommentThread'](_0x2d107c['threadId']);if(!_0x6dcc41)throw new _0x4e095a('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x3cc252=this['_createNewComment'](_0x2d107c),{id:_0x851d7e}=_0x3cc252;if(_0x6dcc41['_add'](_0x3cc252),_0x3d06bb||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x6dcc41['isSubmitted'])return Promise['resolve']();const _0x4d2b95=this['context']['plugins']['get']('PendingActions'),{channelId:_0x38e78e}=_0x6dcc41,_0x3e9339=_0x4d2b95['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x1d52c0||(_0x1d52c0={}),this['adapter']['addComment']({'channelId':_0x38e78e,'threadId':_0x244fa2,'commentId':_0x851d7e,'content':_0x58c8e7,'attributes':_0x1d52c0})['then'](_0x3305b6=>{_0x4d2b95['remove'](_0x3e9339),_0x3305b6&&this['_updateComment']({'channelId':_0x38e78e,'threadId':_0x244fa2,'commentId':_0x851d7e,'createdAt':_0x3305b6['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x22de26=>{throw console['error'](_0x22de26),new _0x4e095a('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x47df3e,commentId:_0x1c0a9d,content:_0x47c694,createdAt:_0x586bd8,attributes:_0x2ca11e,isFromAdapter:_0xd0b948}){if(void 0x0!==_0x47c694&&('string'!=typeof _0x47c694||!_0x47c694['trim']()['length']))throw new _0x4e095a('commentsrepository-update-comment-invalid-content');const _0x57d90c=this['getCommentThread'](_0x47df3e),_0x1c2f19=_0x57d90c['getComment'](_0x1c0a9d);if(!_0x1c2f19)throw new _0x4e095a('commentsrepository-update-missing-comment',this);let _0x43794f=!0x1;if(_0x47c694&&_0x47c694!==_0x1c2f19['content']&&(_0x1c2f19['isEditable']||_0xd0b948)&&(_0x1c2f19['content']=_0x47c694,_0x43794f=!0x0),_0x586bd8&&_0x586bd8!==_0x1c2f19['createdAt']&&(_0x1c2f19['createdAt']=_0x586bd8,_0x1c2f19['attributes']&&_0x1c2f19['attributes']['@external']||(_0x1c2f19['authoredAt']=_0x586bd8),_0x43794f=!0x0),_0x2ca11e&&!At(_0x2ca11e,_0x1c2f19['attributes'])&&(_0x1c2f19['attributes']=_0x2ca11e,_0x43794f=!0x0),!_0x43794f)return Promise['resolve']();if(_0x57d90c['fire']('commentUpdated'),_0xd0b948||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x46f604=this['context']['plugins']['get']('PendingActions'),{channelId:_0x179a80}=this['getCommentThread'](_0x1c2f19['threadId']),_0x26fe10=_0x46f604['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x179a80,'threadId':_0x47df3e,'commentId':_0x1c0a9d,'content':_0x47c694,'attributes':_0x2ca11e})['then'](()=>_0x46f604['remove'](_0x26fe10))['catch'](_0x1d561d=>{throw console['error'](_0x1d561d),new _0x4e095a('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x58a256,commentId:_0x1d4cd7,isFromAdapter:_0x3e30ba}){const _0x36a57f=this['getCommentThread'](_0x58a256),_0xe518b9=_0x36a57f['getComment'](_0x1d4cd7);if(!_0xe518b9)throw new _0x4e095a('commentsrepository-remove-missing-comment',this);if(_0x36a57f['_remove'](_0xe518b9),_0x3e30ba||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x1c672e=this['context']['plugins']['get']('PendingActions'),{channelId:_0x45acec}=_0x36a57f,_0x30d97b=_0x1c672e['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x45acec,'threadId':_0x58a256,'commentId':_0x1d4cd7})['then'](()=>_0x1c672e['remove'](_0x30d97b))['catch'](_0x41e50c=>{throw console['error'](_0x41e50c),new _0x4e095a('commentsrepository-remove-comment-internal-error',this);});}}class Ti extends/* #__PURE__ -- @preserve */
30
- _0x40f554(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x1a73ae,_0x418fff){super();const _0x4f9fac=_0x418fff['isResolvable'];this['channelId']=_0x418fff['channelId'],this['id']=_0x418fff['id'],this['comments']=new _0x294a7b(),this['_repository']=_0x1a73ae,this['_isAttached']=!0x1,this['_isSubmitted']=_0x418fff['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x1a73ae,'_permissions',_0x1a73ae,'_readOnlyChannels',()=>_0x1a73ae['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x1a73ae,'_permissions',()=>_0x1a73ae['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x1a73ae,'_permissions',()=>{const _0x1f5049=_0x1a73ae['getPermissions'](this['channelId']);return _0x1f5049['write']||_0x1f5049['admin'];}),this['bind']('isResolvable')['to'](_0x1a73ae,'_permissions',()=>_0x4f9fac&&_0x1a73ae['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x418fff['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x4f6676,_0x2391d1)=>_0x4f6676?_0x2391d1?_0x4f6676<_0x2391d1?_0x4f6676:_0x2391d1:_0x4f6676:_0x2391d1),this['set']('unlinkedAt',_0x418fff['unlinkedAt']||null),this['set']('resolvedAt',_0x418fff['resolvedAt']||null),this['set']('resolvedBy',_0x418fff['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x47335a=>!!_0x47335a),this['set']('attributes',_0x418fff['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x47c88a,_0x1417b7)=>_0x47c88a+_0x1417b7['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x4891e6,id:_0x2a4f71}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x4891e6),{'channelId':_0x4891e6,'threadId':_0x2a4f71});}['setUnlinkedAt'](_0x430db7){this['_update']({'unlinkedAt':_0x430db7});}['resolve']({resolvedAt:_0x52f6b3=new Date(),resolvedBy:_0x284b72=null,isFromAdapter:_0x2b6d72=!0x1}={}){const _0x3db626=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x3e9905,id:_0x379e31}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x3e9905),{'channelId':_0x3e9905,'threadId':_0x379e31,'resolvedAt':_0x52f6b3,'resolvedBy':_0x284b72||_0x3db626['id'],'isFromAdapter':_0x2b6d72});}['reopen']({isFromAdapter:_0x445c63=!0x1}={}){const {channelId:_0xf4a76c,id:_0x24ecb8}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0xf4a76c),{'channelId':_0xf4a76c,'threadId':_0x24ecb8,'isFromAdapter':_0x445c63});}['setContext'](_0x2ce766){this['context']||this['_update']({'context':_0x2ce766});}['setAttribute'](_0x309db8,_0x4ac424){const _0x544868=wt(this['attributes']);yt(_0x544868,_0x309db8,_0x4ac424),this['_update']({'attributes':_0x544868});}['removeAttribute'](_0xecdfc5){const _0x195e8b=wt(this['attributes']);Ct(_0x195e8b,_0xecdfc5),this['_update']({'attributes':_0x195e8b});}['remove']({isFromAdapter:_0x9f3b26=!0x1}={}){const {channelId:_0x1833e1,id:_0x4156cd}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x1833e1),{'channelId':_0x1833e1,'threadId':_0x4156cd,'isFromAdapter':_0x9f3b26});}['attachTo'](_0x35d046){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x35d046});}['addComment'](_0x2a649f){const {channelId:_0x4b3d8c,id:_0x11ce6d}=this;this['_repository']['fire'](Nt('addComment',_0x4b3d8c,_0x11ce6d),Object['assign']({'channelId':_0x4b3d8c,'threadId':_0x11ce6d},_0x2a649f));}['getComment'](_0x4a5a68){if('string'!=typeof _0x4a5a68)throw new _0x4e095a('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x4a5a68});return this['comments']['get'](_0x4a5a68);}['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'](_0x58a37e=>_0x58a37e['toJSON']()),'attributes':this['attributes']};}['_add'](_0x22ac83){return this['listenTo'](_0x22ac83,'change:authoredAt',()=>{const _0x4fa513=this['_findOptimalIndex'](_0x22ac83),_0x25625a=this['comments'];_0x4fa513-0x1!=_0x25625a['getIndex'](_0x22ac83)&&_0x4fa513+0x1!=_0x25625a['getIndex'](_0x22ac83)&&(this['_remove'](_0x22ac83),this['_add'](_0x22ac83));}),this['comments']['add'](_0x22ac83,this['_findOptimalIndex'](_0x22ac83));}['_update'](_0x47755e){const {channelId:_0x197b63,id:_0x3d8d24}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x197b63),{..._0x47755e,'channelId':_0x197b63,'threadId':_0x3d8d24});}['_remove'](_0x364a92){return this['stopListening'](_0x364a92),_0x364a92['destroy'](),this['comments']['remove'](_0x364a92);}['_findOptimalIndex'](_0x140fce){const _0x68a291=this['comments']['find'](_0x744c71=>new Date(_0x744c71['authoredAt'])['getTime']()>new Date(_0x140fce['authoredAt'])['getTime']());return _0x68a291?this['comments']['getIndex'](_0x68a291):this['length'];}}class yi extends/* #__PURE__ -- @preserve */
31
- _0x40f554(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0xeabda9,_0x2926cc){super();const _0x46544a=_0xeabda9['context']['plugins']['get'](it)['me'],_0x428493=_0xeabda9['getCommentThread'](_0x2926cc['threadId']),_0x52b5eb=0x0===_0x428493['comments']['length'],_0x1a5aba=_0x46544a===_0x2926cc['author'];this['id']=_0x2926cc['id'],this['threadId']=_0x2926cc['threadId'],this['author']=_0x2926cc['author'],this['creator']=_0x2926cc['creator'],this['isExternal']=Boolean(_0x2926cc['attributes']&&_0x2926cc['attributes']['@external']),this['set']('content',_0x2926cc['content']),this['createdAt']=_0x2926cc['createdAt']||new Date(),this['set']('authoredAt',_0x2926cc['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x428493,'resolvedAt'),this['set']('attributes',_0x2926cc['attributes']||{}),this['bind']('isEditable')['to'](_0xeabda9,'_permissions',()=>{const _0xe6d068=_0xeabda9['getPermissions'](_0x428493['channelId'])['write'],_0x4cc07e=_0xeabda9['getPermissions'](_0x428493['channelId'])['modifyAll'];return _0x1a5aba&&_0xe6d068||!_0x1a5aba&&_0x4cc07e;}),this['bind']('isRemovable')['to'](_0x428493,'isRemovable',_0xeabda9,'_permissions',_0x2048ad=>{const _0xa9f7ba=_0xeabda9['getPermissions'](_0x428493['channelId'])['write'],_0x3ea218=_0xeabda9['getPermissions'](_0x428493['channelId'])['modifyAll'];return _0x1a5aba&&_0xa9f7ba||_0x2048ad&&_0x52b5eb||!_0x1a5aba&&_0x3ea218&&!_0x52b5eb;}),this['bind']('isReadOnly')['to'](_0x428493,'isReadOnly'),this['_repository']=_0xeabda9;}get['weight'](){return Math['max'](function(_0x2be283){const _0x41fbf5=document['createElement']('div');return _0x41fbf5['innerHTML']=_0x2be283,_0x41fbf5['textContent']['length'];}(this['content']),0xc8);}['update'](_0x38c72a){const {threadId:_0x3e9d86,id:_0x1b677b}=this;if(!this['_repository']['hasCommentThread'](_0x3e9d86))throw new _0x4e095a('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x3fde93}=this['_repository']['getCommentThread'](_0x3e9d86);this['_repository']['fire'](Nt('updateComment',_0x3fde93,_0x3e9d86),{'channelId':_0x3fde93,'threadId':_0x3e9d86,'commentId':_0x1b677b,..._0x38c72a});}['setAttribute'](_0x2740e3,_0x3b1001){const _0x34d42f=wt(this['attributes']);yt(_0x34d42f,_0x2740e3,_0x3b1001),this['update']({'attributes':_0x34d42f});}['removeAttribute'](_0x27541a){const _0x122b5f=wt(this['attributes']);Ct(_0x122b5f,_0x27541a),this['update']({'attributes':_0x122b5f});}['remove'](_0x5ef75d={}){if(!_0x5ef75d['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x15b89a,id:_0x5ef2c4}=this;if(!this['_repository']['hasCommentThread'](_0x15b89a))throw new _0x4e095a('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x42e4f3}=this['_repository']['getCommentThread'](_0x15b89a);this['_repository']['fire'](Nt('removeComment',_0x42e4f3,_0x15b89a),{'channelId':_0x42e4f3,'threadId':_0x15b89a,'commentId':_0x5ef2c4,..._0x5ef75d});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x2a7324,..._0x421296){for(const _0x2c6473 of _0x421296)void 0x0!==_0x2c6473&&(_0x2a7324+=':'+String(_0x2c6473));return _0x2a7324;}class ot extends _0x324d2c{constructor(_0x234d55){super(_0x234d55),this['set']('hasContent',!0x1);}['refresh'](){const _0x1be2e3=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x4fba1c of _0x1be2e3['getRanges']())if(this['_hasContent'](_0x4fba1c))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x25fe3d=_0x1f2855(),ranges:_0x23c1da,comment:_0x26a4dc}={}){const _0x2b9bc0=this['editor']['model'],_0x444aae=_0x23c1da??Array['from'](_0x2b9bc0['document']['selection']['getRanges']()),_0x5060cc=[];for(const _0x1ea752 of _0x444aae)this['_hasContent'](_0x1ea752)&&_0x5060cc['push'](this['_trimToContent'](_0x1ea752));if(!_0x5060cc['length'])throw new _0x4e095a('addcommentthreadcommand-incorrect-ranges',null);_0x26a4dc&&this['_createCommentThread'](_0x25fe3d,_0x26a4dc),this['_createMarkersFromRanges'](_0x25fe3d,_0x5060cc,!!_0x26a4dc);}['_createMarkersFromRanges'](_0x17cc01,_0x308242,_0x431ec1){this['editor']['model']['change'](_0x379294=>{for(const _0x488e01 of _0x308242){const _0x2a88fb=_0x1f2855()['substr'](0x1,0x5),_0x5862b7='comment:'+_0x17cc01+':'+_0x2a88fb;_0x379294['addMarker'](_0x5862b7,{'range':_0x488e01,'usingOperation':_0x431ec1,'affectsData':_0x431ec1});}});}['_createCommentThread'](_0x3d7b61,_0x56c2dd){const _0x3f754c=this['editor']['plugins']['get']('CommentsRepository'),_0x345b95=this['editor']['config']['get']('collaboration.channelId'),_0x1bedab=this['editor']['plugins']['get']('Users')['me'];if(!_0x1bedab)throw new _0x4e095a('addcommentthreadcommand-user-not-found',null);_0x3f754c['addCommentThread']({'threadId':_0x3d7b61,'channelId':_0x345b95,'comments':[{'authorId':_0x1bedab['id'],'content':_0x56c2dd,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x5a10b){for(const _0x30a5a3 of _0x5a10b['getItems']())if(this['_itemIsContent'](_0x30a5a3))return!0x0;return!0x1;}['_itemIsContent'](_0x527d31){return _0x527d31['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x527d31)&&!_0x527d31['is']('element','tableCell');}['_trimToContent'](_0x4e1a34){const _0x59d247=_0x215deb=>!this['_itemIsContent'](_0x215deb['item']),_0x12aae1=_0x4e1a34['start']['getLastMatchingPosition'](_0x59d247),_0x5ceb6e=_0x4e1a34['end']['getLastMatchingPosition'](_0x59d247,{'direction':'backward'});return this['editor']['model']['createRange'](_0x12aae1,_0x5ceb6e);}}class b extends _0x347641{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2246ec){super(_0x2246ec),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x3d7213=this['editor'],_0x1d6c1b=_0x3d7213['model']['document']['selection'],_0x13c746=_0x44a384(()=>this['refreshSelectedViews'](),0xa);_0x1d6c1b['on']('change:range',(_0xa81e0e,_0x440c6c)=>{_0x440c6c['directChange']&&(_0x13c746['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x3d7213['editing']['view']['document'],'change:isFocused',(_0x34412a,_0x674e92,_0x21de53)=>{_0x21de53&&_0x13c746();}),this['listenTo'](_0x3d7213['ui']['focusTracker'],'change:isFocused',(_0x22b5bd,_0x538b4c,_0x54544e)=>{_0x54544e||this['fire']('blur',{'isAnnotationTracked':_0x5d0a34=>this['_editorAnnotationsData']['has'](_0x5d0a34['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x2ff64e){if(this['_editorAnnotations']['has'](_0x2ff64e['view']))return;this['_editorAnnotations']['add'](_0x2ff64e['view']),this['editor']['ui']['focusTracker']['add'](_0x2ff64e['view']['element']);const _0x13d3e9=this['editor']['plugins']['get'](y);this['listenTo'](_0x13d3e9['collection'],'remove',(_0x2e4994,_0x19d0ae)=>{this['editor']['ui']['focusTracker']['remove'](_0x19d0ae['view']['element']),this['_editorAnnotations']['delete'](_0x19d0ae['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x24bc4f){if('function'!=typeof _0x24bc4f)throw new _0x4e095a('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x24bc4f);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x569500,annotations:_0x4f37d4}){const _0x3350d8=[],_0x6d6a32=this['editor']['model']['document']['selection'],_0x357aa8=Array['from'](_0x6d6a32['getRanges']());for(const [_0x4738a3,_0x26cfbe]of this['_editorAnnotationsData']){const _0x21535d=_0x45493b(_0x26cfbe),_0x4becec=_0x4f37d4['getByInnerView'](_0x4738a3);_0x21535d&&_0x4becec&&_0x3350d8['push']({'annotation':_0x4becec,'range':_0x21535d});}function _0x45493b(_0x164a63){for(const _0x32224c of _0x164a63)for(const _0x2a1127 of _0x357aa8)if(_0x32224c['containsRange'](_0x2a1127,!_0x6d6a32['isCollapsed']))return _0x32224c;return null;}return _0x3350d8['sort']((_0x82e8d5,_0x4cdd1a)=>{const _0x14724c=_0x82e8d5['range'],_0x443632=_0x4cdd1a['range'];if(!_0x14724c['isEqual'](_0x443632)){if(_0x14724c['containsRange'](_0x443632,!0x0))return 0x1;if(_0x443632['containsRange'](_0x14724c,!0x0))return-0x1;}return _0x82e8d5['annotation']==_0x569500?-0x1:_0x4cdd1a['annotation']==_0x569500?0x1:0x0;})['map'](_0x3d6ba8=>_0x3d6ba8['annotation']);}get['_editorAnnotationsData'](){const _0x2fa89c=new Map();for(const _0x281e45 of Array['from'](this['_dataCollectors']))for(const [_0x55b373,_0x39739f]of _0x281e45())_0x2fa89c['set'](_0x55b373,_0x39739f);return _0x2fa89c;}}class st extends _0x347641{['afterInit'](){const _0x2a544b=this['editor'];if(!_0x2a544b['plugins']['has']('RestrictedEditingModeEditing'))return;_0x2a544b['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x347641{constructor(_0x2c8b2d){super(_0x2c8b2d),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x3e1c02=this['editor'],_0x3cadeb=_0x3e1c02['commands']['get']('importWord'),_0x4362a6=_0x3e1c02['plugins']['get'](it);_0x3cadeb&&(_0x3cadeb['on']('execute',(_0x3bce96,[,_0x172e1d])=>{_0x172e1d['collaboration_features']={'comments':!0x0,'user_id':_0x4362a6['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x3cadeb,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x4f3be8,_0x2cdd3c){const {comment_threads:_0x2e3ea1}=_0x2cdd3c;_0x2e3ea1&&_0x2e3ea1['forEach'](({thread_id:_0x284de0,comments:_0x4410ce,is_resolved:_0x42fa3d})=>{const _0x554e44=new Date(),_0x2cc140=_0x4410ce['map'](({author:_0x14b0a9,content:_0x4b7576,created_at:_0x148b07})=>({'content':_0x4b7576,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x554e44,'attributes':{'@external':{'authorName':_0x14b0a9,'createdAt':_0x148b07?new Date(_0x148b07):new Date(),'source':'importWord'}}})),_0x2e1001=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x2e1001,'threadId':_0x284de0,'comments':_0x2cc140,'resolvedAt':_0x42fa3d?_0x554e44:null});});}}class at extends _0x347641{constructor(_0x597e31){super(_0x597e31),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x421a4d=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x421a4d,'contentInsertion',(_0x4f3c62,_0x29e279)=>this['_removeMarkersWithoutThreads'](_0x29e279['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x1a74ee){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x1a74ee;const _0x3831d0=this['editor']['plugins']['get']('CommentsRepository');for(const _0x3f3c7b of _0x1a74ee['keys']()){const [_0x4d5498,_0x1ec839]=_0x3f3c7b['split'](':');'comment'!=_0x4d5498||_0x3831d0['hasCommentThread'](_0x1ec839)||_0x1a74ee['delete'](_0x3f3c7b);}return _0x1a74ee;}['_registerMarkerInClipboardPipeline'](){const _0x14ce35=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x54d565=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x54d565&&_0x14ce35['_registerMarkerToCopy']('comment',_0x54d565);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x181183){switch(_0x181183){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0x54b9b8){const _0x86a339=_0x54b9b8['split'](':');return{'group':_0x86a339[0x0],'id':_0x86a339[0x1],'part':_0x86a339[0x2]};}class ut extends _0x347641{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x120039,_0x5c100e)=>{if(!_0x5c100e['options']['showCommentHighlights'])return null;if(_0x5c100e['options']['ignoreResolvedComments']){const {id:_0x79b70c}=ft(_0x120039['markerName']),_0x3b38a0=this['editor']['plugins']['get'](o);if(_0x3b38a0['getCommentThread'](_0x79b70c)?.['isResolved']&&_0x120039['item'])return _0x5c100e['consumable']['consume'](_0x120039['item'],'addMarker:'+_0x120039['markerName']),_0x5c100e['consumable']['consume'](_0x120039['item'],'removeMarker:'+_0x120039['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x508c9f=>{_0x508c9f['on']('addMarker:comment',(_0x2b6010,_0x44b27b,_0x50d69a)=>{if(!_0x50d69a['options']['showCommentHighlights'])return;const _0x38a03b=_0x44b27b['item'];if(!_0x38a03b)return;const _0x17585d=_0x50d69a['mapper']['toViewElement'](_0x38a03b);this['editor']['model']['schema']['isObject'](_0x38a03b)&&_0x17585d&&!_0x17585d['getCustomProperty']('widget')&&_0x17585d['is']('containerElement')&&_0x4c4665(_0x17585d,_0x50d69a['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x26c69f,{writer:_0x4389a6,options:_0x2e915b})=>{if(!_0x2e915b['showCommentHighlights'])return null;const _0x20ccf7=_0x4389a6['createContainerElement']('div'),_0x45b62b=_0x4389a6['createEmptyElement']('hr');return _0x4389a6['addClass']('ck-horizontal-line',_0x20ccf7),_0x4389a6['insert'](_0x4389a6['createPositionAt'](_0x20ccf7,0x0),_0x45b62b),_0x20ccf7;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x38ddd1,{writer:_0xadbc17,options:_0x23ba90})=>{if(!_0x23ba90['showCommentHighlights'])return null;const _0x1435f1=_0xadbc17['createContainerElement']('span'),_0x17b040=_0xadbc17['createEmptyElement']('img');return _0xadbc17['addClass']('image-inline',_0x1435f1),_0xadbc17['insert'](_0xadbc17['createPositionAt'](_0x1435f1,0x0),_0x17b040),_0x1435f1;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x10ec42,{writer:_0x5655df,options:_0x2f74e1})=>{if(_0x2f74e1['showCommentHighlights'])return _0x5655df['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0xfca346,_0x53cc0d,_0x50a593)=>{_0x50a593['options']['showCommentHighlights']&&_0xfca346['stop']();},{'priority':'high'});}}class r extends _0x347641{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(_0x5a2ffd){super(_0x5a2ffd),this['set']('isThreadsLoadingPaused',!0x0),_0x5a2ffd['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x2cbe32,_0x8a1a2,_0x2f5e06,_0xde1053)=>{const _0x51aef1=_0x5a2ffd['plugins']['get'](o),_0x2c5bca=_0x2f5e06?ft(_0x2f5e06)['id']:null;_0x5a2ffd['model']['change'](()=>{if(_0x2c5bca){const _0x5b3747=this['getAllMarkersForId'](_0x2c5bca);for(const _0x490544 of _0x5b3747)_0x5a2ffd['editing']['reconvertMarker'](_0x490544);}if(_0xde1053){const {id:_0x18b709}=ft(_0xde1053),_0x375147=_0x51aef1['getCommentThread'](_0x18b709);if(_0x375147&&_0x375147['unlinkedAt'])return;if(_0x375147&&!_0x375147['isAttached'])return;const _0x2ff4e0=this['getAllMarkersForId'](_0x18b709);for(const _0x553ac5 of _0x2ff4e0)_0x5a2ffd['editing']['reconvertMarker'](_0x553ac5);}}),_0x2c5bca&&this['scrollToThreadMarker'](_0x2c5bca);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x494ea1=this['editor'],_0x11ef94=_0x494ea1['plugins']['get'](o),_0x40bb10=_0x494ea1['config']['get']('collaboration.channelId'),_0x35b3ae=_0x11ef94['getCommentThreads']()['filter'](_0x46129d=>_0x46129d['channelId']!==_0x40bb10);_0x494ea1['commands']['add']('addCommentThread',new ot(_0x494ea1)),this['listenTo'](_0x494ea1,'change:isReadOnly',(_0x3372b9,_0x49fdfd,_0x10ac5f)=>{_0x11ef94['switchReadOnly'](_0x10ac5f,_0x494ea1['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x11ef94,dt('addCommentThread',_0x40bb10),(_0x19b868,{threadId:_0x1f50cf})=>{const _0x297db9=this['editor']['plugins']['get'](o)['getCommentThread'](_0x1f50cf);_0x297db9?.['unlinkedAt']&&this['_attachArchivedThread'](_0x1f50cf);}),this['listenTo'](_0x11ef94,dt('removeCommentThread',_0x40bb10),(_0x54c362,{threadId:_0xab6ba1})=>{_0x494ea1['model']['enqueueChange']({'isUndoable':!0x1},_0x1c6541=>{const _0x20ef52=this['getAllMarkersForId'](_0xab6ba1);for(const _0x3d2e4e of _0x20ef52)_0x1c6541['removeMarker'](_0x3d2e4e);});}),this['listenTo'](_0x11ef94,dt('resolveCommentThread',_0x40bb10),(_0x5ce875,{threadId:_0x3cb33b})=>{(this['_reconvertMarkers'](_0x3cb33b),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x3cb33b)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x11ef94,dt('reopenCommentThread',_0x40bb10),(_0x3804e2,{threadId:_0x5b9745})=>{this['_reconvertMarkers'](_0x5b9745);},{'priority':'low'}),this['listenTo'](_0x11ef94,dt('addComment',_0x40bb10),(_0x2aa869,{threadId:_0x40e92b,isFromAdapter:_0x466666})=>{const _0x1f3a24=this['getAllMarkersForId'](_0x40e92b);if(_0x466666||0x0==_0x1f3a24['length']||!_0x11ef94['hasCommentThread'](_0x40e92b))return;0x1===_0x11ef94['getCommentThread'](_0x40e92b)['length']&&_0x494ea1['model']['enqueueChange']({'isUndoable':!0x1},_0x2a1861=>{for(const _0x2d0b1c of _0x1f3a24)_0x2a1861['updateMarker'](_0x2d0b1c,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x35b3ae);}['afterInit'](){!async function(_0x3fe81d){const _0x25ab2a=_0x36a6b9([0x4b,0x70,0x4f,0x42,0x4a,0x47,0x4e,0x53,0x45,0x67,0x71,0x43,0x79,0x66,0x56,0x46,0x31,0x6b,0x5a,0x38,0x6c,0x62,0x6e,0x52,0x6a,0x4d,0x37,0x65,0x49,0x7a,0x41,0x73,0x44,0x51,0x48,0x77,0x39,0x61,0x54,0x68,0x75,0x36,0x72,0x63,0x59,0x69,0x30,0x35,0x55,0x6d,0x50,0x4c,0x34,0x64,0x33,0x58,0x32,0x57,0x6f,0x74,0x76,0x78]),_0x2e546d=0x73460ab3,_0x31efd4=0x734179c3^_0x2e546d,_0x3b2dc2=window[_0x36a6b9([0x44,0x61,0x74,0x65])][_0x36a6b9([0x6e,0x6f,0x77])](),_0x536c2e=_0x3fe81d[_0x36a6b9([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x23d90f=new window[(_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5efea9=>{_0x536c2e[_0x36a6b9([0x6f,0x6e,0x63,0x65])](_0x36a6b9([0x72,0x65,0x61,0x64,0x79]),_0x5efea9);}),_0xc920ea={[_0x36a6b9([0x6b,0x74,0x79])]:_0x36a6b9([0x45,0x43]),[_0x36a6b9([0x75,0x73,0x65])]:_0x36a6b9([0x73,0x69,0x67]),[_0x36a6b9([0x63,0x72,0x76])]:_0x36a6b9([0x50,0x2d,0x32,0x35,0x36]),[_0x36a6b9([0x78])]:_0x36a6b9([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]),[_0x36a6b9([0x79])]:_0x36a6b9([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]),[_0x36a6b9([0x61,0x6c,0x67])]:_0x36a6b9([0x45,0x53,0x32,0x35,0x36])},_0x261842=_0x536c2e[_0x36a6b9([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x36a6b9([0x67,0x65,0x74])](_0x36a6b9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3ce6d8(){let _0x1e1597,_0x4c90fb=null,_0x3e603e=null;try{if(_0x261842==_0x36a6b9([0x47,0x50,0x4c]))return _0x36a6b9([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1e1597=_0x3d4811(),!_0x1e1597)return _0x36a6b9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1e1597[_0x36a6b9([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3e603e=_0x2e45a8(_0x1e1597[_0x36a6b9([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1e1597[_0x36a6b9([0x6a,0x74,0x69])])),await _0x210d0e()?_0x49a522()?_0x4ef9b0()?_0x36a6b9([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x8bbb27()?(_0x1e1597[_0x36a6b9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x36a6b9([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4c90fb=_0x203cd2(_0x36a6b9([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1e1597[_0x36a6b9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x36a6b9([0x74,0x72,0x69,0x61,0x6c])&&(_0x4c90fb=_0x203cd2(_0x36a6b9([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3f078b()):_0x36a6b9([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x36a6b9([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x36a6b9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x36a6b9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4ef9b0(){const _0x346068=[_0x36a6b9([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x36a6b9([0x74,0x72,0x69,0x61,0x6c])][_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e1597[_0x36a6b9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3b2dc2/0x3e8:0xe10*_0x31efd4;return _0x1e1597[_0x36a6b9([0x65,0x78,0x70])]<_0x346068;}function _0x49a522(){const _0xd74b67=_0x1e1597[_0x36a6b9([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0xd74b67)return!0x1;if(_0xd74b67[_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x36a6b9([0x2a])))return!0x0;if(_0xd74b67[_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x36a6b9([0x43,0x4d,0x54])))return!0x0;if(_0xd74b67[_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x36a6b9([0x54,0x52,0x49,0x4c,0x49,0x55,0x4d]))&&_0x47c3ac())return!0x0;if(_0xd74b67[_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x36a6b9([0x52,0x43,0x4d,0x54]))){if(_0x318608())return!0x0;if(_0x3a7028()||_0x56e42d())return!0x0;}return!0x1;}function _0x8bbb27(){const _0x44eb3d=_0x1e1597[_0x36a6b9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x44eb3d||0x0==_0x44eb3d[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x57cb6b}=new URL(window[_0x36a6b9([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x44eb3d[_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57cb6b))return!0x0;const _0x1ee1f7=_0x57cb6b[_0x36a6b9([0x73,0x70,0x6c,0x69,0x74])](_0x36a6b9([0x2e]));return _0x44eb3d[_0x36a6b9([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x76da57=>_0x76da57[_0x36a6b9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x36a6b9([0x2a])))[_0x36a6b9([0x6d,0x61,0x70])](_0x30dae7=>_0x30dae7[_0x36a6b9([0x73,0x70,0x6c,0x69,0x74])](_0x36a6b9([0x2e])))[_0x36a6b9([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1492ae=>_0x1492ae[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x1ee1f7[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x36a6b9([0x6d,0x61,0x70])](_0x4f2df4=>Array(_0x1ee1f7[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x4f2df4[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x36a6b9([0x66,0x69,0x6c,0x6c])](_0x4f2df4[0x0]===_0x36a6b9([0x2a])?_0x36a6b9([0x2a]):'')[_0x36a6b9([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x4f2df4))[_0x36a6b9([0x73,0x6f,0x6d,0x65])](_0x506044=>_0x1ee1f7[_0x36a6b9([0x65,0x76,0x65,0x72,0x79])]((_0x2c2fb3,_0x2cf7e3)=>_0x506044[_0x2cf7e3]===_0x2c2fb3||_0x506044[_0x2cf7e3]===_0x36a6b9([0x2a])));}function _0x3f078b(){return _0x4c90fb&&_0x3e603e?new window[(_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x256351,_0x2475d0)=>{_0x4c90fb[_0x36a6b9([0x74,0x68,0x65,0x6e])](_0x256351,_0x2475d0),_0x3e603e[_0x36a6b9([0x74,0x68,0x65,0x6e])](_0x3adfdf=>{_0x3adfdf!=_0x36a6b9([0x56,0x61,0x6c,0x69,0x64])&&_0x256351(_0x3adfdf);},_0x2475d0);}):_0x4c90fb||_0x3e603e||_0x36a6b9([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2e45a8(_0x354889,_0xfb2cef){return new window[(_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x9ca74f=>{if(_0x421234())return _0x9ca74f(_0x36a6b9([0x56,0x61,0x6c,0x69,0x64]));_0x19b9a2(),_0x536c2e[_0x36a6b9([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x36a6b9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x33afbb=!0x1;const _0x4c10d0=_0x1f2855();function _0x34d7a8(_0x4923f2){return!!_0x4923f2&&(typeof _0x4923f2===_0x36a6b9([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x4923f2===_0x36a6b9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x4923f2[_0x36a6b9([0x74,0x68,0x65,0x6e])]===_0x36a6b9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x4923f2[_0x36a6b9([0x63,0x61,0x74,0x63,0x68])]===_0x36a6b9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2f8e02(_0x5792ad){_0x366eb8(_0x5792ad)[_0x36a6b9([0x74,0x68,0x65,0x6e])](_0x1635ef=>{if(!_0x1635ef||_0x1635ef[_0x36a6b9([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x36a6b9([0x6f,0x6b]))return _0x36a6b9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x537976(_0x25abd1(_0x4c10d0+_0xfb2cef))!=_0x1635ef[_0x36a6b9([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x36a6b9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x36a6b9([0x56,0x61,0x6c,0x69,0x64]);})[_0x36a6b9([0x74,0x68,0x65,0x6e])](_0x439a5b=>(_0x292699(),_0x439a5b),()=>{const _0xc0de36=_0x3c21fc();return null==_0xc0de36?(_0x292699(),_0x36a6b9([0x56,0x61,0x6c,0x69,0x64])):_0x36a6b9(_0x3b2dc2-_0xc0de36>(0x574a8eb3^_0x2e546d)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x36a6b9([0x74,0x68,0x65,0x6e])](_0x9ca74f)[_0x36a6b9([0x63,0x61,0x74,0x63,0x68])](()=>{_0x9ca74f(_0x36a6b9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x155d4f=0x7370e433^_0x2e546d;function _0x292699(){const _0x2f0493=_0x36a6b9([0x6c,0x6c,0x63,0x74,0x2d])+_0x537976(_0x25abd1(_0x354889)),_0x1bf4a6=_0x64171d(_0x537976(window[_0x36a6b9([0x4d,0x61,0x74,0x68])][_0x36a6b9([0x63,0x65,0x69,0x6c])](_0x3b2dc2/_0x155d4f)));window[_0x36a6b9([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x36a6b9([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2f0493,_0x1bf4a6);}function _0x3c21fc(){const _0x4d1de3=_0x36a6b9([0x6c,0x6c,0x63,0x74,0x2d])+_0x537976(_0x25abd1(_0x354889)),_0x276c6c=window[_0x36a6b9([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x36a6b9([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4d1de3);return _0x276c6c?window[_0x36a6b9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x64171d(_0x276c6c),0x10)*_0x155d4f:null;}function _0x366eb8(_0x4b5179){return new window[(_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3f38e5,_0x23f7e9)=>{_0x4b5179[_0x36a6b9([0x74,0x68,0x65,0x6e])](_0x3f38e5,_0x23f7e9),window[_0x36a6b9([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x23f7e9,0x7347de73^_0x2e546d);});}}_0x536c2e[_0x36a6b9([0x6f,0x6e])](_0x36a6b9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2c4c69,_0x3ca014)=>{if(_0x3ca014[0x0]!=_0x354889)return _0x9ca74f(_0x36a6b9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3ca014[0x1]={..._0x3ca014[0x1],[_0x36a6b9([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4c10d0};},{[_0x36a6b9([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x36a6b9([0x68,0x69,0x67,0x68])}),_0x536c2e[_0x36a6b9([0x6f,0x6e])](_0x36a6b9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1041f4=>{_0x34d7a8(_0x1041f4[_0x36a6b9([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x33afbb=!0x0,_0x2f8e02(_0x1041f4[_0x36a6b9([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x36a6b9([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x36a6b9([0x6c,0x6f,0x77])}),_0x23d90f[_0x36a6b9([0x74,0x68,0x65,0x6e])](()=>{_0x33afbb||_0x9ca74f(_0x36a6b9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x421234(){return _0x536c2e[_0x36a6b9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x36a6b9([0x76,0x69,0x65,0x77])][_0x36a6b9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x36a6b9([0x61,0x75,0x74,0x6f]);}function _0x19b9a2(){_0x536c2e[_0x36a6b9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x36a6b9([0x76,0x69,0x65,0x77])][_0x36a6b9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x36a6b9([0x61,0x75,0x74,0x6f]);}}function _0x203cd2(_0x577f81){const _0x51a8d8=[new window[(_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1eaa1a=>setTimeout(_0x1eaa1a,0x734f347f^_0x2e546d)),_0x23d90f[_0x36a6b9([0x74,0x68,0x65,0x6e])](()=>new window[(_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x552e8f=>{let _0x25c820=0x0;_0x536c2e[_0x36a6b9([0x6d,0x6f,0x64,0x65,0x6c])][_0x36a6b9([0x6f,0x6e])](_0x36a6b9([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x471e14,_0x26042e)=>{_0x26042e[0x0][_0x36a6b9([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x25c820++,_0x25c820==(0x73460b4b^_0x2e546d)&&(_0x552e8f(),_0x471e14[_0x36a6b9([0x6f,0x66,0x66])]());});}))];return window[_0x36a6b9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x36a6b9([0x72,0x61,0x63,0x65])](_0x51a8d8)[_0x36a6b9([0x74,0x68,0x65,0x6e])](()=>_0x577f81);}async function _0x230475(){await _0x23d90f,_0x536c2e[_0x36a6b9([0x6d,0x6f,0x64,0x65,0x6c])][_0x36a6b9([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4fc43d,_0x536c2e[_0x36a6b9([0x6d,0x6f,0x64,0x65,0x6c])][_0x36a6b9([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4fc43d,_0x536c2e[_0x36a6b9([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x36a6b9([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x47c3ac(){return window[_0x36a6b9([0x67,0x6c,0x6f,0x62])]&&window[_0x36a6b9([0x67,0x6c,0x6f,0x62])][_0x36a6b9([0x74,0x72,0x69,0x6c,0x69,0x75,0x6d,0x56,0x65,0x72,0x73,0x69,0x6f,0x6e])];}function _0x318608(){return _0x5dc0fe(_0x36a6b9([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x59347a(_0x36a6b9([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x36a6b9([0x73,0x74,0x61,0x74,0x65])]==_0x36a6b9([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3a7028(){return _0x5dc0fe(_0x36a6b9([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 _0x56e42d(){return _0x5dc0fe(_0x36a6b9([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x369ac3(_0x3e3183){const _0x4e13b9=_0x1fdddf();_0x536c2e[_0x4e13b9]=_0x36a6b9([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x3e3183,_0x3e3183!=_0x36a6b9([0x56,0x61,0x6c,0x69,0x64])&&_0x230475();}function _0x1fdddf(){const _0x4275f6=window[_0x36a6b9([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x36a6b9([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x36a6b9([0x6e,0x6f,0x77])]())[_0x36a6b9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x36a6b9([0x2e]),'');let _0x4b3fb0=_0x36a6b9([0x4b]);for(let _0x31df21=0x0;_0x31df21<_0x4275f6[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x31df21+=0x2){let _0x22d8f3=window[_0x36a6b9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4275f6[_0x36a6b9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x31df21,_0x31df21+0x2));_0x22d8f3>=_0x25ab2a[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x22d8f3-=_0x25ab2a[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4b3fb0+=_0x25ab2a[_0x22d8f3];}return _0x4b3fb0;}function _0x3d4811(){const _0x5e6fa8=_0x261842[_0x36a6b9([0x73,0x70,0x6c,0x69,0x74])](_0x36a6b9([0x2e]));if(0x3!=_0x5e6fa8[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1643ce(_0x5e6fa8[0x1]);function _0x1643ce(_0x292cb4){const _0x3d7f31=_0x5ea990(_0x292cb4);return _0x3d7f31&&_0x1c49a7()?_0x3d7f31:null;function _0x1c49a7(){const _0x4d9895=_0x3d7f31[_0x36a6b9([0x6a,0x74,0x69])],_0x3422ea=window[_0x36a6b9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4d9895[_0x36a6b9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4d9895[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x554594={..._0x3d7f31,[_0x36a6b9([0x6a,0x74,0x69])]:_0x4d9895[_0x36a6b9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4d9895[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x554594[_0x36a6b9([0x76,0x63])],_0x25abd1(_0x554594)==_0x3422ea;}}}async function _0x210d0e(){let _0x4e5a6f=!0x0;try{const _0x419d6b=_0x261842[_0x36a6b9([0x73,0x70,0x6c,0x69,0x74])](_0x36a6b9([0x2e])),[_0x30c64c,_0x42b28e,_0x574dc5]=_0x419d6b;return _0xe0bb96(_0x30c64c),await _0x502aeb(_0x30c64c,_0x42b28e,_0x574dc5),_0x4e5a6f;}catch{return!0x1;}function _0xe0bb96(_0x5997f4){const _0x2b2263=_0x5ea990(_0x5997f4);_0x2b2263&&_0x2b2263[_0x36a6b9([0x61,0x6c,0x67])]==_0x36a6b9([0x45,0x53,0x32,0x35,0x36])||(_0x4e5a6f=!0x1);}async function _0x502aeb(_0x2345ad,_0x733426,_0x40f76a){const _0x48ae13=window[_0x36a6b9([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x36a6b9([0x66,0x72,0x6f,0x6d])](_0x1576ea(_0x40f76a),_0x1d2956=>_0x1d2956[_0x36a6b9([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x5296ac=new window[(_0x36a6b9([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x36a6b9([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2345ad+_0x36a6b9([0x2e])+_0x733426),_0x49d6fd=window[_0x36a6b9([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x36a6b9([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x49d6fd)return;const _0x226cb9=await _0x49d6fd[_0x36a6b9([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x36a6b9([0x6a,0x77,0x6b]),_0xc920ea,{[_0x36a6b9([0x6e,0x61,0x6d,0x65])]:_0x36a6b9([0x45,0x43,0x44,0x53,0x41]),[_0x36a6b9([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x36a6b9([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x36a6b9([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x49d6fd[_0x36a6b9([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x36a6b9([0x6e,0x61,0x6d,0x65])]:_0x36a6b9([0x45,0x43,0x44,0x53,0x41]),[_0x36a6b9([0x68,0x61,0x73,0x68])]:{[_0x36a6b9([0x6e,0x61,0x6d,0x65])]:_0x36a6b9([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x226cb9,_0x48ae13,_0x5296ac)||(_0x4e5a6f=!0x1);}}function _0x5ea990(_0x3f26b3){return _0x3f26b3[_0x36a6b9([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x36a6b9([0x65,0x79]))?JSON[_0x36a6b9([0x70,0x61,0x72,0x73,0x65])](_0x1576ea(_0x3f26b3)):null;}function _0x1576ea(_0x548a01){return window[_0x36a6b9([0x61,0x74,0x6f,0x62])](_0x548a01[_0x36a6b9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x36a6b9([0x2b]))[_0x36a6b9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x36a6b9([0x2f])));}function _0x25abd1(_0x3c4605){let _0x2509a4=0x1505;function _0x6c4d25(_0xa40415){for(let _0x5d8a3d=0x0;_0x5d8a3d<_0xa40415[_0x36a6b9([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5d8a3d++){const _0x29f6d8=_0xa40415[_0x36a6b9([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5d8a3d);_0x2509a4=(_0x2509a4<<0x5)+_0x2509a4+_0x29f6d8,_0x2509a4&=_0x2509a4;}}function _0x1a2253(_0x293b51){Array[_0x36a6b9([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x293b51)?_0x293b51[_0x36a6b9([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x1a2253):_0x293b51&&typeof _0x293b51==_0x36a6b9([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x36a6b9([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x293b51)[_0x36a6b9([0x73,0x6f,0x72,0x74])]()[_0x36a6b9([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x966ff5,_0x25a6b9])=>{_0x6c4d25(_0x966ff5),_0x1a2253(_0x25a6b9);}):_0x6c4d25(window[_0x36a6b9([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x293b51));}return _0x1a2253(_0x3c4605),_0x2509a4>>>0x0;}function _0x537976(_0x843ec7){return _0x843ec7[_0x36a6b9([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x36a6b9([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x36a6b9([0x30]));}function _0x64171d(_0x39f4ce){return _0x39f4ce[_0x36a6b9([0x73,0x70,0x6c,0x69,0x74])]('')[_0x36a6b9([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x36a6b9([0x6a,0x6f,0x69,0x6e])]('');}function _0x5dc0fe(_0x2e9915){return _0x536c2e[_0x36a6b9([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x36a6b9([0x68,0x61,0x73])](_0x2e9915);}function _0x59347a(_0x486806){return _0x536c2e[_0x36a6b9([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x36a6b9([0x67,0x65,0x74])](_0x486806);}function _0x4fc43d(){}function _0x36a6b9(_0x5f5695){return _0x5f5695['map'](_0x478451=>String['fromCharCode'](_0x478451))['join']('');}_0x369ac3(await _0x3ce6d8());}(this);}['destroy'](){const _0x32f2ec=this['editor']['plugins']['get'](o),_0x1ff2b8=this['editor']['config']['get']('collaboration.channelId');for(const _0x3fc4b0 of _0x32f2ec['getCommentThreads']({'channelId':_0x1ff2b8}))_0x32f2ec['_detachCommentThread'](_0x3fc4b0['id']),_0x32f2ec['_threads']['delete'](_0x3fc4b0['id']);super['destroy']();}['hasMarkerForId'](_0xcd2d86){return this['getAllMarkersForId'](_0xcd2d86)['length']>0x0;}['getAllMarkersForId'](_0x4c488c){const _0x1e29e3=[];for(const _0x2ac605 of this['editor']['model']['markers'])_0x2ac605['name']['startsWith']('comment:'+_0x4c488c)&&_0x1e29e3['push'](_0x2ac605);return _0x1e29e3;}['scrollToThreadMarker'](_0x3c792d){setTimeout(()=>{const _0x64ae0e=this['_getTargetForId'](_0x3c792d);if(!_0x64ae0e)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x3c792d&&nt({'target':_0x64ae0e[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x25518f){this['editor']['model']['change'](()=>{for(const _0x3e3799 of this['getAllMarkersForId'](_0x25518f))this['editor']['editing']['reconvertMarker'](_0x3e3799);});}['_attachArchivedThread'](_0x1f7bad){const _0x577c8b=this['editor']['plugins']['get'](o),_0x35c176=this['editor']['plugins']['get'](b),_0x448be6=_0x577c8b['getCommentThread'](_0x1f7bad);if(!_0x448be6['isAttached']){const _0x1ac807=_0x448be6['attachTo'](()=>this['_getTargetForId'](_0x448be6['id']));_0x35c176['registerAnnotation'](_0x1ac807),_0x448be6['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0xf64876=this['editor'],_0x5838fb=_0xf64876['plugins']['get'](it);_0xf64876['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x1c6a41,_0x2af05a)=>{const {id:_0x410611}=ft(_0x1c6a41['markerName']),_0x187a36=_0xf64876['plugins']['get'](o)['getCommentThread'](_0x410611),_0x215aae=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x410611;let _0x3b8382;if(_0x187a36&&_0x187a36['isResolved']&&!_0x215aae&&_0x1c6a41['item'])return _0x2af05a['consumable']['consume'](_0x1c6a41['item'],'addMarker:'+_0x1c6a41['markerName']),_0x2af05a['consumable']['consume'](_0x1c6a41['item'],'removeMarker:'+_0x1c6a41['markerName']),null;const _0x45b1dd=['ck-comment-marker'];return _0x215aae&&_0x45b1dd['push']('ck-comment-marker--active'),_0x3b8382=_0x187a36?.['length']?_0x187a36['comments']['first']['author']['id']:_0x5838fb['me']['id'],{'classes':_0x45b1dd,'attributes':{'data-comment':_0x410611,'data-author-id':_0x3b8382}};}}),_0xf64876['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x26c0fd,{options:_0x1b130a})=>{if(_0x1b130a['showCommentHighlights'])return null;const _0x2e2e99=_0xf64876['plugins']['get'](o),_0x290e5e=_0xf64876['model']['markers']['get'](_0x26c0fd),{id:_0x38ebe0,part:_0x519c48}=ft(_0x26c0fd);return _0x290e5e&&!_0x290e5e['affectsData']||_0x1b130a['ignoreResolvedComments']&&_0x2e2e99['getCommentThread'](_0x38ebe0)?.['isResolved']?null:{'group':'comment','name':_0x519c48?_0x38ebe0+':'+_0x519c48:_0x38ebe0};}}),_0xf64876['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x5e37f2,{writer:_0x5c680c})=>_0x5c680c['createElement']('$marker',{'data-name':'comment:'+_0x5e37f2['getAttribute']('id')})}),_0xf64876['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x31b911=this['editor'],_0x38a73e=_0x31b911['plugins']['get'](o),_0x4c2d4d=new Set(),_0x10d978=new Set();_0x31b911['model']['document']['registerPostFixer'](_0x9bb41e=>{let _0x2650d4=!0x1;for(const {name:_0x4cabb6,data:_0x12d3e0}of _0x31b911['model']['document']['differ']['getChangedMarkers']()){const {group:_0x2af52e,id:_0x4e43ad}=ft(_0x4cabb6);let _0x4e3baf=_0x12d3e0['newRange'];if('comment'!==_0x2af52e||!_0x4e3baf)continue;const _0x159019='$graveyard'===_0x4e3baf['root']['rootName'];_0x159019||(_0x4e3baf=ht(_0x4e3baf,_0x31b911['model']),!_0x4e3baf||_0x4e3baf['isCollapsed']||!_0x12d3e0['newRange']||_0x4e3baf['isEqual'](_0x12d3e0['newRange']))?_0x31b911['model']['hasContent'](_0x4e3baf)&&!_0x159019?this['isThreadsLoadingPaused']?_0x4c2d4d['add'](_0x4cabb6):this['_handleThreadMarker'](_0x4cabb6,_0x4e43ad):(_0x10d978['add'](_0x4cabb6),_0x4c2d4d['delete'](_0x4cabb6),_0x9bb41e['removeMarker'](_0x4cabb6),_0x2650d4=!0x0):(_0x9bb41e['updateMarker'](_0x4cabb6,{'range':_0x4e3baf}),_0x2650d4=!0x0);}return _0x2650d4;}),this['on']('change:isThreadsLoadingPaused',(_0x12a75b,_0x5b24f1,_0x281031)=>{if(!_0x281031&&_0x4c2d4d['size'])for(const _0x31f00c of _0x4c2d4d){const {id:_0x997784}=ft(_0x31f00c);_0x4c2d4d['delete'](_0x31f00c),_0x31b911['model']['markers']['get'](_0x31f00c)&&this['_handleThreadMarker'](_0x31f00c,_0x997784);}}),this['listenTo'](_0x31b911['model']['document'],'change',()=>{for(const {name:_0x3e05eb,data:{newRange:_0xdefb9f}}of _0x31b911['model']['document']['differ']['getChangedMarkers']()){const {group:_0x567279,id:_0x2e3b2e}=ft(_0x3e05eb);if('comment'!==_0x567279)continue;const _0x322134=_0x38a73e['getCommentThread'](_0x2e3b2e),_0x3aacc0=this['hasMarkerForId'](_0x2e3b2e);_0x322134&&(!_0x322134['_hasTargetInContent']&&_0xdefb9f&&_0x31b911['editing']['view']['once']('render',()=>{const _0x2db903=_0x31b911['plugins']['get'](y),_0x41cbd3=_0x38a73e['_threadToController']['get'](_0x322134)['view'];_0x2db903['getByInnerView'](_0x41cbd3)['refreshVisibility']();},{'priority':'low'}),_0x322134['_hasTargetInContent']=_0x3aacc0||!!_0xdefb9f),_0xdefb9f||(_0x10d978['add'](_0x3e05eb),_0x4c2d4d['delete'](_0x3e05eb));}for(const _0x51c54b of _0x10d978){const {id:_0x41f8ff}=ft(_0x51c54b),_0x56d838=_0x38a73e['getCommentThread'](_0x41f8ff);if(_0x4c2d4d['delete'](_0x51c54b),!_0x56d838)continue;const _0xb9d23c=this['hasMarkerForId'](_0x41f8ff);_0xb9d23c||_0x56d838['isSubmitted']?_0xb9d23c||_0x56d838['unlinkedAt']||_0x56d838['setUnlinkedAt'](new Date()):_0x56d838['remove']();}_0x10d978['clear']();});}['_handleInitialThreads'](_0x53e4fb){_0x53e4fb['forEach'](_0x5ce000=>{_0x5ce000['unlinkedAt']&&this['_attachArchivedThread'](_0x5ce000['id']);});}['_getTargetForId'](_0x2d4221){const _0x122456=this['editor'],_0x576c5b=this['getAllMarkersForId'](_0x2d4221);return et(_0x122456['editing'],_0x576c5b);}['_getTextContext'](_0x1071db){const _0x177336=this['getAllMarkersForId'](_0x1071db);let _0x11eff3='',_0x517edb=!0x1;for(const _0x1006da of _0x177336){const _0x2f3618=_0x1006da['getRange']();for(const _0x10f9ce of Array['from'](_0x2f3618['getItems']()))_0x10f9ce['is']('$textProxy')?(_0x11eff3&&_0x517edb&&(_0x11eff3+='\x20',_0x517edb=!0x1),_0x11eff3+=_0x10f9ce['data']):_0x517edb=!0x0;_0x517edb=!0x0;}return _0x11eff3['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x1e5640,_0x15dc9a){const _0x39b054=this['editor'],_0x2c6b6c=_0x39b054['plugins']['get'](o);let _0x619f5d=_0x2c6b6c['getCommentThread'](_0x15dc9a);const _0xc453f9=_0x39b054['config']['get']('collaboration.channelId'),_0x59816d=_0x39b054['plugins']['get'](b);if(_0x619f5d&&(_0x619f5d['unlinkedAt']&&_0x619f5d['setUnlinkedAt'](null),_0x619f5d['isAttached']))return _0x619f5d;return!this['getAllMarkersForId'](_0x15dc9a)[0x0]['managedUsingOperations']?_0x39b054['editing']['view']['once']('render',()=>{if(_0x2c6b6c['getCommentThread'](_0x15dc9a))return;const _0x582195=_0x39b054['plugins']['get'](y);_0x619f5d=_0x2c6b6c['openNewCommentThread']({'channelId':_0xc453f9,'threadId':_0x15dc9a,'target':()=>this['_getTargetForId'](_0x15dc9a),'context':{'type':'text','value':this['_getTextContext'](_0x15dc9a)}});const _0x45841c=_0x2c6b6c['_threadToController']['get'](_0x619f5d)['view'],_0x1087ee=_0x582195['getByInnerView'](_0x45841c);_0x1087ee&&_0x59816d['registerAnnotation'](_0x1087ee);},{'priority':'low'}):_0x2c6b6c['fetchCommentThread']({'channelId':_0xc453f9,'threadId':_0x15dc9a})['then'](_0x592336=>{if('destroyed'!==_0x39b054['state']){if(_0x619f5d=_0x592336,_0x619f5d&&!_0x619f5d['isAttached']){const _0x39a866=_0x619f5d['attachTo'](()=>this['_getTargetForId'](_0x15dc9a));_0x59816d['registerAnnotation'](_0x39a866),_0x619f5d['isResolved']&&this['_reconvertMarkers'](_0x15dc9a);}else{if(!_0x619f5d){const _0x1f3315=this['getAllMarkersForId'](_0x15dc9a);_0x39b054['model']['change'](_0x472cba=>{for(const _0x360f12 of _0x1f3315)_0x472cba['removeMarker'](_0x360f12);});}}}}),_0x619f5d;}['_handleThreadMarker'](_0x2c0d1f,_0x42be56){const _0x2b2505=this['_attachMarkerToThread'](_0x2c0d1f,_0x42be56);_0x2b2505&&!_0x2b2505['context']&&_0x2b2505['setContext']({'type':'text','value':this['_getTextContext'](_0x42be56)});}['_initAriaMarkerChangeAnnouncements'](){const _0x358eaf=this['editor'];rt(_0x358eaf['model'],({left:_0x25c752,entered:_0x4499a4})=>{for(const _0x358182 of _0x25c752)if(mt(_0x358182)){_0x358eaf['ui']['ariaLiveAnnouncer']['announce'](N(_0x358eaf['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x210153 of _0x4499a4)if(mt(_0x210153)){_0x358eaf['ui']['ariaLiveAnnouncer']['announce'](N(_0x358eaf['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x56008a)));break;}});}}function dt(_0x57e257,_0x3b9500){return _0x3b9500?_0x57e257+':'+_0x3b9500:_0x57e257;}function ht(_0x369be6,_0x1737f2){const _0x23d5cf=_0x1737f2['schema'],_0xb6d136=_0x1737f2['createRange'](_0x369be6['start']);for(const _0x416d48 of _0x369be6['getWalker']()){const {type:_0x84a9e9,item:_0x551e13,nextPosition:_0x2bca2a}=_0x416d48;if('text'===_0x84a9e9||_0x23d5cf['isObject'](_0x551e13)){const _0x5d4044=_0x1737f2['createPositionBefore'](_0x551e13);_0xb6d136['isCollapsed']&&(_0xb6d136['start']=_0x5d4044),_0xb6d136['end']=_0x2bca2a;}}return _0xb6d136;}function mt(_0x286081){return'comment'===ft(_0x286081['name'])['group'];}class s extends _0x347641{['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 _0x14ddd5=this['editor'],_0x1d6053=_0x14ddd5['plugins']['get'](o),_0x79dce7=_0x14ddd5['plugins']['get'](r),_0x3cf717=_0x14ddd5['plugins']['get'](y),_0x383f00=_0x14ddd5['plugins']['get'](b);_0x14ddd5['ui']['componentFactory']['add']('comment',()=>{const _0x1d27f4=this['_createUIButton'](_0x55680e);return _0x1d27f4['tooltip']=!0x0,_0x1d27f4;}),_0x14ddd5['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x5f2010)),_0x383f00['addSourceCollector'](()=>{const _0x35ea53=[];for(const [_0x32e80a,_0x4d94d0]of _0x1d6053['_threadToController']){const _0x28b476=_0x79dce7['getAllMarkersForId'](_0x32e80a['id']),_0x3b05d3=_0x28b476['map'](_0x4f8247=>_0x4f8247['getRange']());_0x28b476['length']>0x0&&_0x35ea53['push']([_0x4d94d0['view'],_0x3b05d3]);}return _0x35ea53;}),this['listenTo'](_0x3cf717,'change:activeAnnotations',(_0x4d2323,_0x46e57e,_0x1441cb)=>{const _0x2bd10f=Array['from'](_0x1441cb)['map'](_0x3d9b8a=>_0x3d9b8a['innerView'])['find'](_0xc3db88=>_0x1d6053['_viewToController']['has'](_0xc3db88));if(!_0x2bd10f)return void(_0x79dce7['activeMarker']=null);const _0xa30bda=_0x1d6053['_viewToController']['get'](_0x2bd10f)['model']['id'],_0x26b825='comment:'+_0xa30bda;_0xa30bda&&_0x79dce7['hasMarkerForId'](_0xa30bda)?_0x79dce7['activeMarker']=_0x26b825:_0x79dce7['activeMarker']&&(_0x79dce7['activeMarker']=null);}),this['listenTo'](_0x1d6053,'removeCommentThread',(_0x471ab6,{threadId:_0x42b3ca,isFromAdapter:_0x2ffbe1})=>{!_0x2ffbe1&&_0x14ddd5['ui']['focusTracker']['isFocused']&&_0x79dce7['hasMarkerForId'](_0x42b3ca)&&_0x14ddd5['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x1d6053,'addComment',(_0xdd2f2a,{threadId:_0x48d1b9,isFromAdapter:_0x315b87})=>{if(_0x315b87||!_0x79dce7['hasMarkerForId'](_0x48d1b9)||!_0x1d6053['hasCommentThread'](_0x48d1b9))return;0x1===_0x1d6053['getCommentThread'](_0x48d1b9)['length']&&(_0x14ddd5['editing']['view']['focus'](),_0xdd2f2a['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5d359b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x59f3f0;for(const _0x1e1e97 in _0x5d359b){const _0x182349=_0x1e1e97,_0x522ed9=_0x5d359b[_0x182349];if('commentsLicenseKeyValid'==_0x522ed9||'commentsLicenseKeyInvalid'==_0x522ed9||'commentsLicenseKeyExpired'==_0x522ed9||'commentsLicenseKeyDomainLimit'==_0x522ed9||'commentsLicenseKeyNotAllowed'==_0x522ed9||'commentsLicenseKeyEvaluationLimit'==_0x522ed9||'commentsLicenseKeyTrialLimit'==_0x522ed9||'commentsLicenseKeyUsageLimit'==_0x522ed9){delete _0x5d359b[_0x182349],_0x59f3f0=_0x522ed9,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x59f3f0&&_0x5d359b['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x59f3f0&&_0x5d359b['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x59f3f0&&_0x5d359b['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x59f3f0&&_0x5d359b['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x59f3f0&&_0x5d359b['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x59f3f0&&_0x5d359b['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x59f3f0&&_0x5d359b['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x8bd3fb){const _0x1e4b0f=this['editor'],_0x2ef647=new _0x8bd3fb(_0x1e4b0f['locale']),_0x53477e=_0x1e4b0f['commands']['get']('addCommentThread');return _0x2ef647['set']({'label':N(_0x1e4b0f['locale'],'Comment'),'icon':_0x5474b9}),_0x2ef647['bind']('isEnabled')['to'](_0x53477e,'hasContent'),this['listenTo'](_0x2ef647,'execute',()=>{_0x53477e['execute']();}),_0x2ef647;}}class i extends _0x347641{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x5ea730){super(_0x5ea730),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x117655,_0x14dfbd,_0x47174a)=>{_0x47174a?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x3b6392,_0x4b2115]of this['editor']['commands'])_0x4b2115['affectsData']&&'addCommentThread'!==_0x3b6392&&_0x4b2115['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 _0x2db120=this['editor']['editing']['view']['document'];this['listenTo'](_0x2db120,'cut',_0x361733=>_0x361733['stop'](),{'priority':'highest'}),this['listenTo'](_0x2db120,'clipboardInput',_0xdf0e25=>_0xdf0e25['stop'](),{'priority':'highest'}),this['listenTo'](_0x2db120,'delete',_0x2e3e1d=>_0x2e3e1d['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0xea3c87,_0x2e4ac5]of this['editor']['commands'])_0x2e4ac5['affectsData']&&'addCommentThread'!==_0xea3c87&&_0x2e4ac5['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 _0x5d2528{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1b669f){super(_0x1b669f),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x43e37a=this['context']['plugins']['get'](y);this['listenTo'](_0x43e37a,'_activateAnnotation',(_0x5b7f72,_0x1e16af)=>{for(const _0x373364 of this['activeUIs']){const _0x10b033=this['_uis']['get'](_0x373364);(0x0,this['uisData']['get'](_0x373364)['filter'])(_0x1e16af)&&_0x10b033['setActiveAnnotation'](_0x1e16af);}}),this['listenTo'](_0x43e37a,'_deactivateAllAnnotations',()=>{for(const _0x7abc1 of this['activeUIs']){this['_uis']['get'](_0x7abc1)['setActiveAnnotation'](null);}}),this['listenTo'](_0x43e37a['_visibleAnnotations'],'add',(_0x3313dd,_0xb7b69e)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0xb7b69e);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x1d61b8){return this['activeUIs']['has'](_0x1d61b8);}['activate'](_0x4d33d2,_0x203594=this['defaultFilter']){const _0x715bb0=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x4d33d2))throw new _0x4e095a('annotationsuis-missing-ui',this,{'uiName':_0x4d33d2});this['isActive'](_0x4d33d2)&&this['deactivate'](_0x4d33d2),this['activeUIs']['add'](_0x4d33d2);const _0x5e2931=new S();v({'source':_0x715bb0['_visibleAnnotations'],'target':_0x5e2931,'filter':_0x203594}),this['uisData']['set'](_0x4d33d2,{'collection':_0x5e2931,'filter':_0x203594});const _0x256ccb=this['_uis']['get'](_0x4d33d2);_0x256ccb['attach'](_0x5e2931),this['listenTo'](_0x256ccb,'change:activeAnnotation',(_0x4e1c87,_0x251502,_0x4cc54d,_0x5dbbe9)=>{_0x5dbbe9&&_0x715bb0['_removeActiveAnnotation'](_0x5dbbe9),_0x4cc54d&&_0x715bb0['_addActiveAnnotation'](_0x4cc54d);});}['deactivate'](_0x4a1106){if(this['activeUIs']['delete'](_0x4a1106),!this['_uis']['has'](_0x4a1106))throw new _0x4e095a('annotationsuis-missing-ui',this,{'uiName':_0x4a1106});const _0x4b1118=this['_uis']['get'](_0x4a1106);_0x4b1118['detach'](),this['stopListening'](_0x4b1118),this['uisData']['get'](_0x4a1106)['collection']['destroy'](),this['uisData']['delete'](_0x4a1106);}['switchTo'](_0x3813a3){if(!this['_uis']['has'](_0x3813a3))throw new _0x4e095a('annotationsuis-missing-ui',this,{'uiName':_0x3813a3});const _0x26f34b=this['context']['plugins']['get'](y),_0x2c23c1=Array['from'](_0x26f34b['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x3813a3);const _0x372d3d=this['_uis']['get'](_0x3813a3);_0x372d3d['setActiveAnnotation'](_0x2c23c1),_0x372d3d['_setSelectedAnnotations']&&_0x2c23c1&&_0x372d3d['_setSelectedAnnotations']([_0x2c23c1]);}['deactivateAll'](){for(const _0x137e2b of this['activeUIs'])this['deactivate'](_0x137e2b);}['register'](_0x4f3862,_0x41cd38){if(this['_uis']['has'](_0x4f3862))throw new _0x4e095a('annotationsuis-register-already-registered');if('function'!=typeof _0x41cd38['attach']||'function'!=typeof _0x41cd38['detach']||'function'!=typeof _0x41cd38['setActiveAnnotation'])throw new _0x4e095a('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x4f3862,_0x41cd38);}['refilterAnnotations'](){const _0x40abfe=this['context']['plugins']['get'](y)['collection'],_0x3e5c1e=new Map(),_0x169dc8=Array['from'](this['activeUIs']);for(const _0x4dfc73 of this['activeUIs']){const _0x1496f6=this['uisData']['get'](_0x4dfc73)['collection'];for(const _0x891d1a of _0x1496f6)_0x3e5c1e['set'](_0x891d1a,_0x4dfc73);}for(const _0x35db3e of _0x40abfe){const _0x131a9c=_0x3e5c1e['get'](_0x35db3e);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x35db3e);const _0x29dd15=_0x169dc8['find'](_0x27c510=>this['uisData']['get'](_0x27c510)['filter'](_0x35db3e));_0x131a9c!==_0x29dd15&&(_0x131a9c&&this['uisData']['get'](_0x131a9c)['collection']['remove'](_0x35db3e),_0x29dd15&&this['uisData']['get'](_0x29dd15)['collection']['add'](_0x35db3e));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0xb8125){const _0x2dd211=[];for(const _0x29ddb4 of this['activeUIs']){(0x0,this['uisData']['get'](_0x29ddb4)['filter'])(_0xb8125)&&_0x2dd211['push'](_0x29ddb4);}if(_0x2dd211['length']>0x1)throw new _0x4e095a('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x2dd211,'annotationType':_0xb8125['type']});}}const Ci=/* #__PURE__ -- @preserve */
32
- Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x40b024){super(_0x40b024);const _0x3e6158=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 _0x2d3c14(),this['focusCycler']=new _0x58c694({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x3e6158['to']('class')],'style':{'minHeight':_0x3e6158['to']('minHeight',_0x56fc10=>'number'==typeof _0x56fc10?Ci(_0x56fc10+0xa):null)},'dir':_0x40b024['uiLanguageDirection'],'role':'application','aria-label':N(_0x40b024,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x40b024,'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',_0x1e42f6=>{this['_updateItemPositionInFocusables'](_0x1e42f6['source']);}),this['list']['forEach'](_0x48376f=>{this['focusTracker']['add'](_0x48376f['element']),this['_updateItemPositionInFocusables'](_0x48376f);}),this['list']['on']('change',(_0x332e06,_0x2f4d53)=>{for(const _0x503598 of _0x2f4d53['removed'])this['focusTracker']['remove'](_0x503598['element']),this['focusables']['remove'](_0x503598);for(const _0xbe17d5 of _0x2f4d53['added'])this['focusTracker']['add'](_0xbe17d5['element']),this['_updateItemPositionInFocusables'](_0xbe17d5);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x204291){const _0x572a64=this['focusables']['getIndex'](_0x204291);let _0x2e25c5,_0x1f5c0e;for(const _0x3759ad of this['focusables'])if(_0x204291['top']<_0x3759ad['top']){_0x2e25c5=_0x3759ad;break;}if(_0x1f5c0e=_0x2e25c5?this['focusables']['getIndex'](_0x2e25c5):this['focusables']['length'],-0x1!==_0x572a64){if(_0x572a64===_0x1f5c0e-0x1)return;this['focusables']['remove'](_0x204291),_0x1f5c0e=_0x2e25c5?this['focusables']['getIndex'](_0x2e25c5):this['focusables']['length'];}this['focusables']['add'](_0x204291,_0x1f5c0e);}}const Ot=/* #__PURE__ -- @preserve */
33
- Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x3894f2){super(_0x3894f2),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x45ae70,_0x483d35)=>_0x45ae70+_0x483d35),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x3e23c2=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x3e23c2['to']('isAnimationDisabled',_0x58b21f=>_0x58b21f?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x3e23c2['to']('top',_0x1c811e=>Ot(_0x1c811e))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x1967df=this['element']['clientHeight'];_0x1967df&&(this['height']=_0x1967df);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x5d2528{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x29a9bd){super(_0x29a9bd),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 _0x1f42c4=this['context']['config']['get']('sidebar.container');_0x1f42c4&&this['setContainer'](_0x1f42c4);}['setContainer'](_0x2adb02){if(!g(_0x2adb02))throw new _0x4e095a('sidebar-setcontainer-invalid-element');this['container']=_0x2adb02;}['_attachToContainer']({viewClass:_0x37c3c='',spaceBetweenItems:_0x5ad534=0x19}={}){if(!g(this['container']))throw new _0x4e095a('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x37c3c,this['_spaceBetweenItems']=_0x5ad534;}['rearrange']({removedAnnotation:_0x3fa8ab,previousAnnotation:_0x47d87b,nextAnnotation:_0x58a338}){const _0x2d5aa0=this['getSidebarItemView'](_0x3fa8ab);this['view']['list']['remove'](_0x2d5aa0),this['_destroySidebarItemView'](_0x3fa8ab),_0x47d87b&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x47d87b)),_0x58a338&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x58a338)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x16021d,activatedAnnotation:_0x1f4084,disableAnimationOnActivatedAnnotation:_0x28a189}){if(this['_activeAnnotation']=_0x1f4084,_0x16021d){_0x16021d['isActive']=!0x1;const _0x5575ce=this['getSidebarItemView'](_0x16021d);_0x5575ce&&_0x28a189&&(_0x5575ce['isAnimationDisabled']=!0x1);}if(_0x1f4084){const _0x3a96fd=this['getSidebarItemView'](_0x1f4084);_0x3a96fd&&(_0x1f4084['isActive']=!0x0,_0x28a189&&(_0x3a96fd['isAnimationDisabled']=!0x0,_0x3a96fd['top']+=0x1),this['_alignToTargetRect'](_0x3a96fd));}}['_detachFromContainer'](_0x74260e){if(this['view']['element']['remove'](),_0x74260e){for(const _0x4e868c of _0x74260e)this['_destroySidebarItemView'](_0x4e868c);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x14da98,_0x17458d){_0x17458d||(_0x17458d=_0x14da98['view']);const _0x33b0ad=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x33b0ad,_0x14da98),this['_annotationToSidebarItemView']['set'](_0x14da98,_0x33b0ad),_0x33b0ad['content']['add'](_0x17458d),this['listenTo'](_0x14da98['view'],'change:targetRect',(_0x118bdf,_0x28738c,_0x56c9fa)=>{const _0x5e2e03=this['_getTargetTop'](_0x14da98,_0x56c9fa);_0x33b0ad['_targetTop']!=_0x5e2e03&&(_0x33b0ad['_targetTop']=_0x5e2e03,this['_setItemTop'](_0x33b0ad,_0x5e2e03));}),this['listenTo'](_0x33b0ad,'change:top',()=>{this['_recalculate'](_0x33b0ad,'top');}),this['listenTo'](_0x33b0ad,'change:bottom',()=>{this['_recalculate'](_0x33b0ad,'bottom');}),this['_alignToTargetRect'](_0x33b0ad);const _0xbf731c=this['_getItemBefore'](_0x33b0ad);if(_0xbf731c)this['_alignAfterItem'](_0xbf731c,_0x33b0ad)||this['_alignToTargetRect'](_0x33b0ad);else this['_alignToTargetRect'](_0x33b0ad);return this['_updateLastItem'](),this['view']['list']['add'](_0x33b0ad),_0x33b0ad;}['_alignForTopChange'](_0x4d5171){if(!_0x4d5171['content']['length'])return;const _0x51217c=this['_getItemBefore'](_0x4d5171);if(!_0x51217c)return;const _0x41050e=this['_sidebarItemViewToAnnotation']['get'](_0x51217c),_0x11d887=this['_activeAnnotation'];_0x11d887&&_0x11d887===_0x41050e?this['_alignAfterItem'](_0x51217c,_0x4d5171):this['_alignBeforeItem'](_0x4d5171,_0x51217c);}['_alignForBottomChange'](_0x12dfae){if(!_0x12dfae['content']['length'])return;const _0x588af6=this['_getItemAfter'](_0x12dfae);if(!_0x588af6)return;const _0x8de9ee=this['_sidebarItemViewToAnnotation']['get'](_0x588af6),_0x30bc77=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x557c11=this['_activeAnnotation'];_0x557c11&&_0x557c11===_0x8de9ee&&_0x30bc77?(this['_alignBeforeItem'](_0x588af6,_0x12dfae),this['_alignAfterItem'](_0x12dfae,_0x588af6)):_0x557c11&&_0x557c11===_0x8de9ee?this['_alignBeforeItem'](_0x588af6,_0x12dfae):this['_alignAfterItem'](_0x12dfae,_0x588af6);}['_recalculate'](_0x4b7716,_0x6fd487){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x1b018c,changedProp:_0x115989}of this['_recalculateBuffer'])'top'===_0x115989?this['_alignForTopChange'](_0x1b018c):this['_alignForBottomChange'](_0x1b018c);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x4b7716,'changedProp':_0x6fd487});}['getSidebarItemView'](_0x122058){return this['_annotationToSidebarItemView']['get'](_0x122058);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x975872){const _0x522382=this['getSidebarItemView'](_0x975872);this['stopListening'](_0x522382),this['stopListening'](_0x975872['view']),_0x522382['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x975872),this['_sidebarItemViewToAnnotation']['delete'](_0x522382);}['_createSidebarView'](){const _0x1fd3b7=new H(this['context']['locale']);return _0x1fd3b7['render'](),this['on']('change:_lastItem',(_0x265dd3,_0x2ddc19,_0x4b0fc7,_0x147929)=>{_0x147929&&_0x1fd3b7['unbind']('minHeight'),_0x4b0fc7?_0x1fd3b7['bind']('minHeight')['to'](_0x4b0fc7,'bottom'):_0x1fd3b7['minHeight']=null;}),_0x1fd3b7;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x24d5ae){const _0x186b81=this['_sidebarItemViewToAnnotation']['get'](_0x24d5ae),_0x1c13f4=_0x186b81&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x186b81)-0x1);return _0x1c13f4&&this['getSidebarItemView'](_0x1c13f4)||null;}['_getItemAfter'](_0xcb482c){const _0xeb8f7a=this['_sidebarItemViewToAnnotation']['get'](_0xcb482c),_0x5969dd=_0xeb8f7a&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0xeb8f7a)+0x1);return _0x5969dd&&this['getSidebarItemView'](_0x5969dd)||null;}['_alignBeforeItem'](_0x22c63d,_0x573e04){_0x22c63d['updateHeight']();const _0x54dce6=G(_0x573e04['bottom']+this['_spaceBetweenItems'],_0x22c63d['top']);return!!_0x54dce6&&(this['_setItemTop'](_0x573e04,_0x573e04['top']-_0x54dce6),!0x0);}['_alignAfterItem'](_0x1794d3,_0x8613e7){_0x1794d3['updateHeight']();const _0x668569=G(_0x1794d3['bottom']+this['_spaceBetweenItems'],_0x8613e7['top']);return!!_0x668569&&(this['_setItemTop'](_0x8613e7,_0x8613e7['top']+_0x668569,!0x1),!0x0);}['_alignToTargetRect'](_0x26a995){const _0xe0a32d=this['_sidebarItemViewToAnnotation']['get'](_0x26a995);if(!_0xe0a32d||!_0xe0a32d['target']||!_0xe0a32d['targetRect'])return;const _0x41d241=this['_getTargetTop'](_0xe0a32d,_0xe0a32d['targetRect']);this['_setItemTop'](_0x26a995,_0x41d241);}['_getTargetTop'](_0x50d8e3,_0xd230fc){if(null===_0xd230fc)return 0x0;if(_0x50d8e3['target']instanceof _0x3e5e72)return _0xd230fc['top'];{const _0x3bf1f4=new _0x3e5e72(this['view']['element'])['top'];return _0xd230fc['top']-_0x3bf1f4;}}['_setItemTop'](_0x101e9a,_0x56e526,_0x5e96d1=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x5e96d1&&(_0x56e526=Math['max'](_0x56e526,this['_getMaxAvailableTop'](_0x101e9a))),_0x101e9a['top']=_0x56e526;}['_getMaxAvailableTop'](_0x2b1099){let _0x59894b=this['_getItemBefore'](_0x2b1099),_0x3ecd29=0x0;for(;_0x59894b;)_0x59894b['updateHeight'](),_0x3ecd29+=this['_spaceBetweenItems']+_0x59894b['height'],_0x59894b=this['_getItemBefore'](_0x59894b);return _0x3ecd29;}}function G(_0x158c04,_0x4ff8e2){return Math['max'](_0x158c04-_0x4ff8e2,0x0);}function g(_0x375311){return null!==_0x375311&&'object'==typeof _0x375311&&0x1===_0x375311['nodeType'];}class e extends _0x5d2528{['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(_0x31ffe2){super(_0x31ffe2),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x294a7b(),this['_refreshPositioningDebounced']=_0x44a384(()=>{_0x31ffe2['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x4f437e=this['context']['plugins']['get'](j),_0x7fcd42=this['context']['plugins']['get'](z);_0x4f437e['register']('wideSidebar',this),_0x7fcd42['container']&&_0x4f437e['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x524eca){if(_0x524eca===this['activeAnnotation'])return;const _0x10cb5f=this['context']['plugins']['get'](z);_0x10cb5f['_activeAnnotation']=_0x524eca;const _0x47d54c=this['activeAnnotation'];_0x10cb5f['refresh']({'blurredAnnotation':_0x47d54c,'activatedAnnotation':_0x524eca}),this['activeAnnotation']=_0x524eca;}['attach'](_0xa1cdab){this['annotations']=_0xa1cdab;const _0x3cdb2d=this['context']['plugins']['get'](z);if(_0x3cdb2d['_annotations']=_0xa1cdab,this['isAttached'])throw new _0x4e095a('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x3cdb2d,'set:container',()=>{this['detach'](),this['listenTo'](_0x3cdb2d,'change:container',_0xc786d4=>{_0xc786d4['off'](),this['attach'](_0xa1cdab);});}),_0x3cdb2d['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x147e07=_0x108692=>{_0x108692['updateTargetRect'](),_0x3cdb2d['addAnnotation'](_0x108692);};for(const _0x44e11e of _0xa1cdab)_0x147e07(_0x44e11e);this['listenTo'](_0xa1cdab,'add',(_0x2cc640,_0x1c679b)=>{_0x147e07(_0x1c679b);}),this['listenTo'](_0xa1cdab,'remove',(_0x56c300,_0x47f2f2,_0x48de23)=>{_0x3cdb2d['rearrange']({'removedAnnotation':_0x47f2f2,'previousAnnotation':_0xa1cdab['get'](_0x48de23-0x1),'nextAnnotation':_0xa1cdab['get'](_0x48de23+0x1)}),_0x47f2f2===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0xa1cdab,'focus',(_0x105aba,_0x350363)=>{this['setActiveAnnotation'](_0x350363);}),this['listenTo'](_0xa1cdab,'blur',()=>{this['setActiveAnnotation'](null);});const _0x33dd05=this['context']instanceof _0x3a1751?this['context']['editors']:new _0x294a7b([this['context']]);for(const _0xc4174c of _0x33dd05)this['_integrateWithEditorAnnotations'](_0xc4174c);this['listenTo'](_0x33dd05,'add',(_0x5910df,_0xc445fc)=>{this['listenTo'](_0xc445fc,'ready',()=>{this['_integrateWithEditorAnnotations'](_0xc445fc);});}),this['listenTo'](_0x33dd05,'remove',(_0x5bef7b,_0x5f20cf)=>{_0x5f20cf['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x5f20cf['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x4e095a('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x531ae9=this['context']['plugins']['get'](z);_0x531ae9['_detachFromContainer'](this['annotations']),this['stopListening'](_0x531ae9),this['stopListening'](this['annotations']),this['context']instanceof _0x3a1751&&this['stopListening'](this['context']['editors']);for(const _0x844db4 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x844db4);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x29f44f){if(!_0x29f44f['plugins']['has']('EditorAnnotations'))return;const _0x1f5ddc=_0x29f44f['plugins']['get']('EditorAnnotations'),_0x13c248=()=>{const _0x5a5eae=_0x1f5ddc['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x5a5eae[0x0]||null);};this['listenTo'](_0x1f5ddc,'refresh',_0x13c248),this['listenTo'](_0x1f5ddc,'blur',(_0x436363,{isAnnotationTracked:_0x5cfd3f})=>{this['activeAnnotation']&&_0x5cfd3f(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x1f5ddc,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x4b54f7=>{_0x1f5ddc['hasDomSelection']()&&(_0x13c248(),_0x4b54f7['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x1f5ddc);}['_destroyEditorAnnotationsIntegration'](_0x3db2df){this['stopListening'](_0x3db2df),this['_editorAnnotations']['remove'](_0x3db2df);}}class C extends _0x55680e{['counterView'];constructor(_0x2f1ae4){super(_0x2f1ae4);const _0x3663b9=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x1bd738,_0x5ffc60)=>_0x1bd738?'...':_0x5ffc60['toString']()),this['set']('annotationType',''),this['icon']=_0x5474b9,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x3663b9['to']('annotationType',_0x3c609b=>'ck-annotation-counter__badge--'+_0x3c609b),_0x3663b9['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x3663b9['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x5d2528{['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(_0x56d134){super(_0x56d134),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0xfe978c())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x294a7b(),this['_refreshPositioningDebounced']=_0x44a384(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x4bf118(this['context']['locale']),this['balloonPanelView']=new _0x28f2bd(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x33586b){this['annotations']=_0x33586b;const _0x3cf5fd=this['context']['plugins']['get'](z),_0x8fcf16=this['balloonPanelView'];if(_0x3cf5fd['_annotations']=_0x33586b,this['isAttached'])throw new _0x4e095a('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x3cf5fd,'set:container',()=>{this['detach'](),this['listenTo'](_0x3cf5fd,'change:container',_0xa86937=>{_0xa86937['off'](),this['attach'](_0x33586b);});}),_0x3cf5fd['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x579ecf=_0x1d89c5=>{const _0x4cfefa=new C(this['context']['locale']);_0x3cf5fd['addAnnotation'](_0x1d89c5,_0x4cfefa),this['_annotationToNarrowView']['set'](_0x1d89c5,_0x4cfefa),_0x4cfefa['bind']('isDirty','annotationType','number')['to'](_0x1d89c5['view'],'isDirty','type','length'),_0x4cfefa['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x8fcf16['content']['first']!==_0x1d89c5['view']?(this['_showBalloon'](_0x1d89c5),_0x1d89c5['view']['element']['focus'](),this['setActiveAnnotation'](_0x1d89c5)):this['setActiveAnnotation'](null);});};for(const _0x2dffdf of _0x33586b)_0x579ecf(_0x2dffdf);this['listenTo'](_0x33586b,'add',(_0x26b897,_0x2e2a76)=>{_0x579ecf(_0x2e2a76);}),this['listenTo'](_0x33586b,'remove',(_0x36d837,_0x59778f,_0x4191ab)=>{this['_annotationToNarrowView']['get'](_0x59778f)['destroy'](),this['_annotationToNarrowView']['delete'](_0x59778f),_0x3cf5fd['rearrange']({'removedAnnotation':_0x59778f,'previousAnnotation':_0x33586b['get'](_0x4191ab-0x1),'nextAnnotation':_0x33586b['get'](_0x4191ab+0x1)}),_0x59778f===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x33586b,'focus',(_0x51b431,_0x14f85d)=>{this['setActiveAnnotation'](_0x14f85d);}),this['listenTo'](_0x33586b,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x2a4082,_0x3d7214)=>{_0x3d7214['keyCode']===_0x3263c4['esc']&&_0x8fcf16['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x8fcf16['content']['first']),this['_hideBalloon'](),_0x3d7214['stopPropagation'](),_0x3d7214['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x1d8b43,_0x273160)=>{const _0x345cf7=_0x273160['target'];_0x8fcf16['isVisible']&&_0x8fcf16['element']['contains'](_0x345cf7)||_0x3cf5fd['view']['element']['contains'](_0x345cf7)||_0x1d8b43['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x3deead=>_0x3deead['contains'](_0x345cf7))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x3d3a23=this['context']instanceof _0x3a1751?this['context']['editors']:new _0x294a7b([this['context']]);for(const _0x46cbda of _0x3d3a23)this['_integrateWithEditorAnnotations'](_0x46cbda);this['listenTo'](_0x3d3a23,'add',(_0x4c3880,_0x5d58ff)=>{this['listenTo'](_0x5d58ff,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x5d58ff);});}),this['listenTo'](_0x3d3a23,'remove',(_0x3df78b,_0x8a2927)=>{_0x8a2927['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x8a2927['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x3aac99){if(_0x3aac99===this['activeAnnotation'])return;const _0x29b0cc=this['context']['plugins']['get'](z);if(_0x29b0cc['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x3aac99,'disableAnimationOnActivatedAnnotation':!0x0}),_0x3aac99)_0x29b0cc['getSidebarItemView'](_0x3aac99)?this['_showBalloon'](_0x3aac99):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x3aac99;}['detach'](){if(!this['isAttached'])throw new _0x4e095a('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x213154=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x41f2b3=>_0x41f2b3['destroy']()),this['_annotationToNarrowView']['clear'](),_0x213154['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x3a1751&&this['stopListening'](this['context']['editors']);for(const _0x93e16d of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x93e16d);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'](_0x5d9f0a){if(!_0x5d9f0a['plugins']['has']('EditorAnnotations'))return;const _0x4a50f1=_0x5d9f0a['plugins']['get']('EditorAnnotations'),_0xa53d0c=this['context']['plugins']['get'](z),_0x15accd=this['annotations'],_0x228291=this['balloonPanelView'],_0x3bb206=()=>{const _0x589440=_0x4a50f1['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x589440),this['setActiveAnnotation'](_0x589440[0x0]||null);};this['listenTo'](_0x4a50f1,'refresh',_0x3bb206),this['listenTo'](_0x4a50f1,'blur',(_0x5a1cdb,{isAnnotationTracked:_0xdea90a})=>{this['activeAnnotation']&&_0xdea90a(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x4a50f1,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x15accd,'blur',_0x3ccdee=>{_0x4a50f1['hasDomSelection']()&&_0x3ccdee['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x1950c,_0x956cee)=>{const _0x1eb273=_0x956cee['target'];_0x228291['isVisible']&&_0x228291['element']['contains'](_0x1eb273)||_0xa53d0c['view']['element']['contains'](_0x1eb273)||this['activeAnnotation']&&_0x4a50f1['hasDomSelection']()&&(_0x3bb206(),_0x1950c['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x4a50f1);}['_destroyEditorAnnotationsIntegration'](_0x2d3ece){_0x2d3ece&&(this['stopListening'](_0x2d3ece),this['_editorAnnotations']['remove'](_0x2d3ece));}['_setSelectedAnnotations'](_0x1de915){for(const _0x4a2711 of this['_selectedAnnotations'])_0x1de915['includes'](_0x4a2711)||this['_manuallyClosedAnnotationViews']['delete'](_0x4a2711['view']);this['_selectedAnnotations']=_0x1de915;}['_refreshPositioning'](){const _0x2ee834=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x2ee834['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x527f80){if(this['_manuallyClosedAnnotationViews']['has'](_0x527f80['view']))return;const _0x14efa4=this['balloonPanelView']['content']['first'];_0x14efa4!==_0x527f80['view']?(_0x14efa4&&this['_detachListeners'](_0x14efa4),this['_attachListeners'](_0x527f80['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x527f80['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x2f1523=this['balloonPanelView']['content']['first'],_0x1a42b2=_0x2f1523&&this['annotations']['getByView'](_0x2f1523);if(!_0x1a42b2||!this['_annotationToNarrowView']['has'](_0x1a42b2))return;const _0x189c4f=this['_annotationToNarrowView']['get'](_0x1a42b2)['element'],_0x652231=(function(){const _0x2bcb45=_0x28f2bd['defaultPositions'];return[_0x2bcb45['southArrowNorthEast'],_0x2bcb45['northArrowSouthEast'],_0x2bcb45['southArrowNorth'],_0x2bcb45['northArrowSouth'],_0x2bcb45['southArrowNorthWest'],_0x2bcb45['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x189c4f,'positions':_0x652231});}['_hideBalloon'](){const _0x415a7c=this['balloonPanelView'],_0x4b522d=_0x415a7c['content']['first'];_0x4b522d&&(this['_detachListeners'](_0x4b522d),_0x415a7c['unpin'](),_0x415a7c['content']['clear']());}['_attachListeners'](_0x4e5fa9){this['listenTo'](_0x4e5fa9,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x4e5fa9,'Esc',(_0x4b0fc6,_0x11b49b)=>{this['_manuallyClosedAnnotationViews']['add'](_0x4e5fa9),this['_hideBalloon'](),_0x11b49b();});}['_detachListeners'](_0x3de3dd){this['stopListening'](_0x3de3dd);}}class c extends _0x347641{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[b,_0x1c40ce,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3e4c03){super(_0x3e4c03),_0x3e4c03['editing']['view']['addObserver'](_0x2497b2),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x3e4c03['plugins']['get'](_0x1c40ce),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x270165=this['editor']['plugins']['get'](j);_0x270165['context']===this['editor']&&(_0x270165['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x3477d7,_0x467c5f)=>{const _0x2b475c=this['_balloon'];if(this['isAttached']&&_0x2b475c['visibleView']){const _0x23b54c=this['annotations']['getByView'](_0x2b475c['visibleView']);_0x23b54c&&this['_closeAnnotation'](_0x23b54c),_0x467c5f();}}));}['afterInit'](){const _0x3fdc90=this['editor']['plugins']['get'](j);_0x3fdc90['context']===this['editor']&&(_0x3fdc90['hasActive']()||_0x3fdc90['switchTo']('inline'));}['setActiveAnnotation'](_0xcdbcd9){_0xcdbcd9!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0xcdbcd9&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0xcdbcd9)&&this['_addAnnotationToBalloon'](_0xcdbcd9,!0x0),_0xcdbcd9['isActive']=!0x0),_0xcdbcd9||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0xcdbcd9);}['attach'](_0x105951){this['annotations']=_0x105951;const _0x4e77d5=this['editor']['plugins']['get'](j),_0x21ac3c=this['_balloon'];if(this['isAttached'])throw new _0x4e095a('inlineannotations-attach-already-attached',this);if(_0x4e77d5['context']!==this['editor'])throw new _0x4e095a('inlineannotations-not-allowed-with-context',this);const _0x2a6a72=this['editor']['plugins']['get'](b);this['listenTo'](_0x2a6a72,'refresh',()=>{const _0x5df79e=_0x2a6a72['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x10b615,_0x1b981f;!this['_forceRefresh']&&(_0x10b615=_0x5df79e,_0x1b981f=this['_selectedAnnotations'],_0x10b615['length']===_0x1b981f['length']&&_0x10b615['every'](_0xa8cb13=>_0x1b981f['includes'](_0xa8cb13)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x5df79e),this['setActiveAnnotation'](_0x5df79e[0x0]||null));}),this['listenTo'](_0x2a6a72,'blur',(_0x2e25cd,{isAnnotationTracked:_0x310076})=>{this['activeAnnotation']&&_0x310076(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x8cd9eb,_0x236920,_0x10a689)=>{_0x10a689||this['setActiveAnnotation'](null);}),this['listenTo'](_0x105951,'remove',(_0x1a0123,_0x237369)=>{this['_removeAnnotationFromBalloon'](_0x237369),_0x237369===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x21ac3c,'change:visibleView',(_0x41b611,_0x51d335,_0x3ac67b,_0xa9ba2e)=>{_0xa9ba2e&&this['stopListening'](_0xa9ba2e);const _0xd7c1c6=_0x105951['getByView'](_0x3ac67b);_0x3ac67b&&_0xd7c1c6&&(this['listenTo'](_0x3ac67b,'change:height',()=>{_0x21ac3c['updatePosition']();}),this['listenTo'](_0x3ac67b,'Esc',()=>{this['_closeAnnotation'](_0xd7c1c6),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0xd7c1c6&&this['setActiveAnnotation'](_0xd7c1c6));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x21ac3c['visibleView']&&(_0x105951['getByView'](_0x21ac3c['visibleView'])&&_0x21ac3c['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 _0x4e095a('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x2c5b53 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x2c5b53);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x55867f){for(const _0x1fd75a of this['_selectedAnnotations'])_0x55867f['includes'](_0x1fd75a)||this['_manuallyClosed']['delete'](_0x1fd75a);for(const _0x448fab of this['annotations'])_0x55867f['includes'](_0x448fab)||this['_removeAnnotationFromBalloon'](_0x448fab);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x5e49d1 of _0x55867f)this['_addAnnotationToBalloon'](_0x5e49d1);}this['_selectedAnnotations']=_0x55867f;}['_addAnnotationToBalloon'](_0x2b05ff,_0x5b46ce=!0x1){this['_manuallyClosed']['has'](_0x2b05ff)||(this['_addedAnnotations']['has'](_0x2b05ff)||this['_balloon']['hasView'](_0x2b05ff['view'])||(this['_addedAnnotations']['add'](_0x2b05ff),this['_balloon']['add']({'stackId':_0x2b05ff['view']['id'],'view':_0x2b05ff['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x2b05ff)}})),_0x5b46ce&&this['_balloon']['showStack'](_0x2b05ff['view']['id']));}['_getBalloonTargetForAnnotation'](_0x364903){const _0x47bea0=_0x364903['target'],_0x191842=this['editor']['editing']['view'],_0x1bab42=_0x191842['document']['selection']['getFirstRange'](),_0x20e9c3=_0x191842['domConverter']['viewRangeToDom'](_0x1bab42);if(_0x20e9c3['collapse'](!0x0),_0x47bea0){if(_0x47bea0 instanceof _0x3e5e72)return _0x47bea0;let _0x1fa114=[];for(const _0x5c5399 of _0x47bea0)_0x1fa114['push'](...F(_0x5c5399['getClientRects']()));_0x1fa114=function(_0x427fb5){const _0x5d771a=[];let _0x2a7e97=_0x427fb5[0x0];for(let _0x237234=0x1;_0x237234<_0x427fb5['length'];_0x237234++)P(_0x2a7e97,_0x427fb5[_0x237234])?_0x2a7e97['width']+=_0x427fb5[_0x237234]['width']:(_0x5d771a['push'](_0x2a7e97),_0x2a7e97=_0x427fb5[_0x237234]);return _0x5d771a['push'](_0x2a7e97),_0x5d771a;}(_0x1fa114);const _0xef2695=_0x20e9c3['getBoundingClientRect']();return _0x1fa114['find'](_0x45dcbd=>_0x45dcbd['top']<=_0xef2695['top']&&_0x45dcbd['bottom']>=_0xef2695['bottom']&&_0x45dcbd['left']<=_0xef2695['left']&&_0x45dcbd['right']>=_0xef2695['right'])||_0x1fa114[0x0];}return _0x364903['targetRect']||_0x20e9c3;}['_removeAnnotationFromBalloon'](_0x2dd9a8){this['_addedAnnotations']['has'](_0x2dd9a8)&&this['_balloon']['hasView'](_0x2dd9a8['view'])&&(this['_addedAnnotations']['delete'](_0x2dd9a8),this['_balloon']['remove'](_0x2dd9a8['view']));}['_closeAnnotation'](_0x450ed1){this['_manuallyClosed']['add'](_0x450ed1),this['_removeAnnotationFromBalloon'](_0x450ed1);}}function F(_0x133c90){return Array['from'](_0x133c90)['map'](DOMRect['fromRect']);}function P(_0x25a8ac,_0x40dba9){return _0x25a8ac['top']===_0x40dba9['top']&&_0x25a8ac['bottom']===_0x40dba9['bottom']&&_0x25a8ac['right']===_0x40dba9['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x597b7a,_0x3d8cbb){super(_0x597b7a),this['set']('isEmpty',!_0x3d8cbb['length']),this['focusTracker']=new _0x2d3c14(),this['_annotationViews']=_0x3d8cbb,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x58c694({'focusables':_0x3d8cbb,'focusTracker':this['focusTracker']}),this['listenTo'](_0x3d8cbb,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x3d8cbb,'remove',(_0x4256bd,_0x4f973c)=>{_0x4f973c['isActive']&&this['focus'](),_0x3d8cbb['length']||(this['isEmpty']=!0x0);});const _0x134fb9=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x597b7a,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x3d8cbb},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x134fb9['if']('isEmpty','ck-hidden',_0x1b7264=>!_0x1b7264)]},'children':[{'text':N(_0x597b7a,'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 _0x49f3dd of this['_annotationViews'])this['focusTracker']['add'](_0x49f3dd['element']);this['_annotationViews']['on']('change',(_0x26728d,{added:_0x4b53bc,removed:_0x4f8eb0})=>{for(const _0x471978 of _0x4b53bc)this['focusTracker']['add'](_0x471978['element']);for(const _0x23abcf of _0x4f8eb0)this['focusTracker']['remove'](_0x23abcf['element']);});}}class p extends _0x5d2528{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x55973b){super(_0x55973b),this['archivedThreads']=new _0x294a7b();}['init'](){const _0x47727d=this['context'],_0x553adb=_0x47727d['plugins']['get'](o),_0x131239=_0x47727d['plugins']['get'](y);this['listenTo'](_0x553adb,'addCommentThread',(_0x58780c,{threadId:_0x23c806})=>{const _0x2313d3=_0x553adb['getCommentThread'](_0x23c806);_0x2313d3['archivedAt']&&this['archivedThreads']['add'](_0x2313d3,this['_calculatePosition'](_0x2313d3['archivedAt'])),this['listenTo'](_0x2313d3,'change:archivedAt',(_0x4b13a8,_0x45d17d,_0x28f719)=>{_0x28f719?this['archivedThreads']['has'](_0x2313d3)||this['archivedThreads']['add'](_0x2313d3,this['_calculatePosition'](_0x2313d3['archivedAt'])):this['archivedThreads']['has'](_0x2313d3)&&this['archivedThreads']['remove'](_0x2313d3);});}),this['listenTo'](_0x553adb,'removeCommentThread',(_0x31d2e8,{threadId:_0x19c670})=>{const _0x52a572=_0x553adb['getCommentThread'](_0x19c670);this['stopListening'](_0x52a572),this['archivedThreads']['has'](_0x52a572)&&this['archivedThreads']['remove'](_0x52a572);},{'priority':'highest'}),this['listenTo'](_0x131239['collection'],'focus',(_0x44cb87,_0x11edfe)=>{_0x11edfe['isVisible']||(_0x11edfe['isActive']=!0x0,_0x131239['activate'](_0x11edfe));});}['_calculatePosition'](_0x381a4c){const _0x40a5a9=[...this['archivedThreads']]['findIndex'](_0x4de762=>_0x4de762['archivedAt']<_0x381a4c);return _0x40a5a9>-0x1?_0x40a5a9:this['archivedThreads']['length'];}}class a extends _0x347641{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x247bd7];}constructor(_0x2378a9){super(_0x2378a9),this['annotationViews']=new _0x58b265(),this['_pendingThreads']=[];}['init'](){const _0x3b4ae3=this['editor'],_0x4e511d=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x3b4ae3['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x55680e,!0x0)),_0x3b4ae3['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x289aba=this['_createCommentsArchiveButton'](_0x5f2010);return _0x289aba['set']({'role':'menuitemcheckbox'}),_0x289aba;});const _0x2dfd02=_0x3b4ae3['plugins']['get'](p),_0x45a96f=_0x3b4ae3['plugins']['get']('Annotations'),_0x251bfa=_0x3b4ae3['plugins']['get']('CommentsRepository');_0x2dfd02['archivedThreads']['forEach'](_0x47a3=>{this['_handleNewThread'](_0x47a3);}),this['listenTo'](_0x2dfd02['archivedThreads'],'add',(_0x105a79,_0xf7175)=>{this['_handleNewThread'](_0xf7175);}),this['listenTo'](_0x45a96f['collection'],'add',(_0x2a1eaa,_0x35642d)=>{const _0x30d1da=this['_pendingThreads']['find'](_0x3a365d=>{const _0x207333=_0x251bfa['_threadToController']['get'](_0x3a365d);return _0x207333&&_0x35642d['innerView']===_0x207333['view'];});if(_0x30d1da){const _0x408483=this['_calculatePosition'](_0x30d1da['archivedAt']);this['_addAnnotationToArchive'](_0x35642d,_0x408483),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x30d1da),0x1);}}),this['listenTo'](_0x2dfd02['archivedThreads'],'remove',(_0xb6e944,_0x51dd0d)=>{const _0x5f121e=_0x3b4ae3['config']['get']('collaboration.channelId');if(!_0x5f121e||_0x51dd0d['channelId']===_0x5f121e){if(this['_pendingThreads']['includes'](_0x51dd0d))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x51dd0d),0x1);else{const _0x50156e=_0x251bfa['_threadToController']['get'](_0x51dd0d),_0x50c927=_0x45a96f['getByInnerView'](_0x50156e['view']);this['annotationViews']['remove'](_0x50c927['view']),this['stopListening'](_0x50c927),this['stopListening'](_0x50c927['focusableElements']);}}}),this['listenTo'](_0x45a96f['collection'],'add',(_0x4cf5f7,_0x5c2be6)=>{this['listenTo'](_0x5c2be6,'escape',_0x4e511d);}),this['listenTo'](_0x45a96f['collection'],'remove',(_0xc7ef9e,_0xfae567)=>{this['stopListening'](_0xfae567,'escape',_0x4e511d);});}['_addAnnotationToArchive'](_0x6d2f3b,_0x40fb13){this['listenTo'](_0x6d2f3b,'set:isVisible',_0x57299d=>{_0x57299d['return']=!0x1,_0x57299d['stop']();}),this['annotationViews']['add'](_0x6d2f3b['view'],_0x40fb13);}['_handleNewThread'](_0xc0e4a3){const _0x85500=this['editor']['plugins']['get']('CommentsRepository'),_0x2bb1a5=this['editor']['plugins']['get']('Annotations'),_0x1405ae=this['editor']['config']['get']('collaboration.channelId');if(!_0x1405ae||_0xc0e4a3['channelId']===_0x1405ae){const _0x3d2ead=_0x85500['_threadToController']['get'](_0xc0e4a3);if(!_0x3d2ead)return void this['_pendingThreads']['push'](_0xc0e4a3);const _0x555be2=this['_calculatePosition'](_0xc0e4a3['archivedAt']),_0x3a0428=_0x2bb1a5['getByInnerView'](_0x3d2ead['view']);_0x3a0428['isVisible']&&_0x2bb1a5['_visibleAnnotations']['remove'](_0x3a0428),this['_addAnnotationToArchive'](_0x3a0428,_0x555be2);}}['_calculatePosition'](_0x5c0324){const _0x3312f6=this['editor']['config']['get']('collaboration.channelId'),_0x2ad48d=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0x3513ee=>_0x3513ee['channelId']===_0x3312f6)['findIndex'](_0x5d8e00=>_0x5d8e00['archivedAt']<_0x5c0324);return _0x2ad48d<0x0||_0x2ad48d>this['annotationViews']['length']?this['annotationViews']['length']:_0x2ad48d-0x1;}['_toggleDialog'](){const _0x3ba6bf=this['editor'],_0x2a109e=_0x3ba6bf['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x3ba6bf['locale'],this['annotationViews'])),'commentsArchive'===_0x2a109e['id']?_0x2a109e['hide']():_0x2a109e['show']({'id':'commentsArchive','title':N(_0x3ba6bf['locale'],'COMMENTS_ARCHIVE'),'icon':_0x2ce601,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x277bfc['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x4421cf,_0x2735c3=!0x1){const _0x344b47=this['editor']['locale'],_0x1611f1=this['editor']['plugins']['get']('Dialog'),_0x255c84=new _0x4421cf(_0x344b47);return _0x255c84['bind']('isEnabled')['to'](this,'isEnabled'),_0x255c84['bind']('isOn')['to'](_0x1611f1,'id',_0x1018de=>'commentsArchive'===_0x1018de),_0x255c84['set']({'label':N(_0x344b47,'COMMENTS_ARCHIVE'),'icon':_0x2ce601,'isToggleable':!0x0}),_0x2735c3&&(_0x255c84['tooltip']=!0x0),this['listenTo'](_0x255c84,'execute',()=>this['_toggleDialog']()),_0x255c84;}['_hideDialogOnAnnotationEscape']=_0x5182af=>{const _0x3a2ed4=_0x5182af['source'];if(!this['annotationViews']['has'](_0x3a2ed4['view']))return;const _0x2451ca=this['editor']['plugins']['get']('Dialog');_0x2451ca['isOpen']&&'commentsArchive'===_0x2451ca['id']&&(_0x2451ca['hide'](),_0x5182af['stop']());};}class vi extends _0x347641{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,Yt as BaseCommentThreadView,ci as BaseCommentView,yi as Comment,Ti as CommentThread,vt as CommentThreadController,ie as CommentThreadInputView,gt as CommentThreadView,Tt as CommentView,vi 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 _0x20c4d1,ContextPlugin as _0x10fb5d,PendingActions as lt,Command as _0x16c327,Plugin as _0x57b43d,Context as _0x114fec}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x344dd5,uid as _0x47ab7a,KeystrokeHandler as jt,FocusTracker as _0x5bef6f,diff as _0x183432,Collection as _0x4654ca,Rect as _0x49c6d0,CKEditorError as _0x5d7ae6,first as _0x426329,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x1c26f7,keyCodes as _0x10fa84}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x11754b,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x599937,trimHtml as ts,LateFocusDropdownButtonView as _0x245e36,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x3fa6bd}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x211bee}from'es-toolkit/compat';import{IconUndo as _0x17c5a9,IconCheck as _0x44cf93,IconPencil as _0x298fe7,IconRemoveComment as _0x2a0a6c,IconThreeVerticalDots as _0x1a5ea9,IconAddComment as _0x25afc1,IconCommentsArchive as _0x154ce6}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as $t,InlineEditableUIView as Vt,EditorUI as Ut,View as kt,FocusCycler as _0x3b0d1d,ButtonView as _0x49decf,ViewCollection as _0x5c4347,createDropdown as _0x90d061,ListView as _0x5ef44c,focusChildOnDropdownOpen as _0x2d1231,ListItemView as _0x23aa4b,MenuBarMenuListItemButtonView as _0x28f235,BodyCollection as _0x7b567a,BalloonPanelView as _0x42f273,ContextualBalloon as _0x2252d1,Dialog as _0x16e01c,DialogViewPosition as _0x4b0027}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as St,enableViewPlaceholder as Ft,MouseObserver as _0x5675a2}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as qt,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as zt,ShiftEnter as Bt}from'@ckeditor/ckeditor5-enter/dist/index.js';import{SelectAll as Gt}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as Jt}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as Kt}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as Lt}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x27c044}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x5cc22c}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
+ _0x344dd5(){['model'];['view'];constructor(_0x17850f,_0x101410){super(),this['model']=_0x17850f,this['model']['_isAttached']=!0x0,this['view']=_0x101410,this['listenTo'](_0x101410,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x101410,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x101410,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x101410,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x101410,'addComment',(_0x256bd7,_0x412160)=>this['addComment'](_0x412160)),this['listenTo'](_0x101410,'updateComment',(_0x11ea6f,_0x25c422,_0x394cfa)=>this['updateComment'](_0x25c422,_0x394cfa)),this['listenTo'](_0x101410,'removeComment',(_0x1b8f97,_0x3aa9cd)=>this['removeComment'](_0x3aa9cd));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x21f07d){this['model']['addComment']({'content':_0x21f07d,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x341454,_0x518017){this['model']['getComment'](_0x341454)['update']({'content':_0x518017});}['removeComment'](_0x587ad4){this['model']['getComment'](_0x587ad4)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x3394ae,_0x509e1e,_0xf72e09){const t=_0x3394ae['t'];switch(_0x509e1e){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'},_0xf72e09);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'},_0xf72e09);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'},_0xf72e09);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'},_0xf72e09);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0xf72e09);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'},_0xf72e09);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'},_0xf72e09);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'},_0xf72e09);case'COMMENTS_ARCHIVE':return t({'string':'Comments\x20archive','id':'COMMENTS_ARCHIVE'});case'EMPTY_COMMENTS_ARCHIVE':return t({'string':'There\x20are\x20no\x20archived\x20comment\x20threads.','id':'EMPTY_COMMENTS_ARCHIVE'});case'COMMENTS_ARCHIVE_LIST_LABEL':return t({'string':'List\x20of\x20comments','id':'COMMENTS_ARCHIVE_LIST_LABEL'});case'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP':return t({'string':'Keystrokes\x20for\x20interacting\x20with\x20annotation\x20threads\x20(e.g.\x20comments,\x20track\x20changes\x20suggestions)','id':'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'});case'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO':return t({'string':'Move\x20focus\x20to\x20the\x20thread\x20when\x20the\x20selection\x20is\x20anchored\x20in\x20its\x20marker','id':'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'});case'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT':return t({'string':'Exit\x20the\x20annotation\x20and\x20move\x20focus\x20back\x20to\x20the\x20edited\x20content','id':'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER':return t({'string':'Browse\x20the\x20focused\x20annotation\x20thread\x20or\x20thread\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'});case'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS':return t({'string':'Move\x20across\x20internals\x20of\x20the\x20annotation\x20thread','id':'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'});case'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT':return t({'string':'Submit\x20the\x20reply\x20while\x20writing\x20a\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS':return t({'string':'Move\x20to\x20the\x20previous\x20or\x20next\x20thread\x20in\x20the\x20annotations\x20sidebar\x20or\x20comments\x20archive','id':'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'});default:return'';}}class Rt extends $t{['main'];['editable'];constructor(_0x5d3637,_0x53ec3e){super(_0x5d3637);const _0x3e59ae=_0x47ab7a();this['main']=this['createCollection'](),this['editable']=new Vt(_0x5d3637,_0x53ec3e,void 0x0,{'label':()=>N(_0x5d3637,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x5d3637['uiLanguageDirection'],'lang':_0x5d3637['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x3e59ae},'children':[{'tag':'div','attributes':{'class':'ck-editor__main','role':'presentation'},'children':this['main']}]});}['render'](){super['render'](),this['main']['add'](this['editable']);}['focus'](){this['editable']['element']['focus']();}}class Et extends Ut{['view'];constructor(_0xc3ba67){super(_0xc3ba67),this['view']=new Rt(_0xc3ba67['locale'],_0xc3ba67['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x582301=this['editor']['editing']['view'],_0x5e6931=this['view']['editable'],_0x245e79=_0x582301['document']['getRoot']();_0x5e6931['name']=_0x245e79['rootName'],this['view']['render']();const _0x32674f=_0x5e6931['element'];this['setEditableElement'](_0x5e6931['name'],_0x32674f),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x582301['attachDomRoot'](_0x32674f),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[qt,zt,Bt,Gt,Jt,Kt,Lt];class hs extends/* #__PURE__ -- @preserve */
25
+ _0x344dd5(_0x20c4d1){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
+ ((()=>Qt)());constructor(_0x5703d4={}){function _0x86c22a(_0x26e6dd){return _0x26e6dd['map'](_0x247d8a=>String['fromCharCode'](_0x247d8a))['join']('');}(_0x5703d4=Object['assign']({},_0x5703d4))['plugins']||(_0x5703d4['plugins']=hs['defaultPlugins']),super(_0x5703d4),this['ui']=new Et(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x86c22a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x86c22a([0x76,0x69,0x65,0x77])][_0x86c22a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x86c22a([0x61,0x75,0x74,0x6f]),this[_0x86c22a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x86c22a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x86c22a([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x86c22a([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x86c22a([0x6f,0x6b])});}['create'](){const _0x421be7=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x421be7))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x1bed83=>{const _0x4a64e4=this['model']['document']['getRoot'](),_0x25af68=_0x4a64e4&&_0x4a64e4['getChild'](_0x4a64e4['childCount']-0x1);_0x1bed83['setSelection'](_0x25af68,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x543dd0=this['editing']['view'],_0x91a675=_0x543dd0['document']['getRoot'](),_0x2d840c=_0x91a675['getChild'](0x0);_0x91a675['childCount']>0x1||!_0x2d840c||'p'!=_0x2d840c['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x543dd0,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x2d840c['placeholder']=this['placeholder']),Ft({'view':_0x543dd0,'element':_0x2d840c,'keepOnFocus':!0x0}),this['placeholderElement']=_0x2d840c);}}class es extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x2ed609,_0x18017c={}){super(_0x2ed609),this['editor']=null,this['_editorConfig']=_0x18017c,this['set']('value',_0x18017c['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x2ed609,'Reply...')),this['set']('submitLabel',N(_0x2ed609,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x5bef6f(),this['focusCycler']=new _0x3b0d1d({'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',(_0x5d70cc,_0x1e0e14)=>{this['cancelButtonView']['fire']('execute'),_0x1e0e14();}),this['keystrokes']['set']('Ctrl+Enter',(_0x27ba36,_0x2a79b2)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x2a79b2());}),this['on']('submit',(_0x298d40,_0x4be3f5)=>{_0x4be3f5['length']>0xfde8?(alert(N(_0x2ed609,'TOO_LONG_COMMENT_ALERT',[_0x4be3f5['length'],0xfde8])),_0x298d40['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new hs(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x43f5e6=this['editor'];this['element']['insertBefore'](_0x43f5e6['ui']['element'],this['element']['firstChild']),_0x43f5e6['model']['document']['on']('change',()=>this['value']=_0x43f5e6['getData']()),_0x43f5e6['bind']('placeholder')['to'](this),this['focusables']['add'](_0x43f5e6['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x3fb653){-0x1===_0x3fb653?(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:_0x3ac92a}=this,_0x4fd6fc=new _0x49decf(_0x3ac92a);return _0x4fd6fc['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x4fd6fc['withText']=!0x0,_0x4fd6fc['bind']('label')['to'](this,'submitLabel'),_0x4fd6fc['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x4fd6fc['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0xb84032,_0x185e1f)=>!_0x185e1f&&!!_0xb84032['trim']()),_0x4fd6fc;}['_createCancelButton'](){const {locale:_0x2f5331}=this,_0x74467d=new _0x49decf(_0x2f5331);return _0x74467d['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x74467d['label']=N(_0x2f5331,'Cancel'),_0x74467d['withText']=!0x0,_0x74467d['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x74467d;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x5871b9=>{this['focusTracker']['add'](_0x5871b9['element']);}),this['focusables']['on']('change',(_0x148b2f,_0x5f40c6)=>{for(const _0x337b08 of Array['from'](_0x5f40c6['added'])['reverse']())this['focusTracker']['add'](_0x337b08['element']);});}}class ie extends kt{constructor(_0x2402a6,_0x5026e2,_0x424b85){super(_0x2402a6),this['commentInputView']=new es(_0x2402a6,_0x424b85),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x5b69e4,_0x218bf6)=>_0x5b69e4||!!_0x218bf6),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 _0x11754b(_0x2402a6,_0x5026e2),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'](_0x32b4b3){this['commentInputView']['focus'](_0x32b4b3);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0xa8abc4,_0x351389)=>{const {submitButtonView:_0x396fb0,cancelButtonView:_0x58bd5e,editor:_0x1ff23e}=this['commentInputView'];[_0x396fb0['element'],_0x58bd5e['element'],_0x1ff23e?_0x1ff23e['editing']['view']['getDomRoot']():null]['filter'](_0x6f5747=>_0x6f5747)['some'](_0xed04a1=>_0xed04a1['contains'](_0x351389['target']))||(this['focus'](),_0x351389['preventDefault']());});}}class rs extends kt{constructor(_0x26f61c){super(_0x26f61c);const _0x12ff12=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x12ff12['to']('count',_0x5300c8=>N(_0x26f61c,'NUMBER_OF_COMMENTS',_0x5300c8))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x44ae28,_0x10d419,_0xf1cf83){super(_0x44ae28);const _0x820d0a=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x10d419['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x10d419,this['_config']=_0xf1cf83,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x5bef6f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x3b0d1d({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x235235=>this['commentViews']['map'](_0x49e9b6=>_0x49e9b6['element'])['includes'](_0x235235['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x44ae28),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x2787c5=>_0x2787c5-this['_config']['maxCommentsWhenCollapsed']);for(const _0x29634e of _0x10d419['comments'])this['_handleNewCommentModel'](_0x29634e);this['_handleInfoComment'](),this['listenTo'](_0x10d419['comments'],'add',(_0x3d5bcd,_0x21273f)=>{const _0x5e9f83=this['_calculatePosition'](_0x21273f);this['length']++,this['_handleNewCommentModel'](_0x21273f,_0x5e9f83),this['refreshVisibleViews']();}),this['listenTo'](_0x10d419['comments'],'remove',(_0x3fbbc8,_0x4acf83)=>{this['length']--,this['_handleRemoveCommentModel'](_0x4acf83),this['refreshVisibleViews']();}),this['listenTo'](_0x10d419,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x10d419,'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',_0x820d0a['if']('length','ck-hidden',_0x4de382=>!_0x4de382)],'aria-label':N(_0x44ae28,'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'](_0x5631d9){-0x1===_0x5631d9?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x14c8fa of this['commentViews'])_0x14c8fa['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x147663,_0x4a2d35){const _0x54cccf=new this['_config']['CommentView'](this['locale'],_0x147663,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x54cccf['viewUid']=_0x147663['id'],_0x54cccf['delegate']('removeComment')['to'](this),_0x54cccf['delegate']('updateComment')['to'](this),_0x54cccf['delegate']('resolveCommentThread')['to'](this),_0x54cccf['delegate']('editorReady')['to'](this),_0x54cccf['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x54cccf,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x54cccf,_0x4a2d35);}['_calculatePosition'](_0x48e38a){const _0x422773=this['_model']['_findOptimalIndex'](_0x48e38a);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x48e38a['authoredAt']?_0x422773-0x1:_0x422773:_0x422773-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0xf9d1fc={'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'],_0xf9d1fc,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0xf9d1fc));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x3a1ab0){const _0x5c85e0=this['commentViews']['remove'](_0x3a1ab0['id']);this['stopListening'](_0x5c85e0),_0x5c85e0['isEditMode']&&this['_updateHasDirtyComment'](),_0x5c85e0['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x3c8750=>_0x3c8750['isEditMode']);}['_rearrangeCollapse'](){const _0x335f09=function(_0x367ca5){const _0x34649d=new _0x4654ca();for(const _0xe3cf33 of _0x367ca5)_0x34649d['add'](_0xe3cf33);return _0x34649d;}(this['commentViews']),_0x3749ac=this['_collapsedCommentsView']['count'];for(let _0x3a75c5=0x1;_0x3a75c5<=_0x3749ac;_0x3a75c5++)_0x335f09['remove'](0x1);for(const _0x5de4e0 of _0x335f09)_0x5de4e0['collapse']();_0x3749ac>0x0&&_0x335f09['add'](this['_collapsedCommentsView'],0x1),ns(_0x183432(Array['from'](this['visibleViews']),Array['from'](_0x335f09)),this['visibleViews'],_0x335f09);}['_rearrangeExpand'](){ns(_0x183432(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x5548db of this['visibleViews'])_0x5548db['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x51af8b=>{this['focusTracker']['add'](_0x51af8b['element']),this['keystrokes']['listenTo'](_0x51af8b['element']);}),this['commentViews']['on']('change',(_0x74e4f2,_0x3b1689)=>{for(const _0x216b6a of _0x3b1689['removed'])this['focusTracker']['remove'](_0x216b6a['element']),this['keystrokes']['stopListening'](_0x216b6a['element']);for(const _0x525558 of Array['from'](_0x3b1689['added'])['reverse']())this['focusTracker']['add'](_0x525558['element']),this['keystrokes']['listenTo'](_0x525558['element']);});}}function ns(_0x554a27,_0x36cdd0,_0x5ef4ec){let _0x2ed585=0x0;for(const _0x261f67 of _0x554a27)switch(_0x261f67){case'insert':_0x36cdd0['add'](_0x5ef4ec['get'](_0x2ed585),_0x2ed585),_0x2ed585++;break;case'delete':_0x36cdd0['remove'](_0x2ed585);break;case'equal':_0x2ed585++;}}class oe extends kt{constructor(_0x3f4fa4){super(_0x3f4fa4);const _0x5b3bc6=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x5b3bc6['to']('contextValue',_0x11cb68=>N(_0x3f4fa4,'THREAD_CONTEXT_LABEL',_0x11cb68)),'tabindex':-0x1},'children':[{'text':_0x5b3bc6['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x284737,_0x1223c4){super(_0x284737);const _0x341c32=this['bindTemplate'];this['_model']=_0x1223c4,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x5bef6f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x3b0d1d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x48e5c8=>!!_0x48e5c8),this['bind']('contextValue')['to'](this['_model'],'context',_0x48de85=>_0x48de85&&_0x48de85['value']?this['_trimContextValue'](_0x48de85['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',_0x341c32['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 _0x2a5400=new _0x49decf(this['locale']);return _0x2a5400['label']=N(this['locale'],'Reopen'),_0x2a5400['tooltip']=N(this['locale'],'Reopen'),_0x2a5400['icon']=_0x17c5a9,_0x2a5400['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x203275=>!_0x203275),_0x2a5400['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x400a1a,_0x441d02)=>_0x400a1a&&_0x441d02),_0x2a5400['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x2a5400;}['_trimContextValue'](_0xb184e8){if(_0xb184e8['length']<0x96)return _0xb184e8;const _0xd1db84=_0xb184e8['lastIndexOf']('\x20',0x93);return _0xb184e8['substring'](0x0,_0xd1db84>-0x1?_0xd1db84:0x93)+'...';}['_attachContextActions'](){const _0x471cc5=this['element']['querySelector']('.ck-context'),_0x11d0e5=_0x471cc5['querySelector']('.ck-context__value');this['listenTo'](_0x471cc5,'mouseenter',()=>{_0x11d0e5['offsetWidth']<_0x11d0e5['scrollWidth']&&_0x471cc5['classList']['add']('overlay');}),this['listenTo'](_0x471cc5,'mouseleave',()=>{_0x471cc5['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x1bdd07 of this['focusables'])this['focusTracker']['add'](_0x1bdd07['element']),this['keystrokes']['listenTo'](_0x1bdd07['element']);}['_createContextView'](){const _0x4784aa=new oe(this['locale']);return _0x4784aa['bind']('contextValue')['to'](this),_0x4784aa;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x311e4e,_0x209224,_0x383c41,_0x351ddf){super(_0x311e4e),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x209224,this['_localUser']=_0x383c41,this['_config']=_0x351ddf,this['commentThreadHeaderView']=new Xt(_0x311e4e,_0x209224),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x311e4e,N(_0x311e4e,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x311e4e,_0x209224,Object['assign']({'CommentView':this['_config']['CommentView']},_0x351ddf)),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',(_0x380a23,_0x3d0dbb)=>_0x380a23||!!_0x3d0dbb),this['bind']('isUnlinked')['to'](_0x209224,'unlinkedAt',_0x19f041=>!!_0x19f041),this['bind']('ariaLabel')['to'](this,'length',_0x186fdd=>{const _0x4aad9c=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x186fdd,_0x4aad9c]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x5bef6f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x3b0d1d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0xaab32f=>_0xaab32f['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),Zt(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x75f29d=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x29ab98=_0x75f29d['commentInputView'];return _0x75f29d['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x29ab98,'value',(_0x57c22c,_0x4140c5,_0x3efc28,_0x1cb452,_0xb04378)=>!!_0xb04378||!!_0x1cb452&&_0x3efc28&&!_0x4140c5||_0x57c22c&&_0x3efc28&&!_0x4140c5),_0x29ab98['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x388ce0,_0x35e448,_0x13c6fb)=>{let _0x5e35e4;return _0x5e35e4=_0x13c6fb&&_0x35e448?'Reply\x20to\x20reopen\x20discussion...':_0x388ce0?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x5e35e4);}),_0x29ab98['bind']('submitLabel')['to'](this,'length',_0x335b10=>N(this['locale'],_0x335b10?'Reply':'Comment')),_0x29ab98['on']('submit',(_0x1384e2,_0x920a3d)=>{this['fire']('addComment',_0x920a3d),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x29ab98['on']('cancel',()=>{this['focus']();}),_0x29ab98['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x29ab98['on']('cancel',_0x292a97=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x292a97['stop']());}),this['on']('change:isActive',(_0x511c01,_0x2fb739,_0x4843f9)=>{_0x4843f9||this['length']||_0x29ab98['value']||this['fire']('removeCommentThread');}),_0x75f29d;}}class gt extends/* #__PURE__ -- @preserve */
27
+ ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x5ae684,_0x143d89,_0x3b9fc9,_0x56f555){super(_0x5ae684,_0x143d89,_0x3b9fc9,_0x56f555),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x5ae684,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x565367,_0x37fef1,_0x56a88c)=>{_0x56a88c||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x4cb717,_0x365f81,_0x98d440)=>{_0x98d440&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x4a97ae=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x4a97ae['if']('isActive','ck-thread--active'),_0x4a97ae['if']('isUnlinked','ck-thread--unlinked'),_0x4a97ae['to']('actionIndicator',_0x5ab5f4=>_0x5ab5f4?'ck-thread--'+_0x5ab5f4:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x4a97ae['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 _0x23e330 of this['commentsListView']['commentViews'])_0x23e330['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x39e6dc}=this,_0x48b4f4=this['commentsListView']['commentViews']['get'](0x0);_0x48b4f4===this['_boundFirstCommentView']||_0x48b4f4['isSystemComment']||(this['_boundFirstCommentView']=_0x48b4f4,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x48b4f4,'actionIndicator',_0x892823=>'remove'===_0x892823?'remove':null),_0x48b4f4['placeholder']=N(_0x39e6dc,'Write\x20a\x20comment...'),_0x48b4f4['removeButton']['on']('execute',_0x20f2a8=>{_0x20f2a8['stop'](),this['showConfirm'](N(_0x39e6dc,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x48b4f4['focus']();}),_0x48b4f4['actionBar']['add'](this['resolveButton'],0x0),_0x48b4f4['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x5c28ae=new _0x599937(this['locale']);return _0x5c28ae['label']=N(this['locale'],'Resolve'),_0x5c28ae['tooltip']=N(this['locale'],'Resolve'),_0x5c28ae['icon']=_0x44cf93,_0x5c28ae['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x5c28ae['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x4885f3=>!_0x4885f3),_0x5c28ae['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x58ad90,_0x548f63)=>_0x58ad90&&!_0x548f63),_0x5c28ae['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x5c28ae;}['_updateArchivedThreadHeader'](){this['_model']['archivedAt']?this['commentThreadChildren']['has'](this['commentThreadHeaderView'])||(this['commentThreadChildren']['add'](this['commentThreadHeaderView'],0x0),this['focusables']['add'](this['commentThreadHeaderView'],0x0)):this['commentThreadChildren']['has'](this['commentThreadHeaderView'])&&(this['commentThreadChildren']['remove'](this['commentThreadHeaderView']),this['focusables']['remove'](this['commentThreadHeaderView']));}}class is extends kt{constructor(_0x2420d2){super(_0x2420d2),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x5b9ba1,_0x5578b3,_0x8dd5ba)=>{this['element']['innerHTML']=_0x8dd5ba;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x1b3ad9,_0x437beb,_0x2e4fe5){super(_0x1b3ad9),this['_model']=_0x437beb,this['_config']=_0x2e4fe5,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x437beb,'content',_0x437beb,'authoredAt',(_0xfa3c28,_0x1ea42e)=>N(_0x1b3ad9,'COMMENT_ARIA_LABEL',[_0x437beb['author']['name'],_0x2e4fe5['formatDateTime'](_0x1ea42e),new DOMParser()['parseFromString'](_0xfa3c28,'text/html')['body']['textContent'],_0x437beb['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x1b3ad9,N(_0x1b3ad9,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x5c4347(),this['focusTracker']=new _0x5bef6f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x3b0d1d({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x20d8b9=>_0x20d8b9['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 _0x227a84=new is(this['locale']);return _0x227a84['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x193554,_0x53a288)=>_0x53a288?ts(_0x193554,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x193554),_0x227a84;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0xec5c7c=new es(this['locale'],this['_config']['editorConfig']);return _0xec5c7c['value']=this['_model']['content'],_0xec5c7c['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0xec5c7c['submitLabel']=N(this['locale'],'Save'),_0xec5c7c['on']('submit',(_0x29a9a7,_0xa531f8)=>{this['fire']('updateComment',this['_model']['id'],_0xa531f8),this['switchToDisplayMode'](),this['focus']();}),_0xec5c7c['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0xec5c7c['once']('editorReady',()=>{_0xec5c7c['focus']();}),_0xec5c7c['createEditor'](),_0xec5c7c['delegate']('editorReady')['to'](this),_0xec5c7c['delegate']('editorDestroyed')['to'](this),_0xec5c7c;}['_setupKeyboardNavigation'](){const _0x2e5491=this['element'];this['keystrokes']['listenTo'](_0x2e5491);for(const _0x5a59b0 of this['focusables'])this['focusTracker']['add'](_0x5a59b0['element']),this['keystrokes']['listenTo'](_0x5a59b0['element']);this['focusables']['on']('change',(_0x417b02,_0x1446fa)=>{for(const _0x4ae82e of _0x1446fa['removed'])this['focusTracker']['remove'](_0x4ae82e['element']),this['keystrokes']['stopListening'](_0x4ae82e['element']);for(const _0x221291 of _0x1446fa['added'])this['focusTracker']['add'](_0x221291['element']),this['keystrokes']['listenTo'](_0x221291['element']);}),this['keystrokes']['set']('enter',(_0x2b9abf,_0x25278b)=>{_0x2e5491===_0x2b9abf['target']&&(this['focusCycler']['focusFirst'](),_0x25278b());}),this['keystrokes']['set']('esc',(_0xa20eff,_0x5d233d)=>{_0x2e5491!==_0xa20eff['target']&&(this['focus'](),_0x5d233d());});}}class Tt extends/* #__PURE__ -- @preserve */
28
+ ti(di){['actionBar'];['userView'];constructor(_0x54b596,_0x3bba05,_0xac9eb7){super(_0x54b596,_0x3bba05,_0xac9eb7),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x54b596,'Reply...')),this['bind']('authoredAt')['to'](_0x3bba05),this['bind']('resolvedAt')['to'](_0x3bba05),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 _0x11754b(_0x54b596,_0x3bba05['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x3bba05,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x436635=this['bindTemplate'],_0x20e244=[{'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':_0x436635['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x436635['to']('authoredAt',_0x2ed1e8=>this['_config']['formatDateTime'](_0x2ed1e8))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x436635['if']('isEditMode','ck-comment__actions--hidden'),_0x436635['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']&&_0x20e244['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper'],'tabindex':-0x1,'aria-label':_0x436635['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x436635['if']('isEditMode','ck-comment--edit'),_0x436635['if']('isSystemComment','ck-comment--info'),_0x436635['to']('actionIndicator',_0x21144e=>_0x21144e?'ck-comment--'+_0x21144e:'')],'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':_0x20e244}]}]};}['_createEditButton'](){const _0x5e8fcd=new _0x49decf(this['locale']);return _0x5e8fcd['label']=N(this['locale'],'Edit'),_0x5e8fcd['icon']=_0x298fe7,_0x5e8fcd['withText']=!0x0,_0x5e8fcd['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x5e8fcd['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0xa15f7d=>!_0xa15f7d),_0x5e8fcd['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x5e8fcd['on']('execute',()=>this['switchToEditMode']()),_0x5e8fcd;}['_createRemoveButton'](){const _0x245fb6=new _0x49decf(this['locale']);return _0x245fb6['label']=N(this['locale'],'Remove'),_0x245fb6['icon']=_0x2a0a6c,_0x245fb6['withText']=!0x0,_0x245fb6['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x245fb6['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x31fd4f=>!_0x31fd4f),_0x245fb6['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x245fb6['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x245fb6;}['_createDropdown'](){const _0x103e58=_0x90d061(this['locale'],_0x245e36),_0x45bafe=_0x103e58['panelView']['children'],_0x3708b4=new _0x5ef44c(this['locale']),_0x81604f=_0x103e58['bindTemplate'];_0x2d1231(_0x103e58,()=>this['items']['find'](_0x2b456a=>_0x2b456a['isVisible'])),_0x103e58['extendTemplate']({'attributes':{'class':[_0x81604f['if']('isVisible','ck-hidden',_0x31818e=>!_0x31818e)]}});const _0x23dc36=(_0x2aca77,_0x234ba8=-0x1)=>{const _0x2148f2=new _0x23aa4b(this['locale']);_0x2148f2['children']['add'](_0x2aca77);const _0xc40cf6=_0x234ba8>-0x1?_0x234ba8:_0x3708b4['items']['length'];_0x3708b4['items']['add'](_0x2148f2,_0xc40cf6);const _0x228605=Array['from'](this['items']);_0x103e58['unbind']('isEnabled','isVisible'),_0x103e58['bind']('isEnabled')['toMany'](_0x228605,'isEnabled',(..._0x792035)=>_0x792035['some'](_0x4642ce=>_0x4642ce)),_0x103e58['bind']('isVisible')['toMany'](_0x228605,'isVisible',(..._0x2e8d33)=>_0x2e8d33['some'](_0xa48d92=>_0xa48d92));};_0x103e58['panelPosition']='sw',_0x103e58['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x1a5ea9});for(const _0x5a25bc of this['items'])_0x23dc36(_0x5a25bc);return _0x45bafe['add'](_0x3708b4),_0x103e58['listenTo'](this['items'],'add',(_0x18e3c1,_0x2e5c88,_0x3985de)=>{_0x23dc36(_0x2e5c88,_0x3985de);}),_0x103e58['listenTo'](this['items'],'remove',(_0x51216b,_0x31a1d6,_0x50b540)=>{_0x3708b4['items']['remove'](_0x50b540);}),_0x103e58;}['_attachActions'](_0x2196c6,_0xdb3db5){const _0x14f8a1=_0x2196c6&&_0x2196c6['element'];_0x14f8a1&&(this['listenTo'](_0x14f8a1,'mouseenter',()=>this['actionIndicator']=_0xdb3db5),this['listenTo'](_0x14f8a1,'focus',()=>this['actionIndicator']=_0xdb3db5),this['listenTo'](_0x14f8a1,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x14f8a1,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x22ce67=super['_createCommentInputView']();return _0x22ce67['bind']('placeholder')['to'](this),_0x22ce67;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x5ce390){const _0x2d1261=Dt(_0x5ce390,0x1e),_0x3e62b3=new MutationObserver(_0x8a8b30=>{for(const _0x5b5b07 of _0x8a8b30)('attributes'==_0x5b5b07['type']&&'class'==_0x5b5b07['attributeName']||'childList'==_0x5b5b07['type']||'characterData'==_0x5b5b07['type'])&&_0x2d1261();});return{'attach'(_0x3f5a36){_0x3e62b3['observe'](_0x3f5a36,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x3e62b3['disconnect'](),_0x2d1261['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x1f292e,_0x3e6516){super(_0x1f292e),this['id']=_0x47ab7a(),this['focusTracker']=new _0x5bef6f(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x42dcce,_0x463869)=>this['fire']('Esc',_0x463869)),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'](_0x3e6516),this['mainView']=_0x3e6516;const _0x40f9f6=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x40f9f6['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 _0x39878c=this['element']['clientHeight'];_0x39878c&&(this['height']=_0x39878c);}}class T extends/* #__PURE__ -- @preserve */
29
+ _0x344dd5(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x586bd4,target:_0x5430a5,type:_0xa11e4a,isVisible:_0x1aca9e=!0x0}){super(),this['view']=_0x586bd4,this['view']['element']||this['view']['render'](),this['_type']=_0xa11e4a,this['_target']=_0x5430a5,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x4654ca([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x1ccf97,_0x1afe48)=>{this['view']['focusTracker']['add'](_0x1afe48);}),this['focusableElements']['on']('remove',(_0x517d19,_0x3fd881)=>{this['view']['focusTracker']['remove'](_0x3fd881);}),this['set']('isVisible',_0x1aca9e);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x1aa4cf=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x1aa4cf),_0x1aa4cf;}get['targetRect'](){const _0x5a65d5=this['target'];if(null===_0x5a65d5)return null;if(_0x5a65d5 instanceof _0x49c6d0)return _0x5a65d5;const _0x18624c=_0x5a65d5['filter'](_0x4302a6=>function(_0x34d8ee){const _0x9da95e=_0x34d8ee['offsetParent'];if(_0x9da95e)return!0x0;const _0x3bb3f6=_0x34d8ee['getClientRects']()['item'](0x0);return!!_0x3bb3f6;}(_0x4302a6));return 0x0===_0x18624c['length']?null:new _0x49c6d0(_0x18624c[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0xe92552){this['view']['isActive']=_0xe92552,this['view']['mainView']['isActive']=_0xe92552;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x4653aa){if(!(null===_0x4653aa||_0x4653aa instanceof _0x49c6d0||Array['isArray'](_0x4653aa)&&_0x4653aa['every'](_0x295d86=>fi(_0x295d86))))throw new _0x5d7ae6('annotation-invalid-target',null,{'target':_0x4653aa});}['_getNormalizedTarget'](){const _0xa817b3='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0xa817b3)?[_0xa817b3]:_0xa817b3;}}function fi(_0x177ed4){return null!==_0x177ed4&&'object'==typeof _0x177ed4&&'nodeType'in _0x177ed4&&0x1===_0x177ed4['nodeType'];}class S extends _0x4654ca{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x4688b1=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x5bef6f(),this['_focusTracker']['on']('change:isFocused',(_0x7e080d,_0x3abf18,_0xc48b5)=>{_0xc48b5||this['fire']('blur');});for(const _0x4ca726 of _0x4688b1)this['add'](_0x4ca726);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x122159){if(this['has'](_0x122159))throw new _0x5d7ae6('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x122159['innerView'],_0x122159),this['_viewToAnnotation']['set'](_0x122159['view'],_0x122159);for(const _0x104869 of _0x122159['focusableElements'])this['_focusTracker']['add'](_0x104869);this['listenTo'](_0x122159['focusableElements'],'add',(_0x55f81c,_0x57171f)=>{this['_focusTracker']['add'](_0x57171f);}),this['listenTo'](_0x122159['focusableElements'],'remove',(_0x82b7c4,_0x3836aa)=>{this['_focusTracker']['remove'](_0x3836aa);}),this['listenTo'](_0x122159['view']['focusTracker'],'change:isFocused',(_0x388467,_0x2158ce,_0x40f9ca)=>{_0x40f9ca&&this['fire']('focus',_0x122159);}),_0x122159['updateTargetRect']();const _0x5ecb4a=this['_getOrderInContent'](_0x122159['view']['targetRect']);return super['add'](_0x122159,_0x5ecb4a);}['remove'](_0x25b350){if(!this['has'](_0x25b350))throw new _0x5d7ae6('annotationcollection-not-existing-item',null);this['stopListening'](_0x25b350['view']['focusTracker']),this['stopListening'](_0x25b350['focusableElements']);for(const _0x4a692f of _0x25b350['focusableElements'])this['_focusTracker']['remove'](_0x4a692f);return this['_viewToAnnotation']['delete'](_0x25b350['view']),this['_innerViewToAnnotation']['delete'](_0x25b350['innerView']),super['remove'](_0x25b350);}['getByInnerView'](_0x4c050e){return this['_innerViewToAnnotation']['get'](_0x4c050e);}['getByView'](_0x343464){return this['_viewToAnnotation']['get'](_0x343464);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x5725a8 of this)_0x5725a8['updateTargetRect']();this['_sort']();}['_sort'](){const _0x28e70d=Array['from'](this)['sort']((_0x2b7642,_0x2b2ebf)=>w(_0x2b7642['view']['targetRect'],_0x2b2ebf['view']['targetRect']));for(let _0x18c6ea=_0x28e70d['length']-0x1;_0x18c6ea>0x0;_0x18c6ea--){const _0x3c1f58=_0x28e70d[_0x18c6ea];_0x18c6ea!==this['getIndex'](_0x3c1f58)&&(this['remove'](_0x3c1f58),this['add'](_0x3c1f58));}}['_getOrderInContent'](_0x3a72cc){let _0x718d01=0x0;if(!_0x3a72cc)return this['length'];for(const _0x3d1856 of this){const _0x14a048=_0x3d1856['view']['targetRect'];if(_0x14a048){if(w(_0x3a72cc,_0x14a048)<0x0)return _0x718d01;_0x718d01++;}}return _0x718d01;}}function v({source:_0x459311,target:_0x3e9d23,filter:_0x2dae31}){for(const _0x25b5d2 of _0x459311)_0x2dae31(_0x25b5d2)&&_0x3e9d23['add'](_0x25b5d2);_0x3e9d23['listenTo'](_0x459311,'add',(_0xe99008,_0x78d579)=>{_0x2dae31(_0x78d579)&&_0x3e9d23['add'](_0x78d579);}),_0x3e9d23['listenTo'](_0x459311,'remove',(_0x20e309,_0x310236)=>{_0x3e9d23['has'](_0x310236)&&_0x3e9d23['remove'](_0x310236);});}function w(_0x59e233,_0x44121b){if(null===_0x59e233&&null===_0x44121b)return 0x0;if(null===_0x59e233)return-0x1;if(null===_0x44121b)return 0x1;const _0x482246=_0x59e233['top']-_0x44121b['top'];return 0x0==_0x482246?_0x59e233['left']-_0x44121b['left']:_0x482246;}class y extends _0x10fb5d{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x449cc2){if(super(_0x449cc2),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x449cc2 instanceof _0x20c4d1){const _0x1e79c9=_0x449cc2['locale'];_0x449cc2['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x1e79c9,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x3a0315){this['collection']['add'](_0x3a0315);}['remove'](_0x122889){this['collection']['remove'](_0x122889),_0x122889['destroy']();}['refreshVisibility'](){for(const _0x1840a0 of this['collection'])_0x1840a0['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x246a61){return this['collection']['getByInnerView'](_0x246a61);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x156865 of this['collection'])_0x156865['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x4ecf0b){this['fire']('_activateAnnotation',_0x4ecf0b);}['createAnnotation'](_0xbd7448){return new T(_0xbd7448);}['createAnnotationView'](_0xaee26b,_0x2cbae3){return new E(_0xaee26b,_0x2cbae3);}['_addActiveAnnotation'](_0x1ea1f3){const _0x4e090a=new Set(this['activeAnnotations']);_0x4e090a['add'](_0x1ea1f3),this['activeAnnotations']=_0x4e090a;}['_removeActiveAnnotation'](_0xcb96ce){const _0x377317=new Set(this['activeAnnotations']);_0x377317['delete'](_0xcb96ce),this['activeAnnotations']=_0x377317;}['_bindAnnotationsToVisibleAnnotations'](){const _0x3638da=this['collection'],_0x2fcde4=this['_visibleAnnotations'];function _0x4ec533(_0x17b3e9){const _0x25b6a3=_0x17b3e9['source'];_0x25b6a3['isVisible']&&!_0x2fcde4['has'](_0x25b6a3)?_0x2fcde4['add'](_0x25b6a3):!_0x25b6a3['isVisible']&&_0x2fcde4['has'](_0x25b6a3)&&_0x2fcde4['remove'](_0x25b6a3),_0x25b6a3['view']['focusTracker']['remove'](_0x25b6a3['view']['element']),_0x25b6a3['view']['focusTracker']['add'](_0x25b6a3['view']['element']);}this['listenTo'](_0x3638da,'add',(_0x37d397,_0x13376f)=>{_0x13376f['isVisible']&&_0x2fcde4['add'](_0x13376f),this['listenTo'](_0x13376f,'change:isVisible',_0x4ec533);}),this['listenTo'](_0x3638da,'remove',(_0x5c85e4,_0x392fea)=>{_0x2fcde4['has'](_0x392fea)&&_0x2fcde4['remove'](_0x392fea),this['stopListening'](_0x392fea,'change:isVisible',_0x4ec533);});}['_setupEnterAnnotationKeystroke'](){const _0x354406=_0x38fbc9=>{_0x38fbc9['on']('ready',()=>{_0x38fbc9['keystrokes']['set'](_0x27c044,(_0xd2841c,_0x590719)=>{const _0x1427c5=_0x426329(this['activeAnnotations']['values']());_0x1427c5&&(_0x1427c5['view']['focus'](),_0x590719());});});};this['context']instanceof _0x20c4d1?_0x354406(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x515ed2,_0x2f63fa)=>{_0x354406(_0x2f63fa);});}['_setupEscapeAnnotationHandling'](){const _0x5f4400=_0x10f53d=>{const _0x6241fe=_0x10f53d['source'],_0x353132=[];let _0x3134d0;if(Array['isArray'](_0x6241fe['target'])){_0x3134d0=_0x6241fe['target'][0x0],this['context']instanceof _0x20c4d1?_0x353132['push'](this['context']):this['context']['editors']&&_0x353132['push'](...this['context']['editors']);for(const _0x41e246 of _0x353132)for(const _0x14b872 of _0x41e246['editing']['view']['domRoots']['values']())if(_0x14b872['contains'](_0x3134d0))return void _0x41e246['editing']['view']['focus']();_0x3134d0['focus']();}};this['listenTo'](this['collection'],'add',(_0x431b67,_0x5c805b)=>{this['listenTo'](_0x5c805b,'escape',_0x5f4400,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x2dd381,_0x377b33)=>{this['stopListening'](_0x377b33,'escape',_0x5f4400);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x10fb5d{['_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(_0x1d04ed){super(_0x1d04ed),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x128405=this['context']['config'];_0x128405['define']('comments.maxCommentsWhenCollapsed',0x2),_0x128405['define']('comments.maxThreadTotalWeight',0x1f4),_0x128405['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x128405['define']('comments.CommentThreadView',gt),_0x128405['define']('comments.CommentView',Tt),_0x128405['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x8315ec=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x17c529,_0x5d8b61)=>this['_addCommentThread'](_0x5d8b61)),this['on']('submitCommentThread',(_0x4a25c0,_0x102bbb)=>this['_submitCommentThread'](_0x102bbb)),this['on']('resolveCommentThread',(_0x167da9,_0x3e5192)=>this['_resolveCommentThread'](_0x3e5192)),this['on']('resolveCommentThread',(_0x1a1cb7,_0x19ff46)=>this['_updateActiveAnnotation'](_0x19ff46),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x177b23,_0xe428aa)=>this['_reopenCommentThread'](_0xe428aa)),this['on']('reopenCommentThread',(_0x1507ae,_0x14cae5)=>this['_updateActiveAnnotation'](_0x14cae5),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x286515,_0x918eed)=>this['_removeCommentThread'](_0x918eed)),this['on']('updateCommentThread',(_0x52b906,_0x246c47)=>this['_updateCommentThread'](_0x246c47)),this['on']('updateCommentThread',(_0x1d2d60,_0x13059c)=>this['_updateActiveAnnotation'](_0x13059c),{'priority':'lowest'}),this['on']('addComment',(_0x54a5ab,_0x50c58d)=>this['_addComment'](_0x50c58d)),this['on']('updateComment',(_0x34f069,_0x18f9d)=>this['_updateComment'](_0x18f9d)),this['on']('removeComment',(_0x5f0688,_0xc59d45)=>this['_removeComment'](_0xc59d45)),this['on']('addComment',(_0x41dcdc,{threadId:_0x120ac6,isFromAdapter:_0x13d05e})=>{if(_0x13d05e)return;const _0x49cbab=this['getCommentThread'](_0x120ac6),_0x4a4151=_0x49cbab&&this['_threadToController']['get'](_0x49cbab);_0x4a4151&&_0x4a4151['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x8315ec,'change:activeAnnotations',(_0x2065a3,_0x10348b,_0x4443fd)=>{const _0x24e9b7=Array['from'](_0x4443fd)['map'](_0x303511=>this['_viewToController']['get'](_0x303511['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x24e9b7?_0x24e9b7['model']:null;});}set['adapter'](_0x3ca81b){if(this['_adapter'])throw new _0x5d7ae6('commentsrepository-adapter-already-set');this['_adapter']=_0x3ca81b;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x4a3312=_t,threadId:_0x18c310=_0x47ab7a(),comments:_0x521cc9=[],unlinkedAt:_0x56b981=null,resolvedAt:_0xc47300=null,resolvedBy:_0x2d9bd5=null,target:_0x258027=null,context:_0x3d816e=null,attributes:_0x30cba6={},isResolvable:_0x513d62=!0x0,isSubmitted:_0x444302=!0x1,isFromAdapter:_0x54c5f3=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x4a3312),{'channelId':_0x4a3312,'threadId':_0x18c310,'comments':_0x521cc9,'unlinkedAt':_0x56b981,'resolvedAt':_0xc47300,'resolvedBy':_0x2d9bd5,'target':_0x258027,'context':_0x3d816e,'attributes':_0x30cba6,'isFromAdapter':_0x54c5f3,'isResolvable':_0x513d62,'isSubmitted':_0x444302}),this['getCommentThread'](_0x18c310);}['openNewCommentThread']({channelId:_0x29e37c=_t,threadId:_0x56fb5e=_0x47ab7a(),target:_0x55cd04,context:_0x273755=null,isResolvable:_0x452066=!0x0}){if(this['_readOnlyChannels']['has'](_0x29e37c)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x55cd04)throw new _0x5d7ae6('commentsrepository-missing-target');const _0x1475ee=this['addCommentThread']({'channelId':_0x29e37c,'threadId':_0x56fb5e,'target':_0x55cd04,'context':_0x273755,'isResolvable':_0x452066});if(!_0x1475ee)return null;const _0x2b07db=this['_threadToController']['get'](_0x1475ee),_0x392ad8=_0x2b07db['view']['commentThreadInputView']['commentInputView'],_0x452d48=this['context']['plugins']['get'](y),_0x5ecae4=_0x452d48['getByInnerView'](_0x2b07db['view']);return _0x452d48['activate'](_0x5ecae4),_0x392ad8['once']('editorReady',()=>_0x392ad8['focus']()),_0x1475ee;}['hasCommentThread'](_0x3b992c){if('string'!=typeof _0x3b992c)throw new _0x5d7ae6('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x3b992c);}['updateCommentThread']({channelId:_0xa1bec7=_t,threadId:_0x47426d,context:_0x1cd900,unlinkedAt:_0x4f728c,attributes:_0x21c737,isFromAdapter:_0x35d50a=!0x1}){return this['fire'](Nt('updateCommentThread',_0xa1bec7),{'channelId':_0xa1bec7,'threadId':_0x47426d,'context':_0x1cd900,'unlinkedAt':_0x4f728c,'attributes':_0x21c737,'isFromAdapter':_0x35d50a}),this['getCommentThread'](_0x47426d);}['getCommentThread'](_0x46a320){if('string'!=typeof _0x46a320)throw new _0x5d7ae6('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x46a320);}['fetchCommentThread']({channelId:_0x196b6c,threadId:_0x47c6b6}={}){const _0x19b8dc=this['getCommentThread'](_0x47c6b6);if(_0x19b8dc)return Promise['resolve'](_0x19b8dc);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x5d7ae6('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x196b6c,'threadId':_0x47c6b6})['then'](_0x11eeff=>this['hasCommentThread'](_0x47c6b6)?this['getCommentThread'](_0x47c6b6):_0x11eeff?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x196b6c},_0x11eeff)):void 0x0)['catch'](_0x3423f0=>{throw console['error'](_0x3423f0),new _0x5d7ae6('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x58ffd5,skipNotAttached:_0x1d43f5=!0x1,skipEmpty:_0x596bd1=!0x1,toJSON:_0x3857b2=!0x1}={}){const _0x24fd65=[];for(const _0x2aa962 of this['_threads']['values']())_0x58ffd5&&_0x2aa962['channelId']!==_0x58ffd5||_0x1d43f5&&!_0x2aa962['isAttached']||_0x596bd1&&0x0===_0x2aa962['length']||_0x24fd65['push'](_0x2aa962);return _0x3857b2?_0x24fd65['map'](_0x2a01dd=>_0x2a01dd['toJSON']()):_0x24fd65;}['getAnnotationForCommentThread'](_0x34ab01){const _0x2dcfdb=this['_threadToController']['get'](_0x34ab01);if(!_0x2dcfdb)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x2dcfdb['view'])||null;}['getCommentThreadForAnnotation'](_0x32f11e){const _0x3de90d=this['_viewToController']['get'](_0x32f11e['innerView']);return _0x3de90d?_0x3de90d['model']:null;}['setActiveCommentThread'](_0x309640){const _0x3ea5ca=this['context']['plugins']['get'](y);if(!_0x309640)return void(this['activeCommentThread']&&_0x3ea5ca['deactivateAll']());const _0xf88ade=this['getCommentThread'](_0x309640);if(!_0xf88ade)throw new _0x5d7ae6('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x309640});if(!this['_threadToController']['has'](_0xf88ade))throw new _0x5d7ae6('commentsrepository-active-not-attached',null,{'threadId':_0x309640});const _0x2db899=_0x3ea5ca['getByInnerView'](this['_threadToController']['get'](_0xf88ade)['view']);_0x3ea5ca['activate'](_0x2db899);}['switchReadOnly'](_0x3e3020,_0x58b96e){_0x3e3020?this['_readOnlyChannels']['add'](_0x58b96e):this['_readOnlyChannels']['delete'](_0x58b96e),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x425f1){return this['_readOnlyChannels']['has'](_0x425f1)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x3868b7,_0x343773){return new vt(_0x3868b7,_0x343773);}['setPermissions'](_0x3d8b4a,_0x2a887a=_t){this['_permissions']['set'](_0x2a887a,_0x3d8b4a),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x98807f=_t){return this['_permissions']['has'](_0x98807f)?this['_permissions']['get'](_0x98807f):bt;}['_addCommentThread']({channelId:_0x6ff177,threadId:_0x27be90,comments:_0x173fce,unlinkedAt:_0xb48988,resolvedAt:_0x3982be,resolvedBy:_0x201d21,target:_0xa09826,context:_0x3b988f,attributes:_0xc1ca19,isFromAdapter:_0x3ff2cb,isResolvable:_0x91e885,isSubmitted:_0x54d85a}){if('string'!=typeof _0x27be90)throw new _0x5d7ae6('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x27be90});if(this['hasCommentThread'](_0x27be90))throw new _0x5d7ae6('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x27be90});const _0x5ee6fc=new pi(this,{'channelId':_0x6ff177,'id':_0x27be90,'context':_0x3b988f,'attributes':_0xc1ca19,'unlinkedAt':_0xb48988,'resolvedAt':_0x3982be,'resolvedBy':_0x201d21?this['context']['plugins']['get'](it)['getUser'](_0x201d21):null,'isResolvable':_0x91e885,'isSubmitted':_0x54d85a||_0x3ff2cb});this['_threads']['set'](_0x27be90,_0x5ee6fc);for(const _0x2f2dd8 of _0x173fce)_0x5ee6fc['_add'](this['_createNewComment']({'threadId':_0x27be90,..._0x2f2dd8}));return _0xa09826&&_0x5ee6fc['attachTo'](_0xa09826),_0x3ff2cb||!_0x5ee6fc['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x6ff177,'threadId':_0x27be90});}['_submitCommentThread']({channelId:_0x2073e9,threadId:_0x3bcaee}){if(!this['hasCommentThread'](_0x3bcaee))throw new _0x5d7ae6('commentsrepository-missing-comment-thread',this);const _0x4c4bac=this['getCommentThread'](_0x3bcaee);if(_0x4c4bac['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x38dcd9,comments:_0x1cb66a,resolvedAt:_0xce06e4,resolvedBy:_0x288a4c,context:_0xf1cd8a,attributes:_0x4cad46}=_0x4c4bac,_0xb0a293=this['context']['plugins']['get']('PendingActions'),_0x5c4e65=_0xb0a293['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x2073e9,'threadId':_0x38dcd9,'comments':_0x1cb66a['map'](_0x1eaa9b=>_0x1eaa9b['toJSON']()),'resolvedAt':_0xce06e4,'resolvedBy':_0x288a4c?_0x288a4c['id']:_0x288a4c,'context':_0xf1cd8a,'attributes':_0x4cad46})['then'](({comments:_0x19882b})=>{_0xb0a293['remove'](_0x5c4e65);for(const _0x366f1b of _0x19882b)this['_updateComment']({'channelId':_0x2073e9,'threadId':_0x3bcaee,'commentId':_0x366f1b['commentId'],'createdAt':_0x366f1b['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x51244c=>{throw console['error'](_0x51244c),new _0x5d7ae6('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x441d9b,target:_0x2a786b}){const _0x11e866=this['getCommentThread'](_0x441d9b);if(!_0x11e866)throw new _0x5d7ae6('commentsrepository-attach-missing-comment-thread',this);const _0x2ebbcc=this['context']['plugins']['get']('PendingActions'),_0x242e01=this['context']['plugins']['get'](y),_0xc2587c=this['_createCommentThreadView'](_0x11e866),_0x139efb=new vt(_0x11e866,_0xc2587c);let _0x31e917=null;_0xc2587c['on']('change:isDirty',(_0x72c7cc,_0xa5910f,_0xcb602)=>{_0xcb602?_0x31e917=_0x2ebbcc['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x31e917&&(_0x2ebbcc['remove'](_0x31e917),_0x31e917=null);}),this['_threadToController']['set'](_0x11e866,_0x139efb),this['_viewToController']['set'](_0xc2587c,_0x139efb);const _0x5d7db5=new E(this['context']['locale'],_0xc2587c);_0x5d7db5['bind']('length')['to'](_0xc2587c),_0x5d7db5['bind']('isDirty')['to'](_0xc2587c,'isDirty',_0xc2587c,'length',(_0x4d4af3,_0x10a05b)=>_0x4d4af3||!_0x10a05b),_0x5d7db5['bind']('isActive')['to'](_0xc2587c),_0x5d7db5['type']='comment';const _0x1a959f=new T({'view':_0x5d7db5,'target':_0x2a786b,'type':'comment','isVisible':!_0x11e866['archivedAt']&&!!('function'==typeof _0x2a786b?_0x2a786b():_0x2a786b)});return _0xc2587c['on']('escape',()=>{_0x1a959f['fire']('escape');}),this['_bindAnnotationToEditors'](_0xc2587c,_0x1a959f),_0x242e01['add'](_0x1a959f),_0x1a959f;}['_bindAnnotationToEditors'](_0x53fe6b,_0x560bf9){this['listenTo'](_0x53fe6b,'editorReady',(_0x5c1bff,_0x148b27)=>{const _0x223966=_0x148b27['ui']['view']['body']['bodyCollectionContainer'];_0x560bf9['focusableElements']['add'](_0x223966),this['context']instanceof _0x20c4d1&&this['context']['ui']['focusTracker']['add'](_0x223966);},{'priority':'highest'}),this['listenTo'](_0x53fe6b,'editorDestroyed',(_0x193ce3,_0x3c034a)=>{const _0x12b71b=_0x3c034a['ui']['view']['body']['bodyCollectionContainer'];_0x560bf9['focusableElements']['has'](_0x12b71b)&&_0x560bf9['focusableElements']['remove'](_0x12b71b),this['context']instanceof _0x20c4d1&&this['context']['ui']['focusTracker']['remove'](_0x12b71b);});}['_unbindEditors'](_0x254ba0){this['stopListening'](_0x254ba0,'editorReady'),this['stopListening'](_0x254ba0,'editorDestroyed');}['_createCommentThreadView'](_0x4b04bc){const _0x844214=this['context']['plugins']['get'](it),{config:_0x590565,locale:_0x4f7b53}=this['context'],_0x2746e5=pt(_0x590565['get']('locale'),_0x4f7b53);return new(0x0,(_0x590565['get']('comments'))['CommentThreadView'])(_0x4f7b53,_0x4b04bc,_0x844214['me'],{'editorConfig':{..._0x590565['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x590565['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x590565['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x590565['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x590565['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x2746e5,'CommentView':_0x590565['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x2a456f,channelId:_0x39f4d9,resolvedAt:_0x114bb4,resolvedBy:_0x510fe3,isFromAdapter:_0x2a88c7}){if(!this['hasCommentThread'](_0x2a456f))throw new _0x5d7ae6('commentsrepository-missing-comment-thread',null,{'threadId':_0x2a456f});const _0x25242d=this['getCommentThread'](_0x2a456f);if(_0x25242d['isResolved'])throw new _0x5d7ae6('commentsrepository-resolved-comment-thread',null,{'threadId':_0x2a456f});const _0x39f057=this['context']['plugins']['get'](it);if(_0x25242d['resolvedBy']=_0x39f057['getUser'](_0x510fe3),_0x25242d['resolvedAt']=_0x114bb4,_0x2a88c7||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x14e47f=this['context']['plugins']['get']('PendingActions'),_0x15b7d2=_0x14e47f['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x39f4d9,'threadId':_0x2a456f})['then'](({resolvedAt:_0x2ff5c9,resolvedBy:_0x451985})=>{_0x14e47f['remove'](_0x15b7d2),_0x25242d['resolvedBy']['id']!==_0x451985&&(_0x25242d['resolvedBy']=_0x39f057['getUser'](_0x451985)),_0x25242d['resolvedAt']=_0x2ff5c9;})['catch'](_0x1671d5=>{throw console['error'](_0x1671d5),new _0x5d7ae6('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x1b5e33,channelId:_0x2ef401,isFromAdapter:_0x321160}){if(!this['hasCommentThread'](_0x1b5e33))throw new _0x5d7ae6('commentsrepository-missing-comment-thread',null,{'threadId':_0x1b5e33});const _0x5e53df=this['getCommentThread'](_0x1b5e33);if(!_0x5e53df['isResolved'])throw new _0x5d7ae6('commentsrepository-reopen-comment-thread',null,{'threadId':_0x1b5e33});if(_0x5e53df['resolvedBy']=null,_0x5e53df['resolvedAt']=null,_0x321160||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x2c7ca5=this['context']['plugins']['get']('PendingActions'),_0x3a5aa1=_0x2c7ca5['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x2ef401,'threadId':_0x1b5e33})['then'](()=>_0x2c7ca5['remove'](_0x3a5aa1))['catch'](_0x5ddb91=>{throw console['error'](_0x5ddb91),new _0x5d7ae6('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x4a4c71,isFromAdapter:_0x14ae7e}){const _0x596984=this['getCommentThread'](_0x4a4c71);if(!_0x596984)throw new _0x5d7ae6('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x4a4c71),this['_threads']['delete'](_0x4a4c71),!_0x596984['isSubmitted']||_0x14ae7e||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x1d5ec9=this['context']['plugins']['get']('PendingActions'),{channelId:_0xe0a7fd}=_0x596984,_0xc73044=_0x1d5ec9['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0xe0a7fd,'threadId':_0x4a4c71})['then'](()=>_0x1d5ec9['remove'](_0xc73044))['catch'](_0xb4a55d=>{throw console['error'](_0xb4a55d),new _0x5d7ae6('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x1771dd,unlinkedAt:_0x2a6604,context:_0x125265,attributes:_0x4a178e,isFromAdapter:_0x232784}){if('string'!=typeof _0x1771dd)throw new _0x5d7ae6('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x1771dd});if(!this['hasCommentThread'](_0x1771dd))throw new _0x5d7ae6('commentsrepository-missing-comment-thread',null,{'threadId':_0x1771dd});const _0x3727f6=this['getCommentThread'](_0x1771dd);let _0x2608a5=!0x1;if(void 0x0!==_0x125265&&_0x3727f6['context']!==_0x125265&&(_0x3727f6['context']=_0x125265,_0x2608a5=!0x0),void 0x0!==_0x2a6604&&_0x3727f6['unlinkedAt']!==_0x2a6604&&(_0x3727f6['unlinkedAt']=_0x2a6604,_0x2608a5=!0x0),_0x4a178e&&!At(_0x4a178e,_0x3727f6['attributes'])&&(_0x3727f6['attributes']=_0x4a178e,_0x2608a5=!0x0),!_0x2608a5)return Promise['resolve']();if(!_0x3727f6['isSubmitted']||_0x232784||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x37de94=this['context']['plugins']['get']('PendingActions'),{channelId:_0x21abd5}=_0x3727f6,_0x29638d=_0x37de94['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x21abd5,'threadId':_0x1771dd,'context':_0x125265,'unlinkedAt':_0x2a6604,'attributes':_0x4a178e})['then'](()=>_0x37de94['remove'](_0x29638d))['catch'](_0x8b1d72=>{throw console['error'](_0x8b1d72),new _0x5d7ae6('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x29a1ba){const _0x5b1a0b=this['context']['plugins']['get'](y),_0x1f3db9=this['getCommentThread'](_0x29a1ba);if(_0x1f3db9['_isAttached']=!0x1,this['_threadToController']['has'](_0x1f3db9)){const _0xf985f6=this['_threadToController']['get'](_0x1f3db9),_0x462bb0=_0xf985f6['view'],_0x16da11=_0x5b1a0b['getByInnerView'](_0x462bb0);this['_threadToController']['delete'](_0x1f3db9),this['_viewToController']['delete'](_0x462bb0),_0x16da11&&_0x5b1a0b['remove'](_0x16da11),_0xf985f6['destroy'](),_0x462bb0['destroy']()['then'](()=>{this['_unbindEditors'](_0x462bb0);});}}['_updateActiveAnnotation']({threadId:_0x4caf54,resolvedAt:_0x6daa44,unlinkedAt:_0x1016ae}){const _0x25905f=!!_0x6daa44,_0x70db96=this['context']['plugins']['get'](y),_0x18f7cc=this['getCommentThread'](_0x4caf54);if(this['_threadToController']['has'](_0x18f7cc)){const _0x17fb6f=this['_threadToController']['get'](_0x18f7cc)['view'],_0x529dd5=_0x70db96['getByInnerView'](_0x17fb6f);_0x529dd5&&(_0x25905f&&_0x70db96['_removeActiveAnnotation'](_0x529dd5),_0x1016ae?_0x529dd5['isVisible']=!0x1:_0x529dd5['refreshVisibility']());}}['_getExternalAuthor'](_0x447b08){const _0x1a2cbb=this['context']['plugins']['get'](it),_0x5c79a8=It('external:'+_0x447b08),_0x38ecfc=_0x1a2cbb['getUser'](_0x5c79a8);return _0x38ecfc||_0x1a2cbb['addUser']({'id':_0x5c79a8,'name':_0x447b08});}['_createNewComment']({threadId:_0x14f181,commentId:_0xfd6e4c=_0x47ab7a(),content:_0x2db2e5,authorId:_0x320864,createdAt:_0x2e8953,attributes:_0xdf87cb}){if('string'!=typeof _0xfd6e4c)throw new _0x5d7ae6('commentsrepository-invalid-commentid');if('string'!=typeof _0x320864)throw new _0x5d7ae6('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x2db2e5||!_0x2db2e5['trim']())throw new _0x5d7ae6('commentsrepository-invalid-comment-content');const _0x184df8=this['context']['plugins']['get'](it)['getUser'](_0x320864);if(!_0x184df8)throw new _0x5d7ae6('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x320864});let _0x276463=null,_0x54b546=_0x2e8953;return _0xdf87cb?.['@external']&&(_0x276463=this['_getExternalAuthor'](_0xdf87cb['@external']['authorName']),_0x54b546=new Date(_0xdf87cb['@external']['createdAt'])),new wi(this,{'threadId':_0x14f181,'id':_0xfd6e4c,'author':_0x276463||_0x184df8,'creator':_0x184df8,'content':_0x2db2e5,'createdAt':_0x2e8953,'authoredAt':_0x54b546,'attributes':_0xdf87cb});}['_addComment'](_0x3a187f){let {threadId:_0x1b2ce1,content:_0x2016fc,attributes:_0x44c9bb,isFromAdapter:_0x48df26}=_0x3a187f;const _0x2dae48=this['getCommentThread'](_0x3a187f['threadId']);if(!_0x2dae48)throw new _0x5d7ae6('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x321103=this['_createNewComment'](_0x3a187f),{id:_0x170a6e}=_0x321103;if(_0x2dae48['_add'](_0x321103),_0x48df26||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x2dae48['isSubmitted'])return Promise['resolve']();const _0x3167a9=this['context']['plugins']['get']('PendingActions'),{channelId:_0x59bd74}=_0x2dae48,_0x1e19f8=_0x3167a9['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x44c9bb||(_0x44c9bb={}),this['adapter']['addComment']({'channelId':_0x59bd74,'threadId':_0x1b2ce1,'commentId':_0x170a6e,'content':_0x2016fc,'attributes':_0x44c9bb})['then'](_0x3e73b0=>{_0x3167a9['remove'](_0x1e19f8),_0x3e73b0&&this['_updateComment']({'channelId':_0x59bd74,'threadId':_0x1b2ce1,'commentId':_0x170a6e,'createdAt':_0x3e73b0['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x5ce981=>{throw console['error'](_0x5ce981),new _0x5d7ae6('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x356929,commentId:_0x3d34e6,content:_0x38ed98,createdAt:_0x69cd04,attributes:_0x3cc086,isFromAdapter:_0x3b71d9}){if(void 0x0!==_0x38ed98&&('string'!=typeof _0x38ed98||!_0x38ed98['trim']()['length']))throw new _0x5d7ae6('commentsrepository-update-comment-invalid-content');const _0xfcedee=this['getCommentThread'](_0x356929),_0x445918=_0xfcedee['getComment'](_0x3d34e6);if(!_0x445918)throw new _0x5d7ae6('commentsrepository-update-missing-comment',this);let _0x4812a6=!0x1;if(_0x38ed98&&_0x38ed98!==_0x445918['content']&&(_0x445918['isEditable']||_0x3b71d9)&&(_0x445918['content']=_0x38ed98,_0x4812a6=!0x0),_0x69cd04&&_0x69cd04!==_0x445918['createdAt']&&(_0x445918['createdAt']=_0x69cd04,_0x445918['attributes']&&_0x445918['attributes']['@external']||(_0x445918['authoredAt']=_0x69cd04),_0x4812a6=!0x0),_0x3cc086&&!At(_0x3cc086,_0x445918['attributes'])&&(_0x445918['attributes']=_0x3cc086,_0x4812a6=!0x0),!_0x4812a6)return Promise['resolve']();if(_0xfcedee['fire']('commentUpdated'),_0x3b71d9||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x465817=this['context']['plugins']['get']('PendingActions'),{channelId:_0x11aa5c}=this['getCommentThread'](_0x445918['threadId']),_0x49729a=_0x465817['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x11aa5c,'threadId':_0x356929,'commentId':_0x3d34e6,'content':_0x38ed98,'attributes':_0x3cc086})['then'](()=>_0x465817['remove'](_0x49729a))['catch'](_0x349dd7=>{throw console['error'](_0x349dd7),new _0x5d7ae6('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x3b2a49,commentId:_0x233935,isFromAdapter:_0x3d3f17}){const _0x1ad5d5=this['getCommentThread'](_0x3b2a49),_0x3afe53=_0x1ad5d5['getComment'](_0x233935);if(!_0x3afe53)throw new _0x5d7ae6('commentsrepository-remove-missing-comment',this);if(_0x1ad5d5['_remove'](_0x3afe53),_0x3d3f17||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x537639=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3f3eee}=_0x1ad5d5,_0x5aaa1d=_0x537639['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x3f3eee,'threadId':_0x3b2a49,'commentId':_0x233935})['then'](()=>_0x537639['remove'](_0x5aaa1d))['catch'](_0x23dcca=>{throw console['error'](_0x23dcca),new _0x5d7ae6('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
+ _0x344dd5(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x426456,_0x4b6899){super();const _0x34a51b=_0x4b6899['isResolvable'];this['channelId']=_0x4b6899['channelId'],this['id']=_0x4b6899['id'],this['comments']=new _0x4654ca(),this['_repository']=_0x426456,this['_isAttached']=!0x1,this['_isSubmitted']=_0x4b6899['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x426456,'_permissions',_0x426456,'_readOnlyChannels',()=>_0x426456['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x426456,'_permissions',()=>_0x426456['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x426456,'_permissions',()=>{const _0x542e84=_0x426456['getPermissions'](this['channelId']);return _0x542e84['write']||_0x542e84['admin'];}),this['bind']('isResolvable')['to'](_0x426456,'_permissions',()=>_0x34a51b&&_0x426456['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x4b6899['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x1e08f4,_0x28b4e7)=>_0x1e08f4?_0x28b4e7?_0x1e08f4<_0x28b4e7?_0x1e08f4:_0x28b4e7:_0x1e08f4:_0x28b4e7),this['set']('unlinkedAt',_0x4b6899['unlinkedAt']||null),this['set']('resolvedAt',_0x4b6899['resolvedAt']||null),this['set']('resolvedBy',_0x4b6899['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x47a62f=>!!_0x47a62f),this['set']('attributes',_0x4b6899['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x390f13,_0x5aeb7c)=>_0x390f13+_0x5aeb7c['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x3787a8,id:_0x44e89d}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x3787a8),{'channelId':_0x3787a8,'threadId':_0x44e89d});}['setUnlinkedAt'](_0x1ab87f){this['_update']({'unlinkedAt':_0x1ab87f});}['resolve']({resolvedAt:_0x1097ca=new Date(),resolvedBy:_0x370cfd='',isFromAdapter:_0x161058=!0x1}={}){const _0x228173=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x2a14bc,id:_0x4ece25}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x2a14bc),{'channelId':_0x2a14bc,'threadId':_0x4ece25,'resolvedAt':_0x1097ca,'resolvedBy':_0x370cfd||_0x228173['id'],'isFromAdapter':_0x161058});}['reopen']({isFromAdapter:_0x318809=!0x1}={}){const {channelId:_0x406429,id:_0x1b5e23}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x406429),{'channelId':_0x406429,'threadId':_0x1b5e23,'isFromAdapter':_0x318809});}['setContext'](_0x25943f){this['context']||this['_update']({'context':_0x25943f});}['setAttribute'](_0x3c98a,_0x45c3a8){const _0x4e82c9=wt(this['attributes']);yt(_0x4e82c9,_0x3c98a,_0x45c3a8),this['_update']({'attributes':_0x4e82c9});}['removeAttribute'](_0x13462a){const _0x55badc=wt(this['attributes']);Ct(_0x55badc,_0x13462a),this['_update']({'attributes':_0x55badc});}['remove']({isFromAdapter:_0x58b9a0=!0x1}={}){const {channelId:_0x48c387,id:_0x45603e}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x48c387),{'channelId':_0x48c387,'threadId':_0x45603e,'isFromAdapter':_0x58b9a0});}['attachTo'](_0x247afd){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x247afd});}['addComment'](_0x11b07e){const {channelId:_0x132310,id:_0x2f4381}=this;this['_repository']['fire'](Nt('addComment',_0x132310,_0x2f4381),Object['assign']({'channelId':_0x132310,'threadId':_0x2f4381},_0x11b07e));}['getComment'](_0x283e75){if('string'!=typeof _0x283e75)throw new _0x5d7ae6('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x283e75});return this['comments']['get'](_0x283e75);}['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'](_0x5ca250=>_0x5ca250['toJSON']()),'attributes':this['attributes']};}['_add'](_0x2ef281){return this['listenTo'](_0x2ef281,'change:authoredAt',()=>{const _0x4bbac8=this['_findOptimalIndex'](_0x2ef281),_0x166058=this['comments'];_0x4bbac8-0x1!=_0x166058['getIndex'](_0x2ef281)&&_0x4bbac8+0x1!=_0x166058['getIndex'](_0x2ef281)&&(this['_remove'](_0x2ef281),this['_add'](_0x2ef281));}),this['comments']['add'](_0x2ef281,this['_findOptimalIndex'](_0x2ef281));}['_update'](_0x359efa){const {channelId:_0x1eaea1,id:_0xc59545}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x1eaea1),{..._0x359efa,'channelId':_0x1eaea1,'threadId':_0xc59545});}['_remove'](_0x278e86){return this['stopListening'](_0x278e86),_0x278e86['destroy'](),this['comments']['remove'](_0x278e86);}['_findOptimalIndex'](_0x39e69e){const _0x1aa489=this['comments']['find'](_0x58fc86=>new Date(_0x58fc86['authoredAt'])['getTime']()>new Date(_0x39e69e['authoredAt'])['getTime']());return _0x1aa489?this['comments']['getIndex'](_0x1aa489):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
+ _0x344dd5(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x37e475,_0x550658){super();const _0x5beb95=_0x37e475['context']['plugins']['get'](it)['me'],_0x33365b=_0x37e475['getCommentThread'](_0x550658['threadId']),_0x199df5=0x0===_0x33365b['comments']['length'],_0x304adc=_0x5beb95===_0x550658['author'];this['id']=_0x550658['id'],this['threadId']=_0x550658['threadId'],this['author']=_0x550658['author'],this['creator']=_0x550658['creator'],this['isExternal']=Boolean(_0x550658['attributes']&&_0x550658['attributes']['@external']),this['set']('content',_0x550658['content']),this['createdAt']=_0x550658['createdAt']||new Date(),this['set']('authoredAt',_0x550658['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x33365b,'resolvedAt'),this['set']('attributes',_0x550658['attributes']||{}),this['bind']('isEditable')['to'](_0x37e475,'_permissions',()=>{const _0xdc0c50=_0x37e475['getPermissions'](_0x33365b['channelId'])['write'],_0x23f4c6=_0x37e475['getPermissions'](_0x33365b['channelId'])['modifyAll'];return _0x304adc&&_0xdc0c50||!_0x304adc&&_0x23f4c6;}),this['bind']('isRemovable')['to'](_0x33365b,'isRemovable',_0x37e475,'_permissions',_0xfbdf91=>{const _0x2bbed9=_0x37e475['getPermissions'](_0x33365b['channelId'])['write'],_0x513a42=_0x37e475['getPermissions'](_0x33365b['channelId'])['modifyAll'];return _0x304adc&&_0x2bbed9||_0xfbdf91&&_0x199df5||!_0x304adc&&_0x513a42&&!_0x199df5;}),this['bind']('isReadOnly')['to'](_0x33365b,'isReadOnly'),this['_repository']=_0x37e475;}get['weight'](){return Math['max'](function(_0x5eb456){const _0x15a3a3=document['createElement']('div');return _0x15a3a3['innerHTML']=_0x5eb456,_0x15a3a3['textContent']['length'];}(this['content']),0xc8);}['update'](_0x5beb7b){const {threadId:_0x33fb43,id:_0x16b6d1}=this;if(!this['_repository']['hasCommentThread'](_0x33fb43))throw new _0x5d7ae6('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x1ddc2c}=this['_repository']['getCommentThread'](_0x33fb43);this['_repository']['fire'](Nt('updateComment',_0x1ddc2c,_0x33fb43),{'channelId':_0x1ddc2c,'threadId':_0x33fb43,'commentId':_0x16b6d1,..._0x5beb7b});}['setAttribute'](_0x599797,_0x377a86){const _0x59cbfc=wt(this['attributes']);yt(_0x59cbfc,_0x599797,_0x377a86),this['update']({'attributes':_0x59cbfc});}['removeAttribute'](_0x1e4c84){const _0x532ee2=wt(this['attributes']);Ct(_0x532ee2,_0x1e4c84),this['update']({'attributes':_0x532ee2});}['remove'](_0x5330f1={}){if(!_0x5330f1['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x41d845,id:_0xc978}=this;if(!this['_repository']['hasCommentThread'](_0x41d845))throw new _0x5d7ae6('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x2cb4e2}=this['_repository']['getCommentThread'](_0x41d845);this['_repository']['fire'](Nt('removeComment',_0x2cb4e2,_0x41d845),{'channelId':_0x2cb4e2,'threadId':_0x41d845,'commentId':_0xc978,..._0x5330f1});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x700ec8,..._0x2e448f){for(const _0x5b6113 of _0x2e448f)void 0x0!==_0x5b6113&&(_0x700ec8+=':'+String(_0x5b6113));return _0x700ec8;}class ot extends _0x16c327{constructor(_0x58e4e8){super(_0x58e4e8),this['set']('hasContent',!0x1);}['refresh'](){const _0x5bcbe3=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x46d6fe of _0x5bcbe3['getRanges']())if(this['_hasContent'](_0x46d6fe))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x293106=_0x47ab7a(),ranges:_0x4d3b3d,comment:_0x15a621}={}){const _0x40627e=this['editor']['model'],_0x238dcf=_0x4d3b3d??Array['from'](_0x40627e['document']['selection']['getRanges']()),_0x4967e2=[];for(const _0x44ffea of _0x238dcf)this['_hasContent'](_0x44ffea)&&_0x4967e2['push'](this['_trimToContent'](_0x44ffea));if(!_0x4967e2['length'])throw new _0x5d7ae6('addcommentthreadcommand-incorrect-ranges',null);_0x15a621&&this['_createCommentThread'](_0x293106,_0x15a621),this['_createMarkersFromRanges'](_0x293106,_0x4967e2,!!_0x15a621);}['_createMarkersFromRanges'](_0x3806cf,_0x3fdecb,_0x164f49){this['editor']['model']['change'](_0x4c8ec6=>{for(const _0x11afb7 of _0x3fdecb){const _0x5f5560=_0x47ab7a()['substr'](0x1,0x5),_0x593c2f='comment:'+_0x3806cf+':'+_0x5f5560;_0x4c8ec6['addMarker'](_0x593c2f,{'range':_0x11afb7,'usingOperation':_0x164f49,'affectsData':_0x164f49});}});}['_createCommentThread'](_0x2eb2aa,_0x503b9e){const _0x4b1f4b=this['editor']['plugins']['get']('CommentsRepository'),_0x48bf46=this['editor']['config']['get']('collaboration.channelId'),_0x1af0c2=this['editor']['plugins']['get']('Users')['me'];if(!_0x1af0c2)throw new _0x5d7ae6('addcommentthreadcommand-user-not-found',null);_0x4b1f4b['addCommentThread']({'threadId':_0x2eb2aa,'channelId':_0x48bf46,'comments':[{'authorId':_0x1af0c2['id'],'content':_0x503b9e,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x54d9c6){for(const _0x577786 of _0x54d9c6['getItems']())if(this['_itemIsContent'](_0x577786))return!0x0;return!0x1;}['_itemIsContent'](_0x6aba1){return _0x6aba1['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x6aba1)&&!_0x6aba1['is']('element','tableCell');}['_trimToContent'](_0x344ae9){const _0x445ec1=_0x453711=>!this['_itemIsContent'](_0x453711['item']),_0x5af2bd=_0x344ae9['start']['getLastMatchingPosition'](_0x445ec1),_0x3fb4f8=_0x344ae9['end']['getLastMatchingPosition'](_0x445ec1,{'direction':'backward'});return this['editor']['model']['createRange'](_0x5af2bd,_0x3fb4f8);}}class b extends _0x57b43d{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1689be){super(_0x1689be),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x181516=this['editor'],_0x5764ba=_0x181516['model']['document']['selection'],_0x3322bc=_0x211bee(()=>this['refreshSelectedViews'](),0xa);_0x5764ba['on']('change:range',(_0x2b169b,_0x5a2e67)=>{_0x5a2e67['directChange']&&(_0x3322bc['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x181516['editing']['view']['document'],'change:isFocused',(_0x1e62a7,_0x570a9f,_0x2161ea)=>{_0x2161ea&&_0x3322bc();}),this['listenTo'](_0x181516['ui']['focusTracker'],'change:isFocused',(_0x47a89f,_0x25ebca,_0x4238bf)=>{_0x4238bf||this['fire']('blur',{'isAnnotationTracked':_0xd885c5=>this['_editorAnnotationsData']['has'](_0xd885c5['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x2d3adf){if(this['_editorAnnotations']['has'](_0x2d3adf['view']))return;this['_editorAnnotations']['add'](_0x2d3adf['view']),this['editor']['ui']['focusTracker']['add'](_0x2d3adf['view']['element']);const _0x214e73=this['editor']['plugins']['get'](y);this['listenTo'](_0x214e73['collection'],'remove',(_0x159328,_0x2001cb)=>{this['editor']['ui']['focusTracker']['remove'](_0x2001cb['view']['element']),this['_editorAnnotations']['delete'](_0x2001cb['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x3b4fad){if('function'!=typeof _0x3b4fad)throw new _0x5d7ae6('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x3b4fad);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x45f9e6,annotations:_0x384ca5}){const _0x17f56b=[],_0x46ae6f=this['editor']['model']['document']['selection'],_0x1ed6a4=Array['from'](_0x46ae6f['getRanges']());for(const [_0x22e8f0,_0x51db53]of this['_editorAnnotationsData']){const _0xa94697=_0x5855b2(_0x51db53),_0xa0aefa=_0x384ca5['getByInnerView'](_0x22e8f0);_0xa94697&&_0xa0aefa&&_0x17f56b['push']({'annotation':_0xa0aefa,'range':_0xa94697});}function _0x5855b2(_0x393aa4){for(const _0x544782 of _0x393aa4)for(const _0x5109b2 of _0x1ed6a4)if(_0x544782['containsRange'](_0x5109b2,!_0x46ae6f['isCollapsed']))return _0x544782;return null;}return _0x17f56b['sort']((_0xb11c72,_0x1ed11e)=>{const _0x3fd447=_0xb11c72['range'],_0x184e8b=_0x1ed11e['range'];if(!_0x3fd447['isEqual'](_0x184e8b)){if(_0x3fd447['containsRange'](_0x184e8b,!0x0))return 0x1;if(_0x184e8b['containsRange'](_0x3fd447,!0x0))return-0x1;}return _0xb11c72['annotation']==_0x45f9e6?-0x1:_0x1ed11e['annotation']==_0x45f9e6?0x1:0x0;})['map'](_0x5285f8=>_0x5285f8['annotation']);}get['_editorAnnotationsData'](){const _0x211526=new Map();for(const _0x1256be of Array['from'](this['_dataCollectors']))for(const [_0xc37190,_0x42d985]of _0x1256be())_0x211526['set'](_0xc37190,_0x42d985);return _0x211526;}}class st extends _0x57b43d{['afterInit'](){const _0x529a7a=this['editor'];if(!_0x529a7a['plugins']['has']('RestrictedEditingModeEditing'))return;_0x529a7a['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x57b43d{constructor(_0x25b092){super(_0x25b092),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x4cad3b=this['editor'],_0x3dc812=_0x4cad3b['commands']['get']('importWord'),_0x47c44b=_0x4cad3b['plugins']['get'](it);_0x3dc812&&(_0x3dc812['on']('execute',(_0x305710,[,_0x2f3dc8])=>{_0x2f3dc8['collaboration_features']={'comments':!0x0,'user_id':_0x47c44b['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x3dc812,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x5dba24,_0x3daabd){const {comment_threads:_0x52067d}=_0x3daabd;_0x52067d&&_0x52067d['forEach'](({thread_id:_0x341ad1,comments:_0x29e970,is_resolved:_0x1a241e})=>{const _0x45e018=new Date(),_0x50958e=_0x29e970['map'](({author:_0x50bf0c,content:_0x421744,created_at:_0x28f2d0})=>({'content':_0x421744,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x45e018,'attributes':{'@external':{'authorName':_0x50bf0c,'createdAt':_0x28f2d0?new Date(_0x28f2d0):new Date(),'source':'importWord'}}})),_0xf81e07=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0xf81e07,'threadId':_0x341ad1,'comments':_0x50958e,'resolvedAt':_0x1a241e?_0x45e018:null});});}}class at extends _0x57b43d{constructor(_0x5a6581){super(_0x5a6581),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x13560e=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x13560e,'contentInsertion',(_0xa3b391,_0x5b6072)=>this['_removeMarkersWithoutThreads'](_0x5b6072['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x8a1281){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x8a1281;const _0xe7025e=this['editor']['plugins']['get']('CommentsRepository');for(const _0xaed985 of _0x8a1281['keys']()){const [_0x5f1aaa,_0x46dc78]=_0xaed985['split'](':');'comment'!=_0x5f1aaa||_0xe7025e['hasCommentThread'](_0x46dc78)||_0x8a1281['delete'](_0xaed985);}return _0x8a1281;}['_registerMarkerInClipboardPipeline'](){const _0x1ba188=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x5a18ae=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x5a18ae&&_0x1ba188['_registerMarkerToCopy']('comment',_0x5a18ae);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x19aeea){switch(_0x19aeea){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0x496a6c){const _0xcd79ee=_0x496a6c['split'](':');return{'group':_0xcd79ee[0x0],'id':_0xcd79ee[0x1],'part':_0xcd79ee[0x2]};}class ut extends _0x57b43d{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x5c1c98,_0x1b9b9f)=>{if(!_0x1b9b9f['options']['showCommentHighlights'])return null;if(_0x1b9b9f['options']['ignoreResolvedComments']){const {id:_0x482778}=ft(_0x5c1c98['markerName']),_0x52cd2d=this['editor']['plugins']['get'](o);if(_0x52cd2d['getCommentThread'](_0x482778)?.['isResolved']&&_0x5c1c98['item'])return _0x1b9b9f['consumable']['consume'](_0x5c1c98['item'],'addMarker:'+_0x5c1c98['markerName']),_0x1b9b9f['consumable']['consume'](_0x5c1c98['item'],'removeMarker:'+_0x5c1c98['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2ea9b1=>{_0x2ea9b1['on']('addMarker:comment',(_0xe88b56,_0x28ad21,_0x4e80c3)=>{if(!_0x4e80c3['options']['showCommentHighlights'])return;const _0x5c36bd=_0x28ad21['item'];if(!_0x5c36bd)return;const _0x39d3dc=_0x4e80c3['mapper']['toViewElement'](_0x5c36bd);this['editor']['model']['schema']['isObject'](_0x5c36bd)&&_0x39d3dc&&!_0x39d3dc['getCustomProperty']('widget')&&_0x39d3dc['is']('containerElement')&&_0x5cc22c(_0x39d3dc,_0x4e80c3['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x3ab40b,{writer:_0x52cf9e,options:_0x2d47c2})=>{if(!_0x2d47c2['showCommentHighlights'])return null;const _0x997ab9=_0x52cf9e['createContainerElement']('div'),_0x31b7b1=_0x52cf9e['createEmptyElement']('hr');return _0x52cf9e['addClass']('ck-horizontal-line',_0x997ab9),_0x52cf9e['insert'](_0x52cf9e['createPositionAt'](_0x997ab9,0x0),_0x31b7b1),_0x997ab9;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0xf83e89,{writer:_0x2aaf62,options:_0x5613ed})=>{if(!_0x5613ed['showCommentHighlights'])return null;const _0xa9871c=_0x2aaf62['createContainerElement']('span'),_0x5af231=_0x2aaf62['createEmptyElement']('img');return _0x2aaf62['addClass']('image-inline',_0xa9871c),_0x2aaf62['insert'](_0x2aaf62['createPositionAt'](_0xa9871c,0x0),_0x5af231),_0xa9871c;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x1cc740,{writer:_0x3d2793,options:_0x42d05b})=>{if(_0x42d05b['showCommentHighlights'])return _0x3d2793['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x5dc491,_0x14c9b8,_0x42fd64)=>{_0x42fd64['options']['showCommentHighlights']&&_0x5dc491['stop']();},{'priority':'high'});}}class r extends _0x57b43d{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(_0x52432b){super(_0x52432b),this['set']('isThreadsLoadingPaused',!0x0),_0x52432b['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x27cb44,_0x5d6a3c,_0x5e21ea,_0x146af5)=>{const _0x120db6=_0x52432b['plugins']['get'](o),_0x25e9db=_0x5e21ea?ft(_0x5e21ea)['id']:null;_0x52432b['model']['change'](()=>{if(_0x25e9db){const _0x526d81=this['getAllMarkersForId'](_0x25e9db);for(const _0x28b000 of _0x526d81)_0x52432b['editing']['reconvertMarker'](_0x28b000);}if(_0x146af5){const {id:_0x340973}=ft(_0x146af5),_0x35db08=_0x120db6['getCommentThread'](_0x340973);if(_0x35db08&&_0x35db08['unlinkedAt'])return;if(_0x35db08&&!_0x35db08['isAttached'])return;const _0x399856=this['getAllMarkersForId'](_0x340973);for(const _0x160f54 of _0x399856)_0x52432b['editing']['reconvertMarker'](_0x160f54);}}),_0x25e9db&&this['scrollToThreadMarker'](_0x25e9db);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x3423e1=this['editor'],_0x9f8499=_0x3423e1['plugins']['get'](o),_0x55b7c8=_0x3423e1['config']['get']('collaboration.channelId'),_0x42a9ad=_0x9f8499['getCommentThreads']()['filter'](_0x49db17=>_0x49db17['channelId']!==_0x55b7c8);_0x3423e1['commands']['add']('addCommentThread',new ot(_0x3423e1)),this['listenTo'](_0x3423e1,'change:isReadOnly',(_0x56eaa4,_0x4e9c16,_0x2247a3)=>{_0x9f8499['switchReadOnly'](_0x2247a3,_0x3423e1['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x9f8499,dt('addCommentThread',_0x55b7c8),(_0x46ce44,{threadId:_0xbb1ff8})=>{const _0x5448a7=this['editor']['plugins']['get'](o)['getCommentThread'](_0xbb1ff8);_0x5448a7?.['unlinkedAt']&&this['_attachArchivedThread'](_0xbb1ff8);}),this['listenTo'](_0x9f8499,dt('removeCommentThread',_0x55b7c8),(_0x4ebf5d,{threadId:_0x54cce7})=>{_0x3423e1['model']['enqueueChange']({'isUndoable':!0x1},_0x4a987d=>{const _0x3054c1=this['getAllMarkersForId'](_0x54cce7);for(const _0x3a7e3c of _0x3054c1)_0x4a987d['removeMarker'](_0x3a7e3c);});}),this['listenTo'](_0x9f8499,dt('resolveCommentThread',_0x55b7c8),(_0x13d4cb,{threadId:_0x12de6c})=>{(this['_reconvertMarkers'](_0x12de6c),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x12de6c)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x9f8499,dt('reopenCommentThread',_0x55b7c8),(_0x5f5c57,{threadId:_0x21f0e7})=>{this['_reconvertMarkers'](_0x21f0e7);},{'priority':'low'}),this['listenTo'](_0x9f8499,dt('addComment',_0x55b7c8),(_0x4fdae5,{threadId:_0x2a7b0f,isFromAdapter:_0x2ca5b3})=>{const _0x5a1aaf=this['getAllMarkersForId'](_0x2a7b0f);if(_0x2ca5b3||0x0==_0x5a1aaf['length']||!_0x9f8499['hasCommentThread'](_0x2a7b0f))return;0x1===_0x9f8499['getCommentThread'](_0x2a7b0f)['length']&&_0x3423e1['model']['enqueueChange']({'isUndoable':!0x1},_0x580200=>{for(const _0x115bb7 of _0x5a1aaf)_0x580200['updateMarker'](_0x115bb7,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x42a9ad);}['afterInit'](){!async function(_0x14ecd8){const _0x3b629a=_0x338f15([0x4b,0x70,0x4f,0x42,0x4a,0x47,0x4e,0x53,0x45,0x67,0x71,0x43,0x79,0x66,0x56,0x46,0x31,0x6b,0x5a,0x38,0x6c,0x62,0x6e,0x52,0x6a,0x4d,0x37,0x65,0x49,0x7a,0x41,0x73,0x44,0x51,0x48,0x77,0x39,0x61,0x54,0x68,0x75,0x36,0x72,0x63,0x59,0x69,0x30,0x35,0x55,0x6d,0x50,0x4c,0x34,0x64,0x33,0x58,0x32,0x57,0x6f,0x74,0x76,0x78]),_0x304211=0x73460ab3,_0x4f1f66=0x73417ed3^_0x304211,_0x4d6865=window[_0x338f15([0x44,0x61,0x74,0x65])][_0x338f15([0x6e,0x6f,0x77])](),_0x84aae9=_0x14ecd8[_0x338f15([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x18f159=new window[(_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x36a6f8=>{_0x84aae9[_0x338f15([0x6f,0x6e,0x63,0x65])](_0x338f15([0x72,0x65,0x61,0x64,0x79]),_0x36a6f8);}),_0x4b3b68={[_0x338f15([0x6b,0x74,0x79])]:_0x338f15([0x45,0x43]),[_0x338f15([0x75,0x73,0x65])]:_0x338f15([0x73,0x69,0x67]),[_0x338f15([0x63,0x72,0x76])]:_0x338f15([0x50,0x2d,0x32,0x35,0x36]),[_0x338f15([0x78])]:_0x338f15([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]),[_0x338f15([0x79])]:_0x338f15([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]),[_0x338f15([0x61,0x6c,0x67])]:_0x338f15([0x45,0x53,0x32,0x35,0x36])},_0x46130c=_0x84aae9[_0x338f15([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x338f15([0x67,0x65,0x74])](_0x338f15([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x26ac0e(){let _0x35eed0,_0x451557=null,_0x1b09ed=null;try{if(_0x46130c==_0x338f15([0x47,0x50,0x4c]))return _0x338f15([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x35eed0=_0xcc5707(),!_0x35eed0)return _0x338f15([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x35eed0[_0x338f15([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1b09ed=_0x1cf313(_0x35eed0[_0x338f15([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x35eed0[_0x338f15([0x6a,0x74,0x69])])),await _0xcb0c7c()?_0x5e8be9()?_0x52c4e2()?_0x338f15([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x992b54()?(_0x35eed0[_0x338f15([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x338f15([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x451557=_0xc9a474(_0x338f15([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x35eed0[_0x338f15([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x338f15([0x74,0x72,0x69,0x61,0x6c])&&(_0x451557=_0xc9a474(_0x338f15([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0xbead5d()):_0x338f15([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x338f15([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x338f15([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x338f15([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x52c4e2(){const _0x5b928b=[_0x338f15([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x338f15([0x74,0x72,0x69,0x61,0x6c])][_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x35eed0[_0x338f15([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4d6865/0x3e8:0xe10*_0x4f1f66;return _0x35eed0[_0x338f15([0x65,0x78,0x70])]<_0x5b928b;}function _0x5e8be9(){const _0x1775f2=_0x35eed0[_0x338f15([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1775f2)return!0x1;if(_0x1775f2[_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x338f15([0x2a])))return!0x0;if(_0x1775f2[_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x338f15([0x43,0x4d,0x54])))return!0x0;if(_0x1775f2[_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x338f15([0x54,0x52,0x49,0x4c,0x49,0x55,0x4d]))&&_0x1ea896())return!0x0;if(_0x1775f2[_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x338f15([0x52,0x43,0x4d,0x54]))){if(_0x3af371())return!0x0;if(_0x40ff8d()||_0x29c322())return!0x0;}return!0x1;}function _0x992b54(){const _0xc9112d=_0x35eed0[_0x338f15([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xc9112d||0x0==_0xc9112d[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3bb06f}=new URL(window[_0x338f15([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xc9112d[_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3bb06f))return!0x0;const _0x40ff75=_0x3bb06f[_0x338f15([0x73,0x70,0x6c,0x69,0x74])](_0x338f15([0x2e]));return _0xc9112d[_0x338f15([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x52e3f9=>_0x52e3f9[_0x338f15([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x338f15([0x2a])))[_0x338f15([0x6d,0x61,0x70])](_0x1c6512=>_0x1c6512[_0x338f15([0x73,0x70,0x6c,0x69,0x74])](_0x338f15([0x2e])))[_0x338f15([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3625cd=>_0x3625cd[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x40ff75[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x338f15([0x6d,0x61,0x70])](_0x1ccb9b=>Array(_0x40ff75[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x1ccb9b[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x338f15([0x66,0x69,0x6c,0x6c])](_0x1ccb9b[0x0]===_0x338f15([0x2a])?_0x338f15([0x2a]):'')[_0x338f15([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x1ccb9b))[_0x338f15([0x73,0x6f,0x6d,0x65])](_0x4026b0=>_0x40ff75[_0x338f15([0x65,0x76,0x65,0x72,0x79])]((_0x17b8a0,_0x30f90f)=>_0x4026b0[_0x30f90f]===_0x17b8a0||_0x4026b0[_0x30f90f]===_0x338f15([0x2a])));}function _0xbead5d(){return _0x451557&&_0x1b09ed?new window[(_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x32587b,_0x5bce8c)=>{_0x451557[_0x338f15([0x74,0x68,0x65,0x6e])](_0x32587b,_0x5bce8c),_0x1b09ed[_0x338f15([0x74,0x68,0x65,0x6e])](_0x1d23cc=>{_0x1d23cc!=_0x338f15([0x56,0x61,0x6c,0x69,0x64])&&_0x32587b(_0x1d23cc);},_0x5bce8c);}):_0x451557||_0x1b09ed||_0x338f15([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1cf313(_0x45e623,_0x247993){return new window[(_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xc5ca57=>{if(_0x3ac190())return _0xc5ca57(_0x338f15([0x56,0x61,0x6c,0x69,0x64]));_0x454820(),_0x84aae9[_0x338f15([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x338f15([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0xb64f29=!0x1;const _0x5149b2=_0x47ab7a();function _0x3ae8f8(_0x2da1a2){return!!_0x2da1a2&&(typeof _0x2da1a2===_0x338f15([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2da1a2===_0x338f15([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2da1a2[_0x338f15([0x74,0x68,0x65,0x6e])]===_0x338f15([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2da1a2[_0x338f15([0x63,0x61,0x74,0x63,0x68])]===_0x338f15([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x435893(_0x2144b1){_0xfe64ac(_0x2144b1)[_0x338f15([0x74,0x68,0x65,0x6e])](_0x3c03ef=>{if(!_0x3c03ef||_0x3c03ef[_0x338f15([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x338f15([0x6f,0x6b]))return _0x338f15([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x147bb2(_0x1fba05(_0x5149b2+_0x247993))!=_0x3c03ef[_0x338f15([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x338f15([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x338f15([0x56,0x61,0x6c,0x69,0x64]);})[_0x338f15([0x74,0x68,0x65,0x6e])](_0x4e1cfb=>(_0x425293(),_0x4e1cfb),()=>{const _0x26d58c=_0x130d5d();return null==_0x26d58c?(_0x425293(),_0x338f15([0x56,0x61,0x6c,0x69,0x64])):_0x338f15(_0x4d6865-_0x26d58c>(0x574a8eb3^_0x304211)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x338f15([0x74,0x68,0x65,0x6e])](_0xc5ca57)[_0x338f15([0x63,0x61,0x74,0x63,0x68])](()=>{_0xc5ca57(_0x338f15([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3da393=0x7370e433^_0x304211;function _0x425293(){const _0x6ea01f=_0x338f15([0x6c,0x6c,0x63,0x74,0x2d])+_0x147bb2(_0x1fba05(_0x45e623)),_0x5156e0=_0x1d6e2e(_0x147bb2(window[_0x338f15([0x4d,0x61,0x74,0x68])][_0x338f15([0x63,0x65,0x69,0x6c])](_0x4d6865/_0x3da393)));window[_0x338f15([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x338f15([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x6ea01f,_0x5156e0);}function _0x130d5d(){const _0x585f5c=_0x338f15([0x6c,0x6c,0x63,0x74,0x2d])+_0x147bb2(_0x1fba05(_0x45e623)),_0x1d043b=window[_0x338f15([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x338f15([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x585f5c);return _0x1d043b?window[_0x338f15([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d6e2e(_0x1d043b),0x10)*_0x3da393:null;}function _0xfe64ac(_0x3c253c){return new window[(_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5d7ff9,_0x4e9d82)=>{_0x3c253c[_0x338f15([0x74,0x68,0x65,0x6e])](_0x5d7ff9,_0x4e9d82),window[_0x338f15([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4e9d82,0x7347de73^_0x304211);});}}_0x84aae9[_0x338f15([0x6f,0x6e])](_0x338f15([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3b69be,_0x567068)=>{if(_0x567068[0x0]!=_0x45e623)return _0xc5ca57(_0x338f15([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x567068[0x1]={..._0x567068[0x1],[_0x338f15([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5149b2};},{[_0x338f15([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x338f15([0x68,0x69,0x67,0x68])}),_0x84aae9[_0x338f15([0x6f,0x6e])](_0x338f15([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x151016=>{_0x3ae8f8(_0x151016[_0x338f15([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0xb64f29=!0x0,_0x435893(_0x151016[_0x338f15([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x338f15([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x338f15([0x6c,0x6f,0x77])}),_0x18f159[_0x338f15([0x74,0x68,0x65,0x6e])](()=>{_0xb64f29||_0xc5ca57(_0x338f15([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3ac190(){return _0x84aae9[_0x338f15([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x338f15([0x76,0x69,0x65,0x77])][_0x338f15([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x338f15([0x61,0x75,0x74,0x6f]);}function _0x454820(){_0x84aae9[_0x338f15([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x338f15([0x76,0x69,0x65,0x77])][_0x338f15([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x338f15([0x61,0x75,0x74,0x6f]);}}function _0xc9a474(_0x31e18f){const _0x115b35=[new window[(_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x13f801=>setTimeout(_0x13f801,0x734f347f^_0x304211)),_0x18f159[_0x338f15([0x74,0x68,0x65,0x6e])](()=>new window[(_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4d0778=>{let _0x408196=0x0;_0x84aae9[_0x338f15([0x6d,0x6f,0x64,0x65,0x6c])][_0x338f15([0x6f,0x6e])](_0x338f15([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x397f31,_0x548f84)=>{_0x548f84[0x0][_0x338f15([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x408196++,_0x408196==(0x73460b4b^_0x304211)&&(_0x4d0778(),_0x397f31[_0x338f15([0x6f,0x66,0x66])]());});}))];return window[_0x338f15([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x338f15([0x72,0x61,0x63,0x65])](_0x115b35)[_0x338f15([0x74,0x68,0x65,0x6e])](()=>_0x31e18f);}async function _0x69baf7(){await _0x18f159,_0x84aae9[_0x338f15([0x6d,0x6f,0x64,0x65,0x6c])][_0x338f15([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2a5feb,_0x84aae9[_0x338f15([0x6d,0x6f,0x64,0x65,0x6c])][_0x338f15([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2a5feb,_0x84aae9[_0x338f15([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x338f15([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1ea896(){return window[_0x338f15([0x67,0x6c,0x6f,0x62])]&&window[_0x338f15([0x67,0x6c,0x6f,0x62])][_0x338f15([0x74,0x72,0x69,0x6c,0x69,0x75,0x6d,0x56,0x65,0x72,0x73,0x69,0x6f,0x6e])];}function _0x3af371(){return _0x33e47b(_0x338f15([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x356982(_0x338f15([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x338f15([0x73,0x74,0x61,0x74,0x65])]==_0x338f15([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x40ff8d(){return _0x33e47b(_0x338f15([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 _0x29c322(){return _0x33e47b(_0x338f15([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2252d9(_0x5c5c66){const _0x13aa6a=_0x59cab5();_0x84aae9[_0x13aa6a]=_0x338f15([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x5c5c66,_0x5c5c66!=_0x338f15([0x56,0x61,0x6c,0x69,0x64])&&_0x69baf7();}function _0x59cab5(){const _0x307e0b=window[_0x338f15([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x338f15([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x338f15([0x6e,0x6f,0x77])]())[_0x338f15([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x338f15([0x2e]),'');let _0x1dfa59=_0x338f15([0x4b]);for(let _0x2d6373=0x0;_0x2d6373<_0x307e0b[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2d6373+=0x2){let _0x1b3516=window[_0x338f15([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x307e0b[_0x338f15([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2d6373,_0x2d6373+0x2));_0x1b3516>=_0x3b629a[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1b3516-=_0x3b629a[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1dfa59+=_0x3b629a[_0x1b3516];}return _0x1dfa59;}function _0xcc5707(){const _0x1c6199=_0x46130c[_0x338f15([0x73,0x70,0x6c,0x69,0x74])](_0x338f15([0x2e]));if(0x3!=_0x1c6199[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4db0e9(_0x1c6199[0x1]);function _0x4db0e9(_0x362917){const _0x2a088c=_0xd2c195(_0x362917);return _0x2a088c&&_0x3b563b()?_0x2a088c:null;function _0x3b563b(){const _0x4121a8=_0x2a088c[_0x338f15([0x6a,0x74,0x69])],_0x41f5d6=window[_0x338f15([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4121a8[_0x338f15([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4121a8[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xd07272={..._0x2a088c,[_0x338f15([0x6a,0x74,0x69])]:_0x4121a8[_0x338f15([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4121a8[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xd07272[_0x338f15([0x76,0x63])],_0x1fba05(_0xd07272)==_0x41f5d6;}}}async function _0xcb0c7c(){let _0x14a3a6=!0x0;try{const _0x47c9ed=_0x46130c[_0x338f15([0x73,0x70,0x6c,0x69,0x74])](_0x338f15([0x2e])),[_0x4049e7,_0x24b146,_0x48e65a]=_0x47c9ed;return _0xbf5ba1(_0x4049e7),await _0x50299e(_0x4049e7,_0x24b146,_0x48e65a),_0x14a3a6;}catch{return!0x1;}function _0xbf5ba1(_0x3193b4){const _0x51f0ce=_0xd2c195(_0x3193b4);_0x51f0ce&&_0x51f0ce[_0x338f15([0x61,0x6c,0x67])]==_0x338f15([0x45,0x53,0x32,0x35,0x36])||(_0x14a3a6=!0x1);}async function _0x50299e(_0x40e5fc,_0x4ca229,_0xf7a175){const _0x57986c=window[_0x338f15([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x338f15([0x66,0x72,0x6f,0x6d])](_0x36511b(_0xf7a175),_0x48a41a=>_0x48a41a[_0x338f15([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x357daf=new window[(_0x338f15([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x338f15([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x40e5fc+_0x338f15([0x2e])+_0x4ca229),_0x411995=window[_0x338f15([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x338f15([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x411995)return;const _0x13edb3=await _0x411995[_0x338f15([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x338f15([0x6a,0x77,0x6b]),_0x4b3b68,{[_0x338f15([0x6e,0x61,0x6d,0x65])]:_0x338f15([0x45,0x43,0x44,0x53,0x41]),[_0x338f15([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x338f15([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x338f15([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x411995[_0x338f15([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x338f15([0x6e,0x61,0x6d,0x65])]:_0x338f15([0x45,0x43,0x44,0x53,0x41]),[_0x338f15([0x68,0x61,0x73,0x68])]:{[_0x338f15([0x6e,0x61,0x6d,0x65])]:_0x338f15([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x13edb3,_0x57986c,_0x357daf)||(_0x14a3a6=!0x1);}}function _0xd2c195(_0x307905){return _0x307905[_0x338f15([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x338f15([0x65,0x79]))?JSON[_0x338f15([0x70,0x61,0x72,0x73,0x65])](_0x36511b(_0x307905)):null;}function _0x36511b(_0x4010c3){return window[_0x338f15([0x61,0x74,0x6f,0x62])](_0x4010c3[_0x338f15([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x338f15([0x2b]))[_0x338f15([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x338f15([0x2f])));}function _0x1fba05(_0x4632f7){let _0x376bd0=0x1505;function _0x569677(_0x1765fc){for(let _0x101f38=0x0;_0x101f38<_0x1765fc[_0x338f15([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x101f38++){const _0x5e74a5=_0x1765fc[_0x338f15([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x101f38);_0x376bd0=(_0x376bd0<<0x5)+_0x376bd0+_0x5e74a5,_0x376bd0&=_0x376bd0;}}function _0x5527ff(_0x2d5fa6){Array[_0x338f15([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2d5fa6)?_0x2d5fa6[_0x338f15([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5527ff):_0x2d5fa6&&typeof _0x2d5fa6==_0x338f15([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x338f15([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2d5fa6)[_0x338f15([0x73,0x6f,0x72,0x74])]()[_0x338f15([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1e0471,_0x395df3])=>{_0x569677(_0x1e0471),_0x5527ff(_0x395df3);}):_0x569677(window[_0x338f15([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2d5fa6));}return _0x5527ff(_0x4632f7),_0x376bd0>>>0x0;}function _0x147bb2(_0x5f266a){return _0x5f266a[_0x338f15([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x338f15([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x338f15([0x30]));}function _0x1d6e2e(_0x20c8e8){return _0x20c8e8[_0x338f15([0x73,0x70,0x6c,0x69,0x74])]('')[_0x338f15([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x338f15([0x6a,0x6f,0x69,0x6e])]('');}function _0x33e47b(_0x5005c7){return _0x84aae9[_0x338f15([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x338f15([0x68,0x61,0x73])](_0x5005c7);}function _0x356982(_0x22c255){return _0x84aae9[_0x338f15([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x338f15([0x67,0x65,0x74])](_0x22c255);}function _0x2a5feb(){}function _0x338f15(_0x15ec2c){return _0x15ec2c['map'](_0x3131ac=>String['fromCharCode'](_0x3131ac))['join']('');}_0x2252d9(await _0x26ac0e());}(this);}['destroy'](){const _0x571a5b=this['editor']['plugins']['get'](o),_0x5a23c9=this['editor']['config']['get']('collaboration.channelId');for(const _0x1ddbd6 of _0x571a5b['getCommentThreads']({'channelId':_0x5a23c9}))_0x571a5b['_detachCommentThread'](_0x1ddbd6['id']),_0x571a5b['_threads']['delete'](_0x1ddbd6['id']);super['destroy']();}['hasMarkerForId'](_0x461488){return this['getAllMarkersForId'](_0x461488)['length']>0x0;}['getAllMarkersForId'](_0x524a34){const _0xeaf7e2=[];for(const _0x553d0e of this['editor']['model']['markers'])_0x553d0e['name']['startsWith']('comment:'+_0x524a34)&&_0xeaf7e2['push'](_0x553d0e);return _0xeaf7e2;}['scrollToThreadMarker'](_0x375fb0){setTimeout(()=>{const _0x26c57d=this['_getTargetForId'](_0x375fb0);if(!_0x26c57d)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x375fb0&&nt({'target':_0x26c57d[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x1bd7e5){this['editor']['model']['change'](()=>{for(const _0x2bebae of this['getAllMarkersForId'](_0x1bd7e5))this['editor']['editing']['reconvertMarker'](_0x2bebae);});}['_attachArchivedThread'](_0x2f1b90){const _0x3a14a2=this['editor']['plugins']['get'](o),_0x4ead9c=this['editor']['plugins']['get'](b),_0x2c7686=_0x3a14a2['getCommentThread'](_0x2f1b90);if(!_0x2c7686['isAttached']){const _0x1f3e49=_0x2c7686['attachTo'](()=>this['_getTargetForId'](_0x2c7686['id']));_0x4ead9c['registerAnnotation'](_0x1f3e49),_0x2c7686['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x209c24=this['editor'],_0x43a052=_0x209c24['plugins']['get'](it);_0x209c24['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x27e02d,_0x23d382)=>{const {id:_0x4ab7d5}=ft(_0x27e02d['markerName']),_0x2a1a13=_0x209c24['plugins']['get'](o)['getCommentThread'](_0x4ab7d5),_0x534276=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x4ab7d5;let _0x31e8f2;if(_0x2a1a13&&_0x2a1a13['isResolved']&&!_0x534276&&_0x27e02d['item'])return _0x23d382['consumable']['consume'](_0x27e02d['item'],'addMarker:'+_0x27e02d['markerName']),_0x23d382['consumable']['consume'](_0x27e02d['item'],'removeMarker:'+_0x27e02d['markerName']),null;const _0x952e4c=['ck-comment-marker'];return _0x534276&&_0x952e4c['push']('ck-comment-marker--active'),_0x31e8f2=_0x2a1a13?.['length']?_0x2a1a13['comments']['first']['author']['id']:_0x43a052['me']['id'],{'classes':_0x952e4c,'attributes':{'data-comment':_0x4ab7d5,'data-author-id':_0x31e8f2}};}}),_0x209c24['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x37fd78,{options:_0x46985d})=>{if(_0x46985d['showCommentHighlights'])return null;const _0x4e702e=_0x209c24['plugins']['get'](o),_0x7e3db5=_0x209c24['model']['markers']['get'](_0x37fd78),{id:_0x1e5239,part:_0x34c59d}=ft(_0x37fd78);return _0x7e3db5&&!_0x7e3db5['affectsData']||_0x46985d['ignoreResolvedComments']&&_0x4e702e['getCommentThread'](_0x1e5239)?.['isResolved']?null:{'group':'comment','name':_0x34c59d?_0x1e5239+':'+_0x34c59d:_0x1e5239};}}),_0x209c24['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x1dc998,{writer:_0x23948c})=>_0x23948c['createElement']('$marker',{'data-name':'comment:'+_0x1dc998['getAttribute']('id')})}),_0x209c24['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x9a919=this['editor'],_0x33e62f=_0x9a919['plugins']['get'](o),_0x2947fe=new Set(),_0x5d7321=new Set();_0x9a919['model']['document']['registerPostFixer'](_0x564d9e=>{let _0x1b3d0e=!0x1;for(const {name:_0x2c85fa,data:_0xc5fbce}of _0x9a919['model']['document']['differ']['getChangedMarkers']()){const {group:_0xfca47c,id:_0xe0521d}=ft(_0x2c85fa);let _0x45b19c=_0xc5fbce['newRange'];if('comment'!==_0xfca47c||!_0x45b19c)continue;const _0x55f795='$graveyard'===_0x45b19c['root']['rootName'];_0x55f795||(_0x45b19c=ht(_0x45b19c,_0x9a919['model']),!_0x45b19c||_0x45b19c['isCollapsed']||!_0xc5fbce['newRange']||_0x45b19c['isEqual'](_0xc5fbce['newRange']))?_0x9a919['model']['hasContent'](_0x45b19c)&&!_0x55f795?this['isThreadsLoadingPaused']?_0x2947fe['add'](_0x2c85fa):this['_handleThreadMarker'](_0x2c85fa,_0xe0521d):(_0x5d7321['add'](_0x2c85fa),_0x2947fe['delete'](_0x2c85fa),_0x564d9e['removeMarker'](_0x2c85fa),_0x1b3d0e=!0x0):(_0x564d9e['updateMarker'](_0x2c85fa,{'range':_0x45b19c}),_0x1b3d0e=!0x0);}return _0x1b3d0e;}),this['on']('change:isThreadsLoadingPaused',(_0x118407,_0x53b16a,_0x15ecc3)=>{if(!_0x15ecc3&&_0x2947fe['size'])for(const _0x24d27e of _0x2947fe){const {id:_0x40936a}=ft(_0x24d27e);_0x2947fe['delete'](_0x24d27e),_0x9a919['model']['markers']['get'](_0x24d27e)&&this['_handleThreadMarker'](_0x24d27e,_0x40936a);}}),this['listenTo'](_0x9a919['model']['document'],'change',()=>{for(const {name:_0x468b9c,data:{newRange:_0x5df915}}of _0x9a919['model']['document']['differ']['getChangedMarkers']()){const {group:_0xeb972f,id:_0x5d070d}=ft(_0x468b9c);if('comment'!==_0xeb972f)continue;const _0x4a8d3e=_0x33e62f['getCommentThread'](_0x5d070d),_0x393c72=this['hasMarkerForId'](_0x5d070d);_0x4a8d3e&&(!_0x4a8d3e['_hasTargetInContent']&&_0x5df915&&_0x9a919['editing']['view']['once']('render',()=>{const _0x47edf0=_0x9a919['plugins']['get'](y),_0x2c067d=_0x33e62f['_threadToController']['get'](_0x4a8d3e)['view'];_0x47edf0['getByInnerView'](_0x2c067d)['refreshVisibility']();},{'priority':'low'}),_0x4a8d3e['_hasTargetInContent']=_0x393c72||!!_0x5df915),_0x5df915||(_0x5d7321['add'](_0x468b9c),_0x2947fe['delete'](_0x468b9c));}for(const _0x3a8542 of _0x5d7321){const {id:_0x14bf8a}=ft(_0x3a8542),_0x45512d=_0x33e62f['getCommentThread'](_0x14bf8a);if(_0x2947fe['delete'](_0x3a8542),!_0x45512d)continue;const _0x5866cc=this['hasMarkerForId'](_0x14bf8a);_0x5866cc||_0x45512d['isSubmitted']?_0x5866cc||_0x45512d['unlinkedAt']||_0x45512d['setUnlinkedAt'](new Date()):_0x45512d['remove']();}_0x5d7321['clear']();});}['_handleInitialThreads'](_0x52f0e2){_0x52f0e2['forEach'](_0x285268=>{_0x285268['unlinkedAt']&&this['_attachArchivedThread'](_0x285268['id']);});}['_getTargetForId'](_0x2f8843){const _0x28700d=this['editor'],_0x34d1ac=this['getAllMarkersForId'](_0x2f8843);return et(_0x28700d['editing'],_0x34d1ac);}['_getTextContext'](_0x219bc6){const _0x3a30e8=this['getAllMarkersForId'](_0x219bc6);let _0xb1506c='',_0xf1d338=!0x1;for(const _0x3cbde4 of _0x3a30e8){const _0x48e9d2=_0x3cbde4['getRange']();for(const _0x2e276c of Array['from'](_0x48e9d2['getItems']()))_0x2e276c['is']('$textProxy')?(_0xb1506c&&_0xf1d338&&(_0xb1506c+='\x20',_0xf1d338=!0x1),_0xb1506c+=_0x2e276c['data']):_0xf1d338=!0x0;_0xf1d338=!0x0;}return _0xb1506c['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x2c2637,_0x29a54e){const _0x46e7c8=this['editor'],_0x51b307=_0x46e7c8['plugins']['get'](o);let _0xc80da2=_0x51b307['getCommentThread'](_0x29a54e);const _0x1637f9=_0x46e7c8['config']['get']('collaboration.channelId'),_0x3e7588=_0x46e7c8['plugins']['get'](b);if(_0xc80da2&&(_0xc80da2['unlinkedAt']&&_0xc80da2['setUnlinkedAt'](null),_0xc80da2['isAttached']))return _0xc80da2;return!this['getAllMarkersForId'](_0x29a54e)[0x0]['managedUsingOperations']?_0x46e7c8['editing']['view']['once']('render',()=>{if(_0x51b307['getCommentThread'](_0x29a54e))return;const _0x3e2988=_0x46e7c8['plugins']['get'](y);_0xc80da2=_0x51b307['openNewCommentThread']({'channelId':_0x1637f9,'threadId':_0x29a54e,'target':()=>this['_getTargetForId'](_0x29a54e),'context':{'type':'text','value':this['_getTextContext'](_0x29a54e)}});const _0x1e82a8=_0x51b307['_threadToController']['get'](_0xc80da2)['view'],_0x580f3b=_0x3e2988['getByInnerView'](_0x1e82a8);_0x580f3b&&_0x3e7588['registerAnnotation'](_0x580f3b);},{'priority':'low'}):_0x51b307['fetchCommentThread']({'channelId':_0x1637f9,'threadId':_0x29a54e})['then'](_0x501a84=>{if('destroyed'!==_0x46e7c8['state']){if(_0xc80da2=_0x501a84,_0xc80da2&&!_0xc80da2['isAttached']){const _0x47e8d4=_0xc80da2['attachTo'](()=>this['_getTargetForId'](_0x29a54e));_0x3e7588['registerAnnotation'](_0x47e8d4),_0xc80da2['isResolved']&&this['_reconvertMarkers'](_0x29a54e);}else{if(!_0xc80da2){const _0x1e3e10=this['getAllMarkersForId'](_0x29a54e);_0x46e7c8['model']['change'](_0x3e2e1b=>{for(const _0x175a4b of _0x1e3e10)_0x3e2e1b['removeMarker'](_0x175a4b);});}}}}),_0xc80da2;}['_handleThreadMarker'](_0x563b75,_0x592310){const _0x4600f3=this['_attachMarkerToThread'](_0x563b75,_0x592310);_0x4600f3&&!_0x4600f3['context']&&_0x4600f3['setContext']({'type':'text','value':this['_getTextContext'](_0x592310)});}['_initAriaMarkerChangeAnnouncements'](){const _0x5ae3aa=this['editor'];rt(_0x5ae3aa['model'],({left:_0x1264f3,entered:_0x179b61})=>{for(const _0xc87904 of _0x1264f3)if(mt(_0xc87904)){_0x5ae3aa['ui']['ariaLiveAnnouncer']['announce'](N(_0x5ae3aa['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x384de8 of _0x179b61)if(mt(_0x384de8)){_0x5ae3aa['ui']['ariaLiveAnnouncer']['announce'](N(_0x5ae3aa['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x3fa6bd)));break;}});}}function dt(_0x4545d1,_0x4e186d){return _0x4e186d?_0x4545d1+':'+_0x4e186d:_0x4545d1;}function ht(_0x122e1a,_0x3d88de){const _0x3deed0=_0x3d88de['schema'],_0x2722d2=_0x3d88de['createRange'](_0x122e1a['start']);for(const _0x51965e of _0x122e1a['getWalker']()){const {type:_0x548d41,item:_0x2db7da,nextPosition:_0x5902ef}=_0x51965e;if('text'===_0x548d41||_0x3deed0['isObject'](_0x2db7da)){const _0x2f10d1=_0x3d88de['createPositionBefore'](_0x2db7da);_0x2722d2['isCollapsed']&&(_0x2722d2['start']=_0x2f10d1),_0x2722d2['end']=_0x5902ef;}}return _0x2722d2;}function mt(_0x3b08c0){return'comment'===ft(_0x3b08c0['name'])['group'];}class s extends _0x57b43d{['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 _0x3691cf=this['editor'],_0x15c679=_0x3691cf['plugins']['get'](o),_0x3ea36c=_0x3691cf['plugins']['get'](r),_0x5ddd4a=_0x3691cf['plugins']['get'](y),_0xd4473d=_0x3691cf['plugins']['get'](b);_0x3691cf['ui']['componentFactory']['add']('comment',()=>{const _0x44b7c9=this['_createUIButton'](_0x49decf);return _0x44b7c9['tooltip']=!0x0,_0x44b7c9;}),_0x3691cf['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x28f235)),_0xd4473d['addSourceCollector'](()=>{const _0x5f4d81=[];for(const [_0x35740d,_0x17d763]of _0x15c679['_threadToController']){const _0x23865b=_0x3ea36c['getAllMarkersForId'](_0x35740d['id']),_0x4c4c4b=_0x23865b['map'](_0x36e746=>_0x36e746['getRange']());_0x23865b['length']>0x0&&_0x5f4d81['push']([_0x17d763['view'],_0x4c4c4b]);}return _0x5f4d81;}),this['listenTo'](_0x5ddd4a,'change:activeAnnotations',(_0x599fc0,_0x4e3a24,_0x15af8c)=>{const _0x2eea1a=Array['from'](_0x15af8c)['map'](_0xf1996c=>_0xf1996c['innerView'])['find'](_0x5a3aaa=>_0x15c679['_viewToController']['has'](_0x5a3aaa));if(!_0x2eea1a)return void(_0x3ea36c['activeMarker']=null);const _0x5f4d95=_0x15c679['_viewToController']['get'](_0x2eea1a)['model']['id'],_0x2fabb0='comment:'+_0x5f4d95;_0x5f4d95&&_0x3ea36c['hasMarkerForId'](_0x5f4d95)?_0x3ea36c['activeMarker']=_0x2fabb0:_0x3ea36c['activeMarker']&&(_0x3ea36c['activeMarker']=null);}),this['listenTo'](_0x15c679,'removeCommentThread',(_0x33d0b1,{threadId:_0x10a878,isFromAdapter:_0x56e422})=>{!_0x56e422&&_0x3691cf['ui']['focusTracker']['isFocused']&&_0x3ea36c['hasMarkerForId'](_0x10a878)&&_0x3691cf['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x15c679,'addComment',(_0x136129,{threadId:_0x4da186,isFromAdapter:_0x2e059f})=>{if(_0x2e059f||!_0x3ea36c['hasMarkerForId'](_0x4da186)||!_0x15c679['hasCommentThread'](_0x4da186))return;0x1===_0x15c679['getCommentThread'](_0x4da186)['length']&&(_0x3691cf['editing']['view']['focus'](),_0x136129['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2986a6=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x7139a5;for(const _0x1c1679 in _0x2986a6){const _0x4bdf44=_0x1c1679,_0x5657a8=_0x2986a6[_0x4bdf44];if('commentsLicenseKeyValid'==_0x5657a8||'commentsLicenseKeyInvalid'==_0x5657a8||'commentsLicenseKeyExpired'==_0x5657a8||'commentsLicenseKeyDomainLimit'==_0x5657a8||'commentsLicenseKeyNotAllowed'==_0x5657a8||'commentsLicenseKeyEvaluationLimit'==_0x5657a8||'commentsLicenseKeyTrialLimit'==_0x5657a8||'commentsLicenseKeyUsageLimit'==_0x5657a8){delete _0x2986a6[_0x4bdf44],_0x7139a5=_0x5657a8,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x7139a5&&_0x2986a6['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x7139a5&&_0x2986a6['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x7139a5&&_0x2986a6['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x7139a5&&_0x2986a6['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x7139a5&&_0x2986a6['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x7139a5&&_0x2986a6['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x7139a5&&_0x2986a6['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x472883){const _0x5ae35a=this['editor'],_0x334960=new _0x472883(_0x5ae35a['locale']),_0x43bac6=_0x5ae35a['commands']['get']('addCommentThread');return _0x334960['set']({'label':N(_0x5ae35a['locale'],'Comment'),'icon':_0x25afc1}),_0x334960['bind']('isEnabled')['to'](_0x43bac6,'hasContent'),this['listenTo'](_0x334960,'execute',()=>{_0x43bac6['execute']();}),_0x334960;}}class i extends _0x57b43d{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x418f1c){super(_0x418f1c),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x537c6e,_0x242e2e,_0x52f8e7)=>{_0x52f8e7?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x45f517,_0x4afb00]of this['editor']['commands'])_0x4afb00['affectsData']&&'addCommentThread'!==_0x45f517&&_0x4afb00['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 _0x150896=this['editor']['editing']['view']['document'];this['listenTo'](_0x150896,'cut',_0x16f023=>_0x16f023['stop'](),{'priority':'highest'}),this['listenTo'](_0x150896,'clipboardInput',_0x1c675b=>_0x1c675b['stop'](),{'priority':'highest'}),this['listenTo'](_0x150896,'delete',_0x5aa329=>_0x5aa329['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x347ee4,_0x491294]of this['editor']['commands'])_0x491294['affectsData']&&'addCommentThread'!==_0x347ee4&&_0x491294['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 _0x10fb5d{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1562b8){super(_0x1562b8),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x36bf4f=this['context']['plugins']['get'](y);this['listenTo'](_0x36bf4f,'_activateAnnotation',(_0x3405e9,_0x2bce61)=>{for(const _0x1548c9 of this['activeUIs']){const _0x110eeb=this['_uis']['get'](_0x1548c9);(0x0,this['uisData']['get'](_0x1548c9)['filter'])(_0x2bce61)&&_0x110eeb['setActiveAnnotation'](_0x2bce61);}}),this['listenTo'](_0x36bf4f,'_deactivateAllAnnotations',()=>{for(const _0x3f66cd of this['activeUIs']){this['_uis']['get'](_0x3f66cd)['setActiveAnnotation'](null);}}),this['listenTo'](_0x36bf4f['_visibleAnnotations'],'add',(_0x1c54ab,_0x1c15d1)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x1c15d1);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0xddef40){return this['activeUIs']['has'](_0xddef40);}['activate'](_0x22eadf,_0x143dfe=this['defaultFilter']){const _0x4838f0=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x22eadf))throw new _0x5d7ae6('annotationsuis-missing-ui',this,{'uiName':_0x22eadf});this['isActive'](_0x22eadf)&&this['deactivate'](_0x22eadf),this['activeUIs']['add'](_0x22eadf);const _0x24e221=new S();v({'source':_0x4838f0['_visibleAnnotations'],'target':_0x24e221,'filter':_0x143dfe}),this['uisData']['set'](_0x22eadf,{'collection':_0x24e221,'filter':_0x143dfe});const _0x577a35=this['_uis']['get'](_0x22eadf);_0x577a35['attach'](_0x24e221),this['listenTo'](_0x577a35,'change:activeAnnotation',(_0x57c455,_0x502700,_0x4eb537,_0x1efd92)=>{_0x1efd92&&_0x4838f0['_removeActiveAnnotation'](_0x1efd92),_0x4eb537&&_0x4838f0['_addActiveAnnotation'](_0x4eb537);});}['deactivate'](_0x2d2cfd){if(this['activeUIs']['delete'](_0x2d2cfd),!this['_uis']['has'](_0x2d2cfd))throw new _0x5d7ae6('annotationsuis-missing-ui',this,{'uiName':_0x2d2cfd});const _0x3f644e=this['_uis']['get'](_0x2d2cfd);_0x3f644e['detach'](),this['stopListening'](_0x3f644e),this['uisData']['get'](_0x2d2cfd)['collection']['destroy'](),this['uisData']['delete'](_0x2d2cfd);}['switchTo'](_0x19a771){if(!this['_uis']['has'](_0x19a771))throw new _0x5d7ae6('annotationsuis-missing-ui',this,{'uiName':_0x19a771});const _0x2bd4d1=this['context']['plugins']['get'](y),_0x74f732=Array['from'](_0x2bd4d1['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x19a771);const _0x54af39=this['_uis']['get'](_0x19a771);_0x54af39['setActiveAnnotation'](_0x74f732),_0x54af39['_setSelectedAnnotations']&&_0x74f732&&_0x54af39['_setSelectedAnnotations']([_0x74f732]);}['deactivateAll'](){for(const _0x415f29 of this['activeUIs'])this['deactivate'](_0x415f29);}['register'](_0x131cb6,_0x1dab6a){if(this['_uis']['has'](_0x131cb6))throw new _0x5d7ae6('annotationsuis-register-already-registered');if('function'!=typeof _0x1dab6a['attach']||'function'!=typeof _0x1dab6a['detach']||'function'!=typeof _0x1dab6a['setActiveAnnotation'])throw new _0x5d7ae6('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x131cb6,_0x1dab6a);}['refilterAnnotations'](){const _0x525cdc=this['context']['plugins']['get'](y)['collection'],_0x4b05df=new Map(),_0x3de9a4=Array['from'](this['activeUIs']);for(const _0x37e0fa of this['activeUIs']){const _0x398a11=this['uisData']['get'](_0x37e0fa)['collection'];for(const _0x513875 of _0x398a11)_0x4b05df['set'](_0x513875,_0x37e0fa);}for(const _0x5eae9f of _0x525cdc){const _0x11df0b=_0x4b05df['get'](_0x5eae9f);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x5eae9f);const _0xabec3b=_0x3de9a4['find'](_0x484846=>this['uisData']['get'](_0x484846)['filter'](_0x5eae9f));_0x11df0b!==_0xabec3b&&(_0x11df0b&&this['uisData']['get'](_0x11df0b)['collection']['remove'](_0x5eae9f),_0xabec3b&&this['uisData']['get'](_0xabec3b)['collection']['add'](_0x5eae9f));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0xdefc08){const _0xe3b773=[];for(const _0x89a41e of this['activeUIs']){(0x0,this['uisData']['get'](_0x89a41e)['filter'])(_0xdefc08)&&_0xe3b773['push'](_0x89a41e);}if(_0xe3b773['length']>0x1)throw new _0x5d7ae6('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0xe3b773,'annotationType':_0xdefc08['type']});}}const _i=/* #__PURE__ -- @preserve */
32
+ Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x2770a0){super(_0x2770a0);const _0xfad73=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 _0x5bef6f(),this['focusCycler']=new _0x3b0d1d({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0xfad73['to']('class')],'style':{'minHeight':_0xfad73['to']('minHeight',_0x7c5dce=>'number'==typeof _0x7c5dce?_i(_0x7c5dce+0xa):null)},'dir':_0x2770a0['uiLanguageDirection'],'role':'application','aria-label':N(_0x2770a0,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x2770a0,'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',_0x2b7fe2=>{this['_updateItemPositionInFocusables'](_0x2b7fe2['source']);}),this['list']['forEach'](_0xf92b3=>{this['focusTracker']['add'](_0xf92b3['element']),this['_updateItemPositionInFocusables'](_0xf92b3);}),this['list']['on']('change',(_0x40becd,_0x33043b)=>{for(const _0x297557 of _0x33043b['removed'])this['focusTracker']['remove'](_0x297557['element']),this['focusables']['remove'](_0x297557);for(const _0x16e4cc of _0x33043b['added'])this['focusTracker']['add'](_0x16e4cc['element']),this['_updateItemPositionInFocusables'](_0x16e4cc);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x2cf529){const _0x2f5735=this['focusables']['getIndex'](_0x2cf529);let _0x375e0d,_0x22278e;for(const _0xa84736 of this['focusables'])if(_0x2cf529['top']<_0xa84736['top']){_0x375e0d=_0xa84736;break;}if(_0x22278e=_0x375e0d?this['focusables']['getIndex'](_0x375e0d):this['focusables']['length'],-0x1!==_0x2f5735){if(_0x2f5735===_0x22278e-0x1)return;this['focusables']['remove'](_0x2cf529),_0x22278e=_0x375e0d?this['focusables']['getIndex'](_0x375e0d):this['focusables']['length'];}this['focusables']['add'](_0x2cf529,_0x22278e);}}const Ot=/* #__PURE__ -- @preserve */
33
+ Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x1dd528){super(_0x1dd528),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x163463,_0x2fae36)=>_0x163463+_0x2fae36),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x517549=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x517549['to']('isAnimationDisabled',_0x41e80c=>_0x41e80c?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x517549['to']('top',_0x46da09=>Ot(_0x46da09))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x370395=this['element']['clientHeight'];_0x370395&&(this['height']=_0x370395);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x10fb5d{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3eda4e){super(_0x3eda4e),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 _0x4ea8b3=this['context']['config']['get']('sidebar.container');_0x4ea8b3&&this['setContainer'](_0x4ea8b3);}['setContainer'](_0x2df7e4){if(!g(_0x2df7e4))throw new _0x5d7ae6('sidebar-setcontainer-invalid-element');this['container']=_0x2df7e4;}['_attachToContainer']({viewClass:_0x27e2f4='',spaceBetweenItems:_0x3cb348=0x19}={}){if(!g(this['container']))throw new _0x5d7ae6('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x27e2f4,this['_spaceBetweenItems']=_0x3cb348;}['rearrange']({removedAnnotation:_0x1b654d,previousAnnotation:_0x468c47,nextAnnotation:_0x2d2091}){const _0x119097=this['getSidebarItemView'](_0x1b654d);this['view']['list']['remove'](_0x119097),this['_destroySidebarItemView'](_0x1b654d),_0x468c47&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x468c47)),_0x2d2091&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x2d2091)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x17f78e,activatedAnnotation:_0x1b0ec6,disableAnimationOnActivatedAnnotation:_0xad5794}){if(this['_activeAnnotation']=_0x1b0ec6,_0x17f78e){_0x17f78e['isActive']=!0x1;const _0x3a425b=this['getSidebarItemView'](_0x17f78e);_0x3a425b&&_0xad5794&&(_0x3a425b['isAnimationDisabled']=!0x1);}if(_0x1b0ec6){const _0x47fc19=this['getSidebarItemView'](_0x1b0ec6);_0x47fc19&&(_0x1b0ec6['isActive']=!0x0,_0xad5794&&(_0x47fc19['isAnimationDisabled']=!0x0,_0x47fc19['top']+=0x1),this['_alignToTargetRect'](_0x47fc19));}}['_detachFromContainer'](_0x1c312d){if(this['view']['element']['remove'](),_0x1c312d){for(const _0x232172 of _0x1c312d)this['_destroySidebarItemView'](_0x232172);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x2071b0,_0x2e9960){_0x2e9960||(_0x2e9960=_0x2071b0['view']);const _0x491931=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x491931,_0x2071b0),this['_annotationToSidebarItemView']['set'](_0x2071b0,_0x491931),_0x491931['content']['add'](_0x2e9960),this['listenTo'](_0x2071b0['view'],'change:targetRect',(_0xed4d90,_0x1da58c,_0x50cc5d)=>{const _0x4467e0=this['_getTargetTop'](_0x2071b0,_0x50cc5d);_0x491931['_targetTop']!=_0x4467e0&&(_0x491931['_targetTop']=_0x4467e0,this['_setItemTop'](_0x491931,_0x4467e0));}),this['listenTo'](_0x491931,'change:top',()=>{this['_recalculate'](_0x491931,'top');}),this['listenTo'](_0x491931,'change:bottom',()=>{this['_recalculate'](_0x491931,'bottom');}),this['_alignToTargetRect'](_0x491931);const _0x1e9a65=this['_getItemBefore'](_0x491931);if(_0x1e9a65)this['_alignAfterItem'](_0x1e9a65,_0x491931)||this['_alignToTargetRect'](_0x491931);else this['_alignToTargetRect'](_0x491931);return this['_updateLastItem'](),this['view']['list']['add'](_0x491931),_0x491931;}['_alignForTopChange'](_0x133126){if(!_0x133126['content']['length'])return;const _0x1bd40=this['_getItemBefore'](_0x133126);if(!_0x1bd40)return;const _0x4b076e=this['_sidebarItemViewToAnnotation']['get'](_0x1bd40),_0x4cf1ac=this['_activeAnnotation'];_0x4cf1ac&&_0x4cf1ac===_0x4b076e?this['_alignAfterItem'](_0x1bd40,_0x133126):this['_alignBeforeItem'](_0x133126,_0x1bd40);}['_alignForBottomChange'](_0x17990f){if(!_0x17990f['content']['length'])return;const _0x51f365=this['_getItemAfter'](_0x17990f);if(!_0x51f365)return;const _0x330dbd=this['_sidebarItemViewToAnnotation']['get'](_0x51f365),_0x57e3dc=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x86e91c=this['_activeAnnotation'];_0x86e91c&&_0x86e91c===_0x330dbd&&_0x57e3dc?(this['_alignBeforeItem'](_0x51f365,_0x17990f),this['_alignAfterItem'](_0x17990f,_0x51f365)):_0x86e91c&&_0x86e91c===_0x330dbd?this['_alignBeforeItem'](_0x51f365,_0x17990f):this['_alignAfterItem'](_0x17990f,_0x51f365);}['_recalculate'](_0x15c704,_0x30b430){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x17a33a,changedProp:_0x14ee18}of this['_recalculateBuffer'])'top'===_0x14ee18?this['_alignForTopChange'](_0x17a33a):this['_alignForBottomChange'](_0x17a33a);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x15c704,'changedProp':_0x30b430});}['getSidebarItemView'](_0x240c7c){return this['_annotationToSidebarItemView']['get'](_0x240c7c);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x3dbd1f){const _0x578d=this['getSidebarItemView'](_0x3dbd1f);this['stopListening'](_0x578d),this['stopListening'](_0x3dbd1f['view']),_0x578d['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x3dbd1f),this['_sidebarItemViewToAnnotation']['delete'](_0x578d);}['_createSidebarView'](){const _0x38c135=new H(this['context']['locale']);return _0x38c135['render'](),this['on']('change:_lastItem',(_0x4138b7,_0x56a4c4,_0x5ecc32,_0x4329be)=>{_0x4329be&&_0x38c135['unbind']('minHeight'),_0x5ecc32?_0x38c135['bind']('minHeight')['to'](_0x5ecc32,'bottom'):_0x38c135['minHeight']=null;}),_0x38c135;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x49edfe){const _0x48d369=this['_sidebarItemViewToAnnotation']['get'](_0x49edfe),_0x2f5030=_0x48d369&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x48d369)-0x1);return _0x2f5030&&this['getSidebarItemView'](_0x2f5030)||null;}['_getItemAfter'](_0x1c07ca){const _0x2df87f=this['_sidebarItemViewToAnnotation']['get'](_0x1c07ca),_0x534fc5=_0x2df87f&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x2df87f)+0x1);return _0x534fc5&&this['getSidebarItemView'](_0x534fc5)||null;}['_alignBeforeItem'](_0x245a07,_0x3f2d95){_0x245a07['updateHeight']();const _0x5dd9ea=G(_0x3f2d95['bottom']+this['_spaceBetweenItems'],_0x245a07['top']);return!!_0x5dd9ea&&(this['_setItemTop'](_0x3f2d95,_0x3f2d95['top']-_0x5dd9ea),!0x0);}['_alignAfterItem'](_0x180430,_0x52a058){_0x180430['updateHeight']();const _0x34e245=G(_0x180430['bottom']+this['_spaceBetweenItems'],_0x52a058['top']);return!!_0x34e245&&(this['_setItemTop'](_0x52a058,_0x52a058['top']+_0x34e245,!0x1),!0x0);}['_alignToTargetRect'](_0x1fe1f2){const _0x11707c=this['_sidebarItemViewToAnnotation']['get'](_0x1fe1f2);if(!_0x11707c||!_0x11707c['target']||!_0x11707c['targetRect'])return;const _0x74c5b6=this['_getTargetTop'](_0x11707c,_0x11707c['targetRect']);this['_setItemTop'](_0x1fe1f2,_0x74c5b6);}['_getTargetTop'](_0x1fb46e,_0x46fae9){if(null===_0x46fae9)return 0x0;if(_0x1fb46e['target']instanceof _0x49c6d0)return _0x46fae9['top'];{const _0x308b26=new _0x49c6d0(this['view']['element'])['top'];return _0x46fae9['top']-_0x308b26;}}['_setItemTop'](_0x32be12,_0x514383,_0x54b34e=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x54b34e&&(_0x514383=Math['max'](_0x514383,this['_getMaxAvailableTop'](_0x32be12))),_0x32be12['top']=_0x514383;}['_getMaxAvailableTop'](_0x1a3b61){let _0x3ffb5c=this['_getItemBefore'](_0x1a3b61),_0x15298f=0x0;for(;_0x3ffb5c;)_0x3ffb5c['updateHeight'](),_0x15298f+=this['_spaceBetweenItems']+_0x3ffb5c['height'],_0x3ffb5c=this['_getItemBefore'](_0x3ffb5c);return _0x15298f;}}function G(_0x3d9a91,_0x3a8d7a){return Math['max'](_0x3d9a91-_0x3a8d7a,0x0);}function g(_0x4af84b){return null!==_0x4af84b&&'object'==typeof _0x4af84b&&0x1===_0x4af84b['nodeType'];}class e extends _0x10fb5d{['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(_0x561a16){super(_0x561a16),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x4654ca(),this['_refreshPositioningDebounced']=_0x211bee(()=>{_0x561a16['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x2e5855=this['context']['plugins']['get'](j),_0x4fc811=this['context']['plugins']['get'](z);_0x2e5855['register']('wideSidebar',this),_0x4fc811['container']&&_0x2e5855['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x118a77){if(_0x118a77===this['activeAnnotation'])return;const _0x5ef096=this['context']['plugins']['get'](z);_0x5ef096['_activeAnnotation']=_0x118a77;const _0x1bee43=this['activeAnnotation'];_0x5ef096['refresh']({'blurredAnnotation':_0x1bee43,'activatedAnnotation':_0x118a77}),this['activeAnnotation']=_0x118a77;}['attach'](_0x35f12b){this['annotations']=_0x35f12b;const _0x5625ad=this['context']['plugins']['get'](z);if(_0x5625ad['_annotations']=_0x35f12b,this['isAttached'])throw new _0x5d7ae6('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x5625ad,'set:container',()=>{this['detach'](),this['listenTo'](_0x5625ad,'change:container',_0xd329bb=>{_0xd329bb['off'](),this['attach'](_0x35f12b);});}),_0x5625ad['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x4bf012=_0x23af2a=>{_0x23af2a['updateTargetRect'](),_0x5625ad['addAnnotation'](_0x23af2a);};for(const _0x284496 of _0x35f12b)_0x4bf012(_0x284496);this['listenTo'](_0x35f12b,'add',(_0x41a362,_0x36f537)=>{_0x4bf012(_0x36f537);}),this['listenTo'](_0x35f12b,'remove',(_0x5431ce,_0x1fc33f,_0x3206f0)=>{_0x5625ad['rearrange']({'removedAnnotation':_0x1fc33f,'previousAnnotation':_0x35f12b['get'](_0x3206f0-0x1),'nextAnnotation':_0x35f12b['get'](_0x3206f0+0x1)}),_0x1fc33f===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x35f12b,'focus',(_0x15067a,_0x45d262)=>{this['setActiveAnnotation'](_0x45d262);}),this['listenTo'](_0x35f12b,'blur',()=>{this['setActiveAnnotation'](null);});const _0x122b03=this['context']instanceof _0x114fec?this['context']['editors']:new _0x4654ca([this['context']]);for(const _0x258a3b of _0x122b03)this['_integrateWithEditorAnnotations'](_0x258a3b);this['listenTo'](_0x122b03,'add',(_0x164daf,_0x1ea028)=>{this['listenTo'](_0x1ea028,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x1ea028);});}),this['listenTo'](_0x122b03,'remove',(_0x4a215a,_0x4e66fa)=>{_0x4e66fa['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x4e66fa['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x5d7ae6('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x2b8399=this['context']['plugins']['get'](z);_0x2b8399['_detachFromContainer'](this['annotations']),this['stopListening'](_0x2b8399),this['stopListening'](this['annotations']),this['context']instanceof _0x114fec&&this['stopListening'](this['context']['editors']);for(const _0x221625 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x221625);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x23ef90){if(!_0x23ef90['plugins']['has']('EditorAnnotations'))return;const _0x3b7388=_0x23ef90['plugins']['get']('EditorAnnotations'),_0x306582=()=>{const _0x1ca500=_0x3b7388['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x1ca500[0x0]||null);};this['listenTo'](_0x3b7388,'refresh',_0x306582),this['listenTo'](_0x3b7388,'blur',(_0x4eefd7,{isAnnotationTracked:_0x56bc21})=>{this['activeAnnotation']&&_0x56bc21(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x3b7388,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x565125=>{_0x3b7388['hasDomSelection']()&&(_0x306582(),_0x565125['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x3b7388);}['_destroyEditorAnnotationsIntegration'](_0x1267fa){this['stopListening'](_0x1267fa),this['_editorAnnotations']['remove'](_0x1267fa);}}class C extends _0x49decf{['counterView'];constructor(_0x2b7985){super(_0x2b7985);const _0x5d3b69=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x129f81,_0x44d343)=>_0x129f81?'...':_0x44d343['toString']()),this['set']('annotationType',''),this['icon']=_0x25afc1,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x5d3b69['to']('annotationType',_0x1de104=>'ck-annotation-counter__badge--'+_0x1de104),_0x5d3b69['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x5d3b69['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x10fb5d{['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(_0xb46706){super(_0xb46706),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x1c26f7())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x4654ca(),this['_refreshPositioningDebounced']=_0x211bee(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x7b567a(this['context']['locale']),this['balloonPanelView']=new _0x42f273(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x55f1d1){this['annotations']=_0x55f1d1;const _0x6e31f4=this['context']['plugins']['get'](z),_0x5b3c49=this['balloonPanelView'];if(_0x6e31f4['_annotations']=_0x55f1d1,this['isAttached'])throw new _0x5d7ae6('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x6e31f4,'set:container',()=>{this['detach'](),this['listenTo'](_0x6e31f4,'change:container',_0x5edfb4=>{_0x5edfb4['off'](),this['attach'](_0x55f1d1);});}),_0x6e31f4['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x1e4108=_0x7e372f=>{const _0x1a7b24=new C(this['context']['locale']);_0x6e31f4['addAnnotation'](_0x7e372f,_0x1a7b24),this['_annotationToNarrowView']['set'](_0x7e372f,_0x1a7b24),_0x1a7b24['bind']('isDirty','annotationType','number')['to'](_0x7e372f['view'],'isDirty','type','length'),_0x1a7b24['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x5b3c49['content']['first']!==_0x7e372f['view']?(this['_showBalloon'](_0x7e372f),_0x7e372f['view']['element']['focus'](),this['setActiveAnnotation'](_0x7e372f)):this['setActiveAnnotation'](null);});};for(const _0x4c62d2 of _0x55f1d1)_0x1e4108(_0x4c62d2);this['listenTo'](_0x55f1d1,'add',(_0x5859dd,_0x53a45a)=>{_0x1e4108(_0x53a45a);}),this['listenTo'](_0x55f1d1,'remove',(_0x265799,_0x4befb6,_0x57e5dc)=>{this['_annotationToNarrowView']['get'](_0x4befb6)['destroy'](),this['_annotationToNarrowView']['delete'](_0x4befb6),_0x6e31f4['rearrange']({'removedAnnotation':_0x4befb6,'previousAnnotation':_0x55f1d1['get'](_0x57e5dc-0x1),'nextAnnotation':_0x55f1d1['get'](_0x57e5dc+0x1)}),_0x4befb6===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x55f1d1,'focus',(_0x1e8e81,_0x51411c)=>{this['setActiveAnnotation'](_0x51411c);}),this['listenTo'](_0x55f1d1,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0xd42016,_0x43d5b0)=>{_0x43d5b0['keyCode']===_0x10fa84['esc']&&_0x5b3c49['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x5b3c49['content']['first']),this['_hideBalloon'](),_0x43d5b0['stopPropagation'](),_0x43d5b0['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x43183e,_0x3d1e51)=>{const _0x107355=_0x3d1e51['target'];_0x5b3c49['isVisible']&&_0x5b3c49['element']['contains'](_0x107355)||_0x6e31f4['view']['element']['contains'](_0x107355)||_0x43183e['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x50b480=>_0x50b480['contains'](_0x107355))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x51aea1=this['context']instanceof _0x114fec?this['context']['editors']:new _0x4654ca([this['context']]);for(const _0x192f1c of _0x51aea1)this['_integrateWithEditorAnnotations'](_0x192f1c);this['listenTo'](_0x51aea1,'add',(_0x131860,_0x1d6158)=>{this['listenTo'](_0x1d6158,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x1d6158);});}),this['listenTo'](_0x51aea1,'remove',(_0x420fd0,_0x4f2a0c)=>{_0x4f2a0c['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x4f2a0c['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x47fe57){if(_0x47fe57===this['activeAnnotation'])return;const _0x577a14=this['context']['plugins']['get'](z);if(_0x577a14['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x47fe57,'disableAnimationOnActivatedAnnotation':!0x0}),_0x47fe57)_0x577a14['getSidebarItemView'](_0x47fe57)?this['_showBalloon'](_0x47fe57):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x47fe57;}['detach'](){if(!this['isAttached'])throw new _0x5d7ae6('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x209921=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x16e740=>_0x16e740['destroy']()),this['_annotationToNarrowView']['clear'](),_0x209921['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x114fec&&this['stopListening'](this['context']['editors']);for(const _0x1a41bb of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x1a41bb);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'](_0x107935){if(!_0x107935['plugins']['has']('EditorAnnotations'))return;const _0x59d660=_0x107935['plugins']['get']('EditorAnnotations'),_0x553033=this['context']['plugins']['get'](z),_0x2c41fc=this['annotations'],_0x17b2f4=this['balloonPanelView'],_0x2befed=()=>{const _0x4ea645=_0x59d660['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x4ea645),this['setActiveAnnotation'](_0x4ea645[0x0]||null);};this['listenTo'](_0x59d660,'refresh',_0x2befed),this['listenTo'](_0x59d660,'blur',(_0x572ba7,{isAnnotationTracked:_0x4d7613})=>{this['activeAnnotation']&&_0x4d7613(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x59d660,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x2c41fc,'blur',_0x4fd7fa=>{_0x59d660['hasDomSelection']()&&_0x4fd7fa['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x7b60f5,_0x2d065b)=>{const _0x1acbb=_0x2d065b['target'];_0x17b2f4['isVisible']&&_0x17b2f4['element']['contains'](_0x1acbb)||_0x553033['view']['element']['contains'](_0x1acbb)||this['activeAnnotation']&&_0x59d660['hasDomSelection']()&&(_0x2befed(),_0x7b60f5['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x59d660);}['_destroyEditorAnnotationsIntegration'](_0x2ae172){_0x2ae172&&(this['stopListening'](_0x2ae172),this['_editorAnnotations']['remove'](_0x2ae172));}['_setSelectedAnnotations'](_0x149fbc){for(const _0x16507d of this['_selectedAnnotations'])_0x149fbc['includes'](_0x16507d)||this['_manuallyClosedAnnotationViews']['delete'](_0x16507d['view']);this['_selectedAnnotations']=_0x149fbc;}['_refreshPositioning'](){const _0x1fb84b=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x1fb84b['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x1cbdd7){if(this['_manuallyClosedAnnotationViews']['has'](_0x1cbdd7['view']))return;const _0x364439=this['balloonPanelView']['content']['first'];_0x364439!==_0x1cbdd7['view']?(_0x364439&&this['_detachListeners'](_0x364439),this['_attachListeners'](_0x1cbdd7['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x1cbdd7['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x2036b2=this['balloonPanelView']['content']['first'],_0x18b5d6=_0x2036b2&&this['annotations']['getByView'](_0x2036b2);if(!_0x18b5d6||!this['_annotationToNarrowView']['has'](_0x18b5d6))return;const _0x105188=this['_annotationToNarrowView']['get'](_0x18b5d6)['element'],_0x1a6ddc=(function(){const _0x45242c=_0x42f273['defaultPositions'];return[_0x45242c['southArrowNorthEast'],_0x45242c['northArrowSouthEast'],_0x45242c['southArrowNorth'],_0x45242c['northArrowSouth'],_0x45242c['southArrowNorthWest'],_0x45242c['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x105188,'positions':_0x1a6ddc});}['_hideBalloon'](){const _0x42b4f7=this['balloonPanelView'],_0x3115ed=_0x42b4f7['content']['first'];_0x3115ed&&(this['_detachListeners'](_0x3115ed),_0x42b4f7['unpin'](),_0x42b4f7['content']['clear']());}['_attachListeners'](_0x3334cf){this['listenTo'](_0x3334cf,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x3334cf,'Esc',(_0x540260,_0x157836)=>{this['_manuallyClosedAnnotationViews']['add'](_0x3334cf),this['_hideBalloon'](),_0x157836();});}['_detachListeners'](_0x57768c){this['stopListening'](_0x57768c);}}class c extends _0x57b43d{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[b,_0x2252d1,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3f24fb){super(_0x3f24fb),_0x3f24fb['editing']['view']['addObserver'](_0x5675a2),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x3f24fb['plugins']['get'](_0x2252d1),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x173bd9=this['editor']['plugins']['get'](j);_0x173bd9['context']===this['editor']&&(_0x173bd9['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x568f68,_0x8ec17)=>{const _0x2d07d8=this['_balloon'];if(this['isAttached']&&_0x2d07d8['visibleView']){const _0x3607a7=this['annotations']['getByView'](_0x2d07d8['visibleView']);_0x3607a7&&this['_closeAnnotation'](_0x3607a7),_0x8ec17();}}));}['afterInit'](){const _0x471c09=this['editor']['plugins']['get'](j);_0x471c09['context']===this['editor']&&(_0x471c09['hasActive']()||_0x471c09['switchTo']('inline'));}['setActiveAnnotation'](_0x49365b){_0x49365b!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x49365b&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x49365b)&&this['_addAnnotationToBalloon'](_0x49365b,!0x0),_0x49365b['isActive']=!0x0),_0x49365b||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x49365b);}['attach'](_0x1a0050){this['annotations']=_0x1a0050;const _0x473fbe=this['editor']['plugins']['get'](j),_0x25f8f5=this['_balloon'];if(this['isAttached'])throw new _0x5d7ae6('inlineannotations-attach-already-attached',this);if(_0x473fbe['context']!==this['editor'])throw new _0x5d7ae6('inlineannotations-not-allowed-with-context',this);const _0x934927=this['editor']['plugins']['get'](b);this['listenTo'](_0x934927,'refresh',()=>{const _0x89045f=_0x934927['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x32cf4c,_0x2b75e7;!this['_forceRefresh']&&(_0x32cf4c=_0x89045f,_0x2b75e7=this['_selectedAnnotations'],_0x32cf4c['length']===_0x2b75e7['length']&&_0x32cf4c['every'](_0x55be11=>_0x2b75e7['includes'](_0x55be11)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x89045f),this['setActiveAnnotation'](_0x89045f[0x0]||null));}),this['listenTo'](_0x934927,'blur',(_0x7f6f,{isAnnotationTracked:_0x1e8e87})=>{this['activeAnnotation']&&_0x1e8e87(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x5e7427,_0x1f7394,_0x1e8ca5)=>{_0x1e8ca5||this['setActiveAnnotation'](null);}),this['listenTo'](_0x1a0050,'remove',(_0x364ba8,_0x5a1cea)=>{this['_removeAnnotationFromBalloon'](_0x5a1cea),_0x5a1cea===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x25f8f5,'change:visibleView',(_0x2314b3,_0x3ebfb0,_0x51f730,_0x53eb2e)=>{_0x53eb2e&&this['stopListening'](_0x53eb2e);const _0x2b14d5=_0x1a0050['getByView'](_0x51f730);_0x51f730&&_0x2b14d5&&(this['listenTo'](_0x51f730,'change:height',()=>{_0x25f8f5['updatePosition']();}),this['listenTo'](_0x51f730,'Esc',()=>{this['_closeAnnotation'](_0x2b14d5),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x2b14d5&&this['setActiveAnnotation'](_0x2b14d5));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x25f8f5['visibleView']&&(_0x1a0050['getByView'](_0x25f8f5['visibleView'])&&_0x25f8f5['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 _0x5d7ae6('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x4b6e09 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x4b6e09);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x34b070){for(const _0x2deb23 of this['_selectedAnnotations'])_0x34b070['includes'](_0x2deb23)||this['_manuallyClosed']['delete'](_0x2deb23);for(const _0x35bd6b of this['annotations'])_0x34b070['includes'](_0x35bd6b)||this['_removeAnnotationFromBalloon'](_0x35bd6b);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x3de29d of _0x34b070)this['_addAnnotationToBalloon'](_0x3de29d);}this['_selectedAnnotations']=_0x34b070;}['_addAnnotationToBalloon'](_0x308c28,_0x2d055b=!0x1){this['_manuallyClosed']['has'](_0x308c28)||(this['_addedAnnotations']['has'](_0x308c28)||this['_balloon']['hasView'](_0x308c28['view'])||(this['_addedAnnotations']['add'](_0x308c28),this['_balloon']['add']({'stackId':_0x308c28['view']['id'],'view':_0x308c28['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x308c28)}})),_0x2d055b&&this['_balloon']['showStack'](_0x308c28['view']['id']));}['_getBalloonTargetForAnnotation'](_0x532900){const _0x528194=_0x532900['target'],_0x278a76=this['editor']['editing']['view'],_0x12c7e1=_0x278a76['document']['selection']['getFirstRange'](),_0x26dff6=_0x278a76['domConverter']['viewRangeToDom'](_0x12c7e1);if(_0x26dff6['collapse'](!0x0),_0x528194){if(_0x528194 instanceof _0x49c6d0)return _0x528194;let _0x47bcc8=[];for(const _0xa93ade of _0x528194)_0x47bcc8['push'](...F(_0xa93ade['getClientRects']()));_0x47bcc8=function(_0x188d5a){const _0x5eacd1=[];let _0xe1896b=_0x188d5a[0x0];for(let _0x1bcb72=0x1;_0x1bcb72<_0x188d5a['length'];_0x1bcb72++)P(_0xe1896b,_0x188d5a[_0x1bcb72])?_0xe1896b['width']+=_0x188d5a[_0x1bcb72]['width']:(_0x5eacd1['push'](_0xe1896b),_0xe1896b=_0x188d5a[_0x1bcb72]);return _0x5eacd1['push'](_0xe1896b),_0x5eacd1;}(_0x47bcc8);const _0x4402dc=_0x26dff6['getBoundingClientRect']();return _0x47bcc8['find'](_0x33c6c2=>_0x33c6c2['top']<=_0x4402dc['top']&&_0x33c6c2['bottom']>=_0x4402dc['bottom']&&_0x33c6c2['left']<=_0x4402dc['left']&&_0x33c6c2['right']>=_0x4402dc['right'])||_0x47bcc8[0x0];}return _0x532900['targetRect']||_0x26dff6;}['_removeAnnotationFromBalloon'](_0x457738){this['_addedAnnotations']['has'](_0x457738)&&this['_balloon']['hasView'](_0x457738['view'])&&(this['_addedAnnotations']['delete'](_0x457738),this['_balloon']['remove'](_0x457738['view']));}['_closeAnnotation'](_0x7ab290){this['_manuallyClosed']['add'](_0x7ab290),this['_removeAnnotationFromBalloon'](_0x7ab290);}}function F(_0x2ffe1c){return Array['from'](_0x2ffe1c)['map'](DOMRect['fromRect']);}function P(_0x17c8b7,_0x4e7dcc){return _0x17c8b7['top']===_0x4e7dcc['top']&&_0x17c8b7['bottom']===_0x4e7dcc['bottom']&&_0x17c8b7['right']===_0x4e7dcc['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x5678e1,_0x1e38a1){super(_0x5678e1),this['set']('isEmpty',!_0x1e38a1['length']),this['focusTracker']=new _0x5bef6f(),this['_annotationViews']=_0x1e38a1,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x3b0d1d({'focusables':_0x1e38a1,'focusTracker':this['focusTracker']}),this['listenTo'](_0x1e38a1,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x1e38a1,'remove',(_0x508c22,_0x27dbc1)=>{_0x27dbc1['isActive']&&this['focus'](),_0x1e38a1['length']||(this['isEmpty']=!0x0);});const _0xcbc25d=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x5678e1,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x1e38a1},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0xcbc25d['if']('isEmpty','ck-hidden',_0x45e1e1=>!_0x45e1e1)]},'children':[{'text':N(_0x5678e1,'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 _0x2257e6 of this['_annotationViews'])this['focusTracker']['add'](_0x2257e6['element']);this['_annotationViews']['on']('change',(_0x4abf4f,{added:_0x3cdbf0,removed:_0x46bf78})=>{for(const _0x2f10ac of _0x3cdbf0)this['focusTracker']['add'](_0x2f10ac['element']);for(const _0x11d9ce of _0x46bf78)this['focusTracker']['remove'](_0x11d9ce['element']);});}}class p extends _0x10fb5d{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x108413){super(_0x108413),this['archivedThreads']=new _0x4654ca();}['init'](){const _0x388cdc=this['context'],_0x1ad9ba=_0x388cdc['plugins']['get'](o),_0x35d2e6=_0x388cdc['plugins']['get'](y);this['listenTo'](_0x1ad9ba,'addCommentThread',(_0x524652,{threadId:_0x41ad65})=>{const _0x4f6110=_0x1ad9ba['getCommentThread'](_0x41ad65);_0x4f6110['archivedAt']&&this['archivedThreads']['add'](_0x4f6110,this['_calculatePosition'](_0x4f6110['archivedAt'])),this['listenTo'](_0x4f6110,'change:archivedAt',(_0x4254f2,_0x43adf2,_0xe316d5)=>{_0xe316d5?this['archivedThreads']['has'](_0x4f6110)||this['archivedThreads']['add'](_0x4f6110,this['_calculatePosition'](_0x4f6110['archivedAt'])):this['archivedThreads']['has'](_0x4f6110)&&this['archivedThreads']['remove'](_0x4f6110);});}),this['listenTo'](_0x1ad9ba,'removeCommentThread',(_0x4192d6,{threadId:_0x27f93b})=>{const _0x4b6868=_0x1ad9ba['getCommentThread'](_0x27f93b);this['stopListening'](_0x4b6868),this['archivedThreads']['has'](_0x4b6868)&&this['archivedThreads']['remove'](_0x4b6868);},{'priority':'highest'}),this['listenTo'](_0x35d2e6['collection'],'focus',(_0x4bb61b,_0x33abef)=>{_0x33abef['isVisible']||(_0x33abef['isActive']=!0x0,_0x35d2e6['activate'](_0x33abef));});}['_calculatePosition'](_0x2ecab2){const _0x2b0133=[...this['archivedThreads']]['findIndex'](_0x4477e9=>_0x4477e9['archivedAt']<_0x2ecab2);return _0x2b0133>-0x1?_0x2b0133:this['archivedThreads']['length'];}}class a extends _0x57b43d{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x16e01c];}constructor(_0x31cf59){super(_0x31cf59),this['annotationViews']=new _0x5c4347(),this['_pendingThreads']=[];}['init'](){const _0x3865cd=this['editor'],_0x5b7cb6=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x3865cd['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x49decf,!0x0)),_0x3865cd['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x278098=this['_createCommentsArchiveButton'](_0x28f235);return _0x278098['set']({'role':'menuitemcheckbox'}),_0x278098;});const _0x5e8a2e=_0x3865cd['plugins']['get'](p),_0x42cd0b=_0x3865cd['plugins']['get']('Annotations'),_0x4254e9=_0x3865cd['plugins']['get']('CommentsRepository');_0x5e8a2e['archivedThreads']['forEach'](_0xf2108d=>{this['_handleNewThread'](_0xf2108d);}),this['listenTo'](_0x5e8a2e['archivedThreads'],'add',(_0x277275,_0x3a980c)=>{this['_handleNewThread'](_0x3a980c);}),this['listenTo'](_0x42cd0b['collection'],'add',(_0x637d7a,_0x17e2fb)=>{const _0x7308d9=this['_pendingThreads']['find'](_0x20e423=>{const _0x1762d6=_0x4254e9['_threadToController']['get'](_0x20e423);return _0x1762d6&&_0x17e2fb['innerView']===_0x1762d6['view'];});if(_0x7308d9){const _0x45b2bf=this['_calculatePosition'](_0x7308d9['archivedAt']);this['_addAnnotationToArchive'](_0x17e2fb,_0x45b2bf),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x7308d9),0x1);}}),this['listenTo'](_0x5e8a2e['archivedThreads'],'remove',(_0x152543,_0x2e3a42)=>{const _0x2f2e37=_0x3865cd['config']['get']('collaboration.channelId');if(!_0x2f2e37||_0x2e3a42['channelId']===_0x2f2e37){if(this['_pendingThreads']['includes'](_0x2e3a42))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x2e3a42),0x1);else{const _0x16dd55=_0x4254e9['_threadToController']['get'](_0x2e3a42),_0x353a3a=_0x42cd0b['getByInnerView'](_0x16dd55['view']);this['annotationViews']['remove'](_0x353a3a['view']),this['stopListening'](_0x353a3a),this['stopListening'](_0x353a3a['focusableElements']);}}}),this['listenTo'](_0x42cd0b['collection'],'add',(_0x1a1ce2,_0x23c3f8)=>{this['listenTo'](_0x23c3f8,'escape',_0x5b7cb6);}),this['listenTo'](_0x42cd0b['collection'],'remove',(_0x4e4fbd,_0xa08b94)=>{this['stopListening'](_0xa08b94,'escape',_0x5b7cb6);});}['_addAnnotationToArchive'](_0x50a85b,_0x13f675){this['listenTo'](_0x50a85b,'set:isVisible',_0x3d8045=>{_0x3d8045['return']=!0x1,_0x3d8045['stop']();}),this['annotationViews']['add'](_0x50a85b['view'],_0x13f675);}['_handleNewThread'](_0x12b5d4){const _0x5d494d=this['editor']['plugins']['get']('CommentsRepository'),_0x42c627=this['editor']['plugins']['get']('Annotations'),_0x3e953b=this['editor']['config']['get']('collaboration.channelId');if(!_0x3e953b||_0x12b5d4['channelId']===_0x3e953b){const _0x35852e=_0x5d494d['_threadToController']['get'](_0x12b5d4);if(!_0x35852e)return void this['_pendingThreads']['push'](_0x12b5d4);const _0x17cd40=this['_calculatePosition'](_0x12b5d4['archivedAt']),_0x3b6e98=_0x42c627['getByInnerView'](_0x35852e['view']);_0x3b6e98['isVisible']&&_0x42c627['_visibleAnnotations']['remove'](_0x3b6e98),this['_addAnnotationToArchive'](_0x3b6e98,_0x17cd40);}}['_calculatePosition'](_0x49498a){const _0xdc73f9=this['editor']['config']['get']('collaboration.channelId'),_0x27e2b4=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0x1b32fb=>_0x1b32fb['channelId']===_0xdc73f9)['findIndex'](_0x22dbb1=>_0x22dbb1['archivedAt']<_0x49498a);return _0x27e2b4<0x0||_0x27e2b4>this['annotationViews']['length']?this['annotationViews']['length']:_0x27e2b4-0x1;}['_toggleDialog'](){const _0x532d76=this['editor'],_0x2b19ba=_0x532d76['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x532d76['locale'],this['annotationViews'])),'commentsArchive'===_0x2b19ba['id']?_0x2b19ba['hide']():_0x2b19ba['show']({'id':'commentsArchive','title':N(_0x532d76['locale'],'COMMENTS_ARCHIVE'),'icon':_0x154ce6,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x4b0027['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x4f6069,_0xf1c55b=!0x1){const _0x3a40b7=this['editor']['locale'],_0x42691b=this['editor']['plugins']['get']('Dialog'),_0x5abd03=new _0x4f6069(_0x3a40b7);return _0x5abd03['bind']('isEnabled')['to'](this,'isEnabled'),_0x5abd03['bind']('isOn')['to'](_0x42691b,'id',_0xe2e183=>'commentsArchive'===_0xe2e183),_0x5abd03['set']({'label':N(_0x3a40b7,'COMMENTS_ARCHIVE'),'icon':_0x154ce6,'isToggleable':!0x0}),_0xf1c55b&&(_0x5abd03['tooltip']=!0x0),this['listenTo'](_0x5abd03,'execute',()=>this['_toggleDialog']()),_0x5abd03;}['_hideDialogOnAnnotationEscape']=_0x593bd9=>{const _0x52db32=_0x593bd9['source'];if(!this['annotationViews']['has'](_0x52db32['view']))return;const _0x156983=this['editor']['plugins']['get']('Dialog');_0x156983['isOpen']&&'commentsArchive'===_0x156983['id']&&(_0x156983['hide'](),_0x593bd9['stop']());};}class gi extends _0x57b43d{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};