@ckeditor/ckeditor5-comments 45.0.0-alpha.11 → 45.0.0-alpha.12

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.
package/dist/index.js CHANGED
@@ -20,12 +20,12 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Editor as _0x26b794,ContextPlugin as _0x3fc4bc,PendingActions as ht,Command as _0x6657d7,Plugin as _0x4ddbc3,Context as _0x52719c}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0xba8ebe,uid as _0x3d5c1c,KeystrokeHandler as jt,FocusTracker as _0x322874,diff as _0x432fed,Collection as _0x564d2c,Rect as _0x23c230,CKEditorError as _0x2bd02b,first as _0x23cbe8,priorities as Wt,scrollViewportToShowTarget as rt,getEnvKeystrokeText as nt,toUnit as xt,DomEmitterMixin as _0x15fb5f,keyCodes as _0x433e11}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x33e929,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x34eab7,trimHtml as _0x1c7951,LateFocusDropdownButtonView as _0x478b2c,Users as it,getDateTimeFormatter as lt,hashObject as pt,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as ot,FOCUS_ANNOTATION_KEYSTROKE as _0x41fdef}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as wt,cloneDeep as It,set as At,unset as yt,debounce as _0x135821}from'es-toolkit/compat';import{IconUndo as _0x56da95,IconCheck as _0x3cf51e,IconPencil as _0x15cf23,IconRemoveComment as _0x2995c7,IconThreeVerticalDots as _0x2a25fa,IconAddComment as _0x1c1b9d,IconCommentsArchive as _0x281e35}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as Vt,InlineEditableUIView as $t,EditorUI as Rt,View as kt,FocusCycler as _0x24abfe,ButtonView as _0x2d05c8,ViewCollection as _0x3f54d3,createDropdown as _0x37f7b8,ListView as _0x2b823b,focusChildOnDropdownOpen as _0x4743ab,ListItemView as _0x493b22,MenuBarMenuListItemButtonView as _0xbc96d4,BodyCollection as _0x2eef2d,BalloonPanelView as _0x105127,ContextualBalloon as _0xb9f12c,Dialog as _0x52081b,DialogViewPosition as _0x485909}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disablePlaceholder as St,enablePlaceholder as Ft,MouseObserver as _0x56765a}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 Et}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as Gt}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as Jt}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as Kt}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x37ff95}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x4758dc}from'@ckeditor/ckeditor5-widget/dist/index.js';class Ct extends/* #__PURE__ -- @preserve */
24
- _0xba8ebe(){['model'];['view'];constructor(_0x43b94b,_0x5bca2e){super(),this['model']=_0x43b94b,this['model']['_isAttached']=!0x0,this['view']=_0x5bca2e,this['listenTo'](_0x5bca2e,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x5bca2e,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x5bca2e,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x5bca2e,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x5bca2e,'addComment',(_0xe960ed,_0xac2278)=>this['addComment'](_0xac2278)),this['listenTo'](_0x5bca2e,'updateComment',(_0xa3202c,_0x52e165,_0x103372)=>this['updateComment'](_0x52e165,_0x103372)),this['listenTo'](_0x5bca2e,'removeComment',(_0x3bc8cc,_0x401cf2)=>this['removeComment'](_0x401cf2));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x300469){this['model']['addComment']({'content':_0x300469,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x11508e,_0xc4ac7b){this['model']['getComment'](_0x11508e)['update']({'content':_0xc4ac7b});}['removeComment'](_0x3f68fa){this['model']['getComment'](_0x3f68fa)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function E(_0x210a71,_0x178b26,_0x4c2b33){const t=_0x210a71['t'];switch(_0x178b26){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'},_0x4c2b33);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'},_0x4c2b33);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'},_0x4c2b33);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'},_0x4c2b33);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x4c2b33);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'},_0x4c2b33);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'},_0x4c2b33);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'},_0x4c2b33);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 Ut extends Vt{['main'];['editable'];constructor(_0x182689,_0x5ddc7e){super(_0x182689);const _0x2fb79d=_0x3d5c1c();this['main']=this['createCollection'](),this['editable']=new $t(_0x182689,_0x5ddc7e,void 0x0,{'label':()=>E(_0x182689,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x182689['uiLanguageDirection'],'lang':_0x182689['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x2fb79d},'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 Ot extends Rt{['view'];constructor(_0x13d98b){super(_0x13d98b),this['view']=new Ut(_0x13d98b['locale'],_0x13d98b['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x4c56fe=this['editor']['editing']['view'],_0x5787db=this['view']['editable'],_0xcbee70=_0x4c56fe['document']['getRoot']();_0x5787db['name']=_0xcbee70['rootName'],this['view']['render']();const _0x3bfced=_0x5787db['element'];this['setEditableElement'](_0x5787db['name'],_0x3bfced),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x4c56fe['attachDomRoot'](_0x3bfced),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Nt=[qt,zt,Bt,Et,Gt,Jt,Kt];class Qt extends/* #__PURE__ -- @preserve */
25
- _0xba8ebe(_0x26b794){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
- ((()=>Nt)());constructor(_0x5335eb={}){function _0x476ff6(_0x2bf312){return _0x2bf312['map'](_0x527faa=>String['fromCharCode'](_0x527faa))['join']('');}(_0x5335eb=Object['assign']({},_0x5335eb))['plugins']||(_0x5335eb['plugins']=Qt['defaultPlugins']),super(_0x5335eb),this['ui']=new Ot(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x476ff6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x476ff6([0x76,0x69,0x65,0x77])][_0x476ff6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x476ff6([0x61,0x75,0x74,0x6f]),this[_0x476ff6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x476ff6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x476ff6([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x476ff6([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x476ff6([0x6f,0x6b])});}['create'](){const _0x5b392b=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x5b392b))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x1da357=>{const _0x1eefaf=this['model']['document']['getRoot'](),_0x2eda6b=_0x1eefaf&&_0x1eefaf['getChild'](_0x1eefaf['childCount']-0x1);_0x1da357['setSelection'](_0x2eda6b,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x283b22=this['editing']['view'],_0x28bcf2=_0x283b22['document']['getRoot'](),_0x48daaa=_0x28bcf2['getChild'](0x0);_0x28bcf2['childCount']>0x1||!_0x48daaa||'p'!=_0x48daaa['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x283b22,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x48daaa['placeholder']=this['placeholder']),Ft({'view':_0x283b22,'element':_0x48daaa,'keepOnFocus':!0x0}),this['placeholderElement']=_0x48daaa);}}class os extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x4bae43,_0x3f7c7f={}){super(_0x4bae43),this['editor']=null,this['_editorConfig']=_0x3f7c7f,this['set']('value',_0x3f7c7f['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',E(_0x4bae43,'Reply...')),this['set']('submitLabel',E(_0x4bae43,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x322874(),this['focusCycler']=new _0x24abfe({'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',(_0x420eb9,_0x4f367e)=>{this['cancelButtonView']['fire']('execute'),_0x4f367e();}),this['keystrokes']['set']('Ctrl+Enter',(_0x2836ed,_0x20184f)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x20184f());}),this['on']('submit',(_0x240eb2,_0x5efeaf)=>{_0x5efeaf['length']>0xfde8?(alert(E(_0x4bae43,'TOO_LONG_COMMENT_ALERT',[_0x5efeaf['length'],0xfde8])),_0x240eb2['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Qt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x30a029=this['editor'];this['element']['insertBefore'](_0x30a029['ui']['element'],this['element']['firstChild']),_0x30a029['model']['document']['on']('change',()=>this['value']=_0x30a029['getData']()),_0x30a029['bind']('placeholder')['to'](this),this['focusables']['add'](_0x30a029['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x148189){-0x1===_0x148189?(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:_0x473433}=this,_0x469102=new _0x2d05c8(_0x473433);return _0x469102['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x469102['withText']=!0x0,_0x469102['bind']('label')['to'](this,'submitLabel'),_0x469102['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x469102['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x5cf427,_0x1a0e47)=>!_0x1a0e47&&!!_0x5cf427['trim']()),_0x469102;}['_createCancelButton'](){const {locale:_0x32b85d}=this,_0xa9f32=new _0x2d05c8(_0x32b85d);return _0xa9f32['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0xa9f32['label']=E(_0x32b85d,'Cancel'),_0xa9f32['withText']=!0x0,_0xa9f32['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0xa9f32;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x5edffc=>{this['focusTracker']['add'](_0x5edffc['element']);}),this['focusables']['on']('change',(_0x4418de,_0x3470fc)=>{for(const _0x498848 of Array['from'](_0x3470fc['added'])['reverse']())this['focusTracker']['add'](_0x498848['element']);});}}class ie extends kt{constructor(_0x3a7b04,_0x173cd9,_0x203790){super(_0x3a7b04),this['commentInputView']=new os(_0x3a7b04,_0x203790),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x2d6aad,_0x43b34d)=>_0x2d6aad||!!_0x43b34d),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 _0x33e929(_0x3a7b04,_0x173cd9),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'](_0x3b2db3){this['commentInputView']['focus'](_0x3b2db3);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x3f2c99,_0x49c0ac)=>{const {submitButtonView:_0xd85fbe,cancelButtonView:_0x58a60e,editor:_0x71dc3d}=this['commentInputView'];[_0xd85fbe['element'],_0x58a60e['element'],_0x71dc3d?_0x71dc3d['editing']['view']['getDomRoot']():null]['filter'](_0x4a6638=>_0x4a6638)['some'](_0x422fa4=>_0x422fa4['contains'](_0x49c0ac['target']))||(this['focus'](),_0x49c0ac['preventDefault']());});}}class cs extends kt{constructor(_0x3d1936){super(_0x3d1936);const _0xec87fa=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0xec87fa['to']('count',_0x271e96=>E(_0x3d1936,'NUMBER_OF_COMMENTS',_0x271e96))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x567186,_0x595491,_0x10e6f0){super(_0x567186);const _0x4a200e=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x595491['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x595491,this['_config']=_0x10e6f0,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x322874(),this['keystrokes']=new jt(),this['focusCycler']=new _0x24abfe({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x1c3bf5=>this['commentViews']['map'](_0x27f53f=>_0x27f53f['element'])['includes'](_0x1c3bf5['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new cs(_0x567186),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x2b9311=>_0x2b9311-this['_config']['maxCommentsWhenCollapsed']);for(const _0x4fdc46 of _0x595491['comments'])this['_handleNewCommentModel'](_0x4fdc46);this['_handleInfoComment'](),this['listenTo'](_0x595491['comments'],'add',(_0x4db58e,_0x17c538)=>{const _0x18f322=this['_calculatePosition'](_0x17c538);this['length']++,this['_handleNewCommentModel'](_0x17c538,_0x18f322),this['refreshVisibleViews']();}),this['listenTo'](_0x595491['comments'],'remove',(_0x4e4c6d,_0x4725a0)=>{this['length']--,this['_handleRemoveCommentModel'](_0x4725a0),this['refreshVisibleViews']();}),this['listenTo'](_0x595491,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x595491,'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',_0x4a200e['if']('length','ck-hidden',_0x32c4b7=>!_0x32c4b7)],'aria-label':E(_0x567186,'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'](_0xe118d1){-0x1===_0xe118d1?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x5d0152 of this['commentViews'])_0x5d0152['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x202634,_0x38d549){const _0x4aece5=new this['_config']['CommentView'](this['locale'],_0x202634,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x4aece5['viewUid']=_0x202634['id'],_0x4aece5['delegate']('removeComment')['to'](this),_0x4aece5['delegate']('updateComment')['to'](this),_0x4aece5['delegate']('resolveCommentThread')['to'](this),_0x4aece5['delegate']('editorReady')['to'](this),_0x4aece5['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x4aece5,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x4aece5,_0x38d549);}['_calculatePosition'](_0x2bc88b){const _0x3f8eb1=this['_model']['_findOptimalIndex'](_0x2bc88b);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x2bc88b['authoredAt']?_0x3f8eb1-0x1:_0x3f8eb1:_0x3f8eb1-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x54ddb8={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':E(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x54ddb8,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x54ddb8));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x43f91c){const _0x46a6a2=this['commentViews']['remove'](_0x43f91c['id']);this['stopListening'](_0x46a6a2),_0x46a6a2['isEditMode']&&this['_updateHasDirtyComment'](),_0x46a6a2['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0xd95b96=>_0xd95b96['isEditMode']);}['_rearrangeCollapse'](){const _0x36aa14=function(_0x5bb075){const _0x159f9d=new _0x564d2c();for(const _0x214fc8 of _0x5bb075)_0x159f9d['add'](_0x214fc8);return _0x159f9d;}(this['commentViews']),_0xf20f13=this['_collapsedCommentsView']['count'];for(let _0x2e521e=0x1;_0x2e521e<=_0xf20f13;_0x2e521e++)_0x36aa14['remove'](0x1);for(const _0x145718 of _0x36aa14)_0x145718['collapse']();_0xf20f13>0x0&&_0x36aa14['add'](this['_collapsedCommentsView'],0x1),ns(_0x432fed(Array['from'](this['visibleViews']),Array['from'](_0x36aa14)),this['visibleViews'],_0x36aa14);}['_rearrangeExpand'](){ns(_0x432fed(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x106c38 of this['visibleViews'])_0x106c38['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x4c6115=>{this['focusTracker']['add'](_0x4c6115['element']),this['keystrokes']['listenTo'](_0x4c6115['element']);}),this['commentViews']['on']('change',(_0x3d01e0,_0x4acdee)=>{for(const _0x24de30 of _0x4acdee['removed'])this['focusTracker']['remove'](_0x24de30['element']),this['keystrokes']['stopListening'](_0x24de30['element']);for(const _0x4855c2 of Array['from'](_0x4acdee['added'])['reverse']())this['focusTracker']['add'](_0x4855c2['element']),this['keystrokes']['listenTo'](_0x4855c2['element']);});}}function ns(_0x714033,_0x4e6565,_0x5c8e42){let _0xb9322b=0x0;for(const _0x63a77c of _0x714033)switch(_0x63a77c){case'insert':_0x4e6565['add'](_0x5c8e42['get'](_0xb9322b),_0xb9322b),_0xb9322b++;break;case'delete':_0x4e6565['remove'](_0xb9322b);break;case'equal':_0xb9322b++;}}class as extends kt{constructor(_0x31bc63){super(_0x31bc63);const _0x3a6006=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x3a6006['to']('contextValue',_0x31b519=>E(_0x31bc63,'THREAD_CONTEXT_LABEL',_0x31b519)),'tabindex':-0x1},'children':[{'text':_0x3a6006['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x1db307,_0x2783ae){super(_0x1db307);const _0x288a74=this['bindTemplate'];this['_model']=_0x2783ae,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x322874(),this['keystrokes']=new jt(),this['focusCycler']=new _0x24abfe({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x2a6ad5=>!!_0x2a6ad5),this['bind']('contextValue')['to'](this['_model'],'context',_0x4947e4=>_0x4947e4&&_0x4947e4['value']?this['_trimContextValue'](_0x4947e4['value']):E(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',_0x288a74['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 _0x563c27=new _0x2d05c8(this['locale']);return _0x563c27['label']=E(this['locale'],'Reopen'),_0x563c27['tooltip']=E(this['locale'],'Reopen'),_0x563c27['icon']=_0x56da95,_0x563c27['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x416c39=>!_0x416c39),_0x563c27['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x58cc1e,_0x2dca2f)=>_0x58cc1e&&_0x2dca2f),_0x563c27['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x563c27;}['_trimContextValue'](_0x56e07d){if(_0x56e07d['length']<0x96)return _0x56e07d;const _0x37ce16=_0x56e07d['lastIndexOf']('\x20',0x93);return _0x56e07d['substring'](0x0,_0x37ce16>-0x1?_0x37ce16:0x93)+'...';}['_attachContextActions'](){const _0x2ffe49=this['element']['querySelector']('.ck-context'),_0x48ebdc=_0x2ffe49['querySelector']('.ck-context__value');this['listenTo'](_0x2ffe49,'mouseenter',()=>{_0x48ebdc['offsetWidth']<_0x48ebdc['scrollWidth']&&_0x2ffe49['classList']['add']('overlay');}),this['listenTo'](_0x2ffe49,'mouseleave',()=>{_0x2ffe49['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x232225 of this['focusables'])this['focusTracker']['add'](_0x232225['element']),this['keystrokes']['listenTo'](_0x232225['element']);}['_createContextView'](){const _0x5260d3=new as(this['locale']);return _0x5260d3['bind']('contextValue')['to'](this),_0x5260d3;}}class ts extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0xbc54d1,_0x40ead5,_0x221688,_0x1dae6b){super(_0xbc54d1),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x40ead5,this['_localUser']=_0x221688,this['_config']=_0x1dae6b,this['commentThreadHeaderView']=new Xt(_0xbc54d1,_0x40ead5),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0xbc54d1,E(_0xbc54d1,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0xbc54d1,_0x40ead5,Object['assign']({'CommentView':this['_config']['CommentView']},_0x1dae6b)),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',(_0x40f567,_0x4d643b)=>_0x40f567||!!_0x4d643b),this['bind']('isUnlinked')['to'](_0x40ead5,'unlinkedAt',_0xb8485=>!!_0xb8485),this['bind']('ariaLabel')['to'](this,'length',_0x588378=>{const _0x44ad65=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return E(this['locale'],'COMMENT_THREAD_LABEL',[_0x588378,_0x44ad65]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x322874(),this['keystrokes']=new jt(),this['focusCycler']=new _0x24abfe({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x19048b=>_0x19048b['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 _0x415798=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x8a518=_0x415798['commentInputView'];return _0x415798['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x8a518,'value',(_0x338570,_0x496616,_0x11d23a,_0x58497e,_0x5a5ef7)=>!!_0x5a5ef7||!!_0x58497e&&_0x11d23a&&!_0x496616||_0x338570&&_0x11d23a&&!_0x496616),_0x8a518['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x15065d,_0x47355d,_0x2074e3)=>{let _0x86ae01;return _0x86ae01=_0x2074e3&&_0x47355d?'Reply\x20to\x20reopen\x20discussion...':_0x15065d?'Reply...':'Write\x20a\x20comment...',E(this['locale'],_0x86ae01);}),_0x8a518['bind']('submitLabel')['to'](this,'length',_0x524f4a=>E(this['locale'],_0x524f4a?'Reply':'Comment')),_0x8a518['on']('submit',(_0x23445f,_0x1179c7)=>{this['fire']('addComment',_0x1179c7),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x8a518['on']('cancel',()=>{this['focus']();}),_0x8a518['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x8a518['on']('cancel',_0x2609c9=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x2609c9['stop']());}),this['on']('change:isActive',(_0x47f297,_0x4e32df,_0x26928e)=>{_0x26928e||this['length']||_0x8a518['value']||this['fire']('removeCommentThread');}),_0x415798;}}class vt extends/* #__PURE__ -- @preserve */
27
- ti(ts){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x53783f,_0x4f4ee6,_0x1ec648,_0x374d2a){super(_0x53783f,_0x4f4ee6,_0x1ec648,_0x374d2a),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x53783f,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x395108,_0x4e7ed7,_0x1d1039)=>{_0x1d1039||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x1e1199,_0x252de9,_0x40a5e0)=>{_0x40a5e0&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x1c8577=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x1c8577['if']('isActive','ck-thread--active'),_0x1c8577['if']('isUnlinked','ck-thread--unlinked'),_0x1c8577['if']('isConfirm','ck-thread--remove-confirmation'),_0x1c8577['to']('actionIndicator',_0x4428e9=>_0x4428e9?'ck-thread--'+_0x4428e9:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x1c8577['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 _0x31b145 of this['commentsListView']['commentViews'])_0x31b145['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x8fdc29}=this,_0x27fd8a=this['commentsListView']['commentViews']['get'](0x0);_0x27fd8a===this['_boundFirstCommentView']||_0x27fd8a['isSystemComment']||(this['_boundFirstCommentView']=_0x27fd8a,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x27fd8a,'actionIndicator',_0x413ce0=>'remove'===_0x413ce0?'remove':null),_0x27fd8a['placeholder']=E(_0x8fdc29,'Write\x20a\x20comment...'),_0x27fd8a['removeButton']['on']('execute',_0x586477=>{_0x586477['stop'](),this['showConfirm'](E(_0x8fdc29,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x27fd8a['focus']();}),_0x27fd8a['actionBar']['add'](this['resolveButton'],0x0),_0x27fd8a['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x56a5a0=new _0x34eab7(this['locale']);return _0x56a5a0['label']=E(this['locale'],'Resolve'),_0x56a5a0['tooltip']=E(this['locale'],'Resolve'),_0x56a5a0['icon']=_0x3cf51e,_0x56a5a0['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x56a5a0['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x437d5b=>!_0x437d5b),_0x56a5a0['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x327f81,_0x2afe4d)=>_0x327f81&&!_0x2afe4d),_0x56a5a0['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x56a5a0;}['_updateArchivedThreadHeader'](){this['_model']['archivedAt']?this['commentThreadChildren']['has'](this['commentThreadHeaderView'])||(this['commentThreadChildren']['add'](this['commentThreadHeaderView'],0x0),this['focusables']['add'](this['commentThreadHeaderView'],0x0)):this['commentThreadChildren']['has'](this['commentThreadHeaderView'])&&(this['commentThreadChildren']['remove'](this['commentThreadHeaderView']),this['focusables']['remove'](this['commentThreadHeaderView']));}}class es extends kt{constructor(_0x1f13c2){super(_0x1f13c2),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x1fdc8b,_0x28eb64,_0xa8e527)=>{this['element']['innerHTML']=_0xa8e527;}),this['element']['innerHTML']=this['content'];}}class hs extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x290311,_0x33c92b,_0x5c0d16){super(_0x290311),this['_model']=_0x33c92b,this['_config']=_0x5c0d16,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x33c92b,'content',_0x33c92b,'authoredAt',(_0x336df4,_0x29a9c3)=>E(_0x290311,'COMMENT_ARIA_LABEL',[_0x33c92b['author']['name'],_0x5c0d16['formatDateTime'](_0x29a9c3),new DOMParser()['parseFromString'](_0x336df4,'text/html')['body']['textContent'],_0x33c92b['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x290311,E(_0x290311,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x3f54d3(),this['focusTracker']=new _0x322874(),this['keystrokes']=new jt(),this['focusCycler']=new _0x24abfe({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x23b5a8=>_0x23b5a8['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']?E(this['locale'],'EXTERNAL_IMPORT_WORD_COMMENT'):E(this['locale'],'EXTERNAL_COMMENT');}['getUserViewNotificationText'](){return this['_model']['isExternal']?'importWord'===this['_model']['attributes']['@external']['source']?E(this['locale'],'EXTERNAL_IMPORT_WORD_AVATAR',this['_model']['creator']['name']):E(this['locale'],'EXTERNAL_AVATAR',this['_model']['creator']['name']):null;}['_createCommentContentView'](){const _0x5c9834=new es(this['locale']);return _0x5c9834['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x21da4a,_0x36059f)=>_0x36059f?_0x1c7951(_0x21da4a,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x21da4a),_0x5c9834;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x3ff70c=new os(this['locale'],this['_config']['editorConfig']);return _0x3ff70c['value']=this['_model']['content'],_0x3ff70c['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x3ff70c['submitLabel']=E(this['locale'],'Save'),_0x3ff70c['on']('submit',(_0x4cfcb7,_0xef6a6a)=>{this['fire']('updateComment',this['_model']['id'],_0xef6a6a),this['switchToDisplayMode'](),this['focus']();}),_0x3ff70c['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x3ff70c['once']('editorReady',()=>{_0x3ff70c['focus']();}),_0x3ff70c['createEditor'](),_0x3ff70c['delegate']('editorReady')['to'](this),_0x3ff70c['delegate']('editorDestroyed')['to'](this),_0x3ff70c;}['_setupKeyboardNavigation'](){const _0x1165b3=this['element'];this['keystrokes']['listenTo'](_0x1165b3);for(const _0x41c1a0 of this['focusables'])this['focusTracker']['add'](_0x41c1a0['element']),this['keystrokes']['listenTo'](_0x41c1a0['element']);this['focusables']['on']('change',(_0x256ce9,_0x581aed)=>{for(const _0x5349e2 of _0x581aed['removed'])this['focusTracker']['remove'](_0x5349e2['element']),this['keystrokes']['stopListening'](_0x5349e2['element']);for(const _0x17c91c of _0x581aed['added'])this['focusTracker']['add'](_0x17c91c['element']),this['keystrokes']['listenTo'](_0x17c91c['element']);}),this['keystrokes']['set']('enter',(_0x2106e0,_0x510bd0)=>{_0x1165b3===_0x2106e0['target']&&(this['focusCycler']['focusFirst'](),_0x510bd0());}),this['keystrokes']['set']('esc',(_0xf2be7b,_0x542869)=>{_0x1165b3!==_0xf2be7b['target']&&(this['focus'](),_0x542869());});}}class gt extends/* #__PURE__ -- @preserve */
28
- ti(hs){['actionBar'];['userView'];constructor(_0x48d043,_0x56f115,_0x254755){super(_0x48d043,_0x56f115,_0x254755),this['set']('actionIndicator',null),this['set']('placeholder',E(_0x48d043,'Reply...')),this['bind']('authoredAt')['to'](_0x56f115),this['bind']('resolvedAt')['to'](_0x56f115),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 _0x33e929(_0x48d043,_0x56f115['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x56f115,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x4a31dd=this['bindTemplate'],_0x207393=[{'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':_0x4a31dd['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x4a31dd['to']('authoredAt',_0x2e5261=>this['_config']['formatDateTime'](_0x2e5261))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x4a31dd['if']('isEditMode','ck-comment__actions--hidden'),_0x4a31dd['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']&&_0x207393['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x4a31dd['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x4a31dd['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x4a31dd['if']('isEditMode','ck-comment--edit'),_0x4a31dd['if']('isSystemComment','ck-comment--info'),_0x4a31dd['to']('actionIndicator',_0x164b11=>_0x164b11?'ck-comment--'+_0x164b11:'')],'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':_0x207393}]}]};}['_createEditButton'](){const _0xe84eea=new _0x2d05c8(this['locale']);return _0xe84eea['label']=E(this['locale'],'Edit'),_0xe84eea['icon']=_0x15cf23,_0xe84eea['withText']=!0x0,_0xe84eea['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0xe84eea['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x541cb5=>!_0x541cb5),_0xe84eea['bind']('isVisible')['to'](this['_model'],'isEditable'),_0xe84eea['on']('execute',()=>this['switchToEditMode']()),_0xe84eea;}['_createRemoveButton'](){const _0x2996d0=new _0x2d05c8(this['locale']);return _0x2996d0['label']=E(this['locale'],'Remove'),_0x2996d0['icon']=_0x2995c7,_0x2996d0['withText']=!0x0,_0x2996d0['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x2996d0['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x2deec4=>!_0x2deec4),_0x2996d0['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x2996d0['on']('execute',()=>{this['showConfirm'](E(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x2996d0;}['_createDropdown'](){const _0x527a2d=_0x37f7b8(this['locale'],_0x478b2c),_0x1b0e50=_0x527a2d['panelView']['children'],_0x146c0d=new _0x2b823b(this['locale']),_0x162daf=_0x527a2d['bindTemplate'];_0x4743ab(_0x527a2d,()=>this['items']['find'](_0x53427a=>_0x53427a['isVisible'])),_0x527a2d['extendTemplate']({'attributes':{'class':[_0x162daf['if']('isVisible','ck-hidden',_0x5b7a5a=>!_0x5b7a5a)]}});const _0x912163=(_0x193358,_0x1ea99b=-0x1)=>{const _0x4cb8f9=new _0x493b22(this['locale']);_0x4cb8f9['children']['add'](_0x193358);const _0x1dd5ee=_0x1ea99b>-0x1?_0x1ea99b:_0x146c0d['items']['length'];_0x146c0d['items']['add'](_0x4cb8f9,_0x1dd5ee);const _0x41254a=Array['from'](this['items']);_0x527a2d['unbind']('isEnabled','isVisible'),_0x527a2d['bind']('isEnabled')['toMany'](_0x41254a,'isEnabled',(..._0x587e11)=>_0x587e11['some'](_0x59a0d7=>_0x59a0d7)),_0x527a2d['bind']('isVisible')['toMany'](_0x41254a,'isVisible',(..._0x453a70)=>_0x453a70['some'](_0x4610cc=>_0x4610cc));};_0x527a2d['panelPosition']='sw',_0x527a2d['buttonView']['set']({'label':E(this['locale'],'Show\x20more\x20items'),'icon':_0x2a25fa});for(const _0x27b0f6 of this['items'])_0x912163(_0x27b0f6);return _0x1b0e50['add'](_0x146c0d),_0x527a2d['listenTo'](this['items'],'add',(_0x1ef6bb,_0x4a846f,_0x3076e5)=>{_0x912163(_0x4a846f,_0x3076e5);}),_0x527a2d['listenTo'](this['items'],'remove',(_0x9031d6,_0x563064,_0x268790)=>{_0x146c0d['items']['remove'](_0x268790);}),_0x527a2d;}['_attachActions'](_0x58cad7,_0x3f61b1){const _0x3b8190=_0x58cad7&&_0x58cad7['element'];_0x3b8190&&(this['listenTo'](_0x3b8190,'mouseenter',()=>this['actionIndicator']=_0x3f61b1),this['listenTo'](_0x3b8190,'focus',()=>this['actionIndicator']=_0x3f61b1),this['listenTo'](_0x3b8190,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x3b8190,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x4d0196=super['_createCommentInputView']();return _0x4d0196['bind']('placeholder')['to'](this),_0x4d0196;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function Lt(_0x13aa63){const _0x1c8b85=Dt(_0x13aa63,0x1e),_0x2dcd57=new MutationObserver(_0x3e17df=>{for(const _0x2295f7 of _0x3e17df)('attributes'==_0x2295f7['type']&&'class'==_0x2295f7['attributeName']||'childList'==_0x2295f7['type']||'characterData'==_0x2295f7['type'])&&_0x1c8b85();});return{'attach'(_0x7e5e11){_0x2dcd57['observe'](_0x7e5e11,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x2dcd57['disconnect'](),_0x1c8b85['cancel']();}};}class S extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x2639de,_0x597ecf){super(_0x2639de),this['id']=_0x3d5c1c(),this['focusTracker']=new _0x322874(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x45ab6f,_0x2538b6)=>this['fire']('Esc',_0x2538b6)),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']=Lt(()=>this['_updateHeight']()),this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this),this['content']['add'](_0x597ecf),this['mainView']=_0x597ecf;const _0x1270e1=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x1270e1['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 _0x9f19f=this['element']['clientHeight'];_0x9f19f&&(this['height']=_0x9f19f);}}class d extends/* #__PURE__ -- @preserve */
29
- _0xba8ebe(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x159ff6,target:_0x1d5459,type:_0x45ab68,isVisible:_0x371f41=!0x0}){super(),this['view']=_0x159ff6,this['view']['element']||this['view']['render'](),this['_type']=_0x45ab68,this['_target']=_0x1d5459,d['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x564d2c([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x1b6a25,_0x554d93)=>{this['view']['focusTracker']['add'](_0x554d93);}),this['focusableElements']['on']('remove',(_0x18b64d,_0x302855)=>{this['view']['focusTracker']['remove'](_0x302855);}),this['set']('isVisible',_0x371f41);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x7d7cb5=this['_getNormalizedTarget']();return d['_assertCorrectTarget'](_0x7d7cb5),_0x7d7cb5;}get['targetRect'](){const _0x1d76c1=this['target'];if(null===_0x1d76c1)return null;if(_0x1d76c1 instanceof _0x23c230)return _0x1d76c1;const _0x18964d=_0x1d76c1['filter'](_0x151a3f=>function(_0x4e3746){const _0x41e4d3=_0x4e3746['offsetParent'];if(_0x41e4d3)return!0x0;const _0x20d2aa=_0x4e3746['getClientRects']()['item'](0x0);return!!_0x20d2aa;}(_0x151a3f));return 0x0===_0x18964d['length']?null:new _0x23c230(_0x18964d[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x19822c){this['view']['isActive']=_0x19822c,this['view']['mainView']['isActive']=_0x19822c;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x49270b){if(!(null===_0x49270b||_0x49270b instanceof _0x23c230||Array['isArray'](_0x49270b)&&_0x49270b['every'](_0x53985a=>li(_0x53985a))))throw new _0x2bd02b('annotation-invalid-target',null,{'target':_0x49270b});}['_getNormalizedTarget'](){const _0x22e370='function'==typeof this['_target']?this['_target']():this['_target'];return li(_0x22e370)?[_0x22e370]:_0x22e370;}}function li(_0x38fb56){return null!==_0x38fb56&&'object'==typeof _0x38fb56&&'nodeType'in _0x38fb56&&0x1===_0x38fb56['nodeType'];}class _ extends _0x564d2c{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x549e9e=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x322874(),this['_focusTracker']['on']('change:isFocused',(_0x33f95a,_0x4f42e8,_0x1de1db)=>{_0x1de1db||this['fire']('blur');});for(const _0x19ec2c of _0x549e9e)this['add'](_0x19ec2c);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x3bcbd3){if(this['has'](_0x3bcbd3))throw new _0x2bd02b('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x3bcbd3['innerView'],_0x3bcbd3),this['_viewToAnnotation']['set'](_0x3bcbd3['view'],_0x3bcbd3);for(const _0x318e73 of _0x3bcbd3['focusableElements'])this['_focusTracker']['add'](_0x318e73);this['listenTo'](_0x3bcbd3['focusableElements'],'add',(_0x5559ac,_0x2bf06e)=>{this['_focusTracker']['add'](_0x2bf06e);}),this['listenTo'](_0x3bcbd3['focusableElements'],'remove',(_0x440138,_0x5f1e96)=>{this['_focusTracker']['remove'](_0x5f1e96);}),this['listenTo'](_0x3bcbd3['view']['focusTracker'],'change:isFocused',(_0x523426,_0x4992b1,_0x531ba0)=>{_0x531ba0&&this['fire']('focus',_0x3bcbd3);}),_0x3bcbd3['updateTargetRect']();const _0x365e42=this['_getOrderInContent'](_0x3bcbd3['view']['targetRect']);return super['add'](_0x3bcbd3,_0x365e42);}['remove'](_0x1c10df){if(!this['has'](_0x1c10df))throw new _0x2bd02b('annotationcollection-not-existing-item',null);this['stopListening'](_0x1c10df['view']['focusTracker']),this['stopListening'](_0x1c10df['focusableElements']);for(const _0x4dbe34 of _0x1c10df['focusableElements'])this['_focusTracker']['remove'](_0x4dbe34);return this['_viewToAnnotation']['delete'](_0x1c10df['view']),this['_innerViewToAnnotation']['delete'](_0x1c10df['innerView']),super['remove'](_0x1c10df);}['getByInnerView'](_0x54dcc7){return this['_innerViewToAnnotation']['get'](_0x54dcc7);}['getByView'](_0x119b41){return this['_viewToAnnotation']['get'](_0x119b41);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x59d8e4 of this)_0x59d8e4['updateTargetRect']();this['_sort']();}['_sort'](){const _0x179402=Array['from'](this)['sort']((_0x20c2ce,_0x39653d)=>v(_0x20c2ce['view']['targetRect'],_0x39653d['view']['targetRect']));for(let _0x3e7289=_0x179402['length']-0x1;_0x3e7289>0x0;_0x3e7289--){const _0xe6848f=_0x179402[_0x3e7289];_0x3e7289!==this['getIndex'](_0xe6848f)&&(this['remove'](_0xe6848f),this['add'](_0xe6848f));}}['_getOrderInContent'](_0x406a2b){let _0x4aa7f6=0x0;if(!_0x406a2b)return this['length'];for(const _0x3235d8 of this){const _0x53162c=_0x3235d8['view']['targetRect'];if(_0x53162c){if(v(_0x406a2b,_0x53162c)<0x0)return _0x4aa7f6;_0x4aa7f6++;}}return _0x4aa7f6;}}function v(_0x2c3c86,_0x20c8d9){if(null===_0x2c3c86&&null===_0x20c8d9)return 0x0;if(null===_0x2c3c86)return-0x1;if(null===_0x20c8d9)return 0x1;const _0x1aebd2=_0x2c3c86['top']-_0x20c8d9['top'];return 0x0==_0x1aebd2?_0x2c3c86['left']-_0x20c8d9['left']:_0x1aebd2;}class O extends _0x3fc4bc{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5f2920){if(super(_0x5f2920),this['collection']=new _(),this['_visibleAnnotations']=new _(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x5f2920 instanceof _0x26b794){const _0x59efca=_0x5f2920['locale'];_0x5f2920['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':E(_0x59efca,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0xf035b8){this['collection']['add'](_0xf035b8);}['remove'](_0x3a66fe){this['collection']['remove'](_0x3a66fe),_0x3a66fe['destroy']();}['refreshVisibility'](){for(const _0x3e0daf of this['collection'])_0x3e0daf['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x30e6c7){return this['collection']['getByInnerView'](_0x30e6c7);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x351069 of this['collection'])_0x351069['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x3695d8){this['fire']('_activateAnnotation',_0x3695d8);}['createAnnotation'](_0x385d12){return new d(_0x385d12);}['createAnnotationView'](_0x56de2e,_0x28f83a){return new S(_0x56de2e,_0x28f83a);}['_addActiveAnnotation'](_0x215e58){const _0x47e389=new Set(this['activeAnnotations']);_0x47e389['add'](_0x215e58),this['activeAnnotations']=_0x47e389;}['_removeActiveAnnotation'](_0x301a4b){const _0x458d3c=new Set(this['activeAnnotations']);_0x458d3c['delete'](_0x301a4b),this['activeAnnotations']=_0x458d3c;}['_bindAnnotationsToVisibleAnnotations'](){const _0x376520=this['collection'],_0x205679=this['_visibleAnnotations'];function _0x4775ec(_0x1b4391){const _0x13a9ad=_0x1b4391['source'];_0x13a9ad['isVisible']&&!_0x205679['has'](_0x13a9ad)?_0x205679['add'](_0x13a9ad):!_0x13a9ad['isVisible']&&_0x205679['has'](_0x13a9ad)&&_0x205679['remove'](_0x13a9ad),_0x13a9ad['view']['focusTracker']['remove'](_0x13a9ad['view']['element']),_0x13a9ad['view']['focusTracker']['add'](_0x13a9ad['view']['element']);}this['listenTo'](_0x376520,'add',(_0x351ca2,_0x5745c5)=>{_0x5745c5['isVisible']&&_0x205679['add'](_0x5745c5),this['listenTo'](_0x5745c5,'change:isVisible',_0x4775ec);}),this['listenTo'](_0x376520,'remove',(_0x2da807,_0x4b25d5)=>{_0x205679['has'](_0x4b25d5)&&_0x205679['remove'](_0x4b25d5),this['stopListening'](_0x4b25d5,'change:isVisible',_0x4775ec);});}['_setupEnterAnnotationKeystroke'](){const _0x5d9e19=_0x3ece2b=>{_0x3ece2b['on']('ready',()=>{_0x3ece2b['keystrokes']['set'](_0x37ff95,(_0x4aa709,_0x56fbc0)=>{const _0x26c64f=_0x23cbe8(this['activeAnnotations']['values']());_0x26c64f&&(_0x26c64f['view']['focus'](),_0x56fbc0());});});};this['context']instanceof _0x26b794?_0x5d9e19(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x251e0a,_0x17c368)=>{_0x5d9e19(_0x17c368);});}['_setupEscapeAnnotationHandling'](){const _0x14faa9=_0x591edb=>{const _0x21bfa6=_0x591edb['source'],_0x1c956b=[];let _0x34f470;if(Array['isArray'](_0x21bfa6['target'])){_0x34f470=_0x21bfa6['target'][0x0],this['context']instanceof _0x26b794?_0x1c956b['push'](this['context']):this['context']['editors']&&_0x1c956b['push'](...this['context']['editors']);for(const _0x595ba3 of _0x1c956b)for(const _0x1bead0 of _0x595ba3['editing']['view']['domRoots']['values']())if(_0x1bead0['contains'](_0x34f470))return void _0x595ba3['editing']['view']['focus']();_0x34f470['focus']();}};this['listenTo'](this['collection'],'add',(_0x3d2fee,_0x1bc529)=>{this['listenTo'](_0x1bc529,'escape',_0x14faa9,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x17fd2c,_0x3382ba)=>{this['stopListening'](_0x3382ba,'escape',_0x14faa9);});}}const Tt=Symbol('noChannel'),_t={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x3fc4bc{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[O,ht,it];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1caccb){super(_0x1caccb),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x1d0142=this['context']['config'];_0x1d0142['define']('comments.maxCommentsWhenCollapsed',0x2),_0x1d0142['define']('comments.maxThreadTotalWeight',0x1f4),_0x1d0142['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x1d0142['define']('comments.CommentThreadView',vt),_0x1d0142['define']('comments.CommentView',gt),_0x1d0142['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x2f6c96=this['context']['plugins']['get'](O);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x31ca6a,_0x4d796f)=>this['_addCommentThread'](_0x4d796f)),this['on']('submitCommentThread',(_0x118a5a,_0x387019)=>this['_submitCommentThread'](_0x387019)),this['on']('resolveCommentThread',(_0x56cc0c,_0x102334)=>this['_resolveCommentThread'](_0x102334)),this['on']('resolveCommentThread',(_0x3874e5,_0x3901e2)=>this['_updateActiveAnnotation'](_0x3901e2),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x4d798f,_0x225376)=>this['_reopenCommentThread'](_0x225376)),this['on']('reopenCommentThread',(_0x14a17d,_0x5da1fe)=>this['_updateActiveAnnotation'](_0x5da1fe),{'priority':'lowest'}),this['on']('removeCommentThread',(_0xf9d114,_0x3d7125)=>this['_removeCommentThread'](_0x3d7125)),this['on']('updateCommentThread',(_0x10136c,_0x53c9c7)=>this['_updateCommentThread'](_0x53c9c7)),this['on']('updateCommentThread',(_0x28878e,_0x54f193)=>this['_updateActiveAnnotation'](_0x54f193),{'priority':'lowest'}),this['on']('addComment',(_0x43b21a,_0x1555ec)=>this['_addComment'](_0x1555ec)),this['on']('updateComment',(_0x28930e,_0x53e7ca)=>this['_updateComment'](_0x53e7ca)),this['on']('removeComment',(_0x37c764,_0x3cbe8f)=>this['_removeComment'](_0x3cbe8f)),this['on']('addComment',(_0x56edc8,{threadId:_0x683e6a,isFromAdapter:_0x46f659})=>{if(_0x46f659)return;const _0x47f193=this['getCommentThread'](_0x683e6a),_0x35d5b9=_0x47f193&&this['_threadToController']['get'](_0x47f193);_0x35d5b9&&_0x35d5b9['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x2f6c96,'change:activeAnnotations',(_0x548c31,_0x2cf136,_0x5e391e)=>{const _0x43235d=Array['from'](_0x5e391e)['map'](_0x3132dd=>this['_viewToController']['get'](_0x3132dd['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x43235d?_0x43235d['model']:null;});}set['adapter'](_0xc5fd9b){if(this['_adapter'])throw new _0x2bd02b('commentsrepository-adapter-already-set');this['_adapter']=_0xc5fd9b;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x776df2=Tt,threadId:_0x1d79f1=_0x3d5c1c(),comments:_0x74dbaf=[],unlinkedAt:_0x5e304e=null,resolvedAt:_0x541ead=null,resolvedBy:_0x3b6925=null,target:_0x912441=null,context:_0x420bb3=null,attributes:_0x20d2a3={},isResolvable:_0x1e75df=!0x0,isSubmitted:_0x4f0160=!0x1,isFromAdapter:_0x57da3e=!0x1}={}){return this['fire'](bt('addCommentThread',_0x776df2),{'channelId':_0x776df2,'threadId':_0x1d79f1,'comments':_0x74dbaf,'unlinkedAt':_0x5e304e,'resolvedAt':_0x541ead,'resolvedBy':_0x3b6925,'target':_0x912441,'context':_0x420bb3,'attributes':_0x20d2a3,'isFromAdapter':_0x57da3e,'isResolvable':_0x1e75df,'isSubmitted':_0x4f0160}),this['getCommentThread'](_0x1d79f1);}['openNewCommentThread']({channelId:_0x67675b=Tt,threadId:_0x40713f=_0x3d5c1c(),target:_0x362950,context:_0xc5989b=null,isResolvable:_0x3c81aa=!0x0}){if(this['_readOnlyChannels']['has'](_0x67675b)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x362950)throw new _0x2bd02b('commentsrepository-missing-target');const _0xd16f85=this['addCommentThread']({'channelId':_0x67675b,'threadId':_0x40713f,'target':_0x362950,'context':_0xc5989b,'isResolvable':_0x3c81aa});if(!_0xd16f85)return null;const _0x4634c0=this['_threadToController']['get'](_0xd16f85),_0x3914a9=_0x4634c0['view']['commentThreadInputView']['commentInputView'],_0x5f5d1e=this['context']['plugins']['get'](O),_0x326b7d=_0x5f5d1e['getByInnerView'](_0x4634c0['view']);return _0x5f5d1e['activate'](_0x326b7d),_0x3914a9['once']('editorReady',()=>_0x3914a9['focus']()),_0xd16f85;}['hasCommentThread'](_0x14dbf3){if('string'!=typeof _0x14dbf3)throw new _0x2bd02b('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x14dbf3);}['updateCommentThread']({channelId:_0x4237c1=Tt,threadId:_0x413437,context:_0xa6077f,unlinkedAt:_0x1cec8f,attributes:_0x11d16c,isFromAdapter:_0x5f5278=!0x1}){return this['fire'](bt('updateCommentThread',_0x4237c1),{'channelId':_0x4237c1,'threadId':_0x413437,'context':_0xa6077f,'unlinkedAt':_0x1cec8f,'attributes':_0x11d16c,'isFromAdapter':_0x5f5278}),this['getCommentThread'](_0x413437);}['getCommentThread'](_0x253749){if('string'!=typeof _0x253749)throw new _0x2bd02b('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x253749);}['fetchCommentThread']({channelId:_0x5b5975,threadId:_0x6fbeb3}={}){const _0x5a311f=this['getCommentThread'](_0x6fbeb3);if(_0x5a311f)return Promise['resolve'](_0x5a311f);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x2bd02b('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x5b5975,'threadId':_0x6fbeb3})['then'](_0x372319=>this['hasCommentThread'](_0x6fbeb3)?this['getCommentThread'](_0x6fbeb3):_0x372319?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x5b5975},_0x372319)):void 0x0)['catch'](_0x3d45d2=>{throw console['error'](_0x3d45d2),new _0x2bd02b('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x56e060,skipNotAttached:_0x324640=!0x1,skipEmpty:_0x36a034=!0x1,toJSON:_0x246fa8=!0x1}={}){const _0x484833=[];for(const _0x306283 of this['_threads']['values']())_0x56e060&&_0x306283['channelId']!==_0x56e060||_0x324640&&!_0x306283['isAttached']||_0x36a034&&0x0===_0x306283['length']||_0x484833['push'](_0x306283);return _0x246fa8?_0x484833['map'](_0x1abc51=>_0x1abc51['toJSON']()):_0x484833;}['setActiveCommentThread'](_0x8757ee){const _0x1e70cb=this['context']['plugins']['get'](O);if(!_0x8757ee)return void(this['activeCommentThread']&&_0x1e70cb['deactivateAll']());const _0x186a91=this['getCommentThread'](_0x8757ee);if(!_0x186a91)throw new _0x2bd02b('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x8757ee});if(!this['_threadToController']['has'](_0x186a91))throw new _0x2bd02b('commentsrepository-active-not-attached',null,{'threadId':_0x8757ee});const _0x309daf=_0x1e70cb['getByInnerView'](this['_threadToController']['get'](_0x186a91)['view']);_0x1e70cb['activate'](_0x309daf);}['switchReadOnly'](_0x5c0400,_0x498abf){_0x5c0400?this['_readOnlyChannels']['add'](_0x498abf):this['_readOnlyChannels']['delete'](_0x498abf),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x1352e2){return this['_readOnlyChannels']['has'](_0x1352e2)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x3325b6,_0x1ca2f8){return new Ct(_0x3325b6,_0x1ca2f8);}['setPermissions'](_0x45f03d,_0x5b6c45=Tt){this['_permissions']['set'](_0x5b6c45,_0x45f03d),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x9b5cc8=Tt){return this['_permissions']['has'](_0x9b5cc8)?this['_permissions']['get'](_0x9b5cc8):_t;}['_addCommentThread']({channelId:_0x58f3cd,threadId:_0x4822a1,comments:_0x1dab80,unlinkedAt:_0x4f830f,resolvedAt:_0x4d23e2,resolvedBy:_0x44bef3,target:_0x448ba3,context:_0x2a681e,attributes:_0x44e599,isFromAdapter:_0x33a532,isResolvable:_0x38fcce,isSubmitted:_0x3c8ea1}){if('string'!=typeof _0x4822a1)throw new _0x2bd02b('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x4822a1});if(this['hasCommentThread'](_0x4822a1))throw new _0x2bd02b('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x4822a1});const _0x4dfabb=new ui(this,{'channelId':_0x58f3cd,'id':_0x4822a1,'context':_0x2a681e,'attributes':_0x44e599,'unlinkedAt':_0x4f830f,'resolvedAt':_0x4d23e2,'resolvedBy':_0x44bef3?this['context']['plugins']['get'](it)['getUser'](_0x44bef3):null,'isResolvable':_0x38fcce,'isSubmitted':_0x3c8ea1||_0x33a532});this['_threads']['set'](_0x4822a1,_0x4dfabb);for(const _0x3cb4b5 of _0x1dab80)_0x4dfabb['_add'](this['_createNewComment']({'threadId':_0x4822a1,..._0x3cb4b5}));return _0x448ba3&&_0x4dfabb['attachTo'](_0x448ba3),_0x33a532||!_0x4dfabb['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x58f3cd,'threadId':_0x4822a1});}['_submitCommentThread']({channelId:_0x27859d,threadId:_0xc6ad7f}){if(!this['hasCommentThread'](_0xc6ad7f))throw new _0x2bd02b('commentsrepository-missing-comment-thread',this);const _0x3f0572=this['getCommentThread'](_0xc6ad7f);if(_0x3f0572['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x577b29,comments:_0x54044a,resolvedAt:_0x255d9d,resolvedBy:_0x44658f,context:_0x42757e,attributes:_0x1f453e}=_0x3f0572,_0x34a66f=this['context']['plugins']['get']('PendingActions'),_0x4ac5f4=_0x34a66f['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x27859d,'threadId':_0x577b29,'comments':_0x54044a['map'](_0x2bd6d0=>_0x2bd6d0['toJSON']()),'resolvedAt':_0x255d9d,'resolvedBy':_0x44658f?_0x44658f['id']:_0x44658f,'context':_0x42757e,'attributes':_0x1f453e})['then'](({comments:_0x1666b8})=>{_0x34a66f['remove'](_0x4ac5f4);for(const _0x585163 of _0x1666b8)this['_updateComment']({'channelId':_0x27859d,'threadId':_0xc6ad7f,'commentId':_0x585163['commentId'],'createdAt':_0x585163['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x199cb1=>{throw console['error'](_0x199cb1),new _0x2bd02b('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x4cc573,target:_0x51d87d}){const _0x25f025=this['getCommentThread'](_0x4cc573);if(!_0x25f025)throw new _0x2bd02b('commentsrepository-attach-missing-comment-thread',this);const _0x457ab8=this['context']['plugins']['get']('PendingActions'),_0x53954f=this['context']['plugins']['get'](O),_0x2a4a72=this['_createCommentThreadView'](_0x25f025),_0x231e25=new Ct(_0x25f025,_0x2a4a72);let _0x45a3aa=null;_0x2a4a72['on']('change:isDirty',(_0x394a17,_0x410721,_0x627727)=>{_0x627727?_0x45a3aa=_0x457ab8['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x45a3aa&&(_0x457ab8['remove'](_0x45a3aa),_0x45a3aa=null);}),this['_threadToController']['set'](_0x25f025,_0x231e25),this['_viewToController']['set'](_0x2a4a72,_0x231e25);const _0x220841=new S(this['context']['locale'],_0x2a4a72);_0x220841['bind']('length')['to'](_0x2a4a72),_0x220841['bind']('isDirty')['to'](_0x2a4a72,'isDirty',_0x2a4a72,'length',(_0x373b43,_0x1527de)=>_0x373b43||!_0x1527de),_0x220841['bind']('isActive')['to'](_0x2a4a72),_0x220841['type']='comment';const _0x132024=new d({'view':_0x220841,'target':_0x51d87d,'type':'comment','isVisible':!_0x25f025['archivedAt']});return _0x2a4a72['on']('escape',()=>{_0x132024['fire']('escape');}),this['_bindAnnotationToEditors'](_0x2a4a72,_0x132024),_0x53954f['add'](_0x132024),_0x132024;}['_bindAnnotationToEditors'](_0x1609e4,_0x42cc71){this['listenTo'](_0x1609e4,'editorReady',(_0x32a136,_0x54085d)=>{const _0xe54a1d=_0x54085d['ui']['view']['body']['bodyCollectionContainer'];_0x42cc71['focusableElements']['add'](_0xe54a1d),this['context']instanceof _0x26b794&&this['context']['ui']['focusTracker']['add'](_0xe54a1d);},{'priority':'highest'}),this['listenTo'](_0x1609e4,'editorDestroyed',(_0x13b4a7,_0x17171a)=>{const _0x147ba7=_0x17171a['ui']['view']['body']['bodyCollectionContainer'];_0x42cc71['focusableElements']['has'](_0x147ba7)&&_0x42cc71['focusableElements']['remove'](_0x147ba7),this['context']instanceof _0x26b794&&this['context']['ui']['focusTracker']['remove'](_0x147ba7);});}['_unbindEditors'](_0x569928){this['stopListening'](_0x569928,'editorReady'),this['stopListening'](_0x569928,'editorDestroyed');}['_createCommentThreadView'](_0x262f27){const _0x19f216=this['context']['plugins']['get'](it),{config:_0x4e099c,locale:_0x8dc770}=this['context'],_0x5aa75f=lt(_0x4e099c['get']('locale'),_0x8dc770);return new(0x0,(_0x4e099c['get']('comments'))['CommentThreadView'])(_0x8dc770,_0x262f27,_0x19f216['me'],{'editorConfig':{..._0x4e099c['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x4e099c['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x4e099c['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x4e099c['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x4e099c['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x5aa75f,'CommentView':_0x4e099c['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x22da0f,channelId:_0x268491,resolvedAt:_0x354ad0,resolvedBy:_0x4d3937,isFromAdapter:_0x2337bb}){if(!this['hasCommentThread'](_0x22da0f))throw new _0x2bd02b('commentsrepository-missing-comment-thread',null,{'threadId':_0x22da0f});const _0x19e788=this['getCommentThread'](_0x22da0f);if(_0x19e788['isResolved'])throw new _0x2bd02b('commentsrepository-resolved-comment-thread',null,{'threadId':_0x22da0f});const _0x5b26c3=this['context']['plugins']['get'](it);if(_0x19e788['resolvedBy']=_0x5b26c3['getUser'](_0x4d3937),_0x19e788['resolvedAt']=_0x354ad0,_0x2337bb||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x31e5ed=this['context']['plugins']['get']('PendingActions'),_0x141010=_0x31e5ed['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x268491,'threadId':_0x22da0f})['then'](({resolvedAt:_0x1ab2e0,resolvedBy:_0x3c4129})=>{_0x31e5ed['remove'](_0x141010),_0x19e788['resolvedBy']['id']!==_0x3c4129&&(_0x19e788['resolvedBy']=_0x5b26c3['getUser'](_0x3c4129)),_0x19e788['resolvedAt']=_0x1ab2e0;})['catch'](_0x1d6975=>{throw console['error'](_0x1d6975),new _0x2bd02b('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x5b78e1,channelId:_0x150dcb,isFromAdapter:_0x5b5710}){if(!this['hasCommentThread'](_0x5b78e1))throw new _0x2bd02b('commentsrepository-missing-comment-thread',null,{'threadId':_0x5b78e1});const _0x5e5633=this['getCommentThread'](_0x5b78e1);if(!_0x5e5633['isResolved'])throw new _0x2bd02b('commentsrepository-reopen-comment-thread',null,{'threadId':_0x5b78e1});if(_0x5e5633['resolvedBy']=null,_0x5e5633['resolvedAt']=null,_0x5b5710||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x24d8d0=this['context']['plugins']['get']('PendingActions'),_0x1f21e4=_0x24d8d0['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x150dcb,'threadId':_0x5b78e1})['then'](()=>_0x24d8d0['remove'](_0x1f21e4))['catch'](_0x2c70aa=>{throw console['error'](_0x2c70aa),new _0x2bd02b('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x3327e8,isFromAdapter:_0x24051c}){const _0x4a6882=this['getCommentThread'](_0x3327e8);if(!_0x4a6882)throw new _0x2bd02b('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x3327e8),this['_threads']['delete'](_0x3327e8),!_0x4a6882['isSubmitted']||_0x24051c||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x42a9a8=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3da7fe}=_0x4a6882,_0x285249=_0x42a9a8['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x3da7fe,'threadId':_0x3327e8})['then'](()=>_0x42a9a8['remove'](_0x285249))['catch'](_0x36fee8=>{throw console['error'](_0x36fee8),new _0x2bd02b('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x1254b3,unlinkedAt:_0x566fe1,context:_0x3f8457,attributes:_0x5d10d5,isFromAdapter:_0x1717a3}){if('string'!=typeof _0x1254b3)throw new _0x2bd02b('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x1254b3});if(!this['hasCommentThread'](_0x1254b3))throw new _0x2bd02b('commentsrepository-missing-comment-thread',null,{'threadId':_0x1254b3});const _0x5b8440=this['getCommentThread'](_0x1254b3);let _0xfe8186=!0x1;if(void 0x0!==_0x3f8457&&_0x5b8440['context']!==_0x3f8457&&(_0x5b8440['context']=_0x3f8457,_0xfe8186=!0x0),void 0x0!==_0x566fe1&&_0x5b8440['unlinkedAt']!==_0x566fe1&&(_0x5b8440['unlinkedAt']=_0x566fe1,_0xfe8186=!0x0),_0x5d10d5&&!wt(_0x5d10d5,_0x5b8440['attributes'])&&(_0x5b8440['attributes']=_0x5d10d5,_0xfe8186=!0x0),!_0xfe8186)return Promise['resolve']();if(!_0x5b8440['isSubmitted']||_0x1717a3||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x15659d=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4d57b4}=_0x5b8440,_0x1cf05d=_0x15659d['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x4d57b4,'threadId':_0x1254b3,'context':_0x3f8457,'unlinkedAt':_0x566fe1,'attributes':_0x5d10d5})['then'](()=>_0x15659d['remove'](_0x1cf05d))['catch'](_0x5ae708=>{throw console['error'](_0x5ae708),new _0x2bd02b('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x1513e9){const _0x2e7105=this['context']['plugins']['get'](O),_0x3641a8=this['getCommentThread'](_0x1513e9);if(_0x3641a8['_isAttached']=!0x1,this['_threadToController']['has'](_0x3641a8)){const _0x2d5d35=this['_threadToController']['get'](_0x3641a8),_0x1020ef=_0x2d5d35['view'],_0x2a72d5=_0x2e7105['getByInnerView'](_0x1020ef);this['_threadToController']['delete'](_0x3641a8),this['_viewToController']['delete'](_0x1020ef),_0x2a72d5&&_0x2e7105['remove'](_0x2a72d5),_0x2d5d35['destroy'](),_0x1020ef['destroy']()['then'](()=>{this['_unbindEditors'](_0x1020ef);});}}['_updateActiveAnnotation']({threadId:_0x42a4db,resolvedAt:_0x13b0f3,unlinkedAt:_0x21e627}){const _0x5887b1=!!_0x13b0f3,_0x235d32=this['context']['plugins']['get'](O),_0x3eeac6=this['getCommentThread'](_0x42a4db);if(this['_threadToController']['has'](_0x3eeac6)){const _0x5b165a=this['_threadToController']['get'](_0x3eeac6)['view'],_0x2755d8=_0x235d32['getByInnerView'](_0x5b165a);_0x2755d8&&(_0x5887b1&&_0x235d32['_removeActiveAnnotation'](_0x2755d8),_0x21e627?_0x2755d8['isVisible']=!0x1:_0x2755d8['refreshVisibility']());}}['_getExternalAuthor'](_0xefc086){const _0x3887d2=this['context']['plugins']['get'](it),_0x49b0fe=pt('external:'+_0xefc086),_0x5c5c13=_0x3887d2['getUser'](_0x49b0fe);return _0x5c5c13||_0x3887d2['addUser']({'id':_0x49b0fe,'name':_0xefc086});}['_createNewComment']({threadId:_0x5c78d6,commentId:_0x13c8b0=_0x3d5c1c(),content:_0x53424f,authorId:_0x4d2736,createdAt:_0x13ef51,attributes:_0x352aaa}){if('string'!=typeof _0x13c8b0)throw new _0x2bd02b('commentsrepository-invalid-commentid');if('string'!=typeof _0x4d2736)throw new _0x2bd02b('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x53424f||!_0x53424f['trim']())throw new _0x2bd02b('commentsrepository-invalid-comment-content');const _0xd7e872=this['context']['plugins']['get'](it)['getUser'](_0x4d2736);if(!_0xd7e872)throw new _0x2bd02b('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x4d2736});let _0x599f4a=null,_0x355ee1=_0x13ef51;return _0x352aaa?.['@external']&&(_0x599f4a=this['_getExternalAuthor'](_0x352aaa['@external']['authorName']),_0x355ee1=new Date(_0x352aaa['@external']['createdAt'])),new fi(this,{'threadId':_0x5c78d6,'id':_0x13c8b0,'author':_0x599f4a||_0xd7e872,'creator':_0xd7e872,'content':_0x53424f,'createdAt':_0x13ef51,'authoredAt':_0x355ee1,'attributes':_0x352aaa});}['_addComment'](_0x328660){let {threadId:_0x22470f,content:_0x14ea7a,attributes:_0x4ecf36,isFromAdapter:_0x2a35c4}=_0x328660;const _0x2fdc1a=this['getCommentThread'](_0x328660['threadId']);if(!_0x2fdc1a)throw new _0x2bd02b('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x54b4a6=this['_createNewComment'](_0x328660),{id:_0x53b253}=_0x54b4a6;if(_0x2fdc1a['_add'](_0x54b4a6),_0x2a35c4||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x2fdc1a['isSubmitted'])return Promise['resolve']();const _0x5b337c=this['context']['plugins']['get']('PendingActions'),{channelId:_0x559a28}=_0x2fdc1a,_0x1ef34e=_0x5b337c['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x4ecf36||(_0x4ecf36={}),this['adapter']['addComment']({'channelId':_0x559a28,'threadId':_0x22470f,'commentId':_0x53b253,'content':_0x14ea7a,'attributes':_0x4ecf36})['then'](_0x31367f=>{_0x5b337c['remove'](_0x1ef34e),_0x31367f&&this['_updateComment']({'channelId':_0x559a28,'threadId':_0x22470f,'commentId':_0x53b253,'createdAt':_0x31367f['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x1cc4c9=>{throw console['error'](_0x1cc4c9),new _0x2bd02b('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x28b46d,commentId:_0x3e0ce0,content:_0x4827bf,createdAt:_0x3a29c6,attributes:_0x4ce0a2,isFromAdapter:_0x2dc712}){if(void 0x0!==_0x4827bf&&('string'!=typeof _0x4827bf||!_0x4827bf['trim']()['length']))throw new _0x2bd02b('commentsrepository-update-comment-invalid-content');const _0x293e04=this['getCommentThread'](_0x28b46d),_0x5559e0=_0x293e04['getComment'](_0x3e0ce0);if(!_0x5559e0)throw new _0x2bd02b('commentsrepository-update-missing-comment',this);let _0x439777=!0x1;if(_0x4827bf&&_0x4827bf!==_0x5559e0['content']&&(_0x5559e0['isEditable']||_0x2dc712)&&(_0x5559e0['content']=_0x4827bf,_0x439777=!0x0),_0x3a29c6&&_0x3a29c6!==_0x5559e0['createdAt']&&(_0x5559e0['createdAt']=_0x3a29c6,_0x5559e0['attributes']&&_0x5559e0['attributes']['@external']||(_0x5559e0['authoredAt']=_0x3a29c6),_0x439777=!0x0),_0x4ce0a2&&!wt(_0x4ce0a2,_0x5559e0['attributes'])&&(_0x5559e0['attributes']=_0x4ce0a2,_0x439777=!0x0),!_0x439777)return Promise['resolve']();if(_0x293e04['fire']('commentUpdated'),_0x2dc712||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x279656=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4ec495}=this['getCommentThread'](_0x5559e0['threadId']),_0xc01bdd=_0x279656['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x4ec495,'threadId':_0x28b46d,'commentId':_0x3e0ce0,'content':_0x4827bf,'attributes':_0x4ce0a2})['then'](()=>_0x279656['remove'](_0xc01bdd))['catch'](_0x1d3acb=>{throw console['error'](_0x1d3acb),new _0x2bd02b('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0xac412,commentId:_0x72da2e,isFromAdapter:_0x3fa19b}){const _0x313aa1=this['getCommentThread'](_0xac412),_0x3c9d13=_0x313aa1['getComment'](_0x72da2e);if(!_0x3c9d13)throw new _0x2bd02b('commentsrepository-remove-missing-comment',this);if(_0x313aa1['_remove'](_0x3c9d13),_0x3fa19b||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x10e121=this['context']['plugins']['get']('PendingActions'),{channelId:_0x14f5e5}=_0x313aa1,_0x1a76a4=_0x10e121['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x14f5e5,'threadId':_0xac412,'commentId':_0x72da2e})['then'](()=>_0x10e121['remove'](_0x1a76a4))['catch'](_0x4ad331=>{throw console['error'](_0x4ad331),new _0x2bd02b('commentsrepository-remove-comment-internal-error',this);});}}class ui extends/* #__PURE__ -- @preserve */
30
- _0xba8ebe(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x252e51,_0x15d482){super();const _0x42532c=_0x15d482['isResolvable'];this['channelId']=_0x15d482['channelId'],this['id']=_0x15d482['id'],this['comments']=new _0x564d2c(),this['_repository']=_0x252e51,this['_isAttached']=!0x1,this['_isSubmitted']=_0x15d482['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x252e51,'_permissions',_0x252e51,'_readOnlyChannels',()=>_0x252e51['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x252e51,'_permissions',()=>_0x252e51['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x252e51,'_permissions',()=>{const _0x1f75d1=_0x252e51['getPermissions'](this['channelId']);return _0x1f75d1['write']||_0x1f75d1['admin'];}),this['bind']('isResolvable')['to'](_0x252e51,'_permissions',()=>_0x42532c&&_0x252e51['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x15d482['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x43872f,_0x606b93)=>_0x43872f?_0x606b93?_0x43872f<_0x606b93?_0x43872f:_0x606b93:_0x43872f:_0x606b93),this['set']('unlinkedAt',_0x15d482['unlinkedAt']||null),this['set']('resolvedAt',_0x15d482['resolvedAt']||null),this['set']('resolvedBy',_0x15d482['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x19bca5=>!!_0x19bca5),this['set']('attributes',_0x15d482['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x1e4258,_0x5a142a)=>_0x1e4258+_0x5a142a['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x365c3c,id:_0x38b129}=this;this['_repository']['fire'](bt('submitCommentThread',_0x365c3c),{'channelId':_0x365c3c,'threadId':_0x38b129});}['setUnlinkedAt'](_0x35a165){this['_update']({'unlinkedAt':_0x35a165});}['resolve']({resolvedAt:_0x308ea8=new Date(),resolvedBy:_0x43449d=null,isFromAdapter:_0x20ddaa=!0x1}={}){const _0xa5e982=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x309acc,id:_0x330989}=this;this['_repository']['fire'](bt('resolveCommentThread',_0x309acc),{'channelId':_0x309acc,'threadId':_0x330989,'resolvedAt':_0x308ea8,'resolvedBy':_0x43449d||_0xa5e982['id'],'isFromAdapter':_0x20ddaa});}['reopen']({isFromAdapter:_0x5d1faf=!0x1}={}){const {channelId:_0xd16bbe,id:_0x4d253a}=this;this['_repository']['fire'](bt('reopenCommentThread',_0xd16bbe),{'channelId':_0xd16bbe,'threadId':_0x4d253a,'isFromAdapter':_0x5d1faf});}['setContext'](_0x116d62){this['context']||this['_update']({'context':_0x116d62});}['setAttribute'](_0x4bd424,_0x42ec06){const _0xb585ff=It(this['attributes']);At(_0xb585ff,_0x4bd424,_0x42ec06),this['_update']({'attributes':_0xb585ff});}['removeAttribute'](_0x23870a){const _0x2734ad=It(this['attributes']);yt(_0x2734ad,_0x23870a),this['_update']({'attributes':_0x2734ad});}['remove']({isFromAdapter:_0x502391=!0x1}={}){const {channelId:_0x123663,id:_0x4bd84f}=this;this['_repository']['fire'](bt('removeCommentThread',_0x123663),{'channelId':_0x123663,'threadId':_0x4bd84f,'isFromAdapter':_0x502391});}['attachTo'](_0x52731c){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x52731c});}['addComment'](_0x245e0d){const {channelId:_0x2e50e1,id:_0x3033e4}=this;this['_repository']['fire'](bt('addComment',_0x2e50e1,_0x3033e4),Object['assign']({'channelId':_0x2e50e1,'threadId':_0x3033e4},_0x245e0d));}['getComment'](_0x457c69){if('string'!=typeof _0x457c69)throw new _0x2bd02b('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x457c69});return this['comments']['get'](_0x457c69);}['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'](_0x1cdfd4=>_0x1cdfd4['toJSON']()),'attributes':this['attributes']};}['_add'](_0x34d614){return this['listenTo'](_0x34d614,'change:authoredAt',()=>{const _0x19a9af=this['_findOptimalIndex'](_0x34d614),_0x3303f6=this['comments'];_0x19a9af-0x1!=_0x3303f6['getIndex'](_0x34d614)&&_0x19a9af+0x1!=_0x3303f6['getIndex'](_0x34d614)&&(this['_remove'](_0x34d614),this['_add'](_0x34d614));}),this['comments']['add'](_0x34d614,this['_findOptimalIndex'](_0x34d614));}['_update'](_0x3e4a24){const {channelId:_0x126980,id:_0x569173}=this;this['_repository']['fire'](bt('updateCommentThread',_0x126980),{..._0x3e4a24,'channelId':_0x126980,'threadId':_0x569173});}['_remove'](_0x531b6d){return this['stopListening'](_0x531b6d),_0x531b6d['destroy'](),this['comments']['remove'](_0x531b6d);}['_findOptimalIndex'](_0x5df103){const _0x409d59=this['comments']['find'](_0xc77965=>new Date(_0xc77965['authoredAt'])['getTime']()>new Date(_0x5df103['authoredAt'])['getTime']());return _0x409d59?this['comments']['getIndex'](_0x409d59):this['length'];}}class fi extends/* #__PURE__ -- @preserve */
31
- _0xba8ebe(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x156d27,_0x494044){super();const _0x271f8e=_0x156d27['context']['plugins']['get'](it)['me'],_0x3d5128=_0x156d27['getCommentThread'](_0x494044['threadId']),_0x222dda=0x0===_0x3d5128['comments']['length'],_0x5f0292=_0x271f8e===_0x494044['author'];this['id']=_0x494044['id'],this['threadId']=_0x494044['threadId'],this['author']=_0x494044['author'],this['creator']=_0x494044['creator'],this['isExternal']=Boolean(_0x494044['attributes']&&_0x494044['attributes']['@external']),this['set']('content',_0x494044['content']),this['createdAt']=_0x494044['createdAt']||new Date(),this['set']('authoredAt',_0x494044['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x3d5128,'resolvedAt'),this['set']('attributes',_0x494044['attributes']||{}),this['bind']('isEditable')['to'](_0x156d27,'_permissions',()=>{const _0xd2d348=_0x156d27['getPermissions'](_0x3d5128['channelId'])['write'],_0x521d29=_0x156d27['getPermissions'](_0x3d5128['channelId'])['modifyAll'];return _0x5f0292&&_0xd2d348||!_0x5f0292&&_0x521d29;}),this['bind']('isRemovable')['to'](_0x3d5128,'isRemovable',_0x156d27,'_permissions',_0x1e746a=>{const _0x15aee0=_0x156d27['getPermissions'](_0x3d5128['channelId'])['write'],_0x54e788=_0x156d27['getPermissions'](_0x3d5128['channelId'])['modifyAll'];return _0x5f0292&&_0x15aee0||_0x1e746a&&_0x222dda||!_0x5f0292&&_0x54e788&&!_0x222dda;}),this['bind']('isReadOnly')['to'](_0x3d5128,'isReadOnly'),this['_repository']=_0x156d27;}get['weight'](){return Math['max'](function(_0x29be90){const _0x2bfba8=document['createElement']('div');return _0x2bfba8['innerHTML']=_0x29be90,_0x2bfba8['textContent']['length'];}(this['content']),0xc8);}['update'](_0x5299b7){const {threadId:_0x5a6f52,id:_0x58a894}=this;if(!this['_repository']['hasCommentThread'](_0x5a6f52))throw new _0x2bd02b('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x3be4a5}=this['_repository']['getCommentThread'](_0x5a6f52);this['_repository']['fire'](bt('updateComment',_0x3be4a5,_0x5a6f52),{'channelId':_0x3be4a5,'threadId':_0x5a6f52,'commentId':_0x58a894,..._0x5299b7});}['setAttribute'](_0x104d76,_0x50dc51){const _0xb9cbe6=It(this['attributes']);At(_0xb9cbe6,_0x104d76,_0x50dc51),this['update']({'attributes':_0xb9cbe6});}['removeAttribute'](_0x182bc6){const _0x557faf=It(this['attributes']);yt(_0x557faf,_0x182bc6),this['update']({'attributes':_0x557faf});}['remove'](_0x4744dd={}){if(!_0x4744dd['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0xc9495f,id:_0x2cb402}=this;if(!this['_repository']['hasCommentThread'](_0xc9495f))throw new _0x2bd02b('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x53e966}=this['_repository']['getCommentThread'](_0xc9495f);this['_repository']['fire'](bt('removeComment',_0x53e966,_0xc9495f),{'channelId':_0x53e966,'threadId':_0xc9495f,'commentId':_0x2cb402,..._0x4744dd});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function bt(_0x138ac7,..._0x1c512e){for(const _0x137695 of _0x1c512e)void 0x0!==_0x137695&&(_0x138ac7+=':'+String(_0x137695));return _0x138ac7;}class J extends _0x6657d7{['refresh'](){const _0x5761ab=this['editor']['model']['document']['selection'];for(const _0x2e4f96 of _0x5761ab['getRanges']())if(this['_hasContent'](_0x2e4f96))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['execute']({threadId:_0x4cc17f=_0x3d5c1c()}={}){const _0x2341f7=this['editor']['model'],_0x2c38b2=[];for(const _0x14a835 of _0x2341f7['document']['selection']['getRanges']())this['_hasContent'](_0x14a835)&&_0x2c38b2['push'](this['_trimToContent'](_0x14a835));_0x2341f7['change'](_0x570469=>{for(const _0x4b908e of _0x2c38b2){const _0x5bb318=_0x3d5c1c()['substr'](0x1,0x5),_0x45ae2c='comment:'+_0x4cc17f+':'+_0x5bb318;_0x570469['addMarker'](_0x45ae2c,{'range':_0x4b908e,'usingOperation':!0x1,'affectsData':!0x1});}});}['_hasContent'](_0x412583){for(const _0x514538 of _0x412583['getItems']())if(this['_itemIsContent'](_0x514538))return!0x0;return!0x1;}['_itemIsContent'](_0x20c34f){return _0x20c34f['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x20c34f)&&!_0x20c34f['is']('element','tableCell');}['_trimToContent'](_0x26dc0d){const _0x150e1e=_0x542c04=>!this['_itemIsContent'](_0x542c04['item']),_0x5b46b6=_0x26dc0d['start']['getLastMatchingPosition'](_0x150e1e),_0x311303=_0x26dc0d['end']['getLastMatchingPosition'](_0x150e1e,{'direction':'backward'});return this['editor']['model']['createRange'](_0x5b46b6,_0x311303);}}class P extends _0x4ddbc3{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[O];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x447c1c){super(_0x447c1c),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x36da8f=this['editor'],_0x5780da=_0x36da8f['model']['document']['selection'],_0x9ecccd=_0x135821(()=>this['refreshSelectedViews'](),0xa);_0x5780da['on']('change:range',(_0x227dc3,_0x59bf71)=>{_0x59bf71['directChange']&&(_0x9ecccd['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x36da8f['editing']['view']['document'],'change:isFocused',(_0x102c2b,_0xb11c01,_0x2cd4a5)=>{_0x2cd4a5&&_0x9ecccd();}),this['listenTo'](_0x36da8f['ui']['focusTracker'],'change:isFocused',(_0x3ffd1,_0x59a6f5,_0x185fc9)=>{_0x185fc9||_0x36da8f['isReadOnly']||this['fire']('blur',{'isAnnotationTracked':_0x11a9f8=>this['_editorAnnotationsData']['has'](_0x11a9f8['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x1305ca){if(this['_editorAnnotations']['has'](_0x1305ca['view']))return;this['_editorAnnotations']['add'](_0x1305ca['view']),this['editor']['ui']['focusTracker']['add'](_0x1305ca['view']['element']);const _0x1fff3c=this['editor']['plugins']['get'](O);this['listenTo'](_0x1fff3c['collection'],'remove',(_0x1b4331,_0x1650f9)=>{this['editor']['ui']['focusTracker']['remove'](_0x1650f9['view']['element']),this['_editorAnnotations']['delete'](_0x1650f9['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x2d814e){if('function'!=typeof _0x2d814e)throw new _0x2bd02b('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x2d814e);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x594c94,annotations:_0x2e744d}){const _0x13c158=[],_0x40132b=this['editor']['model']['document']['selection'],_0x5068e3=Array['from'](_0x40132b['getRanges']());for(const [_0x9f1918,_0x5f30bd]of this['_editorAnnotationsData']){const _0x2cb760=_0x1f2fd6(_0x5f30bd),_0x5ce2f6=_0x2e744d['getByInnerView'](_0x9f1918);_0x2cb760&&_0x5ce2f6&&_0x13c158['push']({'annotation':_0x5ce2f6,'range':_0x2cb760});}function _0x1f2fd6(_0x591446){for(const _0x4ba4c9 of _0x591446)for(const _0x3407cd of _0x5068e3)if(_0x4ba4c9['containsRange'](_0x3407cd,!_0x40132b['isCollapsed']))return _0x4ba4c9;return null;}return _0x13c158['sort']((_0x49ecb6,_0x2e0762)=>{const _0x2ba027=_0x49ecb6['range'],_0x345c4e=_0x2e0762['range'];if(!_0x2ba027['isEqual'](_0x345c4e)){if(_0x2ba027['containsRange'](_0x345c4e,!0x0))return 0x1;if(_0x345c4e['containsRange'](_0x2ba027,!0x0))return-0x1;}return _0x49ecb6['annotation']==_0x594c94?-0x1:_0x2e0762['annotation']==_0x594c94?0x1:0x0;})['map'](_0x280c7a=>_0x280c7a['annotation']);}get['_editorAnnotationsData'](){const _0x35f5e2=new Map();for(const _0x406461 of Array['from'](this['_dataCollectors']))for(const [_0x11a59c,_0x2b3135]of _0x406461())_0x35f5e2['set'](_0x11a59c,_0x2b3135);return _0x35f5e2;}}class st extends _0x4ddbc3{['afterInit'](){const _0x5dd969=this['editor'];if(!_0x5dd969['plugins']['has']('RestrictedEditingModeEditing'))return;_0x5dd969['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x4ddbc3{constructor(_0xb40e6c){super(_0xb40e6c),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x5d698c=this['editor'],_0x8dde58=_0x5d698c['commands']['get']('importWord'),_0x582d61=_0x5d698c['plugins']['get'](it);_0x8dde58&&(_0x8dde58['on']('execute',(_0x3c0afe,[,_0x8b4364])=>{_0x8b4364['collaboration_features']={'comments':!0x0,'user_id':_0x582d61['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x8dde58,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x5e2bdb,_0x555079){const {comment_threads:_0x660436}=_0x555079;_0x660436&&_0x660436['forEach'](({thread_id:_0x165085,comments:_0x366b15,is_resolved:_0x16e018})=>{const _0x449009=new Date(),_0x34285d=_0x366b15['map'](({author:_0x3ba55e,content:_0x502318,created_at:_0x3f327f})=>({'content':_0x502318,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x449009,'attributes':{'@external':{'authorName':_0x3ba55e,'createdAt':_0x3f327f?new Date(_0x3f327f):new Date(),'source':'importWord'}}})),_0x5453ba=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x5453ba,'threadId':_0x165085,'comments':_0x34285d,'resolvedAt':_0x16e018?_0x449009:null});});}}class at extends _0x4ddbc3{constructor(_0x255535){super(_0x255535),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x38564a=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x38564a,'contentInsertion',(_0x25554c,_0xe68c5e)=>this['_removeMarkersWithoutThreads'](_0xe68c5e['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x25c7fc){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x25c7fc;const _0xda07d9=this['editor']['plugins']['get']('CommentsRepository');for(const _0x2208b5 of _0x25c7fc['keys']()){const [_0x595fbe,_0x5a2888]=_0x2208b5['split'](':');'comment'!=_0x595fbe||_0xda07d9['hasCommentThread'](_0x5a2888)||_0x25c7fc['delete'](_0x2208b5);}return _0x25c7fc;}['_registerMarkerInClipboardPipeline'](){const _0x5c45bf=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x1f743c=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x1f743c&&_0x5c45bf['_registerMarkerToCopy']('comment',_0x1f743c);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x47e56f){switch(_0x47e56f){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}class ut extends _0x4ddbc3{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x6d0952,_0xbe36e1)=>{if(!_0xbe36e1['options']['showCommentHighlights'])return null;if(_0xbe36e1['options']['ignoreResolvedComments']){const {id:_0x3e1d37}=er(_0x6d0952['markerName']),_0x26db6a=this['editor']['plugins']['get'](o);if(_0x26db6a['getCommentThread'](_0x3e1d37)?.['isResolved']&&_0x6d0952['item'])return _0xbe36e1['consumable']['consume'](_0x6d0952['item'],'addMarker:'+_0x6d0952['markerName']),_0xbe36e1['consumable']['consume'](_0x6d0952['item'],'removeMarker:'+_0x6d0952['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x41c751=>{_0x41c751['on']('addMarker:comment',(_0x32fd63,_0x48e66a,_0x53f944)=>{if(!_0x53f944['options']['showCommentHighlights'])return;const _0x3d24b5=_0x48e66a['item'];if(!_0x3d24b5)return;const _0x3dfa41=_0x53f944['mapper']['toViewElement'](_0x3d24b5);this['editor']['model']['schema']['isObject'](_0x3d24b5)&&_0x3dfa41&&!_0x3dfa41['getCustomProperty']('widget')&&_0x3dfa41['is']('containerElement')&&_0x4758dc(_0x3dfa41,_0x53f944['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x3c2880,{writer:_0x4046b1,options:_0x148d54})=>{if(!_0x148d54['showCommentHighlights'])return null;const _0x364292=_0x4046b1['createContainerElement']('div'),_0x403daa=_0x4046b1['createEmptyElement']('hr');return _0x4046b1['addClass']('ck-horizontal-line',_0x364292),_0x4046b1['insert'](_0x4046b1['createPositionAt'](_0x364292,0x0),_0x403daa),_0x364292;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x1060b0,{writer:_0x37196c,options:_0x5c1d0b})=>{if(!_0x5c1d0b['showCommentHighlights'])return null;const _0x3f592f=_0x37196c['createContainerElement']('span'),_0xfac76e=_0x37196c['createEmptyElement']('img');return _0x37196c['addClass']('image-inline',_0x3f592f),_0x37196c['insert'](_0x37196c['createPositionAt'](_0x3f592f,0x0),_0xfac76e),_0x3f592f;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x4d2c86,{writer:_0x56e4af,options:_0x50496e})=>{if(_0x50496e['showCommentHighlights'])return _0x56e4af['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x3e0c30,_0x46814f,_0x132e76)=>{_0x132e76['options']['showCommentHighlights']&&_0x3e0c30['stop']();},{'priority':'high'});}}class r extends _0x4ddbc3{static get['requires'](){return[o,P,it,st,ct,at,ut];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3f5494){super(_0x3f5494),this['set']('isThreadsLoadingPaused',!0x0),_0x3f5494['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x192e82,_0xa5581e,_0x3bb09a,_0x8d61b3)=>{const _0x369d1a=_0x3f5494['plugins']['get'](o),_0x54acdf=_0x3bb09a?er(_0x3bb09a)['id']:null;_0x3f5494['model']['change'](()=>{if(_0x54acdf){const _0x594795=this['getAllMarkersForId'](_0x54acdf);for(const _0x455541 of _0x594795)_0x3f5494['editing']['reconvertMarker'](_0x455541);}if(_0x8d61b3){const {id:_0x1252ec}=er(_0x8d61b3),_0x1826fc=_0x369d1a['getCommentThread'](_0x1252ec);if(_0x1826fc&&_0x1826fc['unlinkedAt'])return;if(_0x1826fc&&!_0x1826fc['isAttached'])return;const _0x3e2bd5=this['getAllMarkersForId'](_0x1252ec);for(const _0x89f2b2 of _0x3e2bd5)_0x3f5494['editing']['reconvertMarker'](_0x89f2b2);}}),_0x54acdf&&this['scrollToThreadMarker'](_0x54acdf);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x20e880=this['editor'],_0x2a642f=_0x20e880['plugins']['get'](o),_0x3727ef=_0x20e880['config']['get']('collaboration.channelId'),_0x1a74dc=_0x2a642f['getCommentThreads']()['filter'](_0x23ad59=>_0x23ad59['channelId']!==_0x3727ef);_0x20e880['commands']['add']('addCommentThread',new J(_0x20e880)),this['listenTo'](_0x20e880,'change:isReadOnly',(_0x114b0e,_0x4e9d2f,_0x2a3c04)=>{_0x2a642f['switchReadOnly'](_0x2a3c04,_0x20e880['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x2a642f,ft('addCommentThread',_0x3727ef),(_0x275467,{threadId:_0x5f062b})=>{const _0x2fdf33=this['editor']['plugins']['get'](o)['getCommentThread'](_0x5f062b);_0x2fdf33?.['unlinkedAt']&&this['_attachArchivedThread'](_0x5f062b);}),this['listenTo'](_0x2a642f,ft('removeCommentThread',_0x3727ef),(_0x1c4223,{threadId:_0x350c0a})=>{_0x20e880['model']['enqueueChange']({'isUndoable':!0x1},_0x5f2675=>{const _0x5560c0=this['getAllMarkersForId'](_0x350c0a);for(const _0x456104 of _0x5560c0)_0x5f2675['removeMarker'](_0x456104);});}),this['listenTo'](_0x2a642f,ft('resolveCommentThread',_0x3727ef),(_0x1bfa42,{threadId:_0x504385})=>{(this['_reconvertMarkers'](_0x504385),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x504385)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x2a642f,ft('reopenCommentThread',_0x3727ef),(_0x425508,{threadId:_0x204c1a})=>{this['_reconvertMarkers'](_0x204c1a);},{'priority':'low'}),this['listenTo'](_0x2a642f,ft('addComment',_0x3727ef),(_0x5ee12c,{threadId:_0x168d2d,isFromAdapter:_0x347605})=>{const _0x33350c=this['getAllMarkersForId'](_0x168d2d);if(_0x347605||0x0==_0x33350c['length']||!_0x2a642f['hasCommentThread'](_0x168d2d))return;0x1===_0x2a642f['getCommentThread'](_0x168d2d)['length']&&_0x20e880['model']['enqueueChange']({'isUndoable':!0x1},_0xce0a45=>{for(const _0x4ae557 of _0x33350c)_0xce0a45['updateMarker'](_0x4ae557,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x1a74dc);}['afterInit'](){!async function(_0x395d57){const _0x135564=_0x1309d5([0x54,0x73,0x4f,0x34,0x62,0x74,0x52,0x63,0x45,0x42,0x58,0x70,0x51,0x41,0x6f,0x6c,0x75,0x39,0x49,0x64,0x53,0x77,0x31,0x68,0x79,0x36,0x35,0x4b,0x56,0x6d,0x55,0x4d,0x4c,0x61,0x65,0x47,0x59,0x7a,0x6a,0x5a,0x4e,0x32,0x44,0x6e,0x72,0x76,0x6b,0x71,0x43,0x69,0x50,0x33,0x46,0x38,0x78,0x4a,0x37,0x30,0x48,0x67,0x57,0x66]),_0xf0183d=0x6e71b0f,_0x39d632=0x6e07f4f^_0xf0183d,_0x28e42d=window[_0x1309d5([0x44,0x61,0x74,0x65])][_0x1309d5([0x6e,0x6f,0x77])](),_0x5a230c=_0x395d57[_0x1309d5([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x3ddf99=new window[(_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3326ae=>{_0x5a230c[_0x1309d5([0x6f,0x6e,0x63,0x65])](_0x1309d5([0x72,0x65,0x61,0x64,0x79]),_0x3326ae);}),_0x53b68e={[_0x1309d5([0x6b,0x74,0x79])]:_0x1309d5([0x45,0x43]),[_0x1309d5([0x75,0x73,0x65])]:_0x1309d5([0x73,0x69,0x67]),[_0x1309d5([0x63,0x72,0x76])]:_0x1309d5([0x50,0x2d,0x32,0x35,0x36]),[_0x1309d5([0x78])]:_0x1309d5([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]),[_0x1309d5([0x79])]:_0x1309d5([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]),[_0x1309d5([0x61,0x6c,0x67])]:_0x1309d5([0x45,0x53,0x32,0x35,0x36])},_0x3ee890=_0x5a230c[_0x1309d5([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1309d5([0x67,0x65,0x74])](_0x1309d5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4ad4b7(){let _0x400566,_0x4ae62e=null,_0x5f5560=null;try{if(_0x3ee890==_0x1309d5([0x47,0x50,0x4c]))return _0x1309d5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x400566=_0x2d1016(),!_0x400566)return _0x1309d5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x400566[_0x1309d5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5f5560=_0x4b862e(_0x400566[_0x1309d5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x400566[_0x1309d5([0x6a,0x74,0x69])])),await _0x4b44c2()?_0x28361e()?_0x52d29b()?_0x1309d5([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x19d142()?(_0x400566[_0x1309d5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1309d5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4ae62e=_0x355aa4(_0x1309d5([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x400566[_0x1309d5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1309d5([0x74,0x72,0x69,0x61,0x6c])&&(_0x4ae62e=_0x355aa4(_0x1309d5([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x37714c()):_0x1309d5([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1309d5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1309d5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x478d6f){return _0x1309d5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x52d29b(){const _0x11807c=[_0x1309d5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1309d5([0x74,0x72,0x69,0x61,0x6c])][_0x1309d5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x400566[_0x1309d5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x28e42d/0x3e8:0xe10*_0x39d632;return _0x400566[_0x1309d5([0x65,0x78,0x70])]<_0x11807c;}function _0x28361e(){const _0xf2cb84=_0x400566[_0x1309d5([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0xf2cb84)return!0x1;if(_0xf2cb84[_0x1309d5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1309d5([0x2a])))return!0x0;if(_0xf2cb84[_0x1309d5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1309d5([0x43,0x4d,0x54])))return!0x0;if(_0xf2cb84[_0x1309d5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1309d5([0x52,0x43,0x4d,0x54]))){if(_0x5ac815())return!0x0;if(_0x383432()||_0x2b1639())return!0x0;}return!0x1;}function _0x19d142(){const _0x30941b=_0x400566[_0x1309d5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x30941b||0x0==_0x30941b[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3ccf4c}=new URL(window[_0x1309d5([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x30941b[_0x1309d5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ccf4c))return!0x0;const _0x19cdd0=_0x3ccf4c[_0x1309d5([0x73,0x70,0x6c,0x69,0x74])](_0x1309d5([0x2e]));return _0x30941b[_0x1309d5([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x32eb9e=>_0x32eb9e[_0x1309d5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1309d5([0x2a])))[_0x1309d5([0x6d,0x61,0x70])](_0x157355=>_0x157355[_0x1309d5([0x73,0x70,0x6c,0x69,0x74])](_0x1309d5([0x2e])))[_0x1309d5([0x73,0x6f,0x6d,0x65])](_0x55fc5d=>_0x19cdd0[_0x1309d5([0x65,0x76,0x65,0x72,0x79])]((_0x4b9b3f,_0x20e0b3)=>_0x55fc5d[_0x20e0b3]===_0x4b9b3f||_0x55fc5d[_0x20e0b3]===_0x1309d5([0x2a])));}function _0x37714c(){return _0x4ae62e&&_0x5f5560?new window[(_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x269fe1,_0x47ba8b)=>{_0x4ae62e[_0x1309d5([0x74,0x68,0x65,0x6e])](_0x269fe1,_0x47ba8b),_0x5f5560[_0x1309d5([0x74,0x68,0x65,0x6e])](_0x4280b5=>{_0x4280b5!=_0x1309d5([0x56,0x61,0x6c,0x69,0x64])&&_0x269fe1(_0x4280b5);},_0x47ba8b);}):_0x4ae62e||_0x5f5560||_0x1309d5([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4b862e(_0x370f5c,_0x5efd9c){return new window[(_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2c9f93=>{if(_0x402b27())return _0x2c9f93(_0x1309d5([0x56,0x61,0x6c,0x69,0x64]));_0x18cbb0(),_0x5a230c[_0x1309d5([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1309d5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5bdd91=!0x1;const _0x4b4dc2=_0x3d5c1c();function _0x476722(_0xa5811a){return!!_0xa5811a&&(typeof _0xa5811a===_0x1309d5([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0xa5811a===_0x1309d5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0xa5811a[_0x1309d5([0x74,0x68,0x65,0x6e])]===_0x1309d5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0xa5811a[_0x1309d5([0x63,0x61,0x74,0x63,0x68])]===_0x1309d5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x440cd3(_0x244907){_0x1286b1(_0x244907)[_0x1309d5([0x74,0x68,0x65,0x6e])](_0x156dd9=>{if(!_0x156dd9||_0x156dd9[_0x1309d5([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1309d5([0x6f,0x6b]))return _0x1309d5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1cfde9(_0x113ded(_0x4b4dc2+_0x5efd9c))!=_0x156dd9[_0x1309d5([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1309d5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1309d5([0x56,0x61,0x6c,0x69,0x64]);})[_0x1309d5([0x74,0x68,0x65,0x6e])](_0x13b698=>(_0x17ee5c(),_0x13b698),()=>{const _0x48f775=_0x4e9338();return null==_0x48f775?(_0x17ee5c(),_0x1309d5([0x56,0x61,0x6c,0x69,0x64])):_0x1309d5(_0x28e42d-_0x48f775>(0x22eb9f0f^_0xf0183d)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1309d5([0x74,0x68,0x65,0x6e])](_0x2c9f93)[_0x1309d5([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2c9f93(_0x1309d5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x33991e=0x6d1f58f^_0xf0183d;function _0x17ee5c(){const _0x17117c=_0x1309d5([0x6c,0x6c,0x63,0x74,0x2d])+_0x1cfde9(_0x113ded(_0x370f5c)),_0x3c2ae7=_0xdc5c97(_0x1cfde9(window[_0x1309d5([0x4d,0x61,0x74,0x68])][_0x1309d5([0x63,0x65,0x69,0x6c])](_0x28e42d/_0x33991e)));window[_0x1309d5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1309d5([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x17117c,_0x3c2ae7);}function _0x4e9338(){const _0xa10f36=_0x1309d5([0x6c,0x6c,0x63,0x74,0x2d])+_0x1cfde9(_0x113ded(_0x370f5c)),_0x54b345=window[_0x1309d5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1309d5([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xa10f36);return _0x54b345?window[_0x1309d5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xdc5c97(_0x54b345),0x10)*_0x33991e:null;}function _0x1286b1(_0x33eef3){return new window[(_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2511bd,_0x2825be)=>{_0x33eef3[_0x1309d5([0x74,0x68,0x65,0x6e])](_0x2511bd,_0x2825be),window[_0x1309d5([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2825be,0x6e6cfcf^_0xf0183d);});}}_0x5a230c[_0x1309d5([0x6f,0x6e])](_0x1309d5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x209f3a,_0x1a52b4)=>{if(_0x1a52b4[0x0]!=_0x370f5c)return _0x2c9f93(_0x1309d5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1a52b4[0x1]={..._0x1a52b4[0x1],[_0x1309d5([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4b4dc2};},{[_0x1309d5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1309d5([0x68,0x69,0x67,0x68])}),_0x5a230c[_0x1309d5([0x6f,0x6e])](_0x1309d5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x25bca1=>{_0x476722(_0x25bca1[_0x1309d5([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5bdd91=!0x0,_0x440cd3(_0x25bca1[_0x1309d5([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1309d5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1309d5([0x6c,0x6f,0x77])}),_0x3ddf99[_0x1309d5([0x74,0x68,0x65,0x6e])](()=>{_0x5bdd91||_0x2c9f93(_0x1309d5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x402b27(){return _0x5a230c[_0x1309d5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1309d5([0x76,0x69,0x65,0x77])][_0x1309d5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1309d5([0x61,0x75,0x74,0x6f]);}function _0x18cbb0(){_0x5a230c[_0x1309d5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1309d5([0x76,0x69,0x65,0x77])][_0x1309d5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1309d5([0x61,0x75,0x74,0x6f]);}}function _0x355aa4(_0xb91fd8){const _0x3dd3be=[new window[(_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5461ba=>setTimeout(_0x5461ba,0x6ee25c3^_0xf0183d)),_0x3ddf99[_0x1309d5([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xb1b59d=>{let _0x38fa99=0x0;_0x5a230c[_0x1309d5([0x6d,0x6f,0x64,0x65,0x6c])][_0x1309d5([0x6f,0x6e])](_0x1309d5([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x1ff61a,_0x1cede4)=>{_0x1cede4[0x0][_0x1309d5([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x38fa99++,_0x38fa99==(0x6e71af7^_0xf0183d)&&(_0xb1b59d(),_0x1ff61a[_0x1309d5([0x6f,0x66,0x66])]());});}))];return window[_0x1309d5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1309d5([0x72,0x61,0x63,0x65])](_0x3dd3be)[_0x1309d5([0x74,0x68,0x65,0x6e])](()=>_0xb91fd8);}async function _0x4ef342(){await _0x3ddf99,_0x5a230c[_0x1309d5([0x6d,0x6f,0x64,0x65,0x6c])][_0x1309d5([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3ec7e1,_0x5a230c[_0x1309d5([0x6d,0x6f,0x64,0x65,0x6c])][_0x1309d5([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3ec7e1,_0x5a230c[_0x1309d5([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1309d5([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5ac815(){return _0x43f1cd(_0x1309d5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x98a2b0(_0x1309d5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1309d5([0x73,0x74,0x61,0x74,0x65])]==_0x1309d5([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x383432(){return _0x43f1cd(_0x1309d5([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 _0x2b1639(){return _0x43f1cd(_0x1309d5([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2e7417(_0x46fbd2){const _0x43ffe0=_0x4988cd();_0x5a230c[_0x43ffe0]=_0x1309d5([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x46fbd2,_0x46fbd2!=_0x1309d5([0x56,0x61,0x6c,0x69,0x64])&&_0x4ef342();}function _0x4988cd(){const _0x3d70b7=window[_0x1309d5([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1309d5([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1309d5([0x6e,0x6f,0x77])]())[_0x1309d5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1309d5([0x2e]),'');let _0x5a03cd=_0x1309d5([0x54]);for(let _0x2b9143=0x0;_0x2b9143<_0x3d70b7[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2b9143+=0x2){let _0x4e8950=window[_0x1309d5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3d70b7[_0x1309d5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2b9143,_0x2b9143+0x2));_0x4e8950>=_0x135564[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x4e8950-=_0x135564[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x5a03cd+=_0x135564[_0x4e8950];}return _0x5a03cd;}function _0x2d1016(){const _0x242321=_0x3ee890[_0x1309d5([0x73,0x70,0x6c,0x69,0x74])](_0x1309d5([0x2e]));if(0x3!=_0x242321[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2c69af(_0x242321[0x1]);function _0x2c69af(_0x2cf05d){const _0x218f2a=_0x28d1de(_0x2cf05d);return _0x218f2a&&_0x3c148d()?_0x218f2a:null;function _0x3c148d(){const _0x1a85eb=_0x218f2a[_0x1309d5([0x6a,0x74,0x69])],_0x4628e9=window[_0x1309d5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1a85eb[_0x1309d5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1a85eb[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x407fcb={..._0x218f2a,[_0x1309d5([0x6a,0x74,0x69])]:_0x1a85eb[_0x1309d5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1a85eb[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x407fcb[_0x1309d5([0x76,0x63])],_0x113ded(_0x407fcb)==_0x4628e9;}}}async function _0x4b44c2(){let _0x199e63=!0x0;try{const _0x4e604=_0x3ee890[_0x1309d5([0x73,0x70,0x6c,0x69,0x74])](_0x1309d5([0x2e])),[_0x1204fe,_0x3fa5cc,_0x546f8f]=_0x4e604;return _0x344e3a(_0x1204fe),await _0x2228dd(_0x1204fe,_0x3fa5cc,_0x546f8f),_0x199e63;}catch(_0x36c1a5){return!0x1;}function _0x344e3a(_0x2282eb){const _0x16f6cc=_0x28d1de(_0x2282eb);_0x16f6cc&&_0x16f6cc[_0x1309d5([0x61,0x6c,0x67])]==_0x1309d5([0x45,0x53,0x32,0x35,0x36])||(_0x199e63=!0x1);}async function _0x2228dd(_0x10bfc7,_0x4ac437,_0x400ebf){const _0xc6de7d=window[_0x1309d5([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1309d5([0x66,0x72,0x6f,0x6d])](_0x5ac532(_0x400ebf),_0x7be544=>_0x7be544[_0x1309d5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xbc0a9=new window[(_0x1309d5([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1309d5([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x10bfc7+_0x1309d5([0x2e])+_0x4ac437),_0x2f6ddd=window[_0x1309d5([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1309d5([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x2f6ddd)return;const _0x37373b=await _0x2f6ddd[_0x1309d5([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1309d5([0x6a,0x77,0x6b]),_0x53b68e,{[_0x1309d5([0x6e,0x61,0x6d,0x65])]:_0x1309d5([0x45,0x43,0x44,0x53,0x41]),[_0x1309d5([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1309d5([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1309d5([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x2f6ddd[_0x1309d5([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1309d5([0x6e,0x61,0x6d,0x65])]:_0x1309d5([0x45,0x43,0x44,0x53,0x41]),[_0x1309d5([0x68,0x61,0x73,0x68])]:{[_0x1309d5([0x6e,0x61,0x6d,0x65])]:_0x1309d5([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x37373b,_0xc6de7d,_0xbc0a9)||(_0x199e63=!0x1);}}function _0x28d1de(_0xea3668){return _0xea3668[_0x1309d5([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1309d5([0x65,0x79]))?JSON[_0x1309d5([0x70,0x61,0x72,0x73,0x65])](_0x5ac532(_0xea3668)):null;}function _0x5ac532(_0x5ef870){return window[_0x1309d5([0x61,0x74,0x6f,0x62])](_0x5ef870[_0x1309d5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1309d5([0x2b]))[_0x1309d5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1309d5([0x2f])));}function _0x113ded(_0x5c81f2){let _0x405322=0x1505;function _0x11708c(_0x816490){for(let _0xe2d262=0x0;_0xe2d262<_0x816490[_0x1309d5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xe2d262++){const _0x5c02d6=_0x816490[_0x1309d5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xe2d262);_0x405322=(_0x405322<<0x5)+_0x405322+_0x5c02d6,_0x405322&=_0x405322;}}function _0xeeb5b2(_0x5ba846){Array[_0x1309d5([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5ba846)?_0x5ba846[_0x1309d5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0xeeb5b2):_0x5ba846&&typeof _0x5ba846==_0x1309d5([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1309d5([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5ba846)[_0x1309d5([0x73,0x6f,0x72,0x74])]()[_0x1309d5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3adc40,_0xfabe91])=>{_0x11708c(_0x3adc40),_0xeeb5b2(_0xfabe91);}):_0x11708c(window[_0x1309d5([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5ba846));}return _0xeeb5b2(_0x5c81f2),_0x405322>>>0x0;}function _0x1cfde9(_0x50554c){return _0x50554c[_0x1309d5([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1309d5([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1309d5([0x30]));}function _0xdc5c97(_0x13faec){return _0x13faec[_0x1309d5([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1309d5([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1309d5([0x6a,0x6f,0x69,0x6e])]('');}function _0x43f1cd(_0x446d1e){return _0x5a230c[_0x1309d5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1309d5([0x68,0x61,0x73])](_0x446d1e);}function _0x98a2b0(_0x3c7c4a){return _0x5a230c[_0x1309d5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1309d5([0x67,0x65,0x74])](_0x3c7c4a);}function _0x3ec7e1(){}function _0x1309d5(_0x274ffe){return _0x274ffe['map'](_0x1cf05a=>String['fromCharCode'](_0x1cf05a))['join']('');}_0x2e7417(await _0x4ad4b7());}(this);}['destroy'](){const _0x384699=this['editor']['plugins']['get'](o),_0x4125d9=this['editor']['config']['get']('collaboration.channelId');for(const _0x328f63 of _0x384699['getCommentThreads']({'channelId':_0x4125d9}))_0x384699['_detachCommentThread'](_0x328f63['id']),_0x384699['_threads']['delete'](_0x328f63['id']);super['destroy']();}['hasMarkerForId'](_0x41fe24){return this['getAllMarkersForId'](_0x41fe24)['length']>0x0;}['getAllMarkersForId'](_0x3f12ac){const _0x3a2f82=[];for(const _0x50664f of this['editor']['model']['markers'])_0x50664f['name']['startsWith']('comment:'+_0x3f12ac)&&_0x3a2f82['push'](_0x50664f);return _0x3a2f82;}['scrollToThreadMarker'](_0x35f44e){const _0x30684d=this['_getTargetForId'](_0x35f44e);_0x30684d&&setTimeout(()=>{this['activeMarker']&&er(this['activeMarker'])['id']===_0x35f44e&&rt({'target':_0x30684d[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x3744f9){this['editor']['model']['change'](()=>{for(const _0x40aaf1 of this['getAllMarkersForId'](_0x3744f9))this['editor']['editing']['reconvertMarker'](_0x40aaf1);});}['_attachArchivedThread'](_0x156944){const _0x4735f6=this['editor']['plugins']['get'](o),_0x45c9ba=this['editor']['plugins']['get'](P),_0x4d5b99=_0x4735f6['getCommentThread'](_0x156944);if(!_0x4d5b99['isAttached']){const _0x3dc608=_0x4d5b99['attachTo'](()=>this['_getTargetForId'](_0x4d5b99['id']));_0x45c9ba['registerAnnotation'](_0x3dc608),_0x4d5b99['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x2b12c8=this['editor'],_0x319843=_0x2b12c8['plugins']['get'](it);_0x2b12c8['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x59b25a,_0x389a93)=>{const {id:_0x4c4e48}=er(_0x59b25a['markerName']),_0x5239b5=_0x2b12c8['plugins']['get'](o)['getCommentThread'](_0x4c4e48),_0x17a3ce=this['activeMarker']&&er(this['activeMarker'])['id']===_0x4c4e48;let _0x53b1b0;if(_0x5239b5&&_0x5239b5['isResolved']&&!_0x17a3ce&&_0x59b25a['item'])return _0x389a93['consumable']['consume'](_0x59b25a['item'],'addMarker:'+_0x59b25a['markerName']),_0x389a93['consumable']['consume'](_0x59b25a['item'],'removeMarker:'+_0x59b25a['markerName']),null;const _0x1b1b3f=['ck-comment-marker'];return _0x17a3ce&&_0x1b1b3f['push']('ck-comment-marker--active'),_0x53b1b0=_0x5239b5?.['length']?_0x5239b5['comments']['first']['author']['id']:_0x319843['me']['id'],{'classes':_0x1b1b3f,'attributes':{'data-comment':_0x4c4e48,'data-author-id':_0x53b1b0}};}}),_0x2b12c8['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x4d5f23,{options:_0x30a398})=>{if(_0x30a398['showCommentHighlights'])return null;const _0x32d506=_0x2b12c8['plugins']['get'](o),_0x44a168=_0x2b12c8['model']['markers']['get'](_0x4d5f23),{id:_0x19da7b,part:_0x3d06c5}=er(_0x4d5f23);return _0x44a168&&!_0x44a168['affectsData']||_0x30a398['ignoreResolvedComments']&&_0x32d506['getCommentThread'](_0x19da7b)?.['isResolved']?null:{'group':'comment','name':_0x3d06c5?_0x19da7b+':'+_0x3d06c5:_0x19da7b};}}),_0x2b12c8['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x4d014a,{writer:_0x36b0e8})=>_0x36b0e8['createElement']('$marker',{'data-name':'comment:'+_0x4d014a['getAttribute']('id')})}),_0x2b12c8['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x9207f=this['editor'],_0x2e8e19=_0x9207f['plugins']['get'](o),_0xc6de09=new Set(),_0x3d1c34=new Set();_0x9207f['model']['document']['registerPostFixer'](_0x19a252=>{let _0x2fb060=!0x1;for(const {name:_0xa15842,data:_0x262df0}of _0x9207f['model']['document']['differ']['getChangedMarkers']()){const {group:_0x4dcc58,id:_0x11d35e}=er(_0xa15842);let _0x3a98f3=_0x262df0['newRange'];if('comment'!==_0x4dcc58||!_0x3a98f3)continue;const _0x233dcc='$graveyard'===_0x3a98f3['root']['rootName'];_0x233dcc||(_0x3a98f3=dt(_0x3a98f3,_0x9207f['model']),!_0x3a98f3||_0x3a98f3['isCollapsed']||!_0x262df0['newRange']||_0x3a98f3['isEqual'](_0x262df0['newRange']))?_0x9207f['model']['hasContent'](_0x3a98f3)&&!_0x233dcc?this['isThreadsLoadingPaused']?_0xc6de09['add'](_0xa15842):this['_handleThreadMarker'](_0xa15842,_0x11d35e):(_0x3d1c34['add'](_0xa15842),_0xc6de09['delete'](_0xa15842),_0x19a252['removeMarker'](_0xa15842),_0x2fb060=!0x0):(_0x19a252['updateMarker'](_0xa15842,{'range':_0x3a98f3}),_0x2fb060=!0x0);}return _0x2fb060;}),this['on']('change:isThreadsLoadingPaused',(_0x384db9,_0x333dc8,_0x808b9b)=>{if(!_0x808b9b&&_0xc6de09['size'])for(const _0x30a8d2 of _0xc6de09){const {id:_0x2c8c45}=er(_0x30a8d2);_0xc6de09['delete'](_0x30a8d2),_0x9207f['model']['markers']['get'](_0x30a8d2)&&this['_handleThreadMarker'](_0x30a8d2,_0x2c8c45);}}),this['listenTo'](_0x9207f['model']['document'],'change',()=>{for(const {name:_0x572759,data:{newRange:_0x1216c2}}of _0x9207f['model']['document']['differ']['getChangedMarkers']()){const {group:_0x3aa596,id:_0x35b254}=er(_0x572759);if('comment'!==_0x3aa596)continue;const _0x1b2efb=_0x2e8e19['getCommentThread'](_0x35b254),_0x496337=this['hasMarkerForId'](_0x35b254);_0x1b2efb&&(!_0x1b2efb['_hasTargetInContent']&&_0x1216c2&&_0x9207f['editing']['view']['once']('render',()=>{const _0x1b219b=_0x9207f['plugins']['get'](O),_0x21c48a=_0x2e8e19['_threadToController']['get'](_0x1b2efb)['view'];_0x1b219b['getByInnerView'](_0x21c48a)['refreshVisibility']();},{'priority':'low'}),_0x1b2efb['_hasTargetInContent']=_0x496337||!!_0x1216c2),_0x1216c2||(_0x3d1c34['add'](_0x572759),_0xc6de09['delete'](_0x572759));}for(const _0x393a30 of _0x3d1c34){const {id:_0x4a7bfe}=er(_0x393a30),_0x2b65d2=_0x2e8e19['getCommentThread'](_0x4a7bfe);if(_0xc6de09['delete'](_0x393a30),!_0x2b65d2)continue;const _0x4d3bdc=this['hasMarkerForId'](_0x4a7bfe);_0x4d3bdc||_0x2b65d2['isSubmitted']?_0x4d3bdc||_0x2b65d2['unlinkedAt']||_0x2b65d2['setUnlinkedAt'](new Date()):_0x2b65d2['remove']();}_0x3d1c34['clear']();});}['_handleInitialThreads'](_0x17800e){_0x17800e['forEach'](_0x32b354=>{_0x32b354['unlinkedAt']&&this['_attachArchivedThread'](_0x32b354['id']);});}['_getTargetForId'](_0x3f5272){const _0x213801=this['editor'],_0x36d948=this['getAllMarkersForId'](_0x3f5272);return et(_0x213801['editing'],_0x36d948);}['_getTextContext'](_0x642a7){const _0x2b57b7=this['getAllMarkersForId'](_0x642a7);let _0x2babb9='',_0x402b50=!0x1;for(const _0x56b820 of _0x2b57b7){const _0x4ac7ca=_0x56b820['getRange']();for(const _0x39c17c of Array['from'](_0x4ac7ca['getItems']()))_0x39c17c['is']('$textProxy')?(_0x2babb9&&_0x402b50&&(_0x2babb9+='\x20',_0x402b50=!0x1),_0x2babb9+=_0x39c17c['data']):_0x402b50=!0x0;_0x402b50=!0x0;}return _0x2babb9['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x5110a0,_0x249855){const _0x316615=this['editor'],_0x476392=_0x316615['plugins']['get'](o);let _0x163b5e=_0x476392['getCommentThread'](_0x249855);const _0x2ef531=_0x316615['config']['get']('collaboration.channelId'),_0x3f7e71=_0x316615['plugins']['get'](P);if(_0x163b5e&&(_0x163b5e['unlinkedAt']&&_0x163b5e['setUnlinkedAt'](null),_0x163b5e['isAttached']))return _0x163b5e;return!this['getAllMarkersForId'](_0x249855)[0x0]['managedUsingOperations']?_0x316615['editing']['view']['once']('render',()=>{if(_0x476392['getCommentThread'](_0x249855))return;const _0x1ab99d=_0x316615['plugins']['get'](O);_0x163b5e=_0x476392['openNewCommentThread']({'channelId':_0x2ef531,'threadId':_0x249855,'target':()=>this['_getTargetForId'](_0x249855),'context':{'type':'text','value':this['_getTextContext'](_0x249855)}});const _0x17eeff=_0x476392['_threadToController']['get'](_0x163b5e)['view'],_0x2a7528=_0x1ab99d['getByInnerView'](_0x17eeff);_0x2a7528&&_0x3f7e71['registerAnnotation'](_0x2a7528);},{'priority':'low'}):_0x476392['fetchCommentThread']({'channelId':_0x2ef531,'threadId':_0x249855})['then'](_0x170993=>{if('destroyed'!==_0x316615['state']){if(_0x163b5e=_0x170993,_0x163b5e&&!_0x163b5e['isAttached']){const _0x56bd74=_0x163b5e['attachTo'](()=>this['_getTargetForId'](_0x249855));_0x3f7e71['registerAnnotation'](_0x56bd74),_0x163b5e['isResolved']&&this['_reconvertMarkers'](_0x249855);}else{if(!_0x163b5e){const _0x369e0d=this['getAllMarkersForId'](_0x249855);_0x316615['model']['change'](_0x928ee2=>{for(const _0x23ba7e of _0x369e0d)_0x928ee2['removeMarker'](_0x23ba7e);});}}}}),_0x163b5e;}['_handleThreadMarker'](_0x3df44d,_0x3088fa){const _0x17c793=this['_attachMarkerToThread'](_0x3df44d,_0x3088fa);_0x17c793&&!_0x17c793['context']&&_0x17c793['setContext']({'type':'text','value':this['_getTextContext'](_0x3088fa)});}['_initAriaMarkerChangeAnnouncements'](){const _0x1cb6f5=this['editor'];ot(_0x1cb6f5['model'],({left:_0x52d1db,entered:_0x43c65a})=>{for(const _0x5c473b of _0x52d1db)if(mt(_0x5c473b)){_0x1cb6f5['ui']['ariaLiveAnnouncer']['announce'](E(_0x1cb6f5['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x9de4e7 of _0x43c65a)if(mt(_0x9de4e7)){_0x1cb6f5['ui']['ariaLiveAnnouncer']['announce'](E(_0x1cb6f5['locale'],'ENTER_COMMENT_ANNOUNCEMENT',nt(_0x41fdef)));break;}});}}function ft(_0x241e76,_0x5f299a){return _0x5f299a?_0x241e76+':'+_0x5f299a:_0x241e76;}function er(_0x329643){const _0x85dcb8=_0x329643['split'](':');return{'group':_0x85dcb8[0x0],'id':_0x85dcb8[0x1],'part':_0x85dcb8[0x2]};}function dt(_0x54cf0d,_0x2a23e9){const _0x479912=_0x2a23e9['schema'],_0x3961f4=_0x2a23e9['createRange'](_0x54cf0d['start']);for(const _0x3cf0b6 of _0x54cf0d['getWalker']()){const {type:_0x3f3c4a,item:_0x52863d,nextPosition:_0x57976a}=_0x3cf0b6;if('text'===_0x3f3c4a||_0x479912['isObject'](_0x52863d)){const _0x396879=_0x2a23e9['createPositionBefore'](_0x52863d);_0x3961f4['isCollapsed']&&(_0x3961f4['start']=_0x396879),_0x3961f4['end']=_0x57976a;}}return _0x3961f4;}function mt(_0x85a38d){return'comment'===er(_0x85a38d['name'])['group'];}class i extends _0x4ddbc3{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,r,P,O];}get['CommentsListView'](){return te;}get['CommentThreadInputView'](){return ie;}['init'](){const _0x312a50=this['editor'],_0x120a3e=_0x312a50['plugins']['get'](o),_0xdba802=_0x312a50['plugins']['get'](r),_0x209706=_0x312a50['plugins']['get'](O),_0x58d181=_0x312a50['plugins']['get'](P);_0x312a50['ui']['componentFactory']['add']('comment',()=>{const _0x264cc5=this['_createUIButton'](_0x2d05c8);return _0x264cc5['tooltip']=!0x0,_0x264cc5;}),_0x312a50['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0xbc96d4)),_0x58d181['addSourceCollector'](()=>{const _0x3dcc65=[];for(const [_0x5bc9ee,_0x808fa1]of _0x120a3e['_threadToController']){const _0xd94f49=_0xdba802['getAllMarkersForId'](_0x5bc9ee['id']),_0x13f25c=_0xd94f49['map'](_0x5ae9ae=>_0x5ae9ae['getRange']());_0xd94f49['length']>0x0&&_0x3dcc65['push']([_0x808fa1['view'],_0x13f25c]);}return _0x3dcc65;}),this['listenTo'](_0x209706,'change:activeAnnotations',(_0x4ec510,_0x33b059,_0x3f91c9)=>{const _0x43cfed=Array['from'](_0x3f91c9)['map'](_0x57e037=>_0x57e037['innerView'])['find'](_0x33bb0f=>_0x120a3e['_viewToController']['has'](_0x33bb0f));if(!_0x43cfed)return void(_0xdba802['activeMarker']=null);const _0x4a5da3=_0x120a3e['_viewToController']['get'](_0x43cfed)['model']['id'],_0x31ce0c='comment:'+_0x4a5da3;_0x4a5da3&&_0xdba802['hasMarkerForId'](_0x4a5da3)?_0xdba802['activeMarker']=_0x31ce0c:_0xdba802['activeMarker']&&(_0xdba802['activeMarker']=null);}),this['listenTo'](_0x120a3e,'removeCommentThread',(_0x5494c5,{threadId:_0x3f58ed,isFromAdapter:_0x4f5708})=>{!_0x4f5708&&_0x312a50['ui']['focusTracker']['isFocused']&&_0xdba802['hasMarkerForId'](_0x3f58ed)&&_0x312a50['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x120a3e,'addComment',(_0xb5f0dd,{threadId:_0x541763,isFromAdapter:_0x5731a6})=>{if(_0x5731a6||!_0xdba802['hasMarkerForId'](_0x541763)||!_0x120a3e['hasCommentThread'](_0x541763))return;0x1===_0x120a3e['getCommentThread'](_0x541763)['length']&&(_0x312a50['editing']['view']['focus'](),_0xb5f0dd['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4e3408=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x476542;for(const _0x5bffaf in _0x4e3408){const _0x5e5068=_0x5bffaf,_0x29a25b=_0x4e3408[_0x5e5068];if('commentsLicenseKeyValid'==_0x29a25b||'commentsLicenseKeyInvalid'==_0x29a25b||'commentsLicenseKeyExpired'==_0x29a25b||'commentsLicenseKeyDomainLimit'==_0x29a25b||'commentsLicenseKeyNotAllowed'==_0x29a25b||'commentsLicenseKeyEvaluationLimit'==_0x29a25b||'commentsLicenseKeyTrialLimit'==_0x29a25b||'commentsLicenseKeyUsageLimit'==_0x29a25b){delete _0x4e3408[_0x5e5068],_0x476542=_0x29a25b,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x476542&&_0x4e3408['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x476542&&_0x4e3408['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x476542&&_0x4e3408['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x476542&&_0x4e3408['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x476542&&_0x4e3408['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x476542&&_0x4e3408['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x476542&&_0x4e3408['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x3e1dac){const _0x3222e4=this['editor'],_0x4f4cc0=new _0x3e1dac(_0x3222e4['locale']),_0x390c74=_0x3222e4['commands']['get']('addCommentThread');return _0x4f4cc0['set']({'label':E(_0x3222e4['locale'],'Comment'),'icon':_0x1c1b9d}),_0x4f4cc0['bind']('isEnabled')['to'](_0x390c74),this['listenTo'](_0x4f4cc0,'execute',()=>{_0x390c74['execute']();}),_0x4f4cc0;}}class s extends _0x4ddbc3{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x546abc){super(_0x546abc),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x165d78,_0x310e6e,_0x5d2f66)=>{_0x5d2f66?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x3959eb,_0x124c89]of this['editor']['commands'])_0x124c89['affectsData']&&'addCommentThread'!==_0x3959eb&&_0x124c89['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing'))&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x34fec6=this['editor']['editing']['view']['document'];this['listenTo'](_0x34fec6,'cut',_0x4a6b26=>_0x4a6b26['stop'](),{'priority':'highest'}),this['listenTo'](_0x34fec6,'clipboardInput',_0x4b52cd=>_0x4b52cd['stop'](),{'priority':'highest'}),this['listenTo'](_0x34fec6,'delete',_0x56732a=>_0x56732a['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x5e8dd2,_0x525f89]of this['editor']['commands'])_0x525f89['affectsData']&&'addCommentThread'!==_0x5e8dd2&&_0x525f89['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 M extends _0x3fc4bc{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[O];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x29c847){super(_0x29c847),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0xc669a9=this['context']['plugins']['get'](O);this['listenTo'](_0xc669a9,'_activateAnnotation',(_0x52ee88,_0x239cd5)=>{for(const _0x3054c1 of this['activeUIs']){const _0x3c5bd4=this['_uis']['get'](_0x3054c1);(0x0,this['uisData']['get'](_0x3054c1)['filter'])(_0x239cd5)&&_0x3c5bd4['setActiveAnnotation'](_0x239cd5);}}),this['listenTo'](_0xc669a9,'_deactivateAllAnnotations',()=>{for(const _0x29fda2 of this['activeUIs']){this['_uis']['get'](_0x29fda2)['setActiveAnnotation'](null);}}),this['listenTo'](_0xc669a9['_visibleAnnotations'],'add',(_0x4c0a10,_0x236f3c)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x236f3c);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x36d627){return this['activeUIs']['has'](_0x36d627);}['activate'](_0x257d7e,_0x394868=this['defaultFilter']){const _0x7a9a23=this['context']['plugins']['get'](O);if(!this['_uis']['has'](_0x257d7e))throw new _0x2bd02b('annotationsuis-missing-ui',this,{'uiName':_0x257d7e});this['isActive'](_0x257d7e)&&this['deactivate'](_0x257d7e),this['activeUIs']['add'](_0x257d7e);const _0x5b4cf8=new _();!function({source:_0x3fbbb5,target:_0x51f370,filter:_0x3d2588}){for(const _0x564fb5 of _0x3fbbb5)_0x3d2588(_0x564fb5)&&_0x51f370['add'](_0x564fb5);_0x51f370['listenTo'](_0x3fbbb5,'add',(_0x36d445,_0x504fe0)=>{_0x3d2588(_0x504fe0)&&_0x51f370['add'](_0x504fe0);}),_0x51f370['listenTo'](_0x3fbbb5,'remove',(_0xd1113f,_0x3a6ef4)=>{_0x51f370['has'](_0x3a6ef4)&&_0x51f370['remove'](_0x3a6ef4);});}({'source':_0x7a9a23['_visibleAnnotations'],'target':_0x5b4cf8,'filter':_0x394868}),this['uisData']['set'](_0x257d7e,{'collection':_0x5b4cf8,'filter':_0x394868});const _0x128606=this['_uis']['get'](_0x257d7e);_0x128606['attach'](_0x5b4cf8),this['listenTo'](_0x128606,'change:activeAnnotation',(_0x32fcfd,_0x185742,_0x4ad28b,_0x45f9d3)=>{_0x45f9d3&&_0x7a9a23['_removeActiveAnnotation'](_0x45f9d3),_0x4ad28b&&_0x7a9a23['_addActiveAnnotation'](_0x4ad28b);});}['deactivate'](_0x169707){if(this['activeUIs']['delete'](_0x169707),!this['_uis']['has'](_0x169707))throw new _0x2bd02b('annotationsuis-missing-ui',this,{'uiName':_0x169707});const _0x4d7bca=this['_uis']['get'](_0x169707);_0x4d7bca['detach'](),this['stopListening'](_0x4d7bca),this['uisData']['get'](_0x169707)['collection']['destroy'](),this['uisData']['delete'](_0x169707);}['switchTo'](_0x1c81c1){if(!this['_uis']['has'](_0x1c81c1))throw new _0x2bd02b('annotationsuis-missing-ui',this,{'uiName':_0x1c81c1});const _0x455c7b=this['context']['plugins']['get'](O),_0x35443f=Array['from'](_0x455c7b['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x1c81c1);const _0x5e648f=this['_uis']['get'](_0x1c81c1);_0x5e648f['setActiveAnnotation'](_0x35443f),_0x5e648f['_setSelectedAnnotations']&&_0x35443f&&_0x5e648f['_setSelectedAnnotations']([_0x35443f]);}['deactivateAll'](){for(const _0x1b1cad of this['activeUIs'])this['deactivate'](_0x1b1cad);}['register'](_0x221af7,_0x3d91e7){if(this['_uis']['has'](_0x221af7))throw new _0x2bd02b('annotationsuis-register-already-registered');if('function'!=typeof _0x3d91e7['attach']||'function'!=typeof _0x3d91e7['detach']||'function'!=typeof _0x3d91e7['setActiveAnnotation'])throw new _0x2bd02b('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x221af7,_0x3d91e7);}['refilterAnnotations'](){const _0x13fec1=this['context']['plugins']['get'](O)['collection'],_0x1ffef4=new Map(),_0x3b0e52=Array['from'](this['activeUIs']);for(const _0x457ef9 of this['activeUIs']){const _0x2d8257=this['uisData']['get'](_0x457ef9)['collection'];for(const _0x5eb675 of _0x2d8257)_0x1ffef4['set'](_0x5eb675,_0x457ef9);}for(const _0x1322a7 of _0x13fec1){const _0x4d5322=_0x1ffef4['get'](_0x1322a7);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x1322a7);const _0x266ce0=_0x3b0e52['find'](_0x2770b6=>this['uisData']['get'](_0x2770b6)['filter'](_0x1322a7));_0x4d5322!==_0x266ce0&&(_0x4d5322&&this['uisData']['get'](_0x4d5322)['collection']['remove'](_0x1322a7),_0x266ce0&&this['uisData']['get'](_0x266ce0)['collection']['add'](_0x1322a7));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x491b80){const _0x2904d1=[];for(const _0x25eddb of this['activeUIs']){(0x0,this['uisData']['get'](_0x25eddb)['filter'])(_0x491b80)&&_0x2904d1['push'](_0x25eddb);}if(_0x2904d1['length']>0x1)throw new _0x2bd02b('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x2904d1,'annotationType':_0x491b80['type']});}}const pi=xt('px');class F extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x202162){super(_0x202162);const _0x3d4833=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 _0x322874(),this['focusCycler']=new _0x24abfe({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x3d4833['to']('class')],'style':{'minHeight':_0x3d4833['to']('minHeight',_0x3dfe88=>'number'==typeof _0x3dfe88?pi(_0x3dfe88+0xa):null)},'dir':_0x202162['uiLanguageDirection'],'role':'application','aria-label':E(_0x202162,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':E(_0x202162,'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',_0x1e5df7=>{this['_updateItemPositionInFocusables'](_0x1e5df7['source']);}),this['list']['forEach'](_0x27a190=>{this['focusTracker']['add'](_0x27a190['element']),this['_updateItemPositionInFocusables'](_0x27a190);}),this['list']['on']('change',(_0x4c041d,_0x50205e)=>{for(const _0x3608cc of _0x50205e['removed'])this['focusTracker']['remove'](_0x3608cc['element']),this['focusables']['remove'](_0x3608cc);for(const _0x494c6c of _0x50205e['added'])this['focusTracker']['add'](_0x494c6c['element']),this['_updateItemPositionInFocusables'](_0x494c6c);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x3d8b2b){const _0x5b4f0d=this['focusables']['getIndex'](_0x3d8b2b);let _0x281588,_0x5ec2f7;for(const _0x47fc12 of this['focusables'])if(_0x3d8b2b['top']<_0x47fc12['top']){_0x281588=_0x47fc12;break;}if(_0x5ec2f7=_0x281588?this['focusables']['getIndex'](_0x281588):this['focusables']['length'],-0x1!==_0x5b4f0d){if(_0x5b4f0d===_0x5ec2f7-0x1)return;this['focusables']['remove'](_0x3d8b2b),_0x5ec2f7=_0x281588?this['focusables']['getIndex'](_0x281588):this['focusables']['length'];}this['focusables']['add'](_0x3d8b2b,_0x5ec2f7);}}const Ht=xt('px');class H extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x3aac45){super(_0x3aac45),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x4fbdbb,_0x328988)=>_0x4fbdbb+_0x328988),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Lt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x462220=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x462220['to']('isAnimationDisabled',_0x1a16e4=>_0x1a16e4?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x462220['to']('top',_0x59d4d2=>Ht(_0x59d4d2))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x174677=this['element']['clientHeight'];_0x174677&&(this['height']=_0x174677);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x3fc4bc{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1cb58e){super(_0x1cb58e),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 _0x4821c1=this['context']['config']['get']('sidebar.container');_0x4821c1&&this['setContainer'](_0x4821c1);}['setContainer'](_0x271eba){if(!y(_0x271eba))throw new _0x2bd02b('sidebar-setcontainer-invalid-element');this['container']=_0x271eba;}['_attachToContainer']({viewClass:_0x5425a2='',spaceBetweenItems:_0x24905f=0x19}={}){if(!y(this['container']))throw new _0x2bd02b('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x5425a2,this['_spaceBetweenItems']=_0x24905f;}['rearrange']({removedAnnotation:_0x1b1184,previousAnnotation:_0x93dfc6,nextAnnotation:_0x2b38e5}){const _0x35a5b3=this['getSidebarItemView'](_0x1b1184);this['view']['list']['remove'](_0x35a5b3),this['_destroySidebarItemView'](_0x1b1184),_0x93dfc6&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x93dfc6)),_0x2b38e5&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x2b38e5)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x120b8b,activatedAnnotation:_0x48488e,disableAnimationOnActivatedAnnotation:_0x1a36e3}){if(this['_activeAnnotation']=_0x48488e,_0x120b8b){_0x120b8b['isActive']=!0x1;const _0x78793f=this['getSidebarItemView'](_0x120b8b);_0x78793f&&_0x1a36e3&&(_0x78793f['isAnimationDisabled']=!0x1);}if(_0x48488e){const _0x503663=this['getSidebarItemView'](_0x48488e);_0x503663&&(_0x48488e['isActive']=!0x0,_0x1a36e3&&(_0x503663['isAnimationDisabled']=!0x0,_0x503663['top']+=0x1),this['_alignToTargetRect'](_0x503663));}}['_detachFromContainer'](_0x589680){if(this['view']['element']['remove'](),_0x589680){for(const _0x596435 of _0x589680)this['_destroySidebarItemView'](_0x596435);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x3b502f,_0x423ef0){_0x423ef0||(_0x423ef0=_0x3b502f['view']);const _0x23d912=new H(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x23d912,_0x3b502f),this['_annotationToSidebarItemView']['set'](_0x3b502f,_0x23d912),_0x23d912['content']['add'](_0x423ef0),this['listenTo'](_0x3b502f['view'],'change:targetRect',(_0x3adbf9,_0x12d17f,_0x10044a)=>{const _0x21dd25=this['_getTargetTop'](_0x3b502f,_0x10044a);_0x23d912['_targetTop']!=_0x21dd25&&(_0x23d912['_targetTop']=_0x21dd25,this['_setItemTop'](_0x23d912,_0x21dd25));}),this['listenTo'](_0x23d912,'change:top',()=>{this['_recalculate'](_0x23d912,'top');}),this['listenTo'](_0x23d912,'change:bottom',()=>{this['_recalculate'](_0x23d912,'bottom');}),this['_alignToTargetRect'](_0x23d912);const _0x216ae7=this['_getItemBefore'](_0x23d912);if(_0x216ae7)this['_alignAfterItem'](_0x216ae7,_0x23d912)||this['_alignToTargetRect'](_0x23d912);else this['_alignToTargetRect'](_0x23d912);return this['_updateLastItem'](),this['view']['list']['add'](_0x23d912),_0x23d912;}['_alignForTopChange'](_0x20af0e){if(!_0x20af0e['content']['length'])return;const _0x458e3f=this['_getItemBefore'](_0x20af0e);if(!_0x458e3f)return;const _0x27372a=this['_sidebarItemViewToAnnotation']['get'](_0x458e3f),_0x2b2a27=this['_activeAnnotation'];_0x2b2a27&&_0x2b2a27===_0x27372a?this['_alignAfterItem'](_0x458e3f,_0x20af0e):this['_alignBeforeItem'](_0x20af0e,_0x458e3f);}['_alignForBottomChange'](_0x29ec63){if(!_0x29ec63['content']['length'])return;const _0x396b13=this['_getItemAfter'](_0x29ec63);if(!_0x396b13)return;const _0x2f017e=this['_sidebarItemViewToAnnotation']['get'](_0x396b13),_0x2b64d4=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x45380e=this['_activeAnnotation'];_0x45380e&&_0x45380e===_0x2f017e&&_0x2b64d4?(this['_alignBeforeItem'](_0x396b13,_0x29ec63),this['_alignAfterItem'](_0x29ec63,_0x396b13)):_0x45380e&&_0x45380e===_0x2f017e?this['_alignBeforeItem'](_0x396b13,_0x29ec63):this['_alignAfterItem'](_0x29ec63,_0x396b13);}['_recalculate'](_0x5cee2c,_0x23c048){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x3ce6db,changedProp:_0x59bd31}of this['_recalculateBuffer'])'top'===_0x59bd31?this['_alignForTopChange'](_0x3ce6db):this['_alignForBottomChange'](_0x3ce6db);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x5cee2c,'changedProp':_0x23c048});}['getSidebarItemView'](_0x399987){return this['_annotationToSidebarItemView']['get'](_0x399987);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x5d8ea0){const _0x3b5c47=this['getSidebarItemView'](_0x5d8ea0);this['stopListening'](_0x3b5c47),this['stopListening'](_0x5d8ea0['view']),_0x3b5c47['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x5d8ea0),this['_sidebarItemViewToAnnotation']['delete'](_0x3b5c47);}['_createSidebarView'](){const _0x37d9a6=new F(this['context']['locale']);return _0x37d9a6['render'](),this['on']('change:_lastItem',(_0x29d1a8,_0x5c49e7,_0x279771,_0x33dee7)=>{_0x33dee7&&_0x37d9a6['unbind']('minHeight'),_0x279771?_0x37d9a6['bind']('minHeight')['to'](_0x279771,'bottom'):_0x37d9a6['minHeight']=null;}),_0x37d9a6;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x1b7649){const _0x3a25f5=this['_sidebarItemViewToAnnotation']['get'](_0x1b7649),_0x229abd=_0x3a25f5&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x3a25f5)-0x1);return _0x229abd&&this['getSidebarItemView'](_0x229abd)||null;}['_getItemAfter'](_0x45a2e3){const _0x2081c2=this['_sidebarItemViewToAnnotation']['get'](_0x45a2e3),_0x53651c=_0x2081c2&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x2081c2)+0x1);return _0x53651c&&this['getSidebarItemView'](_0x53651c)||null;}['_alignBeforeItem'](_0x2beae5,_0xff6ef4){_0x2beae5['updateHeight']();const _0x454358=R(_0xff6ef4['bottom']+this['_spaceBetweenItems'],_0x2beae5['top']);return!!_0x454358&&(this['_setItemTop'](_0xff6ef4,_0xff6ef4['top']-_0x454358),!0x0);}['_alignAfterItem'](_0x32ea10,_0x4bda0a){_0x32ea10['updateHeight']();const _0x99a081=R(_0x32ea10['bottom']+this['_spaceBetweenItems'],_0x4bda0a['top']);return!!_0x99a081&&(this['_setItemTop'](_0x4bda0a,_0x4bda0a['top']+_0x99a081,!0x1),!0x0);}['_alignToTargetRect'](_0x5729d6){const _0x456fb4=this['_sidebarItemViewToAnnotation']['get'](_0x5729d6);if(!_0x456fb4||!_0x456fb4['target']||!_0x456fb4['targetRect'])return;const _0x13513f=this['_getTargetTop'](_0x456fb4,_0x456fb4['targetRect']);this['_setItemTop'](_0x5729d6,_0x13513f);}['_getTargetTop'](_0x86c67d,_0x4b54f8){if(null===_0x4b54f8)return 0x0;if(_0x86c67d['target']instanceof _0x23c230)return _0x4b54f8['top'];{const _0x38b5bc=new _0x23c230(this['view']['element'])['top'];return _0x4b54f8['top']-_0x38b5bc;}}['_setItemTop'](_0x528bbe,_0x490e58,_0xbbeafd=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0xbbeafd&&(_0x490e58=Math['max'](_0x490e58,this['_getMaxAvailableTop'](_0x528bbe))),_0x528bbe['top']=_0x490e58;}['_getMaxAvailableTop'](_0x3ae53f){let _0x15417b=this['_getItemBefore'](_0x3ae53f),_0x13d36e=0x0;for(;_0x15417b;)_0x15417b['updateHeight'](),_0x13d36e+=this['_spaceBetweenItems']+_0x15417b['height'],_0x15417b=this['_getItemBefore'](_0x15417b);return _0x13d36e;}}function R(_0x3435f5,_0x1fc9b5){return Math['max'](_0x3435f5-_0x1fc9b5,0x0);}function y(_0x47da79){return null!==_0x47da79&&'object'==typeof _0x47da79&&0x1===_0x47da79['nodeType'];}class e extends _0x3fc4bc{['isAttached'];['annotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,M];}static get['pluginName'](){return'WideSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xbb9ae1){super(_0xbb9ae1),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x564d2c(),this['_refreshPositioningDebounced']=_0x135821(()=>{this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x2d86fd=this['context']['plugins']['get'](M),_0xa9ab3e=this['context']['plugins']['get'](z);_0x2d86fd['register']('wideSidebar',this),_0xa9ab3e['container']&&_0x2d86fd['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x1daf79){if(_0x1daf79===this['activeAnnotation'])return;const _0x294283=this['context']['plugins']['get'](z);_0x294283['_activeAnnotation']=_0x1daf79;const _0x141a7b=this['activeAnnotation'];_0x294283['refresh']({'blurredAnnotation':_0x141a7b,'activatedAnnotation':_0x1daf79}),this['activeAnnotation']=_0x1daf79;}['attach'](_0x380ecf){this['annotations']=_0x380ecf;const _0x3e9bb9=this['context']['plugins']['get'](z);if(_0x3e9bb9['_annotations']=_0x380ecf,this['isAttached'])throw new _0x2bd02b('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x3e9bb9,'set:container',()=>{this['detach'](),this['listenTo'](_0x3e9bb9,'change:container',_0x19eb1f=>{_0x19eb1f['off'](),this['attach'](_0x380ecf);});}),_0x3e9bb9['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x389560=_0x1f3924=>{_0x1f3924['updateTargetRect'](),_0x3e9bb9['addAnnotation'](_0x1f3924);};for(const _0x5a0ee0 of _0x380ecf)_0x389560(_0x5a0ee0);this['listenTo'](_0x380ecf,'add',(_0x15f384,_0xe8226e)=>{_0x389560(_0xe8226e);}),this['listenTo'](_0x380ecf,'remove',(_0x5a1bbb,_0x3ea227,_0x24dc90)=>{_0x3e9bb9['rearrange']({'removedAnnotation':_0x3ea227,'previousAnnotation':_0x380ecf['get'](_0x24dc90-0x1),'nextAnnotation':_0x380ecf['get'](_0x24dc90+0x1)}),_0x3ea227===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x380ecf,'focus',(_0x4e8ddd,_0x2f1d0c)=>{this['setActiveAnnotation'](_0x2f1d0c);}),this['listenTo'](_0x380ecf,'blur',()=>{this['setActiveAnnotation'](null);});const _0x4cdbd1=this['context']instanceof _0x52719c?this['context']['editors']:new _0x564d2c([this['context']]);for(const _0x31bf27 of _0x4cdbd1)this['_integrateWithEditorAnnotations'](_0x31bf27);this['listenTo'](_0x4cdbd1,'add',(_0x5bc41f,_0xb594f5)=>{this['listenTo'](_0xb594f5,'ready',()=>{this['_integrateWithEditorAnnotations'](_0xb594f5);});}),this['listenTo'](_0x4cdbd1,'remove',(_0x1ec13a,_0x1b5b4d)=>{_0x1b5b4d['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x1b5b4d['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x2bd02b('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x53f869=this['context']['plugins']['get'](z);_0x53f869['_detachFromContainer'](this['annotations']),this['stopListening'](_0x53f869),this['stopListening'](this['annotations']),this['context']instanceof _0x52719c&&this['stopListening'](this['context']['editors']);for(const _0xdc7753 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0xdc7753);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x57a8e9){if(!_0x57a8e9['plugins']['has']('EditorAnnotations'))return;const _0x37ea1b=_0x57a8e9['plugins']['get']('EditorAnnotations'),_0x4b63a4=()=>{const _0x1acbd9=_0x37ea1b['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x1acbd9[0x0]||null);};this['listenTo'](_0x37ea1b,'refresh',_0x4b63a4),this['listenTo'](_0x37ea1b,'blur',(_0x47fa6f,{isAnnotationTracked:_0x108580})=>{this['activeAnnotation']&&_0x108580(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x37ea1b,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x3152fa=>{_0x37ea1b['hasDomSelection']()&&(_0x4b63a4(),_0x3152fa['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x37ea1b);}['_destroyEditorAnnotationsIntegration'](_0x54df33){this['stopListening'](_0x54df33),this['_editorAnnotations']['remove'](_0x54df33);}}class C extends _0x2d05c8{['counterView'];constructor(_0x4401da){super(_0x4401da);const _0x5dc5e6=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x368378,_0xb40ddb)=>_0x368378?'...':_0xb40ddb['toString']()),this['set']('annotationType',''),this['icon']=_0x1c1b9d,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x5dc5e6['to']('annotationType',_0x125619=>'ck-annotation-counter__badge--'+_0x125619),_0x5dc5e6['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x5dc5e6['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x3fc4bc{['isAttached'];['annotations'];['_manuallyClosedAnnotationViews'];['_domEmitter'];['_annotationToNarrowView'];['_selectedAnnotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,M];}static get['pluginName'](){return'NarrowSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1c1826){super(_0x1c1826),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=Object['create'](_0x15fb5f),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x564d2c(),this['_refreshPositioningDebounced']=_0x135821(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](M)['register']('narrowSidebar',this),this['bodyCollection']=new _0x2eef2d(this['context']['locale']),this['balloonPanelView']=new _0x105127(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x353445){this['annotations']=_0x353445;const _0x538d15=this['context']['plugins']['get'](z),_0x3c83e9=this['balloonPanelView'];if(_0x538d15['_annotations']=_0x353445,this['isAttached'])throw new _0x2bd02b('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x538d15,'set:container',()=>{this['detach'](),this['listenTo'](_0x538d15,'change:container',_0x476df1=>{_0x476df1['off'](),this['attach'](_0x353445);});}),_0x538d15['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x333adc=_0x2d22ee=>{const _0x1c31ea=new C(this['context']['locale']);_0x538d15['addAnnotation'](_0x2d22ee,_0x1c31ea),this['_annotationToNarrowView']['set'](_0x2d22ee,_0x1c31ea),_0x1c31ea['bind']('isDirty','annotationType','number')['to'](_0x2d22ee['view'],'isDirty','type','length'),_0x1c31ea['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x3c83e9['content']['first']!==_0x2d22ee['view']?(this['_showBalloon'](_0x2d22ee),_0x2d22ee['view']['element']['focus'](),this['setActiveAnnotation'](_0x2d22ee)):this['setActiveAnnotation'](null);});};for(const _0x11868b of _0x353445)_0x333adc(_0x11868b);this['listenTo'](_0x353445,'add',(_0x4a0df1,_0x4b4cf1)=>{_0x333adc(_0x4b4cf1);}),this['listenTo'](_0x353445,'remove',(_0x13f5e5,_0x2ee93f,_0x35371e)=>{this['_annotationToNarrowView']['get'](_0x2ee93f)['destroy'](),this['_annotationToNarrowView']['delete'](_0x2ee93f),_0x538d15['rearrange']({'removedAnnotation':_0x2ee93f,'previousAnnotation':_0x353445['get'](_0x35371e-0x1),'nextAnnotation':_0x353445['get'](_0x35371e+0x1)}),_0x2ee93f===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x353445,'focus',(_0x26e95a,_0x2db811)=>{this['setActiveAnnotation'](_0x2db811);}),this['listenTo'](_0x353445,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0xaa127e,_0x51be2d)=>{_0x51be2d['keyCode']===_0x433e11['esc']&&_0x3c83e9['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x3c83e9['content']['first']),this['_hideBalloon'](),_0x51be2d['stopPropagation'](),_0x51be2d['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x5d0fd6,_0x33e46f)=>{const _0xab644a=_0x33e46f['target'];_0x3c83e9['isVisible']&&_0x3c83e9['element']['contains'](_0xab644a)||_0x538d15['view']['element']['contains'](_0xab644a)||_0x5d0fd6['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x2d51f7=>_0x2d51f7['contains'](_0xab644a))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x42d515=this['context']instanceof _0x52719c?this['context']['editors']:new _0x564d2c([this['context']]);for(const _0x3be000 of _0x42d515)this['_integrateWithEditorAnnotations'](_0x3be000);this['listenTo'](_0x42d515,'add',(_0x187438,_0x5251ab)=>{this['listenTo'](_0x5251ab,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x5251ab);});}),this['listenTo'](_0x42d515,'remove',(_0x55ab5b,_0x27d466)=>{_0x27d466['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x27d466['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x1e860a){if(_0x1e860a===this['activeAnnotation'])return;const _0x212791=this['context']['plugins']['get'](z);if(_0x212791['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x1e860a,'disableAnimationOnActivatedAnnotation':!0x0}),_0x1e860a)_0x212791['getSidebarItemView'](_0x1e860a)?this['_showBalloon'](_0x1e860a):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x1e860a;}['detach'](){if(!this['isAttached'])throw new _0x2bd02b('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x4b6acf=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x5ed092=>_0x5ed092['destroy']()),this['_annotationToNarrowView']['clear'](),_0x4b6acf['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x52719c&&this['stopListening'](this['context']['editors']);for(const _0x2198e5 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x2198e5);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'](_0x80d0f9){if(!_0x80d0f9['plugins']['has']('EditorAnnotations'))return;const _0x3270e0=_0x80d0f9['plugins']['get']('EditorAnnotations'),_0x48aa59=this['context']['plugins']['get'](z),_0x1ae931=this['annotations'],_0xf3ac86=this['balloonPanelView'],_0x36fdba=()=>{const _0x338569=_0x3270e0['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x338569),this['setActiveAnnotation'](_0x338569[0x0]||null);};this['listenTo'](_0x3270e0,'refresh',_0x36fdba),this['listenTo'](_0x3270e0,'blur',(_0x1e9632,{isAnnotationTracked:_0x479082})=>{this['activeAnnotation']&&_0x479082(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x3270e0,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x1ae931,'blur',_0x4314e2=>{_0x3270e0['hasDomSelection']()&&_0x4314e2['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x219fb7,_0x355dbc)=>{const _0x33202c=_0x355dbc['target'];_0xf3ac86['isVisible']&&_0xf3ac86['element']['contains'](_0x33202c)||_0x48aa59['view']['element']['contains'](_0x33202c)||this['activeAnnotation']&&_0x3270e0['hasDomSelection']()&&(_0x36fdba(),_0x219fb7['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x3270e0);}['_destroyEditorAnnotationsIntegration'](_0x15e1ac){_0x15e1ac&&(this['stopListening'](_0x15e1ac),this['_editorAnnotations']['remove'](_0x15e1ac));}['_setSelectedAnnotations'](_0x4bdbf3){for(const _0x1e09d7 of this['_selectedAnnotations'])_0x4bdbf3['includes'](_0x1e09d7)||this['_manuallyClosedAnnotationViews']['delete'](_0x1e09d7['view']);this['_selectedAnnotations']=_0x4bdbf3;}['_refreshPositioning'](){const _0x48b24f=this['balloonPanelView'];this['annotations']['refreshPositioning'](),_0x48b24f['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x413733){if(this['_manuallyClosedAnnotationViews']['has'](_0x413733['view']))return;const _0x59f3bd=this['balloonPanelView']['content']['first'];_0x59f3bd!==_0x413733['view']?(_0x59f3bd&&this['_detachListeners'](_0x59f3bd),this['_attachListeners'](_0x413733['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x413733['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x5eecca=this['balloonPanelView']['content']['first'],_0x553345=_0x5eecca&&this['annotations']['getByView'](_0x5eecca);if(!_0x553345||!this['_annotationToNarrowView']['has'](_0x553345))return;const _0x374334=this['_annotationToNarrowView']['get'](_0x553345)['element'],_0x59f075=(function(){const _0x23017d=_0x105127['defaultPositions'];return[_0x23017d['southArrowNorthEast'],_0x23017d['northArrowSouthEast'],_0x23017d['southArrowNorth'],_0x23017d['northArrowSouth'],_0x23017d['southArrowNorthWest'],_0x23017d['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x374334,'positions':_0x59f075});}['_hideBalloon'](){const _0x303dfe=this['balloonPanelView'],_0x16a384=_0x303dfe['content']['first'];_0x16a384&&(this['_detachListeners'](_0x16a384),_0x303dfe['unpin'](),_0x303dfe['content']['clear']());}['_attachListeners'](_0x1c4dd0){this['listenTo'](_0x1c4dd0,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x1c4dd0,'Esc',(_0x834c40,_0x3ab252)=>{this['_manuallyClosedAnnotationViews']['add'](_0x1c4dd0),this['_hideBalloon'](),_0x3ab252();});}['_detachListeners'](_0x56e2d4){this['stopListening'](_0x56e2d4);}}class c extends _0x4ddbc3{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[P,_0xb9f12c,M];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4fba67){super(_0x4fba67),_0x4fba67['editing']['view']['addObserver'](_0x56765a),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x4fba67['plugins']['get'](_0xb9f12c),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x384ef7=this['editor']['plugins']['get'](M);_0x384ef7['context']===this['editor']&&(_0x384ef7['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0xc030c9,_0x3eb2cd)=>{const _0x14f5ef=this['_balloon'];if(this['isAttached']&&_0x14f5ef['visibleView']){const _0x52e0d3=this['annotations']['getByView'](_0x14f5ef['visibleView']);_0x52e0d3&&this['_closeAnnotation'](_0x52e0d3),_0x3eb2cd();}}));}['afterInit'](){const _0x2bd1e5=this['editor']['plugins']['get'](M);_0x2bd1e5['context']===this['editor']&&(_0x2bd1e5['hasActive']()||_0x2bd1e5['switchTo']('inline'));}['setActiveAnnotation'](_0x30f5df){_0x30f5df!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x30f5df&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x30f5df)&&this['_addAnnotationToBalloon'](_0x30f5df,!0x0),_0x30f5df['isActive']=!0x0),_0x30f5df||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x30f5df);}['attach'](_0x2ebb8e){this['annotations']=_0x2ebb8e;const _0x3ef2e4=this['editor']['plugins']['get'](M),_0x580e3e=this['_balloon'];if(this['isAttached'])throw new _0x2bd02b('inlineannotations-attach-already-attached',this);if(_0x3ef2e4['context']!==this['editor'])throw new _0x2bd02b('inlineannotations-not-allowed-with-context',this);const _0x145a21=this['editor']['plugins']['get'](P);this['listenTo'](_0x145a21,'refresh',()=>{const _0x125d84=_0x145a21['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x1e9aaa,_0xa61531;!this['_forceRefresh']&&(_0x1e9aaa=_0x125d84,_0xa61531=this['_selectedAnnotations'],_0x1e9aaa['length']===_0xa61531['length']&&_0x1e9aaa['every'](_0xbd3449=>_0xa61531['includes'](_0xbd3449)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x125d84),this['setActiveAnnotation'](_0x125d84[0x0]||null));}),this['listenTo'](_0x145a21,'blur',(_0x157321,{isAnnotationTracked:_0xf0b4dc})=>{this['activeAnnotation']&&_0xf0b4dc(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x510ae8,_0x45d03b,_0x58e648)=>{_0x58e648||this['setActiveAnnotation'](null);}),this['listenTo'](_0x2ebb8e,'remove',(_0x412c2b,_0x333a9e)=>{this['_removeAnnotationFromBalloon'](_0x333a9e),_0x333a9e===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x580e3e,'change:visibleView',(_0x102a01,_0x40f688,_0xd8df6,_0x706fe2)=>{_0x706fe2&&this['stopListening'](_0x706fe2);const _0x3b307e=_0x2ebb8e['getByView'](_0xd8df6);_0xd8df6&&_0x3b307e&&(this['listenTo'](_0xd8df6,'change:height',()=>{_0x580e3e['updatePosition']();}),this['listenTo'](_0xd8df6,'Esc',()=>{this['_closeAnnotation'](_0x3b307e),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x3b307e&&this['setActiveAnnotation'](_0x3b307e));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x580e3e['visibleView']&&(_0x2ebb8e['getByView'](_0x580e3e['visibleView'])&&_0x580e3e['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 _0x2bd02b('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x4c89dc of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x4c89dc);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x577feb){for(const _0x17dfb3 of this['_selectedAnnotations'])_0x577feb['includes'](_0x17dfb3)||this['_manuallyClosed']['delete'](_0x17dfb3);for(const _0x425723 of this['annotations'])_0x577feb['includes'](_0x425723)||this['_removeAnnotationFromBalloon'](_0x425723);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x4b8e45 of _0x577feb)this['_addAnnotationToBalloon'](_0x4b8e45);}this['_selectedAnnotations']=_0x577feb;}['_addAnnotationToBalloon'](_0x8b185e,_0x1b929c=!0x1){this['_manuallyClosed']['has'](_0x8b185e)||(this['_addedAnnotations']['has'](_0x8b185e)||this['_balloon']['hasView'](_0x8b185e['view'])||(this['_addedAnnotations']['add'](_0x8b185e),this['_balloon']['add']({'stackId':_0x8b185e['view']['id'],'view':_0x8b185e['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x8b185e)}})),_0x1b929c&&this['_balloon']['showStack'](_0x8b185e['view']['id']));}['_getBalloonTargetForAnnotation'](_0x32d8f7){const _0x121f32=_0x32d8f7['target'],_0x3698fa=this['editor']['editing']['view'],_0x18b575=_0x3698fa['document']['selection']['getFirstRange'](),_0x1a62ab=_0x3698fa['domConverter']['viewRangeToDom'](_0x18b575);if(_0x1a62ab['collapse'](!0x0),_0x121f32){if(_0x121f32 instanceof _0x23c230)return _0x121f32;let _0xb9f785=[];for(const _0x4939a6 of _0x121f32)_0xb9f785['push'](...(_0x540282=_0x4939a6['getClientRects'](),Array['from'](_0x540282)['map'](DOMRect['fromRect'])));_0xb9f785=function(_0x3084ba){const _0x236427=[];let _0x581632=_0x3084ba[0x0];for(let _0x265f5f=0x1;_0x265f5f<_0x3084ba['length'];_0x265f5f++)B(_0x581632,_0x3084ba[_0x265f5f])?_0x581632['width']+=_0x3084ba[_0x265f5f]['width']:(_0x236427['push'](_0x581632),_0x581632=_0x3084ba[_0x265f5f]);return _0x236427['push'](_0x581632),_0x236427;}(_0xb9f785);const _0x464c7d=_0x1a62ab['getBoundingClientRect']();return _0xb9f785['find'](_0x515d5d=>_0x515d5d['top']<=_0x464c7d['top']&&_0x515d5d['bottom']>=_0x464c7d['bottom']&&_0x515d5d['left']<=_0x464c7d['left']&&_0x515d5d['right']>=_0x464c7d['right'])||_0xb9f785[0x0];}var _0x540282;return _0x32d8f7['targetRect']||_0x1a62ab;}['_removeAnnotationFromBalloon'](_0x1c642a){this['_addedAnnotations']['has'](_0x1c642a)&&this['_balloon']['hasView'](_0x1c642a['view'])&&(this['_addedAnnotations']['delete'](_0x1c642a),this['_balloon']['remove'](_0x1c642a['view']));}['_closeAnnotation'](_0x3c660e){this['_manuallyClosed']['add'](_0x3c660e),this['_removeAnnotationFromBalloon'](_0x3c660e);}}function B(_0x483c7d,_0x34df3a){return _0x483c7d['top']===_0x34df3a['top']&&_0x483c7d['bottom']===_0x34df3a['bottom']&&_0x483c7d['right']===_0x34df3a['left'];}class tt extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x2b0a9a,_0x3f89f0){super(_0x2b0a9a),this['set']('isEmpty',!_0x3f89f0['length']),this['focusTracker']=new _0x322874(),this['_annotationViews']=_0x3f89f0,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x24abfe({'focusables':_0x3f89f0,'focusTracker':this['focusTracker']}),this['listenTo'](_0x3f89f0,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x3f89f0,'remove',(_0x13a097,_0x3970ce)=>{_0x3970ce['isActive']&&this['focus'](),_0x3f89f0['length']||(this['isEmpty']=!0x0);});const _0x1cdc46=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':E(_0x2b0a9a,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x3f89f0},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x1cdc46['if']('isEmpty','ck-hidden',_0x910996=>!_0x910996)]},'children':[{'text':E(_0x2b0a9a,'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 _0x3403f1 of this['_annotationViews'])this['focusTracker']['add'](_0x3403f1['element']);this['_annotationViews']['on']('change',(_0x143298,{added:_0x3a6ddd,removed:_0x4fb1ea})=>{for(const _0x54dabb of _0x3a6ddd)this['focusTracker']['add'](_0x54dabb['element']);for(const _0xa7a49f of _0x4fb1ea)this['focusTracker']['remove'](_0xa7a49f['element']);});}}class f extends _0x3fc4bc{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,O];}constructor(_0x30a654){super(_0x30a654),this['archivedThreads']=new _0x564d2c();}['init'](){const _0x59a241=this['context'],_0x580b35=_0x59a241['plugins']['get'](o),_0x52d1ac=_0x59a241['plugins']['get'](O);this['listenTo'](_0x580b35,'addCommentThread',(_0x3d42e9,{threadId:_0x501c73})=>{const _0x179bda=_0x580b35['getCommentThread'](_0x501c73);_0x179bda['archivedAt']&&this['archivedThreads']['add'](_0x179bda,this['_calculatePosition'](_0x179bda['archivedAt'])),this['listenTo'](_0x179bda,'change:archivedAt',(_0x1fede4,_0x34e5e7,_0x308edc)=>{_0x308edc?this['archivedThreads']['has'](_0x179bda)||this['archivedThreads']['add'](_0x179bda,this['_calculatePosition'](_0x179bda['archivedAt'])):this['archivedThreads']['has'](_0x179bda)&&this['archivedThreads']['remove'](_0x179bda);});}),this['listenTo'](_0x580b35,'removeCommentThread',(_0x5cdb63,{threadId:_0x41e25a})=>{const _0x456218=_0x580b35['getCommentThread'](_0x41e25a);this['stopListening'](_0x456218),this['archivedThreads']['has'](_0x456218)&&this['archivedThreads']['remove'](_0x456218);},{'priority':'highest'}),this['listenTo'](_0x52d1ac['collection'],'focus',(_0x209782,_0x50c74a)=>{_0x50c74a['isVisible']||(_0x50c74a['isActive']=!0x0,_0x52d1ac['activate'](_0x50c74a));});}['_calculatePosition'](_0xe7b711){const _0xa24d0f=[...this['archivedThreads']]['findIndex'](_0x13c0ae=>_0x13c0ae['archivedAt']<_0xe7b711);return _0xa24d0f>-0x1?_0xa24d0f:this['archivedThreads']['length'];}}class a extends _0x4ddbc3{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[f,_0x52081b];}constructor(_0x42138b){super(_0x42138b),this['annotationViews']=new _0x3f54d3(),this['_pendingThreads']=[];}['init'](){const _0x24207e=this['editor'],_0x54c5b6=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x24207e['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x2d05c8,!0x0)),_0x24207e['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x5bc06d=this['_createCommentsArchiveButton'](_0xbc96d4);return _0x5bc06d['set']({'role':'menuitemcheckbox'}),_0x5bc06d;});const _0x25b9a3=_0x24207e['plugins']['get'](f),_0x1bab97=_0x24207e['plugins']['get']('Annotations'),_0x520815=_0x24207e['plugins']['get']('CommentsRepository');_0x25b9a3['archivedThreads']['forEach'](_0x5d80f2=>{this['_handleNewThread'](_0x5d80f2);}),this['listenTo'](_0x25b9a3['archivedThreads'],'add',(_0x3366ca,_0x3c6052)=>{this['_handleNewThread'](_0x3c6052);}),this['listenTo'](_0x1bab97['collection'],'add',(_0x58953c,_0x11d5d3)=>{const _0x3ea3b0=this['_pendingThreads']['find'](_0x1f8b81=>{const _0x4e4748=_0x520815['_threadToController']['get'](_0x1f8b81);return _0x4e4748&&_0x11d5d3['innerView']===_0x4e4748['view'];});if(_0x3ea3b0){const _0x1f19b0=this['_calculatePosition'](_0x3ea3b0['archivedAt']);this['annotationViews']['add'](_0x11d5d3['view'],_0x1f19b0),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x3ea3b0),0x1);}}),this['listenTo'](_0x25b9a3['archivedThreads'],'remove',(_0x775e8c,_0x262e0c)=>{const _0x5ab850=_0x24207e['config']['get']('collaboration.channelId');if(!_0x5ab850||_0x262e0c['channelId']===_0x5ab850){const _0x98eb54=_0x520815['_threadToController']['get'](_0x262e0c),_0x39f3b1=_0x1bab97['getByInnerView'](_0x98eb54['view']);this['annotationViews']['remove'](_0x39f3b1['view']),this['stopListening'](_0x39f3b1['focusableElements']);}}),this['listenTo'](_0x1bab97['collection'],'add',(_0x32bfbb,_0x38d6b1)=>{this['listenTo'](_0x38d6b1,'escape',_0x54c5b6);}),this['listenTo'](_0x1bab97['collection'],'remove',(_0x438199,_0x24fc45)=>{this['stopListening'](_0x24fc45,'escape',_0x54c5b6);});}['_handleNewThread'](_0x2d29b5){const _0x500ab5=this['editor']['plugins']['get']('CommentsRepository'),_0x4ee945=this['editor']['plugins']['get']('Annotations'),_0x17caa6=this['editor']['config']['get']('collaboration.channelId');if(!_0x17caa6||_0x2d29b5['channelId']===_0x17caa6){const _0x2845f7=_0x500ab5['_threadToController']['get'](_0x2d29b5);if(!_0x2845f7)return void this['_pendingThreads']['push'](_0x2d29b5);const _0x3509b9=this['_calculatePosition'](_0x2d29b5['archivedAt']),_0x294244=_0x4ee945['getByInnerView'](_0x2845f7['view']);_0x294244['isVisible']&&_0x4ee945['_visibleAnnotations']['remove'](_0x294244),this['annotationViews']['add'](_0x294244['view'],_0x3509b9);}}['_calculatePosition'](_0x263445){const _0x54cc01=this['editor']['config']['get']('collaboration.channelId'),_0xbefdb2=[...this['editor']['plugins']['get'](f)['archivedThreads']]['filter'](_0x127b70=>_0x127b70['channelId']===_0x54cc01)['findIndex'](_0x20b721=>_0x20b721['archivedAt']<_0x263445);return _0xbefdb2<0x0||_0xbefdb2>this['annotationViews']['length']?this['annotationViews']['length']:_0xbefdb2-0x1;}['_toggleDialog'](){const _0xf0843a=this['editor'],_0x2b528e=_0xf0843a['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new tt(_0xf0843a['locale'],this['annotationViews'])),'commentsArchive'===_0x2b528e['id']?_0x2b528e['hide']():_0x2b528e['show']({'id':'commentsArchive','title':E(_0xf0843a['locale'],'COMMENTS_ARCHIVE'),'icon':_0x281e35,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x485909['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x4bbd77,_0x487e7b=!0x1){const _0x5a3c46=this['editor']['locale'],_0x3f95d4=this['editor']['plugins']['get']('Dialog'),_0x252c41=new _0x4bbd77(_0x5a3c46);return _0x252c41['bind']('isEnabled')['to'](this,'isEnabled'),_0x252c41['bind']('isOn')['to'](_0x3f95d4,'id',_0x9e5c0c=>'commentsArchive'===_0x9e5c0c),_0x252c41['set']({'label':E(_0x5a3c46,'COMMENTS_ARCHIVE'),'icon':_0x281e35,'isToggleable':!0x0}),_0x487e7b&&(_0x252c41['tooltip']=!0x0),this['listenTo'](_0x252c41,'execute',()=>this['_toggleDialog']()),_0x252c41;}['_hideDialogOnAnnotationEscape']=_0x447fad=>{const _0x2f5aa4=_0x447fad['source'];if(!this['annotationViews']['has'](_0x2f5aa4['view']))return;const _0x3a9e31=this['editor']['plugins']['get']('Dialog');_0x3a9e31['isOpen']&&'commentsArchive'===_0x3a9e31['id']&&(_0x3a9e31['hide'](),_0x447fad['stop']());};}class p extends _0x4ddbc3{static get['requires'](){return[o,r,i,f,a,s,e,n,c];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{d as Annotation,_ as AnnotationCollection,S as AnnotationView,O as Annotations,M as AnnotationsUIs,ts as BaseCommentThreadView,hs as BaseCommentView,fi as Comment,ui as CommentThread,Ct as CommentThreadController,ie as CommentThreadInputView,vt as CommentThreadView,gt as CommentView,p as Comments,f as CommentsArchive,a as CommentsArchiveUI,te as CommentsListView,s as CommentsOnly,o as CommentsRepository,i as CommentsUI,P as EditorAnnotations,c as InlineAnnotations,n as NarrowSidebar,z as Sidebar,e as WideSidebar};
23
+ import{Editor as _0x342bb8,ContextPlugin as _0x5f4d65,PendingActions as ht,Command as _0x98c743,Plugin as _0x3d65c4,Context as _0x542394}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x1852be,uid as _0x596ab2,KeystrokeHandler as jt,FocusTracker as _0x592ecb,diff as _0x16b9a7,Collection as _0xa9d85c,Rect as _0x21625e,CKEditorError as _0x1b91dd,first as _0x9d13e6,priorities as Wt,scrollViewportToShowTarget as rt,getEnvKeystrokeText as nt,toUnit as xt,DomEmitterMixin as _0x199fdd,keyCodes as _0x2d25f6}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x2167d8,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x462cf1,trimHtml as _0x8e7d23,LateFocusDropdownButtonView as _0x4f6d09,Users as it,getDateTimeFormatter as lt,hashObject as pt,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as ot,FOCUS_ANNOTATION_KEYSTROKE as _0x170a2d}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as wt,cloneDeep as It,set as At,unset as yt,debounce as _0x281f66}from'es-toolkit/compat';import{IconUndo as _0x3f6439,IconCheck as _0xcd4af3,IconPencil as _0x3f2c11,IconRemoveComment as _0x299129,IconThreeVerticalDots as _0x45a143,IconAddComment as _0x23e576,IconCommentsArchive as _0x53aa14}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as Vt,InlineEditableUIView as $t,EditorUI as Rt,View as kt,FocusCycler as _0x22c242,ButtonView as _0xdd1602,ViewCollection as _0x277c84,createDropdown as _0x147b08,ListView as _0x15b356,focusChildOnDropdownOpen as _0x59df6b,ListItemView as _0x51ab8b,MenuBarMenuListItemButtonView as _0x17eead,BodyCollection as _0x434317,BalloonPanelView as _0x376427,ContextualBalloon as _0x5eb984,Dialog as _0x2df1b9,DialogViewPosition as _0x595483}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disablePlaceholder as St,enablePlaceholder as Ft,MouseObserver as _0xc145e3}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 Et}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as Gt}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as Jt}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as Kt}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x2e830d}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x5ba603}from'@ckeditor/ckeditor5-widget/dist/index.js';class Ct extends/* #__PURE__ -- @preserve */
24
+ _0x1852be(){['model'];['view'];constructor(_0x4dfc55,_0x46c72b){super(),this['model']=_0x4dfc55,this['model']['_isAttached']=!0x0,this['view']=_0x46c72b,this['listenTo'](_0x46c72b,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x46c72b,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x46c72b,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x46c72b,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x46c72b,'addComment',(_0xb9e19c,_0x23a6fb)=>this['addComment'](_0x23a6fb)),this['listenTo'](_0x46c72b,'updateComment',(_0x2c2991,_0x2d574d,_0x759341)=>this['updateComment'](_0x2d574d,_0x759341)),this['listenTo'](_0x46c72b,'removeComment',(_0x1a8fcb,_0x331ce0)=>this['removeComment'](_0x331ce0));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x13451b){this['model']['addComment']({'content':_0x13451b,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x1c5f08,_0x127a40){this['model']['getComment'](_0x1c5f08)['update']({'content':_0x127a40});}['removeComment'](_0x251115){this['model']['getComment'](_0x251115)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function E(_0x3fe3ef,_0x3e4548,_0x2801a5){const t=_0x3fe3ef['t'];switch(_0x3e4548){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'},_0x2801a5);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'},_0x2801a5);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'},_0x2801a5);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'},_0x2801a5);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x2801a5);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'},_0x2801a5);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'},_0x2801a5);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'},_0x2801a5);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 Ut extends Vt{['main'];['editable'];constructor(_0x2bafd3,_0x5a3345){super(_0x2bafd3);const _0x6d2907=_0x596ab2();this['main']=this['createCollection'](),this['editable']=new $t(_0x2bafd3,_0x5a3345,void 0x0,{'label':()=>E(_0x2bafd3,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x2bafd3['uiLanguageDirection'],'lang':_0x2bafd3['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x6d2907},'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 Ot extends Rt{['view'];constructor(_0x3e3472){super(_0x3e3472),this['view']=new Ut(_0x3e3472['locale'],_0x3e3472['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x27dc06=this['editor']['editing']['view'],_0x1c0ef4=this['view']['editable'],_0x349c8b=_0x27dc06['document']['getRoot']();_0x1c0ef4['name']=_0x349c8b['rootName'],this['view']['render']();const _0x41aa80=_0x1c0ef4['element'];this['setEditableElement'](_0x1c0ef4['name'],_0x41aa80),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x27dc06['attachDomRoot'](_0x41aa80),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Nt=[qt,zt,Bt,Et,Gt,Jt,Kt];class Qt extends/* #__PURE__ -- @preserve */
25
+ _0x1852be(_0x342bb8){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
+ ((()=>Nt)());constructor(_0x154a58={}){function _0x4e0293(_0x4ba0a8){return _0x4ba0a8['map'](_0xd1f4d9=>String['fromCharCode'](_0xd1f4d9))['join']('');}(_0x154a58=Object['assign']({},_0x154a58))['plugins']||(_0x154a58['plugins']=Qt['defaultPlugins']),super(_0x154a58),this['ui']=new Ot(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this[_0x4e0293([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4e0293([0x76,0x69,0x65,0x77])][_0x4e0293([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4e0293([0x61,0x75,0x74,0x6f]),this[_0x4e0293([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x4e0293([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4e0293([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x4e0293([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x4e0293([0x6f,0x6b])});}['create'](){const _0x1e758f=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x1e758f))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x2f7027=>{const _0x14e270=this['model']['document']['getRoot'](),_0x51bcb7=_0x14e270&&_0x14e270['getChild'](_0x14e270['childCount']-0x1);_0x2f7027['setSelection'](_0x51bcb7,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x51ea5d=this['editing']['view'],_0x5afd2f=_0x51ea5d['document']['getRoot'](),_0x135824=_0x5afd2f['getChild'](0x0);_0x5afd2f['childCount']>0x1||!_0x135824||'p'!=_0x135824['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x51ea5d,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x135824['placeholder']=this['placeholder']),Ft({'view':_0x51ea5d,'element':_0x135824,'keepOnFocus':!0x0}),this['placeholderElement']=_0x135824);}}class os extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x5ec096,_0x56b0f6={}){super(_0x5ec096),this['editor']=null,this['_editorConfig']=_0x56b0f6,this['set']('value',_0x56b0f6['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',E(_0x5ec096,'Reply...')),this['set']('submitLabel',E(_0x5ec096,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x592ecb(),this['focusCycler']=new _0x22c242({'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',(_0x4324ef,_0x19885d)=>{this['cancelButtonView']['fire']('execute'),_0x19885d();}),this['keystrokes']['set']('Ctrl+Enter',(_0x4a4cce,_0x211502)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x211502());}),this['on']('submit',(_0x417363,_0x2c5172)=>{_0x2c5172['length']>0xfde8?(alert(E(_0x5ec096,'TOO_LONG_COMMENT_ALERT',[_0x2c5172['length'],0xfde8])),_0x417363['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Qt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x54270a=this['editor'];this['element']['insertBefore'](_0x54270a['ui']['element'],this['element']['firstChild']),_0x54270a['model']['document']['on']('change',()=>this['value']=_0x54270a['getData']()),_0x54270a['bind']('placeholder')['to'](this),this['focusables']['add'](_0x54270a['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x548223){-0x1===_0x548223?(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:_0x3fc74e}=this,_0x5e396f=new _0xdd1602(_0x3fc74e);return _0x5e396f['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x5e396f['withText']=!0x0,_0x5e396f['bind']('label')['to'](this,'submitLabel'),_0x5e396f['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x5e396f['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x42e7d6,_0x11341f)=>!_0x11341f&&!!_0x42e7d6['trim']()),_0x5e396f;}['_createCancelButton'](){const {locale:_0x7faea6}=this,_0x16b49d=new _0xdd1602(_0x7faea6);return _0x16b49d['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x16b49d['label']=E(_0x7faea6,'Cancel'),_0x16b49d['withText']=!0x0,_0x16b49d['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x16b49d;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x145a65=>{this['focusTracker']['add'](_0x145a65['element']);}),this['focusables']['on']('change',(_0x4211b5,_0x4d50b6)=>{for(const _0x12cd9e of Array['from'](_0x4d50b6['added'])['reverse']())this['focusTracker']['add'](_0x12cd9e['element']);});}}class ie extends kt{constructor(_0x33bc84,_0x4f8f2d,_0x420502){super(_0x33bc84),this['commentInputView']=new os(_0x33bc84,_0x420502),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0xf842d7,_0x388d90)=>_0xf842d7||!!_0x388d90),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 _0x2167d8(_0x33bc84,_0x4f8f2d),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'](_0x4f5405){this['commentInputView']['focus'](_0x4f5405);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x33d708,_0x35661f)=>{const {submitButtonView:_0x58151c,cancelButtonView:_0x2796fe,editor:_0x2ce5fb}=this['commentInputView'];[_0x58151c['element'],_0x2796fe['element'],_0x2ce5fb?_0x2ce5fb['editing']['view']['getDomRoot']():null]['filter'](_0x270ceb=>_0x270ceb)['some'](_0x18219e=>_0x18219e['contains'](_0x35661f['target']))||(this['focus'](),_0x35661f['preventDefault']());});}}class cs extends kt{constructor(_0x1b64ce){super(_0x1b64ce);const _0x4ee649=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x4ee649['to']('count',_0x17da1b=>E(_0x1b64ce,'NUMBER_OF_COMMENTS',_0x17da1b))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x266a98,_0x4ae638,_0x4a16a3){super(_0x266a98);const _0x3b0cd4=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x4ae638['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x4ae638,this['_config']=_0x4a16a3,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x592ecb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x22c242({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x1f56e6=>this['commentViews']['map'](_0x3a2253=>_0x3a2253['element'])['includes'](_0x1f56e6['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new cs(_0x266a98),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x5918db=>_0x5918db-this['_config']['maxCommentsWhenCollapsed']);for(const _0x3af7cb of _0x4ae638['comments'])this['_handleNewCommentModel'](_0x3af7cb);this['_handleInfoComment'](),this['listenTo'](_0x4ae638['comments'],'add',(_0x5aafd8,_0x156b3d)=>{const _0x415e0b=this['_calculatePosition'](_0x156b3d);this['length']++,this['_handleNewCommentModel'](_0x156b3d,_0x415e0b),this['refreshVisibleViews']();}),this['listenTo'](_0x4ae638['comments'],'remove',(_0x95b3ea,_0x2dd39c)=>{this['length']--,this['_handleRemoveCommentModel'](_0x2dd39c),this['refreshVisibleViews']();}),this['listenTo'](_0x4ae638,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x4ae638,'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',_0x3b0cd4['if']('length','ck-hidden',_0x36bf0f=>!_0x36bf0f)],'aria-label':E(_0x266a98,'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'](_0x5f17bf){-0x1===_0x5f17bf?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x1c9096 of this['commentViews'])_0x1c9096['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x1b787a,_0x558c38){const _0xc2b393=new this['_config']['CommentView'](this['locale'],_0x1b787a,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0xc2b393['viewUid']=_0x1b787a['id'],_0xc2b393['delegate']('removeComment')['to'](this),_0xc2b393['delegate']('updateComment')['to'](this),_0xc2b393['delegate']('resolveCommentThread')['to'](this),_0xc2b393['delegate']('editorReady')['to'](this),_0xc2b393['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0xc2b393,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0xc2b393,_0x558c38);}['_calculatePosition'](_0x107165){const _0x6c46d9=this['_model']['_findOptimalIndex'](_0x107165);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x107165['authoredAt']?_0x6c46d9-0x1:_0x6c46d9:_0x6c46d9-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x400b0f={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':E(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x400b0f,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x400b0f));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x256983){const _0x3a91d0=this['commentViews']['remove'](_0x256983['id']);this['stopListening'](_0x3a91d0),_0x3a91d0['isEditMode']&&this['_updateHasDirtyComment'](),_0x3a91d0['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x5639b7=>_0x5639b7['isEditMode']);}['_rearrangeCollapse'](){const _0x3b42d7=function(_0x21ef4f){const _0x3de28a=new _0xa9d85c();for(const _0x44e31c of _0x21ef4f)_0x3de28a['add'](_0x44e31c);return _0x3de28a;}(this['commentViews']),_0x52bc04=this['_collapsedCommentsView']['count'];for(let _0x3ca8e0=0x1;_0x3ca8e0<=_0x52bc04;_0x3ca8e0++)_0x3b42d7['remove'](0x1);for(const _0x39eb96 of _0x3b42d7)_0x39eb96['collapse']();_0x52bc04>0x0&&_0x3b42d7['add'](this['_collapsedCommentsView'],0x1),ns(_0x16b9a7(Array['from'](this['visibleViews']),Array['from'](_0x3b42d7)),this['visibleViews'],_0x3b42d7);}['_rearrangeExpand'](){ns(_0x16b9a7(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x30b1e5 of this['visibleViews'])_0x30b1e5['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0xd0f56b=>{this['focusTracker']['add'](_0xd0f56b['element']),this['keystrokes']['listenTo'](_0xd0f56b['element']);}),this['commentViews']['on']('change',(_0x4d45fa,_0x4897a0)=>{for(const _0x437118 of _0x4897a0['removed'])this['focusTracker']['remove'](_0x437118['element']),this['keystrokes']['stopListening'](_0x437118['element']);for(const _0x44261c of Array['from'](_0x4897a0['added'])['reverse']())this['focusTracker']['add'](_0x44261c['element']),this['keystrokes']['listenTo'](_0x44261c['element']);});}}function ns(_0x149b1c,_0x3378c7,_0x3c01e6){let _0x4f5553=0x0;for(const _0x508d73 of _0x149b1c)switch(_0x508d73){case'insert':_0x3378c7['add'](_0x3c01e6['get'](_0x4f5553),_0x4f5553),_0x4f5553++;break;case'delete':_0x3378c7['remove'](_0x4f5553);break;case'equal':_0x4f5553++;}}class as extends kt{constructor(_0x4f2226){super(_0x4f2226);const _0xe5daab=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0xe5daab['to']('contextValue',_0x589a61=>E(_0x4f2226,'THREAD_CONTEXT_LABEL',_0x589a61)),'tabindex':-0x1},'children':[{'text':_0xe5daab['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x5cc0be,_0x1a8622){super(_0x5cc0be);const _0x53d4fe=this['bindTemplate'];this['_model']=_0x1a8622,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x592ecb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x22c242({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x44f759=>!!_0x44f759),this['bind']('contextValue')['to'](this['_model'],'context',_0x181cb8=>_0x181cb8&&_0x181cb8['value']?this['_trimContextValue'](_0x181cb8['value']):E(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',_0x53d4fe['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 _0x1d3c09=new _0xdd1602(this['locale']);return _0x1d3c09['label']=E(this['locale'],'Reopen'),_0x1d3c09['tooltip']=E(this['locale'],'Reopen'),_0x1d3c09['icon']=_0x3f6439,_0x1d3c09['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x5a8dc2=>!_0x5a8dc2),_0x1d3c09['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x2ba81c,_0x4678d7)=>_0x2ba81c&&_0x4678d7),_0x1d3c09['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x1d3c09;}['_trimContextValue'](_0x6de11c){if(_0x6de11c['length']<0x96)return _0x6de11c;const _0x35a784=_0x6de11c['lastIndexOf']('\x20',0x93);return _0x6de11c['substring'](0x0,_0x35a784>-0x1?_0x35a784:0x93)+'...';}['_attachContextActions'](){const _0x1f8459=this['element']['querySelector']('.ck-context'),_0x2594f6=_0x1f8459['querySelector']('.ck-context__value');this['listenTo'](_0x1f8459,'mouseenter',()=>{_0x2594f6['offsetWidth']<_0x2594f6['scrollWidth']&&_0x1f8459['classList']['add']('overlay');}),this['listenTo'](_0x1f8459,'mouseleave',()=>{_0x1f8459['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x12147a of this['focusables'])this['focusTracker']['add'](_0x12147a['element']),this['keystrokes']['listenTo'](_0x12147a['element']);}['_createContextView'](){const _0x9da43c=new as(this['locale']);return _0x9da43c['bind']('contextValue')['to'](this),_0x9da43c;}}class ts extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x30f722,_0x535de5,_0x3a1b56,_0x4944b8){super(_0x30f722),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x535de5,this['_localUser']=_0x3a1b56,this['_config']=_0x4944b8,this['commentThreadHeaderView']=new Xt(_0x30f722,_0x535de5),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x30f722,E(_0x30f722,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x30f722,_0x535de5,Object['assign']({'CommentView':this['_config']['CommentView']},_0x4944b8)),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',(_0x106652,_0x1c90b3)=>_0x106652||!!_0x1c90b3),this['bind']('isUnlinked')['to'](_0x535de5,'unlinkedAt',_0x11cdda=>!!_0x11cdda),this['bind']('ariaLabel')['to'](this,'length',_0x340546=>{const _0x248eae=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return E(this['locale'],'COMMENT_THREAD_LABEL',[_0x340546,_0x248eae]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x592ecb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x22c242({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x1b0c04=>_0x1b0c04['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 _0x352882=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x470158=_0x352882['commentInputView'];return _0x352882['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x470158,'value',(_0x59d8a4,_0xbfe476,_0x588cc6,_0x3cad0a,_0x430f28)=>!!_0x430f28||!!_0x3cad0a&&_0x588cc6&&!_0xbfe476||_0x59d8a4&&_0x588cc6&&!_0xbfe476),_0x470158['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x49ae56,_0x45ceb1,_0xf05a4f)=>{let _0x4873f2;return _0x4873f2=_0xf05a4f&&_0x45ceb1?'Reply\x20to\x20reopen\x20discussion...':_0x49ae56?'Reply...':'Write\x20a\x20comment...',E(this['locale'],_0x4873f2);}),_0x470158['bind']('submitLabel')['to'](this,'length',_0x16476d=>E(this['locale'],_0x16476d?'Reply':'Comment')),_0x470158['on']('submit',(_0x5556c0,_0x4c2be6)=>{this['fire']('addComment',_0x4c2be6),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x470158['on']('cancel',()=>{this['focus']();}),_0x470158['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x470158['on']('cancel',_0x3bc1b3=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x3bc1b3['stop']());}),this['on']('change:isActive',(_0x1cdd3c,_0x5acbf5,_0x178394)=>{_0x178394||this['length']||_0x470158['value']||this['fire']('removeCommentThread');}),_0x352882;}}class vt extends/* #__PURE__ -- @preserve */
27
+ ti(ts){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x2d17b7,_0xfc2309,_0x60aa6b,_0xad60e){super(_0x2d17b7,_0xfc2309,_0x60aa6b,_0xad60e),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x2d17b7,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x38dc9b,_0xca06c3,_0x545f72)=>{_0x545f72||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0xbccb76,_0x293a13,_0xcd60ee)=>{_0xcd60ee&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x4fc52a=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x4fc52a['if']('isActive','ck-thread--active'),_0x4fc52a['if']('isUnlinked','ck-thread--unlinked'),_0x4fc52a['if']('isConfirm','ck-thread--remove-confirmation'),_0x4fc52a['to']('actionIndicator',_0x19d2e9=>_0x19d2e9?'ck-thread--'+_0x19d2e9:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x4fc52a['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 _0x31bfe7 of this['commentsListView']['commentViews'])_0x31bfe7['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x403fdc}=this,_0x5d164b=this['commentsListView']['commentViews']['get'](0x0);_0x5d164b===this['_boundFirstCommentView']||_0x5d164b['isSystemComment']||(this['_boundFirstCommentView']=_0x5d164b,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x5d164b,'actionIndicator',_0x1ccdc2=>'remove'===_0x1ccdc2?'remove':null),_0x5d164b['placeholder']=E(_0x403fdc,'Write\x20a\x20comment...'),_0x5d164b['removeButton']['on']('execute',_0x4a327b=>{_0x4a327b['stop'](),this['showConfirm'](E(_0x403fdc,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x5d164b['focus']();}),_0x5d164b['actionBar']['add'](this['resolveButton'],0x0),_0x5d164b['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x337c71=new _0x462cf1(this['locale']);return _0x337c71['label']=E(this['locale'],'Resolve'),_0x337c71['tooltip']=E(this['locale'],'Resolve'),_0x337c71['icon']=_0xcd4af3,_0x337c71['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x337c71['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x220e3e=>!_0x220e3e),_0x337c71['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x38d949,_0x5e5a30)=>_0x38d949&&!_0x5e5a30),_0x337c71['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x337c71;}['_updateArchivedThreadHeader'](){this['_model']['archivedAt']?this['commentThreadChildren']['has'](this['commentThreadHeaderView'])||(this['commentThreadChildren']['add'](this['commentThreadHeaderView'],0x0),this['focusables']['add'](this['commentThreadHeaderView'],0x0)):this['commentThreadChildren']['has'](this['commentThreadHeaderView'])&&(this['commentThreadChildren']['remove'](this['commentThreadHeaderView']),this['focusables']['remove'](this['commentThreadHeaderView']));}}class es extends kt{constructor(_0xfb595d){super(_0xfb595d),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x4df17e,_0x113adf,_0x31e367)=>{this['element']['innerHTML']=_0x31e367;}),this['element']['innerHTML']=this['content'];}}class hs extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x260eb3,_0x5ea9bf,_0x247843){super(_0x260eb3),this['_model']=_0x5ea9bf,this['_config']=_0x247843,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x5ea9bf,'content',_0x5ea9bf,'authoredAt',(_0x4067c1,_0x89425b)=>E(_0x260eb3,'COMMENT_ARIA_LABEL',[_0x5ea9bf['author']['name'],_0x247843['formatDateTime'](_0x89425b),new DOMParser()['parseFromString'](_0x4067c1,'text/html')['body']['textContent'],_0x5ea9bf['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x260eb3,E(_0x260eb3,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x277c84(),this['focusTracker']=new _0x592ecb(),this['keystrokes']=new jt(),this['focusCycler']=new _0x22c242({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x35c9fe=>_0x35c9fe['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']?E(this['locale'],'EXTERNAL_IMPORT_WORD_COMMENT'):E(this['locale'],'EXTERNAL_COMMENT');}['getUserViewNotificationText'](){return this['_model']['isExternal']?'importWord'===this['_model']['attributes']['@external']['source']?E(this['locale'],'EXTERNAL_IMPORT_WORD_AVATAR',this['_model']['creator']['name']):E(this['locale'],'EXTERNAL_AVATAR',this['_model']['creator']['name']):null;}['_createCommentContentView'](){const _0x27b0ff=new es(this['locale']);return _0x27b0ff['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x1271b8,_0x41b3b0)=>_0x41b3b0?_0x8e7d23(_0x1271b8,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x1271b8),_0x27b0ff;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x16e718=new os(this['locale'],this['_config']['editorConfig']);return _0x16e718['value']=this['_model']['content'],_0x16e718['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x16e718['submitLabel']=E(this['locale'],'Save'),_0x16e718['on']('submit',(_0xbb8570,_0x5e45e2)=>{this['fire']('updateComment',this['_model']['id'],_0x5e45e2),this['switchToDisplayMode'](),this['focus']();}),_0x16e718['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x16e718['once']('editorReady',()=>{_0x16e718['focus']();}),_0x16e718['createEditor'](),_0x16e718['delegate']('editorReady')['to'](this),_0x16e718['delegate']('editorDestroyed')['to'](this),_0x16e718;}['_setupKeyboardNavigation'](){const _0x2f41df=this['element'];this['keystrokes']['listenTo'](_0x2f41df);for(const _0x39736e of this['focusables'])this['focusTracker']['add'](_0x39736e['element']),this['keystrokes']['listenTo'](_0x39736e['element']);this['focusables']['on']('change',(_0x3fa556,_0x2de04f)=>{for(const _0x435091 of _0x2de04f['removed'])this['focusTracker']['remove'](_0x435091['element']),this['keystrokes']['stopListening'](_0x435091['element']);for(const _0x21ce92 of _0x2de04f['added'])this['focusTracker']['add'](_0x21ce92['element']),this['keystrokes']['listenTo'](_0x21ce92['element']);}),this['keystrokes']['set']('enter',(_0x55a031,_0x5aa4e4)=>{_0x2f41df===_0x55a031['target']&&(this['focusCycler']['focusFirst'](),_0x5aa4e4());}),this['keystrokes']['set']('esc',(_0x126e6c,_0x557a3f)=>{_0x2f41df!==_0x126e6c['target']&&(this['focus'](),_0x557a3f());});}}class gt extends/* #__PURE__ -- @preserve */
28
+ ti(hs){['actionBar'];['userView'];constructor(_0x397db0,_0x45f585,_0x239c47){super(_0x397db0,_0x45f585,_0x239c47),this['set']('actionIndicator',null),this['set']('placeholder',E(_0x397db0,'Reply...')),this['bind']('authoredAt')['to'](_0x45f585),this['bind']('resolvedAt')['to'](_0x45f585),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 _0x2167d8(_0x397db0,_0x45f585['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x45f585,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x5dedbf=this['bindTemplate'],_0x164e51=[{'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':_0x5dedbf['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x5dedbf['to']('authoredAt',_0x28d70a=>this['_config']['formatDateTime'](_0x28d70a))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x5dedbf['if']('isEditMode','ck-comment__actions--hidden'),_0x5dedbf['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']&&_0x164e51['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x5dedbf['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x5dedbf['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x5dedbf['if']('isEditMode','ck-comment--edit'),_0x5dedbf['if']('isSystemComment','ck-comment--info'),_0x5dedbf['to']('actionIndicator',_0x58e7d2=>_0x58e7d2?'ck-comment--'+_0x58e7d2:'')],'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':_0x164e51}]}]};}['_createEditButton'](){const _0x4a4d02=new _0xdd1602(this['locale']);return _0x4a4d02['label']=E(this['locale'],'Edit'),_0x4a4d02['icon']=_0x3f2c11,_0x4a4d02['withText']=!0x0,_0x4a4d02['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x4a4d02['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x5bc8d5=>!_0x5bc8d5),_0x4a4d02['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x4a4d02['on']('execute',()=>this['switchToEditMode']()),_0x4a4d02;}['_createRemoveButton'](){const _0x39bb51=new _0xdd1602(this['locale']);return _0x39bb51['label']=E(this['locale'],'Remove'),_0x39bb51['icon']=_0x299129,_0x39bb51['withText']=!0x0,_0x39bb51['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x39bb51['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x33ba8a=>!_0x33ba8a),_0x39bb51['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x39bb51['on']('execute',()=>{this['showConfirm'](E(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x39bb51;}['_createDropdown'](){const _0x4e3d41=_0x147b08(this['locale'],_0x4f6d09),_0x1e1a17=_0x4e3d41['panelView']['children'],_0x39c053=new _0x15b356(this['locale']),_0x2107dd=_0x4e3d41['bindTemplate'];_0x59df6b(_0x4e3d41,()=>this['items']['find'](_0x4f5112=>_0x4f5112['isVisible'])),_0x4e3d41['extendTemplate']({'attributes':{'class':[_0x2107dd['if']('isVisible','ck-hidden',_0x59a37e=>!_0x59a37e)]}});const _0x27ff0d=(_0x133ee3,_0xccd62a=-0x1)=>{const _0xe14581=new _0x51ab8b(this['locale']);_0xe14581['children']['add'](_0x133ee3);const _0x420d1d=_0xccd62a>-0x1?_0xccd62a:_0x39c053['items']['length'];_0x39c053['items']['add'](_0xe14581,_0x420d1d);const _0x49091e=Array['from'](this['items']);_0x4e3d41['unbind']('isEnabled','isVisible'),_0x4e3d41['bind']('isEnabled')['toMany'](_0x49091e,'isEnabled',(..._0xef6360)=>_0xef6360['some'](_0x4d429e=>_0x4d429e)),_0x4e3d41['bind']('isVisible')['toMany'](_0x49091e,'isVisible',(..._0x86663)=>_0x86663['some'](_0x57a7a7=>_0x57a7a7));};_0x4e3d41['panelPosition']='sw',_0x4e3d41['buttonView']['set']({'label':E(this['locale'],'Show\x20more\x20items'),'icon':_0x45a143});for(const _0x4cd66a of this['items'])_0x27ff0d(_0x4cd66a);return _0x1e1a17['add'](_0x39c053),_0x4e3d41['listenTo'](this['items'],'add',(_0x2188cb,_0x19babb,_0xc6818b)=>{_0x27ff0d(_0x19babb,_0xc6818b);}),_0x4e3d41['listenTo'](this['items'],'remove',(_0x829f1d,_0x21efda,_0x2ba287)=>{_0x39c053['items']['remove'](_0x2ba287);}),_0x4e3d41;}['_attachActions'](_0x33b518,_0x27a766){const _0x4f093f=_0x33b518&&_0x33b518['element'];_0x4f093f&&(this['listenTo'](_0x4f093f,'mouseenter',()=>this['actionIndicator']=_0x27a766),this['listenTo'](_0x4f093f,'focus',()=>this['actionIndicator']=_0x27a766),this['listenTo'](_0x4f093f,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x4f093f,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x93e8b9=super['_createCommentInputView']();return _0x93e8b9['bind']('placeholder')['to'](this),_0x93e8b9;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function Lt(_0x438633){const _0x5a32ae=Dt(_0x438633,0x1e),_0x5c1426=new MutationObserver(_0x58a550=>{for(const _0x477a89 of _0x58a550)('attributes'==_0x477a89['type']&&'class'==_0x477a89['attributeName']||'childList'==_0x477a89['type']||'characterData'==_0x477a89['type'])&&_0x5a32ae();});return{'attach'(_0x3e662c){_0x5c1426['observe'](_0x3e662c,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x5c1426['disconnect'](),_0x5a32ae['cancel']();}};}class S extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x597569,_0x952c31){super(_0x597569),this['id']=_0x596ab2(),this['focusTracker']=new _0x592ecb(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x213231,_0x525519)=>this['fire']('Esc',_0x525519)),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']=Lt(()=>this['_updateHeight']()),this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this),this['content']['add'](_0x952c31),this['mainView']=_0x952c31;const _0x342d5a=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x342d5a['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 _0x3e4658=this['element']['clientHeight'];_0x3e4658&&(this['height']=_0x3e4658);}}class d extends/* #__PURE__ -- @preserve */
29
+ _0x1852be(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x1c8730,target:_0x5f2823,type:_0x1522de,isVisible:_0x4b4cea=!0x0}){super(),this['view']=_0x1c8730,this['view']['element']||this['view']['render'](),this['_type']=_0x1522de,this['_target']=_0x5f2823,d['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0xa9d85c([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x26eb2a,_0x156f94)=>{this['view']['focusTracker']['add'](_0x156f94);}),this['focusableElements']['on']('remove',(_0x5476cd,_0x38ba72)=>{this['view']['focusTracker']['remove'](_0x38ba72);}),this['set']('isVisible',_0x4b4cea);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x3a46ff=this['_getNormalizedTarget']();return d['_assertCorrectTarget'](_0x3a46ff),_0x3a46ff;}get['targetRect'](){const _0x2197bf=this['target'];if(null===_0x2197bf)return null;if(_0x2197bf instanceof _0x21625e)return _0x2197bf;const _0x29185f=_0x2197bf['filter'](_0x2e846d=>function(_0x2c330b){const _0x81e908=_0x2c330b['offsetParent'];if(_0x81e908)return!0x0;const _0x16033b=_0x2c330b['getClientRects']()['item'](0x0);return!!_0x16033b;}(_0x2e846d));return 0x0===_0x29185f['length']?null:new _0x21625e(_0x29185f[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0xa32cd1){this['view']['isActive']=_0xa32cd1,this['view']['mainView']['isActive']=_0xa32cd1;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x489382){if(!(null===_0x489382||_0x489382 instanceof _0x21625e||Array['isArray'](_0x489382)&&_0x489382['every'](_0x110524=>li(_0x110524))))throw new _0x1b91dd('annotation-invalid-target',null,{'target':_0x489382});}['_getNormalizedTarget'](){const _0x30d369='function'==typeof this['_target']?this['_target']():this['_target'];return li(_0x30d369)?[_0x30d369]:_0x30d369;}}function li(_0x5dfeb6){return null!==_0x5dfeb6&&'object'==typeof _0x5dfeb6&&'nodeType'in _0x5dfeb6&&0x1===_0x5dfeb6['nodeType'];}class _ extends _0xa9d85c{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x2d5928=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x592ecb(),this['_focusTracker']['on']('change:isFocused',(_0x1c0485,_0x4cfcac,_0x3a9e4b)=>{_0x3a9e4b||this['fire']('blur');});for(const _0x4aaaf8 of _0x2d5928)this['add'](_0x4aaaf8);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x283aea){if(this['has'](_0x283aea))throw new _0x1b91dd('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x283aea['innerView'],_0x283aea),this['_viewToAnnotation']['set'](_0x283aea['view'],_0x283aea);for(const _0x54844c of _0x283aea['focusableElements'])this['_focusTracker']['add'](_0x54844c);this['listenTo'](_0x283aea['focusableElements'],'add',(_0x54b3e6,_0x5c8dc8)=>{this['_focusTracker']['add'](_0x5c8dc8);}),this['listenTo'](_0x283aea['focusableElements'],'remove',(_0x3d725f,_0x674fa1)=>{this['_focusTracker']['remove'](_0x674fa1);}),this['listenTo'](_0x283aea['view']['focusTracker'],'change:isFocused',(_0x1b52b4,_0x215909,_0x46e723)=>{_0x46e723&&this['fire']('focus',_0x283aea);}),_0x283aea['updateTargetRect']();const _0x2ddfcd=this['_getOrderInContent'](_0x283aea['view']['targetRect']);return super['add'](_0x283aea,_0x2ddfcd);}['remove'](_0x513214){if(!this['has'](_0x513214))throw new _0x1b91dd('annotationcollection-not-existing-item',null);this['stopListening'](_0x513214['view']['focusTracker']),this['stopListening'](_0x513214['focusableElements']);for(const _0x125d7d of _0x513214['focusableElements'])this['_focusTracker']['remove'](_0x125d7d);return this['_viewToAnnotation']['delete'](_0x513214['view']),this['_innerViewToAnnotation']['delete'](_0x513214['innerView']),super['remove'](_0x513214);}['getByInnerView'](_0xb0df73){return this['_innerViewToAnnotation']['get'](_0xb0df73);}['getByView'](_0x4b6b48){return this['_viewToAnnotation']['get'](_0x4b6b48);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x5eb4f8 of this)_0x5eb4f8['updateTargetRect']();this['_sort']();}['_sort'](){const _0x16ba67=Array['from'](this)['sort']((_0x509916,_0x5a01ef)=>v(_0x509916['view']['targetRect'],_0x5a01ef['view']['targetRect']));for(let _0xe2ff59=_0x16ba67['length']-0x1;_0xe2ff59>0x0;_0xe2ff59--){const _0x7b06c8=_0x16ba67[_0xe2ff59];_0xe2ff59!==this['getIndex'](_0x7b06c8)&&(this['remove'](_0x7b06c8),this['add'](_0x7b06c8));}}['_getOrderInContent'](_0x1307e2){let _0x3952dd=0x0;if(!_0x1307e2)return this['length'];for(const _0x5644c1 of this){const _0x179436=_0x5644c1['view']['targetRect'];if(_0x179436){if(v(_0x1307e2,_0x179436)<0x0)return _0x3952dd;_0x3952dd++;}}return _0x3952dd;}}function v(_0x20d42b,_0x2d1418){if(null===_0x20d42b&&null===_0x2d1418)return 0x0;if(null===_0x20d42b)return-0x1;if(null===_0x2d1418)return 0x1;const _0x43a961=_0x20d42b['top']-_0x2d1418['top'];return 0x0==_0x43a961?_0x20d42b['left']-_0x2d1418['left']:_0x43a961;}class O extends _0x5f4d65{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x27044e){if(super(_0x27044e),this['collection']=new _(),this['_visibleAnnotations']=new _(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x27044e instanceof _0x342bb8){const _0x25c215=_0x27044e['locale'];_0x27044e['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':E(_0x25c215,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x1f9f76){this['collection']['add'](_0x1f9f76);}['remove'](_0x8a4c8a){this['collection']['remove'](_0x8a4c8a),_0x8a4c8a['destroy']();}['refreshVisibility'](){for(const _0x3bbc43 of this['collection'])_0x3bbc43['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x2142f2){return this['collection']['getByInnerView'](_0x2142f2);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x4d71c0 of this['collection'])_0x4d71c0['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x2f264b){this['fire']('_activateAnnotation',_0x2f264b);}['createAnnotation'](_0x8b22c2){return new d(_0x8b22c2);}['createAnnotationView'](_0x83cc23,_0x9c064){return new S(_0x83cc23,_0x9c064);}['_addActiveAnnotation'](_0x46962b){const _0x1a6760=new Set(this['activeAnnotations']);_0x1a6760['add'](_0x46962b),this['activeAnnotations']=_0x1a6760;}['_removeActiveAnnotation'](_0x9945bf){const _0x5dc400=new Set(this['activeAnnotations']);_0x5dc400['delete'](_0x9945bf),this['activeAnnotations']=_0x5dc400;}['_bindAnnotationsToVisibleAnnotations'](){const _0x2a29b6=this['collection'],_0x3616e5=this['_visibleAnnotations'];function _0x2ccf90(_0x34ecad){const _0xcbaacd=_0x34ecad['source'];_0xcbaacd['isVisible']&&!_0x3616e5['has'](_0xcbaacd)?_0x3616e5['add'](_0xcbaacd):!_0xcbaacd['isVisible']&&_0x3616e5['has'](_0xcbaacd)&&_0x3616e5['remove'](_0xcbaacd),_0xcbaacd['view']['focusTracker']['remove'](_0xcbaacd['view']['element']),_0xcbaacd['view']['focusTracker']['add'](_0xcbaacd['view']['element']);}this['listenTo'](_0x2a29b6,'add',(_0xf2cf05,_0x158dab)=>{_0x158dab['isVisible']&&_0x3616e5['add'](_0x158dab),this['listenTo'](_0x158dab,'change:isVisible',_0x2ccf90);}),this['listenTo'](_0x2a29b6,'remove',(_0x3ed9cd,_0x404552)=>{_0x3616e5['has'](_0x404552)&&_0x3616e5['remove'](_0x404552),this['stopListening'](_0x404552,'change:isVisible',_0x2ccf90);});}['_setupEnterAnnotationKeystroke'](){const _0xa687de=_0x298281=>{_0x298281['on']('ready',()=>{_0x298281['keystrokes']['set'](_0x2e830d,(_0x415656,_0x5a2dd6)=>{const _0x4ec05b=_0x9d13e6(this['activeAnnotations']['values']());_0x4ec05b&&(_0x4ec05b['view']['focus'](),_0x5a2dd6());});});};this['context']instanceof _0x342bb8?_0xa687de(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x539ddf,_0x5e0751)=>{_0xa687de(_0x5e0751);});}['_setupEscapeAnnotationHandling'](){const _0x43434a=_0x4cf80a=>{const _0x105ba8=_0x4cf80a['source'],_0x24c225=[];let _0x10400a;if(Array['isArray'](_0x105ba8['target'])){_0x10400a=_0x105ba8['target'][0x0],this['context']instanceof _0x342bb8?_0x24c225['push'](this['context']):this['context']['editors']&&_0x24c225['push'](...this['context']['editors']);for(const _0x391242 of _0x24c225)for(const _0x30975d of _0x391242['editing']['view']['domRoots']['values']())if(_0x30975d['contains'](_0x10400a))return void _0x391242['editing']['view']['focus']();_0x10400a['focus']();}};this['listenTo'](this['collection'],'add',(_0x396b9f,_0x58ccf4)=>{this['listenTo'](_0x58ccf4,'escape',_0x43434a,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x5aadbb,_0x47ed9c)=>{this['stopListening'](_0x47ed9c,'escape',_0x43434a);});}}const Tt=Symbol('noChannel'),_t={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x5f4d65{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[O,ht,it];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x33d06b){super(_0x33d06b),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x2f3f1c=this['context']['config'];_0x2f3f1c['define']('comments.maxCommentsWhenCollapsed',0x2),_0x2f3f1c['define']('comments.maxThreadTotalWeight',0x1f4),_0x2f3f1c['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x2f3f1c['define']('comments.CommentThreadView',vt),_0x2f3f1c['define']('comments.CommentView',gt),_0x2f3f1c['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x20d7b9=this['context']['plugins']['get'](O);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x285583,_0x1afc26)=>this['_addCommentThread'](_0x1afc26)),this['on']('submitCommentThread',(_0x24a587,_0x1e23c0)=>this['_submitCommentThread'](_0x1e23c0)),this['on']('resolveCommentThread',(_0x59056e,_0x2fafbe)=>this['_resolveCommentThread'](_0x2fafbe)),this['on']('resolveCommentThread',(_0xac0152,_0x2f0d71)=>this['_updateActiveAnnotation'](_0x2f0d71),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x2824b8,_0x362eaf)=>this['_reopenCommentThread'](_0x362eaf)),this['on']('reopenCommentThread',(_0x3c1de7,_0x288362)=>this['_updateActiveAnnotation'](_0x288362),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x548ea0,_0x158516)=>this['_removeCommentThread'](_0x158516)),this['on']('updateCommentThread',(_0x105364,_0x503648)=>this['_updateCommentThread'](_0x503648)),this['on']('updateCommentThread',(_0x466862,_0x1991a2)=>this['_updateActiveAnnotation'](_0x1991a2),{'priority':'lowest'}),this['on']('addComment',(_0x5c4c21,_0x4de442)=>this['_addComment'](_0x4de442)),this['on']('updateComment',(_0x178a8e,_0xd09a25)=>this['_updateComment'](_0xd09a25)),this['on']('removeComment',(_0x30d5fa,_0x2fa0a8)=>this['_removeComment'](_0x2fa0a8)),this['on']('addComment',(_0x76e48a,{threadId:_0x93e1c0,isFromAdapter:_0x26b458})=>{if(_0x26b458)return;const _0x279aad=this['getCommentThread'](_0x93e1c0),_0x573645=_0x279aad&&this['_threadToController']['get'](_0x279aad);_0x573645&&_0x573645['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x20d7b9,'change:activeAnnotations',(_0x1538f9,_0xc4fe2b,_0x2a380f)=>{const _0x509452=Array['from'](_0x2a380f)['map'](_0x138989=>this['_viewToController']['get'](_0x138989['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x509452?_0x509452['model']:null;});}set['adapter'](_0x33eda4){if(this['_adapter'])throw new _0x1b91dd('commentsrepository-adapter-already-set');this['_adapter']=_0x33eda4;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x292e34=Tt,threadId:_0x8a37c7=_0x596ab2(),comments:_0xfce1ca=[],unlinkedAt:_0xa30618=null,resolvedAt:_0x34684e=null,resolvedBy:_0x409eef=null,target:_0x3938ca=null,context:_0x4479fe=null,attributes:_0x180cbb={},isResolvable:_0x410e81=!0x0,isSubmitted:_0x2917e8=!0x1,isFromAdapter:_0xb6f790=!0x1}={}){return this['fire'](bt('addCommentThread',_0x292e34),{'channelId':_0x292e34,'threadId':_0x8a37c7,'comments':_0xfce1ca,'unlinkedAt':_0xa30618,'resolvedAt':_0x34684e,'resolvedBy':_0x409eef,'target':_0x3938ca,'context':_0x4479fe,'attributes':_0x180cbb,'isFromAdapter':_0xb6f790,'isResolvable':_0x410e81,'isSubmitted':_0x2917e8}),this['getCommentThread'](_0x8a37c7);}['openNewCommentThread']({channelId:_0x3c6822=Tt,threadId:_0x16cee2=_0x596ab2(),target:_0x4131df,context:_0x3c70b6=null,isResolvable:_0x27241c=!0x0}){if(this['_readOnlyChannels']['has'](_0x3c6822)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x4131df)throw new _0x1b91dd('commentsrepository-missing-target');const _0x59696c=this['addCommentThread']({'channelId':_0x3c6822,'threadId':_0x16cee2,'target':_0x4131df,'context':_0x3c70b6,'isResolvable':_0x27241c});if(!_0x59696c)return null;const _0x25e053=this['_threadToController']['get'](_0x59696c),_0x3b685c=_0x25e053['view']['commentThreadInputView']['commentInputView'],_0x3a373a=this['context']['plugins']['get'](O),_0x5ba05d=_0x3a373a['getByInnerView'](_0x25e053['view']);return _0x3a373a['activate'](_0x5ba05d),_0x3b685c['once']('editorReady',()=>_0x3b685c['focus']()),_0x59696c;}['hasCommentThread'](_0x33f004){if('string'!=typeof _0x33f004)throw new _0x1b91dd('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x33f004);}['updateCommentThread']({channelId:_0x711ebd=Tt,threadId:_0x69b47d,context:_0x17dd05,unlinkedAt:_0x30f330,attributes:_0x3375ae,isFromAdapter:_0x1d678f=!0x1}){return this['fire'](bt('updateCommentThread',_0x711ebd),{'channelId':_0x711ebd,'threadId':_0x69b47d,'context':_0x17dd05,'unlinkedAt':_0x30f330,'attributes':_0x3375ae,'isFromAdapter':_0x1d678f}),this['getCommentThread'](_0x69b47d);}['getCommentThread'](_0x1ed08c){if('string'!=typeof _0x1ed08c)throw new _0x1b91dd('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x1ed08c);}['fetchCommentThread']({channelId:_0x588571,threadId:_0x2127d1}={}){const _0x3a90cf=this['getCommentThread'](_0x2127d1);if(_0x3a90cf)return Promise['resolve'](_0x3a90cf);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x1b91dd('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x588571,'threadId':_0x2127d1})['then'](_0x1d7648=>this['hasCommentThread'](_0x2127d1)?this['getCommentThread'](_0x2127d1):_0x1d7648?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x588571},_0x1d7648)):void 0x0)['catch'](_0xdd788=>{throw console['error'](_0xdd788),new _0x1b91dd('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x13476e,skipNotAttached:_0x4df781=!0x1,skipEmpty:_0x27a90=!0x1,toJSON:_0x4819fe=!0x1}={}){const _0x5ad881=[];for(const _0x4378e8 of this['_threads']['values']())_0x13476e&&_0x4378e8['channelId']!==_0x13476e||_0x4df781&&!_0x4378e8['isAttached']||_0x27a90&&0x0===_0x4378e8['length']||_0x5ad881['push'](_0x4378e8);return _0x4819fe?_0x5ad881['map'](_0x373880=>_0x373880['toJSON']()):_0x5ad881;}['setActiveCommentThread'](_0x69c3d0){const _0x2c2705=this['context']['plugins']['get'](O);if(!_0x69c3d0)return void(this['activeCommentThread']&&_0x2c2705['deactivateAll']());const _0x115808=this['getCommentThread'](_0x69c3d0);if(!_0x115808)throw new _0x1b91dd('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x69c3d0});if(!this['_threadToController']['has'](_0x115808))throw new _0x1b91dd('commentsrepository-active-not-attached',null,{'threadId':_0x69c3d0});const _0x32db14=_0x2c2705['getByInnerView'](this['_threadToController']['get'](_0x115808)['view']);_0x2c2705['activate'](_0x32db14);}['switchReadOnly'](_0x505552,_0x2af5af){_0x505552?this['_readOnlyChannels']['add'](_0x2af5af):this['_readOnlyChannels']['delete'](_0x2af5af),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x3d1ed6){return this['_readOnlyChannels']['has'](_0x3d1ed6)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x5cbdc5,_0x4abaf5){return new Ct(_0x5cbdc5,_0x4abaf5);}['setPermissions'](_0x5ad916,_0x2f00b0=Tt){this['_permissions']['set'](_0x2f00b0,_0x5ad916),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x30b294=Tt){return this['_permissions']['has'](_0x30b294)?this['_permissions']['get'](_0x30b294):_t;}['_addCommentThread']({channelId:_0x1ec5b4,threadId:_0x474e59,comments:_0xc347a0,unlinkedAt:_0x562759,resolvedAt:_0x57e153,resolvedBy:_0x1b5b7f,target:_0x16d62c,context:_0x17001b,attributes:_0x4ff6e4,isFromAdapter:_0x2567b5,isResolvable:_0x1cd859,isSubmitted:_0x460c66}){if('string'!=typeof _0x474e59)throw new _0x1b91dd('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x474e59});if(this['hasCommentThread'](_0x474e59))throw new _0x1b91dd('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x474e59});const _0x29b868=new ui(this,{'channelId':_0x1ec5b4,'id':_0x474e59,'context':_0x17001b,'attributes':_0x4ff6e4,'unlinkedAt':_0x562759,'resolvedAt':_0x57e153,'resolvedBy':_0x1b5b7f?this['context']['plugins']['get'](it)['getUser'](_0x1b5b7f):null,'isResolvable':_0x1cd859,'isSubmitted':_0x460c66||_0x2567b5});this['_threads']['set'](_0x474e59,_0x29b868);for(const _0x497dde of _0xc347a0)_0x29b868['_add'](this['_createNewComment']({'threadId':_0x474e59,..._0x497dde}));return _0x16d62c&&_0x29b868['attachTo'](_0x16d62c),_0x2567b5||!_0x29b868['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x1ec5b4,'threadId':_0x474e59});}['_submitCommentThread']({channelId:_0x588c4d,threadId:_0x5dd49b}){if(!this['hasCommentThread'](_0x5dd49b))throw new _0x1b91dd('commentsrepository-missing-comment-thread',this);const _0x5cd590=this['getCommentThread'](_0x5dd49b);if(_0x5cd590['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x51b1e8,comments:_0x9eda46,resolvedAt:_0x56dad2,resolvedBy:_0x50acf7,context:_0x32e28a,attributes:_0x2e1879}=_0x5cd590,_0x5726b9=this['context']['plugins']['get']('PendingActions'),_0x4feaa7=_0x5726b9['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x588c4d,'threadId':_0x51b1e8,'comments':_0x9eda46['map'](_0x477173=>_0x477173['toJSON']()),'resolvedAt':_0x56dad2,'resolvedBy':_0x50acf7?_0x50acf7['id']:_0x50acf7,'context':_0x32e28a,'attributes':_0x2e1879})['then'](({comments:_0x4a545c})=>{_0x5726b9['remove'](_0x4feaa7);for(const _0x712867 of _0x4a545c)this['_updateComment']({'channelId':_0x588c4d,'threadId':_0x5dd49b,'commentId':_0x712867['commentId'],'createdAt':_0x712867['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x6aef5e=>{throw console['error'](_0x6aef5e),new _0x1b91dd('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x597d56,target:_0x465432}){const _0x272b47=this['getCommentThread'](_0x597d56);if(!_0x272b47)throw new _0x1b91dd('commentsrepository-attach-missing-comment-thread',this);const _0x5a709b=this['context']['plugins']['get']('PendingActions'),_0x55a45f=this['context']['plugins']['get'](O),_0x16abf0=this['_createCommentThreadView'](_0x272b47),_0x3d542b=new Ct(_0x272b47,_0x16abf0);let _0x499911=null;_0x16abf0['on']('change:isDirty',(_0x484cf7,_0x451993,_0x3724da)=>{_0x3724da?_0x499911=_0x5a709b['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x499911&&(_0x5a709b['remove'](_0x499911),_0x499911=null);}),this['_threadToController']['set'](_0x272b47,_0x3d542b),this['_viewToController']['set'](_0x16abf0,_0x3d542b);const _0x5bea2c=new S(this['context']['locale'],_0x16abf0);_0x5bea2c['bind']('length')['to'](_0x16abf0),_0x5bea2c['bind']('isDirty')['to'](_0x16abf0,'isDirty',_0x16abf0,'length',(_0x3e8d71,_0x40bebc)=>_0x3e8d71||!_0x40bebc),_0x5bea2c['bind']('isActive')['to'](_0x16abf0),_0x5bea2c['type']='comment';const _0xc1c54a=new d({'view':_0x5bea2c,'target':_0x465432,'type':'comment','isVisible':!_0x272b47['archivedAt']});return _0x16abf0['on']('escape',()=>{_0xc1c54a['fire']('escape');}),this['_bindAnnotationToEditors'](_0x16abf0,_0xc1c54a),_0x55a45f['add'](_0xc1c54a),_0xc1c54a;}['_bindAnnotationToEditors'](_0x5033e2,_0x3c1c89){this['listenTo'](_0x5033e2,'editorReady',(_0x318661,_0x226bf9)=>{const _0x134bfd=_0x226bf9['ui']['view']['body']['bodyCollectionContainer'];_0x3c1c89['focusableElements']['add'](_0x134bfd),this['context']instanceof _0x342bb8&&this['context']['ui']['focusTracker']['add'](_0x134bfd);},{'priority':'highest'}),this['listenTo'](_0x5033e2,'editorDestroyed',(_0x4b02cf,_0x27fc52)=>{const _0xa02ee3=_0x27fc52['ui']['view']['body']['bodyCollectionContainer'];_0x3c1c89['focusableElements']['has'](_0xa02ee3)&&_0x3c1c89['focusableElements']['remove'](_0xa02ee3),this['context']instanceof _0x342bb8&&this['context']['ui']['focusTracker']['remove'](_0xa02ee3);});}['_unbindEditors'](_0x528a94){this['stopListening'](_0x528a94,'editorReady'),this['stopListening'](_0x528a94,'editorDestroyed');}['_createCommentThreadView'](_0x392aaf){const _0x2bbbc6=this['context']['plugins']['get'](it),{config:_0x4ad96c,locale:_0x148f3c}=this['context'],_0x5585b9=lt(_0x4ad96c['get']('locale'),_0x148f3c);return new(0x0,(_0x4ad96c['get']('comments'))['CommentThreadView'])(_0x148f3c,_0x392aaf,_0x2bbbc6['me'],{'editorConfig':{..._0x4ad96c['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x4ad96c['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x4ad96c['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x4ad96c['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x4ad96c['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x5585b9,'CommentView':_0x4ad96c['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x4fae57,channelId:_0xf75d6c,resolvedAt:_0x37d918,resolvedBy:_0x5206b4,isFromAdapter:_0x5a59d4}){if(!this['hasCommentThread'](_0x4fae57))throw new _0x1b91dd('commentsrepository-missing-comment-thread',null,{'threadId':_0x4fae57});const _0x37d4b7=this['getCommentThread'](_0x4fae57);if(_0x37d4b7['isResolved'])throw new _0x1b91dd('commentsrepository-resolved-comment-thread',null,{'threadId':_0x4fae57});const _0x2550e8=this['context']['plugins']['get'](it);if(_0x37d4b7['resolvedBy']=_0x2550e8['getUser'](_0x5206b4),_0x37d4b7['resolvedAt']=_0x37d918,_0x5a59d4||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x2641b2=this['context']['plugins']['get']('PendingActions'),_0x1ba0a6=_0x2641b2['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0xf75d6c,'threadId':_0x4fae57})['then'](({resolvedAt:_0x33c6ed,resolvedBy:_0x3d3910})=>{_0x2641b2['remove'](_0x1ba0a6),_0x37d4b7['resolvedBy']['id']!==_0x3d3910&&(_0x37d4b7['resolvedBy']=_0x2550e8['getUser'](_0x3d3910)),_0x37d4b7['resolvedAt']=_0x33c6ed;})['catch'](_0x4d29e8=>{throw console['error'](_0x4d29e8),new _0x1b91dd('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x24a7a9,channelId:_0x31188b,isFromAdapter:_0x4e76db}){if(!this['hasCommentThread'](_0x24a7a9))throw new _0x1b91dd('commentsrepository-missing-comment-thread',null,{'threadId':_0x24a7a9});const _0x18b7d6=this['getCommentThread'](_0x24a7a9);if(!_0x18b7d6['isResolved'])throw new _0x1b91dd('commentsrepository-reopen-comment-thread',null,{'threadId':_0x24a7a9});if(_0x18b7d6['resolvedBy']=null,_0x18b7d6['resolvedAt']=null,_0x4e76db||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x4b6a88=this['context']['plugins']['get']('PendingActions'),_0x1128a2=_0x4b6a88['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x31188b,'threadId':_0x24a7a9})['then'](()=>_0x4b6a88['remove'](_0x1128a2))['catch'](_0x1ff427=>{throw console['error'](_0x1ff427),new _0x1b91dd('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x13c2dd,isFromAdapter:_0x576a90}){const _0x8140d3=this['getCommentThread'](_0x13c2dd);if(!_0x8140d3)throw new _0x1b91dd('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x13c2dd),this['_threads']['delete'](_0x13c2dd),!_0x8140d3['isSubmitted']||_0x576a90||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x4fcb1f=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5e28f9}=_0x8140d3,_0x416318=_0x4fcb1f['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x5e28f9,'threadId':_0x13c2dd})['then'](()=>_0x4fcb1f['remove'](_0x416318))['catch'](_0x350ba4=>{throw console['error'](_0x350ba4),new _0x1b91dd('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x397241,unlinkedAt:_0x3410a9,context:_0x18ed8d,attributes:_0x24a194,isFromAdapter:_0x4ef2be}){if('string'!=typeof _0x397241)throw new _0x1b91dd('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x397241});if(!this['hasCommentThread'](_0x397241))throw new _0x1b91dd('commentsrepository-missing-comment-thread',null,{'threadId':_0x397241});const _0x3289fe=this['getCommentThread'](_0x397241);let _0xa2721=!0x1;if(void 0x0!==_0x18ed8d&&_0x3289fe['context']!==_0x18ed8d&&(_0x3289fe['context']=_0x18ed8d,_0xa2721=!0x0),void 0x0!==_0x3410a9&&_0x3289fe['unlinkedAt']!==_0x3410a9&&(_0x3289fe['unlinkedAt']=_0x3410a9,_0xa2721=!0x0),_0x24a194&&!wt(_0x24a194,_0x3289fe['attributes'])&&(_0x3289fe['attributes']=_0x24a194,_0xa2721=!0x0),!_0xa2721)return Promise['resolve']();if(!_0x3289fe['isSubmitted']||_0x4ef2be||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x23ed67=this['context']['plugins']['get']('PendingActions'),{channelId:_0x1c7e7e}=_0x3289fe,_0x20a824=_0x23ed67['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x1c7e7e,'threadId':_0x397241,'context':_0x18ed8d,'unlinkedAt':_0x3410a9,'attributes':_0x24a194})['then'](()=>_0x23ed67['remove'](_0x20a824))['catch'](_0x36d3d3=>{throw console['error'](_0x36d3d3),new _0x1b91dd('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x186574){const _0x266fc6=this['context']['plugins']['get'](O),_0x2d10a5=this['getCommentThread'](_0x186574);if(_0x2d10a5['_isAttached']=!0x1,this['_threadToController']['has'](_0x2d10a5)){const _0x2dcfa4=this['_threadToController']['get'](_0x2d10a5),_0x435112=_0x2dcfa4['view'],_0xa6bcc4=_0x266fc6['getByInnerView'](_0x435112);this['_threadToController']['delete'](_0x2d10a5),this['_viewToController']['delete'](_0x435112),_0xa6bcc4&&_0x266fc6['remove'](_0xa6bcc4),_0x2dcfa4['destroy'](),_0x435112['destroy']()['then'](()=>{this['_unbindEditors'](_0x435112);});}}['_updateActiveAnnotation']({threadId:_0x2efb51,resolvedAt:_0x52766d,unlinkedAt:_0x5dd75b}){const _0x5ecd1f=!!_0x52766d,_0x3ff077=this['context']['plugins']['get'](O),_0x3eca73=this['getCommentThread'](_0x2efb51);if(this['_threadToController']['has'](_0x3eca73)){const _0x1632ee=this['_threadToController']['get'](_0x3eca73)['view'],_0x36528f=_0x3ff077['getByInnerView'](_0x1632ee);_0x36528f&&(_0x5ecd1f&&_0x3ff077['_removeActiveAnnotation'](_0x36528f),_0x5dd75b?_0x36528f['isVisible']=!0x1:_0x36528f['refreshVisibility']());}}['_getExternalAuthor'](_0x1c205a){const _0x251342=this['context']['plugins']['get'](it),_0x33a157=pt('external:'+_0x1c205a),_0x27056b=_0x251342['getUser'](_0x33a157);return _0x27056b||_0x251342['addUser']({'id':_0x33a157,'name':_0x1c205a});}['_createNewComment']({threadId:_0x364715,commentId:_0x4da8a5=_0x596ab2(),content:_0x4160cf,authorId:_0x208db2,createdAt:_0x1413af,attributes:_0x597bbc}){if('string'!=typeof _0x4da8a5)throw new _0x1b91dd('commentsrepository-invalid-commentid');if('string'!=typeof _0x208db2)throw new _0x1b91dd('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x4160cf||!_0x4160cf['trim']())throw new _0x1b91dd('commentsrepository-invalid-comment-content');const _0x550a8c=this['context']['plugins']['get'](it)['getUser'](_0x208db2);if(!_0x550a8c)throw new _0x1b91dd('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x208db2});let _0x4acc9c=null,_0xf3fe85=_0x1413af;return _0x597bbc?.['@external']&&(_0x4acc9c=this['_getExternalAuthor'](_0x597bbc['@external']['authorName']),_0xf3fe85=new Date(_0x597bbc['@external']['createdAt'])),new fi(this,{'threadId':_0x364715,'id':_0x4da8a5,'author':_0x4acc9c||_0x550a8c,'creator':_0x550a8c,'content':_0x4160cf,'createdAt':_0x1413af,'authoredAt':_0xf3fe85,'attributes':_0x597bbc});}['_addComment'](_0x541e3d){let {threadId:_0x268938,content:_0x1d05a2,attributes:_0xe18769,isFromAdapter:_0x4f3e4f}=_0x541e3d;const _0x69ddd0=this['getCommentThread'](_0x541e3d['threadId']);if(!_0x69ddd0)throw new _0x1b91dd('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x130254=this['_createNewComment'](_0x541e3d),{id:_0x4e7ffe}=_0x130254;if(_0x69ddd0['_add'](_0x130254),_0x4f3e4f||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x69ddd0['isSubmitted'])return Promise['resolve']();const _0xa6d0a4=this['context']['plugins']['get']('PendingActions'),{channelId:_0x195c86}=_0x69ddd0,_0x20450b=_0xa6d0a4['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0xe18769||(_0xe18769={}),this['adapter']['addComment']({'channelId':_0x195c86,'threadId':_0x268938,'commentId':_0x4e7ffe,'content':_0x1d05a2,'attributes':_0xe18769})['then'](_0x18620f=>{_0xa6d0a4['remove'](_0x20450b),_0x18620f&&this['_updateComment']({'channelId':_0x195c86,'threadId':_0x268938,'commentId':_0x4e7ffe,'createdAt':_0x18620f['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x55c7fd=>{throw console['error'](_0x55c7fd),new _0x1b91dd('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x2009ed,commentId:_0x420f87,content:_0x300ccb,createdAt:_0x4d6373,attributes:_0x4fc24e,isFromAdapter:_0x5a415b}){if(void 0x0!==_0x300ccb&&('string'!=typeof _0x300ccb||!_0x300ccb['trim']()['length']))throw new _0x1b91dd('commentsrepository-update-comment-invalid-content');const _0x1ff44c=this['getCommentThread'](_0x2009ed),_0x120702=_0x1ff44c['getComment'](_0x420f87);if(!_0x120702)throw new _0x1b91dd('commentsrepository-update-missing-comment',this);let _0x177858=!0x1;if(_0x300ccb&&_0x300ccb!==_0x120702['content']&&(_0x120702['isEditable']||_0x5a415b)&&(_0x120702['content']=_0x300ccb,_0x177858=!0x0),_0x4d6373&&_0x4d6373!==_0x120702['createdAt']&&(_0x120702['createdAt']=_0x4d6373,_0x120702['attributes']&&_0x120702['attributes']['@external']||(_0x120702['authoredAt']=_0x4d6373),_0x177858=!0x0),_0x4fc24e&&!wt(_0x4fc24e,_0x120702['attributes'])&&(_0x120702['attributes']=_0x4fc24e,_0x177858=!0x0),!_0x177858)return Promise['resolve']();if(_0x1ff44c['fire']('commentUpdated'),_0x5a415b||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0xcbb402=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3b58fc}=this['getCommentThread'](_0x120702['threadId']),_0xed3ce5=_0xcbb402['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x3b58fc,'threadId':_0x2009ed,'commentId':_0x420f87,'content':_0x300ccb,'attributes':_0x4fc24e})['then'](()=>_0xcbb402['remove'](_0xed3ce5))['catch'](_0x4a6a89=>{throw console['error'](_0x4a6a89),new _0x1b91dd('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x216060,commentId:_0xfe8f2c,isFromAdapter:_0x2e87ca}){const _0x4cf1d0=this['getCommentThread'](_0x216060),_0x33ad58=_0x4cf1d0['getComment'](_0xfe8f2c);if(!_0x33ad58)throw new _0x1b91dd('commentsrepository-remove-missing-comment',this);if(_0x4cf1d0['_remove'](_0x33ad58),_0x2e87ca||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x27e30f=this['context']['plugins']['get']('PendingActions'),{channelId:_0x56b832}=_0x4cf1d0,_0xe2f466=_0x27e30f['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x56b832,'threadId':_0x216060,'commentId':_0xfe8f2c})['then'](()=>_0x27e30f['remove'](_0xe2f466))['catch'](_0x347a02=>{throw console['error'](_0x347a02),new _0x1b91dd('commentsrepository-remove-comment-internal-error',this);});}}class ui extends/* #__PURE__ -- @preserve */
30
+ _0x1852be(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0xfbaa40,_0x3b97f7){super();const _0x45c3c1=_0x3b97f7['isResolvable'];this['channelId']=_0x3b97f7['channelId'],this['id']=_0x3b97f7['id'],this['comments']=new _0xa9d85c(),this['_repository']=_0xfbaa40,this['_isAttached']=!0x1,this['_isSubmitted']=_0x3b97f7['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0xfbaa40,'_permissions',_0xfbaa40,'_readOnlyChannels',()=>_0xfbaa40['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0xfbaa40,'_permissions',()=>_0xfbaa40['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0xfbaa40,'_permissions',()=>{const _0x16ad7c=_0xfbaa40['getPermissions'](this['channelId']);return _0x16ad7c['write']||_0x16ad7c['admin'];}),this['bind']('isResolvable')['to'](_0xfbaa40,'_permissions',()=>_0x45c3c1&&_0xfbaa40['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x3b97f7['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x12e6aa,_0x1f792a)=>_0x12e6aa?_0x1f792a?_0x12e6aa<_0x1f792a?_0x12e6aa:_0x1f792a:_0x12e6aa:_0x1f792a),this['set']('unlinkedAt',_0x3b97f7['unlinkedAt']||null),this['set']('resolvedAt',_0x3b97f7['resolvedAt']||null),this['set']('resolvedBy',_0x3b97f7['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x2cb3de=>!!_0x2cb3de),this['set']('attributes',_0x3b97f7['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x4497d9,_0x3e7336)=>_0x4497d9+_0x3e7336['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x556a18,id:_0x59ed4f}=this;this['_repository']['fire'](bt('submitCommentThread',_0x556a18),{'channelId':_0x556a18,'threadId':_0x59ed4f});}['setUnlinkedAt'](_0x25632a){this['_update']({'unlinkedAt':_0x25632a});}['resolve']({resolvedAt:_0x4de45f=new Date(),resolvedBy:_0x3889e5=null,isFromAdapter:_0x18ca36=!0x1}={}){const _0x55d02a=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x4e3cdc,id:_0x576317}=this;this['_repository']['fire'](bt('resolveCommentThread',_0x4e3cdc),{'channelId':_0x4e3cdc,'threadId':_0x576317,'resolvedAt':_0x4de45f,'resolvedBy':_0x3889e5||_0x55d02a['id'],'isFromAdapter':_0x18ca36});}['reopen']({isFromAdapter:_0x585e4f=!0x1}={}){const {channelId:_0x35d681,id:_0x63c0aa}=this;this['_repository']['fire'](bt('reopenCommentThread',_0x35d681),{'channelId':_0x35d681,'threadId':_0x63c0aa,'isFromAdapter':_0x585e4f});}['setContext'](_0x4a2835){this['context']||this['_update']({'context':_0x4a2835});}['setAttribute'](_0x213485,_0x2eba68){const _0x1315ca=It(this['attributes']);At(_0x1315ca,_0x213485,_0x2eba68),this['_update']({'attributes':_0x1315ca});}['removeAttribute'](_0x4e5d28){const _0x2aa0a4=It(this['attributes']);yt(_0x2aa0a4,_0x4e5d28),this['_update']({'attributes':_0x2aa0a4});}['remove']({isFromAdapter:_0x3bed99=!0x1}={}){const {channelId:_0x1ae6b7,id:_0xef2357}=this;this['_repository']['fire'](bt('removeCommentThread',_0x1ae6b7),{'channelId':_0x1ae6b7,'threadId':_0xef2357,'isFromAdapter':_0x3bed99});}['attachTo'](_0x35b88f){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x35b88f});}['addComment'](_0x3c2fb6){const {channelId:_0x130fa6,id:_0x2a303e}=this;this['_repository']['fire'](bt('addComment',_0x130fa6,_0x2a303e),Object['assign']({'channelId':_0x130fa6,'threadId':_0x2a303e},_0x3c2fb6));}['getComment'](_0x4e9703){if('string'!=typeof _0x4e9703)throw new _0x1b91dd('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x4e9703});return this['comments']['get'](_0x4e9703);}['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'](_0x5a02c6=>_0x5a02c6['toJSON']()),'attributes':this['attributes']};}['_add'](_0xcaf8da){return this['listenTo'](_0xcaf8da,'change:authoredAt',()=>{const _0x28c821=this['_findOptimalIndex'](_0xcaf8da),_0x4cc58b=this['comments'];_0x28c821-0x1!=_0x4cc58b['getIndex'](_0xcaf8da)&&_0x28c821+0x1!=_0x4cc58b['getIndex'](_0xcaf8da)&&(this['_remove'](_0xcaf8da),this['_add'](_0xcaf8da));}),this['comments']['add'](_0xcaf8da,this['_findOptimalIndex'](_0xcaf8da));}['_update'](_0x22c65f){const {channelId:_0x394fe0,id:_0x266476}=this;this['_repository']['fire'](bt('updateCommentThread',_0x394fe0),{..._0x22c65f,'channelId':_0x394fe0,'threadId':_0x266476});}['_remove'](_0x57d04d){return this['stopListening'](_0x57d04d),_0x57d04d['destroy'](),this['comments']['remove'](_0x57d04d);}['_findOptimalIndex'](_0x5babdc){const _0x4426ed=this['comments']['find'](_0x727044=>new Date(_0x727044['authoredAt'])['getTime']()>new Date(_0x5babdc['authoredAt'])['getTime']());return _0x4426ed?this['comments']['getIndex'](_0x4426ed):this['length'];}}class fi extends/* #__PURE__ -- @preserve */
31
+ _0x1852be(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x5d4e0d,_0x1f7aa6){super();const _0x3d1373=_0x5d4e0d['context']['plugins']['get'](it)['me'],_0x37971d=_0x5d4e0d['getCommentThread'](_0x1f7aa6['threadId']),_0x1a9ad4=0x0===_0x37971d['comments']['length'],_0x3c71b7=_0x3d1373===_0x1f7aa6['author'];this['id']=_0x1f7aa6['id'],this['threadId']=_0x1f7aa6['threadId'],this['author']=_0x1f7aa6['author'],this['creator']=_0x1f7aa6['creator'],this['isExternal']=Boolean(_0x1f7aa6['attributes']&&_0x1f7aa6['attributes']['@external']),this['set']('content',_0x1f7aa6['content']),this['createdAt']=_0x1f7aa6['createdAt']||new Date(),this['set']('authoredAt',_0x1f7aa6['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x37971d,'resolvedAt'),this['set']('attributes',_0x1f7aa6['attributes']||{}),this['bind']('isEditable')['to'](_0x5d4e0d,'_permissions',()=>{const _0x5ce70a=_0x5d4e0d['getPermissions'](_0x37971d['channelId'])['write'],_0x3c4f8e=_0x5d4e0d['getPermissions'](_0x37971d['channelId'])['modifyAll'];return _0x3c71b7&&_0x5ce70a||!_0x3c71b7&&_0x3c4f8e;}),this['bind']('isRemovable')['to'](_0x37971d,'isRemovable',_0x5d4e0d,'_permissions',_0x5a43bf=>{const _0x19fbe0=_0x5d4e0d['getPermissions'](_0x37971d['channelId'])['write'],_0x1d1cbc=_0x5d4e0d['getPermissions'](_0x37971d['channelId'])['modifyAll'];return _0x3c71b7&&_0x19fbe0||_0x5a43bf&&_0x1a9ad4||!_0x3c71b7&&_0x1d1cbc&&!_0x1a9ad4;}),this['bind']('isReadOnly')['to'](_0x37971d,'isReadOnly'),this['_repository']=_0x5d4e0d;}get['weight'](){return Math['max'](function(_0x4965e3){const _0x232c83=document['createElement']('div');return _0x232c83['innerHTML']=_0x4965e3,_0x232c83['textContent']['length'];}(this['content']),0xc8);}['update'](_0x308dea){const {threadId:_0x56795d,id:_0xa1b089}=this;if(!this['_repository']['hasCommentThread'](_0x56795d))throw new _0x1b91dd('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x358289}=this['_repository']['getCommentThread'](_0x56795d);this['_repository']['fire'](bt('updateComment',_0x358289,_0x56795d),{'channelId':_0x358289,'threadId':_0x56795d,'commentId':_0xa1b089,..._0x308dea});}['setAttribute'](_0x4385a4,_0x3db66c){const _0x1fddf0=It(this['attributes']);At(_0x1fddf0,_0x4385a4,_0x3db66c),this['update']({'attributes':_0x1fddf0});}['removeAttribute'](_0x4701ea){const _0x47d41a=It(this['attributes']);yt(_0x47d41a,_0x4701ea),this['update']({'attributes':_0x47d41a});}['remove'](_0x39202b={}){if(!_0x39202b['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x36b4e6,id:_0x1ba600}=this;if(!this['_repository']['hasCommentThread'](_0x36b4e6))throw new _0x1b91dd('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x1697ba}=this['_repository']['getCommentThread'](_0x36b4e6);this['_repository']['fire'](bt('removeComment',_0x1697ba,_0x36b4e6),{'channelId':_0x1697ba,'threadId':_0x36b4e6,'commentId':_0x1ba600,..._0x39202b});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function bt(_0x23a481,..._0x560443){for(const _0x422366 of _0x560443)void 0x0!==_0x422366&&(_0x23a481+=':'+String(_0x422366));return _0x23a481;}class J extends _0x98c743{['refresh'](){const _0x522e39=this['editor']['model']['document']['selection'];for(const _0x3154ae of _0x522e39['getRanges']())if(this['_hasContent'](_0x3154ae))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['execute']({threadId:_0x589e69=_0x596ab2()}={}){const _0x16b943=this['editor']['model'],_0x3028bd=[];for(const _0x1c7958 of _0x16b943['document']['selection']['getRanges']())this['_hasContent'](_0x1c7958)&&_0x3028bd['push'](this['_trimToContent'](_0x1c7958));_0x16b943['change'](_0x4edfb1=>{for(const _0x271a23 of _0x3028bd){const _0x10892a=_0x596ab2()['substr'](0x1,0x5),_0x23a9aa='comment:'+_0x589e69+':'+_0x10892a;_0x4edfb1['addMarker'](_0x23a9aa,{'range':_0x271a23,'usingOperation':!0x1,'affectsData':!0x1});}});}['_hasContent'](_0x56d19f){for(const _0x2c432a of _0x56d19f['getItems']())if(this['_itemIsContent'](_0x2c432a))return!0x0;return!0x1;}['_itemIsContent'](_0x42eb9f){return _0x42eb9f['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x42eb9f)&&!_0x42eb9f['is']('element','tableCell');}['_trimToContent'](_0x320897){const _0x14c78a=_0x1e29b0=>!this['_itemIsContent'](_0x1e29b0['item']),_0x2a5b90=_0x320897['start']['getLastMatchingPosition'](_0x14c78a),_0x6ce190=_0x320897['end']['getLastMatchingPosition'](_0x14c78a,{'direction':'backward'});return this['editor']['model']['createRange'](_0x2a5b90,_0x6ce190);}}class P extends _0x3d65c4{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[O];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x29a2f4){super(_0x29a2f4),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x4db4fb=this['editor'],_0x25b115=_0x4db4fb['model']['document']['selection'],_0x1b052c=_0x281f66(()=>this['refreshSelectedViews'](),0xa);_0x25b115['on']('change:range',(_0x3cdd1a,_0x33c6cd)=>{_0x33c6cd['directChange']&&(_0x1b052c['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x4db4fb['editing']['view']['document'],'change:isFocused',(_0x1a46d6,_0x8bd0d7,_0x471232)=>{_0x471232&&_0x1b052c();}),this['listenTo'](_0x4db4fb['ui']['focusTracker'],'change:isFocused',(_0x4a9118,_0x492241,_0x3695f7)=>{_0x3695f7||_0x4db4fb['isReadOnly']||this['fire']('blur',{'isAnnotationTracked':_0x2f30bb=>this['_editorAnnotationsData']['has'](_0x2f30bb['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0xf485e8){if(this['_editorAnnotations']['has'](_0xf485e8['view']))return;this['_editorAnnotations']['add'](_0xf485e8['view']),this['editor']['ui']['focusTracker']['add'](_0xf485e8['view']['element']);const _0x571752=this['editor']['plugins']['get'](O);this['listenTo'](_0x571752['collection'],'remove',(_0x55b3c0,_0x2c031f)=>{this['editor']['ui']['focusTracker']['remove'](_0x2c031f['view']['element']),this['_editorAnnotations']['delete'](_0x2c031f['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0xfb4cd1){if('function'!=typeof _0xfb4cd1)throw new _0x1b91dd('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0xfb4cd1);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x214667,annotations:_0x28b4ce}){const _0x476d07=[],_0x1397d3=this['editor']['model']['document']['selection'],_0x55812c=Array['from'](_0x1397d3['getRanges']());for(const [_0x254602,_0x151251]of this['_editorAnnotationsData']){const _0x488b42=_0x1af9ae(_0x151251),_0x1ab339=_0x28b4ce['getByInnerView'](_0x254602);_0x488b42&&_0x1ab339&&_0x476d07['push']({'annotation':_0x1ab339,'range':_0x488b42});}function _0x1af9ae(_0x4c2386){for(const _0x4ebfbf of _0x4c2386)for(const _0x2449c6 of _0x55812c)if(_0x4ebfbf['containsRange'](_0x2449c6,!_0x1397d3['isCollapsed']))return _0x4ebfbf;return null;}return _0x476d07['sort']((_0x446e56,_0x34ec70)=>{const _0x474de5=_0x446e56['range'],_0x1c422e=_0x34ec70['range'];if(!_0x474de5['isEqual'](_0x1c422e)){if(_0x474de5['containsRange'](_0x1c422e,!0x0))return 0x1;if(_0x1c422e['containsRange'](_0x474de5,!0x0))return-0x1;}return _0x446e56['annotation']==_0x214667?-0x1:_0x34ec70['annotation']==_0x214667?0x1:0x0;})['map'](_0xc271c5=>_0xc271c5['annotation']);}get['_editorAnnotationsData'](){const _0x48efd3=new Map();for(const _0x2bb9eb of Array['from'](this['_dataCollectors']))for(const [_0x3546f2,_0x206003]of _0x2bb9eb())_0x48efd3['set'](_0x3546f2,_0x206003);return _0x48efd3;}}class st extends _0x3d65c4{['afterInit'](){const _0x338344=this['editor'];if(!_0x338344['plugins']['has']('RestrictedEditingModeEditing'))return;_0x338344['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x3d65c4{constructor(_0x286c28){super(_0x286c28),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x464c48=this['editor'],_0x55e398=_0x464c48['commands']['get']('importWord'),_0x208614=_0x464c48['plugins']['get'](it);_0x55e398&&(_0x55e398['on']('execute',(_0x4b1747,[,_0x1bacf3])=>{_0x1bacf3['collaboration_features']={'comments':!0x0,'user_id':_0x208614['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x55e398,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x14275b,_0x59d50b){const {comment_threads:_0x51cb5f}=_0x59d50b;_0x51cb5f&&_0x51cb5f['forEach'](({thread_id:_0x3054ff,comments:_0x5a1f84,is_resolved:_0x4ef876})=>{const _0x45851d=new Date(),_0x116ed7=_0x5a1f84['map'](({author:_0x424480,content:_0x1424e9,created_at:_0x105b9a})=>({'content':_0x1424e9,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x45851d,'attributes':{'@external':{'authorName':_0x424480,'createdAt':_0x105b9a?new Date(_0x105b9a):new Date(),'source':'importWord'}}})),_0x20da88=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x20da88,'threadId':_0x3054ff,'comments':_0x116ed7,'resolvedAt':_0x4ef876?_0x45851d:null});});}}class at extends _0x3d65c4{constructor(_0x41b8d8){super(_0x41b8d8),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x405bb1=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x405bb1,'contentInsertion',(_0x57c87c,_0x2dcb74)=>this['_removeMarkersWithoutThreads'](_0x2dcb74['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x324df8){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x324df8;const _0x59c7c1=this['editor']['plugins']['get']('CommentsRepository');for(const _0x4f87a of _0x324df8['keys']()){const [_0x44b82c,_0x47b5a7]=_0x4f87a['split'](':');'comment'!=_0x44b82c||_0x59c7c1['hasCommentThread'](_0x47b5a7)||_0x324df8['delete'](_0x4f87a);}return _0x324df8;}['_registerMarkerInClipboardPipeline'](){const _0x1d6583=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x3f3ec8=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x3f3ec8&&_0x1d6583['_registerMarkerToCopy']('comment',_0x3f3ec8);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x418e48){switch(_0x418e48){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}class ut extends _0x3d65c4{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x5aa6eb,_0x284751)=>{if(!_0x284751['options']['showCommentHighlights'])return null;if(_0x284751['options']['ignoreResolvedComments']){const {id:_0x145411}=er(_0x5aa6eb['markerName']),_0x36edd2=this['editor']['plugins']['get'](o);if(_0x36edd2['getCommentThread'](_0x145411)?.['isResolved']&&_0x5aa6eb['item'])return _0x284751['consumable']['consume'](_0x5aa6eb['item'],'addMarker:'+_0x5aa6eb['markerName']),_0x284751['consumable']['consume'](_0x5aa6eb['item'],'removeMarker:'+_0x5aa6eb['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x3ad856=>{_0x3ad856['on']('addMarker:comment',(_0x40c69f,_0x164ac3,_0x512373)=>{if(!_0x512373['options']['showCommentHighlights'])return;const _0x61f12f=_0x164ac3['item'];if(!_0x61f12f)return;const _0xa269bf=_0x512373['mapper']['toViewElement'](_0x61f12f);this['editor']['model']['schema']['isObject'](_0x61f12f)&&_0xa269bf&&!_0xa269bf['getCustomProperty']('widget')&&_0xa269bf['is']('containerElement')&&_0x5ba603(_0xa269bf,_0x512373['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x26b633,{writer:_0x2b5e1e,options:_0x2983bd})=>{if(!_0x2983bd['showCommentHighlights'])return null;const _0x24675e=_0x2b5e1e['createContainerElement']('div'),_0x34a7c6=_0x2b5e1e['createEmptyElement']('hr');return _0x2b5e1e['addClass']('ck-horizontal-line',_0x24675e),_0x2b5e1e['insert'](_0x2b5e1e['createPositionAt'](_0x24675e,0x0),_0x34a7c6),_0x24675e;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x20c0e2,{writer:_0x461155,options:_0x16c4f5})=>{if(!_0x16c4f5['showCommentHighlights'])return null;const _0x3e703a=_0x461155['createContainerElement']('span'),_0x3f4aa4=_0x461155['createEmptyElement']('img');return _0x461155['addClass']('image-inline',_0x3e703a),_0x461155['insert'](_0x461155['createPositionAt'](_0x3e703a,0x0),_0x3f4aa4),_0x3e703a;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x21e866,{writer:_0x18f607,options:_0x1c09c9})=>{if(_0x1c09c9['showCommentHighlights'])return _0x18f607['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x4ef5cb,_0xd2ca05,_0x1e03ee)=>{_0x1e03ee['options']['showCommentHighlights']&&_0x4ef5cb['stop']();},{'priority':'high'});}}class r extends _0x3d65c4{static get['requires'](){return[o,P,it,st,ct,at,ut];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2875ba){super(_0x2875ba),this['set']('isThreadsLoadingPaused',!0x0),_0x2875ba['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x524656,_0x396d06,_0x10f2ac,_0x1f38dd)=>{const _0x256bd8=_0x2875ba['plugins']['get'](o),_0x59fe20=_0x10f2ac?er(_0x10f2ac)['id']:null;_0x2875ba['model']['change'](()=>{if(_0x59fe20){const _0x596bf1=this['getAllMarkersForId'](_0x59fe20);for(const _0x205def of _0x596bf1)_0x2875ba['editing']['reconvertMarker'](_0x205def);}if(_0x1f38dd){const {id:_0x2ce729}=er(_0x1f38dd),_0x1b2576=_0x256bd8['getCommentThread'](_0x2ce729);if(_0x1b2576&&_0x1b2576['unlinkedAt'])return;if(_0x1b2576&&!_0x1b2576['isAttached'])return;const _0x4fef98=this['getAllMarkersForId'](_0x2ce729);for(const _0xa3762f of _0x4fef98)_0x2875ba['editing']['reconvertMarker'](_0xa3762f);}}),_0x59fe20&&this['scrollToThreadMarker'](_0x59fe20);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x4747e0=this['editor'],_0x2c3439=_0x4747e0['plugins']['get'](o),_0x3fb3cd=_0x4747e0['config']['get']('collaboration.channelId'),_0x32d53c=_0x2c3439['getCommentThreads']()['filter'](_0x597c9b=>_0x597c9b['channelId']!==_0x3fb3cd);_0x4747e0['commands']['add']('addCommentThread',new J(_0x4747e0)),this['listenTo'](_0x4747e0,'change:isReadOnly',(_0x4bb329,_0x252ad9,_0x563de1)=>{_0x2c3439['switchReadOnly'](_0x563de1,_0x4747e0['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x2c3439,ft('addCommentThread',_0x3fb3cd),(_0x410b16,{threadId:_0xf0c84d})=>{const _0xb440ec=this['editor']['plugins']['get'](o)['getCommentThread'](_0xf0c84d);_0xb440ec?.['unlinkedAt']&&this['_attachArchivedThread'](_0xf0c84d);}),this['listenTo'](_0x2c3439,ft('removeCommentThread',_0x3fb3cd),(_0x2b9ad7,{threadId:_0x11e16a})=>{_0x4747e0['model']['enqueueChange']({'isUndoable':!0x1},_0x131ec6=>{const _0x358a9c=this['getAllMarkersForId'](_0x11e16a);for(const _0x80a7a2 of _0x358a9c)_0x131ec6['removeMarker'](_0x80a7a2);});}),this['listenTo'](_0x2c3439,ft('resolveCommentThread',_0x3fb3cd),(_0x1a004e,{threadId:_0x2a67c5})=>{(this['_reconvertMarkers'](_0x2a67c5),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x2a67c5)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x2c3439,ft('reopenCommentThread',_0x3fb3cd),(_0x3f5336,{threadId:_0x432309})=>{this['_reconvertMarkers'](_0x432309);},{'priority':'low'}),this['listenTo'](_0x2c3439,ft('addComment',_0x3fb3cd),(_0x517fd4,{threadId:_0x243670,isFromAdapter:_0x5dabd9})=>{const _0x29442e=this['getAllMarkersForId'](_0x243670);if(_0x5dabd9||0x0==_0x29442e['length']||!_0x2c3439['hasCommentThread'](_0x243670))return;0x1===_0x2c3439['getCommentThread'](_0x243670)['length']&&_0x4747e0['model']['enqueueChange']({'isUndoable':!0x1},_0x19439b=>{for(const _0x28b4fa of _0x29442e)_0x19439b['updateMarker'](_0x28b4fa,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x32d53c);}['afterInit'](){!async function(_0x1c46e2){const _0x2ee285=_0x4399c5([0x52,0x59,0x44,0x55,0x4b,0x67,0x36,0x42,0x64,0x63,0x49,0x6b,0x79,0x6c,0x4f,0x62,0x7a,0x72,0x43,0x53,0x6e,0x76,0x4c,0x68,0x37,0x71,0x73,0x61,0x65,0x45,0x47,0x34,0x51,0x56,0x46,0x35,0x50,0x32,0x41,0x4a,0x78,0x58,0x66,0x33,0x77,0x70,0x57,0x6f,0x75,0x74,0x5a,0x4d,0x48,0x38,0x39,0x6d,0x6a,0x69,0x31,0x30,0x54,0x4e]),_0x1ee284=0x2031f437,_0x401caf=0x2036906f^_0x1ee284,_0x28ecc6=window[_0x4399c5([0x44,0x61,0x74,0x65])][_0x4399c5([0x6e,0x6f,0x77])](),_0x467847=_0x1c46e2[_0x4399c5([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2a998e=new window[(_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1de20f=>{_0x467847[_0x4399c5([0x6f,0x6e,0x63,0x65])](_0x4399c5([0x72,0x65,0x61,0x64,0x79]),_0x1de20f);}),_0x398992={[_0x4399c5([0x6b,0x74,0x79])]:_0x4399c5([0x45,0x43]),[_0x4399c5([0x75,0x73,0x65])]:_0x4399c5([0x73,0x69,0x67]),[_0x4399c5([0x63,0x72,0x76])]:_0x4399c5([0x50,0x2d,0x32,0x35,0x36]),[_0x4399c5([0x78])]:_0x4399c5([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]),[_0x4399c5([0x79])]:_0x4399c5([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]),[_0x4399c5([0x61,0x6c,0x67])]:_0x4399c5([0x45,0x53,0x32,0x35,0x36])},_0x413b51=_0x467847[_0x4399c5([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4399c5([0x67,0x65,0x74])](_0x4399c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x21dcf5(){let _0x40aef9,_0x50fae6=null,_0x3a9557=null;try{if(_0x413b51==_0x4399c5([0x47,0x50,0x4c]))return _0x4399c5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x40aef9=_0x39ca22(),!_0x40aef9)return _0x4399c5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x40aef9[_0x4399c5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3a9557=_0x389e97(_0x40aef9[_0x4399c5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x40aef9[_0x4399c5([0x6a,0x74,0x69])])),await _0x5cdcb0()?_0x2d05a3()?_0x34f3cf()?_0x4399c5([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0xf0a46f()?(_0x40aef9[_0x4399c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4399c5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x50fae6=_0x28624d(_0x4399c5([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x40aef9[_0x4399c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4399c5([0x74,0x72,0x69,0x61,0x6c])&&(_0x50fae6=_0x28624d(_0x4399c5([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2e1c6d()):_0x4399c5([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4399c5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4399c5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x5a4ff7){return _0x4399c5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x34f3cf(){const _0x5e920c=[_0x4399c5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4399c5([0x74,0x72,0x69,0x61,0x6c])][_0x4399c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x40aef9[_0x4399c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x28ecc6/0x3e8:0xe10*_0x401caf;return _0x40aef9[_0x4399c5([0x65,0x78,0x70])]<_0x5e920c;}function _0x2d05a3(){const _0x4b33da=_0x40aef9[_0x4399c5([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4b33da)return!0x1;if(_0x4b33da[_0x4399c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4399c5([0x2a])))return!0x0;if(_0x4b33da[_0x4399c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4399c5([0x43,0x4d,0x54])))return!0x0;if(_0x4b33da[_0x4399c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4399c5([0x52,0x43,0x4d,0x54]))){if(_0x32e68e())return!0x0;if(_0x455035()||_0x275a9c())return!0x0;}return!0x1;}function _0xf0a46f(){const _0x1d64ca=_0x40aef9[_0x4399c5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x1d64ca||0x0==_0x1d64ca[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2f2781}=new URL(window[_0x4399c5([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x1d64ca[_0x4399c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2f2781))return!0x0;const _0xc91745=_0x2f2781[_0x4399c5([0x73,0x70,0x6c,0x69,0x74])](_0x4399c5([0x2e]));return _0x1d64ca[_0x4399c5([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4d9bcd=>_0x4d9bcd[_0x4399c5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4399c5([0x2a])))[_0x4399c5([0x6d,0x61,0x70])](_0x3fe912=>_0x3fe912[_0x4399c5([0x73,0x70,0x6c,0x69,0x74])](_0x4399c5([0x2e])))[_0x4399c5([0x73,0x6f,0x6d,0x65])](_0x30e9c5=>_0xc91745[_0x4399c5([0x65,0x76,0x65,0x72,0x79])]((_0x353925,_0x46fad0)=>_0x30e9c5[_0x46fad0]===_0x353925||_0x30e9c5[_0x46fad0]===_0x4399c5([0x2a])));}function _0x2e1c6d(){return _0x50fae6&&_0x3a9557?new window[(_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1125bd,_0x251dc6)=>{_0x50fae6[_0x4399c5([0x74,0x68,0x65,0x6e])](_0x1125bd,_0x251dc6),_0x3a9557[_0x4399c5([0x74,0x68,0x65,0x6e])](_0x109bb0=>{_0x109bb0!=_0x4399c5([0x56,0x61,0x6c,0x69,0x64])&&_0x1125bd(_0x109bb0);},_0x251dc6);}):_0x50fae6||_0x3a9557||_0x4399c5([0x56,0x61,0x6c,0x69,0x64]);}}function _0x389e97(_0x1cc7c3,_0x2d2392){return new window[(_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x53c0c4=>{if(_0x3a36c9())return _0x53c0c4(_0x4399c5([0x56,0x61,0x6c,0x69,0x64]));_0x457c07(),_0x467847[_0x4399c5([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4399c5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5e5905=!0x1;const _0x44d2da=_0x596ab2();function _0x31a1e1(_0x2db8e7){return!!_0x2db8e7&&(typeof _0x2db8e7===_0x4399c5([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2db8e7===_0x4399c5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2db8e7[_0x4399c5([0x74,0x68,0x65,0x6e])]===_0x4399c5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2db8e7[_0x4399c5([0x63,0x61,0x74,0x63,0x68])]===_0x4399c5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1a1a09(_0x6abc6){_0x53551e(_0x6abc6)[_0x4399c5([0x74,0x68,0x65,0x6e])](_0x42e774=>{if(!_0x42e774||_0x42e774[_0x4399c5([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4399c5([0x6f,0x6b]))return _0x4399c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xd325b0(_0x5f3274(_0x44d2da+_0x2d2392))!=_0x42e774[_0x4399c5([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4399c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4399c5([0x56,0x61,0x6c,0x69,0x64]);})[_0x4399c5([0x74,0x68,0x65,0x6e])](_0xddc2b4=>(_0x25a631(),_0xddc2b4),()=>{const _0x18c9e3=_0x45760f();return null==_0x18c9e3?(_0x25a631(),_0x4399c5([0x56,0x61,0x6c,0x69,0x64])):_0x4399c5(_0x28ecc6-_0x18c9e3>(0x43d7037^_0x1ee284)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4399c5([0x74,0x68,0x65,0x6e])](_0x53c0c4)[_0x4399c5([0x63,0x61,0x74,0x63,0x68])](()=>{_0x53c0c4(_0x4399c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x47e9cb=0x20071ab7^_0x1ee284;function _0x25a631(){const _0x2b982d=_0x4399c5([0x6c,0x6c,0x63,0x74,0x2d])+_0xd325b0(_0x5f3274(_0x1cc7c3)),_0x1e8146=_0x292694(_0xd325b0(window[_0x4399c5([0x4d,0x61,0x74,0x68])][_0x4399c5([0x63,0x65,0x69,0x6c])](_0x28ecc6/_0x47e9cb)));window[_0x4399c5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4399c5([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2b982d,_0x1e8146);}function _0x45760f(){const _0x6320d5=_0x4399c5([0x6c,0x6c,0x63,0x74,0x2d])+_0xd325b0(_0x5f3274(_0x1cc7c3)),_0x5d9d93=window[_0x4399c5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4399c5([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x6320d5);return _0x5d9d93?window[_0x4399c5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x292694(_0x5d9d93),0x10)*_0x47e9cb:null;}function _0x53551e(_0x3094d5){return new window[(_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3b2cb1,_0x6e7004)=>{_0x3094d5[_0x4399c5([0x74,0x68,0x65,0x6e])](_0x3b2cb1,_0x6e7004),window[_0x4399c5([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x6e7004,0x203020f7^_0x1ee284);});}}_0x467847[_0x4399c5([0x6f,0x6e])](_0x4399c5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5ecab6,_0x203438)=>{if(_0x203438[0x0]!=_0x1cc7c3)return _0x53c0c4(_0x4399c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x203438[0x1]={..._0x203438[0x1],[_0x4399c5([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x44d2da};},{[_0x4399c5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4399c5([0x68,0x69,0x67,0x68])}),_0x467847[_0x4399c5([0x6f,0x6e])](_0x4399c5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3819d6=>{_0x31a1e1(_0x3819d6[_0x4399c5([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5e5905=!0x0,_0x1a1a09(_0x3819d6[_0x4399c5([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4399c5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4399c5([0x6c,0x6f,0x77])}),_0x2a998e[_0x4399c5([0x74,0x68,0x65,0x6e])](()=>{_0x5e5905||_0x53c0c4(_0x4399c5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3a36c9(){return _0x467847[_0x4399c5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4399c5([0x76,0x69,0x65,0x77])][_0x4399c5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4399c5([0x61,0x75,0x74,0x6f]);}function _0x457c07(){_0x467847[_0x4399c5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4399c5([0x76,0x69,0x65,0x77])][_0x4399c5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4399c5([0x61,0x75,0x74,0x6f]);}}function _0x28624d(_0x5a283c){const _0x661297=[new window[(_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1abce2=>setTimeout(_0x1abce2,0x2038cafb^_0x1ee284)),_0x2a998e[_0x4399c5([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x58b9c1=>{let _0xa53a68=0x0;_0x467847[_0x4399c5([0x6d,0x6f,0x64,0x65,0x6c])][_0x4399c5([0x6f,0x6e])](_0x4399c5([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x327833,_0xfdc2a)=>{_0xfdc2a[0x0][_0x4399c5([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0xa53a68++,_0xa53a68==(0x2031f5cf^_0x1ee284)&&(_0x58b9c1(),_0x327833[_0x4399c5([0x6f,0x66,0x66])]());});}))];return window[_0x4399c5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4399c5([0x72,0x61,0x63,0x65])](_0x661297)[_0x4399c5([0x74,0x68,0x65,0x6e])](()=>_0x5a283c);}async function _0x6ee4d7(){await _0x2a998e,_0x467847[_0x4399c5([0x6d,0x6f,0x64,0x65,0x6c])][_0x4399c5([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1a7aca,_0x467847[_0x4399c5([0x6d,0x6f,0x64,0x65,0x6c])][_0x4399c5([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1a7aca,_0x467847[_0x4399c5([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4399c5([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x32e68e(){return _0x254d61(_0x4399c5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5e4db3(_0x4399c5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4399c5([0x73,0x74,0x61,0x74,0x65])]==_0x4399c5([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x455035(){return _0x254d61(_0x4399c5([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 _0x275a9c(){return _0x254d61(_0x4399c5([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x39a7fa(_0x52d233){const _0x4b309a=_0x33a773();_0x467847[_0x4b309a]=_0x4399c5([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x52d233,_0x52d233!=_0x4399c5([0x56,0x61,0x6c,0x69,0x64])&&_0x6ee4d7();}function _0x33a773(){const _0x358077=window[_0x4399c5([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4399c5([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4399c5([0x6e,0x6f,0x77])]())[_0x4399c5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4399c5([0x2e]),'');let _0x4bc7ce=_0x4399c5([0x52]);for(let _0x6cf780=0x0;_0x6cf780<_0x358077[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x6cf780+=0x2){let _0x223f8f=window[_0x4399c5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x358077[_0x4399c5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x6cf780,_0x6cf780+0x2));_0x223f8f>=_0x2ee285[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x223f8f-=_0x2ee285[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4bc7ce+=_0x2ee285[_0x223f8f];}return _0x4bc7ce;}function _0x39ca22(){const _0x5018f6=_0x413b51[_0x4399c5([0x73,0x70,0x6c,0x69,0x74])](_0x4399c5([0x2e]));if(0x3!=_0x5018f6[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1b1ba0(_0x5018f6[0x1]);function _0x1b1ba0(_0xad24ad){const _0x4ed156=_0x16563a(_0xad24ad);return _0x4ed156&&_0x251e1e()?_0x4ed156:null;function _0x251e1e(){const _0x41157c=_0x4ed156[_0x4399c5([0x6a,0x74,0x69])],_0x23ad97=window[_0x4399c5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x41157c[_0x4399c5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x41157c[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x29774b={..._0x4ed156,[_0x4399c5([0x6a,0x74,0x69])]:_0x41157c[_0x4399c5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x41157c[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x29774b[_0x4399c5([0x76,0x63])],_0x5f3274(_0x29774b)==_0x23ad97;}}}async function _0x5cdcb0(){let _0x184631=!0x0;try{const _0x514f0d=_0x413b51[_0x4399c5([0x73,0x70,0x6c,0x69,0x74])](_0x4399c5([0x2e])),[_0x1338b7,_0x41abb7,_0x3081b1]=_0x514f0d;return _0x23ebf0(_0x1338b7),await _0xb264cd(_0x1338b7,_0x41abb7,_0x3081b1),_0x184631;}catch(_0x3724f8){return!0x1;}function _0x23ebf0(_0x3d768c){const _0x143f1e=_0x16563a(_0x3d768c);_0x143f1e&&_0x143f1e[_0x4399c5([0x61,0x6c,0x67])]==_0x4399c5([0x45,0x53,0x32,0x35,0x36])||(_0x184631=!0x1);}async function _0xb264cd(_0x3774a5,_0x3d982e,_0x39cd16){const _0x322590=window[_0x4399c5([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4399c5([0x66,0x72,0x6f,0x6d])](_0x496192(_0x39cd16),_0x34c7d1=>_0x34c7d1[_0x4399c5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4c850c=new window[(_0x4399c5([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4399c5([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3774a5+_0x4399c5([0x2e])+_0x3d982e),_0x29643a=window[_0x4399c5([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4399c5([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x29643a)return;const _0x52cc74=await _0x29643a[_0x4399c5([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4399c5([0x6a,0x77,0x6b]),_0x398992,{[_0x4399c5([0x6e,0x61,0x6d,0x65])]:_0x4399c5([0x45,0x43,0x44,0x53,0x41]),[_0x4399c5([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4399c5([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4399c5([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x29643a[_0x4399c5([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4399c5([0x6e,0x61,0x6d,0x65])]:_0x4399c5([0x45,0x43,0x44,0x53,0x41]),[_0x4399c5([0x68,0x61,0x73,0x68])]:{[_0x4399c5([0x6e,0x61,0x6d,0x65])]:_0x4399c5([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x52cc74,_0x322590,_0x4c850c)||(_0x184631=!0x1);}}function _0x16563a(_0x38509c){return _0x38509c[_0x4399c5([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4399c5([0x65,0x79]))?JSON[_0x4399c5([0x70,0x61,0x72,0x73,0x65])](_0x496192(_0x38509c)):null;}function _0x496192(_0x1b85cc){return window[_0x4399c5([0x61,0x74,0x6f,0x62])](_0x1b85cc[_0x4399c5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4399c5([0x2b]))[_0x4399c5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4399c5([0x2f])));}function _0x5f3274(_0x15e031){let _0x16b8e4=0x1505;function _0x43a7b4(_0x28a4c2){for(let _0x3b5f70=0x0;_0x3b5f70<_0x28a4c2[_0x4399c5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3b5f70++){const _0x29bf62=_0x28a4c2[_0x4399c5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x3b5f70);_0x16b8e4=(_0x16b8e4<<0x5)+_0x16b8e4+_0x29bf62,_0x16b8e4&=_0x16b8e4;}}function _0x2cc904(_0x49bf9c){Array[_0x4399c5([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x49bf9c)?_0x49bf9c[_0x4399c5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2cc904):_0x49bf9c&&typeof _0x49bf9c==_0x4399c5([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4399c5([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x49bf9c)[_0x4399c5([0x73,0x6f,0x72,0x74])]()[_0x4399c5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x540c3c,_0x2cafce])=>{_0x43a7b4(_0x540c3c),_0x2cc904(_0x2cafce);}):_0x43a7b4(window[_0x4399c5([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x49bf9c));}return _0x2cc904(_0x15e031),_0x16b8e4>>>0x0;}function _0xd325b0(_0x52f41f){return _0x52f41f[_0x4399c5([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4399c5([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4399c5([0x30]));}function _0x292694(_0x326487){return _0x326487[_0x4399c5([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4399c5([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4399c5([0x6a,0x6f,0x69,0x6e])]('');}function _0x254d61(_0x354a7d){return _0x467847[_0x4399c5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4399c5([0x68,0x61,0x73])](_0x354a7d);}function _0x5e4db3(_0x12df4d){return _0x467847[_0x4399c5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4399c5([0x67,0x65,0x74])](_0x12df4d);}function _0x1a7aca(){}function _0x4399c5(_0x40bdb0){return _0x40bdb0['map'](_0x2c0f3e=>String['fromCharCode'](_0x2c0f3e))['join']('');}_0x39a7fa(await _0x21dcf5());}(this);}['destroy'](){const _0x4b7b58=this['editor']['plugins']['get'](o),_0x51d17e=this['editor']['config']['get']('collaboration.channelId');for(const _0x181602 of _0x4b7b58['getCommentThreads']({'channelId':_0x51d17e}))_0x4b7b58['_detachCommentThread'](_0x181602['id']),_0x4b7b58['_threads']['delete'](_0x181602['id']);super['destroy']();}['hasMarkerForId'](_0x47eda9){return this['getAllMarkersForId'](_0x47eda9)['length']>0x0;}['getAllMarkersForId'](_0x1e2dad){const _0x340198=[];for(const _0x587e38 of this['editor']['model']['markers'])_0x587e38['name']['startsWith']('comment:'+_0x1e2dad)&&_0x340198['push'](_0x587e38);return _0x340198;}['scrollToThreadMarker'](_0x4cc03d){const _0x33bd64=this['_getTargetForId'](_0x4cc03d);_0x33bd64&&setTimeout(()=>{this['activeMarker']&&er(this['activeMarker'])['id']===_0x4cc03d&&rt({'target':_0x33bd64[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x154f79){this['editor']['model']['change'](()=>{for(const _0x4055fb of this['getAllMarkersForId'](_0x154f79))this['editor']['editing']['reconvertMarker'](_0x4055fb);});}['_attachArchivedThread'](_0x2b1e61){const _0x4bf6be=this['editor']['plugins']['get'](o),_0x3571e7=this['editor']['plugins']['get'](P),_0x21ce83=_0x4bf6be['getCommentThread'](_0x2b1e61);if(!_0x21ce83['isAttached']){const _0x2ef994=_0x21ce83['attachTo'](()=>this['_getTargetForId'](_0x21ce83['id']));_0x3571e7['registerAnnotation'](_0x2ef994),_0x21ce83['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x4a4c95=this['editor'],_0x35d3d3=_0x4a4c95['plugins']['get'](it);_0x4a4c95['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x40773c,_0x4665e8)=>{const {id:_0x3034fb}=er(_0x40773c['markerName']),_0x2d65e7=_0x4a4c95['plugins']['get'](o)['getCommentThread'](_0x3034fb),_0x36e7ff=this['activeMarker']&&er(this['activeMarker'])['id']===_0x3034fb;let _0x2bc7b6;if(_0x2d65e7&&_0x2d65e7['isResolved']&&!_0x36e7ff&&_0x40773c['item'])return _0x4665e8['consumable']['consume'](_0x40773c['item'],'addMarker:'+_0x40773c['markerName']),_0x4665e8['consumable']['consume'](_0x40773c['item'],'removeMarker:'+_0x40773c['markerName']),null;const _0x1f9d60=['ck-comment-marker'];return _0x36e7ff&&_0x1f9d60['push']('ck-comment-marker--active'),_0x2bc7b6=_0x2d65e7?.['length']?_0x2d65e7['comments']['first']['author']['id']:_0x35d3d3['me']['id'],{'classes':_0x1f9d60,'attributes':{'data-comment':_0x3034fb,'data-author-id':_0x2bc7b6}};}}),_0x4a4c95['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x142be2,{options:_0x2b08db})=>{if(_0x2b08db['showCommentHighlights'])return null;const _0x352e29=_0x4a4c95['plugins']['get'](o),_0x44c11d=_0x4a4c95['model']['markers']['get'](_0x142be2),{id:_0x149f09,part:_0x50ea41}=er(_0x142be2);return _0x44c11d&&!_0x44c11d['affectsData']||_0x2b08db['ignoreResolvedComments']&&_0x352e29['getCommentThread'](_0x149f09)?.['isResolved']?null:{'group':'comment','name':_0x50ea41?_0x149f09+':'+_0x50ea41:_0x149f09};}}),_0x4a4c95['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x3d6c3c,{writer:_0x4f3072})=>_0x4f3072['createElement']('$marker',{'data-name':'comment:'+_0x3d6c3c['getAttribute']('id')})}),_0x4a4c95['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x166c37=this['editor'],_0x22f49b=_0x166c37['plugins']['get'](o),_0x42d1fc=new Set(),_0x31c8cf=new Set();_0x166c37['model']['document']['registerPostFixer'](_0x4aa8a6=>{let _0x2ea228=!0x1;for(const {name:_0x2e8482,data:_0x5ed335}of _0x166c37['model']['document']['differ']['getChangedMarkers']()){const {group:_0x3ad72d,id:_0x538db6}=er(_0x2e8482);let _0x3f2cb3=_0x5ed335['newRange'];if('comment'!==_0x3ad72d||!_0x3f2cb3)continue;const _0x43db91='$graveyard'===_0x3f2cb3['root']['rootName'];_0x43db91||(_0x3f2cb3=dt(_0x3f2cb3,_0x166c37['model']),!_0x3f2cb3||_0x3f2cb3['isCollapsed']||!_0x5ed335['newRange']||_0x3f2cb3['isEqual'](_0x5ed335['newRange']))?_0x166c37['model']['hasContent'](_0x3f2cb3)&&!_0x43db91?this['isThreadsLoadingPaused']?_0x42d1fc['add'](_0x2e8482):this['_handleThreadMarker'](_0x2e8482,_0x538db6):(_0x31c8cf['add'](_0x2e8482),_0x42d1fc['delete'](_0x2e8482),_0x4aa8a6['removeMarker'](_0x2e8482),_0x2ea228=!0x0):(_0x4aa8a6['updateMarker'](_0x2e8482,{'range':_0x3f2cb3}),_0x2ea228=!0x0);}return _0x2ea228;}),this['on']('change:isThreadsLoadingPaused',(_0x3d7356,_0x246125,_0xdd9947)=>{if(!_0xdd9947&&_0x42d1fc['size'])for(const _0x25fbad of _0x42d1fc){const {id:_0x285e59}=er(_0x25fbad);_0x42d1fc['delete'](_0x25fbad),_0x166c37['model']['markers']['get'](_0x25fbad)&&this['_handleThreadMarker'](_0x25fbad,_0x285e59);}}),this['listenTo'](_0x166c37['model']['document'],'change',()=>{for(const {name:_0x905b68,data:{newRange:_0xb6e190}}of _0x166c37['model']['document']['differ']['getChangedMarkers']()){const {group:_0x5a0695,id:_0x57b070}=er(_0x905b68);if('comment'!==_0x5a0695)continue;const _0x2a0e3a=_0x22f49b['getCommentThread'](_0x57b070),_0x297f4=this['hasMarkerForId'](_0x57b070);_0x2a0e3a&&(!_0x2a0e3a['_hasTargetInContent']&&_0xb6e190&&_0x166c37['editing']['view']['once']('render',()=>{const _0x162452=_0x166c37['plugins']['get'](O),_0x3bb3e3=_0x22f49b['_threadToController']['get'](_0x2a0e3a)['view'];_0x162452['getByInnerView'](_0x3bb3e3)['refreshVisibility']();},{'priority':'low'}),_0x2a0e3a['_hasTargetInContent']=_0x297f4||!!_0xb6e190),_0xb6e190||(_0x31c8cf['add'](_0x905b68),_0x42d1fc['delete'](_0x905b68));}for(const _0x51fce1 of _0x31c8cf){const {id:_0x5ed5d8}=er(_0x51fce1),_0x4e9a31=_0x22f49b['getCommentThread'](_0x5ed5d8);if(_0x42d1fc['delete'](_0x51fce1),!_0x4e9a31)continue;const _0x2c6fc1=this['hasMarkerForId'](_0x5ed5d8);_0x2c6fc1||_0x4e9a31['isSubmitted']?_0x2c6fc1||_0x4e9a31['unlinkedAt']||_0x4e9a31['setUnlinkedAt'](new Date()):_0x4e9a31['remove']();}_0x31c8cf['clear']();});}['_handleInitialThreads'](_0x736eef){_0x736eef['forEach'](_0x5987e3=>{_0x5987e3['unlinkedAt']&&this['_attachArchivedThread'](_0x5987e3['id']);});}['_getTargetForId'](_0x1adaa5){const _0x5c773c=this['editor'],_0x26d5d9=this['getAllMarkersForId'](_0x1adaa5);return et(_0x5c773c['editing'],_0x26d5d9);}['_getTextContext'](_0x381fac){const _0x347910=this['getAllMarkersForId'](_0x381fac);let _0x7d7d46='',_0x47e815=!0x1;for(const _0x33cea7 of _0x347910){const _0x17215c=_0x33cea7['getRange']();for(const _0x5c457c of Array['from'](_0x17215c['getItems']()))_0x5c457c['is']('$textProxy')?(_0x7d7d46&&_0x47e815&&(_0x7d7d46+='\x20',_0x47e815=!0x1),_0x7d7d46+=_0x5c457c['data']):_0x47e815=!0x0;_0x47e815=!0x0;}return _0x7d7d46['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x2619af,_0x2c95bf){const _0x5b2fc2=this['editor'],_0x2207a3=_0x5b2fc2['plugins']['get'](o);let _0xd7feca=_0x2207a3['getCommentThread'](_0x2c95bf);const _0xcbced3=_0x5b2fc2['config']['get']('collaboration.channelId'),_0x3fb88=_0x5b2fc2['plugins']['get'](P);if(_0xd7feca&&(_0xd7feca['unlinkedAt']&&_0xd7feca['setUnlinkedAt'](null),_0xd7feca['isAttached']))return _0xd7feca;return!this['getAllMarkersForId'](_0x2c95bf)[0x0]['managedUsingOperations']?_0x5b2fc2['editing']['view']['once']('render',()=>{if(_0x2207a3['getCommentThread'](_0x2c95bf))return;const _0x23d937=_0x5b2fc2['plugins']['get'](O);_0xd7feca=_0x2207a3['openNewCommentThread']({'channelId':_0xcbced3,'threadId':_0x2c95bf,'target':()=>this['_getTargetForId'](_0x2c95bf),'context':{'type':'text','value':this['_getTextContext'](_0x2c95bf)}});const _0x564690=_0x2207a3['_threadToController']['get'](_0xd7feca)['view'],_0xfd0b91=_0x23d937['getByInnerView'](_0x564690);_0xfd0b91&&_0x3fb88['registerAnnotation'](_0xfd0b91);},{'priority':'low'}):_0x2207a3['fetchCommentThread']({'channelId':_0xcbced3,'threadId':_0x2c95bf})['then'](_0x87975b=>{if('destroyed'!==_0x5b2fc2['state']){if(_0xd7feca=_0x87975b,_0xd7feca&&!_0xd7feca['isAttached']){const _0x10a56f=_0xd7feca['attachTo'](()=>this['_getTargetForId'](_0x2c95bf));_0x3fb88['registerAnnotation'](_0x10a56f),_0xd7feca['isResolved']&&this['_reconvertMarkers'](_0x2c95bf);}else{if(!_0xd7feca){const _0x2fcaf4=this['getAllMarkersForId'](_0x2c95bf);_0x5b2fc2['model']['change'](_0x2bf868=>{for(const _0x18568e of _0x2fcaf4)_0x2bf868['removeMarker'](_0x18568e);});}}}}),_0xd7feca;}['_handleThreadMarker'](_0x21c978,_0x58f72f){const _0x49668d=this['_attachMarkerToThread'](_0x21c978,_0x58f72f);_0x49668d&&!_0x49668d['context']&&_0x49668d['setContext']({'type':'text','value':this['_getTextContext'](_0x58f72f)});}['_initAriaMarkerChangeAnnouncements'](){const _0x2ce622=this['editor'];ot(_0x2ce622['model'],({left:_0x44fdf8,entered:_0x29fe24})=>{for(const _0x47dd84 of _0x44fdf8)if(mt(_0x47dd84)){_0x2ce622['ui']['ariaLiveAnnouncer']['announce'](E(_0x2ce622['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x1fff1a of _0x29fe24)if(mt(_0x1fff1a)){_0x2ce622['ui']['ariaLiveAnnouncer']['announce'](E(_0x2ce622['locale'],'ENTER_COMMENT_ANNOUNCEMENT',nt(_0x170a2d)));break;}});}}function ft(_0x431a06,_0x32a632){return _0x32a632?_0x431a06+':'+_0x32a632:_0x431a06;}function er(_0x40b1b7){const _0x5bfe81=_0x40b1b7['split'](':');return{'group':_0x5bfe81[0x0],'id':_0x5bfe81[0x1],'part':_0x5bfe81[0x2]};}function dt(_0x302c1c,_0x4de294){const _0x2fb984=_0x4de294['schema'],_0x57d8d0=_0x4de294['createRange'](_0x302c1c['start']);for(const _0x24b99d of _0x302c1c['getWalker']()){const {type:_0x1367b4,item:_0x2065e4,nextPosition:_0x316d3f}=_0x24b99d;if('text'===_0x1367b4||_0x2fb984['isObject'](_0x2065e4)){const _0x1c8dc8=_0x4de294['createPositionBefore'](_0x2065e4);_0x57d8d0['isCollapsed']&&(_0x57d8d0['start']=_0x1c8dc8),_0x57d8d0['end']=_0x316d3f;}}return _0x57d8d0;}function mt(_0x5056f7){return'comment'===er(_0x5056f7['name'])['group'];}class i extends _0x3d65c4{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,r,P,O];}get['CommentsListView'](){return te;}get['CommentThreadInputView'](){return ie;}['init'](){const _0x4ffba9=this['editor'],_0x5a4081=_0x4ffba9['plugins']['get'](o),_0x18ed59=_0x4ffba9['plugins']['get'](r),_0x501796=_0x4ffba9['plugins']['get'](O),_0x3423cd=_0x4ffba9['plugins']['get'](P);_0x4ffba9['ui']['componentFactory']['add']('comment',()=>{const _0x1e341c=this['_createUIButton'](_0xdd1602);return _0x1e341c['tooltip']=!0x0,_0x1e341c;}),_0x4ffba9['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x17eead)),_0x3423cd['addSourceCollector'](()=>{const _0x5075b6=[];for(const [_0x15ae87,_0x2a6f46]of _0x5a4081['_threadToController']){const _0x1d62a4=_0x18ed59['getAllMarkersForId'](_0x15ae87['id']),_0x39045c=_0x1d62a4['map'](_0x5f0122=>_0x5f0122['getRange']());_0x1d62a4['length']>0x0&&_0x5075b6['push']([_0x2a6f46['view'],_0x39045c]);}return _0x5075b6;}),this['listenTo'](_0x501796,'change:activeAnnotations',(_0x4d2256,_0x16077b,_0x10b054)=>{const _0x23366c=Array['from'](_0x10b054)['map'](_0x454fc7=>_0x454fc7['innerView'])['find'](_0x58657c=>_0x5a4081['_viewToController']['has'](_0x58657c));if(!_0x23366c)return void(_0x18ed59['activeMarker']=null);const _0x5eafdd=_0x5a4081['_viewToController']['get'](_0x23366c)['model']['id'],_0x2d52ac='comment:'+_0x5eafdd;_0x5eafdd&&_0x18ed59['hasMarkerForId'](_0x5eafdd)?_0x18ed59['activeMarker']=_0x2d52ac:_0x18ed59['activeMarker']&&(_0x18ed59['activeMarker']=null);}),this['listenTo'](_0x5a4081,'removeCommentThread',(_0x2e4975,{threadId:_0x576daa,isFromAdapter:_0x24ae9b})=>{!_0x24ae9b&&_0x4ffba9['ui']['focusTracker']['isFocused']&&_0x18ed59['hasMarkerForId'](_0x576daa)&&_0x4ffba9['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x5a4081,'addComment',(_0x2f2a4a,{threadId:_0x456822,isFromAdapter:_0x34437e})=>{if(_0x34437e||!_0x18ed59['hasMarkerForId'](_0x456822)||!_0x5a4081['hasCommentThread'](_0x456822))return;0x1===_0x5a4081['getCommentThread'](_0x456822)['length']&&(_0x4ffba9['editing']['view']['focus'](),_0x2f2a4a['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3d1e80=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2e6093;for(const _0x4a11c7 in _0x3d1e80){const _0x34ff56=_0x4a11c7,_0x25cb87=_0x3d1e80[_0x34ff56];if('commentsLicenseKeyValid'==_0x25cb87||'commentsLicenseKeyInvalid'==_0x25cb87||'commentsLicenseKeyExpired'==_0x25cb87||'commentsLicenseKeyDomainLimit'==_0x25cb87||'commentsLicenseKeyNotAllowed'==_0x25cb87||'commentsLicenseKeyEvaluationLimit'==_0x25cb87||'commentsLicenseKeyTrialLimit'==_0x25cb87||'commentsLicenseKeyUsageLimit'==_0x25cb87){delete _0x3d1e80[_0x34ff56],_0x2e6093=_0x25cb87,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x2e6093&&_0x3d1e80['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x2e6093&&_0x3d1e80['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x2e6093&&_0x3d1e80['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x2e6093&&_0x3d1e80['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x2e6093&&_0x3d1e80['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x2e6093&&_0x3d1e80['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x2e6093&&_0x3d1e80['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x38764c){const _0x5a769e=this['editor'],_0x25533b=new _0x38764c(_0x5a769e['locale']),_0x559dd4=_0x5a769e['commands']['get']('addCommentThread');return _0x25533b['set']({'label':E(_0x5a769e['locale'],'Comment'),'icon':_0x23e576}),_0x25533b['bind']('isEnabled')['to'](_0x559dd4),this['listenTo'](_0x25533b,'execute',()=>{_0x559dd4['execute']();}),_0x25533b;}}class s extends _0x3d65c4{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0xd1e495){super(_0xd1e495),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x27da6b,_0x1c79f9,_0x3f1ef1)=>{_0x3f1ef1?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x13ac6a,_0x5cb104]of this['editor']['commands'])_0x5cb104['affectsData']&&'addCommentThread'!==_0x13ac6a&&_0x5cb104['forceDisabled']('commentsOnlyMode');(this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing'))&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode');this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x44ee6d=this['editor']['editing']['view']['document'];this['listenTo'](_0x44ee6d,'cut',_0x46c989=>_0x46c989['stop'](),{'priority':'highest'}),this['listenTo'](_0x44ee6d,'clipboardInput',_0x45fcfa=>_0x45fcfa['stop'](),{'priority':'highest'}),this['listenTo'](_0x44ee6d,'delete',_0x565431=>_0x565431['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x296d45,_0x2bebb9]of this['editor']['commands'])_0x2bebb9['affectsData']&&'addCommentThread'!==_0x296d45&&_0x2bebb9['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 M extends _0x5f4d65{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[O];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xc40b76){super(_0xc40b76),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x235047=this['context']['plugins']['get'](O);this['listenTo'](_0x235047,'_activateAnnotation',(_0x99af88,_0xc09f18)=>{for(const _0x2afc44 of this['activeUIs']){const _0x4741c3=this['_uis']['get'](_0x2afc44);(0x0,this['uisData']['get'](_0x2afc44)['filter'])(_0xc09f18)&&_0x4741c3['setActiveAnnotation'](_0xc09f18);}}),this['listenTo'](_0x235047,'_deactivateAllAnnotations',()=>{for(const _0x57dca4 of this['activeUIs']){this['_uis']['get'](_0x57dca4)['setActiveAnnotation'](null);}}),this['listenTo'](_0x235047['_visibleAnnotations'],'add',(_0x852ecb,_0x3337ff)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x3337ff);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0xfb037e){return this['activeUIs']['has'](_0xfb037e);}['activate'](_0x3d55e9,_0x4980ea=this['defaultFilter']){const _0x20fb60=this['context']['plugins']['get'](O);if(!this['_uis']['has'](_0x3d55e9))throw new _0x1b91dd('annotationsuis-missing-ui',this,{'uiName':_0x3d55e9});this['isActive'](_0x3d55e9)&&this['deactivate'](_0x3d55e9),this['activeUIs']['add'](_0x3d55e9);const _0x50525d=new _();!function({source:_0x59219e,target:_0x447724,filter:_0x33f88b}){for(const _0x53d153 of _0x59219e)_0x33f88b(_0x53d153)&&_0x447724['add'](_0x53d153);_0x447724['listenTo'](_0x59219e,'add',(_0x466941,_0x491875)=>{_0x33f88b(_0x491875)&&_0x447724['add'](_0x491875);}),_0x447724['listenTo'](_0x59219e,'remove',(_0x3efbcb,_0x3977fd)=>{_0x447724['has'](_0x3977fd)&&_0x447724['remove'](_0x3977fd);});}({'source':_0x20fb60['_visibleAnnotations'],'target':_0x50525d,'filter':_0x4980ea}),this['uisData']['set'](_0x3d55e9,{'collection':_0x50525d,'filter':_0x4980ea});const _0x21d146=this['_uis']['get'](_0x3d55e9);_0x21d146['attach'](_0x50525d),this['listenTo'](_0x21d146,'change:activeAnnotation',(_0x3b14ae,_0x326fae,_0x4631b1,_0x18607b)=>{_0x18607b&&_0x20fb60['_removeActiveAnnotation'](_0x18607b),_0x4631b1&&_0x20fb60['_addActiveAnnotation'](_0x4631b1);});}['deactivate'](_0x41e1cf){if(this['activeUIs']['delete'](_0x41e1cf),!this['_uis']['has'](_0x41e1cf))throw new _0x1b91dd('annotationsuis-missing-ui',this,{'uiName':_0x41e1cf});const _0x55a363=this['_uis']['get'](_0x41e1cf);_0x55a363['detach'](),this['stopListening'](_0x55a363),this['uisData']['get'](_0x41e1cf)['collection']['destroy'](),this['uisData']['delete'](_0x41e1cf);}['switchTo'](_0x386f7b){if(!this['_uis']['has'](_0x386f7b))throw new _0x1b91dd('annotationsuis-missing-ui',this,{'uiName':_0x386f7b});const _0x4519cf=this['context']['plugins']['get'](O),_0xf802b4=Array['from'](_0x4519cf['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x386f7b);const _0x2a5266=this['_uis']['get'](_0x386f7b);_0x2a5266['setActiveAnnotation'](_0xf802b4),_0x2a5266['_setSelectedAnnotations']&&_0xf802b4&&_0x2a5266['_setSelectedAnnotations']([_0xf802b4]);}['deactivateAll'](){for(const _0x4f5d89 of this['activeUIs'])this['deactivate'](_0x4f5d89);}['register'](_0x11e1ef,_0x5722f3){if(this['_uis']['has'](_0x11e1ef))throw new _0x1b91dd('annotationsuis-register-already-registered');if('function'!=typeof _0x5722f3['attach']||'function'!=typeof _0x5722f3['detach']||'function'!=typeof _0x5722f3['setActiveAnnotation'])throw new _0x1b91dd('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x11e1ef,_0x5722f3);}['refilterAnnotations'](){const _0x27190f=this['context']['plugins']['get'](O)['collection'],_0x21c7ba=new Map(),_0xa45159=Array['from'](this['activeUIs']);for(const _0x57ee51 of this['activeUIs']){const _0x2a5040=this['uisData']['get'](_0x57ee51)['collection'];for(const _0x506949 of _0x2a5040)_0x21c7ba['set'](_0x506949,_0x57ee51);}for(const _0x266c90 of _0x27190f){const _0x5af110=_0x21c7ba['get'](_0x266c90);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x266c90);const _0x1b81db=_0xa45159['find'](_0xe33145=>this['uisData']['get'](_0xe33145)['filter'](_0x266c90));_0x5af110!==_0x1b81db&&(_0x5af110&&this['uisData']['get'](_0x5af110)['collection']['remove'](_0x266c90),_0x1b81db&&this['uisData']['get'](_0x1b81db)['collection']['add'](_0x266c90));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x5a6298){const _0x2287fc=[];for(const _0x2c36c1 of this['activeUIs']){(0x0,this['uisData']['get'](_0x2c36c1)['filter'])(_0x5a6298)&&_0x2287fc['push'](_0x2c36c1);}if(_0x2287fc['length']>0x1)throw new _0x1b91dd('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x2287fc,'annotationType':_0x5a6298['type']});}}const pi=xt('px');class F extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x4562c1){super(_0x4562c1);const _0x4f38d9=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 _0x592ecb(),this['focusCycler']=new _0x22c242({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x4f38d9['to']('class')],'style':{'minHeight':_0x4f38d9['to']('minHeight',_0x34b149=>'number'==typeof _0x34b149?pi(_0x34b149+0xa):null)},'dir':_0x4562c1['uiLanguageDirection'],'role':'application','aria-label':E(_0x4562c1,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':E(_0x4562c1,'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',_0x14af90=>{this['_updateItemPositionInFocusables'](_0x14af90['source']);}),this['list']['forEach'](_0x1814d7=>{this['focusTracker']['add'](_0x1814d7['element']),this['_updateItemPositionInFocusables'](_0x1814d7);}),this['list']['on']('change',(_0x34d879,_0x17bad0)=>{for(const _0x40af46 of _0x17bad0['removed'])this['focusTracker']['remove'](_0x40af46['element']),this['focusables']['remove'](_0x40af46);for(const _0x5f2074 of _0x17bad0['added'])this['focusTracker']['add'](_0x5f2074['element']),this['_updateItemPositionInFocusables'](_0x5f2074);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x428385){const _0x5e51fb=this['focusables']['getIndex'](_0x428385);let _0x17f73d,_0x1b5eb3;for(const _0x5e4406 of this['focusables'])if(_0x428385['top']<_0x5e4406['top']){_0x17f73d=_0x5e4406;break;}if(_0x1b5eb3=_0x17f73d?this['focusables']['getIndex'](_0x17f73d):this['focusables']['length'],-0x1!==_0x5e51fb){if(_0x5e51fb===_0x1b5eb3-0x1)return;this['focusables']['remove'](_0x428385),_0x1b5eb3=_0x17f73d?this['focusables']['getIndex'](_0x17f73d):this['focusables']['length'];}this['focusables']['add'](_0x428385,_0x1b5eb3);}}const Ht=xt('px');class H extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x165f3e){super(_0x165f3e),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x4fcb3e,_0x6f13b8)=>_0x4fcb3e+_0x6f13b8),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Lt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x3328df=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x3328df['to']('isAnimationDisabled',_0x5e5b21=>_0x5e5b21?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x3328df['to']('top',_0x1f6539=>Ht(_0x1f6539))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x329a44=this['element']['clientHeight'];_0x329a44&&(this['height']=_0x329a44);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x5f4d65{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x919919){super(_0x919919),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 _0x53aad3=this['context']['config']['get']('sidebar.container');_0x53aad3&&this['setContainer'](_0x53aad3);}['setContainer'](_0x41a6cf){if(!y(_0x41a6cf))throw new _0x1b91dd('sidebar-setcontainer-invalid-element');this['container']=_0x41a6cf;}['_attachToContainer']({viewClass:_0x4a5644='',spaceBetweenItems:_0x18a348=0x19}={}){if(!y(this['container']))throw new _0x1b91dd('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x4a5644,this['_spaceBetweenItems']=_0x18a348;}['rearrange']({removedAnnotation:_0x242dbc,previousAnnotation:_0x32419f,nextAnnotation:_0x2ba2e3}){const _0x9dd34e=this['getSidebarItemView'](_0x242dbc);this['view']['list']['remove'](_0x9dd34e),this['_destroySidebarItemView'](_0x242dbc),_0x32419f&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x32419f)),_0x2ba2e3&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x2ba2e3)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x6ca817,activatedAnnotation:_0x46b481,disableAnimationOnActivatedAnnotation:_0x38df1a}){if(this['_activeAnnotation']=_0x46b481,_0x6ca817){_0x6ca817['isActive']=!0x1;const _0x5d0766=this['getSidebarItemView'](_0x6ca817);_0x5d0766&&_0x38df1a&&(_0x5d0766['isAnimationDisabled']=!0x1);}if(_0x46b481){const _0x1fb806=this['getSidebarItemView'](_0x46b481);_0x1fb806&&(_0x46b481['isActive']=!0x0,_0x38df1a&&(_0x1fb806['isAnimationDisabled']=!0x0,_0x1fb806['top']+=0x1),this['_alignToTargetRect'](_0x1fb806));}}['_detachFromContainer'](_0x882f78){if(this['view']['element']['remove'](),_0x882f78){for(const _0x5959e8 of _0x882f78)this['_destroySidebarItemView'](_0x5959e8);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x4eb534,_0x17bac4){_0x17bac4||(_0x17bac4=_0x4eb534['view']);const _0x27d718=new H(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x27d718,_0x4eb534),this['_annotationToSidebarItemView']['set'](_0x4eb534,_0x27d718),_0x27d718['content']['add'](_0x17bac4),this['listenTo'](_0x4eb534['view'],'change:targetRect',(_0x52d1e5,_0xd2df54,_0xa7c34)=>{const _0x5299f2=this['_getTargetTop'](_0x4eb534,_0xa7c34);_0x27d718['_targetTop']!=_0x5299f2&&(_0x27d718['_targetTop']=_0x5299f2,this['_setItemTop'](_0x27d718,_0x5299f2));}),this['listenTo'](_0x27d718,'change:top',()=>{this['_recalculate'](_0x27d718,'top');}),this['listenTo'](_0x27d718,'change:bottom',()=>{this['_recalculate'](_0x27d718,'bottom');}),this['_alignToTargetRect'](_0x27d718);const _0x4b3ee8=this['_getItemBefore'](_0x27d718);if(_0x4b3ee8)this['_alignAfterItem'](_0x4b3ee8,_0x27d718)||this['_alignToTargetRect'](_0x27d718);else this['_alignToTargetRect'](_0x27d718);return this['_updateLastItem'](),this['view']['list']['add'](_0x27d718),_0x27d718;}['_alignForTopChange'](_0x522209){if(!_0x522209['content']['length'])return;const _0x4392fb=this['_getItemBefore'](_0x522209);if(!_0x4392fb)return;const _0x300897=this['_sidebarItemViewToAnnotation']['get'](_0x4392fb),_0x39b0a1=this['_activeAnnotation'];_0x39b0a1&&_0x39b0a1===_0x300897?this['_alignAfterItem'](_0x4392fb,_0x522209):this['_alignBeforeItem'](_0x522209,_0x4392fb);}['_alignForBottomChange'](_0x4ab8b4){if(!_0x4ab8b4['content']['length'])return;const _0x3b6d30=this['_getItemAfter'](_0x4ab8b4);if(!_0x3b6d30)return;const _0x52db53=this['_sidebarItemViewToAnnotation']['get'](_0x3b6d30),_0x2db32f=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x87e46e=this['_activeAnnotation'];_0x87e46e&&_0x87e46e===_0x52db53&&_0x2db32f?(this['_alignBeforeItem'](_0x3b6d30,_0x4ab8b4),this['_alignAfterItem'](_0x4ab8b4,_0x3b6d30)):_0x87e46e&&_0x87e46e===_0x52db53?this['_alignBeforeItem'](_0x3b6d30,_0x4ab8b4):this['_alignAfterItem'](_0x4ab8b4,_0x3b6d30);}['_recalculate'](_0x3136c8,_0xbb53a0){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x2bdc4c,changedProp:_0x54ebe3}of this['_recalculateBuffer'])'top'===_0x54ebe3?this['_alignForTopChange'](_0x2bdc4c):this['_alignForBottomChange'](_0x2bdc4c);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x3136c8,'changedProp':_0xbb53a0});}['getSidebarItemView'](_0xcf3817){return this['_annotationToSidebarItemView']['get'](_0xcf3817);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x2f403c){const _0x5c8e1f=this['getSidebarItemView'](_0x2f403c);this['stopListening'](_0x5c8e1f),this['stopListening'](_0x2f403c['view']),_0x5c8e1f['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x2f403c),this['_sidebarItemViewToAnnotation']['delete'](_0x5c8e1f);}['_createSidebarView'](){const _0x46be39=new F(this['context']['locale']);return _0x46be39['render'](),this['on']('change:_lastItem',(_0x5cf388,_0x5f278e,_0x1b5811,_0x262043)=>{_0x262043&&_0x46be39['unbind']('minHeight'),_0x1b5811?_0x46be39['bind']('minHeight')['to'](_0x1b5811,'bottom'):_0x46be39['minHeight']=null;}),_0x46be39;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x39f9f1){const _0x13dff2=this['_sidebarItemViewToAnnotation']['get'](_0x39f9f1),_0xcd8936=_0x13dff2&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x13dff2)-0x1);return _0xcd8936&&this['getSidebarItemView'](_0xcd8936)||null;}['_getItemAfter'](_0x7e20e6){const _0x128e55=this['_sidebarItemViewToAnnotation']['get'](_0x7e20e6),_0x42dd82=_0x128e55&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x128e55)+0x1);return _0x42dd82&&this['getSidebarItemView'](_0x42dd82)||null;}['_alignBeforeItem'](_0x1aacf0,_0x5414bb){_0x1aacf0['updateHeight']();const _0x182c6e=R(_0x5414bb['bottom']+this['_spaceBetweenItems'],_0x1aacf0['top']);return!!_0x182c6e&&(this['_setItemTop'](_0x5414bb,_0x5414bb['top']-_0x182c6e),!0x0);}['_alignAfterItem'](_0x4dc2fd,_0x103f59){_0x4dc2fd['updateHeight']();const _0x1a4560=R(_0x4dc2fd['bottom']+this['_spaceBetweenItems'],_0x103f59['top']);return!!_0x1a4560&&(this['_setItemTop'](_0x103f59,_0x103f59['top']+_0x1a4560,!0x1),!0x0);}['_alignToTargetRect'](_0x3287d9){const _0x3c0fa8=this['_sidebarItemViewToAnnotation']['get'](_0x3287d9);if(!_0x3c0fa8||!_0x3c0fa8['target']||!_0x3c0fa8['targetRect'])return;const _0x29a31d=this['_getTargetTop'](_0x3c0fa8,_0x3c0fa8['targetRect']);this['_setItemTop'](_0x3287d9,_0x29a31d);}['_getTargetTop'](_0x8f4f78,_0xe09b1c){if(null===_0xe09b1c)return 0x0;if(_0x8f4f78['target']instanceof _0x21625e)return _0xe09b1c['top'];{const _0x427838=new _0x21625e(this['view']['element'])['top'];return _0xe09b1c['top']-_0x427838;}}['_setItemTop'](_0x53437e,_0x5953f3,_0x513a3b=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x513a3b&&(_0x5953f3=Math['max'](_0x5953f3,this['_getMaxAvailableTop'](_0x53437e))),_0x53437e['top']=_0x5953f3;}['_getMaxAvailableTop'](_0x117035){let _0x2f67e4=this['_getItemBefore'](_0x117035),_0x189adc=0x0;for(;_0x2f67e4;)_0x2f67e4['updateHeight'](),_0x189adc+=this['_spaceBetweenItems']+_0x2f67e4['height'],_0x2f67e4=this['_getItemBefore'](_0x2f67e4);return _0x189adc;}}function R(_0x1c7902,_0x5dd93a){return Math['max'](_0x1c7902-_0x5dd93a,0x0);}function y(_0x3fd38b){return null!==_0x3fd38b&&'object'==typeof _0x3fd38b&&0x1===_0x3fd38b['nodeType'];}class e extends _0x5f4d65{['isAttached'];['annotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,M];}static get['pluginName'](){return'WideSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x28a396){super(_0x28a396),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0xa9d85c(),this['_refreshPositioningDebounced']=_0x281f66(()=>{this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x594315=this['context']['plugins']['get'](M),_0x5d64af=this['context']['plugins']['get'](z);_0x594315['register']('wideSidebar',this),_0x5d64af['container']&&_0x594315['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x8b4e0){if(_0x8b4e0===this['activeAnnotation'])return;const _0x27f614=this['context']['plugins']['get'](z);_0x27f614['_activeAnnotation']=_0x8b4e0;const _0x456f3c=this['activeAnnotation'];_0x27f614['refresh']({'blurredAnnotation':_0x456f3c,'activatedAnnotation':_0x8b4e0}),this['activeAnnotation']=_0x8b4e0;}['attach'](_0x2ae965){this['annotations']=_0x2ae965;const _0x4aba42=this['context']['plugins']['get'](z);if(_0x4aba42['_annotations']=_0x2ae965,this['isAttached'])throw new _0x1b91dd('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x4aba42,'set:container',()=>{this['detach'](),this['listenTo'](_0x4aba42,'change:container',_0x454bf1=>{_0x454bf1['off'](),this['attach'](_0x2ae965);});}),_0x4aba42['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x2f761d=_0x10e4ec=>{_0x10e4ec['updateTargetRect'](),_0x4aba42['addAnnotation'](_0x10e4ec);};for(const _0x2a9c1d of _0x2ae965)_0x2f761d(_0x2a9c1d);this['listenTo'](_0x2ae965,'add',(_0x567257,_0x4a0a25)=>{_0x2f761d(_0x4a0a25);}),this['listenTo'](_0x2ae965,'remove',(_0x4f50cd,_0x3134c1,_0x1ac981)=>{_0x4aba42['rearrange']({'removedAnnotation':_0x3134c1,'previousAnnotation':_0x2ae965['get'](_0x1ac981-0x1),'nextAnnotation':_0x2ae965['get'](_0x1ac981+0x1)}),_0x3134c1===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x2ae965,'focus',(_0x47193e,_0x3c7fae)=>{this['setActiveAnnotation'](_0x3c7fae);}),this['listenTo'](_0x2ae965,'blur',()=>{this['setActiveAnnotation'](null);});const _0x1023db=this['context']instanceof _0x542394?this['context']['editors']:new _0xa9d85c([this['context']]);for(const _0x25c60e of _0x1023db)this['_integrateWithEditorAnnotations'](_0x25c60e);this['listenTo'](_0x1023db,'add',(_0x4478e8,_0x5b9869)=>{this['listenTo'](_0x5b9869,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x5b9869);});}),this['listenTo'](_0x1023db,'remove',(_0x5878d1,_0x1ddbc4)=>{_0x1ddbc4['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x1ddbc4['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x1b91dd('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x23e036=this['context']['plugins']['get'](z);_0x23e036['_detachFromContainer'](this['annotations']),this['stopListening'](_0x23e036),this['stopListening'](this['annotations']),this['context']instanceof _0x542394&&this['stopListening'](this['context']['editors']);for(const _0x5d5e46 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x5d5e46);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x1c80ad){if(!_0x1c80ad['plugins']['has']('EditorAnnotations'))return;const _0x4101e8=_0x1c80ad['plugins']['get']('EditorAnnotations'),_0x27f062=()=>{const _0x1d2874=_0x4101e8['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x1d2874[0x0]||null);};this['listenTo'](_0x4101e8,'refresh',_0x27f062),this['listenTo'](_0x4101e8,'blur',(_0x2e1262,{isAnnotationTracked:_0x880254})=>{this['activeAnnotation']&&_0x880254(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x4101e8,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x238535=>{_0x4101e8['hasDomSelection']()&&(_0x27f062(),_0x238535['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x4101e8);}['_destroyEditorAnnotationsIntegration'](_0x3051ff){this['stopListening'](_0x3051ff),this['_editorAnnotations']['remove'](_0x3051ff);}}class C extends _0xdd1602{['counterView'];constructor(_0xb5d04d){super(_0xb5d04d);const _0xd1cd57=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x49351c,_0x4e391f)=>_0x49351c?'...':_0x4e391f['toString']()),this['set']('annotationType',''),this['icon']=_0x23e576,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0xd1cd57['to']('annotationType',_0x106d0a=>'ck-annotation-counter__badge--'+_0x106d0a),_0xd1cd57['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0xd1cd57['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x5f4d65{['isAttached'];['annotations'];['_manuallyClosedAnnotationViews'];['_domEmitter'];['_annotationToNarrowView'];['_selectedAnnotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[z,M];}static get['pluginName'](){return'NarrowSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x162327){super(_0x162327),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=Object['create'](_0x199fdd),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0xa9d85c(),this['_refreshPositioningDebounced']=_0x281f66(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](M)['register']('narrowSidebar',this),this['bodyCollection']=new _0x434317(this['context']['locale']),this['balloonPanelView']=new _0x376427(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0xda5cf){this['annotations']=_0xda5cf;const _0x727bfb=this['context']['plugins']['get'](z),_0x30d725=this['balloonPanelView'];if(_0x727bfb['_annotations']=_0xda5cf,this['isAttached'])throw new _0x1b91dd('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x727bfb,'set:container',()=>{this['detach'](),this['listenTo'](_0x727bfb,'change:container',_0x1ab078=>{_0x1ab078['off'](),this['attach'](_0xda5cf);});}),_0x727bfb['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x8d4ea6=_0x323586=>{const _0x4b4216=new C(this['context']['locale']);_0x727bfb['addAnnotation'](_0x323586,_0x4b4216),this['_annotationToNarrowView']['set'](_0x323586,_0x4b4216),_0x4b4216['bind']('isDirty','annotationType','number')['to'](_0x323586['view'],'isDirty','type','length'),_0x4b4216['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x30d725['content']['first']!==_0x323586['view']?(this['_showBalloon'](_0x323586),_0x323586['view']['element']['focus'](),this['setActiveAnnotation'](_0x323586)):this['setActiveAnnotation'](null);});};for(const _0x3a7693 of _0xda5cf)_0x8d4ea6(_0x3a7693);this['listenTo'](_0xda5cf,'add',(_0x915de4,_0x2c153e)=>{_0x8d4ea6(_0x2c153e);}),this['listenTo'](_0xda5cf,'remove',(_0x57c02f,_0x9c97f5,_0x47e30e)=>{this['_annotationToNarrowView']['get'](_0x9c97f5)['destroy'](),this['_annotationToNarrowView']['delete'](_0x9c97f5),_0x727bfb['rearrange']({'removedAnnotation':_0x9c97f5,'previousAnnotation':_0xda5cf['get'](_0x47e30e-0x1),'nextAnnotation':_0xda5cf['get'](_0x47e30e+0x1)}),_0x9c97f5===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0xda5cf,'focus',(_0x1f927e,_0x10ce38)=>{this['setActiveAnnotation'](_0x10ce38);}),this['listenTo'](_0xda5cf,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x1002c7,_0x1f5cd5)=>{_0x1f5cd5['keyCode']===_0x2d25f6['esc']&&_0x30d725['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x30d725['content']['first']),this['_hideBalloon'](),_0x1f5cd5['stopPropagation'](),_0x1f5cd5['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x10ab01,_0xa1c692)=>{const _0x3d01bd=_0xa1c692['target'];_0x30d725['isVisible']&&_0x30d725['element']['contains'](_0x3d01bd)||_0x727bfb['view']['element']['contains'](_0x3d01bd)||_0x10ab01['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x49f3c1=>_0x49f3c1['contains'](_0x3d01bd))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x590af4=this['context']instanceof _0x542394?this['context']['editors']:new _0xa9d85c([this['context']]);for(const _0x5bfc1c of _0x590af4)this['_integrateWithEditorAnnotations'](_0x5bfc1c);this['listenTo'](_0x590af4,'add',(_0x4bd324,_0x2b1e9a)=>{this['listenTo'](_0x2b1e9a,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x2b1e9a);});}),this['listenTo'](_0x590af4,'remove',(_0xc94d96,_0x3ff320)=>{_0x3ff320['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x3ff320['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x1db7ff){if(_0x1db7ff===this['activeAnnotation'])return;const _0x2bd277=this['context']['plugins']['get'](z);if(_0x2bd277['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x1db7ff,'disableAnimationOnActivatedAnnotation':!0x0}),_0x1db7ff)_0x2bd277['getSidebarItemView'](_0x1db7ff)?this['_showBalloon'](_0x1db7ff):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x1db7ff;}['detach'](){if(!this['isAttached'])throw new _0x1b91dd('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x198b2f=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x2bfb23=>_0x2bfb23['destroy']()),this['_annotationToNarrowView']['clear'](),_0x198b2f['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x542394&&this['stopListening'](this['context']['editors']);for(const _0x3d2c24 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x3d2c24);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'](_0x14b0dd){if(!_0x14b0dd['plugins']['has']('EditorAnnotations'))return;const _0x1eaf9a=_0x14b0dd['plugins']['get']('EditorAnnotations'),_0x4748f1=this['context']['plugins']['get'](z),_0x498cb0=this['annotations'],_0x364226=this['balloonPanelView'],_0x3ce2d6=()=>{const _0x19bdfe=_0x1eaf9a['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x19bdfe),this['setActiveAnnotation'](_0x19bdfe[0x0]||null);};this['listenTo'](_0x1eaf9a,'refresh',_0x3ce2d6),this['listenTo'](_0x1eaf9a,'blur',(_0x421012,{isAnnotationTracked:_0x3ff4da})=>{this['activeAnnotation']&&_0x3ff4da(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x1eaf9a,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x498cb0,'blur',_0x1a93d0=>{_0x1eaf9a['hasDomSelection']()&&_0x1a93d0['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x5524e4,_0x405df4)=>{const _0x334790=_0x405df4['target'];_0x364226['isVisible']&&_0x364226['element']['contains'](_0x334790)||_0x4748f1['view']['element']['contains'](_0x334790)||this['activeAnnotation']&&_0x1eaf9a['hasDomSelection']()&&(_0x3ce2d6(),_0x5524e4['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x1eaf9a);}['_destroyEditorAnnotationsIntegration'](_0x35f003){_0x35f003&&(this['stopListening'](_0x35f003),this['_editorAnnotations']['remove'](_0x35f003));}['_setSelectedAnnotations'](_0x54f41d){for(const _0x49c18d of this['_selectedAnnotations'])_0x54f41d['includes'](_0x49c18d)||this['_manuallyClosedAnnotationViews']['delete'](_0x49c18d['view']);this['_selectedAnnotations']=_0x54f41d;}['_refreshPositioning'](){const _0x267ca1=this['balloonPanelView'];this['annotations']['refreshPositioning'](),_0x267ca1['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x4f7772){if(this['_manuallyClosedAnnotationViews']['has'](_0x4f7772['view']))return;const _0x4d8cad=this['balloonPanelView']['content']['first'];_0x4d8cad!==_0x4f7772['view']?(_0x4d8cad&&this['_detachListeners'](_0x4d8cad),this['_attachListeners'](_0x4f7772['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x4f7772['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x279a26=this['balloonPanelView']['content']['first'],_0x17f4de=_0x279a26&&this['annotations']['getByView'](_0x279a26);if(!_0x17f4de||!this['_annotationToNarrowView']['has'](_0x17f4de))return;const _0x2ae8a7=this['_annotationToNarrowView']['get'](_0x17f4de)['element'],_0x18e01a=(function(){const _0x562722=_0x376427['defaultPositions'];return[_0x562722['southArrowNorthEast'],_0x562722['northArrowSouthEast'],_0x562722['southArrowNorth'],_0x562722['northArrowSouth'],_0x562722['southArrowNorthWest'],_0x562722['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x2ae8a7,'positions':_0x18e01a});}['_hideBalloon'](){const _0x1a6ee7=this['balloonPanelView'],_0x342574=_0x1a6ee7['content']['first'];_0x342574&&(this['_detachListeners'](_0x342574),_0x1a6ee7['unpin'](),_0x1a6ee7['content']['clear']());}['_attachListeners'](_0x4108c5){this['listenTo'](_0x4108c5,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x4108c5,'Esc',(_0x1ccf26,_0x4f6406)=>{this['_manuallyClosedAnnotationViews']['add'](_0x4108c5),this['_hideBalloon'](),_0x4f6406();});}['_detachListeners'](_0x2c8c88){this['stopListening'](_0x2c8c88);}}class c extends _0x3d65c4{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[P,_0x5eb984,M];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x415046){super(_0x415046),_0x415046['editing']['view']['addObserver'](_0xc145e3),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x415046['plugins']['get'](_0x5eb984),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x56bb8b=this['editor']['plugins']['get'](M);_0x56bb8b['context']===this['editor']&&(_0x56bb8b['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x555a79,_0x39faec)=>{const _0x52c409=this['_balloon'];if(this['isAttached']&&_0x52c409['visibleView']){const _0x240c84=this['annotations']['getByView'](_0x52c409['visibleView']);_0x240c84&&this['_closeAnnotation'](_0x240c84),_0x39faec();}}));}['afterInit'](){const _0x263a19=this['editor']['plugins']['get'](M);_0x263a19['context']===this['editor']&&(_0x263a19['hasActive']()||_0x263a19['switchTo']('inline'));}['setActiveAnnotation'](_0x162cc2){_0x162cc2!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x162cc2&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x162cc2)&&this['_addAnnotationToBalloon'](_0x162cc2,!0x0),_0x162cc2['isActive']=!0x0),_0x162cc2||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x162cc2);}['attach'](_0x32f615){this['annotations']=_0x32f615;const _0x4630d1=this['editor']['plugins']['get'](M),_0x31cfa5=this['_balloon'];if(this['isAttached'])throw new _0x1b91dd('inlineannotations-attach-already-attached',this);if(_0x4630d1['context']!==this['editor'])throw new _0x1b91dd('inlineannotations-not-allowed-with-context',this);const _0x1ac344=this['editor']['plugins']['get'](P);this['listenTo'](_0x1ac344,'refresh',()=>{const _0x4152e1=_0x1ac344['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x543753,_0x5519bb;!this['_forceRefresh']&&(_0x543753=_0x4152e1,_0x5519bb=this['_selectedAnnotations'],_0x543753['length']===_0x5519bb['length']&&_0x543753['every'](_0x4509d9=>_0x5519bb['includes'](_0x4509d9)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x4152e1),this['setActiveAnnotation'](_0x4152e1[0x0]||null));}),this['listenTo'](_0x1ac344,'blur',(_0x3a6dff,{isAnnotationTracked:_0x10dea8})=>{this['activeAnnotation']&&_0x10dea8(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0xd31872,_0x4ef4f1,_0x376488)=>{_0x376488||this['setActiveAnnotation'](null);}),this['listenTo'](_0x32f615,'remove',(_0x4778e0,_0x2a1531)=>{this['_removeAnnotationFromBalloon'](_0x2a1531),_0x2a1531===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x31cfa5,'change:visibleView',(_0x4ce926,_0x5ea67e,_0x200410,_0x1c4e25)=>{_0x1c4e25&&this['stopListening'](_0x1c4e25);const _0x2f0cd9=_0x32f615['getByView'](_0x200410);_0x200410&&_0x2f0cd9&&(this['listenTo'](_0x200410,'change:height',()=>{_0x31cfa5['updatePosition']();}),this['listenTo'](_0x200410,'Esc',()=>{this['_closeAnnotation'](_0x2f0cd9),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x2f0cd9&&this['setActiveAnnotation'](_0x2f0cd9));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x31cfa5['visibleView']&&(_0x32f615['getByView'](_0x31cfa5['visibleView'])&&_0x31cfa5['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 _0x1b91dd('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x5dd195 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x5dd195);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x66fcff){for(const _0x5be57d of this['_selectedAnnotations'])_0x66fcff['includes'](_0x5be57d)||this['_manuallyClosed']['delete'](_0x5be57d);for(const _0x20548b of this['annotations'])_0x66fcff['includes'](_0x20548b)||this['_removeAnnotationFromBalloon'](_0x20548b);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x1edb50 of _0x66fcff)this['_addAnnotationToBalloon'](_0x1edb50);}this['_selectedAnnotations']=_0x66fcff;}['_addAnnotationToBalloon'](_0x428cb1,_0x456404=!0x1){this['_manuallyClosed']['has'](_0x428cb1)||(this['_addedAnnotations']['has'](_0x428cb1)||this['_balloon']['hasView'](_0x428cb1['view'])||(this['_addedAnnotations']['add'](_0x428cb1),this['_balloon']['add']({'stackId':_0x428cb1['view']['id'],'view':_0x428cb1['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x428cb1)}})),_0x456404&&this['_balloon']['showStack'](_0x428cb1['view']['id']));}['_getBalloonTargetForAnnotation'](_0x1e91f4){const _0x52b957=_0x1e91f4['target'],_0x21856f=this['editor']['editing']['view'],_0x3ba61a=_0x21856f['document']['selection']['getFirstRange'](),_0xa7ee0a=_0x21856f['domConverter']['viewRangeToDom'](_0x3ba61a);if(_0xa7ee0a['collapse'](!0x0),_0x52b957){if(_0x52b957 instanceof _0x21625e)return _0x52b957;let _0x11c6a4=[];for(const _0x5e4198 of _0x52b957)_0x11c6a4['push'](...(_0x51a0bc=_0x5e4198['getClientRects'](),Array['from'](_0x51a0bc)['map'](DOMRect['fromRect'])));_0x11c6a4=function(_0x1176da){const _0xa36b48=[];let _0x294900=_0x1176da[0x0];for(let _0x3d1ef9=0x1;_0x3d1ef9<_0x1176da['length'];_0x3d1ef9++)B(_0x294900,_0x1176da[_0x3d1ef9])?_0x294900['width']+=_0x1176da[_0x3d1ef9]['width']:(_0xa36b48['push'](_0x294900),_0x294900=_0x1176da[_0x3d1ef9]);return _0xa36b48['push'](_0x294900),_0xa36b48;}(_0x11c6a4);const _0x138f1d=_0xa7ee0a['getBoundingClientRect']();return _0x11c6a4['find'](_0xc2a27e=>_0xc2a27e['top']<=_0x138f1d['top']&&_0xc2a27e['bottom']>=_0x138f1d['bottom']&&_0xc2a27e['left']<=_0x138f1d['left']&&_0xc2a27e['right']>=_0x138f1d['right'])||_0x11c6a4[0x0];}var _0x51a0bc;return _0x1e91f4['targetRect']||_0xa7ee0a;}['_removeAnnotationFromBalloon'](_0x4ba094){this['_addedAnnotations']['has'](_0x4ba094)&&this['_balloon']['hasView'](_0x4ba094['view'])&&(this['_addedAnnotations']['delete'](_0x4ba094),this['_balloon']['remove'](_0x4ba094['view']));}['_closeAnnotation'](_0x2c7f0b){this['_manuallyClosed']['add'](_0x2c7f0b),this['_removeAnnotationFromBalloon'](_0x2c7f0b);}}function B(_0x38d125,_0x23411f){return _0x38d125['top']===_0x23411f['top']&&_0x38d125['bottom']===_0x23411f['bottom']&&_0x38d125['right']===_0x23411f['left'];}class tt extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x1b3a8f,_0x5d0df7){super(_0x1b3a8f),this['set']('isEmpty',!_0x5d0df7['length']),this['focusTracker']=new _0x592ecb(),this['_annotationViews']=_0x5d0df7,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x22c242({'focusables':_0x5d0df7,'focusTracker':this['focusTracker']}),this['listenTo'](_0x5d0df7,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x5d0df7,'remove',(_0x3b9975,_0x1aed11)=>{_0x1aed11['isActive']&&this['focus'](),_0x5d0df7['length']||(this['isEmpty']=!0x0);});const _0x2444c0=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':E(_0x1b3a8f,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x5d0df7},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x2444c0['if']('isEmpty','ck-hidden',_0x466f6d=>!_0x466f6d)]},'children':[{'text':E(_0x1b3a8f,'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 _0x1f5d14 of this['_annotationViews'])this['focusTracker']['add'](_0x1f5d14['element']);this['_annotationViews']['on']('change',(_0x17e323,{added:_0x3771d5,removed:_0x39d9d7})=>{for(const _0x33bcdd of _0x3771d5)this['focusTracker']['add'](_0x33bcdd['element']);for(const _0x5cc8bb of _0x39d9d7)this['focusTracker']['remove'](_0x5cc8bb['element']);});}}class f extends _0x5f4d65{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,O];}constructor(_0x4c9c93){super(_0x4c9c93),this['archivedThreads']=new _0xa9d85c();}['init'](){const _0x6d60bf=this['context'],_0xa5af01=_0x6d60bf['plugins']['get'](o),_0xf1dd8f=_0x6d60bf['plugins']['get'](O);this['listenTo'](_0xa5af01,'addCommentThread',(_0xf2cd27,{threadId:_0x2e9b9c})=>{const _0x2012e3=_0xa5af01['getCommentThread'](_0x2e9b9c);_0x2012e3['archivedAt']&&this['archivedThreads']['add'](_0x2012e3,this['_calculatePosition'](_0x2012e3['archivedAt'])),this['listenTo'](_0x2012e3,'change:archivedAt',(_0x11c1bf,_0x4a2f9b,_0x55ad0a)=>{_0x55ad0a?this['archivedThreads']['has'](_0x2012e3)||this['archivedThreads']['add'](_0x2012e3,this['_calculatePosition'](_0x2012e3['archivedAt'])):this['archivedThreads']['has'](_0x2012e3)&&this['archivedThreads']['remove'](_0x2012e3);});}),this['listenTo'](_0xa5af01,'removeCommentThread',(_0x4e7a98,{threadId:_0x431cb5})=>{const _0x140b15=_0xa5af01['getCommentThread'](_0x431cb5);this['stopListening'](_0x140b15),this['archivedThreads']['has'](_0x140b15)&&this['archivedThreads']['remove'](_0x140b15);},{'priority':'highest'}),this['listenTo'](_0xf1dd8f['collection'],'focus',(_0x5d477c,_0xa4091f)=>{_0xa4091f['isVisible']||(_0xa4091f['isActive']=!0x0,_0xf1dd8f['activate'](_0xa4091f));});}['_calculatePosition'](_0xacfd5c){const _0x3b5809=[...this['archivedThreads']]['findIndex'](_0x342586=>_0x342586['archivedAt']<_0xacfd5c);return _0x3b5809>-0x1?_0x3b5809:this['archivedThreads']['length'];}}class a extends _0x3d65c4{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[f,_0x2df1b9];}constructor(_0x30381c){super(_0x30381c),this['annotationViews']=new _0x277c84(),this['_pendingThreads']=[];}['init'](){const _0x21bfe4=this['editor'],_0x9ecbee=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x21bfe4['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0xdd1602,!0x0)),_0x21bfe4['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0xdb1ea7=this['_createCommentsArchiveButton'](_0x17eead);return _0xdb1ea7['set']({'role':'menuitemcheckbox'}),_0xdb1ea7;});const _0x59504a=_0x21bfe4['plugins']['get'](f),_0x1b334f=_0x21bfe4['plugins']['get']('Annotations'),_0x5ece9b=_0x21bfe4['plugins']['get']('CommentsRepository');_0x59504a['archivedThreads']['forEach'](_0x40cb9c=>{this['_handleNewThread'](_0x40cb9c);}),this['listenTo'](_0x59504a['archivedThreads'],'add',(_0x21e4bb,_0x53e24a)=>{this['_handleNewThread'](_0x53e24a);}),this['listenTo'](_0x1b334f['collection'],'add',(_0x490ff0,_0xfbc4ac)=>{const _0x5c5814=this['_pendingThreads']['find'](_0x459754=>{const _0x4174e2=_0x5ece9b['_threadToController']['get'](_0x459754);return _0x4174e2&&_0xfbc4ac['innerView']===_0x4174e2['view'];});if(_0x5c5814){const _0x4b9fa0=this['_calculatePosition'](_0x5c5814['archivedAt']);this['annotationViews']['add'](_0xfbc4ac['view'],_0x4b9fa0),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x5c5814),0x1);}}),this['listenTo'](_0x59504a['archivedThreads'],'remove',(_0x4eed2c,_0x3cb57a)=>{const _0x2eef97=_0x21bfe4['config']['get']('collaboration.channelId');if(!_0x2eef97||_0x3cb57a['channelId']===_0x2eef97){const _0x13d0a6=_0x5ece9b['_threadToController']['get'](_0x3cb57a),_0x36efc1=_0x1b334f['getByInnerView'](_0x13d0a6['view']);this['annotationViews']['remove'](_0x36efc1['view']),this['stopListening'](_0x36efc1['focusableElements']);}}),this['listenTo'](_0x1b334f['collection'],'add',(_0x4979ee,_0x2f3ada)=>{this['listenTo'](_0x2f3ada,'escape',_0x9ecbee);}),this['listenTo'](_0x1b334f['collection'],'remove',(_0x46f221,_0x24c873)=>{this['stopListening'](_0x24c873,'escape',_0x9ecbee);});}['_handleNewThread'](_0x4b7379){const _0x1edae3=this['editor']['plugins']['get']('CommentsRepository'),_0x57a059=this['editor']['plugins']['get']('Annotations'),_0x56a8f4=this['editor']['config']['get']('collaboration.channelId');if(!_0x56a8f4||_0x4b7379['channelId']===_0x56a8f4){const _0x40fd0a=_0x1edae3['_threadToController']['get'](_0x4b7379);if(!_0x40fd0a)return void this['_pendingThreads']['push'](_0x4b7379);const _0x546c0e=this['_calculatePosition'](_0x4b7379['archivedAt']),_0x4f8688=_0x57a059['getByInnerView'](_0x40fd0a['view']);_0x4f8688['isVisible']&&_0x57a059['_visibleAnnotations']['remove'](_0x4f8688),this['annotationViews']['add'](_0x4f8688['view'],_0x546c0e);}}['_calculatePosition'](_0x263875){const _0x16abe0=this['editor']['config']['get']('collaboration.channelId'),_0x4d181b=[...this['editor']['plugins']['get'](f)['archivedThreads']]['filter'](_0x30cd31=>_0x30cd31['channelId']===_0x16abe0)['findIndex'](_0x153a65=>_0x153a65['archivedAt']<_0x263875);return _0x4d181b<0x0||_0x4d181b>this['annotationViews']['length']?this['annotationViews']['length']:_0x4d181b-0x1;}['_toggleDialog'](){const _0x4198fb=this['editor'],_0x440f07=_0x4198fb['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new tt(_0x4198fb['locale'],this['annotationViews'])),'commentsArchive'===_0x440f07['id']?_0x440f07['hide']():_0x440f07['show']({'id':'commentsArchive','title':E(_0x4198fb['locale'],'COMMENTS_ARCHIVE'),'icon':_0x53aa14,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x595483['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x3b27af,_0x91a76c=!0x1){const _0x31ed7c=this['editor']['locale'],_0x547f26=this['editor']['plugins']['get']('Dialog'),_0x457308=new _0x3b27af(_0x31ed7c);return _0x457308['bind']('isEnabled')['to'](this,'isEnabled'),_0x457308['bind']('isOn')['to'](_0x547f26,'id',_0xc92daf=>'commentsArchive'===_0xc92daf),_0x457308['set']({'label':E(_0x31ed7c,'COMMENTS_ARCHIVE'),'icon':_0x53aa14,'isToggleable':!0x0}),_0x91a76c&&(_0x457308['tooltip']=!0x0),this['listenTo'](_0x457308,'execute',()=>this['_toggleDialog']()),_0x457308;}['_hideDialogOnAnnotationEscape']=_0x4c6339=>{const _0x4d8951=_0x4c6339['source'];if(!this['annotationViews']['has'](_0x4d8951['view']))return;const _0x4ff4e7=this['editor']['plugins']['get']('Dialog');_0x4ff4e7['isOpen']&&'commentsArchive'===_0x4ff4e7['id']&&(_0x4ff4e7['hide'](),_0x4c6339['stop']());};}class p extends _0x3d65c4{static get['requires'](){return[o,r,i,f,a,s,e,n,c];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{d as Annotation,_ as AnnotationCollection,S as AnnotationView,O as Annotations,M as AnnotationsUIs,ts as BaseCommentThreadView,hs as BaseCommentView,fi as Comment,ui as CommentThread,Ct as CommentThreadController,ie as CommentThreadInputView,vt as CommentThreadView,gt as CommentView,p as Comments,f as CommentsArchive,a as CommentsArchiveUI,te as CommentsListView,s as CommentsOnly,o as CommentsRepository,i as CommentsUI,P as EditorAnnotations,c as InlineAnnotations,n as NarrowSidebar,z as Sidebar,e as WideSidebar};