@ckeditor/ckeditor5-comments 47.6.2-alpha.0 → 47.6.2-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 (194) hide show
  1. package/build/comments.js +1 -1
  2. package/dist/index.js +11 -11
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +19 -19
  150. package/src/annotations/annotation.js +2 -2
  151. package/src/annotations/annotationcollection.js +1 -1
  152. package/src/annotations/annotations.js +1 -1
  153. package/src/annotations/annotationsuis.js +1 -1
  154. package/src/annotations/editorannotations.js +1 -1
  155. package/src/annotations/inlineannotations.js +1 -1
  156. package/src/annotations/narrowsidebar.js +1 -1
  157. package/src/annotations/sidebar.js +1 -1
  158. package/src/annotations/view/annotationcounterbuttonview.js +1 -1
  159. package/src/annotations/view/annotationview.js +1 -1
  160. package/src/annotations/view/sidebaritemview.js +2 -2
  161. package/src/annotations/view/sidebarview.js +2 -2
  162. package/src/annotations/widesidebar.js +1 -1
  163. package/src/comments/addcommentthreadcommand.js +1 -1
  164. package/src/comments/commentsarchive.js +1 -1
  165. package/src/comments/commentsarchiveui.js +1 -1
  166. package/src/comments/commentsediting.js +1 -1
  167. package/src/comments/commentsrepository.js +3 -3
  168. package/src/comments/commentsui.js +1 -1
  169. package/src/comments/integrations/clipboard.js +1 -1
  170. package/src/comments/integrations/commentsrestrictededitingmode.js +1 -1
  171. package/src/comments/integrations/importword.js +1 -1
  172. package/src/comments/integrations/showcommenthighlights.js +1 -1
  173. package/src/comments/ui/commenteditor/commenteditor.js +2 -2
  174. package/src/comments/ui/commenteditor/commenteditorui.js +1 -1
  175. package/src/comments/ui/commenteditor/commenteditoruiview.js +1 -1
  176. package/src/comments/ui/commentthreadcontroller.js +2 -2
  177. package/src/comments/ui/view/basecommentthreadview.js +1 -1
  178. package/src/comments/ui/view/basecommentview.js +1 -1
  179. package/src/comments/ui/view/collapsedcommentsview.js +1 -1
  180. package/src/comments/ui/view/commentcontentview.js +1 -1
  181. package/src/comments/ui/view/commentinputview.js +1 -1
  182. package/src/comments/ui/view/commentsarchiveview.js +1 -1
  183. package/src/comments/ui/view/commentslistview.js +1 -1
  184. package/src/comments/ui/view/commentthreadheadercontextview.js +1 -1
  185. package/src/comments/ui/view/commentthreadheaderview.js +1 -1
  186. package/src/comments/ui/view/commentthreadinputview.js +1 -1
  187. package/src/comments/ui/view/commentthreadview.js +2 -2
  188. package/src/comments/ui/view/commentview.js +2 -2
  189. package/src/comments.js +1 -1
  190. package/src/commentsonly.js +1 -1
  191. package/src/index.js +1 -1
  192. package/src/utils/common-translations.js +1 -1
  193. package/src/utils/createmutationobserver.js +1 -1
  194. package/src/utils/splitmarkername.js +1 -1
package/dist/index.js CHANGED
@@ -20,14 +20,14 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Editor as _0x1e4091,ContextPlugin as _0x51795f,PendingActions as lt,Command as _0x3ab548,Plugin as _0x2d240e,Context as _0x5ed2a5}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x22b275,uid as _0x114214,KeystrokeHandler as jt,FocusTracker as _0x144d0f,diff as _0x24f995,Collection as _0x1b1267,Rect as _0x2227f5,CKEditorError as _0x498a52,first as _0x31b8b0,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x128deb,keyCodes as _0x54f57c}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x25fda7,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x5731dd,trimHtml as ts,LateFocusDropdownButtonView as _0x1013b5,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x4c478d}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x4916fd}from'es-toolkit/compat';import{IconUndo as _0x355170,IconCheck as _0xe38e81,IconPencil as _0x4fecaf,IconRemoveComment as _0x1b0bf0,IconThreeVerticalDots as _0x56e494,IconAddComment as _0x59b8c2,IconCommentsArchive as _0x50c104}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as $t,InlineEditableUIView as Vt,EditorUI as Ut,View as kt,FocusCycler as _0x37e2ac,ButtonView as _0x6b909b,ViewCollection as _0x437229,createDropdown as _0x539082,ListView as _0x2ad704,focusChildOnDropdownOpen as _0x4b8bb2,ListItemView as _0x3556d2,MenuBarMenuListItemButtonView as _0x1d6833,BodyCollection as _0x3adbc2,BalloonPanelView as _0x59086b,ContextualBalloon as _0x2d4f82,Dialog as _0x4adc55,DialogViewPosition as _0x3c4ef8}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as St,enableViewPlaceholder as Ft,MouseObserver as _0x3b6d41}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 _0x2c7af9}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x2134c4}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
- _0x22b275(){['model'];['view'];constructor(_0x51704f,_0x343617){super(),this['model']=_0x51704f,this['model']['_isAttached']=!0x0,this['view']=_0x343617,this['listenTo'](_0x343617,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x343617,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x343617,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x343617,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x343617,'addComment',(_0x34eeb7,_0x7909ee)=>this['addComment'](_0x7909ee)),this['listenTo'](_0x343617,'updateComment',(_0xae9de,_0x3516e0,_0x1a2601)=>this['updateComment'](_0x3516e0,_0x1a2601)),this['listenTo'](_0x343617,'removeComment',(_0x252c3b,_0x19e2f2)=>this['removeComment'](_0x19e2f2));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0xa6beee){this['model']['addComment']({'content':_0xa6beee,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x29825b,_0x5b77f1){this['model']['getComment'](_0x29825b)['update']({'content':_0x5b77f1});}['removeComment'](_0xbc892c){this['model']['getComment'](_0xbc892c)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x46e5db,_0x24f529,_0x97a366){const t=_0x46e5db['t'];switch(_0x24f529){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'},_0x97a366);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'},_0x97a366);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'},_0x97a366);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'},_0x97a366);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x97a366);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'},_0x97a366);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'},_0x97a366);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'},_0x97a366);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(_0x432c60,_0x998d34){super(_0x432c60);const _0x1da6b0=_0x114214();this['main']=this['createCollection'](),this['editable']=new Vt(_0x432c60,_0x998d34,void 0x0,{'label':()=>N(_0x432c60,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x432c60['uiLanguageDirection'],'lang':_0x432c60['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x1da6b0},'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(_0x4d1dd3){super(_0x4d1dd3),this['view']=new Rt(_0x4d1dd3['locale'],_0x4d1dd3['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x288e44=this['editor']['editing']['view'],_0x1606bd=this['view']['editable'],_0x234205=_0x288e44['document']['getRoot']();_0x1606bd['name']=_0x234205['rootName'],this['view']['render']();const _0x52a2da=_0x1606bd['element'];this['setEditableElement'](_0x1606bd['name'],_0x52a2da),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x288e44['attachDomRoot'](_0x52a2da),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[qt,zt,Bt,Gt,Jt,Kt,Lt];class hs extends/* #__PURE__ -- @preserve */
25
- _0x22b275(_0x1e4091){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
- ((()=>Qt)());constructor(_0x406b10={}){function _0x278f6c(_0x247ace){return _0x247ace['map'](_0x454f98=>String['fromCharCode'](_0x454f98))['join']('');}(_0x406b10=Object['assign']({},_0x406b10))['plugins']||(_0x406b10['plugins']=hs['defaultPlugins']),super(_0x406b10),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[_0x278f6c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x278f6c([0x76,0x69,0x65,0x77])][_0x278f6c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x278f6c([0x61,0x75,0x74,0x6f]),this[_0x278f6c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x278f6c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x278f6c([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x278f6c([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x278f6c([0x6f,0x6b])});}['create'](){const _0x1d1273=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x1d1273))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x5786d0=>{const _0xb9b8ff=this['model']['document']['getRoot'](),_0x493c81=_0xb9b8ff&&_0xb9b8ff['getChild'](_0xb9b8ff['childCount']-0x1);_0x5786d0['setSelection'](_0x493c81,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x5cd420=this['editing']['view'],_0x3309ff=_0x5cd420['document']['getRoot'](),_0x27b303=_0x3309ff['getChild'](0x0);_0x3309ff['childCount']>0x1||!_0x27b303||'p'!=_0x27b303['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x5cd420,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x27b303['placeholder']=this['placeholder']),Ft({'view':_0x5cd420,'element':_0x27b303,'keepOnFocus':!0x0}),this['placeholderElement']=_0x27b303);}}class es extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x124cc0,_0x2dddad={}){super(_0x124cc0),this['editor']=null,this['_editorConfig']=_0x2dddad,this['set']('value',_0x2dddad['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x124cc0,'Reply...')),this['set']('submitLabel',N(_0x124cc0,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x144d0f(),this['focusCycler']=new _0x37e2ac({'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',(_0x5d56c3,_0x5b6a0b)=>{this['cancelButtonView']['fire']('execute'),_0x5b6a0b();}),this['keystrokes']['set']('Ctrl+Enter',(_0x37f2dc,_0x27e103)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x27e103());}),this['on']('submit',(_0x4675f9,_0x4759fb)=>{_0x4759fb['length']>0xfde8?(alert(N(_0x124cc0,'TOO_LONG_COMMENT_ALERT',[_0x4759fb['length'],0xfde8])),_0x4675f9['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 _0x5860f6=this['editor'];this['element']['insertBefore'](_0x5860f6['ui']['element'],this['element']['firstChild']),_0x5860f6['model']['document']['on']('change',()=>this['value']=_0x5860f6['getData']()),_0x5860f6['bind']('placeholder')['to'](this),this['focusables']['add'](_0x5860f6['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x36da9d){-0x1===_0x36da9d?(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:_0x44f534}=this,_0x49c06b=new _0x6b909b(_0x44f534);return _0x49c06b['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x49c06b['withText']=!0x0,_0x49c06b['bind']('label')['to'](this,'submitLabel'),_0x49c06b['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x49c06b['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x101692,_0x7d3800)=>!_0x7d3800&&!!_0x101692['trim']()),_0x49c06b;}['_createCancelButton'](){const {locale:_0x1e7b93}=this,_0x20fcdd=new _0x6b909b(_0x1e7b93);return _0x20fcdd['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x20fcdd['label']=N(_0x1e7b93,'Cancel'),_0x20fcdd['withText']=!0x0,_0x20fcdd['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x20fcdd;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x29b639=>{this['focusTracker']['add'](_0x29b639['element']);}),this['focusables']['on']('change',(_0x2e06cf,_0xcc8d1b)=>{for(const _0x2171d3 of Array['from'](_0xcc8d1b['added'])['reverse']())this['focusTracker']['add'](_0x2171d3['element']);});}}class ie extends kt{constructor(_0x4ae157,_0x10f545,_0x4e7a8a){super(_0x4ae157),this['commentInputView']=new es(_0x4ae157,_0x4e7a8a),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x42bcf0,_0x5560fc)=>_0x42bcf0||!!_0x5560fc),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 _0x25fda7(_0x4ae157,_0x10f545),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'](_0x11518b){this['commentInputView']['focus'](_0x11518b);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x2ce640,_0x1c6a77)=>{const {submitButtonView:_0x4047dc,cancelButtonView:_0x149b0c,editor:_0x280d34}=this['commentInputView'];[_0x4047dc['element'],_0x149b0c['element'],_0x280d34?_0x280d34['editing']['view']['getDomRoot']():null]['filter'](_0x4efb26=>_0x4efb26)['some'](_0x4c5dc9=>_0x4c5dc9['contains'](_0x1c6a77['target']))||(this['focus'](),_0x1c6a77['preventDefault']());});}}class rs extends kt{constructor(_0x3d4f00){super(_0x3d4f00);const _0x161f69=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x161f69['to']('count',_0xce2b4f=>N(_0x3d4f00,'NUMBER_OF_COMMENTS',_0xce2b4f))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x3e802b,_0x26ee3f,_0x4bd6a2){super(_0x3e802b);const _0x9b4741=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x26ee3f['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x26ee3f,this['_config']=_0x4bd6a2,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x144d0f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x37e2ac({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x270a55=>this['commentViews']['map'](_0x45211b=>_0x45211b['element'])['includes'](_0x270a55['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x3e802b),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x3f052f=>_0x3f052f-this['_config']['maxCommentsWhenCollapsed']);for(const _0x452ecd of _0x26ee3f['comments'])this['_handleNewCommentModel'](_0x452ecd);this['_handleInfoComment'](),this['listenTo'](_0x26ee3f['comments'],'add',(_0x4e8f66,_0x28c91e)=>{const _0x4b8d6a=this['_calculatePosition'](_0x28c91e);this['length']++,this['_handleNewCommentModel'](_0x28c91e,_0x4b8d6a),this['refreshVisibleViews']();}),this['listenTo'](_0x26ee3f['comments'],'remove',(_0x22de1e,_0x51e1ea)=>{this['length']--,this['_handleRemoveCommentModel'](_0x51e1ea),this['refreshVisibleViews']();}),this['listenTo'](_0x26ee3f,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x26ee3f,'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',_0x9b4741['if']('length','ck-hidden',_0x2ae94b=>!_0x2ae94b)],'aria-label':N(_0x3e802b,'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'](_0x2931d0){-0x1===_0x2931d0?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x2f02d3 of this['commentViews'])_0x2f02d3['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x313f40,_0x3e7eca){const _0x1b0966=new this['_config']['CommentView'](this['locale'],_0x313f40,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x1b0966['viewUid']=_0x313f40['id'],_0x1b0966['delegate']('removeComment')['to'](this),_0x1b0966['delegate']('updateComment')['to'](this),_0x1b0966['delegate']('resolveCommentThread')['to'](this),_0x1b0966['delegate']('editorReady')['to'](this),_0x1b0966['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x1b0966,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x1b0966,_0x3e7eca);}['_calculatePosition'](_0x548668){const _0x14e4de=this['_model']['_findOptimalIndex'](_0x548668);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x548668['authoredAt']?_0x14e4de-0x1:_0x14e4de:_0x14e4de-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x4e4c15={'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'],_0x4e4c15,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x4e4c15));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x57ca63){const _0x4913da=this['commentViews']['remove'](_0x57ca63['id']);this['stopListening'](_0x4913da),_0x4913da['isEditMode']&&this['_updateHasDirtyComment'](),_0x4913da['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x52a699=>_0x52a699['isEditMode']);}['_rearrangeCollapse'](){const _0x13d3f8=function(_0x11a56c){const _0x3d975b=new _0x1b1267();for(const _0x4bab16 of _0x11a56c)_0x3d975b['add'](_0x4bab16);return _0x3d975b;}(this['commentViews']),_0x3c1c93=this['_collapsedCommentsView']['count'];for(let _0x4d5dec=0x1;_0x4d5dec<=_0x3c1c93;_0x4d5dec++)_0x13d3f8['remove'](0x1);for(const _0x4f50c6 of _0x13d3f8)_0x4f50c6['collapse']();_0x3c1c93>0x0&&_0x13d3f8['add'](this['_collapsedCommentsView'],0x1),ns(_0x24f995(Array['from'](this['visibleViews']),Array['from'](_0x13d3f8)),this['visibleViews'],_0x13d3f8);}['_rearrangeExpand'](){ns(_0x24f995(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x57ea27 of this['visibleViews'])_0x57ea27['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x57e449=>{this['focusTracker']['add'](_0x57e449['element']),this['keystrokes']['listenTo'](_0x57e449['element']);}),this['commentViews']['on']('change',(_0x187682,_0xa037)=>{for(const _0x3a4bcc of _0xa037['removed'])this['focusTracker']['remove'](_0x3a4bcc['element']),this['keystrokes']['stopListening'](_0x3a4bcc['element']);for(const _0x428338 of Array['from'](_0xa037['added'])['reverse']())this['focusTracker']['add'](_0x428338['element']),this['keystrokes']['listenTo'](_0x428338['element']);});}}function ns(_0x537255,_0x18685b,_0x5b5a9e){let _0xccf250=0x0;for(const _0x44b28a of _0x537255)switch(_0x44b28a){case'insert':_0x18685b['add'](_0x5b5a9e['get'](_0xccf250),_0xccf250),_0xccf250++;break;case'delete':_0x18685b['remove'](_0xccf250);break;case'equal':_0xccf250++;}}class oe extends kt{constructor(_0x2ce1b4){super(_0x2ce1b4);const _0x4283e1=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x4283e1['to']('contextValue',_0x459c9a=>N(_0x2ce1b4,'THREAD_CONTEXT_LABEL',_0x459c9a)),'tabindex':-0x1},'children':[{'text':_0x4283e1['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x27fdf4,_0x10a5a0){super(_0x27fdf4);const _0x53bdf2=this['bindTemplate'];this['_model']=_0x10a5a0,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x144d0f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x37e2ac({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x2fda67=>!!_0x2fda67),this['bind']('contextValue')['to'](this['_model'],'context',_0xf6ac6a=>_0xf6ac6a&&_0xf6ac6a['value']?this['_trimContextValue'](_0xf6ac6a['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',_0x53bdf2['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 _0x2e3efa=new _0x6b909b(this['locale']);return _0x2e3efa['label']=N(this['locale'],'Reopen'),_0x2e3efa['tooltip']=N(this['locale'],'Reopen'),_0x2e3efa['icon']=_0x355170,_0x2e3efa['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x5b5d0c=>!_0x5b5d0c),_0x2e3efa['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x126c89,_0xc65720)=>_0x126c89&&_0xc65720),_0x2e3efa['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x2e3efa;}['_trimContextValue'](_0x5231c1){if(_0x5231c1['length']<0x96)return _0x5231c1;const _0x5b7581=_0x5231c1['lastIndexOf']('\x20',0x93);return _0x5231c1['substring'](0x0,_0x5b7581>-0x1?_0x5b7581:0x93)+'...';}['_attachContextActions'](){const _0x39fcb6=this['element']['querySelector']('.ck-context'),_0x20f76f=_0x39fcb6['querySelector']('.ck-context__value');this['listenTo'](_0x39fcb6,'mouseenter',()=>{_0x20f76f['offsetWidth']<_0x20f76f['scrollWidth']&&_0x39fcb6['classList']['add']('overlay');}),this['listenTo'](_0x39fcb6,'mouseleave',()=>{_0x39fcb6['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x28cc48 of this['focusables'])this['focusTracker']['add'](_0x28cc48['element']),this['keystrokes']['listenTo'](_0x28cc48['element']);}['_createContextView'](){const _0x15b39e=new oe(this['locale']);return _0x15b39e['bind']('contextValue')['to'](this),_0x15b39e;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x80776c,_0x223c7b,_0x4f605b,_0x3f2a57){super(_0x80776c),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x223c7b,this['_localUser']=_0x4f605b,this['_config']=_0x3f2a57,this['commentThreadHeaderView']=new Xt(_0x80776c,_0x223c7b),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x80776c,N(_0x80776c,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x80776c,_0x223c7b,Object['assign']({'CommentView':this['_config']['CommentView']},_0x3f2a57)),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',(_0x17e29c,_0x55ab4a)=>_0x17e29c||!!_0x55ab4a),this['bind']('isUnlinked')['to'](_0x223c7b,'unlinkedAt',_0x42a98e=>!!_0x42a98e),this['bind']('ariaLabel')['to'](this,'length',_0x59bd88=>{const _0x1dbe66=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x59bd88,_0x1dbe66]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x144d0f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x37e2ac({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x355761=>_0x355761['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 _0x15597d=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x3b5142=_0x15597d['commentInputView'];return _0x15597d['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x3b5142,'value',(_0xd67c4d,_0x270731,_0x5d9914,_0x14d4c7,_0x133397)=>!!_0x133397||!!_0x14d4c7&&_0x5d9914&&!_0x270731||_0xd67c4d&&_0x5d9914&&!_0x270731),_0x3b5142['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x53ba42,_0x29f43b,_0x48fbe3)=>{let _0x407429;return _0x407429=_0x48fbe3&&_0x29f43b?'Reply\x20to\x20reopen\x20discussion...':_0x53ba42?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x407429);}),_0x3b5142['bind']('submitLabel')['to'](this,'length',_0x4c3d2d=>N(this['locale'],_0x4c3d2d?'Reply':'Comment')),_0x3b5142['on']('submit',(_0x44e50c,_0x529b82)=>{this['fire']('addComment',_0x529b82),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x3b5142['on']('cancel',()=>{this['focus']();}),_0x3b5142['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x3b5142['on']('cancel',_0x19213a=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x19213a['stop']());}),this['on']('change:isActive',(_0x5e9a3c,_0x154d14,_0x3b800d)=>{_0x3b800d||this['length']||_0x3b5142['value']||this['fire']('removeCommentThread');}),_0x15597d;}}class gt extends/* #__PURE__ -- @preserve */
27
- ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x27c54e,_0x2ed8f0,_0x475bf2,_0xf4c871){super(_0x27c54e,_0x2ed8f0,_0x475bf2,_0xf4c871),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x27c54e,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x1eefb7,_0x20420a,_0x4898b7)=>{_0x4898b7||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x4347eb,_0x2b41f9,_0xf468b9)=>{_0xf468b9&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x5744dd=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x5744dd['if']('isActive','ck-thread--active'),_0x5744dd['if']('isUnlinked','ck-thread--unlinked'),_0x5744dd['to']('actionIndicator',_0x4b549f=>_0x4b549f?'ck-thread--'+_0x4b549f:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x5744dd['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 _0x1a0222 of this['commentsListView']['commentViews'])_0x1a0222['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x558a72}=this,_0xba8fac=this['commentsListView']['commentViews']['get'](0x0);_0xba8fac===this['_boundFirstCommentView']||_0xba8fac['isSystemComment']||(this['_boundFirstCommentView']=_0xba8fac,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0xba8fac,'actionIndicator',_0x3c52b5=>'remove'===_0x3c52b5?'remove':null),_0xba8fac['placeholder']=N(_0x558a72,'Write\x20a\x20comment...'),_0xba8fac['removeButton']['on']('execute',_0x49c5bd=>{_0x49c5bd['stop'](),this['showConfirm'](N(_0x558a72,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0xba8fac['focus']();}),_0xba8fac['actionBar']['add'](this['resolveButton'],0x0),_0xba8fac['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x33200f=new _0x5731dd(this['locale']);return _0x33200f['label']=N(this['locale'],'Resolve'),_0x33200f['tooltip']=N(this['locale'],'Resolve'),_0x33200f['icon']=_0xe38e81,_0x33200f['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x33200f['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x30a525=>!_0x30a525),_0x33200f['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x2ddcce,_0x265159)=>_0x2ddcce&&!_0x265159),_0x33200f['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x33200f;}['_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(_0x2f6f87){super(_0x2f6f87),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x1524ab,_0x1f7809,_0x5cb7ee)=>{this['element']['innerHTML']=_0x5cb7ee;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x26fd72,_0x434ab2,_0x3f3e04){super(_0x26fd72),this['_model']=_0x434ab2,this['_config']=_0x3f3e04,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x434ab2,'content',_0x434ab2,'authoredAt',(_0xef02a1,_0x4ee9e7)=>N(_0x26fd72,'COMMENT_ARIA_LABEL',[_0x434ab2['author']['name'],_0x3f3e04['formatDateTime'](_0x4ee9e7),new DOMParser()['parseFromString'](_0xef02a1,'text/html')['body']['textContent'],_0x434ab2['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x26fd72,N(_0x26fd72,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x437229(),this['focusTracker']=new _0x144d0f(),this['keystrokes']=new jt(),this['focusCycler']=new _0x37e2ac({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x285057=>_0x285057['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 _0x3270ca=new is(this['locale']);return _0x3270ca['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x1c68de,_0x456654)=>_0x456654?ts(_0x1c68de,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x1c68de),_0x3270ca;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x536adb=new es(this['locale'],this['_config']['editorConfig']);return _0x536adb['value']=this['_model']['content'],_0x536adb['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x536adb['submitLabel']=N(this['locale'],'Save'),_0x536adb['on']('submit',(_0x5be790,_0x32dd9d)=>{this['fire']('updateComment',this['_model']['id'],_0x32dd9d),this['switchToDisplayMode'](),this['focus']();}),_0x536adb['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x536adb['once']('editorReady',()=>{_0x536adb['focus']();}),_0x536adb['createEditor'](),_0x536adb['delegate']('editorReady')['to'](this),_0x536adb['delegate']('editorDestroyed')['to'](this),_0x536adb;}['_setupKeyboardNavigation'](){const _0x3e42fe=this['element'];this['keystrokes']['listenTo'](_0x3e42fe);for(const _0x50269e of this['focusables'])this['focusTracker']['add'](_0x50269e['element']),this['keystrokes']['listenTo'](_0x50269e['element']);this['focusables']['on']('change',(_0x53911a,_0x3ab2ec)=>{for(const _0x74a60e of _0x3ab2ec['removed'])this['focusTracker']['remove'](_0x74a60e['element']),this['keystrokes']['stopListening'](_0x74a60e['element']);for(const _0x1291f3 of _0x3ab2ec['added'])this['focusTracker']['add'](_0x1291f3['element']),this['keystrokes']['listenTo'](_0x1291f3['element']);}),this['keystrokes']['set']('enter',(_0x2cfeab,_0x34d33f)=>{_0x3e42fe===_0x2cfeab['target']&&(this['focusCycler']['focusFirst'](),_0x34d33f());}),this['keystrokes']['set']('esc',(_0x7ba1b2,_0x1f9e0b)=>{_0x3e42fe!==_0x7ba1b2['target']&&(this['focus'](),_0x1f9e0b());});}}class Tt extends/* #__PURE__ -- @preserve */
28
- ti(di){['actionBar'];['userView'];constructor(_0x29fd43,_0x5cc38f,_0x304d94){super(_0x29fd43,_0x5cc38f,_0x304d94),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x29fd43,'Reply...')),this['bind']('authoredAt')['to'](_0x5cc38f),this['bind']('resolvedAt')['to'](_0x5cc38f),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 _0x25fda7(_0x29fd43,_0x5cc38f['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x5cc38f,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x841e02=this['bindTemplate'],_0x34cfd9=[{'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':_0x841e02['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x841e02['to']('authoredAt',_0x553531=>this['_config']['formatDateTime'](_0x553531))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x841e02['if']('isEditMode','ck-comment__actions--hidden'),_0x841e02['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']&&_0x34cfd9['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper'],'tabindex':-0x1,'aria-label':_0x841e02['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x841e02['if']('isEditMode','ck-comment--edit'),_0x841e02['if']('isSystemComment','ck-comment--info'),_0x841e02['to']('actionIndicator',_0xcc03c3=>_0xcc03c3?'ck-comment--'+_0xcc03c3:'')],'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':_0x34cfd9}]}]};}['_createEditButton'](){const _0x76e90=new _0x6b909b(this['locale']);return _0x76e90['label']=N(this['locale'],'Edit'),_0x76e90['icon']=_0x4fecaf,_0x76e90['withText']=!0x0,_0x76e90['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x76e90['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x42064a=>!_0x42064a),_0x76e90['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x76e90['on']('execute',()=>this['switchToEditMode']()),_0x76e90;}['_createRemoveButton'](){const _0x2b76cf=new _0x6b909b(this['locale']);return _0x2b76cf['label']=N(this['locale'],'Remove'),_0x2b76cf['icon']=_0x1b0bf0,_0x2b76cf['withText']=!0x0,_0x2b76cf['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x2b76cf['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x46c59d=>!_0x46c59d),_0x2b76cf['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x2b76cf['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x2b76cf;}['_createDropdown'](){const _0x2cea4f=_0x539082(this['locale'],_0x1013b5),_0x312c8b=_0x2cea4f['panelView']['children'],_0x2590b4=new _0x2ad704(this['locale']),_0x2f7016=_0x2cea4f['bindTemplate'];_0x4b8bb2(_0x2cea4f,()=>this['items']['find'](_0x2f05cb=>_0x2f05cb['isVisible'])),_0x2cea4f['extendTemplate']({'attributes':{'class':[_0x2f7016['if']('isVisible','ck-hidden',_0x20be75=>!_0x20be75)]}});const _0x1c6004=(_0x5db6c1,_0x47d6d4=-0x1)=>{const _0x1d081f=new _0x3556d2(this['locale']);_0x1d081f['children']['add'](_0x5db6c1);const _0x84db5=_0x47d6d4>-0x1?_0x47d6d4:_0x2590b4['items']['length'];_0x2590b4['items']['add'](_0x1d081f,_0x84db5);const _0x4f50b9=Array['from'](this['items']);_0x2cea4f['unbind']('isEnabled','isVisible'),_0x2cea4f['bind']('isEnabled')['toMany'](_0x4f50b9,'isEnabled',(..._0x59cdab)=>_0x59cdab['some'](_0x3495ba=>_0x3495ba)),_0x2cea4f['bind']('isVisible')['toMany'](_0x4f50b9,'isVisible',(..._0x1d5e18)=>_0x1d5e18['some'](_0x4290a5=>_0x4290a5));};_0x2cea4f['panelPosition']='sw',_0x2cea4f['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x56e494});for(const _0x44be25 of this['items'])_0x1c6004(_0x44be25);return _0x312c8b['add'](_0x2590b4),_0x2cea4f['listenTo'](this['items'],'add',(_0x1bccd5,_0x534992,_0x1d3b24)=>{_0x1c6004(_0x534992,_0x1d3b24);}),_0x2cea4f['listenTo'](this['items'],'remove',(_0x5ba3a9,_0x5b3c37,_0x1c2551)=>{_0x2590b4['items']['remove'](_0x1c2551);}),_0x2cea4f;}['_attachActions'](_0x57b5c0,_0x21e212){const _0x1524fb=_0x57b5c0&&_0x57b5c0['element'];_0x1524fb&&(this['listenTo'](_0x1524fb,'mouseenter',()=>this['actionIndicator']=_0x21e212),this['listenTo'](_0x1524fb,'focus',()=>this['actionIndicator']=_0x21e212),this['listenTo'](_0x1524fb,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x1524fb,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x9a3ba1=super['_createCommentInputView']();return _0x9a3ba1['bind']('placeholder')['to'](this),_0x9a3ba1;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x4b221a){const _0x434137=Dt(_0x4b221a,0x1e),_0x143771=new MutationObserver(_0x3a820f=>{for(const _0x56cbd0 of _0x3a820f)('attributes'==_0x56cbd0['type']&&'class'==_0x56cbd0['attributeName']||'childList'==_0x56cbd0['type']||'characterData'==_0x56cbd0['type'])&&_0x434137();});return{'attach'(_0x56f19b){_0x143771['observe'](_0x56f19b,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x143771['disconnect'](),_0x434137['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x12cb3a,_0x4606ca){super(_0x12cb3a),this['id']=_0x114214(),this['focusTracker']=new _0x144d0f(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x3b7775,_0x3e509c)=>this['fire']('Esc',_0x3e509c)),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'](_0x4606ca),this['mainView']=_0x4606ca;const _0x4cd73f=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x4cd73f['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 _0x52dec7=this['element']['clientHeight'];_0x52dec7&&(this['height']=_0x52dec7);}}class T extends/* #__PURE__ -- @preserve */
29
- _0x22b275(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x50da0e,target:_0x5314c0,type:_0x51a9d0,isVisible:_0x2d1890=!0x0}){super(),this['view']=_0x50da0e,this['view']['element']||this['view']['render'](),this['_type']=_0x51a9d0,this['_target']=_0x5314c0,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x1b1267([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x29636a,_0x5bb920)=>{this['view']['focusTracker']['add'](_0x5bb920);}),this['focusableElements']['on']('remove',(_0x291c03,_0x2bb2d0)=>{this['view']['focusTracker']['remove'](_0x2bb2d0);}),this['set']('isVisible',_0x2d1890);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x1e2752=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x1e2752),_0x1e2752;}get['targetRect'](){const _0x249ad1=this['target'];if(null===_0x249ad1)return null;if(_0x249ad1 instanceof _0x2227f5)return _0x249ad1;const _0x2c390e=_0x249ad1['filter'](_0x590b75=>function(_0x454949){const _0x3b797c=_0x454949['offsetParent'];if(_0x3b797c)return!0x0;const _0x9bee3d=_0x454949['getClientRects']()['item'](0x0);return!!_0x9bee3d;}(_0x590b75));return 0x0===_0x2c390e['length']?null:new _0x2227f5(_0x2c390e[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x5f1ad2){this['view']['isActive']=_0x5f1ad2,this['view']['mainView']['isActive']=_0x5f1ad2;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x3281b5){if(!(null===_0x3281b5||_0x3281b5 instanceof _0x2227f5||Array['isArray'](_0x3281b5)&&_0x3281b5['every'](_0x232b38=>fi(_0x232b38))))throw new _0x498a52('annotation-invalid-target',null,{'target':_0x3281b5});}['_getNormalizedTarget'](){const _0x4dd6be='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0x4dd6be)?[_0x4dd6be]:_0x4dd6be;}}function fi(_0x12379a){return null!==_0x12379a&&'object'==typeof _0x12379a&&'nodeType'in _0x12379a&&0x1===_0x12379a['nodeType'];}class S extends _0x1b1267{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x162460=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x144d0f(),this['_focusTracker']['on']('change:isFocused',(_0x4fe347,_0xbf9371,_0x376f76)=>{_0x376f76||this['fire']('blur');});for(const _0x3fce19 of _0x162460)this['add'](_0x3fce19);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x4622d1){if(this['has'](_0x4622d1))throw new _0x498a52('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x4622d1['innerView'],_0x4622d1),this['_viewToAnnotation']['set'](_0x4622d1['view'],_0x4622d1);for(const _0x30dc4c of _0x4622d1['focusableElements'])this['_focusTracker']['add'](_0x30dc4c);this['listenTo'](_0x4622d1['focusableElements'],'add',(_0x40c804,_0x2ddabb)=>{this['_focusTracker']['add'](_0x2ddabb);}),this['listenTo'](_0x4622d1['focusableElements'],'remove',(_0x4cd3d2,_0x4e59f6)=>{this['_focusTracker']['remove'](_0x4e59f6);}),this['listenTo'](_0x4622d1['view']['focusTracker'],'change:isFocused',(_0xf0d777,_0x308177,_0x4e1795)=>{_0x4e1795&&this['fire']('focus',_0x4622d1);}),_0x4622d1['updateTargetRect']();const _0x152716=this['_getOrderInContent'](_0x4622d1['view']['targetRect']);return super['add'](_0x4622d1,_0x152716);}['remove'](_0x1b3da5){if(!this['has'](_0x1b3da5))throw new _0x498a52('annotationcollection-not-existing-item',null);this['stopListening'](_0x1b3da5['view']['focusTracker']),this['stopListening'](_0x1b3da5['focusableElements']);for(const _0x1a54c3 of _0x1b3da5['focusableElements'])this['_focusTracker']['remove'](_0x1a54c3);return this['_viewToAnnotation']['delete'](_0x1b3da5['view']),this['_innerViewToAnnotation']['delete'](_0x1b3da5['innerView']),super['remove'](_0x1b3da5);}['getByInnerView'](_0x47f15f){return this['_innerViewToAnnotation']['get'](_0x47f15f);}['getByView'](_0x359d7d){return this['_viewToAnnotation']['get'](_0x359d7d);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x383289 of this)_0x383289['updateTargetRect']();this['_sort']();}['_sort'](){const _0x232f93=Array['from'](this)['sort']((_0x3ea454,_0x4ac61b)=>w(_0x3ea454['view']['targetRect'],_0x4ac61b['view']['targetRect']));for(let _0x1d2cb1=_0x232f93['length']-0x1;_0x1d2cb1>0x0;_0x1d2cb1--){const _0x268393=_0x232f93[_0x1d2cb1];_0x1d2cb1!==this['getIndex'](_0x268393)&&(this['remove'](_0x268393),this['add'](_0x268393));}}['_getOrderInContent'](_0x5affe9){let _0x54872b=0x0;if(!_0x5affe9)return this['length'];for(const _0x37dd18 of this){const _0x2f2075=_0x37dd18['view']['targetRect'];if(_0x2f2075){if(w(_0x5affe9,_0x2f2075)<0x0)return _0x54872b;_0x54872b++;}}return _0x54872b;}}function v({source:_0x38f325,target:_0x2ef6b4,filter:_0x52293f}){for(const _0x3a316a of _0x38f325)_0x52293f(_0x3a316a)&&_0x2ef6b4['add'](_0x3a316a);_0x2ef6b4['listenTo'](_0x38f325,'add',(_0x1cb50e,_0x4cd757)=>{_0x52293f(_0x4cd757)&&_0x2ef6b4['add'](_0x4cd757);}),_0x2ef6b4['listenTo'](_0x38f325,'remove',(_0x163f18,_0x59367d)=>{_0x2ef6b4['has'](_0x59367d)&&_0x2ef6b4['remove'](_0x59367d);});}function w(_0x177aa7,_0x156ad8){if(null===_0x177aa7&&null===_0x156ad8)return 0x0;if(null===_0x177aa7)return-0x1;if(null===_0x156ad8)return 0x1;const _0x510b50=_0x177aa7['top']-_0x156ad8['top'];return 0x0==_0x510b50?_0x177aa7['left']-_0x156ad8['left']:_0x510b50;}class y extends _0x51795f{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x43129f){if(super(_0x43129f),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x43129f instanceof _0x1e4091){const _0x4111d9=_0x43129f['locale'];_0x43129f['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x4111d9,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x2246dc){this['collection']['add'](_0x2246dc);}['remove'](_0x59ed77){this['collection']['remove'](_0x59ed77),_0x59ed77['destroy']();}['refreshVisibility'](){for(const _0x1ad943 of this['collection'])_0x1ad943['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x3f18d8){return this['collection']['getByInnerView'](_0x3f18d8);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x32d615 of this['collection'])_0x32d615['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x3c3272){this['fire']('_activateAnnotation',_0x3c3272);}['createAnnotation'](_0x286e67){return new T(_0x286e67);}['createAnnotationView'](_0x508970,_0xadd02b){return new E(_0x508970,_0xadd02b);}['_addActiveAnnotation'](_0x7a30b8){const _0x3a3f34=new Set(this['activeAnnotations']);_0x3a3f34['add'](_0x7a30b8),this['activeAnnotations']=_0x3a3f34;}['_removeActiveAnnotation'](_0x299340){const _0x4e469e=new Set(this['activeAnnotations']);_0x4e469e['delete'](_0x299340),this['activeAnnotations']=_0x4e469e;}['_bindAnnotationsToVisibleAnnotations'](){const _0x11ec00=this['collection'],_0x41323a=this['_visibleAnnotations'];function _0x5a93fc(_0xc8b83e){const _0x107e7f=_0xc8b83e['source'];_0x107e7f['isVisible']&&!_0x41323a['has'](_0x107e7f)?_0x41323a['add'](_0x107e7f):!_0x107e7f['isVisible']&&_0x41323a['has'](_0x107e7f)&&_0x41323a['remove'](_0x107e7f),_0x107e7f['view']['focusTracker']['remove'](_0x107e7f['view']['element']),_0x107e7f['view']['focusTracker']['add'](_0x107e7f['view']['element']);}this['listenTo'](_0x11ec00,'add',(_0x2c18a5,_0x1113b5)=>{_0x1113b5['isVisible']&&_0x41323a['add'](_0x1113b5),this['listenTo'](_0x1113b5,'change:isVisible',_0x5a93fc);}),this['listenTo'](_0x11ec00,'remove',(_0x371031,_0x3c7478)=>{_0x41323a['has'](_0x3c7478)&&_0x41323a['remove'](_0x3c7478),this['stopListening'](_0x3c7478,'change:isVisible',_0x5a93fc);});}['_setupEnterAnnotationKeystroke'](){const _0x366f0a=_0x46db9b=>{_0x46db9b['on']('ready',()=>{_0x46db9b['keystrokes']['set'](_0x2c7af9,(_0x3f82ec,_0x55879c)=>{const _0x436be5=_0x31b8b0(this['activeAnnotations']['values']());_0x436be5&&(_0x436be5['view']['focus'](),_0x55879c());});});};this['context']instanceof _0x1e4091?_0x366f0a(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x240428,_0x38185c)=>{_0x366f0a(_0x38185c);});}['_setupEscapeAnnotationHandling'](){const _0x5845f6=_0x3a2a5d=>{const _0x50848e=_0x3a2a5d['source'],_0x50d6b3=[];let _0x4b5ee1;if(Array['isArray'](_0x50848e['target'])){_0x4b5ee1=_0x50848e['target'][0x0],this['context']instanceof _0x1e4091?_0x50d6b3['push'](this['context']):this['context']['editors']&&_0x50d6b3['push'](...this['context']['editors']);for(const _0x2e718e of _0x50d6b3)for(const _0x53f727 of _0x2e718e['editing']['view']['domRoots']['values']())if(_0x53f727['contains'](_0x4b5ee1))return void _0x2e718e['editing']['view']['focus']();_0x4b5ee1['focus']();}};this['listenTo'](this['collection'],'add',(_0x2daf09,_0x500714)=>{this['listenTo'](_0x500714,'escape',_0x5845f6,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x3d0b47,_0x102244)=>{this['stopListening'](_0x102244,'escape',_0x5845f6);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x51795f{['_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(_0x59a8f7){super(_0x59a8f7),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x74aaa9=this['context']['config'];_0x74aaa9['define']('comments.maxCommentsWhenCollapsed',0x2),_0x74aaa9['define']('comments.maxThreadTotalWeight',0x1f4),_0x74aaa9['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x74aaa9['define']('comments.CommentThreadView',gt),_0x74aaa9['define']('comments.CommentView',Tt),_0x74aaa9['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x154903=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x148aea,_0x40f42f)=>this['_addCommentThread'](_0x40f42f)),this['on']('submitCommentThread',(_0x1078dd,_0x184648)=>this['_submitCommentThread'](_0x184648)),this['on']('resolveCommentThread',(_0x319d32,_0xf09bdf)=>this['_resolveCommentThread'](_0xf09bdf)),this['on']('resolveCommentThread',(_0x100bb5,_0x554d90)=>this['_updateActiveAnnotation'](_0x554d90),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x25a3ec,_0x3336b9)=>this['_reopenCommentThread'](_0x3336b9)),this['on']('reopenCommentThread',(_0xb7d401,_0x13b8ab)=>this['_updateActiveAnnotation'](_0x13b8ab),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x519601,_0xd7bed4)=>this['_removeCommentThread'](_0xd7bed4)),this['on']('updateCommentThread',(_0x38b977,_0x564628)=>this['_updateCommentThread'](_0x564628)),this['on']('updateCommentThread',(_0x3537f0,_0x1e6a02)=>this['_updateActiveAnnotation'](_0x1e6a02),{'priority':'lowest'}),this['on']('addComment',(_0x49e91d,_0x3edbcf)=>this['_addComment'](_0x3edbcf)),this['on']('updateComment',(_0x4bee8e,_0x420a92)=>this['_updateComment'](_0x420a92)),this['on']('removeComment',(_0x1ac1ff,_0x2242d0)=>this['_removeComment'](_0x2242d0)),this['on']('addComment',(_0x57d88f,{threadId:_0x5a58da,isFromAdapter:_0x3a06a7})=>{if(_0x3a06a7)return;const _0x5badb0=this['getCommentThread'](_0x5a58da),_0x3e8aa3=_0x5badb0&&this['_threadToController']['get'](_0x5badb0);_0x3e8aa3&&_0x3e8aa3['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x154903,'change:activeAnnotations',(_0x331b5f,_0x189e9a,_0x3eb351)=>{const _0x5eb95d=Array['from'](_0x3eb351)['map'](_0x2d2543=>this['_viewToController']['get'](_0x2d2543['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x5eb95d?_0x5eb95d['model']:null;});}set['adapter'](_0x12984c){if(this['_adapter'])throw new _0x498a52('commentsrepository-adapter-already-set');this['_adapter']=_0x12984c;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x1609e8=_t,threadId:_0x4d096b=_0x114214(),comments:_0xcaa349=[],unlinkedAt:_0x14bdc1=null,resolvedAt:_0x26b3da=null,resolvedBy:_0x5f024e=null,target:_0x4fa4f3=null,context:_0x557167=null,attributes:_0xdb126b={},isResolvable:_0x4b7df0=!0x0,isSubmitted:_0x48aa8e=!0x1,isFromAdapter:_0x2636c2=!0x1}={}){return this['fire'](Nt('addCommentThread',_0x1609e8),{'channelId':_0x1609e8,'threadId':_0x4d096b,'comments':_0xcaa349,'unlinkedAt':_0x14bdc1,'resolvedAt':_0x26b3da,'resolvedBy':_0x5f024e,'target':_0x4fa4f3,'context':_0x557167,'attributes':_0xdb126b,'isFromAdapter':_0x2636c2,'isResolvable':_0x4b7df0,'isSubmitted':_0x48aa8e}),this['getCommentThread'](_0x4d096b);}['openNewCommentThread']({channelId:_0x5e9dd9=_t,threadId:_0x2e36f0=_0x114214(),target:_0x28600b,context:_0x1ad317=null,isResolvable:_0x18cdc6=!0x0}){if(this['_readOnlyChannels']['has'](_0x5e9dd9)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x28600b)throw new _0x498a52('commentsrepository-missing-target');const _0xd2ad24=this['addCommentThread']({'channelId':_0x5e9dd9,'threadId':_0x2e36f0,'target':_0x28600b,'context':_0x1ad317,'isResolvable':_0x18cdc6});if(!_0xd2ad24)return null;const _0x1c6ae0=this['_threadToController']['get'](_0xd2ad24),_0x83f61=_0x1c6ae0['view']['commentThreadInputView']['commentInputView'],_0x4a2e08=this['context']['plugins']['get'](y),_0xfda713=_0x4a2e08['getByInnerView'](_0x1c6ae0['view']);return _0x4a2e08['activate'](_0xfda713),_0x83f61['once']('editorReady',()=>_0x83f61['focus']()),_0xd2ad24;}['hasCommentThread'](_0x57f859){if('string'!=typeof _0x57f859)throw new _0x498a52('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x57f859);}['updateCommentThread']({channelId:_0x4c4750=_t,threadId:_0xf18fae,context:_0x2ac1ca,unlinkedAt:_0x4d2152,attributes:_0x3c6de9,isFromAdapter:_0x407f3d=!0x1}){return this['fire'](Nt('updateCommentThread',_0x4c4750),{'channelId':_0x4c4750,'threadId':_0xf18fae,'context':_0x2ac1ca,'unlinkedAt':_0x4d2152,'attributes':_0x3c6de9,'isFromAdapter':_0x407f3d}),this['getCommentThread'](_0xf18fae);}['getCommentThread'](_0x1ecc52){if('string'!=typeof _0x1ecc52)throw new _0x498a52('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x1ecc52);}['fetchCommentThread']({channelId:_0x4f8788,threadId:_0x1e882f}={}){const _0xa196a6=this['getCommentThread'](_0x1e882f);if(_0xa196a6)return Promise['resolve'](_0xa196a6);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x498a52('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x4f8788,'threadId':_0x1e882f})['then'](_0x3a3e60=>this['hasCommentThread'](_0x1e882f)?this['getCommentThread'](_0x1e882f):_0x3a3e60?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x4f8788},_0x3a3e60)):void 0x0)['catch'](_0x5d10cb=>{throw console['error'](_0x5d10cb),new _0x498a52('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x2c956d,skipNotAttached:_0x20c4e7=!0x1,skipEmpty:_0x2793ba=!0x1,toJSON:_0x1869f6=!0x1}={}){const _0x284d24=[];for(const _0x1bf13b of this['_threads']['values']())_0x2c956d&&_0x1bf13b['channelId']!==_0x2c956d||_0x20c4e7&&!_0x1bf13b['isAttached']||_0x2793ba&&0x0===_0x1bf13b['length']||_0x284d24['push'](_0x1bf13b);return _0x1869f6?_0x284d24['map'](_0x2355fe=>_0x2355fe['toJSON']()):_0x284d24;}['getAnnotationForCommentThread'](_0x3fe167){const _0x484757=this['_threadToController']['get'](_0x3fe167);if(!_0x484757)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x484757['view'])||null;}['getCommentThreadForAnnotation'](_0x3c5749){const _0x53158b=this['_viewToController']['get'](_0x3c5749['innerView']);return _0x53158b?_0x53158b['model']:null;}['setActiveCommentThread'](_0x1ef977){const _0x5775a6=this['context']['plugins']['get'](y);if(!_0x1ef977)return void(this['activeCommentThread']&&_0x5775a6['deactivateAll']());const _0x48d3de=this['getCommentThread'](_0x1ef977);if(!_0x48d3de)throw new _0x498a52('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x1ef977});if(!this['_threadToController']['has'](_0x48d3de))throw new _0x498a52('commentsrepository-active-not-attached',null,{'threadId':_0x1ef977});const _0x3472e5=_0x5775a6['getByInnerView'](this['_threadToController']['get'](_0x48d3de)['view']);_0x5775a6['activate'](_0x3472e5);}['switchReadOnly'](_0x4929d2,_0x2e6b0e){_0x4929d2?this['_readOnlyChannels']['add'](_0x2e6b0e):this['_readOnlyChannels']['delete'](_0x2e6b0e),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x4028e9){return this['_readOnlyChannels']['has'](_0x4028e9)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x4b9732,_0x36e2ee){return new vt(_0x4b9732,_0x36e2ee);}['setPermissions'](_0x21d020,_0x43e506=_t){this['_permissions']['set'](_0x43e506,_0x21d020),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x3c8d81=_t){return this['_permissions']['has'](_0x3c8d81)?this['_permissions']['get'](_0x3c8d81):bt;}['_addCommentThread']({channelId:_0x5a8797,threadId:_0x19feb6,comments:_0x4f7d29,unlinkedAt:_0x78d275,resolvedAt:_0x46c4d1,resolvedBy:_0x5a40f6,target:_0xb33154,context:_0x36dd38,attributes:_0x26d69f,isFromAdapter:_0x574a31,isResolvable:_0x2896c2,isSubmitted:_0x20ec26}){if('string'!=typeof _0x19feb6)throw new _0x498a52('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x19feb6});if(this['hasCommentThread'](_0x19feb6))throw new _0x498a52('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x19feb6});const _0x27cb08=new pi(this,{'channelId':_0x5a8797,'id':_0x19feb6,'context':_0x36dd38,'attributes':_0x26d69f,'unlinkedAt':_0x78d275,'resolvedAt':_0x46c4d1,'resolvedBy':_0x5a40f6?this['context']['plugins']['get'](it)['getUser'](_0x5a40f6):null,'isResolvable':_0x2896c2,'isSubmitted':_0x20ec26||_0x574a31});this['_threads']['set'](_0x19feb6,_0x27cb08);for(const _0xd9cd0 of _0x4f7d29)_0x27cb08['_add'](this['_createNewComment']({'threadId':_0x19feb6,..._0xd9cd0}));return _0xb33154&&_0x27cb08['attachTo'](_0xb33154),_0x574a31||!_0x27cb08['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x5a8797,'threadId':_0x19feb6});}['_submitCommentThread']({channelId:_0x1ce81d,threadId:_0x39444a}){if(!this['hasCommentThread'](_0x39444a))throw new _0x498a52('commentsrepository-missing-comment-thread',this);const _0x24d58b=this['getCommentThread'](_0x39444a);if(_0x24d58b['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x1ac1e1,comments:_0x4d8e83,resolvedAt:_0x3c6f52,resolvedBy:_0xb2932f,context:_0x1a4c2a,attributes:_0x294e28}=_0x24d58b,_0xa53ea=this['context']['plugins']['get']('PendingActions'),_0x4a2884=_0xa53ea['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x1ce81d,'threadId':_0x1ac1e1,'comments':_0x4d8e83['map'](_0x1269be=>_0x1269be['toJSON']()),'resolvedAt':_0x3c6f52,'resolvedBy':_0xb2932f?_0xb2932f['id']:_0xb2932f,'context':_0x1a4c2a,'attributes':_0x294e28})['then'](({comments:_0x3f979a})=>{_0xa53ea['remove'](_0x4a2884);for(const _0x2bb655 of _0x3f979a)this['_updateComment']({'channelId':_0x1ce81d,'threadId':_0x39444a,'commentId':_0x2bb655['commentId'],'createdAt':_0x2bb655['createdAt'],'isFromAdapter':!0x0});})['catch'](_0xd21ae5=>{throw console['error'](_0xd21ae5),new _0x498a52('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x3928e6,target:_0x4d8f75}){const _0x27f302=this['getCommentThread'](_0x3928e6);if(!_0x27f302)throw new _0x498a52('commentsrepository-attach-missing-comment-thread',this);const _0x5233ff=this['context']['plugins']['get']('PendingActions'),_0x59d670=this['context']['plugins']['get'](y),_0x4fde67=this['_createCommentThreadView'](_0x27f302),_0x49e80b=new vt(_0x27f302,_0x4fde67);let _0x13345c=null;_0x4fde67['on']('change:isDirty',(_0x58ede1,_0x4cfebe,_0x450d8a)=>{_0x450d8a?_0x13345c=_0x5233ff['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x13345c&&(_0x5233ff['remove'](_0x13345c),_0x13345c=null);}),this['_threadToController']['set'](_0x27f302,_0x49e80b),this['_viewToController']['set'](_0x4fde67,_0x49e80b);const _0x3c7018=new E(this['context']['locale'],_0x4fde67);_0x3c7018['bind']('length')['to'](_0x4fde67),_0x3c7018['bind']('isDirty')['to'](_0x4fde67,'isDirty',_0x4fde67,'length',(_0x329d84,_0x24e4b3)=>_0x329d84||!_0x24e4b3),_0x3c7018['bind']('isActive')['to'](_0x4fde67),_0x3c7018['type']='comment';const _0x5dfba1=new T({'view':_0x3c7018,'target':_0x4d8f75,'type':'comment','isVisible':!_0x27f302['archivedAt']&&!!('function'==typeof _0x4d8f75?_0x4d8f75():_0x4d8f75)});return _0x4fde67['on']('escape',()=>{_0x5dfba1['fire']('escape');}),this['_bindAnnotationToEditors'](_0x4fde67,_0x5dfba1),_0x59d670['add'](_0x5dfba1),_0x5dfba1;}['_bindAnnotationToEditors'](_0x1cd267,_0x2c9308){this['listenTo'](_0x1cd267,'editorReady',(_0x32513f,_0x521c43)=>{const _0x23d63c=_0x521c43['ui']['view']['body']['bodyCollectionContainer'];_0x2c9308['focusableElements']['add'](_0x23d63c),this['context']instanceof _0x1e4091&&this['context']['ui']['focusTracker']['add'](_0x23d63c);},{'priority':'highest'}),this['listenTo'](_0x1cd267,'editorDestroyed',(_0x131d83,_0x595c13)=>{const _0x5eff5c=_0x595c13['ui']['view']['body']['bodyCollectionContainer'];_0x2c9308['focusableElements']['has'](_0x5eff5c)&&_0x2c9308['focusableElements']['remove'](_0x5eff5c),this['context']instanceof _0x1e4091&&this['context']['ui']['focusTracker']['remove'](_0x5eff5c);});}['_unbindEditors'](_0x39a707){this['stopListening'](_0x39a707,'editorReady'),this['stopListening'](_0x39a707,'editorDestroyed');}['_createCommentThreadView'](_0xf13e79){const _0x4693e4=this['context']['plugins']['get'](it),{config:_0x3dbdab,locale:_0x69ff76}=this['context'],_0x28f09d=pt(_0x3dbdab['get']('locale'),_0x69ff76);return new(0x0,(_0x3dbdab['get']('comments'))['CommentThreadView'])(_0x69ff76,_0xf13e79,_0x4693e4['me'],{'editorConfig':{..._0x3dbdab['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x3dbdab['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x3dbdab['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x3dbdab['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x3dbdab['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x28f09d,'CommentView':_0x3dbdab['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x28f85d,channelId:_0x3de923,resolvedAt:_0x23d207,resolvedBy:_0x38f7b3,isFromAdapter:_0x4359da}){if(!this['hasCommentThread'](_0x28f85d))throw new _0x498a52('commentsrepository-missing-comment-thread',null,{'threadId':_0x28f85d});const _0x1e8891=this['getCommentThread'](_0x28f85d);if(_0x1e8891['isResolved'])throw new _0x498a52('commentsrepository-resolved-comment-thread',null,{'threadId':_0x28f85d});const _0x111434=this['context']['plugins']['get'](it);if(_0x1e8891['resolvedBy']=_0x111434['getUser'](_0x38f7b3),_0x1e8891['resolvedAt']=_0x23d207,_0x4359da||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x3bc3da=this['context']['plugins']['get']('PendingActions'),_0x96dab2=_0x3bc3da['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x3de923,'threadId':_0x28f85d})['then'](({resolvedAt:_0x1dbc2a,resolvedBy:_0x37a395})=>{_0x3bc3da['remove'](_0x96dab2),_0x1e8891['resolvedBy']['id']!==_0x37a395&&(_0x1e8891['resolvedBy']=_0x111434['getUser'](_0x37a395)),_0x1e8891['resolvedAt']=_0x1dbc2a;})['catch'](_0x3543ba=>{throw console['error'](_0x3543ba),new _0x498a52('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x2fc97c,channelId:_0x1be498,isFromAdapter:_0x210bb3}){if(!this['hasCommentThread'](_0x2fc97c))throw new _0x498a52('commentsrepository-missing-comment-thread',null,{'threadId':_0x2fc97c});const _0x423810=this['getCommentThread'](_0x2fc97c);if(!_0x423810['isResolved'])throw new _0x498a52('commentsrepository-reopen-comment-thread',null,{'threadId':_0x2fc97c});if(_0x423810['resolvedBy']=null,_0x423810['resolvedAt']=null,_0x210bb3||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x2d681b=this['context']['plugins']['get']('PendingActions'),_0xf078e5=_0x2d681b['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x1be498,'threadId':_0x2fc97c})['then'](()=>_0x2d681b['remove'](_0xf078e5))['catch'](_0x346c52=>{throw console['error'](_0x346c52),new _0x498a52('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x3c3720,isFromAdapter:_0x5e0ad6}){const _0x54a55a=this['getCommentThread'](_0x3c3720);if(!_0x54a55a)throw new _0x498a52('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x3c3720),this['_threads']['delete'](_0x3c3720),!_0x54a55a['isSubmitted']||_0x5e0ad6||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x2ea401=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5d32da}=_0x54a55a,_0x802d3b=_0x2ea401['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x5d32da,'threadId':_0x3c3720})['then'](()=>_0x2ea401['remove'](_0x802d3b))['catch'](_0x4286fb=>{throw console['error'](_0x4286fb),new _0x498a52('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x3b7bc5,unlinkedAt:_0x4ddc0f,context:_0x121dce,attributes:_0x5a5feb,isFromAdapter:_0x42fa87}){if('string'!=typeof _0x3b7bc5)throw new _0x498a52('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x3b7bc5});if(!this['hasCommentThread'](_0x3b7bc5))throw new _0x498a52('commentsrepository-missing-comment-thread',null,{'threadId':_0x3b7bc5});const _0x429d69=this['getCommentThread'](_0x3b7bc5);let _0x5f63a4=!0x1;if(void 0x0!==_0x121dce&&_0x429d69['context']!==_0x121dce&&(_0x429d69['context']=_0x121dce,_0x5f63a4=!0x0),void 0x0!==_0x4ddc0f&&_0x429d69['unlinkedAt']!==_0x4ddc0f&&(_0x429d69['unlinkedAt']=_0x4ddc0f,_0x5f63a4=!0x0),_0x5a5feb&&!At(_0x5a5feb,_0x429d69['attributes'])&&(_0x429d69['attributes']=_0x5a5feb,_0x5f63a4=!0x0),!_0x5f63a4)return Promise['resolve']();if(!_0x429d69['isSubmitted']||_0x42fa87||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x1ddf74=this['context']['plugins']['get']('PendingActions'),{channelId:_0x43cf52}=_0x429d69,_0x37fcef=_0x1ddf74['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x43cf52,'threadId':_0x3b7bc5,'context':_0x121dce,'unlinkedAt':_0x4ddc0f,'attributes':_0x5a5feb})['then'](()=>_0x1ddf74['remove'](_0x37fcef))['catch'](_0x380947=>{throw console['error'](_0x380947),new _0x498a52('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x366165){const _0x4c14b1=this['context']['plugins']['get'](y),_0x53745e=this['getCommentThread'](_0x366165);if(_0x53745e['_isAttached']=!0x1,this['_threadToController']['has'](_0x53745e)){const _0x406e7c=this['_threadToController']['get'](_0x53745e),_0x290d5d=_0x406e7c['view'],_0x8f4a0c=_0x4c14b1['getByInnerView'](_0x290d5d);this['_threadToController']['delete'](_0x53745e),this['_viewToController']['delete'](_0x290d5d),_0x8f4a0c&&_0x4c14b1['remove'](_0x8f4a0c),_0x406e7c['destroy'](),_0x290d5d['destroy']()['then'](()=>{this['_unbindEditors'](_0x290d5d);});}}['_updateActiveAnnotation']({threadId:_0x125295,resolvedAt:_0x2722be,unlinkedAt:_0x2f257b}){const _0x21c545=!!_0x2722be,_0x2c6359=this['context']['plugins']['get'](y),_0x5c61c9=this['getCommentThread'](_0x125295);if(this['_threadToController']['has'](_0x5c61c9)){const _0x47eef2=this['_threadToController']['get'](_0x5c61c9)['view'],_0x4e0c56=_0x2c6359['getByInnerView'](_0x47eef2);_0x4e0c56&&(_0x21c545&&_0x2c6359['_removeActiveAnnotation'](_0x4e0c56),_0x2f257b?_0x4e0c56['isVisible']=!0x1:_0x4e0c56['refreshVisibility']());}}['_getExternalAuthor'](_0x53b708){const _0x51ecb4=this['context']['plugins']['get'](it),_0x4e59dd=It('external:'+_0x53b708),_0x129490=_0x51ecb4['getUser'](_0x4e59dd);return _0x129490||_0x51ecb4['addUser']({'id':_0x4e59dd,'name':_0x53b708});}['_createNewComment']({threadId:_0x7cbe03,commentId:_0x1ce08c=_0x114214(),content:_0x4303c3,authorId:_0x325180,createdAt:_0x4ba788,attributes:_0x5c0e86}){if('string'!=typeof _0x1ce08c)throw new _0x498a52('commentsrepository-invalid-commentid');if('string'!=typeof _0x325180)throw new _0x498a52('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x4303c3||!_0x4303c3['trim']())throw new _0x498a52('commentsrepository-invalid-comment-content');const _0x42f374=this['context']['plugins']['get'](it)['getUser'](_0x325180);if(!_0x42f374)throw new _0x498a52('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x325180});let _0x5719b=null,_0x5c1f57=_0x4ba788;return _0x5c0e86?.['@external']&&(_0x5719b=this['_getExternalAuthor'](_0x5c0e86['@external']['authorName']),_0x5c1f57=new Date(_0x5c0e86['@external']['createdAt'])),new wi(this,{'threadId':_0x7cbe03,'id':_0x1ce08c,'author':_0x5719b||_0x42f374,'creator':_0x42f374,'content':_0x4303c3,'createdAt':_0x4ba788,'authoredAt':_0x5c1f57,'attributes':_0x5c0e86});}['_addComment'](_0x595046){let {threadId:_0x58e700,content:_0x2a73b8,attributes:_0xaf1070,isFromAdapter:_0x33bde3}=_0x595046;const _0x28f63c=this['getCommentThread'](_0x595046['threadId']);if(!_0x28f63c)throw new _0x498a52('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x266b14=this['_createNewComment'](_0x595046),{id:_0x1cfb88}=_0x266b14;if(_0x28f63c['_add'](_0x266b14),_0x33bde3||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x28f63c['isSubmitted'])return Promise['resolve']();const _0x2895f2=this['context']['plugins']['get']('PendingActions'),{channelId:_0x45796e}=_0x28f63c,_0x2da2df=_0x2895f2['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0xaf1070||(_0xaf1070={}),this['adapter']['addComment']({'channelId':_0x45796e,'threadId':_0x58e700,'commentId':_0x1cfb88,'content':_0x2a73b8,'attributes':_0xaf1070})['then'](_0x3fb47d=>{_0x2895f2['remove'](_0x2da2df),_0x3fb47d&&this['_updateComment']({'channelId':_0x45796e,'threadId':_0x58e700,'commentId':_0x1cfb88,'createdAt':_0x3fb47d['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x3dd966=>{throw console['error'](_0x3dd966),new _0x498a52('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x3c1257,commentId:_0x39b9b7,content:_0x906254,createdAt:_0x18ebc8,attributes:_0x1cec89,isFromAdapter:_0x6f5d67}){if(void 0x0!==_0x906254&&('string'!=typeof _0x906254||!_0x906254['trim']()['length']))throw new _0x498a52('commentsrepository-update-comment-invalid-content');const _0x48a372=this['getCommentThread'](_0x3c1257),_0x490631=_0x48a372['getComment'](_0x39b9b7);if(!_0x490631)throw new _0x498a52('commentsrepository-update-missing-comment',this);let _0x31d310=!0x1;if(_0x906254&&_0x906254!==_0x490631['content']&&(_0x490631['isEditable']||_0x6f5d67)&&(_0x490631['content']=_0x906254,_0x31d310=!0x0),_0x18ebc8&&_0x18ebc8!==_0x490631['createdAt']&&(_0x490631['createdAt']=_0x18ebc8,_0x490631['attributes']&&_0x490631['attributes']['@external']||(_0x490631['authoredAt']=_0x18ebc8),_0x31d310=!0x0),_0x1cec89&&!At(_0x1cec89,_0x490631['attributes'])&&(_0x490631['attributes']=_0x1cec89,_0x31d310=!0x0),!_0x31d310)return Promise['resolve']();if(_0x48a372['fire']('commentUpdated'),_0x6f5d67||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x13814a=this['context']['plugins']['get']('PendingActions'),{channelId:_0x8473e5}=this['getCommentThread'](_0x490631['threadId']),_0x4df4c2=_0x13814a['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x8473e5,'threadId':_0x3c1257,'commentId':_0x39b9b7,'content':_0x906254,'attributes':_0x1cec89})['then'](()=>_0x13814a['remove'](_0x4df4c2))['catch'](_0x2f4dc8=>{throw console['error'](_0x2f4dc8),new _0x498a52('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x297e76,commentId:_0x62c25a,isFromAdapter:_0x77a77d}){const _0xc59fd3=this['getCommentThread'](_0x297e76),_0x3d6ec7=_0xc59fd3['getComment'](_0x62c25a);if(!_0x3d6ec7)throw new _0x498a52('commentsrepository-remove-missing-comment',this);if(_0xc59fd3['_remove'](_0x3d6ec7),_0x77a77d||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x4c084c=this['context']['plugins']['get']('PendingActions'),{channelId:_0x301df1}=_0xc59fd3,_0x2c155f=_0x4c084c['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x301df1,'threadId':_0x297e76,'commentId':_0x62c25a})['then'](()=>_0x4c084c['remove'](_0x2c155f))['catch'](_0x1c6d7b=>{throw console['error'](_0x1c6d7b),new _0x498a52('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
- _0x22b275(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0xb38040,_0x56b399){super();const _0x58180b=_0x56b399['isResolvable'];this['channelId']=_0x56b399['channelId'],this['id']=_0x56b399['id'],this['comments']=new _0x1b1267(),this['_repository']=_0xb38040,this['_isAttached']=!0x1,this['_isSubmitted']=_0x56b399['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0xb38040,'_permissions',_0xb38040,'_readOnlyChannels',()=>_0xb38040['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0xb38040,'_permissions',()=>_0xb38040['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0xb38040,'_permissions',()=>{const _0x599cdd=_0xb38040['getPermissions'](this['channelId']);return _0x599cdd['write']||_0x599cdd['admin'];}),this['bind']('isResolvable')['to'](_0xb38040,'_permissions',()=>_0x58180b&&_0xb38040['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x56b399['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x5d0aaf,_0x1487ce)=>_0x5d0aaf?_0x1487ce?_0x5d0aaf<_0x1487ce?_0x5d0aaf:_0x1487ce:_0x5d0aaf:_0x1487ce),this['set']('unlinkedAt',_0x56b399['unlinkedAt']||null),this['set']('resolvedAt',_0x56b399['resolvedAt']||null),this['set']('resolvedBy',_0x56b399['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x6799e8=>!!_0x6799e8),this['set']('attributes',_0x56b399['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x3dc850,_0x31add4)=>_0x3dc850+_0x31add4['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x293a42,id:_0x5f2b9e}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x293a42),{'channelId':_0x293a42,'threadId':_0x5f2b9e});}['setUnlinkedAt'](_0x3e5d8e){this['_update']({'unlinkedAt':_0x3e5d8e});}['resolve']({resolvedAt:_0x2d36ed=new Date(),resolvedBy:_0x2e426c='',isFromAdapter:_0x5ea8cc=!0x1}={}){const _0x3ad18f=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x173c58,id:_0x368ae0}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x173c58),{'channelId':_0x173c58,'threadId':_0x368ae0,'resolvedAt':_0x2d36ed,'resolvedBy':_0x2e426c||_0x3ad18f['id'],'isFromAdapter':_0x5ea8cc});}['reopen']({isFromAdapter:_0x33aef8=!0x1}={}){const {channelId:_0x41e1f7,id:_0xc05bdd}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x41e1f7),{'channelId':_0x41e1f7,'threadId':_0xc05bdd,'isFromAdapter':_0x33aef8});}['setContext'](_0x20fff4){this['context']||this['_update']({'context':_0x20fff4});}['setAttribute'](_0x5817e7,_0xdde748){const _0x208a2f=wt(this['attributes']);yt(_0x208a2f,_0x5817e7,_0xdde748),this['_update']({'attributes':_0x208a2f});}['removeAttribute'](_0x1a6ec){const _0x338d85=wt(this['attributes']);Ct(_0x338d85,_0x1a6ec),this['_update']({'attributes':_0x338d85});}['remove']({isFromAdapter:_0x791231=!0x1}={}){const {channelId:_0x400ee5,id:_0x5cc9cc}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x400ee5),{'channelId':_0x400ee5,'threadId':_0x5cc9cc,'isFromAdapter':_0x791231});}['attachTo'](_0x14d49e){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x14d49e});}['addComment'](_0x50fa84){const {channelId:_0x45753a,id:_0x3fa5b4}=this;this['_repository']['fire'](Nt('addComment',_0x45753a,_0x3fa5b4),Object['assign']({'channelId':_0x45753a,'threadId':_0x3fa5b4},_0x50fa84));}['getComment'](_0x226fa5){if('string'!=typeof _0x226fa5)throw new _0x498a52('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x226fa5});return this['comments']['get'](_0x226fa5);}['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'](_0x1e2296=>_0x1e2296['toJSON']()),'attributes':this['attributes']};}['_add'](_0x39f6a5){return this['listenTo'](_0x39f6a5,'change:authoredAt',()=>{const _0x7ee2cb=this['_findOptimalIndex'](_0x39f6a5),_0x540f60=this['comments'];_0x7ee2cb-0x1!=_0x540f60['getIndex'](_0x39f6a5)&&_0x7ee2cb+0x1!=_0x540f60['getIndex'](_0x39f6a5)&&(this['_remove'](_0x39f6a5),this['_add'](_0x39f6a5));}),this['comments']['add'](_0x39f6a5,this['_findOptimalIndex'](_0x39f6a5));}['_update'](_0x29520a){const {channelId:_0x3ad670,id:_0x1c691c}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x3ad670),{..._0x29520a,'channelId':_0x3ad670,'threadId':_0x1c691c});}['_remove'](_0x2a1efd){return this['stopListening'](_0x2a1efd),_0x2a1efd['destroy'](),this['comments']['remove'](_0x2a1efd);}['_findOptimalIndex'](_0x2c43f0){const _0x21a242=this['comments']['find'](_0x124812=>new Date(_0x124812['authoredAt'])['getTime']()>new Date(_0x2c43f0['authoredAt'])['getTime']());return _0x21a242?this['comments']['getIndex'](_0x21a242):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
- _0x22b275(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x2095e4,_0x31c3af){super();const _0x5b7f10=_0x2095e4['context']['plugins']['get'](it)['me'],_0x24c5da=_0x2095e4['getCommentThread'](_0x31c3af['threadId']),_0x337cc9=0x0===_0x24c5da['comments']['length'],_0xe3e002=_0x5b7f10===_0x31c3af['author'];this['id']=_0x31c3af['id'],this['threadId']=_0x31c3af['threadId'],this['author']=_0x31c3af['author'],this['creator']=_0x31c3af['creator'],this['isExternal']=Boolean(_0x31c3af['attributes']&&_0x31c3af['attributes']['@external']),this['set']('content',_0x31c3af['content']),this['createdAt']=_0x31c3af['createdAt']||new Date(),this['set']('authoredAt',_0x31c3af['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x24c5da,'resolvedAt'),this['set']('attributes',_0x31c3af['attributes']||{}),this['bind']('isEditable')['to'](_0x2095e4,'_permissions',()=>{const _0x297873=_0x2095e4['getPermissions'](_0x24c5da['channelId'])['write'],_0x3fc030=_0x2095e4['getPermissions'](_0x24c5da['channelId'])['modifyAll'];return _0xe3e002&&_0x297873||!_0xe3e002&&_0x3fc030;}),this['bind']('isRemovable')['to'](_0x24c5da,'isRemovable',_0x2095e4,'_permissions',_0x3ae27c=>{const _0x1ffb06=_0x2095e4['getPermissions'](_0x24c5da['channelId'])['write'],_0x3d638c=_0x2095e4['getPermissions'](_0x24c5da['channelId'])['modifyAll'];return _0xe3e002&&_0x1ffb06||_0x3ae27c&&_0x337cc9||!_0xe3e002&&_0x3d638c&&!_0x337cc9;}),this['bind']('isReadOnly')['to'](_0x24c5da,'isReadOnly'),this['_repository']=_0x2095e4;}get['weight'](){return Math['max'](function(_0x340b7b){const _0x4d40f8=document['createElement']('div');return _0x4d40f8['innerHTML']=_0x340b7b,_0x4d40f8['textContent']['length'];}(this['content']),0xc8);}['update'](_0x5cc32d){const {threadId:_0x95a813,id:_0x5dd09c}=this;if(!this['_repository']['hasCommentThread'](_0x95a813))throw new _0x498a52('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x5427f7}=this['_repository']['getCommentThread'](_0x95a813);this['_repository']['fire'](Nt('updateComment',_0x5427f7,_0x95a813),{'channelId':_0x5427f7,'threadId':_0x95a813,'commentId':_0x5dd09c,..._0x5cc32d});}['setAttribute'](_0x28d9e1,_0x51c911){const _0x532eb2=wt(this['attributes']);yt(_0x532eb2,_0x28d9e1,_0x51c911),this['update']({'attributes':_0x532eb2});}['removeAttribute'](_0x3d4f6e){const _0x52c20b=wt(this['attributes']);Ct(_0x52c20b,_0x3d4f6e),this['update']({'attributes':_0x52c20b});}['remove'](_0x140dab={}){if(!_0x140dab['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x36b99e,id:_0x28bd8b}=this;if(!this['_repository']['hasCommentThread'](_0x36b99e))throw new _0x498a52('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0xfd1b33}=this['_repository']['getCommentThread'](_0x36b99e);this['_repository']['fire'](Nt('removeComment',_0xfd1b33,_0x36b99e),{'channelId':_0xfd1b33,'threadId':_0x36b99e,'commentId':_0x28bd8b,..._0x140dab});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x4abd6f,..._0x291404){for(const _0x4e9911 of _0x291404)void 0x0!==_0x4e9911&&(_0x4abd6f+=':'+String(_0x4e9911));return _0x4abd6f;}class ot extends _0x3ab548{constructor(_0x826ef){super(_0x826ef),this['set']('hasContent',!0x1);}['refresh'](){const _0x5443e2=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x43f9eb of _0x5443e2['getRanges']())if(this['_hasContent'](_0x43f9eb))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x3c5350=_0x114214(),ranges:_0x570faa,comment:_0x3daf96}={}){const _0x350acd=this['editor']['model'],_0x45dd1b=_0x570faa??Array['from'](_0x350acd['document']['selection']['getRanges']()),_0x5c51f4=[];for(const _0xa28926 of _0x45dd1b)this['_hasContent'](_0xa28926)&&_0x5c51f4['push'](this['_trimToContent'](_0xa28926));if(!_0x5c51f4['length'])throw new _0x498a52('addcommentthreadcommand-incorrect-ranges',null);_0x3daf96&&this['_createCommentThread'](_0x3c5350,_0x3daf96),this['_createMarkersFromRanges'](_0x3c5350,_0x5c51f4,!!_0x3daf96);}['_createMarkersFromRanges'](_0x507cbf,_0x37c3a6,_0x2e3dec){this['editor']['model']['change'](_0x346855=>{for(const _0x79c3fd of _0x37c3a6){const _0x4000dd=_0x114214()['substr'](0x1,0x5),_0x122ca8='comment:'+_0x507cbf+':'+_0x4000dd;_0x346855['addMarker'](_0x122ca8,{'range':_0x79c3fd,'usingOperation':_0x2e3dec,'affectsData':_0x2e3dec});}});}['_createCommentThread'](_0x479755,_0x36577d){const _0x24e261=this['editor']['plugins']['get']('CommentsRepository'),_0x1ff978=this['editor']['config']['get']('collaboration.channelId'),_0x15d9ec=this['editor']['plugins']['get']('Users')['me'];if(!_0x15d9ec)throw new _0x498a52('addcommentthreadcommand-user-not-found',null);_0x24e261['addCommentThread']({'threadId':_0x479755,'channelId':_0x1ff978,'comments':[{'authorId':_0x15d9ec['id'],'content':_0x36577d,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x350aa1){for(const _0x17311c of _0x350aa1['getItems']())if(this['_itemIsContent'](_0x17311c))return!0x0;return!0x1;}['_itemIsContent'](_0x231de8){return _0x231de8['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x231de8)&&!_0x231de8['is']('element','tableCell');}['_trimToContent'](_0x124b30){const _0x5cc558=_0x35773a=>!this['_itemIsContent'](_0x35773a['item']),_0x326e49=_0x124b30['start']['getLastMatchingPosition'](_0x5cc558),_0x39b39d=_0x124b30['end']['getLastMatchingPosition'](_0x5cc558,{'direction':'backward'});return this['editor']['model']['createRange'](_0x326e49,_0x39b39d);}}class b extends _0x2d240e{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x20ad52){super(_0x20ad52),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x354597=this['editor'],_0x21d9e7=_0x354597['model']['document']['selection'],_0x26e79a=_0x4916fd(()=>this['refreshSelectedViews'](),0xa);_0x21d9e7['on']('change:range',(_0x5f15ba,_0x1699a8)=>{_0x1699a8['directChange']&&(_0x26e79a['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x354597['editing']['view']['document'],'change:isFocused',(_0x56be76,_0x34a74b,_0x25fb04)=>{_0x25fb04&&_0x26e79a();}),this['listenTo'](_0x354597['ui']['focusTracker'],'change:isFocused',(_0x2f28da,_0xa37339,_0x3a24cd)=>{_0x3a24cd||this['fire']('blur',{'isAnnotationTracked':_0x1347ba=>this['_editorAnnotationsData']['has'](_0x1347ba['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x7ad4c8){if(this['_editorAnnotations']['has'](_0x7ad4c8['view']))return;this['_editorAnnotations']['add'](_0x7ad4c8['view']),this['editor']['ui']['focusTracker']['add'](_0x7ad4c8['view']['element']);const _0x336db0=this['editor']['plugins']['get'](y);this['listenTo'](_0x336db0['collection'],'remove',(_0x2f49ec,_0x583672)=>{this['editor']['ui']['focusTracker']['remove'](_0x583672['view']['element']),this['_editorAnnotations']['delete'](_0x583672['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x25869f){if('function'!=typeof _0x25869f)throw new _0x498a52('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x25869f);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x218617,annotations:_0xdbae91}){const _0x67fad9=[],_0x107fb1=this['editor']['model']['document']['selection'],_0xa3cbaa=Array['from'](_0x107fb1['getRanges']());for(const [_0x1a18af,_0x583b50]of this['_editorAnnotationsData']){const _0xd99b12=_0x10e6b5(_0x583b50),_0xbb990c=_0xdbae91['getByInnerView'](_0x1a18af);_0xd99b12&&_0xbb990c&&_0x67fad9['push']({'annotation':_0xbb990c,'range':_0xd99b12});}function _0x10e6b5(_0x124274){for(const _0x476592 of _0x124274)for(const _0x3e598d of _0xa3cbaa)if(_0x476592['containsRange'](_0x3e598d,!_0x107fb1['isCollapsed']))return _0x476592;return null;}return _0x67fad9['sort']((_0x20d512,_0x4a0b0c)=>{const _0x2bb9b4=_0x20d512['range'],_0x5b8b92=_0x4a0b0c['range'];if(!_0x2bb9b4['isEqual'](_0x5b8b92)){if(_0x2bb9b4['containsRange'](_0x5b8b92,!0x0))return 0x1;if(_0x5b8b92['containsRange'](_0x2bb9b4,!0x0))return-0x1;}return _0x20d512['annotation']==_0x218617?-0x1:_0x4a0b0c['annotation']==_0x218617?0x1:0x0;})['map'](_0xe37756=>_0xe37756['annotation']);}get['_editorAnnotationsData'](){const _0x40165b=new Map();for(const _0x1db065 of Array['from'](this['_dataCollectors']))for(const [_0x48c452,_0x42f0f0]of _0x1db065())_0x40165b['set'](_0x48c452,_0x42f0f0);return _0x40165b;}}class st extends _0x2d240e{['afterInit'](){const _0x3c2b8b=this['editor'];if(!_0x3c2b8b['plugins']['has']('RestrictedEditingModeEditing'))return;_0x3c2b8b['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x2d240e{constructor(_0x5a6393){super(_0x5a6393),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x1332a7=this['editor'],_0x1a5687=_0x1332a7['commands']['get']('importWord'),_0x22dc94=_0x1332a7['plugins']['get'](it);_0x1a5687&&(_0x1a5687['on']('execute',(_0x5dcb8a,[,_0x4d5e18])=>{_0x4d5e18['collaboration_features']={'comments':!0x0,'user_id':_0x22dc94['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x1a5687,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x333c82,_0x161978){const {comment_threads:_0x12e35e}=_0x161978;_0x12e35e&&_0x12e35e['forEach'](({thread_id:_0x21f164,comments:_0x303c91,is_resolved:_0x47327d})=>{const _0x27ddfe=new Date(),_0x49c75e=_0x303c91['map'](({author:_0x2b89ba,content:_0x40741b,created_at:_0x26c39c})=>({'content':_0x40741b,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x27ddfe,'attributes':{'@external':{'authorName':_0x2b89ba,'createdAt':_0x26c39c?new Date(_0x26c39c):new Date(),'source':'importWord'}}})),_0x1434cb=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x1434cb,'threadId':_0x21f164,'comments':_0x49c75e,'resolvedAt':_0x47327d?_0x27ddfe:null});});}}class at extends _0x2d240e{constructor(_0x2a851e){super(_0x2a851e),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x590835=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x590835,'contentInsertion',(_0x5f2b94,_0x20bfd0)=>this['_removeMarkersWithoutThreads'](_0x20bfd0['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x5cf812){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x5cf812;const _0x1ac19a=this['editor']['plugins']['get']('CommentsRepository');for(const _0x405522 of _0x5cf812['keys']()){const [_0x3dc5d9,_0x13fb0c]=_0x405522['split'](':');'comment'!=_0x3dc5d9||_0x1ac19a['hasCommentThread'](_0x13fb0c)||_0x5cf812['delete'](_0x405522);}return _0x5cf812;}['_registerMarkerInClipboardPipeline'](){const _0x2866de=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x4576cc=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x4576cc&&_0x2866de['_registerMarkerToCopy']('comment',_0x4576cc);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x55f495){switch(_0x55f495){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0xdbf443){const _0x2762ac=_0xdbf443['split'](':');return{'group':_0x2762ac[0x0],'id':_0x2762ac[0x1],'part':_0x2762ac[0x2]};}class ut extends _0x2d240e{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x39c48e,_0x4e2af1)=>{if(!_0x4e2af1['options']['showCommentHighlights'])return null;if(_0x4e2af1['options']['ignoreResolvedComments']){const {id:_0x27f170}=ft(_0x39c48e['markerName']),_0x16b0bd=this['editor']['plugins']['get'](o);if(_0x16b0bd['getCommentThread'](_0x27f170)?.['isResolved']&&_0x39c48e['item'])return _0x4e2af1['consumable']['consume'](_0x39c48e['item'],'addMarker:'+_0x39c48e['markerName']),_0x4e2af1['consumable']['consume'](_0x39c48e['item'],'removeMarker:'+_0x39c48e['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x473206=>{_0x473206['on']('addMarker:comment',(_0x5af9b5,_0x4f5123,_0x5f4479)=>{if(!_0x5f4479['options']['showCommentHighlights'])return;const _0x59fdba=_0x4f5123['item'];if(!_0x59fdba)return;const _0x33ed13=_0x5f4479['mapper']['toViewElement'](_0x59fdba);this['editor']['model']['schema']['isObject'](_0x59fdba)&&_0x33ed13&&!_0x33ed13['getCustomProperty']('widget')&&_0x33ed13['is']('containerElement')&&_0x2134c4(_0x33ed13,_0x5f4479['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x13ecaa,{writer:_0x207804,options:_0x49ce4c})=>{if(!_0x49ce4c['showCommentHighlights'])return null;const _0x1e4b53=_0x207804['createContainerElement']('div'),_0x3c2b85=_0x207804['createEmptyElement']('hr');return _0x207804['addClass']('ck-horizontal-line',_0x1e4b53),_0x207804['insert'](_0x207804['createPositionAt'](_0x1e4b53,0x0),_0x3c2b85),_0x1e4b53;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0xfc3f1b,{writer:_0x1b777a,options:_0x5108f0})=>{if(!_0x5108f0['showCommentHighlights'])return null;const _0xbcb516=_0x1b777a['createContainerElement']('span'),_0x4227a9=_0x1b777a['createEmptyElement']('img');return _0x1b777a['addClass']('image-inline',_0xbcb516),_0x1b777a['insert'](_0x1b777a['createPositionAt'](_0xbcb516,0x0),_0x4227a9),_0xbcb516;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x547c3e,{writer:_0x38a546,options:_0x4eb90a})=>{if(_0x4eb90a['showCommentHighlights'])return _0x38a546['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x5b5dea,_0x4c4da4,_0x56735a)=>{_0x56735a['options']['showCommentHighlights']&&_0x5b5dea['stop']();},{'priority':'high'});}}class r extends _0x2d240e{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(_0x330264){super(_0x330264),this['set']('isThreadsLoadingPaused',!0x0),_0x330264['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x52cf6e,_0x312a7d,_0x575fae,_0x1be464)=>{const _0x2cb7c4=_0x330264['plugins']['get'](o),_0x576b7c=_0x575fae?ft(_0x575fae)['id']:null;_0x330264['model']['change'](()=>{if(_0x576b7c){const _0x48510f=this['getAllMarkersForId'](_0x576b7c);for(const _0x342833 of _0x48510f)_0x330264['editing']['reconvertMarker'](_0x342833);}if(_0x1be464){const {id:_0x496b04}=ft(_0x1be464),_0xe12fa7=_0x2cb7c4['getCommentThread'](_0x496b04);if(_0xe12fa7&&_0xe12fa7['unlinkedAt'])return;if(_0xe12fa7&&!_0xe12fa7['isAttached'])return;const _0x230229=this['getAllMarkersForId'](_0x496b04);for(const _0x39ec9a of _0x230229)_0x330264['editing']['reconvertMarker'](_0x39ec9a);}}),_0x576b7c&&this['scrollToThreadMarker'](_0x576b7c);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0xb7d24f=this['editor'],_0x27f933=_0xb7d24f['plugins']['get'](o),_0x5737e8=_0xb7d24f['config']['get']('collaboration.channelId'),_0x3030d9=_0x27f933['getCommentThreads']()['filter'](_0x5af4c1=>_0x5af4c1['channelId']!==_0x5737e8);_0xb7d24f['commands']['add']('addCommentThread',new ot(_0xb7d24f)),this['listenTo'](_0xb7d24f,'change:isReadOnly',(_0x2e8da2,_0x1a9623,_0x4cb12f)=>{_0x27f933['switchReadOnly'](_0x4cb12f,_0xb7d24f['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x27f933,dt('addCommentThread',_0x5737e8),(_0x41086b,{threadId:_0x2fafed})=>{const _0x4c4a06=this['editor']['plugins']['get'](o)['getCommentThread'](_0x2fafed);_0x4c4a06?.['unlinkedAt']&&this['_attachArchivedThread'](_0x2fafed);}),this['listenTo'](_0x27f933,dt('removeCommentThread',_0x5737e8),(_0x3dc2fd,{threadId:_0x3cca27})=>{_0xb7d24f['model']['enqueueChange']({'isUndoable':!0x1},_0x38864c=>{const _0x461163=this['getAllMarkersForId'](_0x3cca27);for(const _0x2fc07f of _0x461163)_0x38864c['removeMarker'](_0x2fc07f);});}),this['listenTo'](_0x27f933,dt('resolveCommentThread',_0x5737e8),(_0x2b4163,{threadId:_0x14ee90})=>{(this['_reconvertMarkers'](_0x14ee90),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x14ee90)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x27f933,dt('reopenCommentThread',_0x5737e8),(_0x3419fa,{threadId:_0x3a08f8})=>{this['_reconvertMarkers'](_0x3a08f8);},{'priority':'low'}),this['listenTo'](_0x27f933,dt('addComment',_0x5737e8),(_0x5eb3e0,{threadId:_0x38f0fd,isFromAdapter:_0x3f43e6})=>{const _0x44230e=this['getAllMarkersForId'](_0x38f0fd);if(_0x3f43e6||0x0==_0x44230e['length']||!_0x27f933['hasCommentThread'](_0x38f0fd))return;0x1===_0x27f933['getCommentThread'](_0x38f0fd)['length']&&_0xb7d24f['model']['enqueueChange']({'isUndoable':!0x1},_0x3dc77c=>{for(const _0x1e9ede of _0x44230e)_0x3dc77c['updateMarker'](_0x1e9ede,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x3030d9);}['afterInit'](){!async function(_0x4f3666){const _0x2cb3cf=_0x4a814f([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]),_0xe59349=0x73460ab3,_0x522a26=0x73418c23^_0xe59349,_0x1716c6=window[_0x4a814f([0x44,0x61,0x74,0x65])][_0x4a814f([0x6e,0x6f,0x77])](),_0x154810=_0x4f3666[_0x4a814f([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x15a1f3=new window[(_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x170d75=>{_0x154810[_0x4a814f([0x6f,0x6e,0x63,0x65])](_0x4a814f([0x72,0x65,0x61,0x64,0x79]),_0x170d75);}),_0x2cded8={[_0x4a814f([0x6b,0x74,0x79])]:_0x4a814f([0x45,0x43]),[_0x4a814f([0x75,0x73,0x65])]:_0x4a814f([0x73,0x69,0x67]),[_0x4a814f([0x63,0x72,0x76])]:_0x4a814f([0x50,0x2d,0x32,0x35,0x36]),[_0x4a814f([0x78])]:_0x4a814f([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]),[_0x4a814f([0x79])]:_0x4a814f([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]),[_0x4a814f([0x61,0x6c,0x67])]:_0x4a814f([0x45,0x53,0x32,0x35,0x36])},_0x5ac0b1=_0x154810[_0x4a814f([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4a814f([0x67,0x65,0x74])](_0x4a814f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x24d456(){let _0x382e4b,_0x198c55=null,_0x25043a=null;try{if(_0x5ac0b1==_0x4a814f([0x47,0x50,0x4c]))return _0x4a814f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x382e4b=_0xae17c0(),!_0x382e4b)return _0x4a814f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x382e4b[_0x4a814f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x25043a=_0x509bb9(_0x382e4b[_0x4a814f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x382e4b[_0x4a814f([0x6a,0x74,0x69])])),await _0x2a6b9c()?_0xad103a()?_0x4b382a()?_0x4a814f([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x330dca()?(_0x382e4b[_0x4a814f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a814f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x198c55=_0x58fb77(_0x4a814f([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3b67ed()):_0x4a814f([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4a814f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4a814f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4a814f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4b382a(){const _0x392e33=[_0x4a814f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4a814f([0x74,0x72,0x69,0x61,0x6c])][_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x382e4b[_0x4a814f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x1716c6/0x3e8:0xe10*_0x522a26;return _0x382e4b[_0x4a814f([0x65,0x78,0x70])]<_0x392e33;}function _0xad103a(){const _0x47151c=_0x382e4b[_0x4a814f([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x47151c)return!0x1;if(_0x47151c[_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a814f([0x2a])))return!0x0;if(_0x47151c[_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a814f([0x43,0x4d,0x54])))return!0x0;if(_0x47151c[_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a814f([0x54,0x52,0x49,0x4c,0x49,0x55,0x4d]))&&_0x2a2cfb())return!0x0;if(_0x47151c[_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a814f([0x52,0x43,0x4d,0x54]))){if(_0x4e8baa())return!0x0;if(_0x39e80f()||_0x26dab3())return!0x0;}return!0x1;}function _0x330dca(){const _0x2acf58=_0x382e4b[_0x4a814f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2acf58||0x0==_0x2acf58[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x192ad9}=new URL(window[_0x4a814f([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2acf58[_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x192ad9))return!0x0;const _0x28fb6a=_0x192ad9[_0x4a814f([0x73,0x70,0x6c,0x69,0x74])](_0x4a814f([0x2e]));return _0x2acf58[_0x4a814f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xb983e3=>_0xb983e3[_0x4a814f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a814f([0x2a])))[_0x4a814f([0x6d,0x61,0x70])](_0x3ac10c=>_0x3ac10c[_0x4a814f([0x73,0x70,0x6c,0x69,0x74])](_0x4a814f([0x2e])))[_0x4a814f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x81a911=>_0x81a911[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x28fb6a[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4a814f([0x6d,0x61,0x70])](_0x49f798=>Array(_0x28fb6a[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x49f798[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4a814f([0x66,0x69,0x6c,0x6c])](_0x49f798[0x0]===_0x4a814f([0x2a])?_0x4a814f([0x2a]):'')[_0x4a814f([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x49f798))[_0x4a814f([0x73,0x6f,0x6d,0x65])](_0x4b7136=>_0x28fb6a[_0x4a814f([0x65,0x76,0x65,0x72,0x79])]((_0xedeaca,_0x2ede17)=>_0x4b7136[_0x2ede17]===_0xedeaca||_0x4b7136[_0x2ede17]===_0x4a814f([0x2a])));}function _0x3b67ed(){return _0x198c55&&_0x25043a?new window[(_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xf1ab8c,_0x28f506)=>{_0x198c55[_0x4a814f([0x74,0x68,0x65,0x6e])](_0xf1ab8c,_0x28f506),_0x25043a[_0x4a814f([0x74,0x68,0x65,0x6e])](_0x1a3822=>{_0x1a3822!=_0x4a814f([0x56,0x61,0x6c,0x69,0x64])&&_0xf1ab8c(_0x1a3822);},_0x28f506);}):_0x198c55||_0x25043a||_0x4a814f([0x56,0x61,0x6c,0x69,0x64]);}}function _0x509bb9(_0xce6037,_0x156e35){return new window[(_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x43e632=>{if(_0x41baf8())return _0x43e632(_0x4a814f([0x56,0x61,0x6c,0x69,0x64]));_0x4617cf(),_0x154810[_0x4a814f([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4a814f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x111f1a=!0x1;const _0x3b796c=_0x114214();function _0x19eb06(_0x56b889){return!!_0x56b889&&(typeof _0x56b889===_0x4a814f([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x56b889===_0x4a814f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x56b889[_0x4a814f([0x74,0x68,0x65,0x6e])]===_0x4a814f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x56b889[_0x4a814f([0x63,0x61,0x74,0x63,0x68])]===_0x4a814f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x55b372(_0xf5c995){_0x55af35(_0xf5c995)[_0x4a814f([0x74,0x68,0x65,0x6e])](_0x19ae3d=>{if(!_0x19ae3d||_0x19ae3d[_0x4a814f([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4a814f([0x6f,0x6b]))return _0x4a814f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x508798(_0x58420d(_0x3b796c+_0x156e35))!=_0x19ae3d[_0x4a814f([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4a814f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4a814f([0x56,0x61,0x6c,0x69,0x64]);})[_0x4a814f([0x74,0x68,0x65,0x6e])](_0x1fc434=>(_0x4e6e88(),_0x1fc434),()=>{const _0x4ddd84=_0x206505();return null==_0x4ddd84?(_0x4e6e88(),_0x4a814f([0x56,0x61,0x6c,0x69,0x64])):_0x4a814f(_0x1716c6-_0x4ddd84>(0x574a8eb3^_0xe59349)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4a814f([0x74,0x68,0x65,0x6e])](_0x43e632)[_0x4a814f([0x63,0x61,0x74,0x63,0x68])](()=>{_0x43e632(_0x4a814f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5d8df9=0x7370e433^_0xe59349;function _0x4e6e88(){const _0x2ee044=_0x4a814f([0x6c,0x6c,0x63,0x74,0x2d])+_0x508798(_0x58420d(_0xce6037)),_0x338004=_0x1c051f(_0x508798(window[_0x4a814f([0x4d,0x61,0x74,0x68])][_0x4a814f([0x63,0x65,0x69,0x6c])](_0x1716c6/_0x5d8df9)));window[_0x4a814f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a814f([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2ee044,_0x338004);}function _0x206505(){const _0x1cc4e0=_0x4a814f([0x6c,0x6c,0x63,0x74,0x2d])+_0x508798(_0x58420d(_0xce6037)),_0x12e0d3=window[_0x4a814f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a814f([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1cc4e0);return _0x12e0d3?window[_0x4a814f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1c051f(_0x12e0d3),0x10)*_0x5d8df9:null;}function _0x55af35(_0xc7bd4c){return new window[(_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3f1301,_0x19153b)=>{_0xc7bd4c[_0x4a814f([0x74,0x68,0x65,0x6e])](_0x3f1301,_0x19153b),window[_0x4a814f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x19153b,0x7347de73^_0xe59349);});}}_0x154810[_0x4a814f([0x6f,0x6e])](_0x4a814f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xaf5970,_0x554923)=>{if(_0x554923[0x0]!=_0xce6037)return _0x43e632(_0x4a814f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x554923[0x1]={..._0x554923[0x1],[_0x4a814f([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3b796c};},{[_0x4a814f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a814f([0x68,0x69,0x67,0x68])}),_0x154810[_0x4a814f([0x6f,0x6e])](_0x4a814f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x22bfdf=>{_0x19eb06(_0x22bfdf[_0x4a814f([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x111f1a=!0x0,_0x55b372(_0x22bfdf[_0x4a814f([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4a814f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a814f([0x6c,0x6f,0x77])}),_0x15a1f3[_0x4a814f([0x74,0x68,0x65,0x6e])](()=>{_0x111f1a||_0x43e632(_0x4a814f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x41baf8(){return _0x154810[_0x4a814f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a814f([0x76,0x69,0x65,0x77])][_0x4a814f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4a814f([0x61,0x75,0x74,0x6f]);}function _0x4617cf(){_0x154810[_0x4a814f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a814f([0x76,0x69,0x65,0x77])][_0x4a814f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4a814f([0x61,0x75,0x74,0x6f]);}}function _0x58fb77(_0x12e833){const _0x443b89=[new window[(_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3f9c0c=>setTimeout(_0x3f9c0c,0x734f347f^_0xe59349)),_0x15a1f3[_0x4a814f([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x29e36b=>{let _0x321ce2=0x0;_0x154810[_0x4a814f([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a814f([0x6f,0x6e])](_0x4a814f([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x533e7f,_0x5ee964)=>{_0x5ee964[0x0][_0x4a814f([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x321ce2++,_0x321ce2==(0x73460f5b^_0xe59349)&&(_0x29e36b(),_0x533e7f[_0x4a814f([0x6f,0x66,0x66])]());});}))];return window[_0x4a814f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4a814f([0x72,0x61,0x63,0x65])](_0x443b89)[_0x4a814f([0x74,0x68,0x65,0x6e])](()=>_0x12e833);}async function _0x472084(){await _0x15a1f3,_0x154810[_0x4a814f([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a814f([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0xa4d316,_0x154810[_0x4a814f([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a814f([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0xa4d316,_0x154810[_0x4a814f([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4a814f([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2a2cfb(){return window[_0x4a814f([0x67,0x6c,0x6f,0x62])]&&window[_0x4a814f([0x67,0x6c,0x6f,0x62])][_0x4a814f([0x74,0x72,0x69,0x6c,0x69,0x75,0x6d,0x56,0x65,0x72,0x73,0x69,0x6f,0x6e])];}function _0x4e8baa(){return _0x4e85ee(_0x4a814f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4074d6(_0x4a814f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4a814f([0x73,0x74,0x61,0x74,0x65])]==_0x4a814f([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x39e80f(){return _0x4e85ee(_0x4a814f([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 _0x26dab3(){return _0x4e85ee(_0x4a814f([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x94db45(_0x354a8c){const _0x86c14d=_0x40ef91();_0x154810[_0x86c14d]=_0x4a814f([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x354a8c,_0x354a8c!=_0x4a814f([0x56,0x61,0x6c,0x69,0x64])&&_0x472084();}function _0x40ef91(){const _0x514893=window[_0x4a814f([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4a814f([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4a814f([0x6e,0x6f,0x77])]())[_0x4a814f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4a814f([0x2e]),'');let _0x504738=_0x4a814f([0x4b]);for(let _0x76956a=0x0;_0x76956a<_0x514893[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x76956a+=0x2){let _0x346b66=window[_0x4a814f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x514893[_0x4a814f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x76956a,_0x76956a+0x2));_0x346b66>=_0x2cb3cf[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x346b66-=_0x2cb3cf[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x504738+=_0x2cb3cf[_0x346b66];}return _0x504738;}function _0xae17c0(){const _0x1c7bb0=_0x5ac0b1[_0x4a814f([0x73,0x70,0x6c,0x69,0x74])](_0x4a814f([0x2e]));if(0x3!=_0x1c7bb0[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1cb174(_0x1c7bb0[0x1]);function _0x1cb174(_0x53e82c){const _0x2dca3c=_0x169b49(_0x53e82c);return _0x2dca3c&&_0x5f2e7c()?_0x2dca3c:null;function _0x5f2e7c(){const _0x46431b=_0x2dca3c[_0x4a814f([0x6a,0x74,0x69])],_0x22104d=window[_0x4a814f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x46431b[_0x4a814f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x46431b[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2c1c61={..._0x2dca3c,[_0x4a814f([0x6a,0x74,0x69])]:_0x46431b[_0x4a814f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x46431b[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2c1c61[_0x4a814f([0x76,0x63])],_0x58420d(_0x2c1c61)==_0x22104d;}}}async function _0x2a6b9c(){let _0x2a717b=!0x0;try{const _0x116d5f=_0x5ac0b1[_0x4a814f([0x73,0x70,0x6c,0x69,0x74])](_0x4a814f([0x2e])),[_0x541087,_0x53e853,_0xbdd393]=_0x116d5f;return _0x1379d6(_0x541087),await _0x13fb5f(_0x541087,_0x53e853,_0xbdd393),_0x2a717b;}catch{return!0x1;}function _0x1379d6(_0x515664){const _0x27cd44=_0x169b49(_0x515664);_0x27cd44&&_0x27cd44[_0x4a814f([0x61,0x6c,0x67])]==_0x4a814f([0x45,0x53,0x32,0x35,0x36])||(_0x2a717b=!0x1);}async function _0x13fb5f(_0x31b292,_0x4727a0,_0x351056){const _0x1a9e2b=window[_0x4a814f([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4a814f([0x66,0x72,0x6f,0x6d])](_0x458c07(_0x351056),_0x3f794b=>_0x3f794b[_0x4a814f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2c5677=new window[(_0x4a814f([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4a814f([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x31b292+_0x4a814f([0x2e])+_0x4727a0),_0x4a44db=window[_0x4a814f([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4a814f([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4a44db)return;const _0x4cb99f=await _0x4a44db[_0x4a814f([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4a814f([0x6a,0x77,0x6b]),_0x2cded8,{[_0x4a814f([0x6e,0x61,0x6d,0x65])]:_0x4a814f([0x45,0x43,0x44,0x53,0x41]),[_0x4a814f([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4a814f([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4a814f([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4a44db[_0x4a814f([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4a814f([0x6e,0x61,0x6d,0x65])]:_0x4a814f([0x45,0x43,0x44,0x53,0x41]),[_0x4a814f([0x68,0x61,0x73,0x68])]:{[_0x4a814f([0x6e,0x61,0x6d,0x65])]:_0x4a814f([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4cb99f,_0x1a9e2b,_0x2c5677)||(_0x2a717b=!0x1);}}function _0x169b49(_0x29c1d1){return _0x29c1d1[_0x4a814f([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4a814f([0x65,0x79]))?JSON[_0x4a814f([0x70,0x61,0x72,0x73,0x65])](_0x458c07(_0x29c1d1)):null;}function _0x458c07(_0x525252){return window[_0x4a814f([0x61,0x74,0x6f,0x62])](_0x525252[_0x4a814f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4a814f([0x2b]))[_0x4a814f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4a814f([0x2f])));}function _0x58420d(_0x53e024){let _0x12f96c=0x1505;function _0x34f7af(_0x3e43e1){for(let _0x3048f7=0x0;_0x3048f7<_0x3e43e1[_0x4a814f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3048f7++){const _0x473d99=_0x3e43e1[_0x4a814f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x3048f7);_0x12f96c=(_0x12f96c<<0x5)+_0x12f96c+_0x473d99,_0x12f96c&=_0x12f96c;}}function _0x2023dd(_0x270da4){Array[_0x4a814f([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x270da4)?_0x270da4[_0x4a814f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2023dd):_0x270da4&&typeof _0x270da4==_0x4a814f([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4a814f([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x270da4)[_0x4a814f([0x73,0x6f,0x72,0x74])]()[_0x4a814f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x44d03d,_0x4d32ef])=>{_0x34f7af(_0x44d03d),_0x2023dd(_0x4d32ef);}):_0x34f7af(window[_0x4a814f([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x270da4));}return _0x2023dd(_0x53e024),_0x12f96c>>>0x0;}function _0x508798(_0x3ffefd){return _0x3ffefd[_0x4a814f([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4a814f([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4a814f([0x30]));}function _0x1c051f(_0x154a80){return _0x154a80[_0x4a814f([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4a814f([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4a814f([0x6a,0x6f,0x69,0x6e])]('');}function _0x4e85ee(_0x27e80d){return _0x154810[_0x4a814f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a814f([0x68,0x61,0x73])](_0x27e80d);}function _0x4074d6(_0x533645){return _0x154810[_0x4a814f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a814f([0x67,0x65,0x74])](_0x533645);}function _0xa4d316(){}function _0x4a814f(_0x624c0d){return _0x624c0d['map'](_0x480c71=>String['fromCharCode'](_0x480c71))['join']('');}_0x94db45(await _0x24d456());}(this);}['destroy'](){const _0x5cc1f9=this['editor']['plugins']['get'](o),_0x5c08cb=this['editor']['config']['get']('collaboration.channelId');for(const _0x3f8f38 of _0x5cc1f9['getCommentThreads']({'channelId':_0x5c08cb}))_0x5cc1f9['_detachCommentThread'](_0x3f8f38['id']),_0x5cc1f9['_threads']['delete'](_0x3f8f38['id']);super['destroy']();}['hasMarkerForId'](_0x7c5460){return this['getAllMarkersForId'](_0x7c5460)['length']>0x0;}['getAllMarkersForId'](_0x20b81f){const _0xc68d3f=[];for(const _0x3cf709 of this['editor']['model']['markers'])_0x3cf709['name']['startsWith']('comment:'+_0x20b81f)&&_0xc68d3f['push'](_0x3cf709);return _0xc68d3f;}['scrollToThreadMarker'](_0x971e8e){setTimeout(()=>{const _0x7c7031=this['_getTargetForId'](_0x971e8e);if(!_0x7c7031)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x971e8e&&nt({'target':_0x7c7031[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x2d88bc){this['editor']['model']['change'](()=>{for(const _0x45fa5a of this['getAllMarkersForId'](_0x2d88bc))this['editor']['editing']['reconvertMarker'](_0x45fa5a);});}['_attachArchivedThread'](_0x51ccce){const _0x5ea2eb=this['editor']['plugins']['get'](o),_0x4ef43d=this['editor']['plugins']['get'](b),_0xeadb61=_0x5ea2eb['getCommentThread'](_0x51ccce);if(!_0xeadb61['isAttached']){const _0x552cef=_0xeadb61['attachTo'](()=>this['_getTargetForId'](_0xeadb61['id']));_0x4ef43d['registerAnnotation'](_0x552cef),_0xeadb61['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x3f2e2b=this['editor'],_0x116011=_0x3f2e2b['plugins']['get'](it);_0x3f2e2b['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x46095b,_0x13f594)=>{const {id:_0x76d656}=ft(_0x46095b['markerName']),_0x19e57f=_0x3f2e2b['plugins']['get'](o)['getCommentThread'](_0x76d656),_0x42d5d8=this['activeMarker']&&ft(this['activeMarker'])['id']===_0x76d656;let _0x4e9121;if(_0x19e57f&&_0x19e57f['isResolved']&&!_0x42d5d8&&_0x46095b['item'])return _0x13f594['consumable']['consume'](_0x46095b['item'],'addMarker:'+_0x46095b['markerName']),_0x13f594['consumable']['consume'](_0x46095b['item'],'removeMarker:'+_0x46095b['markerName']),null;const _0x5346af=['ck-comment-marker'];return _0x42d5d8&&_0x5346af['push']('ck-comment-marker--active'),_0x4e9121=_0x19e57f?.['length']?_0x19e57f['comments']['first']['author']['id']:_0x116011['me']['id'],{'classes':_0x5346af,'attributes':{'data-comment':_0x76d656,'data-author-id':_0x4e9121}};}}),_0x3f2e2b['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x3cb38a,{options:_0xfd6286})=>{if(_0xfd6286['showCommentHighlights'])return null;const _0x49d741=_0x3f2e2b['plugins']['get'](o),_0x2c2da9=_0x3f2e2b['model']['markers']['get'](_0x3cb38a),{id:_0x2da90b,part:_0x878e09}=ft(_0x3cb38a);return _0x2c2da9&&!_0x2c2da9['affectsData']||_0xfd6286['ignoreResolvedComments']&&_0x49d741['getCommentThread'](_0x2da90b)?.['isResolved']?null:{'group':'comment','name':_0x878e09?_0x2da90b+':'+_0x878e09:_0x2da90b};}}),_0x3f2e2b['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x4c6d6a,{writer:_0x3697b3})=>_0x3697b3['createElement']('$marker',{'data-name':'comment:'+_0x4c6d6a['getAttribute']('id')})}),_0x3f2e2b['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x16d952=this['editor'],_0xe28798=_0x16d952['plugins']['get'](o),_0x113015=new Set(),_0xf80af5=new Set();_0x16d952['model']['document']['registerPostFixer'](_0x1110ce=>{let _0x44391b=!0x1;for(const {name:_0x3a8721,data:_0x4bccfc}of _0x16d952['model']['document']['differ']['getChangedMarkers']()){const {group:_0x44b9bb,id:_0x57dc70}=ft(_0x3a8721);let _0x4598b1=_0x4bccfc['newRange'];if('comment'!==_0x44b9bb||!_0x4598b1)continue;const _0x4ae11f='$graveyard'===_0x4598b1['root']['rootName'];_0x4ae11f||(_0x4598b1=ht(_0x4598b1,_0x16d952['model']),!_0x4598b1||_0x4598b1['isCollapsed']||!_0x4bccfc['newRange']||_0x4598b1['isEqual'](_0x4bccfc['newRange']))?_0x16d952['model']['hasContent'](_0x4598b1)&&!_0x4ae11f?this['isThreadsLoadingPaused']?_0x113015['add'](_0x3a8721):this['_handleThreadMarker'](_0x3a8721,_0x57dc70):(_0xf80af5['add'](_0x3a8721),_0x113015['delete'](_0x3a8721),_0x1110ce['removeMarker'](_0x3a8721),_0x44391b=!0x0):(_0x1110ce['updateMarker'](_0x3a8721,{'range':_0x4598b1}),_0x44391b=!0x0);}return _0x44391b;}),this['on']('change:isThreadsLoadingPaused',(_0xe3a3b,_0x5af6ba,_0x271cc5)=>{if(!_0x271cc5&&_0x113015['size'])for(const _0xa1dba6 of _0x113015){const {id:_0x4c6822}=ft(_0xa1dba6);_0x113015['delete'](_0xa1dba6),_0x16d952['model']['markers']['get'](_0xa1dba6)&&this['_handleThreadMarker'](_0xa1dba6,_0x4c6822);}}),this['listenTo'](_0x16d952['model']['document'],'change',()=>{for(const {name:_0x200fa3,data:{newRange:_0x49617b}}of _0x16d952['model']['document']['differ']['getChangedMarkers']()){const {group:_0x76a63d,id:_0x41731f}=ft(_0x200fa3);if('comment'!==_0x76a63d)continue;const _0x22cf84=_0xe28798['getCommentThread'](_0x41731f),_0xed5619=this['hasMarkerForId'](_0x41731f);_0x22cf84&&(!_0x22cf84['_hasTargetInContent']&&_0x49617b&&_0x16d952['editing']['view']['once']('render',()=>{const _0xee0349=_0x16d952['plugins']['get'](y),_0x4fba27=_0xe28798['_threadToController']['get'](_0x22cf84)['view'];_0xee0349['getByInnerView'](_0x4fba27)['refreshVisibility']();},{'priority':'low'}),_0x22cf84['_hasTargetInContent']=_0xed5619||!!_0x49617b),_0x49617b||(_0xf80af5['add'](_0x200fa3),_0x113015['delete'](_0x200fa3));}for(const _0x376bd6 of _0xf80af5){const {id:_0x3e5db5}=ft(_0x376bd6),_0x167f22=_0xe28798['getCommentThread'](_0x3e5db5);if(_0x113015['delete'](_0x376bd6),!_0x167f22)continue;const _0x2f1ea7=this['hasMarkerForId'](_0x3e5db5);_0x2f1ea7||_0x167f22['isSubmitted']?_0x2f1ea7||_0x167f22['unlinkedAt']||_0x167f22['setUnlinkedAt'](new Date()):_0x167f22['remove']();}_0xf80af5['clear']();});}['_handleInitialThreads'](_0x34bdef){_0x34bdef['forEach'](_0x1a8778=>{_0x1a8778['unlinkedAt']&&this['_attachArchivedThread'](_0x1a8778['id']);});}['_getTargetForId'](_0x3f6961){const _0x3937f0=this['editor'],_0x4a8fc7=this['getAllMarkersForId'](_0x3f6961);return et(_0x3937f0['editing'],_0x4a8fc7);}['_getTextContext'](_0x5af931){const _0x5c3d55=this['getAllMarkersForId'](_0x5af931);let _0x11d118='',_0x5c9ab4=!0x1;for(const _0x11d989 of _0x5c3d55){const _0x267a6f=_0x11d989['getRange']();for(const _0x532e07 of Array['from'](_0x267a6f['getItems']()))_0x532e07['is']('$textProxy')?(_0x11d118&&_0x5c9ab4&&(_0x11d118+='\x20',_0x5c9ab4=!0x1),_0x11d118+=_0x532e07['data']):_0x5c9ab4=!0x0;_0x5c9ab4=!0x0;}return _0x11d118['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x5a5401,_0x1af0df){const _0x41f652=this['editor'],_0xb506c8=_0x41f652['plugins']['get'](o);let _0x552574=_0xb506c8['getCommentThread'](_0x1af0df);const _0x3e8801=_0x41f652['config']['get']('collaboration.channelId'),_0x1a1f44=_0x41f652['plugins']['get'](b);if(_0x552574&&(_0x552574['unlinkedAt']&&_0x552574['setUnlinkedAt'](null),_0x552574['isAttached']))return _0x552574;return!this['getAllMarkersForId'](_0x1af0df)[0x0]['managedUsingOperations']?_0x41f652['editing']['view']['once']('render',()=>{if(_0xb506c8['getCommentThread'](_0x1af0df))return;const _0x10c3fa=_0x41f652['plugins']['get'](y);_0x552574=_0xb506c8['openNewCommentThread']({'channelId':_0x3e8801,'threadId':_0x1af0df,'target':()=>this['_getTargetForId'](_0x1af0df),'context':{'type':'text','value':this['_getTextContext'](_0x1af0df)}});const _0x3ad590=_0xb506c8['_threadToController']['get'](_0x552574)['view'],_0x58de46=_0x10c3fa['getByInnerView'](_0x3ad590);_0x58de46&&_0x1a1f44['registerAnnotation'](_0x58de46);},{'priority':'low'}):_0xb506c8['fetchCommentThread']({'channelId':_0x3e8801,'threadId':_0x1af0df})['then'](_0x37f1a2=>{if('destroyed'!==_0x41f652['state']){if(_0x552574=_0x37f1a2,_0x552574&&!_0x552574['isAttached']){const _0x4e19e7=_0x552574['attachTo'](()=>this['_getTargetForId'](_0x1af0df));_0x1a1f44['registerAnnotation'](_0x4e19e7),_0x552574['isResolved']&&this['_reconvertMarkers'](_0x1af0df);}else{if(!_0x552574){const _0x5db782=this['getAllMarkersForId'](_0x1af0df);_0x41f652['model']['change'](_0xbe25b5=>{for(const _0x28e279 of _0x5db782)_0xbe25b5['removeMarker'](_0x28e279);});}}}}),_0x552574;}['_handleThreadMarker'](_0x3e2ad2,_0x962b7f){const _0x49f9c5=this['_attachMarkerToThread'](_0x3e2ad2,_0x962b7f);_0x49f9c5&&!_0x49f9c5['context']&&_0x49f9c5['setContext']({'type':'text','value':this['_getTextContext'](_0x962b7f)});}['_initAriaMarkerChangeAnnouncements'](){const _0x311976=this['editor'];rt(_0x311976['model'],({left:_0x4dda52,entered:_0x3aa151})=>{for(const _0x8ec359 of _0x4dda52)if(mt(_0x8ec359)){_0x311976['ui']['ariaLiveAnnouncer']['announce'](N(_0x311976['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x10f78f of _0x3aa151)if(mt(_0x10f78f)){_0x311976['ui']['ariaLiveAnnouncer']['announce'](N(_0x311976['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x4c478d)));break;}});}}function dt(_0x2a9c5a,_0x2a17f6){return _0x2a17f6?_0x2a9c5a+':'+_0x2a17f6:_0x2a9c5a;}function ht(_0x4d76fa,_0x7ac424){const _0x382391=_0x7ac424['schema'],_0x4a0a96=_0x7ac424['createRange'](_0x4d76fa['start']);for(const _0x917974 of _0x4d76fa['getWalker']()){const {type:_0x345d4b,item:_0x3f8f9f,nextPosition:_0x4e09c4}=_0x917974;if('text'===_0x345d4b||_0x382391['isObject'](_0x3f8f9f)){const _0x148f2c=_0x7ac424['createPositionBefore'](_0x3f8f9f);_0x4a0a96['isCollapsed']&&(_0x4a0a96['start']=_0x148f2c),_0x4a0a96['end']=_0x4e09c4;}}return _0x4a0a96;}function mt(_0x561bcd){return'comment'===ft(_0x561bcd['name'])['group'];}class s extends _0x2d240e{['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 _0x12c443=this['editor'],_0x3baffb=_0x12c443['plugins']['get'](o),_0x4089bf=_0x12c443['plugins']['get'](r),_0x22a55f=_0x12c443['plugins']['get'](y),_0x4e06b0=_0x12c443['plugins']['get'](b);_0x12c443['ui']['componentFactory']['add']('comment',()=>{const _0x3ea3ea=this['_createUIButton'](_0x6b909b);return _0x3ea3ea['tooltip']=!0x0,_0x3ea3ea;}),_0x12c443['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x1d6833)),_0x4e06b0['addSourceCollector'](()=>{const _0x47ef59=[];for(const [_0x3c7bc3,_0x23aa11]of _0x3baffb['_threadToController']){const _0x38e954=_0x4089bf['getAllMarkersForId'](_0x3c7bc3['id']),_0x463322=_0x38e954['map'](_0x23122e=>_0x23122e['getRange']());_0x38e954['length']>0x0&&_0x47ef59['push']([_0x23aa11['view'],_0x463322]);}return _0x47ef59;}),this['listenTo'](_0x22a55f,'change:activeAnnotations',(_0xe040c8,_0x5a031f,_0x4d8e6d)=>{const _0x6aa8dd=Array['from'](_0x4d8e6d)['map'](_0x3e82e0=>_0x3e82e0['innerView'])['find'](_0x1d2f77=>_0x3baffb['_viewToController']['has'](_0x1d2f77));if(!_0x6aa8dd)return void(_0x4089bf['activeMarker']=null);const _0x351f55=_0x3baffb['_viewToController']['get'](_0x6aa8dd)['model']['id'],_0x5c493c='comment:'+_0x351f55;_0x351f55&&_0x4089bf['hasMarkerForId'](_0x351f55)?_0x4089bf['activeMarker']=_0x5c493c:_0x4089bf['activeMarker']&&(_0x4089bf['activeMarker']=null);}),this['listenTo'](_0x3baffb,'removeCommentThread',(_0x2d2f55,{threadId:_0x1514ca,isFromAdapter:_0x440d8b})=>{!_0x440d8b&&_0x12c443['ui']['focusTracker']['isFocused']&&_0x4089bf['hasMarkerForId'](_0x1514ca)&&_0x12c443['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x3baffb,'addComment',(_0x12fcc6,{threadId:_0x3c8572,isFromAdapter:_0x34f7f9})=>{if(_0x34f7f9||!_0x4089bf['hasMarkerForId'](_0x3c8572)||!_0x3baffb['hasCommentThread'](_0x3c8572))return;0x1===_0x3baffb['getCommentThread'](_0x3c8572)['length']&&(_0x12c443['editing']['view']['focus'](),_0x12fcc6['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4ec312=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x3029b5;for(const _0x402043 in _0x4ec312){const _0x3c09a8=_0x402043,_0x362b11=_0x4ec312[_0x3c09a8];if('commentsLicenseKeyValid'==_0x362b11||'commentsLicenseKeyInvalid'==_0x362b11||'commentsLicenseKeyExpired'==_0x362b11||'commentsLicenseKeyDomainLimit'==_0x362b11||'commentsLicenseKeyNotAllowed'==_0x362b11||'commentsLicenseKeyEvaluationLimit'==_0x362b11||'commentsLicenseKeyUsageLimit'==_0x362b11){delete _0x4ec312[_0x3c09a8],_0x3029b5=_0x362b11,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x3029b5&&_0x4ec312['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x3029b5&&_0x4ec312['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x3029b5&&_0x4ec312['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x3029b5&&_0x4ec312['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x3029b5&&_0x4ec312['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyUsageLimit'==_0x3029b5&&_0x4ec312['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x22bd45){const _0x52a8ac=this['editor'],_0x4c73d6=new _0x22bd45(_0x52a8ac['locale']),_0x5482f5=_0x52a8ac['commands']['get']('addCommentThread');return _0x4c73d6['set']({'label':N(_0x52a8ac['locale'],'Comment'),'icon':_0x59b8c2}),_0x4c73d6['bind']('isEnabled')['to'](_0x5482f5,'isEnabled',_0x5482f5,'hasContent',(_0x2eba85,_0xd1a8b7)=>_0x2eba85&&_0xd1a8b7),this['listenTo'](_0x4c73d6,'execute',()=>{_0x5482f5['execute']();}),_0x4c73d6;}}class i extends _0x2d240e{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x198c0d){super(_0x198c0d),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x4c4f4e,_0x1eb1fe,_0x5b6ac0)=>{_0x5b6ac0?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x17724d,_0x154a90]of this['editor']['commands'])_0x154a90['affectsData']&&'addCommentThread'!==_0x17724d&&_0x154a90['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('RevisionTracker'))&&this['editor']['plugins']['get']('RevisionTracker')['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x532b02=this['editor']['editing']['view']['document'];this['listenTo'](_0x532b02,'cut',_0x386ee6=>_0x386ee6['stop'](),{'priority':'highest'}),this['listenTo'](_0x532b02,'clipboardInput',_0x2e8651=>_0x2e8651['stop'](),{'priority':'highest'}),this['listenTo'](_0x532b02,'delete',_0x1a137b=>_0x1a137b['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x5487e,_0xc8c7e8]of this['editor']['commands'])_0xc8c7e8['affectsData']&&'addCommentThread'!==_0x5487e&&_0xc8c7e8['clearForceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['clearForceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['clearForceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['clearForceDisabled']('commentsOnlyMode'),this['stopListening'](this['editor']['editing']['view']['document']);}}class j extends _0x51795f{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x229f9a){super(_0x229f9a),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x145ce1=this['context']['plugins']['get'](y);this['listenTo'](_0x145ce1,'_activateAnnotation',(_0x4af6d2,_0x10d347)=>{for(const _0x130987 of this['activeUIs']){const _0x4b1f95=this['_uis']['get'](_0x130987);(0x0,this['uisData']['get'](_0x130987)['filter'])(_0x10d347)&&_0x4b1f95['setActiveAnnotation'](_0x10d347);}}),this['listenTo'](_0x145ce1,'_deactivateAllAnnotations',()=>{for(const _0x4bf2f4 of this['activeUIs']){this['_uis']['get'](_0x4bf2f4)['setActiveAnnotation'](null);}}),this['listenTo'](_0x145ce1['_visibleAnnotations'],'add',(_0x56bb17,_0x420dbd)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x420dbd);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x1d9606){return this['activeUIs']['has'](_0x1d9606);}['activate'](_0x4ac2f2,_0x16d23a=this['defaultFilter']){const _0x4b5011=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x4ac2f2))throw new _0x498a52('annotationsuis-missing-ui',this,{'uiName':_0x4ac2f2});this['isActive'](_0x4ac2f2)&&this['deactivate'](_0x4ac2f2),this['activeUIs']['add'](_0x4ac2f2);const _0x539e34=new S();v({'source':_0x4b5011['_visibleAnnotations'],'target':_0x539e34,'filter':_0x16d23a}),this['uisData']['set'](_0x4ac2f2,{'collection':_0x539e34,'filter':_0x16d23a});const _0x5d8b59=this['_uis']['get'](_0x4ac2f2);_0x5d8b59['attach'](_0x539e34),this['listenTo'](_0x5d8b59,'change:activeAnnotation',(_0x5c32e1,_0x119324,_0x38eafc,_0x47994e)=>{_0x47994e&&_0x4b5011['_removeActiveAnnotation'](_0x47994e),_0x38eafc&&_0x4b5011['_addActiveAnnotation'](_0x38eafc);});}['deactivate'](_0x1d03eb){if(this['activeUIs']['delete'](_0x1d03eb),!this['_uis']['has'](_0x1d03eb))throw new _0x498a52('annotationsuis-missing-ui',this,{'uiName':_0x1d03eb});const _0x34428f=this['_uis']['get'](_0x1d03eb);_0x34428f['detach'](),this['stopListening'](_0x34428f),this['uisData']['get'](_0x1d03eb)['collection']['destroy'](),this['uisData']['delete'](_0x1d03eb);}['switchTo'](_0x4e9312){if(!this['_uis']['has'](_0x4e9312))throw new _0x498a52('annotationsuis-missing-ui',this,{'uiName':_0x4e9312});const _0x2695a9=this['context']['plugins']['get'](y),_0x3e9158=Array['from'](_0x2695a9['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x4e9312);const _0x4b45b6=this['_uis']['get'](_0x4e9312);_0x4b45b6['setActiveAnnotation'](_0x3e9158),_0x4b45b6['_setSelectedAnnotations']&&_0x3e9158&&_0x4b45b6['_setSelectedAnnotations']([_0x3e9158]);}['deactivateAll'](){for(const _0x54082f of this['activeUIs'])this['deactivate'](_0x54082f);}['register'](_0x94b329,_0x4b370c){if(this['_uis']['has'](_0x94b329))throw new _0x498a52('annotationsuis-register-already-registered');if('function'!=typeof _0x4b370c['attach']||'function'!=typeof _0x4b370c['detach']||'function'!=typeof _0x4b370c['setActiveAnnotation'])throw new _0x498a52('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x94b329,_0x4b370c);}['refilterAnnotations'](){const _0x1412c2=this['context']['plugins']['get'](y)['collection'],_0x149f22=new Map(),_0x59141e=Array['from'](this['activeUIs']);for(const _0x4ac1cd of this['activeUIs']){const _0x146a03=this['uisData']['get'](_0x4ac1cd)['collection'];for(const _0x15206a of _0x146a03)_0x149f22['set'](_0x15206a,_0x4ac1cd);}for(const _0x1ce850 of _0x1412c2){const _0x52ff19=_0x149f22['get'](_0x1ce850);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x1ce850);const _0x2d1501=_0x59141e['find'](_0x5339bf=>this['uisData']['get'](_0x5339bf)['filter'](_0x1ce850));_0x52ff19!==_0x2d1501&&(_0x52ff19&&this['uisData']['get'](_0x52ff19)['collection']['remove'](_0x1ce850),_0x2d1501&&this['uisData']['get'](_0x2d1501)['collection']['add'](_0x1ce850));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x883a21){const _0x2cd09a=[];for(const _0x3e5b77 of this['activeUIs']){(0x0,this['uisData']['get'](_0x3e5b77)['filter'])(_0x883a21)&&_0x2cd09a['push'](_0x3e5b77);}if(_0x2cd09a['length']>0x1)throw new _0x498a52('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x2cd09a,'annotationType':_0x883a21['type']});}}const _i=/* #__PURE__ -- @preserve */
32
- Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x444b3b){super(_0x444b3b);const _0x59de08=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 _0x144d0f(),this['focusCycler']=new _0x37e2ac({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x59de08['to']('class')],'style':{'minHeight':_0x59de08['to']('minHeight',_0x254e08=>'number'==typeof _0x254e08?_i(_0x254e08+0xa):null)},'dir':_0x444b3b['uiLanguageDirection'],'role':'application','aria-label':N(_0x444b3b,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x444b3b,'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',_0x5e76c7=>{this['_updateItemPositionInFocusables'](_0x5e76c7['source']);}),this['list']['forEach'](_0x3e31ba=>{this['focusTracker']['add'](_0x3e31ba['element']),this['_updateItemPositionInFocusables'](_0x3e31ba);}),this['list']['on']('change',(_0x5d6e1a,_0x5dd7e4)=>{for(const _0x25de5f of _0x5dd7e4['removed'])this['focusTracker']['remove'](_0x25de5f['element']),this['focusables']['remove'](_0x25de5f);for(const _0x6db25a of _0x5dd7e4['added'])this['focusTracker']['add'](_0x6db25a['element']),this['_updateItemPositionInFocusables'](_0x6db25a);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x18caec){const _0x48a506=this['focusables']['getIndex'](_0x18caec);let _0x9b250b,_0x3b2d0f;for(const _0x3617e3 of this['focusables'])if(_0x18caec['top']<_0x3617e3['top']){_0x9b250b=_0x3617e3;break;}if(_0x3b2d0f=_0x9b250b?this['focusables']['getIndex'](_0x9b250b):this['focusables']['length'],-0x1!==_0x48a506){if(_0x48a506===_0x3b2d0f-0x1)return;this['focusables']['remove'](_0x18caec),_0x3b2d0f=_0x9b250b?this['focusables']['getIndex'](_0x9b250b):this['focusables']['length'];}this['focusables']['add'](_0x18caec,_0x3b2d0f);}}const Ot=/* #__PURE__ -- @preserve */
33
- Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x157e82){super(_0x157e82),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x3997e3,_0x28cabf)=>_0x3997e3+_0x28cabf),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x328b70=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x328b70['to']('isAnimationDisabled',_0x7494a6=>_0x7494a6?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x328b70['to']('top',_0x430a4d=>Ot(_0x430a4d))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x178d99=this['element']['clientHeight'];_0x178d99&&(this['height']=_0x178d99);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x51795f{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x43f1bf){super(_0x43f1bf),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 _0x812b5f=this['context']['config']['get']('sidebar.container');_0x812b5f&&this['setContainer'](_0x812b5f);}['setContainer'](_0x468886){if(!g(_0x468886))throw new _0x498a52('sidebar-setcontainer-invalid-element');this['container']=_0x468886;}['_attachToContainer']({viewClass:_0x28200a='',spaceBetweenItems:_0x1b7fc3=0x19}={}){if(!g(this['container']))throw new _0x498a52('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x28200a,this['_spaceBetweenItems']=_0x1b7fc3;}['rearrange']({removedAnnotation:_0x35ca2f,previousAnnotation:_0xbaf777,nextAnnotation:_0x33c4e6}){const _0x3d8dbd=this['getSidebarItemView'](_0x35ca2f);this['view']['list']['remove'](_0x3d8dbd),this['_destroySidebarItemView'](_0x35ca2f),_0xbaf777&&this['_alignToTargetRect'](this['getSidebarItemView'](_0xbaf777)),_0x33c4e6&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x33c4e6)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x3da057,activatedAnnotation:_0x5cc821,disableAnimationOnActivatedAnnotation:_0x354d06}){if(this['_activeAnnotation']=_0x5cc821,_0x3da057){_0x3da057['isActive']=!0x1;const _0x1e2864=this['getSidebarItemView'](_0x3da057);_0x1e2864&&_0x354d06&&(_0x1e2864['isAnimationDisabled']=!0x1);}if(_0x5cc821){const _0x58f852=this['getSidebarItemView'](_0x5cc821);_0x58f852&&(_0x5cc821['isActive']=!0x0,_0x354d06&&(_0x58f852['isAnimationDisabled']=!0x0,_0x58f852['top']+=0x1),this['_alignToTargetRect'](_0x58f852));}}['_detachFromContainer'](_0x11c591){if(this['view']['element']['remove'](),_0x11c591){for(const _0x41b534 of _0x11c591)this['_destroySidebarItemView'](_0x41b534);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x589194,_0x4e3a6d){_0x4e3a6d||(_0x4e3a6d=_0x589194['view']);const _0x587b79=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x587b79,_0x589194),this['_annotationToSidebarItemView']['set'](_0x589194,_0x587b79),_0x587b79['content']['add'](_0x4e3a6d),this['listenTo'](_0x589194['view'],'change:targetRect',(_0x12b4c4,_0x4dacaf,_0x55a3e3)=>{const _0x371c51=this['_getTargetTop'](_0x589194,_0x55a3e3);_0x587b79['_targetTop']!=_0x371c51&&(_0x587b79['_targetTop']=_0x371c51,this['_setItemTop'](_0x587b79,_0x371c51));}),this['listenTo'](_0x587b79,'change:top',()=>{this['_recalculate'](_0x587b79,'top');}),this['listenTo'](_0x587b79,'change:bottom',()=>{this['_recalculate'](_0x587b79,'bottom');}),this['_alignToTargetRect'](_0x587b79);const _0x3b6836=this['_getItemBefore'](_0x587b79);if(_0x3b6836)this['_alignAfterItem'](_0x3b6836,_0x587b79)||this['_alignToTargetRect'](_0x587b79);else this['_alignToTargetRect'](_0x587b79);return this['_updateLastItem'](),this['view']['list']['add'](_0x587b79),_0x587b79;}['_alignForTopChange'](_0x462671){if(!_0x462671['content']['length'])return;const _0x20f419=this['_getItemBefore'](_0x462671);if(!_0x20f419)return;const _0x276799=this['_sidebarItemViewToAnnotation']['get'](_0x20f419),_0x4c3b61=this['_activeAnnotation'];_0x4c3b61&&_0x4c3b61===_0x276799?this['_alignAfterItem'](_0x20f419,_0x462671):this['_alignBeforeItem'](_0x462671,_0x20f419);}['_alignForBottomChange'](_0x3b3e78){if(!_0x3b3e78['content']['length'])return;const _0x128523=this['_getItemAfter'](_0x3b3e78);if(!_0x128523)return;const _0x5228f4=this['_sidebarItemViewToAnnotation']['get'](_0x128523),_0x506108=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x1f654e=this['_activeAnnotation'];_0x1f654e&&_0x1f654e===_0x5228f4&&_0x506108?(this['_alignBeforeItem'](_0x128523,_0x3b3e78),this['_alignAfterItem'](_0x3b3e78,_0x128523)):_0x1f654e&&_0x1f654e===_0x5228f4?this['_alignBeforeItem'](_0x128523,_0x3b3e78):this['_alignAfterItem'](_0x3b3e78,_0x128523);}['_recalculate'](_0xaa5bef,_0x15ed59){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x4e5662,changedProp:_0x32da35}of this['_recalculateBuffer'])'top'===_0x32da35?this['_alignForTopChange'](_0x4e5662):this['_alignForBottomChange'](_0x4e5662);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0xaa5bef,'changedProp':_0x15ed59});}['getSidebarItemView'](_0x34f41a){return this['_annotationToSidebarItemView']['get'](_0x34f41a);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x3fde7a){const _0x436f52=this['getSidebarItemView'](_0x3fde7a);this['stopListening'](_0x436f52),this['stopListening'](_0x3fde7a['view']),_0x436f52['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x3fde7a),this['_sidebarItemViewToAnnotation']['delete'](_0x436f52);}['_createSidebarView'](){const _0x2c179f=new H(this['context']['locale']);return _0x2c179f['render'](),this['on']('change:_lastItem',(_0xfbf2bf,_0x42cf38,_0x5e560f,_0x4f5d0e)=>{_0x4f5d0e&&_0x2c179f['unbind']('minHeight'),_0x5e560f?_0x2c179f['bind']('minHeight')['to'](_0x5e560f,'bottom'):_0x2c179f['minHeight']=null;}),_0x2c179f;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x2fc455){const _0x58e26a=this['_sidebarItemViewToAnnotation']['get'](_0x2fc455),_0x9dfae=_0x58e26a&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x58e26a)-0x1);return _0x9dfae&&this['getSidebarItemView'](_0x9dfae)||null;}['_getItemAfter'](_0x5ea53a){const _0x144ae6=this['_sidebarItemViewToAnnotation']['get'](_0x5ea53a),_0x412a0b=_0x144ae6&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x144ae6)+0x1);return _0x412a0b&&this['getSidebarItemView'](_0x412a0b)||null;}['_alignBeforeItem'](_0x406d0a,_0x4d7738){_0x406d0a['updateHeight']();const _0x47d924=G(_0x4d7738['bottom']+this['_spaceBetweenItems'],_0x406d0a['top']);return!!_0x47d924&&(this['_setItemTop'](_0x4d7738,_0x4d7738['top']-_0x47d924),!0x0);}['_alignAfterItem'](_0x5bd9d2,_0x535b6e){_0x5bd9d2['updateHeight']();const _0x242763=G(_0x5bd9d2['bottom']+this['_spaceBetweenItems'],_0x535b6e['top']);return!!_0x242763&&(this['_setItemTop'](_0x535b6e,_0x535b6e['top']+_0x242763,!0x1),!0x0);}['_alignToTargetRect'](_0x56f440){const _0x5221c0=this['_sidebarItemViewToAnnotation']['get'](_0x56f440);if(!_0x5221c0||!_0x5221c0['target']||!_0x5221c0['targetRect'])return;const _0x525168=this['_getTargetTop'](_0x5221c0,_0x5221c0['targetRect']);this['_setItemTop'](_0x56f440,_0x525168);}['_getTargetTop'](_0x347ba6,_0x4e6e1c){if(null===_0x4e6e1c)return 0x0;if(_0x347ba6['target']instanceof _0x2227f5)return _0x4e6e1c['top'];{const _0x163382=new _0x2227f5(this['view']['element'])['top'];return _0x4e6e1c['top']-_0x163382;}}['_setItemTop'](_0x287c46,_0x542bf1,_0x55c195=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x55c195&&(_0x542bf1=Math['max'](_0x542bf1,this['_getMaxAvailableTop'](_0x287c46))),_0x287c46['top']=_0x542bf1;}['_getMaxAvailableTop'](_0x394c7d){let _0x106368=this['_getItemBefore'](_0x394c7d),_0x2b42db=0x0;for(;_0x106368;)_0x106368['updateHeight'](),_0x2b42db+=this['_spaceBetweenItems']+_0x106368['height'],_0x106368=this['_getItemBefore'](_0x106368);return _0x2b42db;}}function G(_0x41d5c8,_0x35dc6e){return Math['max'](_0x41d5c8-_0x35dc6e,0x0);}function g(_0x1870d4){return null!==_0x1870d4&&'object'==typeof _0x1870d4&&0x1===_0x1870d4['nodeType'];}class e extends _0x51795f{['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(_0x36ad14){super(_0x36ad14),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x1b1267(),this['_refreshPositioningDebounced']=_0x4916fd(()=>{_0x36ad14['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x5b79f2=this['context']['plugins']['get'](j),_0x44ff50=this['context']['plugins']['get'](z);_0x5b79f2['register']('wideSidebar',this),_0x44ff50['container']&&_0x5b79f2['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x578f92){if(_0x578f92===this['activeAnnotation'])return;const _0xbf911=this['context']['plugins']['get'](z);_0xbf911['_activeAnnotation']=_0x578f92;const _0x198b2a=this['activeAnnotation'];_0xbf911['refresh']({'blurredAnnotation':_0x198b2a,'activatedAnnotation':_0x578f92}),this['activeAnnotation']=_0x578f92;}['attach'](_0x285d6d){this['annotations']=_0x285d6d;const _0x30f82e=this['context']['plugins']['get'](z);if(_0x30f82e['_annotations']=_0x285d6d,this['isAttached'])throw new _0x498a52('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x30f82e,'set:container',()=>{this['detach'](),this['listenTo'](_0x30f82e,'change:container',_0xeaccb=>{_0xeaccb['off'](),this['attach'](_0x285d6d);});}),_0x30f82e['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x5283ad=_0x3d6307=>{_0x3d6307['updateTargetRect'](),_0x30f82e['addAnnotation'](_0x3d6307);};for(const _0x6d7fe1 of _0x285d6d)_0x5283ad(_0x6d7fe1);this['listenTo'](_0x285d6d,'add',(_0x4dc3c6,_0x188b0d)=>{_0x5283ad(_0x188b0d);}),this['listenTo'](_0x285d6d,'remove',(_0x2ee125,_0x137782,_0x3308bf)=>{_0x30f82e['rearrange']({'removedAnnotation':_0x137782,'previousAnnotation':_0x285d6d['get'](_0x3308bf-0x1),'nextAnnotation':_0x285d6d['get'](_0x3308bf+0x1)}),_0x137782===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x285d6d,'focus',(_0x2c18b4,_0x2bc0c2)=>{this['setActiveAnnotation'](_0x2bc0c2);}),this['listenTo'](_0x285d6d,'blur',()=>{this['setActiveAnnotation'](null);});const _0x3f5ec8=this['context']instanceof _0x5ed2a5?this['context']['editors']:new _0x1b1267([this['context']]);for(const _0x225602 of _0x3f5ec8)this['_integrateWithEditorAnnotations'](_0x225602);this['listenTo'](_0x3f5ec8,'add',(_0x3d985f,_0x3026bc)=>{this['listenTo'](_0x3026bc,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x3026bc);});}),this['listenTo'](_0x3f5ec8,'remove',(_0x17a439,_0x3d6f95)=>{_0x3d6f95['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x3d6f95['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x498a52('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x4625ba=this['context']['plugins']['get'](z);_0x4625ba['_detachFromContainer'](this['annotations']),this['stopListening'](_0x4625ba),this['stopListening'](this['annotations']),this['context']instanceof _0x5ed2a5&&this['stopListening'](this['context']['editors']);for(const _0x28a27a of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x28a27a);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x1f3768){if(!_0x1f3768['plugins']['has']('EditorAnnotations'))return;const _0x4d8779=_0x1f3768['plugins']['get']('EditorAnnotations'),_0x2512e1=()=>{const _0x2e8643=_0x4d8779['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x2e8643[0x0]||null);};this['listenTo'](_0x4d8779,'refresh',_0x2512e1),this['listenTo'](_0x4d8779,'blur',(_0x1cf526,{isAnnotationTracked:_0x3cddb4})=>{this['activeAnnotation']&&_0x3cddb4(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x4d8779,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x4b1be3=>{_0x4d8779['hasDomSelection']()&&(_0x2512e1(),_0x4b1be3['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x4d8779);}['_destroyEditorAnnotationsIntegration'](_0x18b21d){this['stopListening'](_0x18b21d),this['_editorAnnotations']['remove'](_0x18b21d);}}class C extends _0x6b909b{['counterView'];constructor(_0x35841d){super(_0x35841d);const _0x552e4f=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x3951eb,_0x1c8818)=>_0x3951eb?'...':_0x1c8818['toString']()),this['set']('annotationType',''),this['icon']=_0x59b8c2,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x552e4f['to']('annotationType',_0x3dcc36=>'ck-annotation-counter__badge--'+_0x3dcc36),_0x552e4f['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x552e4f['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x51795f{['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(_0x548579){super(_0x548579),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x128deb())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x1b1267(),this['_refreshPositioningDebounced']=_0x4916fd(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x3adbc2(this['context']['locale']),this['balloonPanelView']=new _0x59086b(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0xe3f238){this['annotations']=_0xe3f238;const _0xa74ae2=this['context']['plugins']['get'](z),_0x202c46=this['balloonPanelView'];if(_0xa74ae2['_annotations']=_0xe3f238,this['isAttached'])throw new _0x498a52('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0xa74ae2,'set:container',()=>{this['detach'](),this['listenTo'](_0xa74ae2,'change:container',_0x424700=>{_0x424700['off'](),this['attach'](_0xe3f238);});}),_0xa74ae2['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x2c3979=_0x2fada6=>{const _0x2d57b4=new C(this['context']['locale']);_0xa74ae2['addAnnotation'](_0x2fada6,_0x2d57b4),this['_annotationToNarrowView']['set'](_0x2fada6,_0x2d57b4),_0x2d57b4['bind']('isDirty','annotationType','number')['to'](_0x2fada6['view'],'isDirty','type','length'),_0x2d57b4['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x202c46['content']['first']!==_0x2fada6['view']?(this['_showBalloon'](_0x2fada6),_0x2fada6['view']['element']['focus'](),this['setActiveAnnotation'](_0x2fada6)):this['setActiveAnnotation'](null);});};for(const _0x4dd4fc of _0xe3f238)_0x2c3979(_0x4dd4fc);this['listenTo'](_0xe3f238,'add',(_0x5caf5a,_0x337eed)=>{_0x2c3979(_0x337eed);}),this['listenTo'](_0xe3f238,'remove',(_0x31ef14,_0x2b696d,_0x31c746)=>{this['_annotationToNarrowView']['get'](_0x2b696d)['destroy'](),this['_annotationToNarrowView']['delete'](_0x2b696d),_0xa74ae2['rearrange']({'removedAnnotation':_0x2b696d,'previousAnnotation':_0xe3f238['get'](_0x31c746-0x1),'nextAnnotation':_0xe3f238['get'](_0x31c746+0x1)}),_0x2b696d===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0xe3f238,'focus',(_0x13033a,_0x3ff4a)=>{this['setActiveAnnotation'](_0x3ff4a);}),this['listenTo'](_0xe3f238,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x3e13cb,_0x2049de)=>{_0x2049de['keyCode']===_0x54f57c['esc']&&_0x202c46['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x202c46['content']['first']),this['_hideBalloon'](),_0x2049de['stopPropagation'](),_0x2049de['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x3c771d,_0x35a585)=>{const _0x204089=_0x35a585['target'];_0x202c46['isVisible']&&_0x202c46['element']['contains'](_0x204089)||_0xa74ae2['view']['element']['contains'](_0x204089)||_0x3c771d['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x4665ef=>_0x4665ef['contains'](_0x204089))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x3bf53c=this['context']instanceof _0x5ed2a5?this['context']['editors']:new _0x1b1267([this['context']]);for(const _0x5a7cef of _0x3bf53c)this['_integrateWithEditorAnnotations'](_0x5a7cef);this['listenTo'](_0x3bf53c,'add',(_0x4afbee,_0x472958)=>{this['listenTo'](_0x472958,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x472958);});}),this['listenTo'](_0x3bf53c,'remove',(_0x157bfd,_0xfc9acf)=>{_0xfc9acf['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0xfc9acf['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x2cf891){if(_0x2cf891===this['activeAnnotation'])return;const _0x31a5b7=this['context']['plugins']['get'](z);if(_0x31a5b7['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x2cf891,'disableAnimationOnActivatedAnnotation':!0x0}),_0x2cf891)_0x31a5b7['getSidebarItemView'](_0x2cf891)?this['_showBalloon'](_0x2cf891):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x2cf891;}['detach'](){if(!this['isAttached'])throw new _0x498a52('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x3a29a6=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x118b89=>_0x118b89['destroy']()),this['_annotationToNarrowView']['clear'](),_0x3a29a6['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x5ed2a5&&this['stopListening'](this['context']['editors']);for(const _0x5199f1 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x5199f1);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'](_0x2bcd84){if(!_0x2bcd84['plugins']['has']('EditorAnnotations'))return;const _0x3240de=_0x2bcd84['plugins']['get']('EditorAnnotations'),_0x4c7e41=this['context']['plugins']['get'](z),_0x4303ce=this['annotations'],_0x4e56c2=this['balloonPanelView'],_0x4f0bd1=()=>{const _0x29c87b=_0x3240de['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x29c87b),this['setActiveAnnotation'](_0x29c87b[0x0]||null);};this['listenTo'](_0x3240de,'refresh',_0x4f0bd1),this['listenTo'](_0x3240de,'blur',(_0x45138d,{isAnnotationTracked:_0x875334})=>{this['activeAnnotation']&&_0x875334(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x3240de,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x4303ce,'blur',_0x2b9d29=>{_0x3240de['hasDomSelection']()&&_0x2b9d29['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x50b78f,_0x230328)=>{const _0x11dd71=_0x230328['target'];_0x4e56c2['isVisible']&&_0x4e56c2['element']['contains'](_0x11dd71)||_0x4c7e41['view']['element']['contains'](_0x11dd71)||this['activeAnnotation']&&_0x3240de['hasDomSelection']()&&(_0x4f0bd1(),_0x50b78f['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x3240de);}['_destroyEditorAnnotationsIntegration'](_0x2cd28a){_0x2cd28a&&(this['stopListening'](_0x2cd28a),this['_editorAnnotations']['remove'](_0x2cd28a));}['_setSelectedAnnotations'](_0x5853d1){for(const _0x4b0e08 of this['_selectedAnnotations'])_0x5853d1['includes'](_0x4b0e08)||this['_manuallyClosedAnnotationViews']['delete'](_0x4b0e08['view']);this['_selectedAnnotations']=_0x5853d1;}['_refreshPositioning'](){const _0x162b38=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x162b38['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x213f71){if(this['_manuallyClosedAnnotationViews']['has'](_0x213f71['view']))return;const _0x316fc2=this['balloonPanelView']['content']['first'];_0x316fc2!==_0x213f71['view']?(_0x316fc2&&this['_detachListeners'](_0x316fc2),this['_attachListeners'](_0x213f71['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x213f71['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x4c1073=this['balloonPanelView']['content']['first'],_0x1ca663=_0x4c1073&&this['annotations']['getByView'](_0x4c1073);if(!_0x1ca663||!this['_annotationToNarrowView']['has'](_0x1ca663))return;const _0x5dbba7=this['_annotationToNarrowView']['get'](_0x1ca663)['element'],_0xd3086e=(function(){const _0x16920b=_0x59086b['defaultPositions'];return[_0x16920b['southArrowNorthEast'],_0x16920b['northArrowSouthEast'],_0x16920b['southArrowNorth'],_0x16920b['northArrowSouth'],_0x16920b['southArrowNorthWest'],_0x16920b['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x5dbba7,'positions':_0xd3086e});}['_hideBalloon'](){const _0x43e3e9=this['balloonPanelView'],_0x4584c7=_0x43e3e9['content']['first'];_0x4584c7&&(this['_detachListeners'](_0x4584c7),_0x43e3e9['unpin'](),_0x43e3e9['content']['clear']());}['_attachListeners'](_0x1dda64){this['listenTo'](_0x1dda64,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x1dda64,'Esc',(_0x568282,_0x5ea3af)=>{this['_manuallyClosedAnnotationViews']['add'](_0x1dda64),this['_hideBalloon'](),_0x5ea3af();});}['_detachListeners'](_0x57ee3a){this['stopListening'](_0x57ee3a);}}class c extends _0x2d240e{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];['_refreshVisibilityDebounced'];static get['requires'](){return[b,_0x2d4f82,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4f5441){super(_0x4f5441),_0x4f5441['editing']['view']['addObserver'](_0x3b6d41),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x4f5441['plugins']['get'](_0x2d4f82),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1,this['_refreshVisibilityDebounced']=_0x4916fd(()=>{this['editor']['plugins']['get']('Annotations')['refreshVisibility']();},0xfa,{'leading':!0x1});}['init'](){const _0x5edf2f=this['editor']['plugins']['get'](j);_0x5edf2f['context']===this['editor']&&(_0x5edf2f['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x3a8c20,_0x356896)=>{const _0x53ae03=this['_balloon'];if(this['isAttached']&&_0x53ae03['visibleView']){const _0x27a6d9=this['annotations']['getByView'](_0x53ae03['visibleView']);_0x27a6d9&&this['_closeAnnotation'](_0x27a6d9),_0x356896();}}));}['afterInit'](){const _0x1fd965=this['editor']['plugins']['get'](j);_0x1fd965['context']===this['editor']&&(_0x1fd965['hasActive']()||_0x1fd965['switchTo']('inline'));}['setActiveAnnotation'](_0x3f0371){_0x3f0371!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x3f0371&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x3f0371)&&this['_addAnnotationToBalloon'](_0x3f0371,!0x0),_0x3f0371['isActive']=!0x0),_0x3f0371||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x3f0371);}['attach'](_0x17042c){this['annotations']=_0x17042c;const _0x5f2d68=this['editor']['plugins']['get'](j),_0x2c6aa2=this['_balloon'];if(this['isAttached'])throw new _0x498a52('inlineannotations-attach-already-attached',this);if(_0x5f2d68['context']!==this['editor'])throw new _0x498a52('inlineannotations-not-allowed-with-context',this);const _0x425d02=this['editor']['plugins']['get'](b);this['listenTo'](_0x425d02,'refresh',()=>{const _0x1868d9=_0x425d02['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x1c7e32,_0x4e3a86;!this['_forceRefresh']&&(_0x1c7e32=_0x1868d9,_0x4e3a86=this['_selectedAnnotations'],_0x1c7e32['length']===_0x4e3a86['length']&&_0x1c7e32['every'](_0x1481ae=>_0x4e3a86['includes'](_0x1481ae)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x1868d9),this['setActiveAnnotation'](_0x1868d9[0x0]||null));}),this['listenTo'](_0x425d02,'blur',(_0x211e93,{isAnnotationTracked:_0x27d616})=>{this['activeAnnotation']&&_0x27d616(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x425d02,'uiUpdate',()=>{this['_refreshVisibilityDebounced']();}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x1e1cc0,_0x123aa7,_0x3bc4ad)=>{_0x3bc4ad||this['setActiveAnnotation'](null);}),this['listenTo'](_0x17042c,'remove',(_0x4003ab,_0x132638)=>{this['_removeAnnotationFromBalloon'](_0x132638),_0x132638===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x2c6aa2,'change:visibleView',(_0x195b12,_0x2c58a2,_0xa5860e,_0x5522f5)=>{_0x5522f5&&this['stopListening'](_0x5522f5);const _0x11d605=_0x17042c['getByView'](_0xa5860e);_0xa5860e&&_0x11d605&&(this['listenTo'](_0xa5860e,'change:height',()=>{_0x2c6aa2['updatePosition']();}),this['listenTo'](_0xa5860e,'Esc',()=>{this['_closeAnnotation'](_0x11d605),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x11d605&&this['setActiveAnnotation'](_0x11d605));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x2c6aa2['visibleView']&&(_0x17042c['getByView'](_0x2c6aa2['visibleView'])&&_0x2c6aa2['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 _0x498a52('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x101ee8 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x101ee8);this['_refreshVisibilityDebounced']['cancel'](),this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['_refreshVisibilityDebounced']['cancel']();}['_setSelectedAnnotations'](_0x398ed5){for(const _0x2a374e of this['_selectedAnnotations'])_0x398ed5['includes'](_0x2a374e)||this['_manuallyClosed']['delete'](_0x2a374e);for(const _0x1761f8 of this['annotations'])_0x398ed5['includes'](_0x1761f8)||this['_removeAnnotationFromBalloon'](_0x1761f8);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0xd12c19 of _0x398ed5)this['_addAnnotationToBalloon'](_0xd12c19);}this['_selectedAnnotations']=_0x398ed5;}['_addAnnotationToBalloon'](_0x398d74,_0x2e6544=!0x1){this['_manuallyClosed']['has'](_0x398d74)||(this['_addedAnnotations']['has'](_0x398d74)||this['_balloon']['hasView'](_0x398d74['view'])||(this['_addedAnnotations']['add'](_0x398d74),this['_balloon']['add']({'stackId':_0x398d74['view']['id'],'view':_0x398d74['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x398d74)}})),_0x2e6544&&this['_balloon']['showStack'](_0x398d74['view']['id']));}['_getBalloonTargetForAnnotation'](_0x234e64){const _0x49f398=_0x234e64['target'],_0x532914=this['editor']['editing']['view'],_0xebad59=_0x532914['document']['selection']['getFirstRange'](),_0x126cb7=_0x532914['domConverter']['viewRangeToDom'](_0xebad59);if(_0x126cb7['collapse'](!0x0),_0x49f398){if(_0x49f398 instanceof _0x2227f5)return _0x49f398;let _0x55aa03=[];for(const _0x6aa118 of _0x49f398)_0x55aa03['push'](...F(_0x6aa118['getClientRects']()));_0x55aa03=function(_0x3bd4eb){const _0x41df22=[];let _0xd3c6fd=_0x3bd4eb[0x0];for(let _0x24ce20=0x1;_0x24ce20<_0x3bd4eb['length'];_0x24ce20++)P(_0xd3c6fd,_0x3bd4eb[_0x24ce20])?_0xd3c6fd['width']+=_0x3bd4eb[_0x24ce20]['width']:(_0x41df22['push'](_0xd3c6fd),_0xd3c6fd=_0x3bd4eb[_0x24ce20]);return _0x41df22['push'](_0xd3c6fd),_0x41df22;}(_0x55aa03);const _0x41770e=_0x126cb7['getBoundingClientRect']();return _0x55aa03['find'](_0x110e91=>_0x110e91['top']<=_0x41770e['top']&&_0x110e91['bottom']>=_0x41770e['bottom']&&_0x110e91['left']<=_0x41770e['left']&&_0x110e91['right']>=_0x41770e['right'])||_0x55aa03[0x0];}return _0x234e64['targetRect']||_0x126cb7;}['_removeAnnotationFromBalloon'](_0x891cba){this['_addedAnnotations']['has'](_0x891cba)&&this['_balloon']['hasView'](_0x891cba['view'])&&(this['_addedAnnotations']['delete'](_0x891cba),this['_balloon']['remove'](_0x891cba['view']));}['_closeAnnotation'](_0x5c1b43){this['_manuallyClosed']['add'](_0x5c1b43),this['_removeAnnotationFromBalloon'](_0x5c1b43);}}function F(_0x3d4954){return Array['from'](_0x3d4954)['map'](DOMRect['fromRect']);}function P(_0x2b69e3,_0x28dc2e){return _0x2b69e3['top']===_0x28dc2e['top']&&_0x2b69e3['bottom']===_0x28dc2e['bottom']&&_0x2b69e3['right']===_0x28dc2e['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x300076,_0x46978d){super(_0x300076),this['set']('isEmpty',!_0x46978d['length']),this['focusTracker']=new _0x144d0f(),this['_annotationViews']=_0x46978d,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x37e2ac({'focusables':_0x46978d,'focusTracker':this['focusTracker']}),this['listenTo'](_0x46978d,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x46978d,'remove',(_0x22a305,_0x298048)=>{_0x298048['isActive']&&this['focus'](),_0x46978d['length']||(this['isEmpty']=!0x0);});const _0x26b937=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x300076,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x46978d},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x26b937['if']('isEmpty','ck-hidden',_0x3cdcae=>!_0x3cdcae)]},'children':[{'text':N(_0x300076,'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 _0x4c8dcb of this['_annotationViews'])this['focusTracker']['add'](_0x4c8dcb['element']);this['_annotationViews']['on']('change',(_0x248475,{added:_0x9314a2,removed:_0x3e4fc9})=>{for(const _0x320e1b of _0x9314a2)this['focusTracker']['add'](_0x320e1b['element']);for(const _0x440325 of _0x3e4fc9)this['focusTracker']['remove'](_0x440325['element']);});}}class p extends _0x51795f{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x195aef){super(_0x195aef),this['archivedThreads']=new _0x1b1267();}['init'](){const _0x146349=this['context'],_0x2690b6=_0x146349['plugins']['get'](o),_0x400477=_0x146349['plugins']['get'](y);this['listenTo'](_0x2690b6,'addCommentThread',(_0x1972bc,{threadId:_0x50f531})=>{const _0x564df8=_0x2690b6['getCommentThread'](_0x50f531);_0x564df8['archivedAt']&&this['archivedThreads']['add'](_0x564df8,this['_calculatePosition'](_0x564df8['archivedAt'])),this['listenTo'](_0x564df8,'change:archivedAt',(_0x54d2cf,_0x3c68d1,_0x2b7dad)=>{_0x2b7dad?this['archivedThreads']['has'](_0x564df8)||this['archivedThreads']['add'](_0x564df8,this['_calculatePosition'](_0x564df8['archivedAt'])):this['archivedThreads']['has'](_0x564df8)&&this['archivedThreads']['remove'](_0x564df8);});}),this['listenTo'](_0x2690b6,'removeCommentThread',(_0x28f4dd,{threadId:_0x4112f8})=>{const _0x40f8e9=_0x2690b6['getCommentThread'](_0x4112f8);this['stopListening'](_0x40f8e9),this['archivedThreads']['has'](_0x40f8e9)&&this['archivedThreads']['remove'](_0x40f8e9);},{'priority':'highest'}),this['listenTo'](_0x400477['collection'],'focus',(_0x588560,_0x12573a)=>{_0x12573a['isVisible']||(_0x12573a['isActive']=!0x0,_0x400477['activate'](_0x12573a));});}['_calculatePosition'](_0x36c760){const _0x32a464=[...this['archivedThreads']]['findIndex'](_0x4fc1af=>_0x4fc1af['archivedAt']<_0x36c760);return _0x32a464>-0x1?_0x32a464:this['archivedThreads']['length'];}}class a extends _0x2d240e{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x4adc55];}constructor(_0x120f17){super(_0x120f17),this['annotationViews']=new _0x437229(),this['_pendingThreads']=[];}['init'](){const _0x359f5a=this['editor'],_0x47630d=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x359f5a['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x6b909b,!0x0)),_0x359f5a['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x5e4a48=this['_createCommentsArchiveButton'](_0x1d6833);return _0x5e4a48['set']({'role':'menuitemcheckbox'}),_0x5e4a48;});const _0x63cced=_0x359f5a['plugins']['get'](p),_0x556e2f=_0x359f5a['plugins']['get']('Annotations'),_0x284c8d=_0x359f5a['plugins']['get']('CommentsRepository');_0x63cced['archivedThreads']['forEach'](_0x4beb6c=>{this['_handleNewThread'](_0x4beb6c);}),this['listenTo'](_0x63cced['archivedThreads'],'add',(_0x298970,_0x5416fa)=>{this['_handleNewThread'](_0x5416fa);}),this['listenTo'](_0x556e2f['collection'],'add',(_0x227f1b,_0x233c83)=>{const _0x1f2cd1=this['_pendingThreads']['find'](_0x2d8eea=>{const _0x1ee089=_0x284c8d['_threadToController']['get'](_0x2d8eea);return _0x1ee089&&_0x233c83['innerView']===_0x1ee089['view'];});if(_0x1f2cd1){const _0x3b7100=this['_calculatePosition'](_0x1f2cd1['archivedAt']);this['_addAnnotationToArchive'](_0x233c83,_0x3b7100),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x1f2cd1),0x1);}}),this['listenTo'](_0x63cced['archivedThreads'],'remove',(_0x1460a4,_0x2da440)=>{const _0x1b0bbc=_0x359f5a['config']['get']('collaboration.channelId');if(!_0x1b0bbc||_0x2da440['channelId']===_0x1b0bbc){if(this['_pendingThreads']['includes'](_0x2da440))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x2da440),0x1);else{const _0x327b44=_0x284c8d['_threadToController']['get'](_0x2da440),_0x260313=_0x556e2f['getByInnerView'](_0x327b44['view']);this['annotationViews']['remove'](_0x260313['view']),this['stopListening'](_0x260313),this['stopListening'](_0x260313['focusableElements']);}}}),this['listenTo'](_0x556e2f['collection'],'add',(_0x4bddf4,_0x16ed2d)=>{this['listenTo'](_0x16ed2d,'escape',_0x47630d);}),this['listenTo'](_0x556e2f['collection'],'remove',(_0xe6017f,_0x361a12)=>{this['stopListening'](_0x361a12,'escape',_0x47630d);});}['_addAnnotationToArchive'](_0x56cf7b,_0x18ceb2){this['listenTo'](_0x56cf7b,'set:isVisible',_0x3bcbaf=>{_0x3bcbaf['return']=!0x1,_0x3bcbaf['stop']();}),this['annotationViews']['add'](_0x56cf7b['view'],_0x18ceb2);}['_handleNewThread'](_0x591634){const _0x432e55=this['editor']['plugins']['get']('CommentsRepository'),_0x2a24f0=this['editor']['plugins']['get']('Annotations'),_0x245cd3=this['editor']['config']['get']('collaboration.channelId');if(!_0x245cd3||_0x591634['channelId']===_0x245cd3){const _0x4a4c2e=_0x432e55['_threadToController']['get'](_0x591634);if(!_0x4a4c2e)return void this['_pendingThreads']['push'](_0x591634);const _0x2c58a7=this['_calculatePosition'](_0x591634['archivedAt']),_0x5ccaa1=_0x2a24f0['getByInnerView'](_0x4a4c2e['view']);_0x5ccaa1['isVisible']&&_0x2a24f0['_visibleAnnotations']['remove'](_0x5ccaa1),this['_addAnnotationToArchive'](_0x5ccaa1,_0x2c58a7);}}['_calculatePosition'](_0x15e3ba){const _0x7a2fe6=this['editor']['config']['get']('collaboration.channelId'),_0x303a35=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0x113dd6=>_0x113dd6['channelId']===_0x7a2fe6)['findIndex'](_0x3daae8=>_0x3daae8['archivedAt']<_0x15e3ba);return _0x303a35<0x0||_0x303a35>this['annotationViews']['length']?this['annotationViews']['length']:_0x303a35-0x1;}['_toggleDialog'](){const _0x3d94fb=this['editor'],_0x4ad477=_0x3d94fb['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x3d94fb['locale'],this['annotationViews'])),'commentsArchive'===_0x4ad477['id']?_0x4ad477['hide']():_0x4ad477['show']({'id':'commentsArchive','title':N(_0x3d94fb['locale'],'COMMENTS_ARCHIVE'),'icon':_0x50c104,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x3c4ef8['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x186a4b,_0x44c780=!0x1){const _0x67096a=this['editor']['locale'],_0x1bbdb0=this['editor']['plugins']['get']('Dialog'),_0x142f02=new _0x186a4b(_0x67096a);return _0x142f02['bind']('isEnabled')['to'](this,'isEnabled'),_0x142f02['bind']('isOn')['to'](_0x1bbdb0,'id',_0x4081e5=>'commentsArchive'===_0x4081e5),_0x142f02['set']({'label':N(_0x67096a,'COMMENTS_ARCHIVE'),'icon':_0x50c104,'isToggleable':!0x0}),_0x44c780&&(_0x142f02['tooltip']=!0x0),this['listenTo'](_0x142f02,'execute',()=>this['_toggleDialog']()),_0x142f02;}['_hideDialogOnAnnotationEscape']=_0x9ed9eb=>{const _0x203786=_0x9ed9eb['source'];if(!this['annotationViews']['has'](_0x203786['view']))return;const _0x5b4e91=this['editor']['plugins']['get']('Dialog');_0x5b4e91['isOpen']&&'commentsArchive'===_0x5b4e91['id']&&(_0x5b4e91['hide'](),_0x9ed9eb['stop']());};}class gi extends _0x2d240e{static get['requires'](){return[o,r,s,p,a,i,e,n,c];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{ot as AddCommentThreadCommand,T as Annotation,S as AnnotationCollection,C as AnnotationCounterButtonView,E as AnnotationView,y as Annotations,R as AnnotationsSidebarItemView,H as AnnotationsSidebarView,j as AnnotationsUIs,si as BaseCommentThreadView,di as BaseCommentView,wi as Comment,pi as CommentThread,vt as CommentThreadController,ie as CommentThreadInputView,gt as CommentThreadView,Tt as CommentView,gi as Comments,p as CommentsArchive,a as CommentsArchiveUI,r as CommentsEditing,te as CommentsListView,i as CommentsOnly,o as CommentsRepository,s as CommentsUI,b as EditorAnnotations,c as InlineAnnotations,n as NarrowSidebar,z as Sidebar,e as WideSidebar,v as bindAnnotationCollections};
23
+ import{Editor as _0x22a44e,ContextPlugin as _0x3110a5,PendingActions as lt,Command as _0x296d98,Plugin as _0x25b6bf,Context as _0x1726b6}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0xca3058,uid as _0x14661f,KeystrokeHandler as jt,FocusTracker as _0x44f1cb,diff as _0x3f67f3,Collection as _0x4fc713,Rect as _0x375970,CKEditorError as _0xd7b9fb,first as _0xa3ef79,priorities as Wt,scrollViewportToShowTarget as nt,getEnvKeystrokeText as tt,toUnit as Ht,DomEmitterMixin as _0x68bcfd,keyCodes as _0x5eb4f3}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x5537f3,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x75fe4c,trimHtml as ts,LateFocusDropdownButtonView as _0xa07f13,Users as it,getDateTimeFormatter as pt,hashObject as It,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as rt,FOCUS_ANNOTATION_KEYSTROKE as _0x253346}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as At,cloneDeep as wt,set as yt,unset as Ct,debounce as _0x46ba7a}from'es-toolkit/compat';import{IconUndo as _0x434316,IconCheck as _0x611c86,IconPencil as _0x2e1b6c,IconRemoveComment as _0x3a1ba4,IconThreeVerticalDots as _0x437776,IconAddComment as _0x37d815,IconCommentsArchive as _0x3db991}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as $t,InlineEditableUIView as Vt,EditorUI as Ut,View as kt,FocusCycler as _0x47d7f6,ButtonView as _0xf18eca,ViewCollection as _0x9ecf0b,createDropdown as _0x25965d,ListView as _0x9a55eb,focusChildOnDropdownOpen as _0x569b97,ListItemView as _0x5629aa,MenuBarMenuListItemButtonView as _0x892bd0,BodyCollection as _0x9a194a,BalloonPanelView as _0x484888,ContextualBalloon as _0x4ecb9d,Dialog as _0x57a2d7,DialogViewPosition as _0x1300f0}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disableViewPlaceholder as St,enableViewPlaceholder as Ft,MouseObserver as _0x5956f6}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 _0xa0140e}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x631d41}from'@ckeditor/ckeditor5-widget/dist/index.js';class vt extends/* #__PURE__ -- @preserve */
24
+ _0xca3058(){['model'];['view'];constructor(_0x106c66,_0x4f0d37){super(),this['model']=_0x106c66,this['model']['_isAttached']=!0x0,this['view']=_0x4f0d37,this['listenTo'](_0x4f0d37,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x4f0d37,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x4f0d37,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x4f0d37,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x4f0d37,'addComment',(_0x1cb145,_0x458345)=>this['addComment'](_0x458345)),this['listenTo'](_0x4f0d37,'updateComment',(_0x18d02f,_0x5760ad,_0x3b5b55)=>this['updateComment'](_0x5760ad,_0x3b5b55)),this['listenTo'](_0x4f0d37,'removeComment',(_0x585eeb,_0x43233b)=>this['removeComment'](_0x43233b));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x38ca19){this['model']['addComment']({'content':_0x38ca19,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x273352,_0x841fd4){this['model']['getComment'](_0x273352)['update']({'content':_0x841fd4});}['removeComment'](_0x769657){this['model']['getComment'](_0x769657)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function N(_0x5acea0,_0xe43eb0,_0x3c3d8b){const t=_0x5acea0['t'];switch(_0xe43eb0){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'},_0x3c3d8b);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'},_0x3c3d8b);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'},_0x3c3d8b);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'},_0x3c3d8b);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x3c3d8b);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'},_0x3c3d8b);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'},_0x3c3d8b);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'},_0x3c3d8b);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(_0x20b165,_0x294f43){super(_0x20b165);const _0x321a67=_0x14661f();this['main']=this['createCollection'](),this['editable']=new Vt(_0x20b165,_0x294f43,void 0x0,{'label':()=>N(_0x20b165,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x20b165['uiLanguageDirection'],'lang':_0x20b165['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x321a67},'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(_0x15bd85){super(_0x15bd85),this['view']=new Rt(_0x15bd85['locale'],_0x15bd85['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x133557=this['editor']['editing']['view'],_0x1042e7=this['view']['editable'],_0x262be9=_0x133557['document']['getRoot']();_0x1042e7['name']=_0x262be9['rootName'],this['view']['render']();const _0x31db62=_0x1042e7['element'];this['setEditableElement'](_0x1042e7['name'],_0x31db62),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x133557['attachDomRoot'](_0x31db62),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[qt,zt,Bt,Gt,Jt,Kt,Lt];class hs extends/* #__PURE__ -- @preserve */
25
+ _0xca3058(_0x22a44e){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
+ ((()=>Qt)());constructor(_0x3073f7={}){function _0x57e2af(_0x5a8110){return _0x5a8110['map'](_0x29b8f0=>String['fromCharCode'](_0x29b8f0))['join']('');}(_0x3073f7=Object['assign']({},_0x3073f7))['plugins']||(_0x3073f7['plugins']=hs['defaultPlugins']),super(_0x3073f7),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[_0x57e2af([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x57e2af([0x76,0x69,0x65,0x77])][_0x57e2af([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x57e2af([0x61,0x75,0x74,0x6f]),this[_0x57e2af([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x57e2af([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x57e2af([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x57e2af([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x57e2af([0x6f,0x6b])});}['create'](){const _0x1235d4=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x1235d4))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x3c9b85=>{const _0x48052a=this['model']['document']['getRoot'](),_0x53f0ed=_0x48052a&&_0x48052a['getChild'](_0x48052a['childCount']-0x1);_0x3c9b85['setSelection'](_0x53f0ed,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x59413c=this['editing']['view'],_0x56581d=_0x59413c['document']['getRoot'](),_0x3c3b98=_0x56581d['getChild'](0x0);_0x56581d['childCount']>0x1||!_0x3c3b98||'p'!=_0x3c3b98['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x59413c,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x3c3b98['placeholder']=this['placeholder']),Ft({'view':_0x59413c,'element':_0x3c3b98,'keepOnFocus':!0x0}),this['placeholderElement']=_0x3c3b98);}}class es extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x20ca14,_0x17b230={}){super(_0x20ca14),this['editor']=null,this['_editorConfig']=_0x17b230,this['set']('value',_0x17b230['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',N(_0x20ca14,'Reply...')),this['set']('submitLabel',N(_0x20ca14,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x44f1cb(),this['focusCycler']=new _0x47d7f6({'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',(_0x3b979b,_0x10d1bc)=>{this['cancelButtonView']['fire']('execute'),_0x10d1bc();}),this['keystrokes']['set']('Ctrl+Enter',(_0x4e3443,_0x1d4243)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x1d4243());}),this['on']('submit',(_0x5783e2,_0x4d5370)=>{_0x4d5370['length']>0xfde8?(alert(N(_0x20ca14,'TOO_LONG_COMMENT_ALERT',[_0x4d5370['length'],0xfde8])),_0x5783e2['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 _0x2845cd=this['editor'];this['element']['insertBefore'](_0x2845cd['ui']['element'],this['element']['firstChild']),_0x2845cd['model']['document']['on']('change',()=>this['value']=_0x2845cd['getData']()),_0x2845cd['bind']('placeholder')['to'](this),this['focusables']['add'](_0x2845cd['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x255736){-0x1===_0x255736?(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:_0x5dbc64}=this,_0x49f541=new _0xf18eca(_0x5dbc64);return _0x49f541['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x49f541['withText']=!0x0,_0x49f541['bind']('label')['to'](this,'submitLabel'),_0x49f541['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x49f541['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x20cda0,_0x8bd780)=>!_0x8bd780&&!!_0x20cda0['trim']()),_0x49f541;}['_createCancelButton'](){const {locale:_0x28b44b}=this,_0x4fb08e=new _0xf18eca(_0x28b44b);return _0x4fb08e['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x4fb08e['label']=N(_0x28b44b,'Cancel'),_0x4fb08e['withText']=!0x0,_0x4fb08e['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x4fb08e;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x4eb504=>{this['focusTracker']['add'](_0x4eb504['element']);}),this['focusables']['on']('change',(_0x3e9b75,_0x40cb76)=>{for(const _0x451d2b of Array['from'](_0x40cb76['added'])['reverse']())this['focusTracker']['add'](_0x451d2b['element']);});}}class ie extends kt{constructor(_0xafa8ad,_0x17ca89,_0x108004){super(_0xafa8ad),this['commentInputView']=new es(_0xafa8ad,_0x108004),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x1be040,_0x16aaf6)=>_0x1be040||!!_0x16aaf6),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 _0x5537f3(_0xafa8ad,_0x17ca89),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'](_0x492e4e){this['commentInputView']['focus'](_0x492e4e);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x56943e,_0x3f465d)=>{const {submitButtonView:_0x548e8e,cancelButtonView:_0x354573,editor:_0x21d867}=this['commentInputView'];[_0x548e8e['element'],_0x354573['element'],_0x21d867?_0x21d867['editing']['view']['getDomRoot']():null]['filter'](_0x276b76=>_0x276b76)['some'](_0x2dbcc5=>_0x2dbcc5['contains'](_0x3f465d['target']))||(this['focus'](),_0x3f465d['preventDefault']());});}}class rs extends kt{constructor(_0x37e497){super(_0x37e497);const _0x491e04=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x491e04['to']('count',_0x12d7fb=>N(_0x37e497,'NUMBER_OF_COMMENTS',_0x12d7fb))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x42f88a,_0x24dd2a,_0x1533b5){super(_0x42f88a);const _0x2e89e5=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x24dd2a['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x24dd2a,this['_config']=_0x1533b5,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x44f1cb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x47d7f6({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x26f84d=>this['commentViews']['map'](_0x242934=>_0x242934['element'])['includes'](_0x26f84d['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new rs(_0x42f88a),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0xaca3c7=>_0xaca3c7-this['_config']['maxCommentsWhenCollapsed']);for(const _0x33eee3 of _0x24dd2a['comments'])this['_handleNewCommentModel'](_0x33eee3);this['_handleInfoComment'](),this['listenTo'](_0x24dd2a['comments'],'add',(_0x511a72,_0x1384a7)=>{const _0xa3f37c=this['_calculatePosition'](_0x1384a7);this['length']++,this['_handleNewCommentModel'](_0x1384a7,_0xa3f37c),this['refreshVisibleViews']();}),this['listenTo'](_0x24dd2a['comments'],'remove',(_0x2f50cd,_0x22e07c)=>{this['length']--,this['_handleRemoveCommentModel'](_0x22e07c),this['refreshVisibleViews']();}),this['listenTo'](_0x24dd2a,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x24dd2a,'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',_0x2e89e5['if']('length','ck-hidden',_0x4a034b=>!_0x4a034b)],'aria-label':N(_0x42f88a,'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'](_0xd67d8f){-0x1===_0xd67d8f?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x503e9d of this['commentViews'])_0x503e9d['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x1591e4,_0x5e7a69){const _0x1a64a5=new this['_config']['CommentView'](this['locale'],_0x1591e4,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x1a64a5['viewUid']=_0x1591e4['id'],_0x1a64a5['delegate']('removeComment')['to'](this),_0x1a64a5['delegate']('updateComment')['to'](this),_0x1a64a5['delegate']('resolveCommentThread')['to'](this),_0x1a64a5['delegate']('editorReady')['to'](this),_0x1a64a5['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x1a64a5,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x1a64a5,_0x5e7a69);}['_calculatePosition'](_0x6c02d8){const _0x4efeaa=this['_model']['_findOptimalIndex'](_0x6c02d8);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x6c02d8['authoredAt']?_0x4efeaa-0x1:_0x4efeaa:_0x4efeaa-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x2fdfc8={'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'],_0x2fdfc8,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x2fdfc8));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0xe5e8e){const _0x4155f3=this['commentViews']['remove'](_0xe5e8e['id']);this['stopListening'](_0x4155f3),_0x4155f3['isEditMode']&&this['_updateHasDirtyComment'](),_0x4155f3['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x5b4cca=>_0x5b4cca['isEditMode']);}['_rearrangeCollapse'](){const _0xe70320=function(_0x286ab7){const _0x1ebc6b=new _0x4fc713();for(const _0x46370b of _0x286ab7)_0x1ebc6b['add'](_0x46370b);return _0x1ebc6b;}(this['commentViews']),_0x1b2486=this['_collapsedCommentsView']['count'];for(let _0x2db9a4=0x1;_0x2db9a4<=_0x1b2486;_0x2db9a4++)_0xe70320['remove'](0x1);for(const _0x3510cf of _0xe70320)_0x3510cf['collapse']();_0x1b2486>0x0&&_0xe70320['add'](this['_collapsedCommentsView'],0x1),ns(_0x3f67f3(Array['from'](this['visibleViews']),Array['from'](_0xe70320)),this['visibleViews'],_0xe70320);}['_rearrangeExpand'](){ns(_0x3f67f3(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x11f025 of this['visibleViews'])_0x11f025['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x1a131c=>{this['focusTracker']['add'](_0x1a131c['element']),this['keystrokes']['listenTo'](_0x1a131c['element']);}),this['commentViews']['on']('change',(_0x203feb,_0x6e37c1)=>{for(const _0x4ddbf4 of _0x6e37c1['removed'])this['focusTracker']['remove'](_0x4ddbf4['element']),this['keystrokes']['stopListening'](_0x4ddbf4['element']);for(const _0x54b591 of Array['from'](_0x6e37c1['added'])['reverse']())this['focusTracker']['add'](_0x54b591['element']),this['keystrokes']['listenTo'](_0x54b591['element']);});}}function ns(_0x16812f,_0x408fad,_0x1f641d){let _0x32ccbb=0x0;for(const _0xe882bf of _0x16812f)switch(_0xe882bf){case'insert':_0x408fad['add'](_0x1f641d['get'](_0x32ccbb),_0x32ccbb),_0x32ccbb++;break;case'delete':_0x408fad['remove'](_0x32ccbb);break;case'equal':_0x32ccbb++;}}class oe extends kt{constructor(_0x479335){super(_0x479335);const _0x483e9a=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x483e9a['to']('contextValue',_0x42887a=>N(_0x479335,'THREAD_CONTEXT_LABEL',_0x42887a)),'tabindex':-0x1},'children':[{'text':_0x483e9a['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x391476,_0x44c6ad){super(_0x391476);const _0x5b5406=this['bindTemplate'];this['_model']=_0x44c6ad,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x44f1cb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x47d7f6({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x3ce96d=>!!_0x3ce96d),this['bind']('contextValue')['to'](this['_model'],'context',_0x44ac17=>_0x44ac17&&_0x44ac17['value']?this['_trimContextValue'](_0x44ac17['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',_0x5b5406['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 _0x2c0e7b=new _0xf18eca(this['locale']);return _0x2c0e7b['label']=N(this['locale'],'Reopen'),_0x2c0e7b['tooltip']=N(this['locale'],'Reopen'),_0x2c0e7b['icon']=_0x434316,_0x2c0e7b['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x185e4a=>!_0x185e4a),_0x2c0e7b['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x47d451,_0x26c2ff)=>_0x47d451&&_0x26c2ff),_0x2c0e7b['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x2c0e7b;}['_trimContextValue'](_0x8cd1b3){if(_0x8cd1b3['length']<0x96)return _0x8cd1b3;const _0x1b0cc3=_0x8cd1b3['lastIndexOf']('\x20',0x93);return _0x8cd1b3['substring'](0x0,_0x1b0cc3>-0x1?_0x1b0cc3:0x93)+'...';}['_attachContextActions'](){const _0x5e8802=this['element']['querySelector']('.ck-context'),_0x3cd566=_0x5e8802['querySelector']('.ck-context__value');this['listenTo'](_0x5e8802,'mouseenter',()=>{_0x3cd566['offsetWidth']<_0x3cd566['scrollWidth']&&_0x5e8802['classList']['add']('overlay');}),this['listenTo'](_0x5e8802,'mouseleave',()=>{_0x5e8802['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x4ba79e of this['focusables'])this['focusTracker']['add'](_0x4ba79e['element']),this['keystrokes']['listenTo'](_0x4ba79e['element']);}['_createContextView'](){const _0x2a56e7=new oe(this['locale']);return _0x2a56e7['bind']('contextValue')['to'](this),_0x2a56e7;}}class si extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x594838,_0x1ca75e,_0x491ca2,_0x3b391b){super(_0x594838),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x1ca75e,this['_localUser']=_0x491ca2,this['_config']=_0x3b391b,this['commentThreadHeaderView']=new Xt(_0x594838,_0x1ca75e),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x594838,N(_0x594838,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x594838,_0x1ca75e,Object['assign']({'CommentView':this['_config']['CommentView']},_0x3b391b)),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',(_0x223a97,_0x3ca68d)=>_0x223a97||!!_0x3ca68d),this['bind']('isUnlinked')['to'](_0x1ca75e,'unlinkedAt',_0x2dd11a=>!!_0x2dd11a),this['bind']('ariaLabel')['to'](this,'length',_0x16d884=>{const _0x463bff=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return N(this['locale'],'COMMENT_THREAD_LABEL',[_0x16d884,_0x463bff]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x44f1cb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x47d7f6({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x3d26fb=>_0x3d26fb['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 _0x15979b=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x593fae=_0x15979b['commentInputView'];return _0x15979b['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x593fae,'value',(_0x4f389c,_0x11bcbb,_0x10c5b9,_0x1f2950,_0x3500ad)=>!!_0x3500ad||!!_0x1f2950&&_0x10c5b9&&!_0x11bcbb||_0x4f389c&&_0x10c5b9&&!_0x11bcbb),_0x593fae['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x5050d4,_0x1229a8,_0x1c851a)=>{let _0x3083ee;return _0x3083ee=_0x1c851a&&_0x1229a8?'Reply\x20to\x20reopen\x20discussion...':_0x5050d4?'Reply...':'Write\x20a\x20comment...',N(this['locale'],_0x3083ee);}),_0x593fae['bind']('submitLabel')['to'](this,'length',_0x1e9698=>N(this['locale'],_0x1e9698?'Reply':'Comment')),_0x593fae['on']('submit',(_0x4fbf74,_0x248770)=>{this['fire']('addComment',_0x248770),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x593fae['on']('cancel',()=>{this['focus']();}),_0x593fae['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x593fae['on']('cancel',_0x1e5139=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x1e5139['stop']());}),this['on']('change:isActive',(_0xb5299d,_0x3e23cc,_0x3ae429)=>{_0x3ae429||this['length']||_0x593fae['value']||this['fire']('removeCommentThread');}),_0x15979b;}}class gt extends/* #__PURE__ -- @preserve */
27
+ ti(si){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x5806ca,_0xdc58f7,_0x369d8f,_0x1f6603){super(_0x5806ca,_0xdc58f7,_0x369d8f,_0x1f6603),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x5806ca,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x24d653,_0xb9eb,_0x246985)=>{_0x246985||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x10662a,_0x1e9f52,_0x1a9e2c)=>{_0x1a9e2c&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x47f203=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x47f203['if']('isActive','ck-thread--active'),_0x47f203['if']('isUnlinked','ck-thread--unlinked'),_0x47f203['to']('actionIndicator',_0x4e87fc=>_0x4e87fc?'ck-thread--'+_0x4e87fc:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x47f203['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 _0x503b48 of this['commentsListView']['commentViews'])_0x503b48['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x301a99}=this,_0x187cca=this['commentsListView']['commentViews']['get'](0x0);_0x187cca===this['_boundFirstCommentView']||_0x187cca['isSystemComment']||(this['_boundFirstCommentView']=_0x187cca,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x187cca,'actionIndicator',_0x2763f4=>'remove'===_0x2763f4?'remove':null),_0x187cca['placeholder']=N(_0x301a99,'Write\x20a\x20comment...'),_0x187cca['removeButton']['on']('execute',_0x134612=>{_0x134612['stop'](),this['showConfirm'](N(_0x301a99,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x187cca['focus']();}),_0x187cca['actionBar']['add'](this['resolveButton'],0x0),_0x187cca['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x25b894=new _0x75fe4c(this['locale']);return _0x25b894['label']=N(this['locale'],'Resolve'),_0x25b894['tooltip']=N(this['locale'],'Resolve'),_0x25b894['icon']=_0x611c86,_0x25b894['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x25b894['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x327dd1=>!_0x327dd1),_0x25b894['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x7a8f20,_0x3f4522)=>_0x7a8f20&&!_0x3f4522),_0x25b894['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x25b894;}['_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(_0x2b921e){super(_0x2b921e),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x581249,_0x53d3de,_0x31906f)=>{this['element']['innerHTML']=_0x31906f;}),this['element']['innerHTML']=this['content'];}}class di extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x35f761,_0x5b835e,_0x2c65e9){super(_0x35f761),this['_model']=_0x5b835e,this['_config']=_0x2c65e9,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x5b835e,'content',_0x5b835e,'authoredAt',(_0x11ede4,_0x392f17)=>N(_0x35f761,'COMMENT_ARIA_LABEL',[_0x5b835e['author']['name'],_0x2c65e9['formatDateTime'](_0x392f17),new DOMParser()['parseFromString'](_0x11ede4,'text/html')['body']['textContent'],_0x5b835e['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x35f761,N(_0x35f761,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x9ecf0b(),this['focusTracker']=new _0x44f1cb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x47d7f6({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x2e5ef7=>_0x2e5ef7['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 _0x18cb46=new is(this['locale']);return _0x18cb46['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x269409,_0x117cf8)=>_0x117cf8?ts(_0x269409,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x269409),_0x18cb46;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x1e3d95=new es(this['locale'],this['_config']['editorConfig']);return _0x1e3d95['value']=this['_model']['content'],_0x1e3d95['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x1e3d95['submitLabel']=N(this['locale'],'Save'),_0x1e3d95['on']('submit',(_0x45f0fb,_0x522779)=>{this['fire']('updateComment',this['_model']['id'],_0x522779),this['switchToDisplayMode'](),this['focus']();}),_0x1e3d95['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x1e3d95['once']('editorReady',()=>{_0x1e3d95['focus']();}),_0x1e3d95['createEditor'](),_0x1e3d95['delegate']('editorReady')['to'](this),_0x1e3d95['delegate']('editorDestroyed')['to'](this),_0x1e3d95;}['_setupKeyboardNavigation'](){const _0x45081d=this['element'];this['keystrokes']['listenTo'](_0x45081d);for(const _0x1a35c2 of this['focusables'])this['focusTracker']['add'](_0x1a35c2['element']),this['keystrokes']['listenTo'](_0x1a35c2['element']);this['focusables']['on']('change',(_0x29286d,_0x5a5f72)=>{for(const _0x1f8197 of _0x5a5f72['removed'])this['focusTracker']['remove'](_0x1f8197['element']),this['keystrokes']['stopListening'](_0x1f8197['element']);for(const _0x1a6b50 of _0x5a5f72['added'])this['focusTracker']['add'](_0x1a6b50['element']),this['keystrokes']['listenTo'](_0x1a6b50['element']);}),this['keystrokes']['set']('enter',(_0x413dc9,_0x30d8b8)=>{_0x45081d===_0x413dc9['target']&&(this['focusCycler']['focusFirst'](),_0x30d8b8());}),this['keystrokes']['set']('esc',(_0x22e3f6,_0x5caf63)=>{_0x45081d!==_0x22e3f6['target']&&(this['focus'](),_0x5caf63());});}}class Tt extends/* #__PURE__ -- @preserve */
28
+ ti(di){['actionBar'];['userView'];constructor(_0x2512ed,_0xf0d3f2,_0xd5527){super(_0x2512ed,_0xf0d3f2,_0xd5527),this['set']('actionIndicator',null),this['set']('placeholder',N(_0x2512ed,'Reply...')),this['bind']('authoredAt')['to'](_0xf0d3f2),this['bind']('resolvedAt')['to'](_0xf0d3f2),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 _0x5537f3(_0x2512ed,_0xf0d3f2['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0xf0d3f2,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x5a28b7=this['bindTemplate'],_0x33a52e=[{'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':_0x5a28b7['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x5a28b7['to']('authoredAt',_0x557cf8=>this['_config']['formatDateTime'](_0x557cf8))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x5a28b7['if']('isEditMode','ck-comment__actions--hidden'),_0x5a28b7['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']&&_0x33a52e['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper'],'tabindex':-0x1,'aria-label':_0x5a28b7['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x5a28b7['if']('isEditMode','ck-comment--edit'),_0x5a28b7['if']('isSystemComment','ck-comment--info'),_0x5a28b7['to']('actionIndicator',_0x3334f0=>_0x3334f0?'ck-comment--'+_0x3334f0:'')],'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':_0x33a52e}]}]};}['_createEditButton'](){const _0xa3aca4=new _0xf18eca(this['locale']);return _0xa3aca4['label']=N(this['locale'],'Edit'),_0xa3aca4['icon']=_0x2e1b6c,_0xa3aca4['withText']=!0x0,_0xa3aca4['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0xa3aca4['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x2d243f=>!_0x2d243f),_0xa3aca4['bind']('isVisible')['to'](this['_model'],'isEditable'),_0xa3aca4['on']('execute',()=>this['switchToEditMode']()),_0xa3aca4;}['_createRemoveButton'](){const _0x4e030c=new _0xf18eca(this['locale']);return _0x4e030c['label']=N(this['locale'],'Remove'),_0x4e030c['icon']=_0x3a1ba4,_0x4e030c['withText']=!0x0,_0x4e030c['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x4e030c['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3d05af=>!_0x3d05af),_0x4e030c['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x4e030c['on']('execute',()=>{this['showConfirm'](N(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x4e030c;}['_createDropdown'](){const _0x398724=_0x25965d(this['locale'],_0xa07f13),_0x4e68b1=_0x398724['panelView']['children'],_0x594936=new _0x9a55eb(this['locale']),_0x48d7a2=_0x398724['bindTemplate'];_0x569b97(_0x398724,()=>this['items']['find'](_0x233146=>_0x233146['isVisible'])),_0x398724['extendTemplate']({'attributes':{'class':[_0x48d7a2['if']('isVisible','ck-hidden',_0x3a00c0=>!_0x3a00c0)]}});const _0x47b9b4=(_0x1779a3,_0x594d22=-0x1)=>{const _0x16ff67=new _0x5629aa(this['locale']);_0x16ff67['children']['add'](_0x1779a3);const _0x55985b=_0x594d22>-0x1?_0x594d22:_0x594936['items']['length'];_0x594936['items']['add'](_0x16ff67,_0x55985b);const _0x1b8e35=Array['from'](this['items']);_0x398724['unbind']('isEnabled','isVisible'),_0x398724['bind']('isEnabled')['toMany'](_0x1b8e35,'isEnabled',(..._0x145c0c)=>_0x145c0c['some'](_0x451bcf=>_0x451bcf)),_0x398724['bind']('isVisible')['toMany'](_0x1b8e35,'isVisible',(..._0x343daa)=>_0x343daa['some'](_0x88d471=>_0x88d471));};_0x398724['panelPosition']='sw',_0x398724['buttonView']['set']({'label':N(this['locale'],'Show\x20more\x20items'),'icon':_0x437776});for(const _0x1fd6d9 of this['items'])_0x47b9b4(_0x1fd6d9);return _0x4e68b1['add'](_0x594936),_0x398724['listenTo'](this['items'],'add',(_0x15d954,_0xa128dc,_0x5c9d6b)=>{_0x47b9b4(_0xa128dc,_0x5c9d6b);}),_0x398724['listenTo'](this['items'],'remove',(_0x464aa6,_0x5b50ba,_0x2ec5fb)=>{_0x594936['items']['remove'](_0x2ec5fb);}),_0x398724;}['_attachActions'](_0x228e82,_0x588dd8){const _0x508f5f=_0x228e82&&_0x228e82['element'];_0x508f5f&&(this['listenTo'](_0x508f5f,'mouseenter',()=>this['actionIndicator']=_0x588dd8),this['listenTo'](_0x508f5f,'focus',()=>this['actionIndicator']=_0x588dd8),this['listenTo'](_0x508f5f,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x508f5f,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x2d86b9=super['_createCommentInputView']();return _0x2d86b9['bind']('placeholder')['to'](this),_0x2d86b9;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function xt(_0x9fc30e){const _0x1b20a8=Dt(_0x9fc30e,0x1e),_0x4a924e=new MutationObserver(_0x22be73=>{for(const _0x3fb948 of _0x22be73)('attributes'==_0x3fb948['type']&&'class'==_0x3fb948['attributeName']||'childList'==_0x3fb948['type']||'characterData'==_0x3fb948['type'])&&_0x1b20a8();});return{'attach'(_0x8f29b3){_0x4a924e['observe'](_0x8f29b3,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x4a924e['disconnect'](),_0x1b20a8['cancel']();}};}class E extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0xf5a7e5,_0x1c4c97){super(_0xf5a7e5),this['id']=_0x14661f(),this['focusTracker']=new _0x44f1cb(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0xabaa49,_0x39d11b)=>this['fire']('Esc',_0x39d11b)),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'](_0x1c4c97),this['mainView']=_0x1c4c97;const _0x1ec1e7=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x1ec1e7['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 _0x147798=this['element']['clientHeight'];_0x147798&&(this['height']=_0x147798);}}class T extends/* #__PURE__ -- @preserve */
29
+ _0xca3058(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x3a68d7,target:_0x2d96a0,type:_0x271538,isVisible:_0x668990=!0x0}){super(),this['view']=_0x3a68d7,this['view']['element']||this['view']['render'](),this['_type']=_0x271538,this['_target']=_0x2d96a0,T['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x4fc713([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x24a6e4,_0x56291b)=>{this['view']['focusTracker']['add'](_0x56291b);}),this['focusableElements']['on']('remove',(_0x312044,_0x2a9af9)=>{this['view']['focusTracker']['remove'](_0x2a9af9);}),this['set']('isVisible',_0x668990);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x2b285d=this['_getNormalizedTarget']();return T['_assertCorrectTarget'](_0x2b285d),_0x2b285d;}get['targetRect'](){const _0x2d36d5=this['target'];if(null===_0x2d36d5)return null;if(_0x2d36d5 instanceof _0x375970)return _0x2d36d5;const _0x21f0d9=_0x2d36d5['filter'](_0x430c12=>function(_0x1047ed){const _0x4657c5=_0x1047ed['offsetParent'];if(_0x4657c5)return!0x0;const _0x1a6000=_0x1047ed['getClientRects']()['item'](0x0);return!!_0x1a6000;}(_0x430c12));return 0x0===_0x21f0d9['length']?null:new _0x375970(_0x21f0d9[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x2e8a98){this['view']['isActive']=_0x2e8a98,this['view']['mainView']['isActive']=_0x2e8a98;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x32e085){if(!(null===_0x32e085||_0x32e085 instanceof _0x375970||Array['isArray'](_0x32e085)&&_0x32e085['every'](_0x520763=>fi(_0x520763))))throw new _0xd7b9fb('annotation-invalid-target',null,{'target':_0x32e085});}['_getNormalizedTarget'](){const _0x558d1c='function'==typeof this['_target']?this['_target']():this['_target'];return fi(_0x558d1c)?[_0x558d1c]:_0x558d1c;}}function fi(_0x12e54a){return null!==_0x12e54a&&'object'==typeof _0x12e54a&&'nodeType'in _0x12e54a&&0x1===_0x12e54a['nodeType'];}class S extends _0x4fc713{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x4c3e1b=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x44f1cb(),this['_focusTracker']['on']('change:isFocused',(_0x417558,_0xc0505e,_0x5b4c89)=>{_0x5b4c89||this['fire']('blur');});for(const _0x4fd90a of _0x4c3e1b)this['add'](_0x4fd90a);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0xe3a09){if(this['has'](_0xe3a09))throw new _0xd7b9fb('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0xe3a09['innerView'],_0xe3a09),this['_viewToAnnotation']['set'](_0xe3a09['view'],_0xe3a09);for(const _0x15a30b of _0xe3a09['focusableElements'])this['_focusTracker']['add'](_0x15a30b);this['listenTo'](_0xe3a09['focusableElements'],'add',(_0x52233a,_0x3e7348)=>{this['_focusTracker']['add'](_0x3e7348);}),this['listenTo'](_0xe3a09['focusableElements'],'remove',(_0x2eae83,_0x108faa)=>{this['_focusTracker']['remove'](_0x108faa);}),this['listenTo'](_0xe3a09['view']['focusTracker'],'change:isFocused',(_0x20d7a2,_0x4d7369,_0x49c15e)=>{_0x49c15e&&this['fire']('focus',_0xe3a09);}),_0xe3a09['updateTargetRect']();const _0x1b4ddc=this['_getOrderInContent'](_0xe3a09['view']['targetRect']);return super['add'](_0xe3a09,_0x1b4ddc);}['remove'](_0x22cbf4){if(!this['has'](_0x22cbf4))throw new _0xd7b9fb('annotationcollection-not-existing-item',null);this['stopListening'](_0x22cbf4['view']['focusTracker']),this['stopListening'](_0x22cbf4['focusableElements']);for(const _0x5c341e of _0x22cbf4['focusableElements'])this['_focusTracker']['remove'](_0x5c341e);return this['_viewToAnnotation']['delete'](_0x22cbf4['view']),this['_innerViewToAnnotation']['delete'](_0x22cbf4['innerView']),super['remove'](_0x22cbf4);}['getByInnerView'](_0x9e8dba){return this['_innerViewToAnnotation']['get'](_0x9e8dba);}['getByView'](_0x518a3c){return this['_viewToAnnotation']['get'](_0x518a3c);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x445f48 of this)_0x445f48['updateTargetRect']();this['_sort']();}['_sort'](){const _0xaf43e6=Array['from'](this)['sort']((_0x390b29,_0xe3f556)=>w(_0x390b29['view']['targetRect'],_0xe3f556['view']['targetRect']));for(let _0x1cd7d5=_0xaf43e6['length']-0x1;_0x1cd7d5>0x0;_0x1cd7d5--){const _0x35bad3=_0xaf43e6[_0x1cd7d5];_0x1cd7d5!==this['getIndex'](_0x35bad3)&&(this['remove'](_0x35bad3),this['add'](_0x35bad3));}}['_getOrderInContent'](_0x427e7d){let _0x4d2dc7=0x0;if(!_0x427e7d)return this['length'];for(const _0x41b00a of this){const _0x4b9111=_0x41b00a['view']['targetRect'];if(_0x4b9111){if(w(_0x427e7d,_0x4b9111)<0x0)return _0x4d2dc7;_0x4d2dc7++;}}return _0x4d2dc7;}}function v({source:_0x4578ae,target:_0x1f1378,filter:_0x5ad2b2}){for(const _0x13ba31 of _0x4578ae)_0x5ad2b2(_0x13ba31)&&_0x1f1378['add'](_0x13ba31);_0x1f1378['listenTo'](_0x4578ae,'add',(_0x460981,_0x589c14)=>{_0x5ad2b2(_0x589c14)&&_0x1f1378['add'](_0x589c14);}),_0x1f1378['listenTo'](_0x4578ae,'remove',(_0x52c4b6,_0x4169cf)=>{_0x1f1378['has'](_0x4169cf)&&_0x1f1378['remove'](_0x4169cf);});}function w(_0x2332ef,_0x4c1580){if(null===_0x2332ef&&null===_0x4c1580)return 0x0;if(null===_0x2332ef)return-0x1;if(null===_0x4c1580)return 0x1;const _0x1f3c9c=_0x2332ef['top']-_0x4c1580['top'];return 0x0==_0x1f3c9c?_0x2332ef['left']-_0x4c1580['left']:_0x1f3c9c;}class y extends _0x3110a5{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5490c3){if(super(_0x5490c3),this['collection']=new S(),this['_visibleAnnotations']=new S(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x5490c3 instanceof _0x22a44e){const _0x1de3c6=_0x5490c3['locale'];_0x5490c3['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':N(_0x1de3c6,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x8475bf){this['collection']['add'](_0x8475bf);}['remove'](_0x383638){this['collection']['remove'](_0x383638),_0x383638['destroy']();}['refreshVisibility'](){for(const _0x5df636 of this['collection'])_0x5df636['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x45b1b4){return this['collection']['getByInnerView'](_0x45b1b4);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x8c3fe of this['collection'])_0x8c3fe['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x4edbd9){this['fire']('_activateAnnotation',_0x4edbd9);}['createAnnotation'](_0x1b6fb3){return new T(_0x1b6fb3);}['createAnnotationView'](_0x11bb2d,_0x519322){return new E(_0x11bb2d,_0x519322);}['_addActiveAnnotation'](_0x21b802){const _0x5eab76=new Set(this['activeAnnotations']);_0x5eab76['add'](_0x21b802),this['activeAnnotations']=_0x5eab76;}['_removeActiveAnnotation'](_0x2b43a5){const _0x9b0c71=new Set(this['activeAnnotations']);_0x9b0c71['delete'](_0x2b43a5),this['activeAnnotations']=_0x9b0c71;}['_bindAnnotationsToVisibleAnnotations'](){const _0x35ac78=this['collection'],_0x55f9f9=this['_visibleAnnotations'];function _0x13a2ab(_0x554c34){const _0x15ad91=_0x554c34['source'];_0x15ad91['isVisible']&&!_0x55f9f9['has'](_0x15ad91)?_0x55f9f9['add'](_0x15ad91):!_0x15ad91['isVisible']&&_0x55f9f9['has'](_0x15ad91)&&_0x55f9f9['remove'](_0x15ad91),_0x15ad91['view']['focusTracker']['remove'](_0x15ad91['view']['element']),_0x15ad91['view']['focusTracker']['add'](_0x15ad91['view']['element']);}this['listenTo'](_0x35ac78,'add',(_0xac99cb,_0x58db64)=>{_0x58db64['isVisible']&&_0x55f9f9['add'](_0x58db64),this['listenTo'](_0x58db64,'change:isVisible',_0x13a2ab);}),this['listenTo'](_0x35ac78,'remove',(_0x1e38ba,_0x496f13)=>{_0x55f9f9['has'](_0x496f13)&&_0x55f9f9['remove'](_0x496f13),this['stopListening'](_0x496f13,'change:isVisible',_0x13a2ab);});}['_setupEnterAnnotationKeystroke'](){const _0x2e9759=_0x3e3635=>{_0x3e3635['on']('ready',()=>{_0x3e3635['keystrokes']['set'](_0xa0140e,(_0x26c7a7,_0x269293)=>{const _0x436bab=_0xa3ef79(this['activeAnnotations']['values']());_0x436bab&&(_0x436bab['view']['focus'](),_0x269293());});});};this['context']instanceof _0x22a44e?_0x2e9759(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x57448f,_0x4de36b)=>{_0x2e9759(_0x4de36b);});}['_setupEscapeAnnotationHandling'](){const _0x1f7a31=_0x22a04c=>{const _0x48bdfc=_0x22a04c['source'],_0x25368a=[];let _0x18dc3e;if(Array['isArray'](_0x48bdfc['target'])){_0x18dc3e=_0x48bdfc['target'][0x0],this['context']instanceof _0x22a44e?_0x25368a['push'](this['context']):this['context']['editors']&&_0x25368a['push'](...this['context']['editors']);for(const _0x360554 of _0x25368a)for(const _0x343065 of _0x360554['editing']['view']['domRoots']['values']())if(_0x343065['contains'](_0x18dc3e))return void _0x360554['editing']['view']['focus']();_0x18dc3e['focus']();}};this['listenTo'](this['collection'],'add',(_0xe3f4c8,_0x15ca55)=>{this['listenTo'](_0x15ca55,'escape',_0x1f7a31,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x2f1749,_0x5a2081)=>{this['stopListening'](_0x5a2081,'escape',_0x1f7a31);});}}const _t=Symbol('noChannel'),bt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x3110a5{['_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(_0x5c5075){super(_0x5c5075),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x380dd4=this['context']['config'];_0x380dd4['define']('comments.maxCommentsWhenCollapsed',0x2),_0x380dd4['define']('comments.maxThreadTotalWeight',0x1f4),_0x380dd4['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x380dd4['define']('comments.CommentThreadView',gt),_0x380dd4['define']('comments.CommentView',Tt),_0x380dd4['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x3fca60=this['context']['plugins']['get'](y);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x7d0b76,_0x56dda8)=>this['_addCommentThread'](_0x56dda8)),this['on']('submitCommentThread',(_0x2ce513,_0xf0503a)=>this['_submitCommentThread'](_0xf0503a)),this['on']('resolveCommentThread',(_0x130d8d,_0x2f90d4)=>this['_resolveCommentThread'](_0x2f90d4)),this['on']('resolveCommentThread',(_0x4abc78,_0x54087a)=>this['_updateActiveAnnotation'](_0x54087a),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x32d7e7,_0x508374)=>this['_reopenCommentThread'](_0x508374)),this['on']('reopenCommentThread',(_0x3c14ad,_0x43fb1c)=>this['_updateActiveAnnotation'](_0x43fb1c),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x4c14fc,_0x3f1fca)=>this['_removeCommentThread'](_0x3f1fca)),this['on']('updateCommentThread',(_0x179817,_0x1a21e2)=>this['_updateCommentThread'](_0x1a21e2)),this['on']('updateCommentThread',(_0x1f68bc,_0x28f8f8)=>this['_updateActiveAnnotation'](_0x28f8f8),{'priority':'lowest'}),this['on']('addComment',(_0x4c2848,_0x5df7cd)=>this['_addComment'](_0x5df7cd)),this['on']('updateComment',(_0x2f3971,_0x505c8f)=>this['_updateComment'](_0x505c8f)),this['on']('removeComment',(_0x10c440,_0x3e9074)=>this['_removeComment'](_0x3e9074)),this['on']('addComment',(_0x1aad30,{threadId:_0xcc3b83,isFromAdapter:_0x595d9c})=>{if(_0x595d9c)return;const _0x5075f4=this['getCommentThread'](_0xcc3b83),_0x4d8de1=_0x5075f4&&this['_threadToController']['get'](_0x5075f4);_0x4d8de1&&_0x4d8de1['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x3fca60,'change:activeAnnotations',(_0x33e116,_0x8b7c4e,_0x2d7337)=>{const _0x544ef=Array['from'](_0x2d7337)['map'](_0x592442=>this['_viewToController']['get'](_0x592442['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x544ef?_0x544ef['model']:null;});}set['adapter'](_0x43b90b){if(this['_adapter'])throw new _0xd7b9fb('commentsrepository-adapter-already-set');this['_adapter']=_0x43b90b;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0xc82883=_t,threadId:_0x31339b=_0x14661f(),comments:_0x440987=[],unlinkedAt:_0x45eaf4=null,resolvedAt:_0x2ab819=null,resolvedBy:_0x3d167c=null,target:_0xd1d8bf=null,context:_0x1fb57d=null,attributes:_0x44466c={},isResolvable:_0x1f9c5d=!0x0,isSubmitted:_0x3f781f=!0x1,isFromAdapter:_0x1b62fe=!0x1}={}){return this['fire'](Nt('addCommentThread',_0xc82883),{'channelId':_0xc82883,'threadId':_0x31339b,'comments':_0x440987,'unlinkedAt':_0x45eaf4,'resolvedAt':_0x2ab819,'resolvedBy':_0x3d167c,'target':_0xd1d8bf,'context':_0x1fb57d,'attributes':_0x44466c,'isFromAdapter':_0x1b62fe,'isResolvable':_0x1f9c5d,'isSubmitted':_0x3f781f}),this['getCommentThread'](_0x31339b);}['openNewCommentThread']({channelId:_0x333219=_t,threadId:_0x1960f3=_0x14661f(),target:_0x1369bc,context:_0xd39023=null,isResolvable:_0xa52bd6=!0x0}){if(this['_readOnlyChannels']['has'](_0x333219)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x1369bc)throw new _0xd7b9fb('commentsrepository-missing-target');const _0x3cb9f5=this['addCommentThread']({'channelId':_0x333219,'threadId':_0x1960f3,'target':_0x1369bc,'context':_0xd39023,'isResolvable':_0xa52bd6});if(!_0x3cb9f5)return null;const _0x178394=this['_threadToController']['get'](_0x3cb9f5),_0x20e070=_0x178394['view']['commentThreadInputView']['commentInputView'],_0x572860=this['context']['plugins']['get'](y),_0xec432d=_0x572860['getByInnerView'](_0x178394['view']);return _0x572860['activate'](_0xec432d),_0x20e070['once']('editorReady',()=>_0x20e070['focus']()),_0x3cb9f5;}['hasCommentThread'](_0x5c9344){if('string'!=typeof _0x5c9344)throw new _0xd7b9fb('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x5c9344);}['updateCommentThread']({channelId:_0x18a834=_t,threadId:_0x1e77a0,context:_0x1818e7,unlinkedAt:_0xafdb92,attributes:_0x2e4f04,isFromAdapter:_0x170d6c=!0x1}){return this['fire'](Nt('updateCommentThread',_0x18a834),{'channelId':_0x18a834,'threadId':_0x1e77a0,'context':_0x1818e7,'unlinkedAt':_0xafdb92,'attributes':_0x2e4f04,'isFromAdapter':_0x170d6c}),this['getCommentThread'](_0x1e77a0);}['getCommentThread'](_0x269710){if('string'!=typeof _0x269710)throw new _0xd7b9fb('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x269710);}['fetchCommentThread']({channelId:_0x18af39,threadId:_0x395e90}={}){const _0x47ddd9=this['getCommentThread'](_0x395e90);if(_0x47ddd9)return Promise['resolve'](_0x47ddd9);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0xd7b9fb('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x18af39,'threadId':_0x395e90})['then'](_0x3c054e=>this['hasCommentThread'](_0x395e90)?this['getCommentThread'](_0x395e90):_0x3c054e?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x18af39},_0x3c054e)):void 0x0)['catch'](_0x3c00f0=>{throw console['error'](_0x3c00f0),new _0xd7b9fb('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x1d6211,skipNotAttached:_0x5db6fb=!0x1,skipEmpty:_0x23fdd1=!0x1,toJSON:_0x148b36=!0x1}={}){const _0x30b0df=[];for(const _0x3e2e61 of this['_threads']['values']())_0x1d6211&&_0x3e2e61['channelId']!==_0x1d6211||_0x5db6fb&&!_0x3e2e61['isAttached']||_0x23fdd1&&0x0===_0x3e2e61['length']||_0x30b0df['push'](_0x3e2e61);return _0x148b36?_0x30b0df['map'](_0x2aa469=>_0x2aa469['toJSON']()):_0x30b0df;}['getAnnotationForCommentThread'](_0x4657ff){const _0x5a85be=this['_threadToController']['get'](_0x4657ff);if(!_0x5a85be)return null;return this['context']['plugins']['get'](y)['getByInnerView'](_0x5a85be['view'])||null;}['getCommentThreadForAnnotation'](_0x23430e){const _0x572afb=this['_viewToController']['get'](_0x23430e['innerView']);return _0x572afb?_0x572afb['model']:null;}['setActiveCommentThread'](_0x14b56d){const _0x2a591c=this['context']['plugins']['get'](y);if(!_0x14b56d)return void(this['activeCommentThread']&&_0x2a591c['deactivateAll']());const _0x3d86de=this['getCommentThread'](_0x14b56d);if(!_0x3d86de)throw new _0xd7b9fb('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x14b56d});if(!this['_threadToController']['has'](_0x3d86de))throw new _0xd7b9fb('commentsrepository-active-not-attached',null,{'threadId':_0x14b56d});const _0x420411=_0x2a591c['getByInnerView'](this['_threadToController']['get'](_0x3d86de)['view']);_0x2a591c['activate'](_0x420411);}['switchReadOnly'](_0x17d4ca,_0x407baf){_0x17d4ca?this['_readOnlyChannels']['add'](_0x407baf):this['_readOnlyChannels']['delete'](_0x407baf),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x3b30f0){return this['_readOnlyChannels']['has'](_0x3b30f0)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x3a8a06,_0x3fbb62){return new vt(_0x3a8a06,_0x3fbb62);}['setPermissions'](_0x281072,_0x3d0b89=_t){this['_permissions']['set'](_0x3d0b89,_0x281072),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x1cfeef=_t){return this['_permissions']['has'](_0x1cfeef)?this['_permissions']['get'](_0x1cfeef):bt;}['_addCommentThread']({channelId:_0x51db38,threadId:_0x3d4cff,comments:_0x2f2be7,unlinkedAt:_0x446636,resolvedAt:_0xaf5b48,resolvedBy:_0xf5f1b7,target:_0x34a51e,context:_0x26bee2,attributes:_0x274431,isFromAdapter:_0x17ce30,isResolvable:_0x3c2c48,isSubmitted:_0x4ff762}){if('string'!=typeof _0x3d4cff)throw new _0xd7b9fb('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x3d4cff});if(this['hasCommentThread'](_0x3d4cff))throw new _0xd7b9fb('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x3d4cff});const _0x48efc2=new pi(this,{'channelId':_0x51db38,'id':_0x3d4cff,'context':_0x26bee2,'attributes':_0x274431,'unlinkedAt':_0x446636,'resolvedAt':_0xaf5b48,'resolvedBy':_0xf5f1b7?this['context']['plugins']['get'](it)['getUser'](_0xf5f1b7):null,'isResolvable':_0x3c2c48,'isSubmitted':_0x4ff762||_0x17ce30});this['_threads']['set'](_0x3d4cff,_0x48efc2);for(const _0x3c25d9 of _0x2f2be7)_0x48efc2['_add'](this['_createNewComment']({'threadId':_0x3d4cff,..._0x3c25d9}));return _0x34a51e&&_0x48efc2['attachTo'](_0x34a51e),_0x17ce30||!_0x48efc2['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x51db38,'threadId':_0x3d4cff});}['_submitCommentThread']({channelId:_0x22220a,threadId:_0x481c6a}){if(!this['hasCommentThread'](_0x481c6a))throw new _0xd7b9fb('commentsrepository-missing-comment-thread',this);const _0x29b913=this['getCommentThread'](_0x481c6a);if(_0x29b913['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x57d1c3,comments:_0x3e8f12,resolvedAt:_0x5d592d,resolvedBy:_0xf41a64,context:_0x4790a9,attributes:_0x5b058f}=_0x29b913,_0xb32cdb=this['context']['plugins']['get']('PendingActions'),_0x11aa22=_0xb32cdb['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x22220a,'threadId':_0x57d1c3,'comments':_0x3e8f12['map'](_0x3e11da=>_0x3e11da['toJSON']()),'resolvedAt':_0x5d592d,'resolvedBy':_0xf41a64?_0xf41a64['id']:_0xf41a64,'context':_0x4790a9,'attributes':_0x5b058f})['then'](({comments:_0x3ca940})=>{_0xb32cdb['remove'](_0x11aa22);for(const _0x4fcd50 of _0x3ca940)this['_updateComment']({'channelId':_0x22220a,'threadId':_0x481c6a,'commentId':_0x4fcd50['commentId'],'createdAt':_0x4fcd50['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x5a91a1=>{throw console['error'](_0x5a91a1),new _0xd7b9fb('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x4552ae,target:_0x4f6755}){const _0x226672=this['getCommentThread'](_0x4552ae);if(!_0x226672)throw new _0xd7b9fb('commentsrepository-attach-missing-comment-thread',this);const _0x1c4664=this['context']['plugins']['get']('PendingActions'),_0x2ff926=this['context']['plugins']['get'](y),_0x4cd734=this['_createCommentThreadView'](_0x226672),_0x36ddce=new vt(_0x226672,_0x4cd734);let _0x4973cb=null;_0x4cd734['on']('change:isDirty',(_0x4d8414,_0x43ec91,_0x28c97b)=>{_0x28c97b?_0x4973cb=_0x1c4664['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x4973cb&&(_0x1c4664['remove'](_0x4973cb),_0x4973cb=null);}),this['_threadToController']['set'](_0x226672,_0x36ddce),this['_viewToController']['set'](_0x4cd734,_0x36ddce);const _0x424571=new E(this['context']['locale'],_0x4cd734);_0x424571['bind']('length')['to'](_0x4cd734),_0x424571['bind']('isDirty')['to'](_0x4cd734,'isDirty',_0x4cd734,'length',(_0x2c16f7,_0x18bd7c)=>_0x2c16f7||!_0x18bd7c),_0x424571['bind']('isActive')['to'](_0x4cd734),_0x424571['type']='comment';const _0x52e8f4=new T({'view':_0x424571,'target':_0x4f6755,'type':'comment','isVisible':!_0x226672['archivedAt']&&!!('function'==typeof _0x4f6755?_0x4f6755():_0x4f6755)});return _0x4cd734['on']('escape',()=>{_0x52e8f4['fire']('escape');}),this['_bindAnnotationToEditors'](_0x4cd734,_0x52e8f4),_0x2ff926['add'](_0x52e8f4),_0x52e8f4;}['_bindAnnotationToEditors'](_0x265da8,_0x51569f){this['listenTo'](_0x265da8,'editorReady',(_0x56c3ed,_0x1c2e68)=>{const _0x38bab8=_0x1c2e68['ui']['view']['body']['bodyCollectionContainer'];_0x51569f['focusableElements']['add'](_0x38bab8),this['context']instanceof _0x22a44e&&this['context']['ui']['focusTracker']['add'](_0x38bab8);},{'priority':'highest'}),this['listenTo'](_0x265da8,'editorDestroyed',(_0x50f47d,_0x454d85)=>{const _0x226cbf=_0x454d85['ui']['view']['body']['bodyCollectionContainer'];_0x51569f['focusableElements']['has'](_0x226cbf)&&_0x51569f['focusableElements']['remove'](_0x226cbf),this['context']instanceof _0x22a44e&&this['context']['ui']['focusTracker']['remove'](_0x226cbf);});}['_unbindEditors'](_0x5124ca){this['stopListening'](_0x5124ca,'editorReady'),this['stopListening'](_0x5124ca,'editorDestroyed');}['_createCommentThreadView'](_0x230e0c){const _0x382140=this['context']['plugins']['get'](it),{config:_0x3e63d9,locale:_0x31ddef}=this['context'],_0x3a49f7=pt(_0x3e63d9['get']('locale'),_0x31ddef);return new(0x0,(_0x3e63d9['get']('comments'))['CommentThreadView'])(_0x31ddef,_0x230e0c,_0x382140['me'],{'editorConfig':{..._0x3e63d9['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x3e63d9['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x3e63d9['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x3e63d9['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x3e63d9['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x3a49f7,'CommentView':_0x3e63d9['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x5dffd7,channelId:_0x52b4f6,resolvedAt:_0x5d5848,resolvedBy:_0x43f165,isFromAdapter:_0x523a03}){if(!this['hasCommentThread'](_0x5dffd7))throw new _0xd7b9fb('commentsrepository-missing-comment-thread',null,{'threadId':_0x5dffd7});const _0x3b0edb=this['getCommentThread'](_0x5dffd7);if(_0x3b0edb['isResolved'])throw new _0xd7b9fb('commentsrepository-resolved-comment-thread',null,{'threadId':_0x5dffd7});const _0x55217c=this['context']['plugins']['get'](it);if(_0x3b0edb['resolvedBy']=_0x55217c['getUser'](_0x43f165),_0x3b0edb['resolvedAt']=_0x5d5848,_0x523a03||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x3d3a55=this['context']['plugins']['get']('PendingActions'),_0x5ebd17=_0x3d3a55['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x52b4f6,'threadId':_0x5dffd7})['then'](({resolvedAt:_0x230e9e,resolvedBy:_0x3f387c})=>{_0x3d3a55['remove'](_0x5ebd17),_0x3b0edb['resolvedBy']['id']!==_0x3f387c&&(_0x3b0edb['resolvedBy']=_0x55217c['getUser'](_0x3f387c)),_0x3b0edb['resolvedAt']=_0x230e9e;})['catch'](_0xc19179=>{throw console['error'](_0xc19179),new _0xd7b9fb('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x5c69f2,channelId:_0x37f877,isFromAdapter:_0x4a720c}){if(!this['hasCommentThread'](_0x5c69f2))throw new _0xd7b9fb('commentsrepository-missing-comment-thread',null,{'threadId':_0x5c69f2});const _0x176ef9=this['getCommentThread'](_0x5c69f2);if(!_0x176ef9['isResolved'])throw new _0xd7b9fb('commentsrepository-reopen-comment-thread',null,{'threadId':_0x5c69f2});if(_0x176ef9['resolvedBy']=null,_0x176ef9['resolvedAt']=null,_0x4a720c||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x30d07e=this['context']['plugins']['get']('PendingActions'),_0x1c54e4=_0x30d07e['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x37f877,'threadId':_0x5c69f2})['then'](()=>_0x30d07e['remove'](_0x1c54e4))['catch'](_0x8e8f59=>{throw console['error'](_0x8e8f59),new _0xd7b9fb('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x2ad614,isFromAdapter:_0x43b5ac}){const _0x16ba63=this['getCommentThread'](_0x2ad614);if(!_0x16ba63)throw new _0xd7b9fb('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x2ad614),this['_threads']['delete'](_0x2ad614),!_0x16ba63['isSubmitted']||_0x43b5ac||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x127320=this['context']['plugins']['get']('PendingActions'),{channelId:_0x522ce8}=_0x16ba63,_0x6d50ed=_0x127320['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x522ce8,'threadId':_0x2ad614})['then'](()=>_0x127320['remove'](_0x6d50ed))['catch'](_0x531f5c=>{throw console['error'](_0x531f5c),new _0xd7b9fb('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x3c02a2,unlinkedAt:_0x57c8ba,context:_0x2fda28,attributes:_0x27c3f2,isFromAdapter:_0x570118}){if('string'!=typeof _0x3c02a2)throw new _0xd7b9fb('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x3c02a2});if(!this['hasCommentThread'](_0x3c02a2))throw new _0xd7b9fb('commentsrepository-missing-comment-thread',null,{'threadId':_0x3c02a2});const _0x1398ff=this['getCommentThread'](_0x3c02a2);let _0x394b02=!0x1;if(void 0x0!==_0x2fda28&&_0x1398ff['context']!==_0x2fda28&&(_0x1398ff['context']=_0x2fda28,_0x394b02=!0x0),void 0x0!==_0x57c8ba&&_0x1398ff['unlinkedAt']!==_0x57c8ba&&(_0x1398ff['unlinkedAt']=_0x57c8ba,_0x394b02=!0x0),_0x27c3f2&&!At(_0x27c3f2,_0x1398ff['attributes'])&&(_0x1398ff['attributes']=_0x27c3f2,_0x394b02=!0x0),!_0x394b02)return Promise['resolve']();if(!_0x1398ff['isSubmitted']||_0x570118||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0xc6b000=this['context']['plugins']['get']('PendingActions'),{channelId:_0x2a864a}=_0x1398ff,_0x40f573=_0xc6b000['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x2a864a,'threadId':_0x3c02a2,'context':_0x2fda28,'unlinkedAt':_0x57c8ba,'attributes':_0x27c3f2})['then'](()=>_0xc6b000['remove'](_0x40f573))['catch'](_0x311ef1=>{throw console['error'](_0x311ef1),new _0xd7b9fb('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x5ba991){const _0xf9367d=this['context']['plugins']['get'](y),_0x441799=this['getCommentThread'](_0x5ba991);if(_0x441799['_isAttached']=!0x1,this['_threadToController']['has'](_0x441799)){const _0x4c5602=this['_threadToController']['get'](_0x441799),_0x185ba9=_0x4c5602['view'],_0x1a9514=_0xf9367d['getByInnerView'](_0x185ba9);this['_threadToController']['delete'](_0x441799),this['_viewToController']['delete'](_0x185ba9),_0x1a9514&&_0xf9367d['remove'](_0x1a9514),_0x4c5602['destroy'](),_0x185ba9['destroy']()['then'](()=>{this['_unbindEditors'](_0x185ba9);});}}['_updateActiveAnnotation']({threadId:_0x1fe507,resolvedAt:_0x1d2505,unlinkedAt:_0x446b53}){const _0x2a1e10=!!_0x1d2505,_0x1250eb=this['context']['plugins']['get'](y),_0x37384c=this['getCommentThread'](_0x1fe507);if(this['_threadToController']['has'](_0x37384c)){const _0x288c74=this['_threadToController']['get'](_0x37384c)['view'],_0x217a74=_0x1250eb['getByInnerView'](_0x288c74);_0x217a74&&(_0x2a1e10&&_0x1250eb['_removeActiveAnnotation'](_0x217a74),_0x446b53?_0x217a74['isVisible']=!0x1:_0x217a74['refreshVisibility']());}}['_getExternalAuthor'](_0x5b654e){const _0x3b8ce2=this['context']['plugins']['get'](it),_0xe8796d=It('external:'+_0x5b654e),_0x5b8edf=_0x3b8ce2['getUser'](_0xe8796d);return _0x5b8edf||_0x3b8ce2['addUser']({'id':_0xe8796d,'name':_0x5b654e});}['_createNewComment']({threadId:_0x27d994,commentId:_0x2d2c37=_0x14661f(),content:_0x23c5b9,authorId:_0xb5b6b8,createdAt:_0x3d5bea,attributes:_0x1d8dfa}){if('string'!=typeof _0x2d2c37)throw new _0xd7b9fb('commentsrepository-invalid-commentid');if('string'!=typeof _0xb5b6b8)throw new _0xd7b9fb('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x23c5b9||!_0x23c5b9['trim']())throw new _0xd7b9fb('commentsrepository-invalid-comment-content');const _0x54bae5=this['context']['plugins']['get'](it)['getUser'](_0xb5b6b8);if(!_0x54bae5)throw new _0xd7b9fb('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0xb5b6b8});let _0x1a45ac=null,_0x4172df=_0x3d5bea;return _0x1d8dfa?.['@external']&&(_0x1a45ac=this['_getExternalAuthor'](_0x1d8dfa['@external']['authorName']),_0x4172df=new Date(_0x1d8dfa['@external']['createdAt'])),new wi(this,{'threadId':_0x27d994,'id':_0x2d2c37,'author':_0x1a45ac||_0x54bae5,'creator':_0x54bae5,'content':_0x23c5b9,'createdAt':_0x3d5bea,'authoredAt':_0x4172df,'attributes':_0x1d8dfa});}['_addComment'](_0x49fe0f){let {threadId:_0x3c256e,content:_0x26ccdc,attributes:_0x429fdd,isFromAdapter:_0x2618de}=_0x49fe0f;const _0x2cc654=this['getCommentThread'](_0x49fe0f['threadId']);if(!_0x2cc654)throw new _0xd7b9fb('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x50af6c=this['_createNewComment'](_0x49fe0f),{id:_0x1bcf7a}=_0x50af6c;if(_0x2cc654['_add'](_0x50af6c),_0x2618de||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x2cc654['isSubmitted'])return Promise['resolve']();const _0x245518=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3dc6b5}=_0x2cc654,_0x2f6b39=_0x245518['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x429fdd||(_0x429fdd={}),this['adapter']['addComment']({'channelId':_0x3dc6b5,'threadId':_0x3c256e,'commentId':_0x1bcf7a,'content':_0x26ccdc,'attributes':_0x429fdd})['then'](_0x282803=>{_0x245518['remove'](_0x2f6b39),_0x282803&&this['_updateComment']({'channelId':_0x3dc6b5,'threadId':_0x3c256e,'commentId':_0x1bcf7a,'createdAt':_0x282803['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x1ca638=>{throw console['error'](_0x1ca638),new _0xd7b9fb('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x309e95,commentId:_0x49c0b9,content:_0x547448,createdAt:_0x29aa0f,attributes:_0x22036b,isFromAdapter:_0x365039}){if(void 0x0!==_0x547448&&('string'!=typeof _0x547448||!_0x547448['trim']()['length']))throw new _0xd7b9fb('commentsrepository-update-comment-invalid-content');const _0xb2c25=this['getCommentThread'](_0x309e95),_0x49cf9b=_0xb2c25['getComment'](_0x49c0b9);if(!_0x49cf9b)throw new _0xd7b9fb('commentsrepository-update-missing-comment',this);let _0x36b482=!0x1;if(_0x547448&&_0x547448!==_0x49cf9b['content']&&(_0x49cf9b['isEditable']||_0x365039)&&(_0x49cf9b['content']=_0x547448,_0x36b482=!0x0),_0x29aa0f&&_0x29aa0f!==_0x49cf9b['createdAt']&&(_0x49cf9b['createdAt']=_0x29aa0f,_0x49cf9b['attributes']&&_0x49cf9b['attributes']['@external']||(_0x49cf9b['authoredAt']=_0x29aa0f),_0x36b482=!0x0),_0x22036b&&!At(_0x22036b,_0x49cf9b['attributes'])&&(_0x49cf9b['attributes']=_0x22036b,_0x36b482=!0x0),!_0x36b482)return Promise['resolve']();if(_0xb2c25['fire']('commentUpdated'),_0x365039||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x5610e8=this['context']['plugins']['get']('PendingActions'),{channelId:_0xed5f6f}=this['getCommentThread'](_0x49cf9b['threadId']),_0x32d628=_0x5610e8['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0xed5f6f,'threadId':_0x309e95,'commentId':_0x49c0b9,'content':_0x547448,'attributes':_0x22036b})['then'](()=>_0x5610e8['remove'](_0x32d628))['catch'](_0x552050=>{throw console['error'](_0x552050),new _0xd7b9fb('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x26578d,commentId:_0x28dfac,isFromAdapter:_0x21d9f7}){const _0x350802=this['getCommentThread'](_0x26578d),_0x18273f=_0x350802['getComment'](_0x28dfac);if(!_0x18273f)throw new _0xd7b9fb('commentsrepository-remove-missing-comment',this);if(_0x350802['_remove'](_0x18273f),_0x21d9f7||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x1b50fc=this['context']['plugins']['get']('PendingActions'),{channelId:_0x30b166}=_0x350802,_0x1b7505=_0x1b50fc['add'](N(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x30b166,'threadId':_0x26578d,'commentId':_0x28dfac})['then'](()=>_0x1b50fc['remove'](_0x1b7505))['catch'](_0x6ed77d=>{throw console['error'](_0x6ed77d),new _0xd7b9fb('commentsrepository-remove-comment-internal-error',this);});}}class pi extends/* #__PURE__ -- @preserve */
30
+ _0xca3058(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x11b3cb,_0x4060db){super();const _0x3b2f18=_0x4060db['isResolvable'];this['channelId']=_0x4060db['channelId'],this['id']=_0x4060db['id'],this['comments']=new _0x4fc713(),this['_repository']=_0x11b3cb,this['_isAttached']=!0x1,this['_isSubmitted']=_0x4060db['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x11b3cb,'_permissions',_0x11b3cb,'_readOnlyChannels',()=>_0x11b3cb['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x11b3cb,'_permissions',()=>_0x11b3cb['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x11b3cb,'_permissions',()=>{const _0x45f52d=_0x11b3cb['getPermissions'](this['channelId']);return _0x45f52d['write']||_0x45f52d['admin'];}),this['bind']('isResolvable')['to'](_0x11b3cb,'_permissions',()=>_0x3b2f18&&_0x11b3cb['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x4060db['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x126cec,_0x22fc73)=>_0x126cec?_0x22fc73?_0x126cec<_0x22fc73?_0x126cec:_0x22fc73:_0x126cec:_0x22fc73),this['set']('unlinkedAt',_0x4060db['unlinkedAt']||null),this['set']('resolvedAt',_0x4060db['resolvedAt']||null),this['set']('resolvedBy',_0x4060db['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x548e5d=>!!_0x548e5d),this['set']('attributes',_0x4060db['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x209c8e,_0x37127f)=>_0x209c8e+_0x37127f['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x407bc1,id:_0x43668a}=this;this['_repository']['fire'](Nt('submitCommentThread',_0x407bc1),{'channelId':_0x407bc1,'threadId':_0x43668a});}['setUnlinkedAt'](_0x2e5bd9){this['_update']({'unlinkedAt':_0x2e5bd9});}['resolve']({resolvedAt:_0x5a541c=new Date(),resolvedBy:_0x3acec4='',isFromAdapter:_0x1cdaa5=!0x1}={}){const _0x30e395=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x18ab80,id:_0x3b9fc7}=this;this['_repository']['fire'](Nt('resolveCommentThread',_0x18ab80),{'channelId':_0x18ab80,'threadId':_0x3b9fc7,'resolvedAt':_0x5a541c,'resolvedBy':_0x3acec4||_0x30e395['id'],'isFromAdapter':_0x1cdaa5});}['reopen']({isFromAdapter:_0x33f734=!0x1}={}){const {channelId:_0x3e38d4,id:_0x550fe4}=this;this['_repository']['fire'](Nt('reopenCommentThread',_0x3e38d4),{'channelId':_0x3e38d4,'threadId':_0x550fe4,'isFromAdapter':_0x33f734});}['setContext'](_0x3590ab){this['context']||this['_update']({'context':_0x3590ab});}['setAttribute'](_0x51e953,_0x3eacce){const _0x42e832=wt(this['attributes']);yt(_0x42e832,_0x51e953,_0x3eacce),this['_update']({'attributes':_0x42e832});}['removeAttribute'](_0x383551){const _0x20c788=wt(this['attributes']);Ct(_0x20c788,_0x383551),this['_update']({'attributes':_0x20c788});}['remove']({isFromAdapter:_0x546c33=!0x1}={}){const {channelId:_0x5b9931,id:_0x267bde}=this;this['_repository']['fire'](Nt('removeCommentThread',_0x5b9931),{'channelId':_0x5b9931,'threadId':_0x267bde,'isFromAdapter':_0x546c33});}['attachTo'](_0x45e6ae){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x45e6ae});}['addComment'](_0x4fccc7){const {channelId:_0x38a1fc,id:_0x48a8bb}=this;this['_repository']['fire'](Nt('addComment',_0x38a1fc,_0x48a8bb),Object['assign']({'channelId':_0x38a1fc,'threadId':_0x48a8bb},_0x4fccc7));}['getComment'](_0x333aa9){if('string'!=typeof _0x333aa9)throw new _0xd7b9fb('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x333aa9});return this['comments']['get'](_0x333aa9);}['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'](_0x3ed3b1=>_0x3ed3b1['toJSON']()),'attributes':this['attributes']};}['_add'](_0x35ba02){return this['listenTo'](_0x35ba02,'change:authoredAt',()=>{const _0xabe638=this['_findOptimalIndex'](_0x35ba02),_0x58b0a7=this['comments'];_0xabe638-0x1!=_0x58b0a7['getIndex'](_0x35ba02)&&_0xabe638+0x1!=_0x58b0a7['getIndex'](_0x35ba02)&&(this['_remove'](_0x35ba02),this['_add'](_0x35ba02));}),this['comments']['add'](_0x35ba02,this['_findOptimalIndex'](_0x35ba02));}['_update'](_0x2b76a8){const {channelId:_0x1c6b30,id:_0x3e2ce9}=this;this['_repository']['fire'](Nt('updateCommentThread',_0x1c6b30),{..._0x2b76a8,'channelId':_0x1c6b30,'threadId':_0x3e2ce9});}['_remove'](_0x3caf61){return this['stopListening'](_0x3caf61),_0x3caf61['destroy'](),this['comments']['remove'](_0x3caf61);}['_findOptimalIndex'](_0x2d5f8b){const _0x14f4f5=this['comments']['find'](_0x96139c=>new Date(_0x96139c['authoredAt'])['getTime']()>new Date(_0x2d5f8b['authoredAt'])['getTime']());return _0x14f4f5?this['comments']['getIndex'](_0x14f4f5):this['length'];}}class wi extends/* #__PURE__ -- @preserve */
31
+ _0xca3058(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x20d44e,_0x28845a){super();const _0x4d84bb=_0x20d44e['context']['plugins']['get'](it)['me'],_0x392588=_0x20d44e['getCommentThread'](_0x28845a['threadId']),_0x3d7e45=0x0===_0x392588['comments']['length'],_0x11ca52=_0x4d84bb===_0x28845a['author'];this['id']=_0x28845a['id'],this['threadId']=_0x28845a['threadId'],this['author']=_0x28845a['author'],this['creator']=_0x28845a['creator'],this['isExternal']=Boolean(_0x28845a['attributes']&&_0x28845a['attributes']['@external']),this['set']('content',_0x28845a['content']),this['createdAt']=_0x28845a['createdAt']||new Date(),this['set']('authoredAt',_0x28845a['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x392588,'resolvedAt'),this['set']('attributes',_0x28845a['attributes']||{}),this['bind']('isEditable')['to'](_0x20d44e,'_permissions',()=>{const _0x20b1db=_0x20d44e['getPermissions'](_0x392588['channelId'])['write'],_0x3c97dc=_0x20d44e['getPermissions'](_0x392588['channelId'])['modifyAll'];return _0x11ca52&&_0x20b1db||!_0x11ca52&&_0x3c97dc;}),this['bind']('isRemovable')['to'](_0x392588,'isRemovable',_0x20d44e,'_permissions',_0x498b40=>{const _0xd1c51e=_0x20d44e['getPermissions'](_0x392588['channelId'])['write'],_0x35035c=_0x20d44e['getPermissions'](_0x392588['channelId'])['modifyAll'];return _0x11ca52&&_0xd1c51e||_0x498b40&&_0x3d7e45||!_0x11ca52&&_0x35035c&&!_0x3d7e45;}),this['bind']('isReadOnly')['to'](_0x392588,'isReadOnly'),this['_repository']=_0x20d44e;}get['weight'](){return Math['max'](function(_0x3a815a){const _0x2494a0=document['createElement']('div');return _0x2494a0['innerHTML']=_0x3a815a,_0x2494a0['textContent']['length'];}(this['content']),0xc8);}['update'](_0x4774e8){const {threadId:_0x311a8a,id:_0x120ba1}=this;if(!this['_repository']['hasCommentThread'](_0x311a8a))throw new _0xd7b9fb('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x24ebef}=this['_repository']['getCommentThread'](_0x311a8a);this['_repository']['fire'](Nt('updateComment',_0x24ebef,_0x311a8a),{'channelId':_0x24ebef,'threadId':_0x311a8a,'commentId':_0x120ba1,..._0x4774e8});}['setAttribute'](_0x430ff1,_0x36fc2c){const _0x57303f=wt(this['attributes']);yt(_0x57303f,_0x430ff1,_0x36fc2c),this['update']({'attributes':_0x57303f});}['removeAttribute'](_0x598769){const _0x3d42ee=wt(this['attributes']);Ct(_0x3d42ee,_0x598769),this['update']({'attributes':_0x3d42ee});}['remove'](_0x1c9a89={}){if(!_0x1c9a89['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x3b914c,id:_0x2cc7d8}=this;if(!this['_repository']['hasCommentThread'](_0x3b914c))throw new _0xd7b9fb('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x4ce589}=this['_repository']['getCommentThread'](_0x3b914c);this['_repository']['fire'](Nt('removeComment',_0x4ce589,_0x3b914c),{'channelId':_0x4ce589,'threadId':_0x3b914c,'commentId':_0x2cc7d8,..._0x1c9a89});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function Nt(_0x2e1386,..._0x3293ce){for(const _0x511c50 of _0x3293ce)void 0x0!==_0x511c50&&(_0x2e1386+=':'+String(_0x511c50));return _0x2e1386;}class ot extends _0x296d98{constructor(_0x2db86e){super(_0x2db86e),this['set']('hasContent',!0x1);}['refresh'](){const _0x5172dd=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x43b5f7 of _0x5172dd['getRanges']())if(this['_hasContent'](_0x43b5f7))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x34b732=_0x14661f(),ranges:_0x271243,comment:_0x19badf}={}){const _0x5c6dfc=this['editor']['model'],_0x4387af=_0x271243??Array['from'](_0x5c6dfc['document']['selection']['getRanges']()),_0x53e7ea=[];for(const _0x5ac6d2 of _0x4387af)this['_hasContent'](_0x5ac6d2)&&_0x53e7ea['push'](this['_trimToContent'](_0x5ac6d2));if(!_0x53e7ea['length'])throw new _0xd7b9fb('addcommentthreadcommand-incorrect-ranges',null);_0x19badf&&this['_createCommentThread'](_0x34b732,_0x19badf),this['_createMarkersFromRanges'](_0x34b732,_0x53e7ea,!!_0x19badf);}['_createMarkersFromRanges'](_0x504734,_0x5ab299,_0x29927e){this['editor']['model']['change'](_0x243fa1=>{for(const _0x167c9a of _0x5ab299){const _0x2ded3d=_0x14661f()['substr'](0x1,0x5),_0x36e7c7='comment:'+_0x504734+':'+_0x2ded3d;_0x243fa1['addMarker'](_0x36e7c7,{'range':_0x167c9a,'usingOperation':_0x29927e,'affectsData':_0x29927e});}});}['_createCommentThread'](_0x3bb312,_0x54b347){const _0x21b80d=this['editor']['plugins']['get']('CommentsRepository'),_0x55f511=this['editor']['config']['get']('collaboration.channelId'),_0x45b2bc=this['editor']['plugins']['get']('Users')['me'];if(!_0x45b2bc)throw new _0xd7b9fb('addcommentthreadcommand-user-not-found',null);_0x21b80d['addCommentThread']({'threadId':_0x3bb312,'channelId':_0x55f511,'comments':[{'authorId':_0x45b2bc['id'],'content':_0x54b347,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x2cb536){for(const _0xe67dfb of _0x2cb536['getItems']())if(this['_itemIsContent'](_0xe67dfb))return!0x0;return!0x1;}['_itemIsContent'](_0x42a677){return _0x42a677['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x42a677)&&!_0x42a677['is']('element','tableCell');}['_trimToContent'](_0x334579){const _0x1fa50d=_0x2160ee=>!this['_itemIsContent'](_0x2160ee['item']),_0x53ee5b=_0x334579['start']['getLastMatchingPosition'](_0x1fa50d),_0xd85e5=_0x334579['end']['getLastMatchingPosition'](_0x1fa50d,{'direction':'backward'});return this['editor']['model']['createRange'](_0x53ee5b,_0xd85e5);}}class b extends _0x25b6bf{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[y];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2a17ce){super(_0x2a17ce),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x20dbdd=this['editor'],_0x2c7422=_0x20dbdd['model']['document']['selection'],_0x3b1beb=_0x46ba7a(()=>this['refreshSelectedViews'](),0xa);_0x2c7422['on']('change:range',(_0x543f8d,_0x4c28ad)=>{_0x4c28ad['directChange']&&(_0x3b1beb['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x20dbdd['editing']['view']['document'],'change:isFocused',(_0x128a63,_0x4b7d63,_0xb2df1)=>{_0xb2df1&&_0x3b1beb();}),this['listenTo'](_0x20dbdd['ui']['focusTracker'],'change:isFocused',(_0x57f112,_0x411ee4,_0x57f938)=>{_0x57f938||this['fire']('blur',{'isAnnotationTracked':_0x681814=>this['_editorAnnotationsData']['has'](_0x681814['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x1a57a0){if(this['_editorAnnotations']['has'](_0x1a57a0['view']))return;this['_editorAnnotations']['add'](_0x1a57a0['view']),this['editor']['ui']['focusTracker']['add'](_0x1a57a0['view']['element']);const _0x20e0a9=this['editor']['plugins']['get'](y);this['listenTo'](_0x20e0a9['collection'],'remove',(_0x59756b,_0x174436)=>{this['editor']['ui']['focusTracker']['remove'](_0x174436['view']['element']),this['_editorAnnotations']['delete'](_0x174436['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x156851){if('function'!=typeof _0x156851)throw new _0xd7b9fb('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x156851);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x847f73,annotations:_0x3b5ff0}){const _0x8c7365=[],_0x54519=this['editor']['model']['document']['selection'],_0x8cac56=Array['from'](_0x54519['getRanges']());for(const [_0x2dd42a,_0x4035bc]of this['_editorAnnotationsData']){const _0x370ff3=_0x5ceffe(_0x4035bc),_0x39610=_0x3b5ff0['getByInnerView'](_0x2dd42a);_0x370ff3&&_0x39610&&_0x8c7365['push']({'annotation':_0x39610,'range':_0x370ff3});}function _0x5ceffe(_0x188e6f){for(const _0x5663db of _0x188e6f)for(const _0x420d42 of _0x8cac56)if(_0x5663db['containsRange'](_0x420d42,!_0x54519['isCollapsed']))return _0x5663db;return null;}return _0x8c7365['sort']((_0x2ae7d4,_0x397ab9)=>{const _0x22a9de=_0x2ae7d4['range'],_0x43afd3=_0x397ab9['range'];if(!_0x22a9de['isEqual'](_0x43afd3)){if(_0x22a9de['containsRange'](_0x43afd3,!0x0))return 0x1;if(_0x43afd3['containsRange'](_0x22a9de,!0x0))return-0x1;}return _0x2ae7d4['annotation']==_0x847f73?-0x1:_0x397ab9['annotation']==_0x847f73?0x1:0x0;})['map'](_0x2c8e7a=>_0x2c8e7a['annotation']);}get['_editorAnnotationsData'](){const _0x351633=new Map();for(const _0x31ce1c of Array['from'](this['_dataCollectors']))for(const [_0x3c1ec8,_0x32f3a1]of _0x31ce1c())_0x351633['set'](_0x3c1ec8,_0x32f3a1);return _0x351633;}}class st extends _0x25b6bf{['afterInit'](){const _0x30dfac=this['editor'];if(!_0x30dfac['plugins']['has']('RestrictedEditingModeEditing'))return;_0x30dfac['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x25b6bf{constructor(_0x49d25e){super(_0x49d25e),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x1ae99c=this['editor'],_0x22844c=_0x1ae99c['commands']['get']('importWord'),_0x3afbda=_0x1ae99c['plugins']['get'](it);_0x22844c&&(_0x22844c['on']('execute',(_0x8a3b02,[,_0x49511])=>{_0x49511['collaboration_features']={'comments':!0x0,'user_id':_0x3afbda['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x22844c,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x3d94c7,_0x277d88){const {comment_threads:_0x2ef4a7}=_0x277d88;_0x2ef4a7&&_0x2ef4a7['forEach'](({thread_id:_0xc9160b,comments:_0x190bb7,is_resolved:_0x3ac300})=>{const _0x40bc24=new Date(),_0x23e744=_0x190bb7['map'](({author:_0x1e8248,content:_0x119c03,created_at:_0x852455})=>({'content':_0x119c03,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x40bc24,'attributes':{'@external':{'authorName':_0x1e8248,'createdAt':_0x852455?new Date(_0x852455):new Date(),'source':'importWord'}}})),_0xe73ded=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0xe73ded,'threadId':_0xc9160b,'comments':_0x23e744,'resolvedAt':_0x3ac300?_0x40bc24:null});});}}class at extends _0x25b6bf{constructor(_0x12c595){super(_0x12c595),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x140717=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x140717,'contentInsertion',(_0x29edbf,_0x1412a4)=>this['_removeMarkersWithoutThreads'](_0x1412a4['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x32364b){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x32364b;const _0x3c139b=this['editor']['plugins']['get']('CommentsRepository');for(const _0x4d8974 of _0x32364b['keys']()){const [_0x46baef,_0x21a378]=_0x4d8974['split'](':');'comment'!=_0x46baef||_0x3c139b['hasCommentThread'](_0x21a378)||_0x32364b['delete'](_0x4d8974);}return _0x32364b;}['_registerMarkerInClipboardPipeline'](){const _0x24e9cc=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x3ba415=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x3ba415&&_0x24e9cc['_registerMarkerToCopy']('comment',_0x3ba415);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x216f6d){switch(_0x216f6d){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}function ft(_0x531e2c){const _0x2bc5d2=_0x531e2c['split'](':');return{'group':_0x2bc5d2[0x0],'id':_0x2bc5d2[0x1],'part':_0x2bc5d2[0x2]};}class ut extends _0x25b6bf{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x581904,_0x5e5122)=>{if(!_0x5e5122['options']['showCommentHighlights'])return null;if(_0x5e5122['options']['ignoreResolvedComments']){const {id:_0x421536}=ft(_0x581904['markerName']),_0x54efb5=this['editor']['plugins']['get'](o);if(_0x54efb5['getCommentThread'](_0x421536)?.['isResolved']&&_0x581904['item'])return _0x5e5122['consumable']['consume'](_0x581904['item'],'addMarker:'+_0x581904['markerName']),_0x5e5122['consumable']['consume'](_0x581904['item'],'removeMarker:'+_0x581904['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x14a913=>{_0x14a913['on']('addMarker:comment',(_0x10847e,_0x506623,_0x4464c6)=>{if(!_0x4464c6['options']['showCommentHighlights'])return;const _0x1df9ba=_0x506623['item'];if(!_0x1df9ba)return;const _0xa3c77d=_0x4464c6['mapper']['toViewElement'](_0x1df9ba);this['editor']['model']['schema']['isObject'](_0x1df9ba)&&_0xa3c77d&&!_0xa3c77d['getCustomProperty']('widget')&&_0xa3c77d['is']('containerElement')&&_0x631d41(_0xa3c77d,_0x4464c6['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x466c36,{writer:_0x316e51,options:_0x2dcb97})=>{if(!_0x2dcb97['showCommentHighlights'])return null;const _0x245685=_0x316e51['createContainerElement']('div'),_0x50c80=_0x316e51['createEmptyElement']('hr');return _0x316e51['addClass']('ck-horizontal-line',_0x245685),_0x316e51['insert'](_0x316e51['createPositionAt'](_0x245685,0x0),_0x50c80),_0x245685;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x46511e,{writer:_0x56b82e,options:_0x11fea5})=>{if(!_0x11fea5['showCommentHighlights'])return null;const _0x140c33=_0x56b82e['createContainerElement']('span'),_0x119ba0=_0x56b82e['createEmptyElement']('img');return _0x56b82e['addClass']('image-inline',_0x140c33),_0x56b82e['insert'](_0x56b82e['createPositionAt'](_0x140c33,0x0),_0x119ba0),_0x140c33;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0xa8b82,{writer:_0x2bba03,options:_0x38f0ba})=>{if(_0x38f0ba['showCommentHighlights'])return _0x2bba03['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x4c9e86,_0x138673,_0x2d9be0)=>{_0x2d9be0['options']['showCommentHighlights']&&_0x4c9e86['stop']();},{'priority':'high'});}}class r extends _0x25b6bf{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(_0x121e33){super(_0x121e33),this['set']('isThreadsLoadingPaused',!0x0),_0x121e33['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x1c8790,_0xf818ac,_0x5ea72c,_0x2726cb)=>{const _0x2b8f0b=_0x121e33['plugins']['get'](o),_0x4b2296=_0x5ea72c?ft(_0x5ea72c)['id']:null;_0x121e33['model']['change'](()=>{if(_0x4b2296){const _0x53941d=this['getAllMarkersForId'](_0x4b2296);for(const _0x50d915 of _0x53941d)_0x121e33['editing']['reconvertMarker'](_0x50d915);}if(_0x2726cb){const {id:_0x4da8e0}=ft(_0x2726cb),_0x2bda23=_0x2b8f0b['getCommentThread'](_0x4da8e0);if(_0x2bda23&&_0x2bda23['unlinkedAt'])return;if(_0x2bda23&&!_0x2bda23['isAttached'])return;const _0x2e9b07=this['getAllMarkersForId'](_0x4da8e0);for(const _0x1c2b33 of _0x2e9b07)_0x121e33['editing']['reconvertMarker'](_0x1c2b33);}}),_0x4b2296&&this['scrollToThreadMarker'](_0x4b2296);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x2adeff=this['editor'],_0x2101ab=_0x2adeff['plugins']['get'](o),_0xdc8a59=_0x2adeff['config']['get']('collaboration.channelId'),_0x372689=_0x2101ab['getCommentThreads']()['filter'](_0x32457c=>_0x32457c['channelId']!==_0xdc8a59);_0x2adeff['commands']['add']('addCommentThread',new ot(_0x2adeff)),this['listenTo'](_0x2adeff,'change:isReadOnly',(_0x258a48,_0x1d2bc4,_0x391c83)=>{_0x2101ab['switchReadOnly'](_0x391c83,_0x2adeff['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x2101ab,dt('addCommentThread',_0xdc8a59),(_0x1b7063,{threadId:_0x1f40d6})=>{const _0x585a3e=this['editor']['plugins']['get'](o)['getCommentThread'](_0x1f40d6);_0x585a3e?.['unlinkedAt']&&this['_attachArchivedThread'](_0x1f40d6);}),this['listenTo'](_0x2101ab,dt('removeCommentThread',_0xdc8a59),(_0x4adbbf,{threadId:_0x6dc3de})=>{_0x2adeff['model']['enqueueChange']({'isUndoable':!0x1},_0x2c0cd3=>{const _0x3e6e82=this['getAllMarkersForId'](_0x6dc3de);for(const _0x1624d0 of _0x3e6e82)_0x2c0cd3['removeMarker'](_0x1624d0);});}),this['listenTo'](_0x2101ab,dt('resolveCommentThread',_0xdc8a59),(_0x4bc1a9,{threadId:_0x4e4976})=>{(this['_reconvertMarkers'](_0x4e4976),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x4e4976)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x2101ab,dt('reopenCommentThread',_0xdc8a59),(_0x501f75,{threadId:_0x297513})=>{this['_reconvertMarkers'](_0x297513);},{'priority':'low'}),this['listenTo'](_0x2101ab,dt('addComment',_0xdc8a59),(_0x4e4b84,{threadId:_0x13c563,isFromAdapter:_0x5f310f})=>{const _0x21de02=this['getAllMarkersForId'](_0x13c563);if(_0x5f310f||0x0==_0x21de02['length']||!_0x2101ab['hasCommentThread'](_0x13c563))return;0x1===_0x2101ab['getCommentThread'](_0x13c563)['length']&&_0x2adeff['model']['enqueueChange']({'isUndoable':!0x1},_0x554dd3=>{for(const _0xd846cf of _0x21de02)_0x554dd3['updateMarker'](_0xd846cf,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x372689);}['afterInit'](){!async function(_0x31519f){const _0x5aefdc=_0x310aa0([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]),_0x3bdae4=0x73460ab3,_0x584f6f=0x73418c1b^_0x3bdae4,_0x3732bb=window[_0x310aa0([0x44,0x61,0x74,0x65])][_0x310aa0([0x6e,0x6f,0x77])](),_0x5c7091=_0x31519f[_0x310aa0([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x219745=new window[(_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x78e5bc=>{_0x5c7091[_0x310aa0([0x6f,0x6e,0x63,0x65])](_0x310aa0([0x72,0x65,0x61,0x64,0x79]),_0x78e5bc);}),_0x3aa57d={[_0x310aa0([0x6b,0x74,0x79])]:_0x310aa0([0x45,0x43]),[_0x310aa0([0x75,0x73,0x65])]:_0x310aa0([0x73,0x69,0x67]),[_0x310aa0([0x63,0x72,0x76])]:_0x310aa0([0x50,0x2d,0x32,0x35,0x36]),[_0x310aa0([0x78])]:_0x310aa0([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]),[_0x310aa0([0x79])]:_0x310aa0([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]),[_0x310aa0([0x61,0x6c,0x67])]:_0x310aa0([0x45,0x53,0x32,0x35,0x36])},_0x5b698a=_0x5c7091[_0x310aa0([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x310aa0([0x67,0x65,0x74])](_0x310aa0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x240e08(){let _0x151168,_0x47ebeb=null,_0x16b4cf=null;try{if(_0x5b698a==_0x310aa0([0x47,0x50,0x4c]))return _0x310aa0([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x151168=_0x18d24e(),!_0x151168)return _0x310aa0([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x151168[_0x310aa0([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x16b4cf=_0x46b606(_0x151168[_0x310aa0([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x151168[_0x310aa0([0x6a,0x74,0x69])])),await _0x42911d()?_0x4d07dd()?_0x58ce1()?_0x310aa0([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5aed0f()?(_0x151168[_0x310aa0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x310aa0([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x47ebeb=_0x32cfd4(_0x310aa0([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2c01e7()):_0x310aa0([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x310aa0([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x310aa0([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x310aa0([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x58ce1(){const _0x12e298=[_0x310aa0([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x310aa0([0x74,0x72,0x69,0x61,0x6c])][_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x151168[_0x310aa0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3732bb/0x3e8:0xe10*_0x584f6f;return _0x151168[_0x310aa0([0x65,0x78,0x70])]<_0x12e298;}function _0x4d07dd(){const _0x53e4d9=_0x151168[_0x310aa0([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x53e4d9)return!0x1;if(_0x53e4d9[_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x310aa0([0x2a])))return!0x0;if(_0x53e4d9[_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x310aa0([0x43,0x4d,0x54])))return!0x0;if(_0x53e4d9[_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x310aa0([0x54,0x52,0x49,0x4c,0x49,0x55,0x4d]))&&_0x970364())return!0x0;if(_0x53e4d9[_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x310aa0([0x52,0x43,0x4d,0x54]))){if(_0xbfad26())return!0x0;if(_0x277df0()||_0x2f67f7())return!0x0;}return!0x1;}function _0x5aed0f(){const _0x29dec3=_0x151168[_0x310aa0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x29dec3||0x0==_0x29dec3[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2a0fdd}=new URL(window[_0x310aa0([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x29dec3[_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2a0fdd))return!0x0;const _0x37f917=_0x2a0fdd[_0x310aa0([0x73,0x70,0x6c,0x69,0x74])](_0x310aa0([0x2e]));return _0x29dec3[_0x310aa0([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x438db8=>_0x438db8[_0x310aa0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x310aa0([0x2a])))[_0x310aa0([0x6d,0x61,0x70])](_0x3bf971=>_0x3bf971[_0x310aa0([0x73,0x70,0x6c,0x69,0x74])](_0x310aa0([0x2e])))[_0x310aa0([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x35d3e9=>_0x35d3e9[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x37f917[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x310aa0([0x6d,0x61,0x70])](_0x3ce0b9=>Array(_0x37f917[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3ce0b9[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x310aa0([0x66,0x69,0x6c,0x6c])](_0x3ce0b9[0x0]===_0x310aa0([0x2a])?_0x310aa0([0x2a]):'')[_0x310aa0([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3ce0b9))[_0x310aa0([0x73,0x6f,0x6d,0x65])](_0x573a1e=>_0x37f917[_0x310aa0([0x65,0x76,0x65,0x72,0x79])]((_0x363e62,_0x577176)=>_0x573a1e[_0x577176]===_0x363e62||_0x573a1e[_0x577176]===_0x310aa0([0x2a])));}function _0x2c01e7(){return _0x47ebeb&&_0x16b4cf?new window[(_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1bd6b4,_0x55bccb)=>{_0x47ebeb[_0x310aa0([0x74,0x68,0x65,0x6e])](_0x1bd6b4,_0x55bccb),_0x16b4cf[_0x310aa0([0x74,0x68,0x65,0x6e])](_0x20ba45=>{_0x20ba45!=_0x310aa0([0x56,0x61,0x6c,0x69,0x64])&&_0x1bd6b4(_0x20ba45);},_0x55bccb);}):_0x47ebeb||_0x16b4cf||_0x310aa0([0x56,0x61,0x6c,0x69,0x64]);}}function _0x46b606(_0x5d1e97,_0x4621c7){return new window[(_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x9d6cb6=>{if(_0x48f193())return _0x9d6cb6(_0x310aa0([0x56,0x61,0x6c,0x69,0x64]));_0x3b5138(),_0x5c7091[_0x310aa0([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x310aa0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x36da7f=!0x1;const _0x224e51=_0x14661f();function _0x299654(_0x5af3e4){return!!_0x5af3e4&&(typeof _0x5af3e4===_0x310aa0([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5af3e4===_0x310aa0([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5af3e4[_0x310aa0([0x74,0x68,0x65,0x6e])]===_0x310aa0([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5af3e4[_0x310aa0([0x63,0x61,0x74,0x63,0x68])]===_0x310aa0([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x12bf11(_0x5b9ac2){_0x3cbe0d(_0x5b9ac2)[_0x310aa0([0x74,0x68,0x65,0x6e])](_0x1059f4=>{if(!_0x1059f4||_0x1059f4[_0x310aa0([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x310aa0([0x6f,0x6b]))return _0x310aa0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x36d8d3(_0x56c4e6(_0x224e51+_0x4621c7))!=_0x1059f4[_0x310aa0([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x310aa0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x310aa0([0x56,0x61,0x6c,0x69,0x64]);})[_0x310aa0([0x74,0x68,0x65,0x6e])](_0x1dd389=>(_0x39d532(),_0x1dd389),()=>{const _0x204020=_0x299004();return null==_0x204020?(_0x39d532(),_0x310aa0([0x56,0x61,0x6c,0x69,0x64])):_0x310aa0(_0x3732bb-_0x204020>(0x574a8eb3^_0x3bdae4)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x310aa0([0x74,0x68,0x65,0x6e])](_0x9d6cb6)[_0x310aa0([0x63,0x61,0x74,0x63,0x68])](()=>{_0x9d6cb6(_0x310aa0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x33f97d=0x7370e433^_0x3bdae4;function _0x39d532(){const _0x3eb25d=_0x310aa0([0x6c,0x6c,0x63,0x74,0x2d])+_0x36d8d3(_0x56c4e6(_0x5d1e97)),_0xd727fe=_0x23580c(_0x36d8d3(window[_0x310aa0([0x4d,0x61,0x74,0x68])][_0x310aa0([0x63,0x65,0x69,0x6c])](_0x3732bb/_0x33f97d)));window[_0x310aa0([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x310aa0([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3eb25d,_0xd727fe);}function _0x299004(){const _0x4d0fd4=_0x310aa0([0x6c,0x6c,0x63,0x74,0x2d])+_0x36d8d3(_0x56c4e6(_0x5d1e97)),_0x308c98=window[_0x310aa0([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x310aa0([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4d0fd4);return _0x308c98?window[_0x310aa0([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x23580c(_0x308c98),0x10)*_0x33f97d:null;}function _0x3cbe0d(_0x58b92a){return new window[(_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4bcb08,_0x5d0b59)=>{_0x58b92a[_0x310aa0([0x74,0x68,0x65,0x6e])](_0x4bcb08,_0x5d0b59),window[_0x310aa0([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5d0b59,0x7347de73^_0x3bdae4);});}}_0x5c7091[_0x310aa0([0x6f,0x6e])](_0x310aa0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x53a9b0,_0x38557d)=>{if(_0x38557d[0x0]!=_0x5d1e97)return _0x9d6cb6(_0x310aa0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x38557d[0x1]={..._0x38557d[0x1],[_0x310aa0([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x224e51};},{[_0x310aa0([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x310aa0([0x68,0x69,0x67,0x68])}),_0x5c7091[_0x310aa0([0x6f,0x6e])](_0x310aa0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1365c1=>{_0x299654(_0x1365c1[_0x310aa0([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x36da7f=!0x0,_0x12bf11(_0x1365c1[_0x310aa0([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x310aa0([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x310aa0([0x6c,0x6f,0x77])}),_0x219745[_0x310aa0([0x74,0x68,0x65,0x6e])](()=>{_0x36da7f||_0x9d6cb6(_0x310aa0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x48f193(){return _0x5c7091[_0x310aa0([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x310aa0([0x76,0x69,0x65,0x77])][_0x310aa0([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x310aa0([0x61,0x75,0x74,0x6f]);}function _0x3b5138(){_0x5c7091[_0x310aa0([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x310aa0([0x76,0x69,0x65,0x77])][_0x310aa0([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x310aa0([0x61,0x75,0x74,0x6f]);}}function _0x32cfd4(_0x4019af){const _0x4d52c4=[new window[(_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x24444d=>setTimeout(_0x24444d,0x734f347f^_0x3bdae4)),_0x219745[_0x310aa0([0x74,0x68,0x65,0x6e])](()=>new window[(_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x196c98=>{let _0x170044=0x0;_0x5c7091[_0x310aa0([0x6d,0x6f,0x64,0x65,0x6c])][_0x310aa0([0x6f,0x6e])](_0x310aa0([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x377677,_0x16302f)=>{_0x16302f[0x0][_0x310aa0([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x170044++,_0x170044==(0x73460f5b^_0x3bdae4)&&(_0x196c98(),_0x377677[_0x310aa0([0x6f,0x66,0x66])]());});}))];return window[_0x310aa0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x310aa0([0x72,0x61,0x63,0x65])](_0x4d52c4)[_0x310aa0([0x74,0x68,0x65,0x6e])](()=>_0x4019af);}async function _0x33a499(){await _0x219745,_0x5c7091[_0x310aa0([0x6d,0x6f,0x64,0x65,0x6c])][_0x310aa0([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4b1737,_0x5c7091[_0x310aa0([0x6d,0x6f,0x64,0x65,0x6c])][_0x310aa0([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4b1737,_0x5c7091[_0x310aa0([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x310aa0([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x970364(){return window[_0x310aa0([0x67,0x6c,0x6f,0x62])]&&window[_0x310aa0([0x67,0x6c,0x6f,0x62])][_0x310aa0([0x74,0x72,0x69,0x6c,0x69,0x75,0x6d,0x56,0x65,0x72,0x73,0x69,0x6f,0x6e])];}function _0xbfad26(){return _0x29ce2b(_0x310aa0([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x183178(_0x310aa0([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x310aa0([0x73,0x74,0x61,0x74,0x65])]==_0x310aa0([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x277df0(){return _0x29ce2b(_0x310aa0([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 _0x2f67f7(){return _0x29ce2b(_0x310aa0([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x175ab5(_0x13b055){const _0x333b23=_0x31fdbe();_0x5c7091[_0x333b23]=_0x310aa0([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x13b055,_0x13b055!=_0x310aa0([0x56,0x61,0x6c,0x69,0x64])&&_0x33a499();}function _0x31fdbe(){const _0xbf0591=window[_0x310aa0([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x310aa0([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x310aa0([0x6e,0x6f,0x77])]())[_0x310aa0([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x310aa0([0x2e]),'');let _0x918422=_0x310aa0([0x4b]);for(let _0x242278=0x0;_0x242278<_0xbf0591[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x242278+=0x2){let _0xda5bbc=window[_0x310aa0([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xbf0591[_0x310aa0([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x242278,_0x242278+0x2));_0xda5bbc>=_0x5aefdc[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xda5bbc-=_0x5aefdc[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x918422+=_0x5aefdc[_0xda5bbc];}return _0x918422;}function _0x18d24e(){const _0x15c0c1=_0x5b698a[_0x310aa0([0x73,0x70,0x6c,0x69,0x74])](_0x310aa0([0x2e]));if(0x3!=_0x15c0c1[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x10fec5(_0x15c0c1[0x1]);function _0x10fec5(_0x56b605){const _0x276b11=_0x1653de(_0x56b605);return _0x276b11&&_0x435566()?_0x276b11:null;function _0x435566(){const _0x523a10=_0x276b11[_0x310aa0([0x6a,0x74,0x69])],_0x1450bd=window[_0x310aa0([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x523a10[_0x310aa0([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x523a10[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xbebdb3={..._0x276b11,[_0x310aa0([0x6a,0x74,0x69])]:_0x523a10[_0x310aa0([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x523a10[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xbebdb3[_0x310aa0([0x76,0x63])],_0x56c4e6(_0xbebdb3)==_0x1450bd;}}}async function _0x42911d(){let _0x3042e2=!0x0;try{const _0x5f35da=_0x5b698a[_0x310aa0([0x73,0x70,0x6c,0x69,0x74])](_0x310aa0([0x2e])),[_0x1ffd37,_0x26ce4f,_0x15c504]=_0x5f35da;return _0x13a20f(_0x1ffd37),await _0x1acffa(_0x1ffd37,_0x26ce4f,_0x15c504),_0x3042e2;}catch{return!0x1;}function _0x13a20f(_0x1a0b9c){const _0x37d7d9=_0x1653de(_0x1a0b9c);_0x37d7d9&&_0x37d7d9[_0x310aa0([0x61,0x6c,0x67])]==_0x310aa0([0x45,0x53,0x32,0x35,0x36])||(_0x3042e2=!0x1);}async function _0x1acffa(_0x1a72b3,_0x461064,_0x476d76){const _0x80fa0c=window[_0x310aa0([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x310aa0([0x66,0x72,0x6f,0x6d])](_0x4f14a0(_0x476d76),_0xf7113f=>_0xf7113f[_0x310aa0([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x41dc90=new window[(_0x310aa0([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x310aa0([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1a72b3+_0x310aa0([0x2e])+_0x461064),_0xf7bbf2=window[_0x310aa0([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x310aa0([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xf7bbf2)return;const _0x436186=await _0xf7bbf2[_0x310aa0([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x310aa0([0x6a,0x77,0x6b]),_0x3aa57d,{[_0x310aa0([0x6e,0x61,0x6d,0x65])]:_0x310aa0([0x45,0x43,0x44,0x53,0x41]),[_0x310aa0([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x310aa0([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x310aa0([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xf7bbf2[_0x310aa0([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x310aa0([0x6e,0x61,0x6d,0x65])]:_0x310aa0([0x45,0x43,0x44,0x53,0x41]),[_0x310aa0([0x68,0x61,0x73,0x68])]:{[_0x310aa0([0x6e,0x61,0x6d,0x65])]:_0x310aa0([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x436186,_0x80fa0c,_0x41dc90)||(_0x3042e2=!0x1);}}function _0x1653de(_0x79f23d){return _0x79f23d[_0x310aa0([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x310aa0([0x65,0x79]))?JSON[_0x310aa0([0x70,0x61,0x72,0x73,0x65])](_0x4f14a0(_0x79f23d)):null;}function _0x4f14a0(_0x5e3722){return window[_0x310aa0([0x61,0x74,0x6f,0x62])](_0x5e3722[_0x310aa0([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x310aa0([0x2b]))[_0x310aa0([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x310aa0([0x2f])));}function _0x56c4e6(_0x40316a){let _0x2ef408=0x1505;function _0x531b8a(_0x438edf){for(let _0x38f322=0x0;_0x38f322<_0x438edf[_0x310aa0([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x38f322++){const _0x899e54=_0x438edf[_0x310aa0([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x38f322);_0x2ef408=(_0x2ef408<<0x5)+_0x2ef408+_0x899e54,_0x2ef408&=_0x2ef408;}}function _0x431511(_0x27fc9d){Array[_0x310aa0([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x27fc9d)?_0x27fc9d[_0x310aa0([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x431511):_0x27fc9d&&typeof _0x27fc9d==_0x310aa0([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x310aa0([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x27fc9d)[_0x310aa0([0x73,0x6f,0x72,0x74])]()[_0x310aa0([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x344ded,_0x1049d6])=>{_0x531b8a(_0x344ded),_0x431511(_0x1049d6);}):_0x531b8a(window[_0x310aa0([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x27fc9d));}return _0x431511(_0x40316a),_0x2ef408>>>0x0;}function _0x36d8d3(_0x59e00f){return _0x59e00f[_0x310aa0([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x310aa0([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x310aa0([0x30]));}function _0x23580c(_0x12f06c){return _0x12f06c[_0x310aa0([0x73,0x70,0x6c,0x69,0x74])]('')[_0x310aa0([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x310aa0([0x6a,0x6f,0x69,0x6e])]('');}function _0x29ce2b(_0x43c9f2){return _0x5c7091[_0x310aa0([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x310aa0([0x68,0x61,0x73])](_0x43c9f2);}function _0x183178(_0xe520af){return _0x5c7091[_0x310aa0([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x310aa0([0x67,0x65,0x74])](_0xe520af);}function _0x4b1737(){}function _0x310aa0(_0x8c1a08){return _0x8c1a08['map'](_0x5e05d8=>String['fromCharCode'](_0x5e05d8))['join']('');}_0x175ab5(await _0x240e08());}(this);}['destroy'](){const _0x291cb7=this['editor']['plugins']['get'](o),_0x16c3f2=this['editor']['config']['get']('collaboration.channelId');for(const _0x576e61 of _0x291cb7['getCommentThreads']({'channelId':_0x16c3f2}))_0x291cb7['_detachCommentThread'](_0x576e61['id']),_0x291cb7['_threads']['delete'](_0x576e61['id']);super['destroy']();}['hasMarkerForId'](_0x3b3cee){return this['getAllMarkersForId'](_0x3b3cee)['length']>0x0;}['getAllMarkersForId'](_0x4e4728){const _0x331ba2=[];for(const _0x580157 of this['editor']['model']['markers'])_0x580157['name']['startsWith']('comment:'+_0x4e4728)&&_0x331ba2['push'](_0x580157);return _0x331ba2;}['scrollToThreadMarker'](_0x46e848){setTimeout(()=>{const _0x6dff41=this['_getTargetForId'](_0x46e848);if(!_0x6dff41)return;this['activeMarker']&&ft(this['activeMarker'])['id']===_0x46e848&&nt({'target':_0x6dff41[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x43f5c4){this['editor']['model']['change'](()=>{for(const _0x4a3ffe of this['getAllMarkersForId'](_0x43f5c4))this['editor']['editing']['reconvertMarker'](_0x4a3ffe);});}['_attachArchivedThread'](_0x3185e5){const _0x48d0bc=this['editor']['plugins']['get'](o),_0x1b6e1c=this['editor']['plugins']['get'](b),_0x37b832=_0x48d0bc['getCommentThread'](_0x3185e5);if(!_0x37b832['isAttached']){const _0x5adefe=_0x37b832['attachTo'](()=>this['_getTargetForId'](_0x37b832['id']));_0x1b6e1c['registerAnnotation'](_0x5adefe),_0x37b832['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x295631=this['editor'],_0x2ab2d0=_0x295631['plugins']['get'](it);_0x295631['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x808e0f,_0x2c88fc)=>{const {id:_0xa96178}=ft(_0x808e0f['markerName']),_0x39632a=_0x295631['plugins']['get'](o)['getCommentThread'](_0xa96178),_0x2848a9=this['activeMarker']&&ft(this['activeMarker'])['id']===_0xa96178;let _0x1083f0;if(_0x39632a&&_0x39632a['isResolved']&&!_0x2848a9&&_0x808e0f['item'])return _0x2c88fc['consumable']['consume'](_0x808e0f['item'],'addMarker:'+_0x808e0f['markerName']),_0x2c88fc['consumable']['consume'](_0x808e0f['item'],'removeMarker:'+_0x808e0f['markerName']),null;const _0x5c732b=['ck-comment-marker'];return _0x2848a9&&_0x5c732b['push']('ck-comment-marker--active'),_0x1083f0=_0x39632a?.['length']?_0x39632a['comments']['first']['author']['id']:_0x2ab2d0['me']['id'],{'classes':_0x5c732b,'attributes':{'data-comment':_0xa96178,'data-author-id':_0x1083f0}};}}),_0x295631['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x10a1d4,{options:_0x250433})=>{if(_0x250433['showCommentHighlights'])return null;const _0x32f0be=_0x295631['plugins']['get'](o),_0x13e072=_0x295631['model']['markers']['get'](_0x10a1d4),{id:_0x2bd42f,part:_0x5d3997}=ft(_0x10a1d4);return _0x13e072&&!_0x13e072['affectsData']||_0x250433['ignoreResolvedComments']&&_0x32f0be['getCommentThread'](_0x2bd42f)?.['isResolved']?null:{'group':'comment','name':_0x5d3997?_0x2bd42f+':'+_0x5d3997:_0x2bd42f};}}),_0x295631['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x5c58ae,{writer:_0xf4c99})=>_0xf4c99['createElement']('$marker',{'data-name':'comment:'+_0x5c58ae['getAttribute']('id')})}),_0x295631['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x2e60ab=this['editor'],_0x13e1c7=_0x2e60ab['plugins']['get'](o),_0x1d7141=new Set(),_0x1cbf6d=new Set();_0x2e60ab['model']['document']['registerPostFixer'](_0x5cae4d=>{let _0x37874c=!0x1;for(const {name:_0xd115bb,data:_0x1bf854}of _0x2e60ab['model']['document']['differ']['getChangedMarkers']()){const {group:_0x28e8bb,id:_0x4d218f}=ft(_0xd115bb);let _0x594ca7=_0x1bf854['newRange'];if('comment'!==_0x28e8bb||!_0x594ca7)continue;const _0x900edd='$graveyard'===_0x594ca7['root']['rootName'];_0x900edd||(_0x594ca7=ht(_0x594ca7,_0x2e60ab['model']),!_0x594ca7||_0x594ca7['isCollapsed']||!_0x1bf854['newRange']||_0x594ca7['isEqual'](_0x1bf854['newRange']))?_0x2e60ab['model']['hasContent'](_0x594ca7)&&!_0x900edd?this['isThreadsLoadingPaused']?_0x1d7141['add'](_0xd115bb):this['_handleThreadMarker'](_0xd115bb,_0x4d218f):(_0x1cbf6d['add'](_0xd115bb),_0x1d7141['delete'](_0xd115bb),_0x5cae4d['removeMarker'](_0xd115bb),_0x37874c=!0x0):(_0x5cae4d['updateMarker'](_0xd115bb,{'range':_0x594ca7}),_0x37874c=!0x0);}return _0x37874c;}),this['on']('change:isThreadsLoadingPaused',(_0x188096,_0x58ebd8,_0x6aeba7)=>{if(!_0x6aeba7&&_0x1d7141['size'])for(const _0x393165 of _0x1d7141){const {id:_0x52a31a}=ft(_0x393165);_0x1d7141['delete'](_0x393165),_0x2e60ab['model']['markers']['get'](_0x393165)&&this['_handleThreadMarker'](_0x393165,_0x52a31a);}}),this['listenTo'](_0x2e60ab['model']['document'],'change',()=>{for(const {name:_0x2686b1,data:{newRange:_0x496360}}of _0x2e60ab['model']['document']['differ']['getChangedMarkers']()){const {group:_0x61045d,id:_0x2a12a0}=ft(_0x2686b1);if('comment'!==_0x61045d)continue;const _0x36bcc5=_0x13e1c7['getCommentThread'](_0x2a12a0),_0x2df1f7=this['hasMarkerForId'](_0x2a12a0);_0x36bcc5&&(!_0x36bcc5['_hasTargetInContent']&&_0x496360&&_0x2e60ab['editing']['view']['once']('render',()=>{const _0x258552=_0x2e60ab['plugins']['get'](y),_0x2f3527=_0x13e1c7['_threadToController']['get'](_0x36bcc5)['view'];_0x258552['getByInnerView'](_0x2f3527)['refreshVisibility']();},{'priority':'low'}),_0x36bcc5['_hasTargetInContent']=_0x2df1f7||!!_0x496360),_0x496360||(_0x1cbf6d['add'](_0x2686b1),_0x1d7141['delete'](_0x2686b1));}for(const _0x10fcf1 of _0x1cbf6d){const {id:_0x1b6206}=ft(_0x10fcf1),_0x50d1c4=_0x13e1c7['getCommentThread'](_0x1b6206);if(_0x1d7141['delete'](_0x10fcf1),!_0x50d1c4)continue;const _0x59e4c2=this['hasMarkerForId'](_0x1b6206);_0x59e4c2||_0x50d1c4['isSubmitted']?_0x59e4c2||_0x50d1c4['unlinkedAt']||_0x50d1c4['setUnlinkedAt'](new Date()):_0x50d1c4['remove']();}_0x1cbf6d['clear']();});}['_handleInitialThreads'](_0xee309e){_0xee309e['forEach'](_0x18e2c7=>{_0x18e2c7['unlinkedAt']&&this['_attachArchivedThread'](_0x18e2c7['id']);});}['_getTargetForId'](_0x22614f){const _0x24ef5b=this['editor'],_0x545a29=this['getAllMarkersForId'](_0x22614f);return et(_0x24ef5b['editing'],_0x545a29);}['_getTextContext'](_0x4c3844){const _0x1b1b01=this['getAllMarkersForId'](_0x4c3844);let _0x9cc08a='',_0x271424=!0x1;for(const _0x48ba15 of _0x1b1b01){const _0x3dfb28=_0x48ba15['getRange']();for(const _0x157ecc of Array['from'](_0x3dfb28['getItems']()))_0x157ecc['is']('$textProxy')?(_0x9cc08a&&_0x271424&&(_0x9cc08a+='\x20',_0x271424=!0x1),_0x9cc08a+=_0x157ecc['data']):_0x271424=!0x0;_0x271424=!0x0;}return _0x9cc08a['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x130cba,_0x51ed4c){const _0x3a8994=this['editor'],_0x5ea16b=_0x3a8994['plugins']['get'](o);let _0x248046=_0x5ea16b['getCommentThread'](_0x51ed4c);const _0x277a78=_0x3a8994['config']['get']('collaboration.channelId'),_0x4b54bb=_0x3a8994['plugins']['get'](b);if(_0x248046&&(_0x248046['unlinkedAt']&&_0x248046['setUnlinkedAt'](null),_0x248046['isAttached']))return _0x248046;return!this['getAllMarkersForId'](_0x51ed4c)[0x0]['managedUsingOperations']?_0x3a8994['editing']['view']['once']('render',()=>{if(_0x5ea16b['getCommentThread'](_0x51ed4c))return;const _0x2f230f=_0x3a8994['plugins']['get'](y);_0x248046=_0x5ea16b['openNewCommentThread']({'channelId':_0x277a78,'threadId':_0x51ed4c,'target':()=>this['_getTargetForId'](_0x51ed4c),'context':{'type':'text','value':this['_getTextContext'](_0x51ed4c)}});const _0x306c76=_0x5ea16b['_threadToController']['get'](_0x248046)['view'],_0x35e167=_0x2f230f['getByInnerView'](_0x306c76);_0x35e167&&_0x4b54bb['registerAnnotation'](_0x35e167);},{'priority':'low'}):_0x5ea16b['fetchCommentThread']({'channelId':_0x277a78,'threadId':_0x51ed4c})['then'](_0x463e2e=>{if('destroyed'!==_0x3a8994['state']){if(_0x248046=_0x463e2e,_0x248046&&!_0x248046['isAttached']){const _0x4fecc7=_0x248046['attachTo'](()=>this['_getTargetForId'](_0x51ed4c));_0x4b54bb['registerAnnotation'](_0x4fecc7),_0x248046['isResolved']&&this['_reconvertMarkers'](_0x51ed4c);}else{if(!_0x248046){const _0x501219=this['getAllMarkersForId'](_0x51ed4c);_0x3a8994['model']['change'](_0x17fdbf=>{for(const _0x43747 of _0x501219)_0x17fdbf['removeMarker'](_0x43747);});}}}}),_0x248046;}['_handleThreadMarker'](_0x24e39f,_0xebc063){const _0x3a67e0=this['_attachMarkerToThread'](_0x24e39f,_0xebc063);_0x3a67e0&&!_0x3a67e0['context']&&_0x3a67e0['setContext']({'type':'text','value':this['_getTextContext'](_0xebc063)});}['_initAriaMarkerChangeAnnouncements'](){const _0x56a64b=this['editor'];rt(_0x56a64b['model'],({left:_0x4092f8,entered:_0x841be2})=>{for(const _0x58d2ea of _0x4092f8)if(mt(_0x58d2ea)){_0x56a64b['ui']['ariaLiveAnnouncer']['announce'](N(_0x56a64b['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x2ea8e3 of _0x841be2)if(mt(_0x2ea8e3)){_0x56a64b['ui']['ariaLiveAnnouncer']['announce'](N(_0x56a64b['locale'],'ENTER_COMMENT_ANNOUNCEMENT',tt(_0x253346)));break;}});}}function dt(_0xcc5a2a,_0x10feb9){return _0x10feb9?_0xcc5a2a+':'+_0x10feb9:_0xcc5a2a;}function ht(_0x3dbbe1,_0x4905b4){const _0x252b7c=_0x4905b4['schema'],_0x420faf=_0x4905b4['createRange'](_0x3dbbe1['start']);for(const _0x3dd4fc of _0x3dbbe1['getWalker']()){const {type:_0x18d680,item:_0x139571,nextPosition:_0x453fa8}=_0x3dd4fc;if('text'===_0x18d680||_0x252b7c['isObject'](_0x139571)){const _0x50895f=_0x4905b4['createPositionBefore'](_0x139571);_0x420faf['isCollapsed']&&(_0x420faf['start']=_0x50895f),_0x420faf['end']=_0x453fa8;}}return _0x420faf;}function mt(_0x5be3c1){return'comment'===ft(_0x5be3c1['name'])['group'];}class s extends _0x25b6bf{['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 _0x3242aa=this['editor'],_0x32f7e4=_0x3242aa['plugins']['get'](o),_0x3be2e4=_0x3242aa['plugins']['get'](r),_0x3f138d=_0x3242aa['plugins']['get'](y),_0x3cbeea=_0x3242aa['plugins']['get'](b);_0x3242aa['ui']['componentFactory']['add']('comment',()=>{const _0x30748b=this['_createUIButton'](_0xf18eca);return _0x30748b['tooltip']=!0x0,_0x30748b;}),_0x3242aa['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x892bd0)),_0x3cbeea['addSourceCollector'](()=>{const _0x548fd1=[];for(const [_0x4ec05a,_0x4243cc]of _0x32f7e4['_threadToController']){const _0x4a6834=_0x3be2e4['getAllMarkersForId'](_0x4ec05a['id']),_0x52e6c8=_0x4a6834['map'](_0x3ce8ca=>_0x3ce8ca['getRange']());_0x4a6834['length']>0x0&&_0x548fd1['push']([_0x4243cc['view'],_0x52e6c8]);}return _0x548fd1;}),this['listenTo'](_0x3f138d,'change:activeAnnotations',(_0x1193d2,_0x11fe4d,_0x4c5b23)=>{const _0x461a89=Array['from'](_0x4c5b23)['map'](_0x2a4d58=>_0x2a4d58['innerView'])['find'](_0x51a902=>_0x32f7e4['_viewToController']['has'](_0x51a902));if(!_0x461a89)return void(_0x3be2e4['activeMarker']=null);const _0x519d44=_0x32f7e4['_viewToController']['get'](_0x461a89)['model']['id'],_0x357e42='comment:'+_0x519d44;_0x519d44&&_0x3be2e4['hasMarkerForId'](_0x519d44)?_0x3be2e4['activeMarker']=_0x357e42:_0x3be2e4['activeMarker']&&(_0x3be2e4['activeMarker']=null);}),this['listenTo'](_0x32f7e4,'removeCommentThread',(_0x30dce3,{threadId:_0x199e8b,isFromAdapter:_0x21a844})=>{!_0x21a844&&_0x3242aa['ui']['focusTracker']['isFocused']&&_0x3be2e4['hasMarkerForId'](_0x199e8b)&&_0x3242aa['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x32f7e4,'addComment',(_0x35198d,{threadId:_0x5ada9c,isFromAdapter:_0x30caf6})=>{if(_0x30caf6||!_0x3be2e4['hasMarkerForId'](_0x5ada9c)||!_0x32f7e4['hasCommentThread'](_0x5ada9c))return;0x1===_0x32f7e4['getCommentThread'](_0x5ada9c)['length']&&(_0x3242aa['editing']['view']['focus'](),_0x35198d['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1e2b17=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2eb60e;for(const _0x1f1e3d in _0x1e2b17){const _0x28a7be=_0x1f1e3d,_0x23a4ed=_0x1e2b17[_0x28a7be];if('commentsLicenseKeyValid'==_0x23a4ed||'commentsLicenseKeyInvalid'==_0x23a4ed||'commentsLicenseKeyExpired'==_0x23a4ed||'commentsLicenseKeyDomainLimit'==_0x23a4ed||'commentsLicenseKeyNotAllowed'==_0x23a4ed||'commentsLicenseKeyEvaluationLimit'==_0x23a4ed||'commentsLicenseKeyUsageLimit'==_0x23a4ed){delete _0x1e2b17[_0x28a7be],_0x2eb60e=_0x23a4ed,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x2eb60e&&_0x1e2b17['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x2eb60e&&_0x1e2b17['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x2eb60e&&_0x1e2b17['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x2eb60e&&_0x1e2b17['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x2eb60e&&_0x1e2b17['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyUsageLimit'==_0x2eb60e&&_0x1e2b17['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x282969){const _0x2b6fcc=this['editor'],_0x487f37=new _0x282969(_0x2b6fcc['locale']),_0x324a39=_0x2b6fcc['commands']['get']('addCommentThread');return _0x487f37['set']({'label':N(_0x2b6fcc['locale'],'Comment'),'icon':_0x37d815}),_0x487f37['bind']('isEnabled')['to'](_0x324a39,'isEnabled',_0x324a39,'hasContent',(_0xf34cae,_0x3b27f4)=>_0xf34cae&&_0x3b27f4),this['listenTo'](_0x487f37,'execute',()=>{_0x324a39['execute']();}),_0x487f37;}}class i extends _0x25b6bf{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x37a65b){super(_0x37a65b),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x1d5a18,_0x396fad,_0x35e5bd)=>{_0x35e5bd?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x4cc22f,_0x350428]of this['editor']['commands'])_0x350428['affectsData']&&'addCommentThread'!==_0x4cc22f&&_0x350428['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('RevisionTracker'))&&this['editor']['plugins']['get']('RevisionTracker')['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x3a8751=this['editor']['editing']['view']['document'];this['listenTo'](_0x3a8751,'cut',_0x3c1694=>_0x3c1694['stop'](),{'priority':'highest'}),this['listenTo'](_0x3a8751,'clipboardInput',_0x214861=>_0x214861['stop'](),{'priority':'highest'}),this['listenTo'](_0x3a8751,'delete',_0x28405c=>_0x28405c['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x84fdbe,_0x406695]of this['editor']['commands'])_0x406695['affectsData']&&'addCommentThread'!==_0x84fdbe&&_0x406695['clearForceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['clearForceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['clearForceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['clearForceDisabled']('commentsOnlyMode'),this['stopListening'](this['editor']['editing']['view']['document']);}}class j extends _0x3110a5{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[y];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x59d8c8){super(_0x59d8c8),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0xc8b48f=this['context']['plugins']['get'](y);this['listenTo'](_0xc8b48f,'_activateAnnotation',(_0x51f023,_0x523c0e)=>{for(const _0x3ce35a of this['activeUIs']){const _0x2f0cac=this['_uis']['get'](_0x3ce35a);(0x0,this['uisData']['get'](_0x3ce35a)['filter'])(_0x523c0e)&&_0x2f0cac['setActiveAnnotation'](_0x523c0e);}}),this['listenTo'](_0xc8b48f,'_deactivateAllAnnotations',()=>{for(const _0x41ef90 of this['activeUIs']){this['_uis']['get'](_0x41ef90)['setActiveAnnotation'](null);}}),this['listenTo'](_0xc8b48f['_visibleAnnotations'],'add',(_0x589bc2,_0x5bd3d6)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x5bd3d6);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x402ae2){return this['activeUIs']['has'](_0x402ae2);}['activate'](_0x64f5ab,_0x1f14b3=this['defaultFilter']){const _0x388dd5=this['context']['plugins']['get'](y);if(!this['_uis']['has'](_0x64f5ab))throw new _0xd7b9fb('annotationsuis-missing-ui',this,{'uiName':_0x64f5ab});this['isActive'](_0x64f5ab)&&this['deactivate'](_0x64f5ab),this['activeUIs']['add'](_0x64f5ab);const _0x3647c2=new S();v({'source':_0x388dd5['_visibleAnnotations'],'target':_0x3647c2,'filter':_0x1f14b3}),this['uisData']['set'](_0x64f5ab,{'collection':_0x3647c2,'filter':_0x1f14b3});const _0x2176a3=this['_uis']['get'](_0x64f5ab);_0x2176a3['attach'](_0x3647c2),this['listenTo'](_0x2176a3,'change:activeAnnotation',(_0x165d9a,_0x3d5aed,_0x2c64fc,_0x13e29a)=>{_0x13e29a&&_0x388dd5['_removeActiveAnnotation'](_0x13e29a),_0x2c64fc&&_0x388dd5['_addActiveAnnotation'](_0x2c64fc);});}['deactivate'](_0x1759b8){if(this['activeUIs']['delete'](_0x1759b8),!this['_uis']['has'](_0x1759b8))throw new _0xd7b9fb('annotationsuis-missing-ui',this,{'uiName':_0x1759b8});const _0x37cf7a=this['_uis']['get'](_0x1759b8);_0x37cf7a['detach'](),this['stopListening'](_0x37cf7a),this['uisData']['get'](_0x1759b8)['collection']['destroy'](),this['uisData']['delete'](_0x1759b8);}['switchTo'](_0x1a6f50){if(!this['_uis']['has'](_0x1a6f50))throw new _0xd7b9fb('annotationsuis-missing-ui',this,{'uiName':_0x1a6f50});const _0x7e7b46=this['context']['plugins']['get'](y),_0x2d89be=Array['from'](_0x7e7b46['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x1a6f50);const _0x42f129=this['_uis']['get'](_0x1a6f50);_0x42f129['setActiveAnnotation'](_0x2d89be),_0x42f129['_setSelectedAnnotations']&&_0x2d89be&&_0x42f129['_setSelectedAnnotations']([_0x2d89be]);}['deactivateAll'](){for(const _0x41c606 of this['activeUIs'])this['deactivate'](_0x41c606);}['register'](_0x41306e,_0x49688b){if(this['_uis']['has'](_0x41306e))throw new _0xd7b9fb('annotationsuis-register-already-registered');if('function'!=typeof _0x49688b['attach']||'function'!=typeof _0x49688b['detach']||'function'!=typeof _0x49688b['setActiveAnnotation'])throw new _0xd7b9fb('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x41306e,_0x49688b);}['refilterAnnotations'](){const _0x1c7396=this['context']['plugins']['get'](y)['collection'],_0x44f626=new Map(),_0x5eba61=Array['from'](this['activeUIs']);for(const _0x8d628e of this['activeUIs']){const _0x5ae933=this['uisData']['get'](_0x8d628e)['collection'];for(const _0x108723 of _0x5ae933)_0x44f626['set'](_0x108723,_0x8d628e);}for(const _0x5e9d85 of _0x1c7396){const _0x392aee=_0x44f626['get'](_0x5e9d85);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x5e9d85);const _0x384a70=_0x5eba61['find'](_0x555549=>this['uisData']['get'](_0x555549)['filter'](_0x5e9d85));_0x392aee!==_0x384a70&&(_0x392aee&&this['uisData']['get'](_0x392aee)['collection']['remove'](_0x5e9d85),_0x384a70&&this['uisData']['get'](_0x384a70)['collection']['add'](_0x5e9d85));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x90c1d8){const _0x1844c8=[];for(const _0x5b3242 of this['activeUIs']){(0x0,this['uisData']['get'](_0x5b3242)['filter'])(_0x90c1d8)&&_0x1844c8['push'](_0x5b3242);}if(_0x1844c8['length']>0x1)throw new _0xd7b9fb('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x1844c8,'annotationType':_0x90c1d8['type']});}}const _i=/* #__PURE__ -- @preserve */
32
+ Ht('px');class H extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x2e126d){super(_0x2e126d);const _0x4734fb=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 _0x44f1cb(),this['focusCycler']=new _0x47d7f6({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x4734fb['to']('class')],'style':{'minHeight':_0x4734fb['to']('minHeight',_0x4f4e10=>'number'==typeof _0x4f4e10?_i(_0x4f4e10+0xa):null)},'dir':_0x2e126d['uiLanguageDirection'],'role':'application','aria-label':N(_0x2e126d,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':N(_0x2e126d,'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',_0xd9869=>{this['_updateItemPositionInFocusables'](_0xd9869['source']);}),this['list']['forEach'](_0x5b0356=>{this['focusTracker']['add'](_0x5b0356['element']),this['_updateItemPositionInFocusables'](_0x5b0356);}),this['list']['on']('change',(_0x10f06d,_0x3ecb0f)=>{for(const _0x1609f6 of _0x3ecb0f['removed'])this['focusTracker']['remove'](_0x1609f6['element']),this['focusables']['remove'](_0x1609f6);for(const _0x5bf3b8 of _0x3ecb0f['added'])this['focusTracker']['add'](_0x5bf3b8['element']),this['_updateItemPositionInFocusables'](_0x5bf3b8);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x17f78c){const _0x16bcfe=this['focusables']['getIndex'](_0x17f78c);let _0xc509a7,_0x336cd4;for(const _0x35d235 of this['focusables'])if(_0x17f78c['top']<_0x35d235['top']){_0xc509a7=_0x35d235;break;}if(_0x336cd4=_0xc509a7?this['focusables']['getIndex'](_0xc509a7):this['focusables']['length'],-0x1!==_0x16bcfe){if(_0x16bcfe===_0x336cd4-0x1)return;this['focusables']['remove'](_0x17f78c),_0x336cd4=_0xc509a7?this['focusables']['getIndex'](_0xc509a7):this['focusables']['length'];}this['focusables']['add'](_0x17f78c,_0x336cd4);}}const Ot=/* #__PURE__ -- @preserve */
33
+ Ht('px');class R extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x44363b){super(_0x44363b),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x2579a2,_0x41cc73)=>_0x2579a2+_0x41cc73),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x38efa1=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x38efa1['to']('isAnimationDisabled',_0x5e3a72=>_0x5e3a72?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x38efa1['to']('top',_0x6db3aa=>Ot(_0x6db3aa))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x3c8844=this['element']['clientHeight'];_0x3c8844&&(this['height']=_0x3c8844);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x3110a5{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x197c2c){super(_0x197c2c),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 _0x579482=this['context']['config']['get']('sidebar.container');_0x579482&&this['setContainer'](_0x579482);}['setContainer'](_0x5d80ce){if(!g(_0x5d80ce))throw new _0xd7b9fb('sidebar-setcontainer-invalid-element');this['container']=_0x5d80ce;}['_attachToContainer']({viewClass:_0x1a8285='',spaceBetweenItems:_0x4a3cf6=0x19}={}){if(!g(this['container']))throw new _0xd7b9fb('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x1a8285,this['_spaceBetweenItems']=_0x4a3cf6;}['rearrange']({removedAnnotation:_0x35b3ec,previousAnnotation:_0x5d02cc,nextAnnotation:_0x302c5e}){const _0x5093ab=this['getSidebarItemView'](_0x35b3ec);this['view']['list']['remove'](_0x5093ab),this['_destroySidebarItemView'](_0x35b3ec),_0x5d02cc&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x5d02cc)),_0x302c5e&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x302c5e)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x1b3de8,activatedAnnotation:_0x95bbc2,disableAnimationOnActivatedAnnotation:_0x2d019a}){if(this['_activeAnnotation']=_0x95bbc2,_0x1b3de8){_0x1b3de8['isActive']=!0x1;const _0x347b2d=this['getSidebarItemView'](_0x1b3de8);_0x347b2d&&_0x2d019a&&(_0x347b2d['isAnimationDisabled']=!0x1);}if(_0x95bbc2){const _0x12f8c7=this['getSidebarItemView'](_0x95bbc2);_0x12f8c7&&(_0x95bbc2['isActive']=!0x0,_0x2d019a&&(_0x12f8c7['isAnimationDisabled']=!0x0,_0x12f8c7['top']+=0x1),this['_alignToTargetRect'](_0x12f8c7));}}['_detachFromContainer'](_0x3ccb0e){if(this['view']['element']['remove'](),_0x3ccb0e){for(const _0x43226e of _0x3ccb0e)this['_destroySidebarItemView'](_0x43226e);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x231ab1,_0x2387ff){_0x2387ff||(_0x2387ff=_0x231ab1['view']);const _0x1975f2=new R(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x1975f2,_0x231ab1),this['_annotationToSidebarItemView']['set'](_0x231ab1,_0x1975f2),_0x1975f2['content']['add'](_0x2387ff),this['listenTo'](_0x231ab1['view'],'change:targetRect',(_0x47bac7,_0x27aac6,_0x6b70ed)=>{const _0x28350c=this['_getTargetTop'](_0x231ab1,_0x6b70ed);_0x1975f2['_targetTop']!=_0x28350c&&(_0x1975f2['_targetTop']=_0x28350c,this['_setItemTop'](_0x1975f2,_0x28350c));}),this['listenTo'](_0x1975f2,'change:top',()=>{this['_recalculate'](_0x1975f2,'top');}),this['listenTo'](_0x1975f2,'change:bottom',()=>{this['_recalculate'](_0x1975f2,'bottom');}),this['_alignToTargetRect'](_0x1975f2);const _0x5a8822=this['_getItemBefore'](_0x1975f2);if(_0x5a8822)this['_alignAfterItem'](_0x5a8822,_0x1975f2)||this['_alignToTargetRect'](_0x1975f2);else this['_alignToTargetRect'](_0x1975f2);return this['_updateLastItem'](),this['view']['list']['add'](_0x1975f2),_0x1975f2;}['_alignForTopChange'](_0x9b631b){if(!_0x9b631b['content']['length'])return;const _0xb2e88e=this['_getItemBefore'](_0x9b631b);if(!_0xb2e88e)return;const _0x13d524=this['_sidebarItemViewToAnnotation']['get'](_0xb2e88e),_0x3f1dac=this['_activeAnnotation'];_0x3f1dac&&_0x3f1dac===_0x13d524?this['_alignAfterItem'](_0xb2e88e,_0x9b631b):this['_alignBeforeItem'](_0x9b631b,_0xb2e88e);}['_alignForBottomChange'](_0x2e35b1){if(!_0x2e35b1['content']['length'])return;const _0x17f06d=this['_getItemAfter'](_0x2e35b1);if(!_0x17f06d)return;const _0x55b86d=this['_sidebarItemViewToAnnotation']['get'](_0x17f06d),_0x5f2cc6=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0xe8a1e0=this['_activeAnnotation'];_0xe8a1e0&&_0xe8a1e0===_0x55b86d&&_0x5f2cc6?(this['_alignBeforeItem'](_0x17f06d,_0x2e35b1),this['_alignAfterItem'](_0x2e35b1,_0x17f06d)):_0xe8a1e0&&_0xe8a1e0===_0x55b86d?this['_alignBeforeItem'](_0x17f06d,_0x2e35b1):this['_alignAfterItem'](_0x2e35b1,_0x17f06d);}['_recalculate'](_0x18116c,_0x16e077){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x5369ff,changedProp:_0x3ef740}of this['_recalculateBuffer'])'top'===_0x3ef740?this['_alignForTopChange'](_0x5369ff):this['_alignForBottomChange'](_0x5369ff);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x18116c,'changedProp':_0x16e077});}['getSidebarItemView'](_0x1ffbc1){return this['_annotationToSidebarItemView']['get'](_0x1ffbc1);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x4e6a89){const _0x230155=this['getSidebarItemView'](_0x4e6a89);this['stopListening'](_0x230155),this['stopListening'](_0x4e6a89['view']),_0x230155['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x4e6a89),this['_sidebarItemViewToAnnotation']['delete'](_0x230155);}['_createSidebarView'](){const _0x5c3c9a=new H(this['context']['locale']);return _0x5c3c9a['render'](),this['on']('change:_lastItem',(_0x451bfd,_0x28082a,_0x2003f7,_0x2cbec4)=>{_0x2cbec4&&_0x5c3c9a['unbind']('minHeight'),_0x2003f7?_0x5c3c9a['bind']('minHeight')['to'](_0x2003f7,'bottom'):_0x5c3c9a['minHeight']=null;}),_0x5c3c9a;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x4d7b34){const _0x151f1e=this['_sidebarItemViewToAnnotation']['get'](_0x4d7b34),_0x142b33=_0x151f1e&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x151f1e)-0x1);return _0x142b33&&this['getSidebarItemView'](_0x142b33)||null;}['_getItemAfter'](_0x35f9a2){const _0x1a7edc=this['_sidebarItemViewToAnnotation']['get'](_0x35f9a2),_0x233ec8=_0x1a7edc&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x1a7edc)+0x1);return _0x233ec8&&this['getSidebarItemView'](_0x233ec8)||null;}['_alignBeforeItem'](_0x3f4c71,_0x57902c){_0x3f4c71['updateHeight']();const _0x4f8008=G(_0x57902c['bottom']+this['_spaceBetweenItems'],_0x3f4c71['top']);return!!_0x4f8008&&(this['_setItemTop'](_0x57902c,_0x57902c['top']-_0x4f8008),!0x0);}['_alignAfterItem'](_0x3e61ae,_0x61048f){_0x3e61ae['updateHeight']();const _0x11427f=G(_0x3e61ae['bottom']+this['_spaceBetweenItems'],_0x61048f['top']);return!!_0x11427f&&(this['_setItemTop'](_0x61048f,_0x61048f['top']+_0x11427f,!0x1),!0x0);}['_alignToTargetRect'](_0x5293d7){const _0x35336b=this['_sidebarItemViewToAnnotation']['get'](_0x5293d7);if(!_0x35336b||!_0x35336b['target']||!_0x35336b['targetRect'])return;const _0x48b8b7=this['_getTargetTop'](_0x35336b,_0x35336b['targetRect']);this['_setItemTop'](_0x5293d7,_0x48b8b7);}['_getTargetTop'](_0x1aa000,_0x2e3813){if(null===_0x2e3813)return 0x0;if(_0x1aa000['target']instanceof _0x375970)return _0x2e3813['top'];{const _0x1c77fe=new _0x375970(this['view']['element'])['top'];return _0x2e3813['top']-_0x1c77fe;}}['_setItemTop'](_0x51ed18,_0x507b32,_0x35b627=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x35b627&&(_0x507b32=Math['max'](_0x507b32,this['_getMaxAvailableTop'](_0x51ed18))),_0x51ed18['top']=_0x507b32;}['_getMaxAvailableTop'](_0x40ab2a){let _0x1f40c5=this['_getItemBefore'](_0x40ab2a),_0x30595e=0x0;for(;_0x1f40c5;)_0x1f40c5['updateHeight'](),_0x30595e+=this['_spaceBetweenItems']+_0x1f40c5['height'],_0x1f40c5=this['_getItemBefore'](_0x1f40c5);return _0x30595e;}}function G(_0x5ae92f,_0x408ef5){return Math['max'](_0x5ae92f-_0x408ef5,0x0);}function g(_0x3579fd){return null!==_0x3579fd&&'object'==typeof _0x3579fd&&0x1===_0x3579fd['nodeType'];}class e extends _0x3110a5{['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(_0x1436ec){super(_0x1436ec),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x4fc713(),this['_refreshPositioningDebounced']=_0x46ba7a(()=>{_0x1436ec['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x712bc6=this['context']['plugins']['get'](j),_0x4cf60d=this['context']['plugins']['get'](z);_0x712bc6['register']('wideSidebar',this),_0x4cf60d['container']&&_0x712bc6['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x228581){if(_0x228581===this['activeAnnotation'])return;const _0x4aa3e1=this['context']['plugins']['get'](z);_0x4aa3e1['_activeAnnotation']=_0x228581;const _0x18795c=this['activeAnnotation'];_0x4aa3e1['refresh']({'blurredAnnotation':_0x18795c,'activatedAnnotation':_0x228581}),this['activeAnnotation']=_0x228581;}['attach'](_0x24c1b2){this['annotations']=_0x24c1b2;const _0x541250=this['context']['plugins']['get'](z);if(_0x541250['_annotations']=_0x24c1b2,this['isAttached'])throw new _0xd7b9fb('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x541250,'set:container',()=>{this['detach'](),this['listenTo'](_0x541250,'change:container',_0x43d9be=>{_0x43d9be['off'](),this['attach'](_0x24c1b2);});}),_0x541250['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x183a8d=_0x45baa5=>{_0x45baa5['updateTargetRect'](),_0x541250['addAnnotation'](_0x45baa5);};for(const _0x24e05a of _0x24c1b2)_0x183a8d(_0x24e05a);this['listenTo'](_0x24c1b2,'add',(_0x89d3b8,_0x592c5a)=>{_0x183a8d(_0x592c5a);}),this['listenTo'](_0x24c1b2,'remove',(_0x4b96f5,_0x5c7385,_0x136760)=>{_0x541250['rearrange']({'removedAnnotation':_0x5c7385,'previousAnnotation':_0x24c1b2['get'](_0x136760-0x1),'nextAnnotation':_0x24c1b2['get'](_0x136760+0x1)}),_0x5c7385===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x24c1b2,'focus',(_0x301c57,_0x3857e4)=>{this['setActiveAnnotation'](_0x3857e4);}),this['listenTo'](_0x24c1b2,'blur',()=>{this['setActiveAnnotation'](null);});const _0x4afccc=this['context']instanceof _0x1726b6?this['context']['editors']:new _0x4fc713([this['context']]);for(const _0x159a4b of _0x4afccc)this['_integrateWithEditorAnnotations'](_0x159a4b);this['listenTo'](_0x4afccc,'add',(_0x167cca,_0x4d73c3)=>{this['listenTo'](_0x4d73c3,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x4d73c3);});}),this['listenTo'](_0x4afccc,'remove',(_0x55e3c3,_0x373694)=>{_0x373694['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x373694['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0xd7b9fb('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x4961f3=this['context']['plugins']['get'](z);_0x4961f3['_detachFromContainer'](this['annotations']),this['stopListening'](_0x4961f3),this['stopListening'](this['annotations']),this['context']instanceof _0x1726b6&&this['stopListening'](this['context']['editors']);for(const _0x567a39 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x567a39);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x213e02){if(!_0x213e02['plugins']['has']('EditorAnnotations'))return;const _0x2bd7f1=_0x213e02['plugins']['get']('EditorAnnotations'),_0x1a7d8b=()=>{const _0x1a6f84=_0x2bd7f1['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x1a6f84[0x0]||null);};this['listenTo'](_0x2bd7f1,'refresh',_0x1a7d8b),this['listenTo'](_0x2bd7f1,'blur',(_0x19fd87,{isAnnotationTracked:_0x2a016d})=>{this['activeAnnotation']&&_0x2a016d(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x2bd7f1,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x1a5c11=>{_0x2bd7f1['hasDomSelection']()&&(_0x1a7d8b(),_0x1a5c11['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x2bd7f1);}['_destroyEditorAnnotationsIntegration'](_0x4a15db){this['stopListening'](_0x4a15db),this['_editorAnnotations']['remove'](_0x4a15db);}}class C extends _0xf18eca{['counterView'];constructor(_0x248446){super(_0x248446);const _0x334357=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0xc7ef35,_0x58dbd2)=>_0xc7ef35?'...':_0x58dbd2['toString']()),this['set']('annotationType',''),this['icon']=_0x37d815,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x334357['to']('annotationType',_0x1b7682=>'ck-annotation-counter__badge--'+_0x1b7682),_0x334357['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x334357['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x3110a5{['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(_0x297def){super(_0x297def),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x68bcfd())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x4fc713(),this['_refreshPositioningDebounced']=_0x46ba7a(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](j)['register']('narrowSidebar',this),this['bodyCollection']=new _0x9a194a(this['context']['locale']),this['balloonPanelView']=new _0x484888(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0xcbbac1){this['annotations']=_0xcbbac1;const _0x15781f=this['context']['plugins']['get'](z),_0x56d79b=this['balloonPanelView'];if(_0x15781f['_annotations']=_0xcbbac1,this['isAttached'])throw new _0xd7b9fb('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x15781f,'set:container',()=>{this['detach'](),this['listenTo'](_0x15781f,'change:container',_0x4083fc=>{_0x4083fc['off'](),this['attach'](_0xcbbac1);});}),_0x15781f['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0xc8afde=_0x312bec=>{const _0x2a489a=new C(this['context']['locale']);_0x15781f['addAnnotation'](_0x312bec,_0x2a489a),this['_annotationToNarrowView']['set'](_0x312bec,_0x2a489a),_0x2a489a['bind']('isDirty','annotationType','number')['to'](_0x312bec['view'],'isDirty','type','length'),_0x2a489a['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x56d79b['content']['first']!==_0x312bec['view']?(this['_showBalloon'](_0x312bec),_0x312bec['view']['element']['focus'](),this['setActiveAnnotation'](_0x312bec)):this['setActiveAnnotation'](null);});};for(const _0x467bc3 of _0xcbbac1)_0xc8afde(_0x467bc3);this['listenTo'](_0xcbbac1,'add',(_0x270c2d,_0x535165)=>{_0xc8afde(_0x535165);}),this['listenTo'](_0xcbbac1,'remove',(_0x50d3da,_0x40724f,_0x43deb3)=>{this['_annotationToNarrowView']['get'](_0x40724f)['destroy'](),this['_annotationToNarrowView']['delete'](_0x40724f),_0x15781f['rearrange']({'removedAnnotation':_0x40724f,'previousAnnotation':_0xcbbac1['get'](_0x43deb3-0x1),'nextAnnotation':_0xcbbac1['get'](_0x43deb3+0x1)}),_0x40724f===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0xcbbac1,'focus',(_0x2ca35d,_0x509773)=>{this['setActiveAnnotation'](_0x509773);}),this['listenTo'](_0xcbbac1,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0xe55731,_0x396955)=>{_0x396955['keyCode']===_0x5eb4f3['esc']&&_0x56d79b['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x56d79b['content']['first']),this['_hideBalloon'](),_0x396955['stopPropagation'](),_0x396955['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x338b63,_0x209c2c)=>{const _0x560561=_0x209c2c['target'];_0x56d79b['isVisible']&&_0x56d79b['element']['contains'](_0x560561)||_0x15781f['view']['element']['contains'](_0x560561)||_0x338b63['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x1cdb78=>_0x1cdb78['contains'](_0x560561))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x4c96dc=this['context']instanceof _0x1726b6?this['context']['editors']:new _0x4fc713([this['context']]);for(const _0x4cf2fe of _0x4c96dc)this['_integrateWithEditorAnnotations'](_0x4cf2fe);this['listenTo'](_0x4c96dc,'add',(_0x1af139,_0x5c7ee4)=>{this['listenTo'](_0x5c7ee4,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x5c7ee4);});}),this['listenTo'](_0x4c96dc,'remove',(_0x59a424,_0x8cd9a0)=>{_0x8cd9a0['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x8cd9a0['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x42a05b){if(_0x42a05b===this['activeAnnotation'])return;const _0x3b2539=this['context']['plugins']['get'](z);if(_0x3b2539['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x42a05b,'disableAnimationOnActivatedAnnotation':!0x0}),_0x42a05b)_0x3b2539['getSidebarItemView'](_0x42a05b)?this['_showBalloon'](_0x42a05b):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x42a05b;}['detach'](){if(!this['isAttached'])throw new _0xd7b9fb('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x1f7320=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x1bb618=>_0x1bb618['destroy']()),this['_annotationToNarrowView']['clear'](),_0x1f7320['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x1726b6&&this['stopListening'](this['context']['editors']);for(const _0xb3ac51 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0xb3ac51);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'](_0x364b9d){if(!_0x364b9d['plugins']['has']('EditorAnnotations'))return;const _0x76e307=_0x364b9d['plugins']['get']('EditorAnnotations'),_0x590b05=this['context']['plugins']['get'](z),_0x1d9aee=this['annotations'],_0x57ebbf=this['balloonPanelView'],_0x2b6739=()=>{const _0x6034f5=_0x76e307['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x6034f5),this['setActiveAnnotation'](_0x6034f5[0x0]||null);};this['listenTo'](_0x76e307,'refresh',_0x2b6739),this['listenTo'](_0x76e307,'blur',(_0x26c520,{isAnnotationTracked:_0x20a093})=>{this['activeAnnotation']&&_0x20a093(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x76e307,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x1d9aee,'blur',_0x38b620=>{_0x76e307['hasDomSelection']()&&_0x38b620['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x4ee73f,_0x304982)=>{const _0x4e0436=_0x304982['target'];_0x57ebbf['isVisible']&&_0x57ebbf['element']['contains'](_0x4e0436)||_0x590b05['view']['element']['contains'](_0x4e0436)||this['activeAnnotation']&&_0x76e307['hasDomSelection']()&&(_0x2b6739(),_0x4ee73f['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x76e307);}['_destroyEditorAnnotationsIntegration'](_0x145d81){_0x145d81&&(this['stopListening'](_0x145d81),this['_editorAnnotations']['remove'](_0x145d81));}['_setSelectedAnnotations'](_0x12370a){for(const _0x151600 of this['_selectedAnnotations'])_0x12370a['includes'](_0x151600)||this['_manuallyClosedAnnotationViews']['delete'](_0x151600['view']);this['_selectedAnnotations']=_0x12370a;}['_refreshPositioning'](){const _0x45ac8b=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x45ac8b['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x8d88b4){if(this['_manuallyClosedAnnotationViews']['has'](_0x8d88b4['view']))return;const _0x4e9d51=this['balloonPanelView']['content']['first'];_0x4e9d51!==_0x8d88b4['view']?(_0x4e9d51&&this['_detachListeners'](_0x4e9d51),this['_attachListeners'](_0x8d88b4['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x8d88b4['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x56af15=this['balloonPanelView']['content']['first'],_0x5e973a=_0x56af15&&this['annotations']['getByView'](_0x56af15);if(!_0x5e973a||!this['_annotationToNarrowView']['has'](_0x5e973a))return;const _0x1e3678=this['_annotationToNarrowView']['get'](_0x5e973a)['element'],_0x2f0f76=(function(){const _0x4631f1=_0x484888['defaultPositions'];return[_0x4631f1['southArrowNorthEast'],_0x4631f1['northArrowSouthEast'],_0x4631f1['southArrowNorth'],_0x4631f1['northArrowSouth'],_0x4631f1['southArrowNorthWest'],_0x4631f1['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x1e3678,'positions':_0x2f0f76});}['_hideBalloon'](){const _0x573047=this['balloonPanelView'],_0x2c6677=_0x573047['content']['first'];_0x2c6677&&(this['_detachListeners'](_0x2c6677),_0x573047['unpin'](),_0x573047['content']['clear']());}['_attachListeners'](_0x1d5ad2){this['listenTo'](_0x1d5ad2,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x1d5ad2,'Esc',(_0x29350b,_0x5b40a3)=>{this['_manuallyClosedAnnotationViews']['add'](_0x1d5ad2),this['_hideBalloon'](),_0x5b40a3();});}['_detachListeners'](_0x16a1b6){this['stopListening'](_0x16a1b6);}}class c extends _0x25b6bf{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];['_refreshVisibilityDebounced'];static get['requires'](){return[b,_0x4ecb9d,j];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x18f7f0){super(_0x18f7f0),_0x18f7f0['editing']['view']['addObserver'](_0x5956f6),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x18f7f0['plugins']['get'](_0x4ecb9d),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1,this['_refreshVisibilityDebounced']=_0x46ba7a(()=>{this['editor']['plugins']['get']('Annotations')['refreshVisibility']();},0xfa,{'leading':!0x1});}['init'](){const _0x49d4da=this['editor']['plugins']['get'](j);_0x49d4da['context']===this['editor']&&(_0x49d4da['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x1235e6,_0xbdb525)=>{const _0x400491=this['_balloon'];if(this['isAttached']&&_0x400491['visibleView']){const _0x541b6e=this['annotations']['getByView'](_0x400491['visibleView']);_0x541b6e&&this['_closeAnnotation'](_0x541b6e),_0xbdb525();}}));}['afterInit'](){const _0x1c7977=this['editor']['plugins']['get'](j);_0x1c7977['context']===this['editor']&&(_0x1c7977['hasActive']()||_0x1c7977['switchTo']('inline'));}['setActiveAnnotation'](_0x5740b4){_0x5740b4!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x5740b4&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x5740b4)&&this['_addAnnotationToBalloon'](_0x5740b4,!0x0),_0x5740b4['isActive']=!0x0),_0x5740b4||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x5740b4);}['attach'](_0x136906){this['annotations']=_0x136906;const _0x10ccd1=this['editor']['plugins']['get'](j),_0xb50f3e=this['_balloon'];if(this['isAttached'])throw new _0xd7b9fb('inlineannotations-attach-already-attached',this);if(_0x10ccd1['context']!==this['editor'])throw new _0xd7b9fb('inlineannotations-not-allowed-with-context',this);const _0xa65b31=this['editor']['plugins']['get'](b);this['listenTo'](_0xa65b31,'refresh',()=>{const _0x2bd376=_0xa65b31['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x2d3a84,_0x19e841;!this['_forceRefresh']&&(_0x2d3a84=_0x2bd376,_0x19e841=this['_selectedAnnotations'],_0x2d3a84['length']===_0x19e841['length']&&_0x2d3a84['every'](_0x5ad500=>_0x19e841['includes'](_0x5ad500)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x2bd376),this['setActiveAnnotation'](_0x2bd376[0x0]||null));}),this['listenTo'](_0xa65b31,'blur',(_0x469486,{isAnnotationTracked:_0x1431cb})=>{this['activeAnnotation']&&_0x1431cb(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0xa65b31,'uiUpdate',()=>{this['_refreshVisibilityDebounced']();}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x2b7f40,_0x2b3ba3,_0x3e53bd)=>{_0x3e53bd||this['setActiveAnnotation'](null);}),this['listenTo'](_0x136906,'remove',(_0x5b01e7,_0x1caf4b)=>{this['_removeAnnotationFromBalloon'](_0x1caf4b),_0x1caf4b===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0xb50f3e,'change:visibleView',(_0x5b210e,_0x503413,_0x40b127,_0x29bce3)=>{_0x29bce3&&this['stopListening'](_0x29bce3);const _0xe59c50=_0x136906['getByView'](_0x40b127);_0x40b127&&_0xe59c50&&(this['listenTo'](_0x40b127,'change:height',()=>{_0xb50f3e['updatePosition']();}),this['listenTo'](_0x40b127,'Esc',()=>{this['_closeAnnotation'](_0xe59c50),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0xe59c50&&this['setActiveAnnotation'](_0xe59c50));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0xb50f3e['visibleView']&&(_0x136906['getByView'](_0xb50f3e['visibleView'])&&_0xb50f3e['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 _0xd7b9fb('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x1a0909 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x1a0909);this['_refreshVisibilityDebounced']['cancel'](),this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['_refreshVisibilityDebounced']['cancel']();}['_setSelectedAnnotations'](_0x2e630a){for(const _0x4b0591 of this['_selectedAnnotations'])_0x2e630a['includes'](_0x4b0591)||this['_manuallyClosed']['delete'](_0x4b0591);for(const _0x5bfcaa of this['annotations'])_0x2e630a['includes'](_0x5bfcaa)||this['_removeAnnotationFromBalloon'](_0x5bfcaa);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x2afd76 of _0x2e630a)this['_addAnnotationToBalloon'](_0x2afd76);}this['_selectedAnnotations']=_0x2e630a;}['_addAnnotationToBalloon'](_0x192242,_0x353cb6=!0x1){this['_manuallyClosed']['has'](_0x192242)||(this['_addedAnnotations']['has'](_0x192242)||this['_balloon']['hasView'](_0x192242['view'])||(this['_addedAnnotations']['add'](_0x192242),this['_balloon']['add']({'stackId':_0x192242['view']['id'],'view':_0x192242['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x192242)}})),_0x353cb6&&this['_balloon']['showStack'](_0x192242['view']['id']));}['_getBalloonTargetForAnnotation'](_0xf31349){const _0x2d2c7e=_0xf31349['target'],_0x3997f1=this['editor']['editing']['view'],_0x5668ee=_0x3997f1['document']['selection']['getFirstRange'](),_0x4e7a97=_0x3997f1['domConverter']['viewRangeToDom'](_0x5668ee);if(_0x4e7a97['collapse'](!0x0),_0x2d2c7e){if(_0x2d2c7e instanceof _0x375970)return _0x2d2c7e;let _0x2ea9fb=[];for(const _0x5e0c31 of _0x2d2c7e)_0x2ea9fb['push'](...F(_0x5e0c31['getClientRects']()));_0x2ea9fb=function(_0x20816b){const _0x57e013=[];let _0x2cf40b=_0x20816b[0x0];for(let _0x58021f=0x1;_0x58021f<_0x20816b['length'];_0x58021f++)P(_0x2cf40b,_0x20816b[_0x58021f])?_0x2cf40b['width']+=_0x20816b[_0x58021f]['width']:(_0x57e013['push'](_0x2cf40b),_0x2cf40b=_0x20816b[_0x58021f]);return _0x57e013['push'](_0x2cf40b),_0x57e013;}(_0x2ea9fb);const _0x1f1a78=_0x4e7a97['getBoundingClientRect']();return _0x2ea9fb['find'](_0x21ef89=>_0x21ef89['top']<=_0x1f1a78['top']&&_0x21ef89['bottom']>=_0x1f1a78['bottom']&&_0x21ef89['left']<=_0x1f1a78['left']&&_0x21ef89['right']>=_0x1f1a78['right'])||_0x2ea9fb[0x0];}return _0xf31349['targetRect']||_0x4e7a97;}['_removeAnnotationFromBalloon'](_0xa02175){this['_addedAnnotations']['has'](_0xa02175)&&this['_balloon']['hasView'](_0xa02175['view'])&&(this['_addedAnnotations']['delete'](_0xa02175),this['_balloon']['remove'](_0xa02175['view']));}['_closeAnnotation'](_0x29345d){this['_manuallyClosed']['add'](_0x29345d),this['_removeAnnotationFromBalloon'](_0x29345d);}}function F(_0x368d1d){return Array['from'](_0x368d1d)['map'](DOMRect['fromRect']);}function P(_0x4003b2,_0x567b16){return _0x4003b2['top']===_0x567b16['top']&&_0x4003b2['bottom']===_0x567b16['bottom']&&_0x4003b2['right']===_0x567b16['left'];}class Z extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x306776,_0x2e021f){super(_0x306776),this['set']('isEmpty',!_0x2e021f['length']),this['focusTracker']=new _0x44f1cb(),this['_annotationViews']=_0x2e021f,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x47d7f6({'focusables':_0x2e021f,'focusTracker':this['focusTracker']}),this['listenTo'](_0x2e021f,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x2e021f,'remove',(_0x8634f9,_0x7d3472)=>{_0x7d3472['isActive']&&this['focus'](),_0x2e021f['length']||(this['isEmpty']=!0x0);});const _0x43c182=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':N(_0x306776,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x2e021f},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x43c182['if']('isEmpty','ck-hidden',_0x5b3e3e=>!_0x5b3e3e)]},'children':[{'text':N(_0x306776,'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 _0x317cba of this['_annotationViews'])this['focusTracker']['add'](_0x317cba['element']);this['_annotationViews']['on']('change',(_0x2e601b,{added:_0x1802a0,removed:_0x466e8d})=>{for(const _0x5d1ae5 of _0x1802a0)this['focusTracker']['add'](_0x5d1ae5['element']);for(const _0x43e53b of _0x466e8d)this['focusTracker']['remove'](_0x43e53b['element']);});}}class p extends _0x3110a5{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,y];}constructor(_0x5f3fa2){super(_0x5f3fa2),this['archivedThreads']=new _0x4fc713();}['init'](){const _0x4faa33=this['context'],_0x267673=_0x4faa33['plugins']['get'](o),_0x35fb3d=_0x4faa33['plugins']['get'](y);this['listenTo'](_0x267673,'addCommentThread',(_0x111dde,{threadId:_0x3fd50f})=>{const _0x26ddec=_0x267673['getCommentThread'](_0x3fd50f);_0x26ddec['archivedAt']&&this['archivedThreads']['add'](_0x26ddec,this['_calculatePosition'](_0x26ddec['archivedAt'])),this['listenTo'](_0x26ddec,'change:archivedAt',(_0x2e0be2,_0x2a3e5a,_0x3bc5ab)=>{_0x3bc5ab?this['archivedThreads']['has'](_0x26ddec)||this['archivedThreads']['add'](_0x26ddec,this['_calculatePosition'](_0x26ddec['archivedAt'])):this['archivedThreads']['has'](_0x26ddec)&&this['archivedThreads']['remove'](_0x26ddec);});}),this['listenTo'](_0x267673,'removeCommentThread',(_0x23c0c4,{threadId:_0x1d3e81})=>{const _0xb673b0=_0x267673['getCommentThread'](_0x1d3e81);this['stopListening'](_0xb673b0),this['archivedThreads']['has'](_0xb673b0)&&this['archivedThreads']['remove'](_0xb673b0);},{'priority':'highest'}),this['listenTo'](_0x35fb3d['collection'],'focus',(_0x1522bf,_0x318a9d)=>{_0x318a9d['isVisible']||(_0x318a9d['isActive']=!0x0,_0x35fb3d['activate'](_0x318a9d));});}['_calculatePosition'](_0x7937e7){const _0x5c8387=[...this['archivedThreads']]['findIndex'](_0x15cefd=>_0x15cefd['archivedAt']<_0x7937e7);return _0x5c8387>-0x1?_0x5c8387:this['archivedThreads']['length'];}}class a extends _0x25b6bf{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[p,_0x57a2d7];}constructor(_0x16f4b2){super(_0x16f4b2),this['annotationViews']=new _0x9ecf0b(),this['_pendingThreads']=[];}['init'](){const _0xb8cb61=this['editor'],_0x951ae7=this['_hideDialogOnAnnotationEscape']['bind'](this);_0xb8cb61['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0xf18eca,!0x0)),_0xb8cb61['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x2fb8f9=this['_createCommentsArchiveButton'](_0x892bd0);return _0x2fb8f9['set']({'role':'menuitemcheckbox'}),_0x2fb8f9;});const _0x219cad=_0xb8cb61['plugins']['get'](p),_0x15757c=_0xb8cb61['plugins']['get']('Annotations'),_0x205419=_0xb8cb61['plugins']['get']('CommentsRepository');_0x219cad['archivedThreads']['forEach'](_0x531882=>{this['_handleNewThread'](_0x531882);}),this['listenTo'](_0x219cad['archivedThreads'],'add',(_0x4b04fc,_0x2f2976)=>{this['_handleNewThread'](_0x2f2976);}),this['listenTo'](_0x15757c['collection'],'add',(_0x4ba2b5,_0x417fab)=>{const _0x41eafc=this['_pendingThreads']['find'](_0x5c5a17=>{const _0x4f56c5=_0x205419['_threadToController']['get'](_0x5c5a17);return _0x4f56c5&&_0x417fab['innerView']===_0x4f56c5['view'];});if(_0x41eafc){const _0x46c167=this['_calculatePosition'](_0x41eafc['archivedAt']);this['_addAnnotationToArchive'](_0x417fab,_0x46c167),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x41eafc),0x1);}}),this['listenTo'](_0x219cad['archivedThreads'],'remove',(_0x2b963b,_0xddd1d2)=>{const _0x1e27bc=_0xb8cb61['config']['get']('collaboration.channelId');if(!_0x1e27bc||_0xddd1d2['channelId']===_0x1e27bc){if(this['_pendingThreads']['includes'](_0xddd1d2))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0xddd1d2),0x1);else{const _0x1b39a8=_0x205419['_threadToController']['get'](_0xddd1d2),_0x44a12a=_0x15757c['getByInnerView'](_0x1b39a8['view']);this['annotationViews']['remove'](_0x44a12a['view']),this['stopListening'](_0x44a12a),this['stopListening'](_0x44a12a['focusableElements']);}}}),this['listenTo'](_0x15757c['collection'],'add',(_0x44a821,_0x1d0422)=>{this['listenTo'](_0x1d0422,'escape',_0x951ae7);}),this['listenTo'](_0x15757c['collection'],'remove',(_0x1753e0,_0x1a4328)=>{this['stopListening'](_0x1a4328,'escape',_0x951ae7);});}['_addAnnotationToArchive'](_0x5bd55f,_0x1d62c4){this['listenTo'](_0x5bd55f,'set:isVisible',_0xc2cf62=>{_0xc2cf62['return']=!0x1,_0xc2cf62['stop']();}),this['annotationViews']['add'](_0x5bd55f['view'],_0x1d62c4);}['_handleNewThread'](_0x233204){const _0x101a6f=this['editor']['plugins']['get']('CommentsRepository'),_0x456b52=this['editor']['plugins']['get']('Annotations'),_0x4ae842=this['editor']['config']['get']('collaboration.channelId');if(!_0x4ae842||_0x233204['channelId']===_0x4ae842){const _0xcd1483=_0x101a6f['_threadToController']['get'](_0x233204);if(!_0xcd1483)return void this['_pendingThreads']['push'](_0x233204);const _0x434ee9=this['_calculatePosition'](_0x233204['archivedAt']),_0x4e4dff=_0x456b52['getByInnerView'](_0xcd1483['view']);_0x4e4dff['isVisible']&&_0x456b52['_visibleAnnotations']['remove'](_0x4e4dff),this['_addAnnotationToArchive'](_0x4e4dff,_0x434ee9);}}['_calculatePosition'](_0x52df7b){const _0x520c39=this['editor']['config']['get']('collaboration.channelId'),_0x15658b=[...this['editor']['plugins']['get'](p)['archivedThreads']]['filter'](_0x4e21a8=>_0x4e21a8['channelId']===_0x520c39)['findIndex'](_0x459b04=>_0x459b04['archivedAt']<_0x52df7b);return _0x15658b<0x0||_0x15658b>this['annotationViews']['length']?this['annotationViews']['length']:_0x15658b-0x1;}['_toggleDialog'](){const _0x49a100=this['editor'],_0xaead88=_0x49a100['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Z(_0x49a100['locale'],this['annotationViews'])),'commentsArchive'===_0xaead88['id']?_0xaead88['hide']():_0xaead88['show']({'id':'commentsArchive','title':N(_0x49a100['locale'],'COMMENTS_ARCHIVE'),'icon':_0x3db991,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x1300f0['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x19bcfc,_0x381f18=!0x1){const _0x1003b4=this['editor']['locale'],_0xc8ceef=this['editor']['plugins']['get']('Dialog'),_0x12d5a2=new _0x19bcfc(_0x1003b4);return _0x12d5a2['bind']('isEnabled')['to'](this,'isEnabled'),_0x12d5a2['bind']('isOn')['to'](_0xc8ceef,'id',_0x336188=>'commentsArchive'===_0x336188),_0x12d5a2['set']({'label':N(_0x1003b4,'COMMENTS_ARCHIVE'),'icon':_0x3db991,'isToggleable':!0x0}),_0x381f18&&(_0x12d5a2['tooltip']=!0x0),this['listenTo'](_0x12d5a2,'execute',()=>this['_toggleDialog']()),_0x12d5a2;}['_hideDialogOnAnnotationEscape']=_0x59ff3a=>{const _0x4b15be=_0x59ff3a['source'];if(!this['annotationViews']['has'](_0x4b15be['view']))return;const _0x262d5d=this['editor']['plugins']['get']('Dialog');_0x262d5d['isOpen']&&'commentsArchive'===_0x262d5d['id']&&(_0x262d5d['hide'](),_0x59ff3a['stop']());};}class gi extends _0x25b6bf{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};