@ckeditor/ckeditor5-comments 45.1.0-alpha.2 → 45.1.0-alpha.3

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 _0x569ce8,ContextPlugin as _0x36b078,PendingActions as ht,Command as _0x252083,Plugin as _0x584d8b,Context as _0x546a23}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0xde29c0,uid as _0x1b72a9,KeystrokeHandler as jt,FocusTracker as _0x35ba42,diff as _0x36fe32,Collection as _0x3ea071,Rect as _0x40616d,CKEditorError as _0x2a0e2d,first as _0xb5b0ae,priorities as Wt,scrollViewportToShowTarget as rt,getEnvKeystrokeText as nt,toUnit as xt,DomEmitterMixin as _0xfc451c,keyCodes as _0xa4c8b7}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x1dd037,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x2dd53d,trimHtml as _0x303f49,LateFocusDropdownButtonView as _0x4dd275,Users as it,getDateTimeFormatter as lt,hashObject as pt,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as ot,FOCUS_ANNOTATION_KEYSTROKE as _0x5c669a}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as wt,cloneDeep as It,set as At,unset as yt,debounce as _0x6e87ff}from'es-toolkit/compat';import{IconUndo as _0xf876bb,IconCheck as _0xc39267,IconPencil as _0x19d127,IconRemoveComment as _0x24f60c,IconThreeVerticalDots as _0x17c49b,IconAddComment as _0x48cf2c,IconCommentsArchive as _0x58018f}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as Vt,InlineEditableUIView as $t,EditorUI as Rt,View as kt,FocusCycler as _0x13e912,ButtonView as _0x9d10e1,ViewCollection as _0x291d35,createDropdown as _0x15f6a5,ListView as _0x3602d4,focusChildOnDropdownOpen as _0x5fd7f7,ListItemView as _0x488664,MenuBarMenuListItemButtonView as _0x27809a,BodyCollection as _0x54a758,BalloonPanelView as _0x222632,ContextualBalloon as _0x42ea7c,Dialog as _0x1b29cc,DialogViewPosition as _0x15f97d}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disablePlaceholder as St,enablePlaceholder as Ft,MouseObserver as _0x31f65c}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 _0x526b5c}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x1546a3}from'@ckeditor/ckeditor5-widget/dist/index.js';class Ct extends/* #__PURE__ -- @preserve */
24
- _0xde29c0(){['model'];['view'];constructor(_0x1e142c,_0x5644ea){super(),this['model']=_0x1e142c,this['model']['_isAttached']=!0x0,this['view']=_0x5644ea,this['listenTo'](_0x5644ea,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x5644ea,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x5644ea,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x5644ea,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x5644ea,'addComment',(_0x167c6d,_0x38d888)=>this['addComment'](_0x38d888)),this['listenTo'](_0x5644ea,'updateComment',(_0x211670,_0x29759a,_0x1f91fe)=>this['updateComment'](_0x29759a,_0x1f91fe)),this['listenTo'](_0x5644ea,'removeComment',(_0x6d2eb0,_0x517414)=>this['removeComment'](_0x517414));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x21e9a4){this['model']['addComment']({'content':_0x21e9a4,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x42e100,_0x24def5){this['model']['getComment'](_0x42e100)['update']({'content':_0x24def5});}['removeComment'](_0x3ee6cc){this['model']['getComment'](_0x3ee6cc)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function E(_0x22dc9b,_0x39ea16,_0x289e25){const t=_0x22dc9b['t'];switch(_0x39ea16){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'},_0x289e25);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'},_0x289e25);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'},_0x289e25);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'},_0x289e25);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x289e25);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'},_0x289e25);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'},_0x289e25);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'},_0x289e25);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(_0x153940,_0x1c858b){super(_0x153940);const _0x41c055=_0x1b72a9();this['main']=this['createCollection'](),this['editable']=new $t(_0x153940,_0x1c858b,void 0x0,{'label':()=>E(_0x153940,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x153940['uiLanguageDirection'],'lang':_0x153940['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x41c055},'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(_0x136819){super(_0x136819),this['view']=new Ut(_0x136819['locale'],_0x136819['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x447594=this['editor']['editing']['view'],_0x420712=this['view']['editable'],_0x3d63c8=_0x447594['document']['getRoot']();_0x420712['name']=_0x3d63c8['rootName'],this['view']['render']();const _0x42ba58=_0x420712['element'];this['setEditableElement'](_0x420712['name'],_0x42ba58),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x447594['attachDomRoot'](_0x42ba58),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Nt=[qt,zt,Bt,Et,Gt,Jt,Kt];class Qt extends/* #__PURE__ -- @preserve */
25
- _0xde29c0(_0x569ce8){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
- ((()=>Nt)());constructor(_0x1ee5d9={}){function _0x3114ad(_0x359210){return _0x359210['map'](_0x4b4e1f=>String['fromCharCode'](_0x4b4e1f))['join']('');}(_0x1ee5d9=Object['assign']({},_0x1ee5d9))['plugins']||(_0x1ee5d9['plugins']=Qt['defaultPlugins']),super(_0x1ee5d9),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[_0x3114ad([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3114ad([0x76,0x69,0x65,0x77])][_0x3114ad([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3114ad([0x61,0x75,0x74,0x6f]),this[_0x3114ad([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3114ad([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3114ad([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3114ad([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3114ad([0x6f,0x6b])});}['create'](){const _0x1a39fb=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x1a39fb))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x3d5a74=>{const _0x2c73e3=this['model']['document']['getRoot'](),_0x2bfb75=_0x2c73e3&&_0x2c73e3['getChild'](_0x2c73e3['childCount']-0x1);_0x3d5a74['setSelection'](_0x2bfb75,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x46eac0=this['editing']['view'],_0x5cc7cb=_0x46eac0['document']['getRoot'](),_0x1500fe=_0x5cc7cb['getChild'](0x0);_0x5cc7cb['childCount']>0x1||!_0x1500fe||'p'!=_0x1500fe['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x46eac0,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x1500fe['placeholder']=this['placeholder']),Ft({'view':_0x46eac0,'element':_0x1500fe,'keepOnFocus':!0x0}),this['placeholderElement']=_0x1500fe);}}class os extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x3e558b,_0x1daded={}){super(_0x3e558b),this['editor']=null,this['_editorConfig']=_0x1daded,this['set']('value',_0x1daded['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',E(_0x3e558b,'Reply...')),this['set']('submitLabel',E(_0x3e558b,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x35ba42(),this['focusCycler']=new _0x13e912({'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',(_0x3931ec,_0x2cfff3)=>{this['cancelButtonView']['fire']('execute'),_0x2cfff3();}),this['keystrokes']['set']('Ctrl+Enter',(_0xd5f047,_0xec8aa5)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0xec8aa5());}),this['on']('submit',(_0x33fb83,_0xfa89d8)=>{_0xfa89d8['length']>0xfde8?(alert(E(_0x3e558b,'TOO_LONG_COMMENT_ALERT',[_0xfa89d8['length'],0xfde8])),_0x33fb83['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 _0xed7265=this['editor'];this['element']['insertBefore'](_0xed7265['ui']['element'],this['element']['firstChild']),_0xed7265['model']['document']['on']('change',()=>this['value']=_0xed7265['getData']()),_0xed7265['bind']('placeholder')['to'](this),this['focusables']['add'](_0xed7265['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x5cd7cd){-0x1===_0x5cd7cd?(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:_0x2341ea}=this,_0x3d0cae=new _0x9d10e1(_0x2341ea);return _0x3d0cae['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x3d0cae['withText']=!0x0,_0x3d0cae['bind']('label')['to'](this,'submitLabel'),_0x3d0cae['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x3d0cae['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x929ade,_0x461f58)=>!_0x461f58&&!!_0x929ade['trim']()),_0x3d0cae;}['_createCancelButton'](){const {locale:_0x49af66}=this,_0x9329c5=new _0x9d10e1(_0x49af66);return _0x9329c5['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x9329c5['label']=E(_0x49af66,'Cancel'),_0x9329c5['withText']=!0x0,_0x9329c5['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x9329c5;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x5e6823=>{this['focusTracker']['add'](_0x5e6823['element']);}),this['focusables']['on']('change',(_0x36a2d7,_0xe58b22)=>{for(const _0x5b7410 of Array['from'](_0xe58b22['added'])['reverse']())this['focusTracker']['add'](_0x5b7410['element']);});}}class ie extends kt{constructor(_0x269154,_0x534996,_0x24b36e){super(_0x269154),this['commentInputView']=new os(_0x269154,_0x24b36e),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x1df422,_0x4c6149)=>_0x1df422||!!_0x4c6149),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 _0x1dd037(_0x269154,_0x534996),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'](_0x301e2f){this['commentInputView']['focus'](_0x301e2f);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x40eac2,_0x58510a)=>{const {submitButtonView:_0x367fdb,cancelButtonView:_0x43c4be,editor:_0x1093d5}=this['commentInputView'];[_0x367fdb['element'],_0x43c4be['element'],_0x1093d5?_0x1093d5['editing']['view']['getDomRoot']():null]['filter'](_0x42a6b2=>_0x42a6b2)['some'](_0x1ad321=>_0x1ad321['contains'](_0x58510a['target']))||(this['focus'](),_0x58510a['preventDefault']());});}}class cs extends kt{constructor(_0x3ae3c7){super(_0x3ae3c7);const _0x3de210=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x3de210['to']('count',_0x1d15b7=>E(_0x3ae3c7,'NUMBER_OF_COMMENTS',_0x1d15b7))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x34327a,_0x4c2725,_0x2c90ed){super(_0x34327a);const _0x1e6772=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x4c2725['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x4c2725,this['_config']=_0x2c90ed,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x35ba42(),this['keystrokes']=new jt(),this['focusCycler']=new _0x13e912({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5a930d=>this['commentViews']['map'](_0x553e95=>_0x553e95['element'])['includes'](_0x5a930d['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new cs(_0x34327a),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x2bdc88=>_0x2bdc88-this['_config']['maxCommentsWhenCollapsed']);for(const _0x2ff4c5 of _0x4c2725['comments'])this['_handleNewCommentModel'](_0x2ff4c5);this['_handleInfoComment'](),this['listenTo'](_0x4c2725['comments'],'add',(_0x47f49d,_0x3f37c7)=>{const _0x268253=this['_calculatePosition'](_0x3f37c7);this['length']++,this['_handleNewCommentModel'](_0x3f37c7,_0x268253),this['refreshVisibleViews']();}),this['listenTo'](_0x4c2725['comments'],'remove',(_0x55787e,_0x1b58ee)=>{this['length']--,this['_handleRemoveCommentModel'](_0x1b58ee),this['refreshVisibleViews']();}),this['listenTo'](_0x4c2725,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x4c2725,'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',_0x1e6772['if']('length','ck-hidden',_0x5b7447=>!_0x5b7447)],'aria-label':E(_0x34327a,'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'](_0x530fe0){-0x1===_0x530fe0?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0xeda255 of this['commentViews'])_0xeda255['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x95262a,_0x452168){const _0x4d1a15=new this['_config']['CommentView'](this['locale'],_0x95262a,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x4d1a15['viewUid']=_0x95262a['id'],_0x4d1a15['delegate']('removeComment')['to'](this),_0x4d1a15['delegate']('updateComment')['to'](this),_0x4d1a15['delegate']('resolveCommentThread')['to'](this),_0x4d1a15['delegate']('editorReady')['to'](this),_0x4d1a15['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x4d1a15,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x4d1a15,_0x452168);}['_calculatePosition'](_0x623477){const _0x4416e1=this['_model']['_findOptimalIndex'](_0x623477);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x623477['authoredAt']?_0x4416e1-0x1:_0x4416e1:_0x4416e1-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x59b90b={'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'],_0x59b90b,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x59b90b));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x4f5499){const _0xce35ff=this['commentViews']['remove'](_0x4f5499['id']);this['stopListening'](_0xce35ff),_0xce35ff['isEditMode']&&this['_updateHasDirtyComment'](),_0xce35ff['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x3cfd4d=>_0x3cfd4d['isEditMode']);}['_rearrangeCollapse'](){const _0x40188f=function(_0x11f90f){const _0x3fa82e=new _0x3ea071();for(const _0x2773a5 of _0x11f90f)_0x3fa82e['add'](_0x2773a5);return _0x3fa82e;}(this['commentViews']),_0x1c5d8f=this['_collapsedCommentsView']['count'];for(let _0x311785=0x1;_0x311785<=_0x1c5d8f;_0x311785++)_0x40188f['remove'](0x1);for(const _0x3a97e2 of _0x40188f)_0x3a97e2['collapse']();_0x1c5d8f>0x0&&_0x40188f['add'](this['_collapsedCommentsView'],0x1),ns(_0x36fe32(Array['from'](this['visibleViews']),Array['from'](_0x40188f)),this['visibleViews'],_0x40188f);}['_rearrangeExpand'](){ns(_0x36fe32(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x970a64 of this['visibleViews'])_0x970a64['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x2e7111=>{this['focusTracker']['add'](_0x2e7111['element']),this['keystrokes']['listenTo'](_0x2e7111['element']);}),this['commentViews']['on']('change',(_0x11069b,_0xf09995)=>{for(const _0x2420e6 of _0xf09995['removed'])this['focusTracker']['remove'](_0x2420e6['element']),this['keystrokes']['stopListening'](_0x2420e6['element']);for(const _0x1d19d8 of Array['from'](_0xf09995['added'])['reverse']())this['focusTracker']['add'](_0x1d19d8['element']),this['keystrokes']['listenTo'](_0x1d19d8['element']);});}}function ns(_0x59364e,_0x1e8ba8,_0x31a150){let _0x1594ca=0x0;for(const _0x346f5c of _0x59364e)switch(_0x346f5c){case'insert':_0x1e8ba8['add'](_0x31a150['get'](_0x1594ca),_0x1594ca),_0x1594ca++;break;case'delete':_0x1e8ba8['remove'](_0x1594ca);break;case'equal':_0x1594ca++;}}class as extends kt{constructor(_0x4e3cf0){super(_0x4e3cf0);const _0x4c9816=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x4c9816['to']('contextValue',_0x3e4762=>E(_0x4e3cf0,'THREAD_CONTEXT_LABEL',_0x3e4762)),'tabindex':-0x1},'children':[{'text':_0x4c9816['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x9d2fdd,_0x5c0b07){super(_0x9d2fdd);const _0x3df913=this['bindTemplate'];this['_model']=_0x5c0b07,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x35ba42(),this['keystrokes']=new jt(),this['focusCycler']=new _0x13e912({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x1b764a=>!!_0x1b764a),this['bind']('contextValue')['to'](this['_model'],'context',_0x226c27=>_0x226c27&&_0x226c27['value']?this['_trimContextValue'](_0x226c27['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',_0x3df913['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 _0x1081cf=new _0x9d10e1(this['locale']);return _0x1081cf['label']=E(this['locale'],'Reopen'),_0x1081cf['tooltip']=E(this['locale'],'Reopen'),_0x1081cf['icon']=_0xf876bb,_0x1081cf['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3f8177=>!_0x3f8177),_0x1081cf['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x1b3623,_0xde65c8)=>_0x1b3623&&_0xde65c8),_0x1081cf['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x1081cf;}['_trimContextValue'](_0x532f21){if(_0x532f21['length']<0x96)return _0x532f21;const _0x4ec6bc=_0x532f21['lastIndexOf']('\x20',0x93);return _0x532f21['substring'](0x0,_0x4ec6bc>-0x1?_0x4ec6bc:0x93)+'...';}['_attachContextActions'](){const _0x250bbd=this['element']['querySelector']('.ck-context'),_0x49f825=_0x250bbd['querySelector']('.ck-context__value');this['listenTo'](_0x250bbd,'mouseenter',()=>{_0x49f825['offsetWidth']<_0x49f825['scrollWidth']&&_0x250bbd['classList']['add']('overlay');}),this['listenTo'](_0x250bbd,'mouseleave',()=>{_0x250bbd['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x10ca50 of this['focusables'])this['focusTracker']['add'](_0x10ca50['element']),this['keystrokes']['listenTo'](_0x10ca50['element']);}['_createContextView'](){const _0x40666=new as(this['locale']);return _0x40666['bind']('contextValue')['to'](this),_0x40666;}}class ts extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x17559d,_0x203fee,_0x37d11c,_0x102fb1){super(_0x17559d),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x203fee,this['_localUser']=_0x37d11c,this['_config']=_0x102fb1,this['commentThreadHeaderView']=new Xt(_0x17559d,_0x203fee),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x17559d,E(_0x17559d,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x17559d,_0x203fee,Object['assign']({'CommentView':this['_config']['CommentView']},_0x102fb1)),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',(_0x3be21a,_0x3c1595)=>_0x3be21a||!!_0x3c1595),this['bind']('isUnlinked')['to'](_0x203fee,'unlinkedAt',_0x4933e6=>!!_0x4933e6),this['bind']('ariaLabel')['to'](this,'length',_0x2136cd=>{const _0x4152d3=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return E(this['locale'],'COMMENT_THREAD_LABEL',[_0x2136cd,_0x4152d3]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x35ba42(),this['keystrokes']=new jt(),this['focusCycler']=new _0x13e912({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5bd807=>_0x5bd807['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 _0xfe4985=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x5c3fed=_0xfe4985['commentInputView'];return _0xfe4985['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x5c3fed,'value',(_0x3ec06b,_0x4e1371,_0x4b00ea,_0x2ec310,_0x1903bf)=>!!_0x1903bf||!!_0x2ec310&&_0x4b00ea&&!_0x4e1371||_0x3ec06b&&_0x4b00ea&&!_0x4e1371),_0x5c3fed['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x36dac8,_0x39bce3,_0x2fde44)=>{let _0x24b55f;return _0x24b55f=_0x2fde44&&_0x39bce3?'Reply\x20to\x20reopen\x20discussion...':_0x36dac8?'Reply...':'Write\x20a\x20comment...',E(this['locale'],_0x24b55f);}),_0x5c3fed['bind']('submitLabel')['to'](this,'length',_0x148af6=>E(this['locale'],_0x148af6?'Reply':'Comment')),_0x5c3fed['on']('submit',(_0x571764,_0x6e0d06)=>{this['fire']('addComment',_0x6e0d06),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x5c3fed['on']('cancel',()=>{this['focus']();}),_0x5c3fed['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x5c3fed['on']('cancel',_0x42f0d9=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x42f0d9['stop']());}),this['on']('change:isActive',(_0x5757a2,_0x4cc1d9,_0x1dd01a)=>{_0x1dd01a||this['length']||_0x5c3fed['value']||this['fire']('removeCommentThread');}),_0xfe4985;}}class vt extends/* #__PURE__ -- @preserve */
27
- ti(ts){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x599a23,_0x3b19b2,_0x3fce89,_0x152471){super(_0x599a23,_0x3b19b2,_0x3fce89,_0x152471),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x599a23,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x26ed86,_0x27aba1,_0x5166f9)=>{_0x5166f9||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x327d2e,_0x5da0a0,_0x303d4)=>{_0x303d4&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x27decf=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x27decf['if']('isActive','ck-thread--active'),_0x27decf['if']('isUnlinked','ck-thread--unlinked'),_0x27decf['if']('isConfirm','ck-thread--remove-confirmation'),_0x27decf['to']('actionIndicator',_0x18560b=>_0x18560b?'ck-thread--'+_0x18560b:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x27decf['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 _0x3562f3 of this['commentsListView']['commentViews'])_0x3562f3['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x35ad76}=this,_0x24c7e9=this['commentsListView']['commentViews']['get'](0x0);_0x24c7e9===this['_boundFirstCommentView']||_0x24c7e9['isSystemComment']||(this['_boundFirstCommentView']=_0x24c7e9,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x24c7e9,'actionIndicator',_0x2fb0a3=>'remove'===_0x2fb0a3?'remove':null),_0x24c7e9['placeholder']=E(_0x35ad76,'Write\x20a\x20comment...'),_0x24c7e9['removeButton']['on']('execute',_0x20aed8=>{_0x20aed8['stop'](),this['showConfirm'](E(_0x35ad76,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x24c7e9['focus']();}),_0x24c7e9['actionBar']['add'](this['resolveButton'],0x0),_0x24c7e9['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x1ccaaf=new _0x2dd53d(this['locale']);return _0x1ccaaf['label']=E(this['locale'],'Resolve'),_0x1ccaaf['tooltip']=E(this['locale'],'Resolve'),_0x1ccaaf['icon']=_0xc39267,_0x1ccaaf['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x1ccaaf['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3a272f=>!_0x3a272f),_0x1ccaaf['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x4e2d5f,_0x20b0fb)=>_0x4e2d5f&&!_0x20b0fb),_0x1ccaaf['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x1ccaaf;}['_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(_0x5a2a59){super(_0x5a2a59),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x54584b,_0x170d1d,_0x435e85)=>{this['element']['innerHTML']=_0x435e85;}),this['element']['innerHTML']=this['content'];}}class hs extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0xc7ae4c,_0x2b9913,_0x14bbf5){super(_0xc7ae4c),this['_model']=_0x2b9913,this['_config']=_0x14bbf5,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x2b9913,'content',_0x2b9913,'authoredAt',(_0x93c8c3,_0x37178d)=>E(_0xc7ae4c,'COMMENT_ARIA_LABEL',[_0x2b9913['author']['name'],_0x14bbf5['formatDateTime'](_0x37178d),new DOMParser()['parseFromString'](_0x93c8c3,'text/html')['body']['textContent'],_0x2b9913['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0xc7ae4c,E(_0xc7ae4c,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x291d35(),this['focusTracker']=new _0x35ba42(),this['keystrokes']=new jt(),this['focusCycler']=new _0x13e912({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x35dc4e=>_0x35dc4e['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 _0x2189bb=new es(this['locale']);return _0x2189bb['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x33d143,_0x1f534f)=>_0x1f534f?_0x303f49(_0x33d143,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x33d143),_0x2189bb;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x11b8c4=new os(this['locale'],this['_config']['editorConfig']);return _0x11b8c4['value']=this['_model']['content'],_0x11b8c4['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x11b8c4['submitLabel']=E(this['locale'],'Save'),_0x11b8c4['on']('submit',(_0x2212e5,_0x4927f2)=>{this['fire']('updateComment',this['_model']['id'],_0x4927f2),this['switchToDisplayMode'](),this['focus']();}),_0x11b8c4['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x11b8c4['once']('editorReady',()=>{_0x11b8c4['focus']();}),_0x11b8c4['createEditor'](),_0x11b8c4['delegate']('editorReady')['to'](this),_0x11b8c4['delegate']('editorDestroyed')['to'](this),_0x11b8c4;}['_setupKeyboardNavigation'](){const _0x2a4f26=this['element'];this['keystrokes']['listenTo'](_0x2a4f26);for(const _0x26e662 of this['focusables'])this['focusTracker']['add'](_0x26e662['element']),this['keystrokes']['listenTo'](_0x26e662['element']);this['focusables']['on']('change',(_0x2b5281,_0x5ab435)=>{for(const _0x90d178 of _0x5ab435['removed'])this['focusTracker']['remove'](_0x90d178['element']),this['keystrokes']['stopListening'](_0x90d178['element']);for(const _0x4dcda2 of _0x5ab435['added'])this['focusTracker']['add'](_0x4dcda2['element']),this['keystrokes']['listenTo'](_0x4dcda2['element']);}),this['keystrokes']['set']('enter',(_0x44e93d,_0x2136fd)=>{_0x2a4f26===_0x44e93d['target']&&(this['focusCycler']['focusFirst'](),_0x2136fd());}),this['keystrokes']['set']('esc',(_0x8ee859,_0xd68a3e)=>{_0x2a4f26!==_0x8ee859['target']&&(this['focus'](),_0xd68a3e());});}}class gt extends/* #__PURE__ -- @preserve */
28
- ti(hs){['actionBar'];['userView'];constructor(_0x41a326,_0x38dcb8,_0xff8249){super(_0x41a326,_0x38dcb8,_0xff8249),this['set']('actionIndicator',null),this['set']('placeholder',E(_0x41a326,'Reply...')),this['bind']('authoredAt')['to'](_0x38dcb8),this['bind']('resolvedAt')['to'](_0x38dcb8),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 _0x1dd037(_0x41a326,_0x38dcb8['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x38dcb8,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x3c9dc7=this['bindTemplate'],_0x31c719=[{'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':_0x3c9dc7['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x3c9dc7['to']('authoredAt',_0x34fe3e=>this['_config']['formatDateTime'](_0x34fe3e))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x3c9dc7['if']('isEditMode','ck-comment__actions--hidden'),_0x3c9dc7['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']&&_0x31c719['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x3c9dc7['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x3c9dc7['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x3c9dc7['if']('isEditMode','ck-comment--edit'),_0x3c9dc7['if']('isSystemComment','ck-comment--info'),_0x3c9dc7['to']('actionIndicator',_0x3e6090=>_0x3e6090?'ck-comment--'+_0x3e6090:'')],'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':_0x31c719}]}]};}['_createEditButton'](){const _0x37ba62=new _0x9d10e1(this['locale']);return _0x37ba62['label']=E(this['locale'],'Edit'),_0x37ba62['icon']=_0x19d127,_0x37ba62['withText']=!0x0,_0x37ba62['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x37ba62['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3ee60a=>!_0x3ee60a),_0x37ba62['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x37ba62['on']('execute',()=>this['switchToEditMode']()),_0x37ba62;}['_createRemoveButton'](){const _0x1a7531=new _0x9d10e1(this['locale']);return _0x1a7531['label']=E(this['locale'],'Remove'),_0x1a7531['icon']=_0x24f60c,_0x1a7531['withText']=!0x0,_0x1a7531['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x1a7531['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3408f0=>!_0x3408f0),_0x1a7531['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x1a7531['on']('execute',()=>{this['showConfirm'](E(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x1a7531;}['_createDropdown'](){const _0x2d668b=_0x15f6a5(this['locale'],_0x4dd275),_0x534300=_0x2d668b['panelView']['children'],_0x5e9f7f=new _0x3602d4(this['locale']),_0x4be454=_0x2d668b['bindTemplate'];_0x5fd7f7(_0x2d668b,()=>this['items']['find'](_0x56a7a4=>_0x56a7a4['isVisible'])),_0x2d668b['extendTemplate']({'attributes':{'class':[_0x4be454['if']('isVisible','ck-hidden',_0xbfa1c9=>!_0xbfa1c9)]}});const _0xd5a901=(_0x1b12c5,_0x45a89a=-0x1)=>{const _0x1d06f6=new _0x488664(this['locale']);_0x1d06f6['children']['add'](_0x1b12c5);const _0x1a6b2=_0x45a89a>-0x1?_0x45a89a:_0x5e9f7f['items']['length'];_0x5e9f7f['items']['add'](_0x1d06f6,_0x1a6b2);const _0x562e7b=Array['from'](this['items']);_0x2d668b['unbind']('isEnabled','isVisible'),_0x2d668b['bind']('isEnabled')['toMany'](_0x562e7b,'isEnabled',(..._0x5f4893)=>_0x5f4893['some'](_0x7225e6=>_0x7225e6)),_0x2d668b['bind']('isVisible')['toMany'](_0x562e7b,'isVisible',(..._0x189dfb)=>_0x189dfb['some'](_0x2e19a9=>_0x2e19a9));};_0x2d668b['panelPosition']='sw',_0x2d668b['buttonView']['set']({'label':E(this['locale'],'Show\x20more\x20items'),'icon':_0x17c49b});for(const _0x29279f of this['items'])_0xd5a901(_0x29279f);return _0x534300['add'](_0x5e9f7f),_0x2d668b['listenTo'](this['items'],'add',(_0x3f2ad9,_0x1acfe2,_0x51c4d5)=>{_0xd5a901(_0x1acfe2,_0x51c4d5);}),_0x2d668b['listenTo'](this['items'],'remove',(_0x5c7d55,_0x36057a,_0x3b8c87)=>{_0x5e9f7f['items']['remove'](_0x3b8c87);}),_0x2d668b;}['_attachActions'](_0x37a055,_0x4bbc87){const _0x2117b0=_0x37a055&&_0x37a055['element'];_0x2117b0&&(this['listenTo'](_0x2117b0,'mouseenter',()=>this['actionIndicator']=_0x4bbc87),this['listenTo'](_0x2117b0,'focus',()=>this['actionIndicator']=_0x4bbc87),this['listenTo'](_0x2117b0,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x2117b0,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x367176=super['_createCommentInputView']();return _0x367176['bind']('placeholder')['to'](this),_0x367176;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function Lt(_0x4162fb){const _0x5030c6=Dt(_0x4162fb,0x1e),_0x5b4137=new MutationObserver(_0x23419d=>{for(const _0x471877 of _0x23419d)('attributes'==_0x471877['type']&&'class'==_0x471877['attributeName']||'childList'==_0x471877['type']||'characterData'==_0x471877['type'])&&_0x5030c6();});return{'attach'(_0x2597c1){_0x5b4137['observe'](_0x2597c1,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x5b4137['disconnect'](),_0x5030c6['cancel']();}};}class S extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x114075,_0x1a83fd){super(_0x114075),this['id']=_0x1b72a9(),this['focusTracker']=new _0x35ba42(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x291471,_0x4fa2f3)=>this['fire']('Esc',_0x4fa2f3)),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'](_0x1a83fd),this['mainView']=_0x1a83fd;const _0x2914b0=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x2914b0['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 _0x510b31=this['element']['clientHeight'];_0x510b31&&(this['height']=_0x510b31);}}class d extends/* #__PURE__ -- @preserve */
29
- _0xde29c0(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x8356d3,target:_0x7d0589,type:_0x59a5c0,isVisible:_0x59a3ae=!0x0}){super(),this['view']=_0x8356d3,this['view']['element']||this['view']['render'](),this['_type']=_0x59a5c0,this['_target']=_0x7d0589,d['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x3ea071([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x2b6995,_0x4bb6b0)=>{this['view']['focusTracker']['add'](_0x4bb6b0);}),this['focusableElements']['on']('remove',(_0x301afb,_0x3cbd79)=>{this['view']['focusTracker']['remove'](_0x3cbd79);}),this['set']('isVisible',_0x59a3ae);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0xf0a057=this['_getNormalizedTarget']();return d['_assertCorrectTarget'](_0xf0a057),_0xf0a057;}get['targetRect'](){const _0x4c9c1b=this['target'];if(null===_0x4c9c1b)return null;if(_0x4c9c1b instanceof _0x40616d)return _0x4c9c1b;const _0x172d9f=_0x4c9c1b['filter'](_0xe4d5a1=>function(_0x557a7f){const _0x71e540=_0x557a7f['offsetParent'];if(_0x71e540)return!0x0;const _0x30f18c=_0x557a7f['getClientRects']()['item'](0x0);return!!_0x30f18c;}(_0xe4d5a1));return 0x0===_0x172d9f['length']?null:new _0x40616d(_0x172d9f[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x333303){this['view']['isActive']=_0x333303,this['view']['mainView']['isActive']=_0x333303;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x2d75bc){if(!(null===_0x2d75bc||_0x2d75bc instanceof _0x40616d||Array['isArray'](_0x2d75bc)&&_0x2d75bc['every'](_0x5879b1=>li(_0x5879b1))))throw new _0x2a0e2d('annotation-invalid-target',null,{'target':_0x2d75bc});}['_getNormalizedTarget'](){const _0x5d7e2f='function'==typeof this['_target']?this['_target']():this['_target'];return li(_0x5d7e2f)?[_0x5d7e2f]:_0x5d7e2f;}}function li(_0x19d7ad){return null!==_0x19d7ad&&'object'==typeof _0x19d7ad&&'nodeType'in _0x19d7ad&&0x1===_0x19d7ad['nodeType'];}class _ extends _0x3ea071{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x184b36=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x35ba42(),this['_focusTracker']['on']('change:isFocused',(_0x3116cb,_0x1b024c,_0x5c63cc)=>{_0x5c63cc||this['fire']('blur');});for(const _0x5349bd of _0x184b36)this['add'](_0x5349bd);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x372fa7){if(this['has'](_0x372fa7))throw new _0x2a0e2d('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x372fa7['innerView'],_0x372fa7),this['_viewToAnnotation']['set'](_0x372fa7['view'],_0x372fa7);for(const _0xbcb2e3 of _0x372fa7['focusableElements'])this['_focusTracker']['add'](_0xbcb2e3);this['listenTo'](_0x372fa7['focusableElements'],'add',(_0x38820b,_0x967158)=>{this['_focusTracker']['add'](_0x967158);}),this['listenTo'](_0x372fa7['focusableElements'],'remove',(_0x15653d,_0x53c64c)=>{this['_focusTracker']['remove'](_0x53c64c);}),this['listenTo'](_0x372fa7['view']['focusTracker'],'change:isFocused',(_0x85279b,_0x2313a7,_0x3b67b6)=>{_0x3b67b6&&this['fire']('focus',_0x372fa7);}),_0x372fa7['updateTargetRect']();const _0x3a6ba9=this['_getOrderInContent'](_0x372fa7['view']['targetRect']);return super['add'](_0x372fa7,_0x3a6ba9);}['remove'](_0x887859){if(!this['has'](_0x887859))throw new _0x2a0e2d('annotationcollection-not-existing-item',null);this['stopListening'](_0x887859['view']['focusTracker']),this['stopListening'](_0x887859['focusableElements']);for(const _0x574346 of _0x887859['focusableElements'])this['_focusTracker']['remove'](_0x574346);return this['_viewToAnnotation']['delete'](_0x887859['view']),this['_innerViewToAnnotation']['delete'](_0x887859['innerView']),super['remove'](_0x887859);}['getByInnerView'](_0x2d55ee){return this['_innerViewToAnnotation']['get'](_0x2d55ee);}['getByView'](_0x2949b7){return this['_viewToAnnotation']['get'](_0x2949b7);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x25bbdd of this)_0x25bbdd['updateTargetRect']();this['_sort']();}['_sort'](){const _0x2c92d4=Array['from'](this)['sort']((_0x4003da,_0x149ffd)=>v(_0x4003da['view']['targetRect'],_0x149ffd['view']['targetRect']));for(let _0x40bd52=_0x2c92d4['length']-0x1;_0x40bd52>0x0;_0x40bd52--){const _0x4e2014=_0x2c92d4[_0x40bd52];_0x40bd52!==this['getIndex'](_0x4e2014)&&(this['remove'](_0x4e2014),this['add'](_0x4e2014));}}['_getOrderInContent'](_0xabc740){let _0x380548=0x0;if(!_0xabc740)return this['length'];for(const _0x49c33a of this){const _0x2bc89=_0x49c33a['view']['targetRect'];if(_0x2bc89){if(v(_0xabc740,_0x2bc89)<0x0)return _0x380548;_0x380548++;}}return _0x380548;}}function v(_0xdbb0bb,_0x4677e3){if(null===_0xdbb0bb&&null===_0x4677e3)return 0x0;if(null===_0xdbb0bb)return-0x1;if(null===_0x4677e3)return 0x1;const _0x208d2d=_0xdbb0bb['top']-_0x4677e3['top'];return 0x0==_0x208d2d?_0xdbb0bb['left']-_0x4677e3['left']:_0x208d2d;}class O extends _0x36b078{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x525de0){if(super(_0x525de0),this['collection']=new _(),this['_visibleAnnotations']=new _(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x525de0 instanceof _0x569ce8){const _0x2c53ad=_0x525de0['locale'];_0x525de0['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':E(_0x2c53ad,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x29f78c){this['collection']['add'](_0x29f78c);}['remove'](_0xcee77f){this['collection']['remove'](_0xcee77f),_0xcee77f['destroy']();}['refreshVisibility'](){for(const _0x3d2817 of this['collection'])_0x3d2817['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x209eba){return this['collection']['getByInnerView'](_0x209eba);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x47d9b8 of this['collection'])_0x47d9b8['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x31387b){this['fire']('_activateAnnotation',_0x31387b);}['createAnnotation'](_0x24a77d){return new d(_0x24a77d);}['createAnnotationView'](_0x338d4d,_0x71eb52){return new S(_0x338d4d,_0x71eb52);}['_addActiveAnnotation'](_0x1b352d){const _0x5b5253=new Set(this['activeAnnotations']);_0x5b5253['add'](_0x1b352d),this['activeAnnotations']=_0x5b5253;}['_removeActiveAnnotation'](_0x493e72){const _0x410245=new Set(this['activeAnnotations']);_0x410245['delete'](_0x493e72),this['activeAnnotations']=_0x410245;}['_bindAnnotationsToVisibleAnnotations'](){const _0x2f203e=this['collection'],_0x5c0ec6=this['_visibleAnnotations'];function _0x3f8b0c(_0x5c839a){const _0x58dcef=_0x5c839a['source'];_0x58dcef['isVisible']&&!_0x5c0ec6['has'](_0x58dcef)?_0x5c0ec6['add'](_0x58dcef):!_0x58dcef['isVisible']&&_0x5c0ec6['has'](_0x58dcef)&&_0x5c0ec6['remove'](_0x58dcef),_0x58dcef['view']['focusTracker']['remove'](_0x58dcef['view']['element']),_0x58dcef['view']['focusTracker']['add'](_0x58dcef['view']['element']);}this['listenTo'](_0x2f203e,'add',(_0x1b78fc,_0xf4f49c)=>{_0xf4f49c['isVisible']&&_0x5c0ec6['add'](_0xf4f49c),this['listenTo'](_0xf4f49c,'change:isVisible',_0x3f8b0c);}),this['listenTo'](_0x2f203e,'remove',(_0x303f2d,_0x4c54b6)=>{_0x5c0ec6['has'](_0x4c54b6)&&_0x5c0ec6['remove'](_0x4c54b6),this['stopListening'](_0x4c54b6,'change:isVisible',_0x3f8b0c);});}['_setupEnterAnnotationKeystroke'](){const _0x3fa206=_0x1c0623=>{_0x1c0623['on']('ready',()=>{_0x1c0623['keystrokes']['set'](_0x526b5c,(_0xd57c24,_0x36dac7)=>{const _0x3ef9d0=_0xb5b0ae(this['activeAnnotations']['values']());_0x3ef9d0&&(_0x3ef9d0['view']['focus'](),_0x36dac7());});});};this['context']instanceof _0x569ce8?_0x3fa206(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x1fd5b0,_0x11cb8a)=>{_0x3fa206(_0x11cb8a);});}['_setupEscapeAnnotationHandling'](){const _0x474dab=_0x104d53=>{const _0x26bc5=_0x104d53['source'],_0x46b3a0=[];let _0x5941bd;if(Array['isArray'](_0x26bc5['target'])){_0x5941bd=_0x26bc5['target'][0x0],this['context']instanceof _0x569ce8?_0x46b3a0['push'](this['context']):this['context']['editors']&&_0x46b3a0['push'](...this['context']['editors']);for(const _0x4c8d79 of _0x46b3a0)for(const _0x54b695 of _0x4c8d79['editing']['view']['domRoots']['values']())if(_0x54b695['contains'](_0x5941bd))return void _0x4c8d79['editing']['view']['focus']();_0x5941bd['focus']();}};this['listenTo'](this['collection'],'add',(_0x58adae,_0x93c326)=>{this['listenTo'](_0x93c326,'escape',_0x474dab,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x4dfa1a,_0x18b432)=>{this['stopListening'](_0x18b432,'escape',_0x474dab);});}}const Tt=Symbol('noChannel'),_t={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x36b078{['_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(_0x2e946e){super(_0x2e946e),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x4bfcd6=this['context']['config'];_0x4bfcd6['define']('comments.maxCommentsWhenCollapsed',0x2),_0x4bfcd6['define']('comments.maxThreadTotalWeight',0x1f4),_0x4bfcd6['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x4bfcd6['define']('comments.CommentThreadView',vt),_0x4bfcd6['define']('comments.CommentView',gt),_0x4bfcd6['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x50644d=this['context']['plugins']['get'](O);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x2c63ca,_0x1d721a)=>this['_addCommentThread'](_0x1d721a)),this['on']('submitCommentThread',(_0xa5f00e,_0x1235e9)=>this['_submitCommentThread'](_0x1235e9)),this['on']('resolveCommentThread',(_0x38629b,_0x12ce67)=>this['_resolveCommentThread'](_0x12ce67)),this['on']('resolveCommentThread',(_0x41833e,_0x2cfad8)=>this['_updateActiveAnnotation'](_0x2cfad8),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0xd59d10,_0x174870)=>this['_reopenCommentThread'](_0x174870)),this['on']('reopenCommentThread',(_0x473799,_0x450c41)=>this['_updateActiveAnnotation'](_0x450c41),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x2c4991,_0x3abb48)=>this['_removeCommentThread'](_0x3abb48)),this['on']('updateCommentThread',(_0x5d90f7,_0x1fbfbf)=>this['_updateCommentThread'](_0x1fbfbf)),this['on']('updateCommentThread',(_0x55a5df,_0x60c068)=>this['_updateActiveAnnotation'](_0x60c068),{'priority':'lowest'}),this['on']('addComment',(_0x5ade81,_0x31d422)=>this['_addComment'](_0x31d422)),this['on']('updateComment',(_0x578b9f,_0x2ac1b6)=>this['_updateComment'](_0x2ac1b6)),this['on']('removeComment',(_0x4c804a,_0x5d8d5d)=>this['_removeComment'](_0x5d8d5d)),this['on']('addComment',(_0x1ab2f2,{threadId:_0x35ef21,isFromAdapter:_0x1fa562})=>{if(_0x1fa562)return;const _0x13fc76=this['getCommentThread'](_0x35ef21),_0x58c753=_0x13fc76&&this['_threadToController']['get'](_0x13fc76);_0x58c753&&_0x58c753['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x50644d,'change:activeAnnotations',(_0x5d54cf,_0x148b74,_0x4bf332)=>{const _0x42c45a=Array['from'](_0x4bf332)['map'](_0x5e4fb9=>this['_viewToController']['get'](_0x5e4fb9['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x42c45a?_0x42c45a['model']:null;});}set['adapter'](_0x56f67f){if(this['_adapter'])throw new _0x2a0e2d('commentsrepository-adapter-already-set');this['_adapter']=_0x56f67f;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x1f55c9=Tt,threadId:_0x5a29c6=_0x1b72a9(),comments:_0x86152=[],unlinkedAt:_0x1d84a6=null,resolvedAt:_0x6268be=null,resolvedBy:_0x4717c5=null,target:_0x18457a=null,context:_0x1664cb=null,attributes:_0x261421={},isResolvable:_0x4abbfc=!0x0,isSubmitted:_0x8aad45=!0x1,isFromAdapter:_0x4eb389=!0x1}={}){return this['fire'](bt('addCommentThread',_0x1f55c9),{'channelId':_0x1f55c9,'threadId':_0x5a29c6,'comments':_0x86152,'unlinkedAt':_0x1d84a6,'resolvedAt':_0x6268be,'resolvedBy':_0x4717c5,'target':_0x18457a,'context':_0x1664cb,'attributes':_0x261421,'isFromAdapter':_0x4eb389,'isResolvable':_0x4abbfc,'isSubmitted':_0x8aad45}),this['getCommentThread'](_0x5a29c6);}['openNewCommentThread']({channelId:_0x1a8010=Tt,threadId:_0x535eb2=_0x1b72a9(),target:_0x10d883,context:_0x2304c9=null,isResolvable:_0x4dd9f9=!0x0}){if(this['_readOnlyChannels']['has'](_0x1a8010)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x10d883)throw new _0x2a0e2d('commentsrepository-missing-target');const _0x353c0b=this['addCommentThread']({'channelId':_0x1a8010,'threadId':_0x535eb2,'target':_0x10d883,'context':_0x2304c9,'isResolvable':_0x4dd9f9});if(!_0x353c0b)return null;const _0x22bcbf=this['_threadToController']['get'](_0x353c0b),_0x4b7753=_0x22bcbf['view']['commentThreadInputView']['commentInputView'],_0xb83926=this['context']['plugins']['get'](O),_0xb3936e=_0xb83926['getByInnerView'](_0x22bcbf['view']);return _0xb83926['activate'](_0xb3936e),_0x4b7753['once']('editorReady',()=>_0x4b7753['focus']()),_0x353c0b;}['hasCommentThread'](_0x4e4860){if('string'!=typeof _0x4e4860)throw new _0x2a0e2d('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x4e4860);}['updateCommentThread']({channelId:_0x4fdeb3=Tt,threadId:_0x2bff6a,context:_0x5aa015,unlinkedAt:_0x1e8a45,attributes:_0x22ea88,isFromAdapter:_0x31fcac=!0x1}){return this['fire'](bt('updateCommentThread',_0x4fdeb3),{'channelId':_0x4fdeb3,'threadId':_0x2bff6a,'context':_0x5aa015,'unlinkedAt':_0x1e8a45,'attributes':_0x22ea88,'isFromAdapter':_0x31fcac}),this['getCommentThread'](_0x2bff6a);}['getCommentThread'](_0x51a161){if('string'!=typeof _0x51a161)throw new _0x2a0e2d('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x51a161);}['fetchCommentThread']({channelId:_0x5c1b3f,threadId:_0x1c634d}={}){const _0x142bb8=this['getCommentThread'](_0x1c634d);if(_0x142bb8)return Promise['resolve'](_0x142bb8);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x2a0e2d('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x5c1b3f,'threadId':_0x1c634d})['then'](_0x2f1619=>this['hasCommentThread'](_0x1c634d)?this['getCommentThread'](_0x1c634d):_0x2f1619?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x5c1b3f},_0x2f1619)):void 0x0)['catch'](_0x5793ca=>{throw console['error'](_0x5793ca),new _0x2a0e2d('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x2ce366,skipNotAttached:_0x10a0d8=!0x1,skipEmpty:_0x5de030=!0x1,toJSON:_0xcf33d4=!0x1}={}){const _0x3b209d=[];for(const _0x1281bf of this['_threads']['values']())_0x2ce366&&_0x1281bf['channelId']!==_0x2ce366||_0x10a0d8&&!_0x1281bf['isAttached']||_0x5de030&&0x0===_0x1281bf['length']||_0x3b209d['push'](_0x1281bf);return _0xcf33d4?_0x3b209d['map'](_0x555d1d=>_0x555d1d['toJSON']()):_0x3b209d;}['setActiveCommentThread'](_0x2f0b22){const _0x1b58c4=this['context']['plugins']['get'](O);if(!_0x2f0b22)return void(this['activeCommentThread']&&_0x1b58c4['deactivateAll']());const _0x307d08=this['getCommentThread'](_0x2f0b22);if(!_0x307d08)throw new _0x2a0e2d('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x2f0b22});if(!this['_threadToController']['has'](_0x307d08))throw new _0x2a0e2d('commentsrepository-active-not-attached',null,{'threadId':_0x2f0b22});const _0xcfd2ec=_0x1b58c4['getByInnerView'](this['_threadToController']['get'](_0x307d08)['view']);_0x1b58c4['activate'](_0xcfd2ec);}['switchReadOnly'](_0x8c1734,_0x4399c9){_0x8c1734?this['_readOnlyChannels']['add'](_0x4399c9):this['_readOnlyChannels']['delete'](_0x4399c9),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x335bd6){return this['_readOnlyChannels']['has'](_0x335bd6)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x1c7547,_0x1f8476){return new Ct(_0x1c7547,_0x1f8476);}['setPermissions'](_0x298207,_0x4a7ad8=Tt){this['_permissions']['set'](_0x4a7ad8,_0x298207),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x5d2a2f=Tt){return this['_permissions']['has'](_0x5d2a2f)?this['_permissions']['get'](_0x5d2a2f):_t;}['_addCommentThread']({channelId:_0x27f88c,threadId:_0x38b7e6,comments:_0x1e0ce3,unlinkedAt:_0x22b4ba,resolvedAt:_0x57320b,resolvedBy:_0x133c80,target:_0x36a95a,context:_0x53ea61,attributes:_0x5ea764,isFromAdapter:_0xedd962,isResolvable:_0x44833c,isSubmitted:_0x32069c}){if('string'!=typeof _0x38b7e6)throw new _0x2a0e2d('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x38b7e6});if(this['hasCommentThread'](_0x38b7e6))throw new _0x2a0e2d('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x38b7e6});const _0x259e54=new ui(this,{'channelId':_0x27f88c,'id':_0x38b7e6,'context':_0x53ea61,'attributes':_0x5ea764,'unlinkedAt':_0x22b4ba,'resolvedAt':_0x57320b,'resolvedBy':_0x133c80?this['context']['plugins']['get'](it)['getUser'](_0x133c80):null,'isResolvable':_0x44833c,'isSubmitted':_0x32069c||_0xedd962});this['_threads']['set'](_0x38b7e6,_0x259e54);for(const _0x41e0e2 of _0x1e0ce3)_0x259e54['_add'](this['_createNewComment']({'threadId':_0x38b7e6,..._0x41e0e2}));return _0x36a95a&&_0x259e54['attachTo'](_0x36a95a),_0xedd962||!_0x259e54['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x27f88c,'threadId':_0x38b7e6});}['_submitCommentThread']({channelId:_0x5e5d37,threadId:_0x35dc7f}){if(!this['hasCommentThread'](_0x35dc7f))throw new _0x2a0e2d('commentsrepository-missing-comment-thread',this);const _0x24e9ab=this['getCommentThread'](_0x35dc7f);if(_0x24e9ab['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0xa8bbe2,comments:_0xa4f953,resolvedAt:_0x3dfecc,resolvedBy:_0x4188ca,context:_0x17ba0f,attributes:_0x3a7b37}=_0x24e9ab,_0x348559=this['context']['plugins']['get']('PendingActions'),_0x621efe=_0x348559['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x5e5d37,'threadId':_0xa8bbe2,'comments':_0xa4f953['map'](_0x5fccad=>_0x5fccad['toJSON']()),'resolvedAt':_0x3dfecc,'resolvedBy':_0x4188ca?_0x4188ca['id']:_0x4188ca,'context':_0x17ba0f,'attributes':_0x3a7b37})['then'](({comments:_0x14d3ff})=>{_0x348559['remove'](_0x621efe);for(const _0x4b6562 of _0x14d3ff)this['_updateComment']({'channelId':_0x5e5d37,'threadId':_0x35dc7f,'commentId':_0x4b6562['commentId'],'createdAt':_0x4b6562['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x49ad73=>{throw console['error'](_0x49ad73),new _0x2a0e2d('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x43abb6,target:_0x2a3fcd}){const _0x4dafb3=this['getCommentThread'](_0x43abb6);if(!_0x4dafb3)throw new _0x2a0e2d('commentsrepository-attach-missing-comment-thread',this);const _0x3c2585=this['context']['plugins']['get']('PendingActions'),_0x5cb983=this['context']['plugins']['get'](O),_0xd4922b=this['_createCommentThreadView'](_0x4dafb3),_0x339811=new Ct(_0x4dafb3,_0xd4922b);let _0x47a515=null;_0xd4922b['on']('change:isDirty',(_0x3ae878,_0x2eb984,_0x38cad2)=>{_0x38cad2?_0x47a515=_0x3c2585['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x47a515&&(_0x3c2585['remove'](_0x47a515),_0x47a515=null);}),this['_threadToController']['set'](_0x4dafb3,_0x339811),this['_viewToController']['set'](_0xd4922b,_0x339811);const _0x1a67c8=new S(this['context']['locale'],_0xd4922b);_0x1a67c8['bind']('length')['to'](_0xd4922b),_0x1a67c8['bind']('isDirty')['to'](_0xd4922b,'isDirty',_0xd4922b,'length',(_0x2e8c38,_0x20ddf5)=>_0x2e8c38||!_0x20ddf5),_0x1a67c8['bind']('isActive')['to'](_0xd4922b),_0x1a67c8['type']='comment';const _0x347c87=new d({'view':_0x1a67c8,'target':_0x2a3fcd,'type':'comment','isVisible':!_0x4dafb3['archivedAt']});return _0xd4922b['on']('escape',()=>{_0x347c87['fire']('escape');}),this['_bindAnnotationToEditors'](_0xd4922b,_0x347c87),_0x5cb983['add'](_0x347c87),_0x347c87;}['_bindAnnotationToEditors'](_0x9cbee9,_0x3d7e6b){this['listenTo'](_0x9cbee9,'editorReady',(_0x39695c,_0x3df063)=>{const _0x3b0ecf=_0x3df063['ui']['view']['body']['bodyCollectionContainer'];_0x3d7e6b['focusableElements']['add'](_0x3b0ecf),this['context']instanceof _0x569ce8&&this['context']['ui']['focusTracker']['add'](_0x3b0ecf);},{'priority':'highest'}),this['listenTo'](_0x9cbee9,'editorDestroyed',(_0x2b3bf6,_0x31728a)=>{const _0x545872=_0x31728a['ui']['view']['body']['bodyCollectionContainer'];_0x3d7e6b['focusableElements']['has'](_0x545872)&&_0x3d7e6b['focusableElements']['remove'](_0x545872),this['context']instanceof _0x569ce8&&this['context']['ui']['focusTracker']['remove'](_0x545872);});}['_unbindEditors'](_0x29c91a){this['stopListening'](_0x29c91a,'editorReady'),this['stopListening'](_0x29c91a,'editorDestroyed');}['_createCommentThreadView'](_0x537c54){const _0x3e34ab=this['context']['plugins']['get'](it),{config:_0x2d2056,locale:_0xeb71d4}=this['context'],_0x1d44ca=lt(_0x2d2056['get']('locale'),_0xeb71d4);return new(0x0,(_0x2d2056['get']('comments'))['CommentThreadView'])(_0xeb71d4,_0x537c54,_0x3e34ab['me'],{'editorConfig':{..._0x2d2056['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x2d2056['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x2d2056['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x2d2056['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x2d2056['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x1d44ca,'CommentView':_0x2d2056['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x1f99fe,channelId:_0x34d0b4,resolvedAt:_0x25a905,resolvedBy:_0x4ed1eb,isFromAdapter:_0x597a5b}){if(!this['hasCommentThread'](_0x1f99fe))throw new _0x2a0e2d('commentsrepository-missing-comment-thread',null,{'threadId':_0x1f99fe});const _0x253c6b=this['getCommentThread'](_0x1f99fe);if(_0x253c6b['isResolved'])throw new _0x2a0e2d('commentsrepository-resolved-comment-thread',null,{'threadId':_0x1f99fe});const _0x11734d=this['context']['plugins']['get'](it);if(_0x253c6b['resolvedBy']=_0x11734d['getUser'](_0x4ed1eb),_0x253c6b['resolvedAt']=_0x25a905,_0x597a5b||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x4bd339=this['context']['plugins']['get']('PendingActions'),_0x198b93=_0x4bd339['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x34d0b4,'threadId':_0x1f99fe})['then'](({resolvedAt:_0x256447,resolvedBy:_0x56e33e})=>{_0x4bd339['remove'](_0x198b93),_0x253c6b['resolvedBy']['id']!==_0x56e33e&&(_0x253c6b['resolvedBy']=_0x11734d['getUser'](_0x56e33e)),_0x253c6b['resolvedAt']=_0x256447;})['catch'](_0x385169=>{throw console['error'](_0x385169),new _0x2a0e2d('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x5bd2a1,channelId:_0x230c53,isFromAdapter:_0x1aefe2}){if(!this['hasCommentThread'](_0x5bd2a1))throw new _0x2a0e2d('commentsrepository-missing-comment-thread',null,{'threadId':_0x5bd2a1});const _0x365a55=this['getCommentThread'](_0x5bd2a1);if(!_0x365a55['isResolved'])throw new _0x2a0e2d('commentsrepository-reopen-comment-thread',null,{'threadId':_0x5bd2a1});if(_0x365a55['resolvedBy']=null,_0x365a55['resolvedAt']=null,_0x1aefe2||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x1f8487=this['context']['plugins']['get']('PendingActions'),_0x457e85=_0x1f8487['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x230c53,'threadId':_0x5bd2a1})['then'](()=>_0x1f8487['remove'](_0x457e85))['catch'](_0x3f8a24=>{throw console['error'](_0x3f8a24),new _0x2a0e2d('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x5c6c4c,isFromAdapter:_0x32c575}){const _0x5a492e=this['getCommentThread'](_0x5c6c4c);if(!_0x5a492e)throw new _0x2a0e2d('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x5c6c4c),this['_threads']['delete'](_0x5c6c4c),!_0x5a492e['isSubmitted']||_0x32c575||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x113a02=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4261b5}=_0x5a492e,_0x51df5b=_0x113a02['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x4261b5,'threadId':_0x5c6c4c})['then'](()=>_0x113a02['remove'](_0x51df5b))['catch'](_0x132008=>{throw console['error'](_0x132008),new _0x2a0e2d('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x5e3d31,unlinkedAt:_0x241585,context:_0x4f9188,attributes:_0x4fddf1,isFromAdapter:_0x11aba5}){if('string'!=typeof _0x5e3d31)throw new _0x2a0e2d('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x5e3d31});if(!this['hasCommentThread'](_0x5e3d31))throw new _0x2a0e2d('commentsrepository-missing-comment-thread',null,{'threadId':_0x5e3d31});const _0x48fd4d=this['getCommentThread'](_0x5e3d31);let _0x2cb168=!0x1;if(void 0x0!==_0x4f9188&&_0x48fd4d['context']!==_0x4f9188&&(_0x48fd4d['context']=_0x4f9188,_0x2cb168=!0x0),void 0x0!==_0x241585&&_0x48fd4d['unlinkedAt']!==_0x241585&&(_0x48fd4d['unlinkedAt']=_0x241585,_0x2cb168=!0x0),_0x4fddf1&&!wt(_0x4fddf1,_0x48fd4d['attributes'])&&(_0x48fd4d['attributes']=_0x4fddf1,_0x2cb168=!0x0),!_0x2cb168)return Promise['resolve']();if(!_0x48fd4d['isSubmitted']||_0x11aba5||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x4ea24e=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3bdc51}=_0x48fd4d,_0x41d55f=_0x4ea24e['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x3bdc51,'threadId':_0x5e3d31,'context':_0x4f9188,'unlinkedAt':_0x241585,'attributes':_0x4fddf1})['then'](()=>_0x4ea24e['remove'](_0x41d55f))['catch'](_0x4a39ed=>{throw console['error'](_0x4a39ed),new _0x2a0e2d('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x52892b){const _0x2c740c=this['context']['plugins']['get'](O),_0x3d44cf=this['getCommentThread'](_0x52892b);if(_0x3d44cf['_isAttached']=!0x1,this['_threadToController']['has'](_0x3d44cf)){const _0x56c829=this['_threadToController']['get'](_0x3d44cf),_0x5754ae=_0x56c829['view'],_0x611adb=_0x2c740c['getByInnerView'](_0x5754ae);this['_threadToController']['delete'](_0x3d44cf),this['_viewToController']['delete'](_0x5754ae),_0x611adb&&_0x2c740c['remove'](_0x611adb),_0x56c829['destroy'](),_0x5754ae['destroy']()['then'](()=>{this['_unbindEditors'](_0x5754ae);});}}['_updateActiveAnnotation']({threadId:_0x40d90b,resolvedAt:_0x122caa,unlinkedAt:_0x34b9cd}){const _0xae6811=!!_0x122caa,_0x4eb390=this['context']['plugins']['get'](O),_0x479eca=this['getCommentThread'](_0x40d90b);if(this['_threadToController']['has'](_0x479eca)){const _0x2a6f96=this['_threadToController']['get'](_0x479eca)['view'],_0x2a20a5=_0x4eb390['getByInnerView'](_0x2a6f96);_0x2a20a5&&(_0xae6811&&_0x4eb390['_removeActiveAnnotation'](_0x2a20a5),_0x34b9cd?_0x2a20a5['isVisible']=!0x1:_0x2a20a5['refreshVisibility']());}}['_getExternalAuthor'](_0x51d700){const _0x4b684c=this['context']['plugins']['get'](it),_0x350bbe=pt('external:'+_0x51d700),_0x85b1e3=_0x4b684c['getUser'](_0x350bbe);return _0x85b1e3||_0x4b684c['addUser']({'id':_0x350bbe,'name':_0x51d700});}['_createNewComment']({threadId:_0x119d34,commentId:_0x175270=_0x1b72a9(),content:_0x50f36d,authorId:_0x2fec78,createdAt:_0x249ce7,attributes:_0x37f89d}){if('string'!=typeof _0x175270)throw new _0x2a0e2d('commentsrepository-invalid-commentid');if('string'!=typeof _0x2fec78)throw new _0x2a0e2d('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x50f36d||!_0x50f36d['trim']())throw new _0x2a0e2d('commentsrepository-invalid-comment-content');const _0x3c222b=this['context']['plugins']['get'](it)['getUser'](_0x2fec78);if(!_0x3c222b)throw new _0x2a0e2d('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x2fec78});let _0x14bc29=null,_0x2bfcf0=_0x249ce7;return _0x37f89d?.['@external']&&(_0x14bc29=this['_getExternalAuthor'](_0x37f89d['@external']['authorName']),_0x2bfcf0=new Date(_0x37f89d['@external']['createdAt'])),new fi(this,{'threadId':_0x119d34,'id':_0x175270,'author':_0x14bc29||_0x3c222b,'creator':_0x3c222b,'content':_0x50f36d,'createdAt':_0x249ce7,'authoredAt':_0x2bfcf0,'attributes':_0x37f89d});}['_addComment'](_0x43abf2){let {threadId:_0x58de2e,content:_0x3f1504,attributes:_0x1ec19c,isFromAdapter:_0x187f26}=_0x43abf2;const _0x22dd8c=this['getCommentThread'](_0x43abf2['threadId']);if(!_0x22dd8c)throw new _0x2a0e2d('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x56892e=this['_createNewComment'](_0x43abf2),{id:_0x213019}=_0x56892e;if(_0x22dd8c['_add'](_0x56892e),_0x187f26||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x22dd8c['isSubmitted'])return Promise['resolve']();const _0x519044=this['context']['plugins']['get']('PendingActions'),{channelId:_0x28ced1}=_0x22dd8c,_0x5e6d6a=_0x519044['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x1ec19c||(_0x1ec19c={}),this['adapter']['addComment']({'channelId':_0x28ced1,'threadId':_0x58de2e,'commentId':_0x213019,'content':_0x3f1504,'attributes':_0x1ec19c})['then'](_0x484bf3=>{_0x519044['remove'](_0x5e6d6a),_0x484bf3&&this['_updateComment']({'channelId':_0x28ced1,'threadId':_0x58de2e,'commentId':_0x213019,'createdAt':_0x484bf3['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x150117=>{throw console['error'](_0x150117),new _0x2a0e2d('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0xa52a4d,commentId:_0x4e1c84,content:_0xa91fcf,createdAt:_0x416294,attributes:_0x441d59,isFromAdapter:_0x51b9cb}){if(void 0x0!==_0xa91fcf&&('string'!=typeof _0xa91fcf||!_0xa91fcf['trim']()['length']))throw new _0x2a0e2d('commentsrepository-update-comment-invalid-content');const _0x4573f9=this['getCommentThread'](_0xa52a4d),_0x54a824=_0x4573f9['getComment'](_0x4e1c84);if(!_0x54a824)throw new _0x2a0e2d('commentsrepository-update-missing-comment',this);let _0x40707d=!0x1;if(_0xa91fcf&&_0xa91fcf!==_0x54a824['content']&&(_0x54a824['isEditable']||_0x51b9cb)&&(_0x54a824['content']=_0xa91fcf,_0x40707d=!0x0),_0x416294&&_0x416294!==_0x54a824['createdAt']&&(_0x54a824['createdAt']=_0x416294,_0x54a824['attributes']&&_0x54a824['attributes']['@external']||(_0x54a824['authoredAt']=_0x416294),_0x40707d=!0x0),_0x441d59&&!wt(_0x441d59,_0x54a824['attributes'])&&(_0x54a824['attributes']=_0x441d59,_0x40707d=!0x0),!_0x40707d)return Promise['resolve']();if(_0x4573f9['fire']('commentUpdated'),_0x51b9cb||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x2d00bc=this['context']['plugins']['get']('PendingActions'),{channelId:_0x54abef}=this['getCommentThread'](_0x54a824['threadId']),_0x34b70a=_0x2d00bc['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x54abef,'threadId':_0xa52a4d,'commentId':_0x4e1c84,'content':_0xa91fcf,'attributes':_0x441d59})['then'](()=>_0x2d00bc['remove'](_0x34b70a))['catch'](_0x2e5750=>{throw console['error'](_0x2e5750),new _0x2a0e2d('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x1b5206,commentId:_0x3fa179,isFromAdapter:_0x5ce1c3}){const _0x4f2130=this['getCommentThread'](_0x1b5206),_0x2eb7e3=_0x4f2130['getComment'](_0x3fa179);if(!_0x2eb7e3)throw new _0x2a0e2d('commentsrepository-remove-missing-comment',this);if(_0x4f2130['_remove'](_0x2eb7e3),_0x5ce1c3||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x2355e1=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5899db}=_0x4f2130,_0x3533ac=_0x2355e1['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x5899db,'threadId':_0x1b5206,'commentId':_0x3fa179})['then'](()=>_0x2355e1['remove'](_0x3533ac))['catch'](_0x4e9461=>{throw console['error'](_0x4e9461),new _0x2a0e2d('commentsrepository-remove-comment-internal-error',this);});}}class ui extends/* #__PURE__ -- @preserve */
30
- _0xde29c0(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x59d3b9,_0x2bd1d9){super();const _0x4b1479=_0x2bd1d9['isResolvable'];this['channelId']=_0x2bd1d9['channelId'],this['id']=_0x2bd1d9['id'],this['comments']=new _0x3ea071(),this['_repository']=_0x59d3b9,this['_isAttached']=!0x1,this['_isSubmitted']=_0x2bd1d9['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x59d3b9,'_permissions',_0x59d3b9,'_readOnlyChannels',()=>_0x59d3b9['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x59d3b9,'_permissions',()=>_0x59d3b9['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x59d3b9,'_permissions',()=>{const _0x369169=_0x59d3b9['getPermissions'](this['channelId']);return _0x369169['write']||_0x369169['admin'];}),this['bind']('isResolvable')['to'](_0x59d3b9,'_permissions',()=>_0x4b1479&&_0x59d3b9['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x2bd1d9['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x27723e,_0x33760f)=>_0x27723e?_0x33760f?_0x27723e<_0x33760f?_0x27723e:_0x33760f:_0x27723e:_0x33760f),this['set']('unlinkedAt',_0x2bd1d9['unlinkedAt']||null),this['set']('resolvedAt',_0x2bd1d9['resolvedAt']||null),this['set']('resolvedBy',_0x2bd1d9['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x276fdd=>!!_0x276fdd),this['set']('attributes',_0x2bd1d9['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x286fb2,_0x3b79ed)=>_0x286fb2+_0x3b79ed['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x51c4e4,id:_0x13bbcc}=this;this['_repository']['fire'](bt('submitCommentThread',_0x51c4e4),{'channelId':_0x51c4e4,'threadId':_0x13bbcc});}['setUnlinkedAt'](_0x3feb10){this['_update']({'unlinkedAt':_0x3feb10});}['resolve']({resolvedAt:_0x340271=new Date(),resolvedBy:_0x4afe3c=null,isFromAdapter:_0x3766f3=!0x1}={}){const _0x577e16=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x291319,id:_0x29a7d1}=this;this['_repository']['fire'](bt('resolveCommentThread',_0x291319),{'channelId':_0x291319,'threadId':_0x29a7d1,'resolvedAt':_0x340271,'resolvedBy':_0x4afe3c||_0x577e16['id'],'isFromAdapter':_0x3766f3});}['reopen']({isFromAdapter:_0xa57437=!0x1}={}){const {channelId:_0x409f5a,id:_0x47c5d5}=this;this['_repository']['fire'](bt('reopenCommentThread',_0x409f5a),{'channelId':_0x409f5a,'threadId':_0x47c5d5,'isFromAdapter':_0xa57437});}['setContext'](_0x5602f6){this['context']||this['_update']({'context':_0x5602f6});}['setAttribute'](_0x1b9f08,_0x5bcdfc){const _0x2be666=It(this['attributes']);At(_0x2be666,_0x1b9f08,_0x5bcdfc),this['_update']({'attributes':_0x2be666});}['removeAttribute'](_0x100ed5){const _0x2b036e=It(this['attributes']);yt(_0x2b036e,_0x100ed5),this['_update']({'attributes':_0x2b036e});}['remove']({isFromAdapter:_0x3eaf4f=!0x1}={}){const {channelId:_0x3f83a6,id:_0x463ebb}=this;this['_repository']['fire'](bt('removeCommentThread',_0x3f83a6),{'channelId':_0x3f83a6,'threadId':_0x463ebb,'isFromAdapter':_0x3eaf4f});}['attachTo'](_0x28b01a){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x28b01a});}['addComment'](_0x35da43){const {channelId:_0x113664,id:_0x5d0c03}=this;this['_repository']['fire'](bt('addComment',_0x113664,_0x5d0c03),Object['assign']({'channelId':_0x113664,'threadId':_0x5d0c03},_0x35da43));}['getComment'](_0x18eb40){if('string'!=typeof _0x18eb40)throw new _0x2a0e2d('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x18eb40});return this['comments']['get'](_0x18eb40);}['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'](_0x31f08e=>_0x31f08e['toJSON']()),'attributes':this['attributes']};}['_add'](_0x3860fc){return this['listenTo'](_0x3860fc,'change:authoredAt',()=>{const _0x5a4435=this['_findOptimalIndex'](_0x3860fc),_0x141747=this['comments'];_0x5a4435-0x1!=_0x141747['getIndex'](_0x3860fc)&&_0x5a4435+0x1!=_0x141747['getIndex'](_0x3860fc)&&(this['_remove'](_0x3860fc),this['_add'](_0x3860fc));}),this['comments']['add'](_0x3860fc,this['_findOptimalIndex'](_0x3860fc));}['_update'](_0x2cb79f){const {channelId:_0x208e18,id:_0x393aff}=this;this['_repository']['fire'](bt('updateCommentThread',_0x208e18),{..._0x2cb79f,'channelId':_0x208e18,'threadId':_0x393aff});}['_remove'](_0x47ba5f){return this['stopListening'](_0x47ba5f),_0x47ba5f['destroy'](),this['comments']['remove'](_0x47ba5f);}['_findOptimalIndex'](_0x440394){const _0x59ffca=this['comments']['find'](_0x9eebdf=>new Date(_0x9eebdf['authoredAt'])['getTime']()>new Date(_0x440394['authoredAt'])['getTime']());return _0x59ffca?this['comments']['getIndex'](_0x59ffca):this['length'];}}class fi extends/* #__PURE__ -- @preserve */
31
- _0xde29c0(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x3870af,_0x2e055f){super();const _0x408822=_0x3870af['context']['plugins']['get'](it)['me'],_0x472ae5=_0x3870af['getCommentThread'](_0x2e055f['threadId']),_0x58fb67=0x0===_0x472ae5['comments']['length'],_0x50a7b6=_0x408822===_0x2e055f['author'];this['id']=_0x2e055f['id'],this['threadId']=_0x2e055f['threadId'],this['author']=_0x2e055f['author'],this['creator']=_0x2e055f['creator'],this['isExternal']=Boolean(_0x2e055f['attributes']&&_0x2e055f['attributes']['@external']),this['set']('content',_0x2e055f['content']),this['createdAt']=_0x2e055f['createdAt']||new Date(),this['set']('authoredAt',_0x2e055f['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x472ae5,'resolvedAt'),this['set']('attributes',_0x2e055f['attributes']||{}),this['bind']('isEditable')['to'](_0x3870af,'_permissions',()=>{const _0x6a6ed9=_0x3870af['getPermissions'](_0x472ae5['channelId'])['write'],_0x262903=_0x3870af['getPermissions'](_0x472ae5['channelId'])['modifyAll'];return _0x50a7b6&&_0x6a6ed9||!_0x50a7b6&&_0x262903;}),this['bind']('isRemovable')['to'](_0x472ae5,'isRemovable',_0x3870af,'_permissions',_0x2431fa=>{const _0x2b7b4b=_0x3870af['getPermissions'](_0x472ae5['channelId'])['write'],_0xa7c72c=_0x3870af['getPermissions'](_0x472ae5['channelId'])['modifyAll'];return _0x50a7b6&&_0x2b7b4b||_0x2431fa&&_0x58fb67||!_0x50a7b6&&_0xa7c72c&&!_0x58fb67;}),this['bind']('isReadOnly')['to'](_0x472ae5,'isReadOnly'),this['_repository']=_0x3870af;}get['weight'](){return Math['max'](function(_0x456786){const _0x17b539=document['createElement']('div');return _0x17b539['innerHTML']=_0x456786,_0x17b539['textContent']['length'];}(this['content']),0xc8);}['update'](_0x14f1a7){const {threadId:_0x3b30e9,id:_0x5288ce}=this;if(!this['_repository']['hasCommentThread'](_0x3b30e9))throw new _0x2a0e2d('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x4b12ec}=this['_repository']['getCommentThread'](_0x3b30e9);this['_repository']['fire'](bt('updateComment',_0x4b12ec,_0x3b30e9),{'channelId':_0x4b12ec,'threadId':_0x3b30e9,'commentId':_0x5288ce,..._0x14f1a7});}['setAttribute'](_0x607ba,_0xef6308){const _0x2093d1=It(this['attributes']);At(_0x2093d1,_0x607ba,_0xef6308),this['update']({'attributes':_0x2093d1});}['removeAttribute'](_0x458b49){const _0x37a464=It(this['attributes']);yt(_0x37a464,_0x458b49),this['update']({'attributes':_0x37a464});}['remove'](_0x3d6512={}){if(!_0x3d6512['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x2d56a9,id:_0x7c0121}=this;if(!this['_repository']['hasCommentThread'](_0x2d56a9))throw new _0x2a0e2d('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x4e241f}=this['_repository']['getCommentThread'](_0x2d56a9);this['_repository']['fire'](bt('removeComment',_0x4e241f,_0x2d56a9),{'channelId':_0x4e241f,'threadId':_0x2d56a9,'commentId':_0x7c0121,..._0x3d6512});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function bt(_0x1955f7,..._0x3dfb40){for(const _0x326180 of _0x3dfb40)void 0x0!==_0x326180&&(_0x1955f7+=':'+String(_0x326180));return _0x1955f7;}class J extends _0x252083{['refresh'](){const _0x4eb79e=this['editor']['model']['document']['selection'];for(const _0x1e7d50 of _0x4eb79e['getRanges']())if(this['_hasContent'](_0x1e7d50))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['execute']({threadId:_0x2d12fd=_0x1b72a9()}={}){const _0x1ca4a6=this['editor']['model'],_0x511ab1=[];for(const _0x14daa1 of _0x1ca4a6['document']['selection']['getRanges']())this['_hasContent'](_0x14daa1)&&_0x511ab1['push'](this['_trimToContent'](_0x14daa1));_0x1ca4a6['change'](_0x344e24=>{for(const _0x2e3b34 of _0x511ab1){const _0x207686=_0x1b72a9()['substr'](0x1,0x5),_0x5cbfdb='comment:'+_0x2d12fd+':'+_0x207686;_0x344e24['addMarker'](_0x5cbfdb,{'range':_0x2e3b34,'usingOperation':!0x1,'affectsData':!0x1});}});}['_hasContent'](_0x533086){for(const _0x555406 of _0x533086['getItems']())if(this['_itemIsContent'](_0x555406))return!0x0;return!0x1;}['_itemIsContent'](_0x4e6f12){return _0x4e6f12['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x4e6f12)&&!_0x4e6f12['is']('element','tableCell');}['_trimToContent'](_0x27d3bd){const _0x574caa=_0x11cb1c=>!this['_itemIsContent'](_0x11cb1c['item']),_0x489790=_0x27d3bd['start']['getLastMatchingPosition'](_0x574caa),_0x5a7f81=_0x27d3bd['end']['getLastMatchingPosition'](_0x574caa,{'direction':'backward'});return this['editor']['model']['createRange'](_0x489790,_0x5a7f81);}}class P extends _0x584d8b{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[O];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x13f300){super(_0x13f300),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x840907=this['editor'],_0x351a76=_0x840907['model']['document']['selection'],_0x391057=_0x6e87ff(()=>this['refreshSelectedViews'](),0xa);_0x351a76['on']('change:range',(_0x7cb34,_0x2eb3f5)=>{_0x2eb3f5['directChange']&&(_0x391057['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x840907['editing']['view']['document'],'change:isFocused',(_0x3e7c3d,_0x5f506b,_0x4365d3)=>{_0x4365d3&&_0x391057();}),this['listenTo'](_0x840907['ui']['focusTracker'],'change:isFocused',(_0x51220e,_0x168100,_0x9c8257)=>{_0x9c8257||_0x840907['isReadOnly']||this['fire']('blur',{'isAnnotationTracked':_0x47c131=>this['_editorAnnotationsData']['has'](_0x47c131['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x15739e){if(this['_editorAnnotations']['has'](_0x15739e['view']))return;this['_editorAnnotations']['add'](_0x15739e['view']),this['editor']['ui']['focusTracker']['add'](_0x15739e['view']['element']);const _0xbd4f5d=this['editor']['plugins']['get'](O);this['listenTo'](_0xbd4f5d['collection'],'remove',(_0x15bd3d,_0x4ebadf)=>{this['editor']['ui']['focusTracker']['remove'](_0x4ebadf['view']['element']),this['_editorAnnotations']['delete'](_0x4ebadf['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x2b3966){if('function'!=typeof _0x2b3966)throw new _0x2a0e2d('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x2b3966);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x192f7d,annotations:_0x24bfc0}){const _0x3e9853=[],_0x267cbe=this['editor']['model']['document']['selection'],_0x1842a2=Array['from'](_0x267cbe['getRanges']());for(const [_0x228249,_0x3feeb1]of this['_editorAnnotationsData']){const _0x572112=_0x24305f(_0x3feeb1),_0x33c7db=_0x24bfc0['getByInnerView'](_0x228249);_0x572112&&_0x33c7db&&_0x3e9853['push']({'annotation':_0x33c7db,'range':_0x572112});}function _0x24305f(_0xb97c00){for(const _0x5507cb of _0xb97c00)for(const _0x3c838b of _0x1842a2)if(_0x5507cb['containsRange'](_0x3c838b,!_0x267cbe['isCollapsed']))return _0x5507cb;return null;}return _0x3e9853['sort']((_0x3ac56b,_0x548800)=>{const _0x3acb9c=_0x3ac56b['range'],_0x1fa686=_0x548800['range'];if(!_0x3acb9c['isEqual'](_0x1fa686)){if(_0x3acb9c['containsRange'](_0x1fa686,!0x0))return 0x1;if(_0x1fa686['containsRange'](_0x3acb9c,!0x0))return-0x1;}return _0x3ac56b['annotation']==_0x192f7d?-0x1:_0x548800['annotation']==_0x192f7d?0x1:0x0;})['map'](_0x87cb34=>_0x87cb34['annotation']);}get['_editorAnnotationsData'](){const _0x3b2bb7=new Map();for(const _0x27925a of Array['from'](this['_dataCollectors']))for(const [_0xb4758d,_0x23a37e]of _0x27925a())_0x3b2bb7['set'](_0xb4758d,_0x23a37e);return _0x3b2bb7;}}class st extends _0x584d8b{['afterInit'](){const _0xad25f1=this['editor'];if(!_0xad25f1['plugins']['has']('RestrictedEditingModeEditing'))return;_0xad25f1['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x584d8b{constructor(_0x5840ad){super(_0x5840ad),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x1d36b2=this['editor'],_0x582bd4=_0x1d36b2['commands']['get']('importWord'),_0x27bf1c=_0x1d36b2['plugins']['get'](it);_0x582bd4&&(_0x582bd4['on']('execute',(_0xb1c2dc,[,_0xe67c16])=>{_0xe67c16['collaboration_features']={'comments':!0x0,'user_id':_0x27bf1c['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x582bd4,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x69dcf2,_0x1a60f2){const {comment_threads:_0x41cf44}=_0x1a60f2;_0x41cf44&&_0x41cf44['forEach'](({thread_id:_0x220898,comments:_0x1a95f4,is_resolved:_0x4a7779})=>{const _0x1740db=new Date(),_0x541bb4=_0x1a95f4['map'](({author:_0x24a25c,content:_0x591e08,created_at:_0x52d524})=>({'content':_0x591e08,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x1740db,'attributes':{'@external':{'authorName':_0x24a25c,'createdAt':_0x52d524?new Date(_0x52d524):new Date(),'source':'importWord'}}})),_0x5a35ee=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x5a35ee,'threadId':_0x220898,'comments':_0x541bb4,'resolvedAt':_0x4a7779?_0x1740db:null});});}}class at extends _0x584d8b{constructor(_0x471512){super(_0x471512),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x4af273=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x4af273,'contentInsertion',(_0x38636c,_0x57d32e)=>this['_removeMarkersWithoutThreads'](_0x57d32e['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x5154f4){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x5154f4;const _0x4362a7=this['editor']['plugins']['get']('CommentsRepository');for(const _0x34f194 of _0x5154f4['keys']()){const [_0x2b39c0,_0x2fd22c]=_0x34f194['split'](':');'comment'!=_0x2b39c0||_0x4362a7['hasCommentThread'](_0x2fd22c)||_0x5154f4['delete'](_0x34f194);}return _0x5154f4;}['_registerMarkerInClipboardPipeline'](){const _0x39f928=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x446035=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x446035&&_0x39f928['_registerMarkerToCopy']('comment',_0x446035);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x2f1f69){switch(_0x2f1f69){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 _0x584d8b{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x2bd1bd,_0x2cb663)=>{if(!_0x2cb663['options']['showCommentHighlights'])return null;if(_0x2cb663['options']['ignoreResolvedComments']){const {id:_0x38194a}=er(_0x2bd1bd['markerName']),_0x280483=this['editor']['plugins']['get'](o);if(_0x280483['getCommentThread'](_0x38194a)?.['isResolved']&&_0x2bd1bd['item'])return _0x2cb663['consumable']['consume'](_0x2bd1bd['item'],'addMarker:'+_0x2bd1bd['markerName']),_0x2cb663['consumable']['consume'](_0x2bd1bd['item'],'removeMarker:'+_0x2bd1bd['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1779e1=>{_0x1779e1['on']('addMarker:comment',(_0x27c979,_0x431cf1,_0x49256c)=>{if(!_0x49256c['options']['showCommentHighlights'])return;const _0x5874f8=_0x431cf1['item'];if(!_0x5874f8)return;const _0x55e2b1=_0x49256c['mapper']['toViewElement'](_0x5874f8);this['editor']['model']['schema']['isObject'](_0x5874f8)&&_0x55e2b1&&!_0x55e2b1['getCustomProperty']('widget')&&_0x55e2b1['is']('containerElement')&&_0x1546a3(_0x55e2b1,_0x49256c['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x17f5d9,{writer:_0x36b4ce,options:_0x375913})=>{if(!_0x375913['showCommentHighlights'])return null;const _0x4b91d1=_0x36b4ce['createContainerElement']('div'),_0x4fcc1a=_0x36b4ce['createEmptyElement']('hr');return _0x36b4ce['addClass']('ck-horizontal-line',_0x4b91d1),_0x36b4ce['insert'](_0x36b4ce['createPositionAt'](_0x4b91d1,0x0),_0x4fcc1a),_0x4b91d1;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x593a86,{writer:_0x360dce,options:_0x4a96fa})=>{if(!_0x4a96fa['showCommentHighlights'])return null;const _0x3c2751=_0x360dce['createContainerElement']('span'),_0x462054=_0x360dce['createEmptyElement']('img');return _0x360dce['addClass']('image-inline',_0x3c2751),_0x360dce['insert'](_0x360dce['createPositionAt'](_0x3c2751,0x0),_0x462054),_0x3c2751;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x105340,{writer:_0x478b0e,options:_0x120773})=>{if(_0x120773['showCommentHighlights'])return _0x478b0e['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x105356,_0x23736b,_0x595055)=>{_0x595055['options']['showCommentHighlights']&&_0x105356['stop']();},{'priority':'high'});}}class r extends _0x584d8b{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(_0x2082b7){super(_0x2082b7),this['set']('isThreadsLoadingPaused',!0x0),_0x2082b7['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x3fba57,_0x295a9b,_0x44bfb8,_0x501cb7)=>{const _0x4de00e=_0x2082b7['plugins']['get'](o),_0x484d84=_0x44bfb8?er(_0x44bfb8)['id']:null;_0x2082b7['model']['change'](()=>{if(_0x484d84){const _0x34362c=this['getAllMarkersForId'](_0x484d84);for(const _0xd6b0c2 of _0x34362c)_0x2082b7['editing']['reconvertMarker'](_0xd6b0c2);}if(_0x501cb7){const {id:_0x522d1f}=er(_0x501cb7),_0xf4fb75=_0x4de00e['getCommentThread'](_0x522d1f);if(_0xf4fb75&&_0xf4fb75['unlinkedAt'])return;if(_0xf4fb75&&!_0xf4fb75['isAttached'])return;const _0x257fd2=this['getAllMarkersForId'](_0x522d1f);for(const _0x40717b of _0x257fd2)_0x2082b7['editing']['reconvertMarker'](_0x40717b);}}),_0x484d84&&this['scrollToThreadMarker'](_0x484d84);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0xae8096=this['editor'],_0x29fa2d=_0xae8096['plugins']['get'](o),_0x1bbbab=_0xae8096['config']['get']('collaboration.channelId'),_0x3a219e=_0x29fa2d['getCommentThreads']()['filter'](_0x8aab19=>_0x8aab19['channelId']!==_0x1bbbab);_0xae8096['commands']['add']('addCommentThread',new J(_0xae8096)),this['listenTo'](_0xae8096,'change:isReadOnly',(_0x3ce664,_0x2f9379,_0x47eb70)=>{_0x29fa2d['switchReadOnly'](_0x47eb70,_0xae8096['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x29fa2d,ft('addCommentThread',_0x1bbbab),(_0x3dc8ef,{threadId:_0x527a91})=>{const _0x26467c=this['editor']['plugins']['get'](o)['getCommentThread'](_0x527a91);_0x26467c?.['unlinkedAt']&&this['_attachArchivedThread'](_0x527a91);}),this['listenTo'](_0x29fa2d,ft('removeCommentThread',_0x1bbbab),(_0x4799cb,{threadId:_0x29cec1})=>{_0xae8096['model']['enqueueChange']({'isUndoable':!0x1},_0x4acecf=>{const _0x10214c=this['getAllMarkersForId'](_0x29cec1);for(const _0x4466a6 of _0x10214c)_0x4acecf['removeMarker'](_0x4466a6);});}),this['listenTo'](_0x29fa2d,ft('resolveCommentThread',_0x1bbbab),(_0x3e9d24,{threadId:_0x20fed4})=>{(this['_reconvertMarkers'](_0x20fed4),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x20fed4)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x29fa2d,ft('reopenCommentThread',_0x1bbbab),(_0x180ad5,{threadId:_0x3b1ed2})=>{this['_reconvertMarkers'](_0x3b1ed2);},{'priority':'low'}),this['listenTo'](_0x29fa2d,ft('addComment',_0x1bbbab),(_0x513564,{threadId:_0x4c14e8,isFromAdapter:_0x22de21})=>{const _0x355acd=this['getAllMarkersForId'](_0x4c14e8);if(_0x22de21||0x0==_0x355acd['length']||!_0x29fa2d['hasCommentThread'](_0x4c14e8))return;0x1===_0x29fa2d['getCommentThread'](_0x4c14e8)['length']&&_0xae8096['model']['enqueueChange']({'isUndoable':!0x1},_0x4e915a=>{for(const _0x40b29f of _0x355acd)_0x4e915a['updateMarker'](_0x40b29f,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x3a219e);}['afterInit'](){!async function(_0x43c88f){const _0x25f0c0=_0x5d3e5d([0x38,0x4a,0x78,0x6e,0x62,0x45,0x34,0x50,0x76,0x72,0x6c,0x65,0x36,0x4f,0x71,0x4e,0x33,0x75,0x35,0x4d,0x70,0x37,0x42,0x41,0x43,0x54,0x49,0x30,0x7a,0x44,0x77,0x73,0x64,0x63,0x48,0x57,0x46,0x53,0x55,0x6f,0x68,0x39,0x32,0x51,0x6d,0x58,0x5a,0x47,0x56,0x69,0x59,0x79,0x74,0x6b,0x31,0x4b,0x67,0x66,0x52,0x4c,0x61,0x6a]),_0x450cff=0x32935f92,_0x585914=0x329438ca^_0x450cff,_0x1c2fbe=window[_0x5d3e5d([0x44,0x61,0x74,0x65])][_0x5d3e5d([0x6e,0x6f,0x77])](),_0x49f928=_0x43c88f[_0x5d3e5d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x47617b=new window[(_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1dee51=>{_0x49f928[_0x5d3e5d([0x6f,0x6e,0x63,0x65])](_0x5d3e5d([0x72,0x65,0x61,0x64,0x79]),_0x1dee51);}),_0x514f5d={[_0x5d3e5d([0x6b,0x74,0x79])]:_0x5d3e5d([0x45,0x43]),[_0x5d3e5d([0x75,0x73,0x65])]:_0x5d3e5d([0x73,0x69,0x67]),[_0x5d3e5d([0x63,0x72,0x76])]:_0x5d3e5d([0x50,0x2d,0x32,0x35,0x36]),[_0x5d3e5d([0x78])]:_0x5d3e5d([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]),[_0x5d3e5d([0x79])]:_0x5d3e5d([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]),[_0x5d3e5d([0x61,0x6c,0x67])]:_0x5d3e5d([0x45,0x53,0x32,0x35,0x36])},_0x2d7042=_0x49f928[_0x5d3e5d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x5d3e5d([0x67,0x65,0x74])](_0x5d3e5d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x59ce7a(){let _0x41efde,_0x4618fd=null,_0x371a5a=null;try{if(_0x2d7042==_0x5d3e5d([0x47,0x50,0x4c]))return _0x5d3e5d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x41efde=_0x391811(),!_0x41efde)return _0x5d3e5d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x41efde[_0x5d3e5d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x371a5a=_0x2c0b7a(_0x41efde[_0x5d3e5d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x41efde[_0x5d3e5d([0x6a,0x74,0x69])])),await _0x59bfea()?_0x34cb37()?_0x2fb678()?_0x5d3e5d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x2d601a()?(_0x41efde[_0x5d3e5d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5d3e5d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4618fd=_0x4bbea1(_0x5d3e5d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x41efde[_0x5d3e5d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5d3e5d([0x74,0x72,0x69,0x61,0x6c])&&(_0x4618fd=_0x4bbea1(_0x5d3e5d([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0xcd3242()):_0x5d3e5d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x5d3e5d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x5d3e5d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x58fd3a){return _0x5d3e5d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2fb678(){const _0x198b65=[_0x5d3e5d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x5d3e5d([0x74,0x72,0x69,0x61,0x6c])][_0x5d3e5d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x41efde[_0x5d3e5d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x1c2fbe/0x3e8:0xe10*_0x585914;return _0x41efde[_0x5d3e5d([0x65,0x78,0x70])]<_0x198b65;}function _0x34cb37(){const _0x5c28f2=_0x41efde[_0x5d3e5d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5c28f2)return!0x1;if(_0x5c28f2[_0x5d3e5d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d3e5d([0x2a])))return!0x0;if(_0x5c28f2[_0x5d3e5d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d3e5d([0x43,0x4d,0x54])))return!0x0;if(_0x5c28f2[_0x5d3e5d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d3e5d([0x52,0x43,0x4d,0x54]))){if(_0xe6d1a0())return!0x0;if(_0x1a00a2()||_0x218387())return!0x0;}return!0x1;}function _0x2d601a(){const _0x5f1b62=_0x41efde[_0x5d3e5d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5f1b62||0x0==_0x5f1b62[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1e9aba}=new URL(window[_0x5d3e5d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5f1b62[_0x5d3e5d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e9aba))return!0x0;const _0xc814e1=_0x1e9aba[_0x5d3e5d([0x73,0x70,0x6c,0x69,0x74])](_0x5d3e5d([0x2e]));return _0x5f1b62[_0x5d3e5d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x39bc3=>_0x39bc3[_0x5d3e5d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d3e5d([0x2a])))[_0x5d3e5d([0x6d,0x61,0x70])](_0x100d4e=>_0x100d4e[_0x5d3e5d([0x73,0x70,0x6c,0x69,0x74])](_0x5d3e5d([0x2e])))[_0x5d3e5d([0x73,0x6f,0x6d,0x65])](_0x284e75=>_0xc814e1[_0x5d3e5d([0x65,0x76,0x65,0x72,0x79])]((_0x5ea3fd,_0x465eca)=>_0x284e75[_0x465eca]===_0x5ea3fd||_0x284e75[_0x465eca]===_0x5d3e5d([0x2a])));}function _0xcd3242(){return _0x4618fd&&_0x371a5a?new window[(_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x42cd97,_0x32ad43)=>{_0x4618fd[_0x5d3e5d([0x74,0x68,0x65,0x6e])](_0x42cd97,_0x32ad43),_0x371a5a[_0x5d3e5d([0x74,0x68,0x65,0x6e])](_0x28a0bb=>{_0x28a0bb!=_0x5d3e5d([0x56,0x61,0x6c,0x69,0x64])&&_0x42cd97(_0x28a0bb);},_0x32ad43);}):_0x4618fd||_0x371a5a||_0x5d3e5d([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2c0b7a(_0x18fd12,_0x172514){return new window[(_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x27971f=>{if(_0x4f9c95())return _0x27971f(_0x5d3e5d([0x56,0x61,0x6c,0x69,0x64]));_0x240e74(),_0x49f928[_0x5d3e5d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x5d3e5d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x199b9e=!0x1;const _0x231408=_0x1b72a9();function _0x4b563e(_0x108a75){return!!_0x108a75&&(typeof _0x108a75===_0x5d3e5d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x108a75===_0x5d3e5d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x108a75[_0x5d3e5d([0x74,0x68,0x65,0x6e])]===_0x5d3e5d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x108a75[_0x5d3e5d([0x63,0x61,0x74,0x63,0x68])]===_0x5d3e5d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x58e74b(_0x451706){_0x3aa1d7(_0x451706)[_0x5d3e5d([0x74,0x68,0x65,0x6e])](_0x49cb0b=>{if(!_0x49cb0b||_0x49cb0b[_0x5d3e5d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x5d3e5d([0x6f,0x6b]))return _0x5d3e5d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3aa081(_0xff0097(_0x231408+_0x172514))!=_0x49cb0b[_0x5d3e5d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x5d3e5d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x5d3e5d([0x56,0x61,0x6c,0x69,0x64]);})[_0x5d3e5d([0x74,0x68,0x65,0x6e])](_0x34c9f7=>(_0x4ff18c(),_0x34c9f7),()=>{const _0x41fedf=_0x218c73();return null==_0x41fedf?(_0x4ff18c(),_0x5d3e5d([0x56,0x61,0x6c,0x69,0x64])):_0x5d3e5d(_0x1c2fbe-_0x41fedf>(0x169fdb92^_0x450cff)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x5d3e5d([0x74,0x68,0x65,0x6e])](_0x27971f)[_0x5d3e5d([0x63,0x61,0x74,0x63,0x68])](()=>{_0x27971f(_0x5d3e5d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x31f88b=0x32a5b112^_0x450cff;function _0x4ff18c(){const _0x149cf7=_0x5d3e5d([0x6c,0x6c,0x63,0x74,0x2d])+_0x3aa081(_0xff0097(_0x18fd12)),_0x118431=_0x2acdec(_0x3aa081(window[_0x5d3e5d([0x4d,0x61,0x74,0x68])][_0x5d3e5d([0x63,0x65,0x69,0x6c])](_0x1c2fbe/_0x31f88b)));window[_0x5d3e5d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5d3e5d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x149cf7,_0x118431);}function _0x218c73(){const _0x5dbba0=_0x5d3e5d([0x6c,0x6c,0x63,0x74,0x2d])+_0x3aa081(_0xff0097(_0x18fd12)),_0x2236d7=window[_0x5d3e5d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5d3e5d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5dbba0);return _0x2236d7?window[_0x5d3e5d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2acdec(_0x2236d7),0x10)*_0x31f88b:null;}function _0x3aa1d7(_0x249606){return new window[(_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x47e177,_0x461646)=>{_0x249606[_0x5d3e5d([0x74,0x68,0x65,0x6e])](_0x47e177,_0x461646),window[_0x5d3e5d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x461646,0x32928b52^_0x450cff);});}}_0x49f928[_0x5d3e5d([0x6f,0x6e])](_0x5d3e5d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x43cba5,_0x17e0a4)=>{if(_0x17e0a4[0x0]!=_0x18fd12)return _0x27971f(_0x5d3e5d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x17e0a4[0x1]={..._0x17e0a4[0x1],[_0x5d3e5d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x231408};},{[_0x5d3e5d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5d3e5d([0x68,0x69,0x67,0x68])}),_0x49f928[_0x5d3e5d([0x6f,0x6e])](_0x5d3e5d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xabcf7=>{_0x4b563e(_0xabcf7[_0x5d3e5d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x199b9e=!0x0,_0x58e74b(_0xabcf7[_0x5d3e5d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x5d3e5d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5d3e5d([0x6c,0x6f,0x77])}),_0x47617b[_0x5d3e5d([0x74,0x68,0x65,0x6e])](()=>{_0x199b9e||_0x27971f(_0x5d3e5d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4f9c95(){return _0x49f928[_0x5d3e5d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5d3e5d([0x76,0x69,0x65,0x77])][_0x5d3e5d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x5d3e5d([0x61,0x75,0x74,0x6f]);}function _0x240e74(){_0x49f928[_0x5d3e5d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5d3e5d([0x76,0x69,0x65,0x77])][_0x5d3e5d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5d3e5d([0x61,0x75,0x74,0x6f]);}}function _0x4bbea1(_0xe3afe0){const _0xa9df53=[new window[(_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3ed4f9=>setTimeout(_0x3ed4f9,0x329a615e^_0x450cff)),_0x47617b[_0x5d3e5d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5a0e48=>{let _0x57414a=0x0;_0x49f928[_0x5d3e5d([0x6d,0x6f,0x64,0x65,0x6c])][_0x5d3e5d([0x6f,0x6e])](_0x5d3e5d([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x507fb9,_0x41727e)=>{_0x41727e[0x0][_0x5d3e5d([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x57414a++,_0x57414a==(0x32935e6a^_0x450cff)&&(_0x5a0e48(),_0x507fb9[_0x5d3e5d([0x6f,0x66,0x66])]());});}))];return window[_0x5d3e5d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5d3e5d([0x72,0x61,0x63,0x65])](_0xa9df53)[_0x5d3e5d([0x74,0x68,0x65,0x6e])](()=>_0xe3afe0);}async function _0x4b2db2(){await _0x47617b,_0x49f928[_0x5d3e5d([0x6d,0x6f,0x64,0x65,0x6c])][_0x5d3e5d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x7d3c1e,_0x49f928[_0x5d3e5d([0x6d,0x6f,0x64,0x65,0x6c])][_0x5d3e5d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x7d3c1e,_0x49f928[_0x5d3e5d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x5d3e5d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0xe6d1a0(){return _0x4d8bc6(_0x5d3e5d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5e8d00(_0x5d3e5d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x5d3e5d([0x73,0x74,0x61,0x74,0x65])]==_0x5d3e5d([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1a00a2(){return _0x4d8bc6(_0x5d3e5d([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 _0x218387(){return _0x4d8bc6(_0x5d3e5d([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x60e064(_0x5d3342){const _0x1b1a97=_0x15d5c1();_0x49f928[_0x1b1a97]=_0x5d3e5d([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x5d3342,_0x5d3342!=_0x5d3e5d([0x56,0x61,0x6c,0x69,0x64])&&_0x4b2db2();}function _0x15d5c1(){const _0xe0f3ca=window[_0x5d3e5d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x5d3e5d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x5d3e5d([0x6e,0x6f,0x77])]())[_0x5d3e5d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x5d3e5d([0x2e]),'');let _0x24ff41=_0x5d3e5d([0x4a]);for(let _0x19cf13=0x0;_0x19cf13<_0xe0f3ca[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x19cf13+=0x2){let _0x5882b0=window[_0x5d3e5d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xe0f3ca[_0x5d3e5d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x19cf13,_0x19cf13+0x2));_0x5882b0>=_0x25f0c0[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5882b0-=_0x25f0c0[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x24ff41+=_0x25f0c0[_0x5882b0];}return _0x24ff41;}function _0x391811(){const _0x7b46db=_0x2d7042[_0x5d3e5d([0x73,0x70,0x6c,0x69,0x74])](_0x5d3e5d([0x2e]));if(0x3!=_0x7b46db[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1a079e(_0x7b46db[0x1]);function _0x1a079e(_0x399eee){const _0x3073f6=_0x5ce82b(_0x399eee);return _0x3073f6&&_0x351acc()?_0x3073f6:null;function _0x351acc(){const _0x12bbfd=_0x3073f6[_0x5d3e5d([0x6a,0x74,0x69])],_0x2acca9=window[_0x5d3e5d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x12bbfd[_0x5d3e5d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x12bbfd[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x53e9cf={..._0x3073f6,[_0x5d3e5d([0x6a,0x74,0x69])]:_0x12bbfd[_0x5d3e5d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x12bbfd[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x53e9cf[_0x5d3e5d([0x76,0x63])],_0xff0097(_0x53e9cf)==_0x2acca9;}}}async function _0x59bfea(){let _0x5228ce=!0x0;try{const _0x294282=_0x2d7042[_0x5d3e5d([0x73,0x70,0x6c,0x69,0x74])](_0x5d3e5d([0x2e])),[_0x7a0788,_0x3530af,_0x53daa4]=_0x294282;return _0x9127ee(_0x7a0788),await _0x3961d8(_0x7a0788,_0x3530af,_0x53daa4),_0x5228ce;}catch(_0x23b0f0){return!0x1;}function _0x9127ee(_0x2f24ca){const _0x3867bd=_0x5ce82b(_0x2f24ca);_0x3867bd&&_0x3867bd[_0x5d3e5d([0x61,0x6c,0x67])]==_0x5d3e5d([0x45,0x53,0x32,0x35,0x36])||(_0x5228ce=!0x1);}async function _0x3961d8(_0x5db31a,_0x2ff1ea,_0x53686c){const _0x500649=window[_0x5d3e5d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x5d3e5d([0x66,0x72,0x6f,0x6d])](_0x3aaf69(_0x53686c),_0x1773c9=>_0x1773c9[_0x5d3e5d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3570df=new window[(_0x5d3e5d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x5d3e5d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5db31a+_0x5d3e5d([0x2e])+_0x2ff1ea),_0x4e68c4=window[_0x5d3e5d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x5d3e5d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4e68c4)return;const _0x486aef=await _0x4e68c4[_0x5d3e5d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x5d3e5d([0x6a,0x77,0x6b]),_0x514f5d,{[_0x5d3e5d([0x6e,0x61,0x6d,0x65])]:_0x5d3e5d([0x45,0x43,0x44,0x53,0x41]),[_0x5d3e5d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x5d3e5d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x5d3e5d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4e68c4[_0x5d3e5d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x5d3e5d([0x6e,0x61,0x6d,0x65])]:_0x5d3e5d([0x45,0x43,0x44,0x53,0x41]),[_0x5d3e5d([0x68,0x61,0x73,0x68])]:{[_0x5d3e5d([0x6e,0x61,0x6d,0x65])]:_0x5d3e5d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x486aef,_0x500649,_0x3570df)||(_0x5228ce=!0x1);}}function _0x5ce82b(_0x1e3cf0){return _0x1e3cf0[_0x5d3e5d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x5d3e5d([0x65,0x79]))?JSON[_0x5d3e5d([0x70,0x61,0x72,0x73,0x65])](_0x3aaf69(_0x1e3cf0)):null;}function _0x3aaf69(_0x2ff1fc){return window[_0x5d3e5d([0x61,0x74,0x6f,0x62])](_0x2ff1fc[_0x5d3e5d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x5d3e5d([0x2b]))[_0x5d3e5d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x5d3e5d([0x2f])));}function _0xff0097(_0x91291c){let _0x587094=0x1505;function _0x3d408c(_0x39ec28){for(let _0x1d170c=0x0;_0x1d170c<_0x39ec28[_0x5d3e5d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1d170c++){const _0x12b891=_0x39ec28[_0x5d3e5d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1d170c);_0x587094=(_0x587094<<0x5)+_0x587094+_0x12b891,_0x587094&=_0x587094;}}function _0x2592a0(_0x23b631){Array[_0x5d3e5d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x23b631)?_0x23b631[_0x5d3e5d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2592a0):_0x23b631&&typeof _0x23b631==_0x5d3e5d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x5d3e5d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x23b631)[_0x5d3e5d([0x73,0x6f,0x72,0x74])]()[_0x5d3e5d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x539bf3,_0x1e8fcd])=>{_0x3d408c(_0x539bf3),_0x2592a0(_0x1e8fcd);}):_0x3d408c(window[_0x5d3e5d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x23b631));}return _0x2592a0(_0x91291c),_0x587094>>>0x0;}function _0x3aa081(_0x34e59c){return _0x34e59c[_0x5d3e5d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x5d3e5d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x5d3e5d([0x30]));}function _0x2acdec(_0x16c716){return _0x16c716[_0x5d3e5d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x5d3e5d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x5d3e5d([0x6a,0x6f,0x69,0x6e])]('');}function _0x4d8bc6(_0x1891b1){return _0x49f928[_0x5d3e5d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5d3e5d([0x68,0x61,0x73])](_0x1891b1);}function _0x5e8d00(_0xac6e0c){return _0x49f928[_0x5d3e5d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5d3e5d([0x67,0x65,0x74])](_0xac6e0c);}function _0x7d3c1e(){}function _0x5d3e5d(_0x2e11c1){return _0x2e11c1['map'](_0x51c4d1=>String['fromCharCode'](_0x51c4d1))['join']('');}_0x60e064(await _0x59ce7a());}(this);}['destroy'](){const _0x4e9b48=this['editor']['plugins']['get'](o),_0xac231a=this['editor']['config']['get']('collaboration.channelId');for(const _0x3ff64a of _0x4e9b48['getCommentThreads']({'channelId':_0xac231a}))_0x4e9b48['_detachCommentThread'](_0x3ff64a['id']),_0x4e9b48['_threads']['delete'](_0x3ff64a['id']);super['destroy']();}['hasMarkerForId'](_0x14bded){return this['getAllMarkersForId'](_0x14bded)['length']>0x0;}['getAllMarkersForId'](_0x4f3fbc){const _0x456cc6=[];for(const _0x1d903f of this['editor']['model']['markers'])_0x1d903f['name']['startsWith']('comment:'+_0x4f3fbc)&&_0x456cc6['push'](_0x1d903f);return _0x456cc6;}['scrollToThreadMarker'](_0x1304df){const _0x514d82=this['_getTargetForId'](_0x1304df);_0x514d82&&setTimeout(()=>{this['activeMarker']&&er(this['activeMarker'])['id']===_0x1304df&&rt({'target':_0x514d82[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x4a17d1){this['editor']['model']['change'](()=>{for(const _0x5e1e04 of this['getAllMarkersForId'](_0x4a17d1))this['editor']['editing']['reconvertMarker'](_0x5e1e04);});}['_attachArchivedThread'](_0x439f5a){const _0x512dd8=this['editor']['plugins']['get'](o),_0x3618b8=this['editor']['plugins']['get'](P),_0x360ec5=_0x512dd8['getCommentThread'](_0x439f5a);if(!_0x360ec5['isAttached']){const _0x10c9ff=_0x360ec5['attachTo'](()=>this['_getTargetForId'](_0x360ec5['id']));_0x3618b8['registerAnnotation'](_0x10c9ff),_0x360ec5['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x209dbc=this['editor'],_0x46bbc0=_0x209dbc['plugins']['get'](it);_0x209dbc['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x4f7cee,_0x26a3cd)=>{const {id:_0x5555c2}=er(_0x4f7cee['markerName']),_0x46c794=_0x209dbc['plugins']['get'](o)['getCommentThread'](_0x5555c2),_0x512527=this['activeMarker']&&er(this['activeMarker'])['id']===_0x5555c2;let _0x225edc;if(_0x46c794&&_0x46c794['isResolved']&&!_0x512527&&_0x4f7cee['item'])return _0x26a3cd['consumable']['consume'](_0x4f7cee['item'],'addMarker:'+_0x4f7cee['markerName']),_0x26a3cd['consumable']['consume'](_0x4f7cee['item'],'removeMarker:'+_0x4f7cee['markerName']),null;const _0xf3939f=['ck-comment-marker'];return _0x512527&&_0xf3939f['push']('ck-comment-marker--active'),_0x225edc=_0x46c794?.['length']?_0x46c794['comments']['first']['author']['id']:_0x46bbc0['me']['id'],{'classes':_0xf3939f,'attributes':{'data-comment':_0x5555c2,'data-author-id':_0x225edc}};}}),_0x209dbc['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x185446,{options:_0x4c9e81})=>{if(_0x4c9e81['showCommentHighlights'])return null;const _0x3b34f4=_0x209dbc['plugins']['get'](o),_0x701b3d=_0x209dbc['model']['markers']['get'](_0x185446),{id:_0x25e6f3,part:_0x1d7130}=er(_0x185446);return _0x701b3d&&!_0x701b3d['affectsData']||_0x4c9e81['ignoreResolvedComments']&&_0x3b34f4['getCommentThread'](_0x25e6f3)?.['isResolved']?null:{'group':'comment','name':_0x1d7130?_0x25e6f3+':'+_0x1d7130:_0x25e6f3};}}),_0x209dbc['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x39759d,{writer:_0x5728b7})=>_0x5728b7['createElement']('$marker',{'data-name':'comment:'+_0x39759d['getAttribute']('id')})}),_0x209dbc['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x180a90=this['editor'],_0xe11d67=_0x180a90['plugins']['get'](o),_0x59d9a6=new Set(),_0xc05aaa=new Set();_0x180a90['model']['document']['registerPostFixer'](_0xc9fb83=>{let _0x2cd94a=!0x1;for(const {name:_0x2b54bf,data:_0x17ba6c}of _0x180a90['model']['document']['differ']['getChangedMarkers']()){const {group:_0x26e9a4,id:_0x58cdae}=er(_0x2b54bf);let _0x59d2cf=_0x17ba6c['newRange'];if('comment'!==_0x26e9a4||!_0x59d2cf)continue;const _0x31f57f='$graveyard'===_0x59d2cf['root']['rootName'];_0x31f57f||(_0x59d2cf=dt(_0x59d2cf,_0x180a90['model']),!_0x59d2cf||_0x59d2cf['isCollapsed']||!_0x17ba6c['newRange']||_0x59d2cf['isEqual'](_0x17ba6c['newRange']))?_0x180a90['model']['hasContent'](_0x59d2cf)&&!_0x31f57f?this['isThreadsLoadingPaused']?_0x59d9a6['add'](_0x2b54bf):this['_handleThreadMarker'](_0x2b54bf,_0x58cdae):(_0xc05aaa['add'](_0x2b54bf),_0x59d9a6['delete'](_0x2b54bf),_0xc9fb83['removeMarker'](_0x2b54bf),_0x2cd94a=!0x0):(_0xc9fb83['updateMarker'](_0x2b54bf,{'range':_0x59d2cf}),_0x2cd94a=!0x0);}return _0x2cd94a;}),this['on']('change:isThreadsLoadingPaused',(_0x42a094,_0x2fd2b4,_0x2cfe47)=>{if(!_0x2cfe47&&_0x59d9a6['size'])for(const _0x33980f of _0x59d9a6){const {id:_0x48c376}=er(_0x33980f);_0x59d9a6['delete'](_0x33980f),_0x180a90['model']['markers']['get'](_0x33980f)&&this['_handleThreadMarker'](_0x33980f,_0x48c376);}}),this['listenTo'](_0x180a90['model']['document'],'change',()=>{for(const {name:_0xbd3c24,data:{newRange:_0x5dc32e}}of _0x180a90['model']['document']['differ']['getChangedMarkers']()){const {group:_0x327a1c,id:_0x59417e}=er(_0xbd3c24);if('comment'!==_0x327a1c)continue;const _0x3819c9=_0xe11d67['getCommentThread'](_0x59417e),_0x34382a=this['hasMarkerForId'](_0x59417e);_0x3819c9&&(!_0x3819c9['_hasTargetInContent']&&_0x5dc32e&&_0x180a90['editing']['view']['once']('render',()=>{const _0x364b6c=_0x180a90['plugins']['get'](O),_0x289af2=_0xe11d67['_threadToController']['get'](_0x3819c9)['view'];_0x364b6c['getByInnerView'](_0x289af2)['refreshVisibility']();},{'priority':'low'}),_0x3819c9['_hasTargetInContent']=_0x34382a||!!_0x5dc32e),_0x5dc32e||(_0xc05aaa['add'](_0xbd3c24),_0x59d9a6['delete'](_0xbd3c24));}for(const _0x103a5b of _0xc05aaa){const {id:_0x273590}=er(_0x103a5b),_0x517c91=_0xe11d67['getCommentThread'](_0x273590);if(_0x59d9a6['delete'](_0x103a5b),!_0x517c91)continue;const _0x45c868=this['hasMarkerForId'](_0x273590);_0x45c868||_0x517c91['isSubmitted']?_0x45c868||_0x517c91['unlinkedAt']||_0x517c91['setUnlinkedAt'](new Date()):_0x517c91['remove']();}_0xc05aaa['clear']();});}['_handleInitialThreads'](_0x2e65b1){_0x2e65b1['forEach'](_0x3a4276=>{_0x3a4276['unlinkedAt']&&this['_attachArchivedThread'](_0x3a4276['id']);});}['_getTargetForId'](_0x306064){const _0x15f251=this['editor'],_0x137488=this['getAllMarkersForId'](_0x306064);return et(_0x15f251['editing'],_0x137488);}['_getTextContext'](_0x1bff96){const _0x5b5ae4=this['getAllMarkersForId'](_0x1bff96);let _0x14b452='',_0x1a4db3=!0x1;for(const _0x70260f of _0x5b5ae4){const _0x1bd423=_0x70260f['getRange']();for(const _0x533a61 of Array['from'](_0x1bd423['getItems']()))_0x533a61['is']('$textProxy')?(_0x14b452&&_0x1a4db3&&(_0x14b452+='\x20',_0x1a4db3=!0x1),_0x14b452+=_0x533a61['data']):_0x1a4db3=!0x0;_0x1a4db3=!0x0;}return _0x14b452['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x1cb354,_0x209108){const _0x101711=this['editor'],_0x456543=_0x101711['plugins']['get'](o);let _0x36a65d=_0x456543['getCommentThread'](_0x209108);const _0x128105=_0x101711['config']['get']('collaboration.channelId'),_0xd673ba=_0x101711['plugins']['get'](P);if(_0x36a65d&&(_0x36a65d['unlinkedAt']&&_0x36a65d['setUnlinkedAt'](null),_0x36a65d['isAttached']))return _0x36a65d;return!this['getAllMarkersForId'](_0x209108)[0x0]['managedUsingOperations']?_0x101711['editing']['view']['once']('render',()=>{if(_0x456543['getCommentThread'](_0x209108))return;const _0x5092cb=_0x101711['plugins']['get'](O);_0x36a65d=_0x456543['openNewCommentThread']({'channelId':_0x128105,'threadId':_0x209108,'target':()=>this['_getTargetForId'](_0x209108),'context':{'type':'text','value':this['_getTextContext'](_0x209108)}});const _0x58bf3b=_0x456543['_threadToController']['get'](_0x36a65d)['view'],_0x36050f=_0x5092cb['getByInnerView'](_0x58bf3b);_0x36050f&&_0xd673ba['registerAnnotation'](_0x36050f);},{'priority':'low'}):_0x456543['fetchCommentThread']({'channelId':_0x128105,'threadId':_0x209108})['then'](_0x98ad=>{if('destroyed'!==_0x101711['state']){if(_0x36a65d=_0x98ad,_0x36a65d&&!_0x36a65d['isAttached']){const _0x2e7255=_0x36a65d['attachTo'](()=>this['_getTargetForId'](_0x209108));_0xd673ba['registerAnnotation'](_0x2e7255),_0x36a65d['isResolved']&&this['_reconvertMarkers'](_0x209108);}else{if(!_0x36a65d){const _0x4323c8=this['getAllMarkersForId'](_0x209108);_0x101711['model']['change'](_0x3c02f4=>{for(const _0x2430cb of _0x4323c8)_0x3c02f4['removeMarker'](_0x2430cb);});}}}}),_0x36a65d;}['_handleThreadMarker'](_0x2a8397,_0x316e8d){const _0x4f0613=this['_attachMarkerToThread'](_0x2a8397,_0x316e8d);_0x4f0613&&!_0x4f0613['context']&&_0x4f0613['setContext']({'type':'text','value':this['_getTextContext'](_0x316e8d)});}['_initAriaMarkerChangeAnnouncements'](){const _0x18ac51=this['editor'];ot(_0x18ac51['model'],({left:_0x52f1c9,entered:_0x5396c1})=>{for(const _0x20c4ce of _0x52f1c9)if(mt(_0x20c4ce)){_0x18ac51['ui']['ariaLiveAnnouncer']['announce'](E(_0x18ac51['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x23d443 of _0x5396c1)if(mt(_0x23d443)){_0x18ac51['ui']['ariaLiveAnnouncer']['announce'](E(_0x18ac51['locale'],'ENTER_COMMENT_ANNOUNCEMENT',nt(_0x5c669a)));break;}});}}function ft(_0x23bc0a,_0x4ad793){return _0x4ad793?_0x23bc0a+':'+_0x4ad793:_0x23bc0a;}function er(_0x141971){const _0x236901=_0x141971['split'](':');return{'group':_0x236901[0x0],'id':_0x236901[0x1],'part':_0x236901[0x2]};}function dt(_0x479afd,_0x2e66f0){const _0x1ef069=_0x2e66f0['schema'],_0x13d767=_0x2e66f0['createRange'](_0x479afd['start']);for(const _0x455801 of _0x479afd['getWalker']()){const {type:_0x7b6d37,item:_0x589f6e,nextPosition:_0x3f6510}=_0x455801;if('text'===_0x7b6d37||_0x1ef069['isObject'](_0x589f6e)){const _0x303456=_0x2e66f0['createPositionBefore'](_0x589f6e);_0x13d767['isCollapsed']&&(_0x13d767['start']=_0x303456),_0x13d767['end']=_0x3f6510;}}return _0x13d767;}function mt(_0x5392ea){return'comment'===er(_0x5392ea['name'])['group'];}class i extends _0x584d8b{['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 _0x45b8ee=this['editor'],_0x3ba555=_0x45b8ee['plugins']['get'](o),_0xf1b3b5=_0x45b8ee['plugins']['get'](r),_0x1bdc65=_0x45b8ee['plugins']['get'](O),_0x405bf2=_0x45b8ee['plugins']['get'](P);_0x45b8ee['ui']['componentFactory']['add']('comment',()=>{const _0x17e5c1=this['_createUIButton'](_0x9d10e1);return _0x17e5c1['tooltip']=!0x0,_0x17e5c1;}),_0x45b8ee['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x27809a)),_0x405bf2['addSourceCollector'](()=>{const _0x2d110d=[];for(const [_0x5d0ddf,_0xcd93f6]of _0x3ba555['_threadToController']){const _0x4446ea=_0xf1b3b5['getAllMarkersForId'](_0x5d0ddf['id']),_0x35f8a3=_0x4446ea['map'](_0x188076=>_0x188076['getRange']());_0x4446ea['length']>0x0&&_0x2d110d['push']([_0xcd93f6['view'],_0x35f8a3]);}return _0x2d110d;}),this['listenTo'](_0x1bdc65,'change:activeAnnotations',(_0x296c7d,_0x29e695,_0xa162e3)=>{const _0x19f831=Array['from'](_0xa162e3)['map'](_0x15f1a7=>_0x15f1a7['innerView'])['find'](_0x530f95=>_0x3ba555['_viewToController']['has'](_0x530f95));if(!_0x19f831)return void(_0xf1b3b5['activeMarker']=null);const _0x3484fa=_0x3ba555['_viewToController']['get'](_0x19f831)['model']['id'],_0x1aa90c='comment:'+_0x3484fa;_0x3484fa&&_0xf1b3b5['hasMarkerForId'](_0x3484fa)?_0xf1b3b5['activeMarker']=_0x1aa90c:_0xf1b3b5['activeMarker']&&(_0xf1b3b5['activeMarker']=null);}),this['listenTo'](_0x3ba555,'removeCommentThread',(_0x32978d,{threadId:_0x566f6b,isFromAdapter:_0x2da09f})=>{!_0x2da09f&&_0x45b8ee['ui']['focusTracker']['isFocused']&&_0xf1b3b5['hasMarkerForId'](_0x566f6b)&&_0x45b8ee['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x3ba555,'addComment',(_0x19bef3,{threadId:_0x3a8263,isFromAdapter:_0x32443f})=>{if(_0x32443f||!_0xf1b3b5['hasMarkerForId'](_0x3a8263)||!_0x3ba555['hasCommentThread'](_0x3a8263))return;0x1===_0x3ba555['getCommentThread'](_0x3a8263)['length']&&(_0x45b8ee['editing']['view']['focus'](),_0x19bef3['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3406fa=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2c611a;for(const _0x1f59fc in _0x3406fa){const _0x59881e=_0x1f59fc,_0x10b0a2=_0x3406fa[_0x59881e];if('commentsLicenseKeyValid'==_0x10b0a2||'commentsLicenseKeyInvalid'==_0x10b0a2||'commentsLicenseKeyExpired'==_0x10b0a2||'commentsLicenseKeyDomainLimit'==_0x10b0a2||'commentsLicenseKeyNotAllowed'==_0x10b0a2||'commentsLicenseKeyEvaluationLimit'==_0x10b0a2||'commentsLicenseKeyTrialLimit'==_0x10b0a2||'commentsLicenseKeyUsageLimit'==_0x10b0a2){delete _0x3406fa[_0x59881e],_0x2c611a=_0x10b0a2,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x2c611a&&_0x3406fa['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x2c611a&&_0x3406fa['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x2c611a&&_0x3406fa['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x2c611a&&_0x3406fa['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x2c611a&&_0x3406fa['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x2c611a&&_0x3406fa['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x2c611a&&_0x3406fa['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x3f63e2){const _0x1ca6da=this['editor'],_0x473d64=new _0x3f63e2(_0x1ca6da['locale']),_0x5a8ff7=_0x1ca6da['commands']['get']('addCommentThread');return _0x473d64['set']({'label':E(_0x1ca6da['locale'],'Comment'),'icon':_0x48cf2c}),_0x473d64['bind']('isEnabled')['to'](_0x5a8ff7),this['listenTo'](_0x473d64,'execute',()=>{_0x5a8ff7['execute']();}),_0x473d64;}}class s extends _0x584d8b{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x1e4c8a){super(_0x1e4c8a),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x1d679e,_0x5a90d0,_0x54d047)=>{_0x54d047?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x39e21d,_0x3e4716]of this['editor']['commands'])_0x3e4716['affectsData']&&'addCommentThread'!==_0x39e21d&&_0x3e4716['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 _0x1c1ad8=this['editor']['editing']['view']['document'];this['listenTo'](_0x1c1ad8,'cut',_0x2bb4a1=>_0x2bb4a1['stop'](),{'priority':'highest'}),this['listenTo'](_0x1c1ad8,'clipboardInput',_0x53c4ae=>_0x53c4ae['stop'](),{'priority':'highest'}),this['listenTo'](_0x1c1ad8,'delete',_0x564d2a=>_0x564d2a['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x4d6a00,_0x463425]of this['editor']['commands'])_0x463425['affectsData']&&'addCommentThread'!==_0x4d6a00&&_0x463425['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 _0x36b078{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[O];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x517681){super(_0x517681),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x265ca4=this['context']['plugins']['get'](O);this['listenTo'](_0x265ca4,'_activateAnnotation',(_0x1833a1,_0x455e3f)=>{for(const _0x501229 of this['activeUIs']){const _0x5f0bd5=this['_uis']['get'](_0x501229);(0x0,this['uisData']['get'](_0x501229)['filter'])(_0x455e3f)&&_0x5f0bd5['setActiveAnnotation'](_0x455e3f);}}),this['listenTo'](_0x265ca4,'_deactivateAllAnnotations',()=>{for(const _0x16ea01 of this['activeUIs']){this['_uis']['get'](_0x16ea01)['setActiveAnnotation'](null);}}),this['listenTo'](_0x265ca4['_visibleAnnotations'],'add',(_0x50131c,_0xafb8c7)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0xafb8c7);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x4980d8){return this['activeUIs']['has'](_0x4980d8);}['activate'](_0x10516b,_0x58b1f4=this['defaultFilter']){const _0x3116ac=this['context']['plugins']['get'](O);if(!this['_uis']['has'](_0x10516b))throw new _0x2a0e2d('annotationsuis-missing-ui',this,{'uiName':_0x10516b});this['isActive'](_0x10516b)&&this['deactivate'](_0x10516b),this['activeUIs']['add'](_0x10516b);const _0x254c75=new _();!function({source:_0x399b8c,target:_0x219da3,filter:_0x44e272}){for(const _0x55d8c5 of _0x399b8c)_0x44e272(_0x55d8c5)&&_0x219da3['add'](_0x55d8c5);_0x219da3['listenTo'](_0x399b8c,'add',(_0x2af4b2,_0x37b312)=>{_0x44e272(_0x37b312)&&_0x219da3['add'](_0x37b312);}),_0x219da3['listenTo'](_0x399b8c,'remove',(_0x38f127,_0x4a6f19)=>{_0x219da3['has'](_0x4a6f19)&&_0x219da3['remove'](_0x4a6f19);});}({'source':_0x3116ac['_visibleAnnotations'],'target':_0x254c75,'filter':_0x58b1f4}),this['uisData']['set'](_0x10516b,{'collection':_0x254c75,'filter':_0x58b1f4});const _0x2c0d1c=this['_uis']['get'](_0x10516b);_0x2c0d1c['attach'](_0x254c75),this['listenTo'](_0x2c0d1c,'change:activeAnnotation',(_0x85b3ec,_0x3108fd,_0x42cf3e,_0x1f8037)=>{_0x1f8037&&_0x3116ac['_removeActiveAnnotation'](_0x1f8037),_0x42cf3e&&_0x3116ac['_addActiveAnnotation'](_0x42cf3e);});}['deactivate'](_0x2391a0){if(this['activeUIs']['delete'](_0x2391a0),!this['_uis']['has'](_0x2391a0))throw new _0x2a0e2d('annotationsuis-missing-ui',this,{'uiName':_0x2391a0});const _0x5eaf0d=this['_uis']['get'](_0x2391a0);_0x5eaf0d['detach'](),this['stopListening'](_0x5eaf0d),this['uisData']['get'](_0x2391a0)['collection']['destroy'](),this['uisData']['delete'](_0x2391a0);}['switchTo'](_0x1377fe){if(!this['_uis']['has'](_0x1377fe))throw new _0x2a0e2d('annotationsuis-missing-ui',this,{'uiName':_0x1377fe});const _0x37e36d=this['context']['plugins']['get'](O),_0x473074=Array['from'](_0x37e36d['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x1377fe);const _0x432177=this['_uis']['get'](_0x1377fe);_0x432177['setActiveAnnotation'](_0x473074),_0x432177['_setSelectedAnnotations']&&_0x473074&&_0x432177['_setSelectedAnnotations']([_0x473074]);}['deactivateAll'](){for(const _0xd3a386 of this['activeUIs'])this['deactivate'](_0xd3a386);}['register'](_0x10e02e,_0xf5607d){if(this['_uis']['has'](_0x10e02e))throw new _0x2a0e2d('annotationsuis-register-already-registered');if('function'!=typeof _0xf5607d['attach']||'function'!=typeof _0xf5607d['detach']||'function'!=typeof _0xf5607d['setActiveAnnotation'])throw new _0x2a0e2d('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x10e02e,_0xf5607d);}['refilterAnnotations'](){const _0x345106=this['context']['plugins']['get'](O)['collection'],_0x259283=new Map(),_0x3d8502=Array['from'](this['activeUIs']);for(const _0x5a68bb of this['activeUIs']){const _0x3ea684=this['uisData']['get'](_0x5a68bb)['collection'];for(const _0xc158bc of _0x3ea684)_0x259283['set'](_0xc158bc,_0x5a68bb);}for(const _0x3c3e99 of _0x345106){const _0x4de652=_0x259283['get'](_0x3c3e99);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x3c3e99);const _0x17b5f0=_0x3d8502['find'](_0x5df785=>this['uisData']['get'](_0x5df785)['filter'](_0x3c3e99));_0x4de652!==_0x17b5f0&&(_0x4de652&&this['uisData']['get'](_0x4de652)['collection']['remove'](_0x3c3e99),_0x17b5f0&&this['uisData']['get'](_0x17b5f0)['collection']['add'](_0x3c3e99));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x1955bb){const _0x432172=[];for(const _0x1db4d0 of this['activeUIs']){(0x0,this['uisData']['get'](_0x1db4d0)['filter'])(_0x1955bb)&&_0x432172['push'](_0x1db4d0);}if(_0x432172['length']>0x1)throw new _0x2a0e2d('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x432172,'annotationType':_0x1955bb['type']});}}const pi=xt('px');class F extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x272fb4){super(_0x272fb4);const _0x68e66c=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 _0x35ba42(),this['focusCycler']=new _0x13e912({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x68e66c['to']('class')],'style':{'minHeight':_0x68e66c['to']('minHeight',_0x32bae9=>'number'==typeof _0x32bae9?pi(_0x32bae9+0xa):null)},'dir':_0x272fb4['uiLanguageDirection'],'role':'application','aria-label':E(_0x272fb4,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':E(_0x272fb4,'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',_0x106e48=>{this['_updateItemPositionInFocusables'](_0x106e48['source']);}),this['list']['forEach'](_0x64a709=>{this['focusTracker']['add'](_0x64a709['element']),this['_updateItemPositionInFocusables'](_0x64a709);}),this['list']['on']('change',(_0x147ddc,_0x468b43)=>{for(const _0x2cdbc5 of _0x468b43['removed'])this['focusTracker']['remove'](_0x2cdbc5['element']),this['focusables']['remove'](_0x2cdbc5);for(const _0x69ce11 of _0x468b43['added'])this['focusTracker']['add'](_0x69ce11['element']),this['_updateItemPositionInFocusables'](_0x69ce11);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x1ba70d){const _0x3ee811=this['focusables']['getIndex'](_0x1ba70d);let _0x535148,_0x23c584;for(const _0x343ec6 of this['focusables'])if(_0x1ba70d['top']<_0x343ec6['top']){_0x535148=_0x343ec6;break;}if(_0x23c584=_0x535148?this['focusables']['getIndex'](_0x535148):this['focusables']['length'],-0x1!==_0x3ee811){if(_0x3ee811===_0x23c584-0x1)return;this['focusables']['remove'](_0x1ba70d),_0x23c584=_0x535148?this['focusables']['getIndex'](_0x535148):this['focusables']['length'];}this['focusables']['add'](_0x1ba70d,_0x23c584);}}const Ht=xt('px');class H extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x585c5a){super(_0x585c5a),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x24b465,_0x128d9f)=>_0x24b465+_0x128d9f),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Lt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x30de82=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x30de82['to']('isAnimationDisabled',_0x294617=>_0x294617?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x30de82['to']('top',_0x460c65=>Ht(_0x460c65))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x63fb1d=this['element']['clientHeight'];_0x63fb1d&&(this['height']=_0x63fb1d);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x36b078{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x28a0b4){super(_0x28a0b4),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 _0x24ad07=this['context']['config']['get']('sidebar.container');_0x24ad07&&this['setContainer'](_0x24ad07);}['setContainer'](_0x2b4f30){if(!y(_0x2b4f30))throw new _0x2a0e2d('sidebar-setcontainer-invalid-element');this['container']=_0x2b4f30;}['_attachToContainer']({viewClass:_0x397f3b='',spaceBetweenItems:_0x261b29=0x19}={}){if(!y(this['container']))throw new _0x2a0e2d('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x397f3b,this['_spaceBetweenItems']=_0x261b29;}['rearrange']({removedAnnotation:_0x3a36c4,previousAnnotation:_0x5473cb,nextAnnotation:_0x216cb7}){const _0x2606d6=this['getSidebarItemView'](_0x3a36c4);this['view']['list']['remove'](_0x2606d6),this['_destroySidebarItemView'](_0x3a36c4),_0x5473cb&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x5473cb)),_0x216cb7&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x216cb7)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x58ba5e,activatedAnnotation:_0x6d7905,disableAnimationOnActivatedAnnotation:_0x471500}){if(this['_activeAnnotation']=_0x6d7905,_0x58ba5e){_0x58ba5e['isActive']=!0x1;const _0x5c96c6=this['getSidebarItemView'](_0x58ba5e);_0x5c96c6&&_0x471500&&(_0x5c96c6['isAnimationDisabled']=!0x1);}if(_0x6d7905){const _0x17856e=this['getSidebarItemView'](_0x6d7905);_0x17856e&&(_0x6d7905['isActive']=!0x0,_0x471500&&(_0x17856e['isAnimationDisabled']=!0x0,_0x17856e['top']+=0x1),this['_alignToTargetRect'](_0x17856e));}}['_detachFromContainer'](_0x1ae6a3){if(this['view']['element']['remove'](),_0x1ae6a3){for(const _0x38d455 of _0x1ae6a3)this['_destroySidebarItemView'](_0x38d455);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x3eaf42,_0x26b5dd){_0x26b5dd||(_0x26b5dd=_0x3eaf42['view']);const _0x40b4ad=new H(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x40b4ad,_0x3eaf42),this['_annotationToSidebarItemView']['set'](_0x3eaf42,_0x40b4ad),_0x40b4ad['content']['add'](_0x26b5dd),this['listenTo'](_0x3eaf42['view'],'change:targetRect',(_0x1f9c64,_0x499c14,_0x15c57b)=>{const _0x4138d1=this['_getTargetTop'](_0x3eaf42,_0x15c57b);_0x40b4ad['_targetTop']!=_0x4138d1&&(_0x40b4ad['_targetTop']=_0x4138d1,this['_setItemTop'](_0x40b4ad,_0x4138d1));}),this['listenTo'](_0x40b4ad,'change:top',()=>{this['_recalculate'](_0x40b4ad,'top');}),this['listenTo'](_0x40b4ad,'change:bottom',()=>{this['_recalculate'](_0x40b4ad,'bottom');}),this['_alignToTargetRect'](_0x40b4ad);const _0x86141d=this['_getItemBefore'](_0x40b4ad);if(_0x86141d)this['_alignAfterItem'](_0x86141d,_0x40b4ad)||this['_alignToTargetRect'](_0x40b4ad);else this['_alignToTargetRect'](_0x40b4ad);return this['_updateLastItem'](),this['view']['list']['add'](_0x40b4ad),_0x40b4ad;}['_alignForTopChange'](_0x301d7c){if(!_0x301d7c['content']['length'])return;const _0x42e353=this['_getItemBefore'](_0x301d7c);if(!_0x42e353)return;const _0x45b957=this['_sidebarItemViewToAnnotation']['get'](_0x42e353),_0x389cbc=this['_activeAnnotation'];_0x389cbc&&_0x389cbc===_0x45b957?this['_alignAfterItem'](_0x42e353,_0x301d7c):this['_alignBeforeItem'](_0x301d7c,_0x42e353);}['_alignForBottomChange'](_0x30c5ba){if(!_0x30c5ba['content']['length'])return;const _0x3d3292=this['_getItemAfter'](_0x30c5ba);if(!_0x3d3292)return;const _0x520936=this['_sidebarItemViewToAnnotation']['get'](_0x3d3292),_0x28563a=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x37e0f2=this['_activeAnnotation'];_0x37e0f2&&_0x37e0f2===_0x520936&&_0x28563a?(this['_alignBeforeItem'](_0x3d3292,_0x30c5ba),this['_alignAfterItem'](_0x30c5ba,_0x3d3292)):_0x37e0f2&&_0x37e0f2===_0x520936?this['_alignBeforeItem'](_0x3d3292,_0x30c5ba):this['_alignAfterItem'](_0x30c5ba,_0x3d3292);}['_recalculate'](_0x105ec2,_0x125a60){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x4d31f1,changedProp:_0x36c464}of this['_recalculateBuffer'])'top'===_0x36c464?this['_alignForTopChange'](_0x4d31f1):this['_alignForBottomChange'](_0x4d31f1);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x105ec2,'changedProp':_0x125a60});}['getSidebarItemView'](_0x3c6865){return this['_annotationToSidebarItemView']['get'](_0x3c6865);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x19dbcc){const _0x550a1e=this['getSidebarItemView'](_0x19dbcc);this['stopListening'](_0x550a1e),this['stopListening'](_0x19dbcc['view']),_0x550a1e['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x19dbcc),this['_sidebarItemViewToAnnotation']['delete'](_0x550a1e);}['_createSidebarView'](){const _0xbbdbae=new F(this['context']['locale']);return _0xbbdbae['render'](),this['on']('change:_lastItem',(_0x5d6f2b,_0x44cfbd,_0x2892b8,_0x12c955)=>{_0x12c955&&_0xbbdbae['unbind']('minHeight'),_0x2892b8?_0xbbdbae['bind']('minHeight')['to'](_0x2892b8,'bottom'):_0xbbdbae['minHeight']=null;}),_0xbbdbae;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x4be206){const _0x2b2c75=this['_sidebarItemViewToAnnotation']['get'](_0x4be206),_0x19ee49=_0x2b2c75&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x2b2c75)-0x1);return _0x19ee49&&this['getSidebarItemView'](_0x19ee49)||null;}['_getItemAfter'](_0x46b2a0){const _0x46ff6a=this['_sidebarItemViewToAnnotation']['get'](_0x46b2a0),_0x3f382f=_0x46ff6a&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x46ff6a)+0x1);return _0x3f382f&&this['getSidebarItemView'](_0x3f382f)||null;}['_alignBeforeItem'](_0x1ee379,_0xe1f784){_0x1ee379['updateHeight']();const _0x385c30=R(_0xe1f784['bottom']+this['_spaceBetweenItems'],_0x1ee379['top']);return!!_0x385c30&&(this['_setItemTop'](_0xe1f784,_0xe1f784['top']-_0x385c30),!0x0);}['_alignAfterItem'](_0x53bfe9,_0x27e1ca){_0x53bfe9['updateHeight']();const _0x3ef3ae=R(_0x53bfe9['bottom']+this['_spaceBetweenItems'],_0x27e1ca['top']);return!!_0x3ef3ae&&(this['_setItemTop'](_0x27e1ca,_0x27e1ca['top']+_0x3ef3ae,!0x1),!0x0);}['_alignToTargetRect'](_0x535af8){const _0x3cde86=this['_sidebarItemViewToAnnotation']['get'](_0x535af8);if(!_0x3cde86||!_0x3cde86['target']||!_0x3cde86['targetRect'])return;const _0x1080d1=this['_getTargetTop'](_0x3cde86,_0x3cde86['targetRect']);this['_setItemTop'](_0x535af8,_0x1080d1);}['_getTargetTop'](_0x1ece87,_0x5514f2){if(null===_0x5514f2)return 0x0;if(_0x1ece87['target']instanceof _0x40616d)return _0x5514f2['top'];{const _0x1b771e=new _0x40616d(this['view']['element'])['top'];return _0x5514f2['top']-_0x1b771e;}}['_setItemTop'](_0x5ccd77,_0x4a4918,_0x532b28=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x532b28&&(_0x4a4918=Math['max'](_0x4a4918,this['_getMaxAvailableTop'](_0x5ccd77))),_0x5ccd77['top']=_0x4a4918;}['_getMaxAvailableTop'](_0x7bc4cc){let _0x29a37a=this['_getItemBefore'](_0x7bc4cc),_0x3f9b3f=0x0;for(;_0x29a37a;)_0x29a37a['updateHeight'](),_0x3f9b3f+=this['_spaceBetweenItems']+_0x29a37a['height'],_0x29a37a=this['_getItemBefore'](_0x29a37a);return _0x3f9b3f;}}function R(_0x13c649,_0xf5d357){return Math['max'](_0x13c649-_0xf5d357,0x0);}function y(_0x34738a){return null!==_0x34738a&&'object'==typeof _0x34738a&&0x1===_0x34738a['nodeType'];}class e extends _0x36b078{['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(_0x4f5f34){super(_0x4f5f34),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x3ea071(),this['_refreshPositioningDebounced']=_0x6e87ff(()=>{this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x95c1f7=this['context']['plugins']['get'](M),_0x488454=this['context']['plugins']['get'](z);_0x95c1f7['register']('wideSidebar',this),_0x488454['container']&&_0x95c1f7['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x213747){if(_0x213747===this['activeAnnotation'])return;const _0x47554e=this['context']['plugins']['get'](z);_0x47554e['_activeAnnotation']=_0x213747;const _0x2806f1=this['activeAnnotation'];_0x47554e['refresh']({'blurredAnnotation':_0x2806f1,'activatedAnnotation':_0x213747}),this['activeAnnotation']=_0x213747;}['attach'](_0x421ace){this['annotations']=_0x421ace;const _0x4fb359=this['context']['plugins']['get'](z);if(_0x4fb359['_annotations']=_0x421ace,this['isAttached'])throw new _0x2a0e2d('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x4fb359,'set:container',()=>{this['detach'](),this['listenTo'](_0x4fb359,'change:container',_0x26445e=>{_0x26445e['off'](),this['attach'](_0x421ace);});}),_0x4fb359['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x4096a7=_0x4cf175=>{_0x4cf175['updateTargetRect'](),_0x4fb359['addAnnotation'](_0x4cf175);};for(const _0x312196 of _0x421ace)_0x4096a7(_0x312196);this['listenTo'](_0x421ace,'add',(_0x44c8d9,_0x573643)=>{_0x4096a7(_0x573643);}),this['listenTo'](_0x421ace,'remove',(_0x5a6d7d,_0x99a1f2,_0xba823b)=>{_0x4fb359['rearrange']({'removedAnnotation':_0x99a1f2,'previousAnnotation':_0x421ace['get'](_0xba823b-0x1),'nextAnnotation':_0x421ace['get'](_0xba823b+0x1)}),_0x99a1f2===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x421ace,'focus',(_0x3c9d09,_0x4245df)=>{this['setActiveAnnotation'](_0x4245df);}),this['listenTo'](_0x421ace,'blur',()=>{this['setActiveAnnotation'](null);});const _0x50091d=this['context']instanceof _0x546a23?this['context']['editors']:new _0x3ea071([this['context']]);for(const _0x156649 of _0x50091d)this['_integrateWithEditorAnnotations'](_0x156649);this['listenTo'](_0x50091d,'add',(_0x158be5,_0x3d6adc)=>{this['listenTo'](_0x3d6adc,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x3d6adc);});}),this['listenTo'](_0x50091d,'remove',(_0x195c5c,_0x33b34b)=>{_0x33b34b['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x33b34b['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x2a0e2d('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x53e03f=this['context']['plugins']['get'](z);_0x53e03f['_detachFromContainer'](this['annotations']),this['stopListening'](_0x53e03f),this['stopListening'](this['annotations']),this['context']instanceof _0x546a23&&this['stopListening'](this['context']['editors']);for(const _0x7d761c of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x7d761c);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x1d9b5c){if(!_0x1d9b5c['plugins']['has']('EditorAnnotations'))return;const _0x3fc6da=_0x1d9b5c['plugins']['get']('EditorAnnotations'),_0x4f03dc=()=>{const _0x25ab23=_0x3fc6da['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x25ab23[0x0]||null);};this['listenTo'](_0x3fc6da,'refresh',_0x4f03dc),this['listenTo'](_0x3fc6da,'blur',(_0x5d9243,{isAnnotationTracked:_0x4b6a50})=>{this['activeAnnotation']&&_0x4b6a50(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x3fc6da,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0xc8ec3b=>{_0x3fc6da['hasDomSelection']()&&(_0x4f03dc(),_0xc8ec3b['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x3fc6da);}['_destroyEditorAnnotationsIntegration'](_0x32faaa){this['stopListening'](_0x32faaa),this['_editorAnnotations']['remove'](_0x32faaa);}}class C extends _0x9d10e1{['counterView'];constructor(_0xf3fbdc){super(_0xf3fbdc);const _0x4861e1=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x50a2da,_0x26896d)=>_0x50a2da?'...':_0x26896d['toString']()),this['set']('annotationType',''),this['icon']=_0x48cf2c,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x4861e1['to']('annotationType',_0x3d3733=>'ck-annotation-counter__badge--'+_0x3d3733),_0x4861e1['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x4861e1['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x36b078{['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(_0x2b07ca){super(_0x2b07ca),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=Object['create'](_0xfc451c),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x3ea071(),this['_refreshPositioningDebounced']=_0x6e87ff(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](M)['register']('narrowSidebar',this),this['bodyCollection']=new _0x54a758(this['context']['locale']),this['balloonPanelView']=new _0x222632(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0xd8e058){this['annotations']=_0xd8e058;const _0x1534fa=this['context']['plugins']['get'](z),_0x4e5c8d=this['balloonPanelView'];if(_0x1534fa['_annotations']=_0xd8e058,this['isAttached'])throw new _0x2a0e2d('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x1534fa,'set:container',()=>{this['detach'](),this['listenTo'](_0x1534fa,'change:container',_0x3778ed=>{_0x3778ed['off'](),this['attach'](_0xd8e058);});}),_0x1534fa['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0xde923f=_0x4552c1=>{const _0x12e7a4=new C(this['context']['locale']);_0x1534fa['addAnnotation'](_0x4552c1,_0x12e7a4),this['_annotationToNarrowView']['set'](_0x4552c1,_0x12e7a4),_0x12e7a4['bind']('isDirty','annotationType','number')['to'](_0x4552c1['view'],'isDirty','type','length'),_0x12e7a4['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x4e5c8d['content']['first']!==_0x4552c1['view']?(this['_showBalloon'](_0x4552c1),_0x4552c1['view']['element']['focus'](),this['setActiveAnnotation'](_0x4552c1)):this['setActiveAnnotation'](null);});};for(const _0x5d0fd5 of _0xd8e058)_0xde923f(_0x5d0fd5);this['listenTo'](_0xd8e058,'add',(_0x4b8113,_0x590e61)=>{_0xde923f(_0x590e61);}),this['listenTo'](_0xd8e058,'remove',(_0xba4527,_0x488cd8,_0x487d4a)=>{this['_annotationToNarrowView']['get'](_0x488cd8)['destroy'](),this['_annotationToNarrowView']['delete'](_0x488cd8),_0x1534fa['rearrange']({'removedAnnotation':_0x488cd8,'previousAnnotation':_0xd8e058['get'](_0x487d4a-0x1),'nextAnnotation':_0xd8e058['get'](_0x487d4a+0x1)}),_0x488cd8===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0xd8e058,'focus',(_0x25dc66,_0xa50dee)=>{this['setActiveAnnotation'](_0xa50dee);}),this['listenTo'](_0xd8e058,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x5c3a7c,_0x4dba43)=>{_0x4dba43['keyCode']===_0xa4c8b7['esc']&&_0x4e5c8d['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x4e5c8d['content']['first']),this['_hideBalloon'](),_0x4dba43['stopPropagation'](),_0x4dba43['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x41aeeb,_0x542b41)=>{const _0x42b2eb=_0x542b41['target'];_0x4e5c8d['isVisible']&&_0x4e5c8d['element']['contains'](_0x42b2eb)||_0x1534fa['view']['element']['contains'](_0x42b2eb)||_0x41aeeb['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0xa39f71=>_0xa39f71['contains'](_0x42b2eb))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x6ffb87=this['context']instanceof _0x546a23?this['context']['editors']:new _0x3ea071([this['context']]);for(const _0x1b2893 of _0x6ffb87)this['_integrateWithEditorAnnotations'](_0x1b2893);this['listenTo'](_0x6ffb87,'add',(_0x2c19e8,_0x175345)=>{this['listenTo'](_0x175345,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x175345);});}),this['listenTo'](_0x6ffb87,'remove',(_0x5e4d00,_0x4e78c6)=>{_0x4e78c6['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x4e78c6['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x49fda8){if(_0x49fda8===this['activeAnnotation'])return;const _0x56c3b7=this['context']['plugins']['get'](z);if(_0x56c3b7['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x49fda8,'disableAnimationOnActivatedAnnotation':!0x0}),_0x49fda8)_0x56c3b7['getSidebarItemView'](_0x49fda8)?this['_showBalloon'](_0x49fda8):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x49fda8;}['detach'](){if(!this['isAttached'])throw new _0x2a0e2d('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x52e649=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0xaf44d9=>_0xaf44d9['destroy']()),this['_annotationToNarrowView']['clear'](),_0x52e649['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x546a23&&this['stopListening'](this['context']['editors']);for(const _0x8283e7 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x8283e7);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'](_0x488381){if(!_0x488381['plugins']['has']('EditorAnnotations'))return;const _0x51c5d5=_0x488381['plugins']['get']('EditorAnnotations'),_0x2a6567=this['context']['plugins']['get'](z),_0x2bb56b=this['annotations'],_0x14f4d3=this['balloonPanelView'],_0x100844=()=>{const _0x4fffa1=_0x51c5d5['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x4fffa1),this['setActiveAnnotation'](_0x4fffa1[0x0]||null);};this['listenTo'](_0x51c5d5,'refresh',_0x100844),this['listenTo'](_0x51c5d5,'blur',(_0x130955,{isAnnotationTracked:_0x28a45f})=>{this['activeAnnotation']&&_0x28a45f(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x51c5d5,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x2bb56b,'blur',_0x21b8fd=>{_0x51c5d5['hasDomSelection']()&&_0x21b8fd['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0xeb6b07,_0x5169e3)=>{const _0x11f97b=_0x5169e3['target'];_0x14f4d3['isVisible']&&_0x14f4d3['element']['contains'](_0x11f97b)||_0x2a6567['view']['element']['contains'](_0x11f97b)||this['activeAnnotation']&&_0x51c5d5['hasDomSelection']()&&(_0x100844(),_0xeb6b07['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x51c5d5);}['_destroyEditorAnnotationsIntegration'](_0x4eeaaa){_0x4eeaaa&&(this['stopListening'](_0x4eeaaa),this['_editorAnnotations']['remove'](_0x4eeaaa));}['_setSelectedAnnotations'](_0x196ef1){for(const _0x1f0d37 of this['_selectedAnnotations'])_0x196ef1['includes'](_0x1f0d37)||this['_manuallyClosedAnnotationViews']['delete'](_0x1f0d37['view']);this['_selectedAnnotations']=_0x196ef1;}['_refreshPositioning'](){const _0x7ee7aa=this['balloonPanelView'];this['annotations']['refreshPositioning'](),_0x7ee7aa['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x479933){if(this['_manuallyClosedAnnotationViews']['has'](_0x479933['view']))return;const _0x3c7b9b=this['balloonPanelView']['content']['first'];_0x3c7b9b!==_0x479933['view']?(_0x3c7b9b&&this['_detachListeners'](_0x3c7b9b),this['_attachListeners'](_0x479933['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x479933['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x597af3=this['balloonPanelView']['content']['first'],_0x50d5cb=_0x597af3&&this['annotations']['getByView'](_0x597af3);if(!_0x50d5cb||!this['_annotationToNarrowView']['has'](_0x50d5cb))return;const _0x272b60=this['_annotationToNarrowView']['get'](_0x50d5cb)['element'],_0x13f943=(function(){const _0x37b42f=_0x222632['defaultPositions'];return[_0x37b42f['southArrowNorthEast'],_0x37b42f['northArrowSouthEast'],_0x37b42f['southArrowNorth'],_0x37b42f['northArrowSouth'],_0x37b42f['southArrowNorthWest'],_0x37b42f['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x272b60,'positions':_0x13f943});}['_hideBalloon'](){const _0x69b401=this['balloonPanelView'],_0x166e67=_0x69b401['content']['first'];_0x166e67&&(this['_detachListeners'](_0x166e67),_0x69b401['unpin'](),_0x69b401['content']['clear']());}['_attachListeners'](_0x3bb70f){this['listenTo'](_0x3bb70f,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x3bb70f,'Esc',(_0x872c30,_0x546549)=>{this['_manuallyClosedAnnotationViews']['add'](_0x3bb70f),this['_hideBalloon'](),_0x546549();});}['_detachListeners'](_0x141581){this['stopListening'](_0x141581);}}class c extends _0x584d8b{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[P,_0x42ea7c,M];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x14ca4c){super(_0x14ca4c),_0x14ca4c['editing']['view']['addObserver'](_0x31f65c),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x14ca4c['plugins']['get'](_0x42ea7c),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x4636b1=this['editor']['plugins']['get'](M);_0x4636b1['context']===this['editor']&&(_0x4636b1['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x2d5045,_0x1272fa)=>{const _0x5bc158=this['_balloon'];if(this['isAttached']&&_0x5bc158['visibleView']){const _0x124610=this['annotations']['getByView'](_0x5bc158['visibleView']);_0x124610&&this['_closeAnnotation'](_0x124610),_0x1272fa();}}));}['afterInit'](){const _0x4fcd8d=this['editor']['plugins']['get'](M);_0x4fcd8d['context']===this['editor']&&(_0x4fcd8d['hasActive']()||_0x4fcd8d['switchTo']('inline'));}['setActiveAnnotation'](_0x36a234){_0x36a234!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x36a234&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x36a234)&&this['_addAnnotationToBalloon'](_0x36a234,!0x0),_0x36a234['isActive']=!0x0),_0x36a234||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x36a234);}['attach'](_0x3bac19){this['annotations']=_0x3bac19;const _0xe27051=this['editor']['plugins']['get'](M),_0x4f1260=this['_balloon'];if(this['isAttached'])throw new _0x2a0e2d('inlineannotations-attach-already-attached',this);if(_0xe27051['context']!==this['editor'])throw new _0x2a0e2d('inlineannotations-not-allowed-with-context',this);const _0x28dcb8=this['editor']['plugins']['get'](P);this['listenTo'](_0x28dcb8,'refresh',()=>{const _0x4b423d=_0x28dcb8['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x3f2fa5,_0x29d905;!this['_forceRefresh']&&(_0x3f2fa5=_0x4b423d,_0x29d905=this['_selectedAnnotations'],_0x3f2fa5['length']===_0x29d905['length']&&_0x3f2fa5['every'](_0x56289b=>_0x29d905['includes'](_0x56289b)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x4b423d),this['setActiveAnnotation'](_0x4b423d[0x0]||null));}),this['listenTo'](_0x28dcb8,'blur',(_0x496472,{isAnnotationTracked:_0x4adcd8})=>{this['activeAnnotation']&&_0x4adcd8(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x1bc4a0,_0x16bd0a,_0x1272e9)=>{_0x1272e9||this['setActiveAnnotation'](null);}),this['listenTo'](_0x3bac19,'remove',(_0x5aa0c6,_0x36652a)=>{this['_removeAnnotationFromBalloon'](_0x36652a),_0x36652a===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x4f1260,'change:visibleView',(_0x2bf352,_0x3c779c,_0x38d7b8,_0xc1d444)=>{_0xc1d444&&this['stopListening'](_0xc1d444);const _0x100c85=_0x3bac19['getByView'](_0x38d7b8);_0x38d7b8&&_0x100c85&&(this['listenTo'](_0x38d7b8,'change:height',()=>{_0x4f1260['updatePosition']();}),this['listenTo'](_0x38d7b8,'Esc',()=>{this['_closeAnnotation'](_0x100c85),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x100c85&&this['setActiveAnnotation'](_0x100c85));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x4f1260['visibleView']&&(_0x3bac19['getByView'](_0x4f1260['visibleView'])&&_0x4f1260['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 _0x2a0e2d('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x51ed15 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x51ed15);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x12bcbe){for(const _0x4a5415 of this['_selectedAnnotations'])_0x12bcbe['includes'](_0x4a5415)||this['_manuallyClosed']['delete'](_0x4a5415);for(const _0x1b8031 of this['annotations'])_0x12bcbe['includes'](_0x1b8031)||this['_removeAnnotationFromBalloon'](_0x1b8031);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x32facb of _0x12bcbe)this['_addAnnotationToBalloon'](_0x32facb);}this['_selectedAnnotations']=_0x12bcbe;}['_addAnnotationToBalloon'](_0x5acf82,_0x42c0ef=!0x1){this['_manuallyClosed']['has'](_0x5acf82)||(this['_addedAnnotations']['has'](_0x5acf82)||this['_balloon']['hasView'](_0x5acf82['view'])||(this['_addedAnnotations']['add'](_0x5acf82),this['_balloon']['add']({'stackId':_0x5acf82['view']['id'],'view':_0x5acf82['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x5acf82)}})),_0x42c0ef&&this['_balloon']['showStack'](_0x5acf82['view']['id']));}['_getBalloonTargetForAnnotation'](_0x28ad20){const _0x1493bf=_0x28ad20['target'],_0x4519b6=this['editor']['editing']['view'],_0x58558d=_0x4519b6['document']['selection']['getFirstRange'](),_0x53bf71=_0x4519b6['domConverter']['viewRangeToDom'](_0x58558d);if(_0x53bf71['collapse'](!0x0),_0x1493bf){if(_0x1493bf instanceof _0x40616d)return _0x1493bf;let _0x3cd5dd=[];for(const _0x5a9a83 of _0x1493bf)_0x3cd5dd['push'](...(_0x409bdd=_0x5a9a83['getClientRects'](),Array['from'](_0x409bdd)['map'](DOMRect['fromRect'])));_0x3cd5dd=function(_0x22941f){const _0x3cb3b1=[];let _0x4d8875=_0x22941f[0x0];for(let _0x1bd78f=0x1;_0x1bd78f<_0x22941f['length'];_0x1bd78f++)B(_0x4d8875,_0x22941f[_0x1bd78f])?_0x4d8875['width']+=_0x22941f[_0x1bd78f]['width']:(_0x3cb3b1['push'](_0x4d8875),_0x4d8875=_0x22941f[_0x1bd78f]);return _0x3cb3b1['push'](_0x4d8875),_0x3cb3b1;}(_0x3cd5dd);const _0x377e10=_0x53bf71['getBoundingClientRect']();return _0x3cd5dd['find'](_0x4e2996=>_0x4e2996['top']<=_0x377e10['top']&&_0x4e2996['bottom']>=_0x377e10['bottom']&&_0x4e2996['left']<=_0x377e10['left']&&_0x4e2996['right']>=_0x377e10['right'])||_0x3cd5dd[0x0];}var _0x409bdd;return _0x28ad20['targetRect']||_0x53bf71;}['_removeAnnotationFromBalloon'](_0x2af909){this['_addedAnnotations']['has'](_0x2af909)&&this['_balloon']['hasView'](_0x2af909['view'])&&(this['_addedAnnotations']['delete'](_0x2af909),this['_balloon']['remove'](_0x2af909['view']));}['_closeAnnotation'](_0x2d70ad){this['_manuallyClosed']['add'](_0x2d70ad),this['_removeAnnotationFromBalloon'](_0x2d70ad);}}function B(_0x5c1c5d,_0x370b89){return _0x5c1c5d['top']===_0x370b89['top']&&_0x5c1c5d['bottom']===_0x370b89['bottom']&&_0x5c1c5d['right']===_0x370b89['left'];}class tt extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x2c0f93,_0x400528){super(_0x2c0f93),this['set']('isEmpty',!_0x400528['length']),this['focusTracker']=new _0x35ba42(),this['_annotationViews']=_0x400528,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x13e912({'focusables':_0x400528,'focusTracker':this['focusTracker']}),this['listenTo'](_0x400528,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x400528,'remove',(_0x542985,_0x2cc01d)=>{_0x2cc01d['isActive']&&this['focus'](),_0x400528['length']||(this['isEmpty']=!0x0);});const _0x3d1350=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':E(_0x2c0f93,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x400528},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x3d1350['if']('isEmpty','ck-hidden',_0x423168=>!_0x423168)]},'children':[{'text':E(_0x2c0f93,'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 _0x476647 of this['_annotationViews'])this['focusTracker']['add'](_0x476647['element']);this['_annotationViews']['on']('change',(_0x48f71c,{added:_0xc74efd,removed:_0xa5c879})=>{for(const _0x4304fc of _0xc74efd)this['focusTracker']['add'](_0x4304fc['element']);for(const _0x22f96f of _0xa5c879)this['focusTracker']['remove'](_0x22f96f['element']);});}}class f extends _0x36b078{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,O];}constructor(_0xc5092c){super(_0xc5092c),this['archivedThreads']=new _0x3ea071();}['init'](){const _0x5e7386=this['context'],_0x50f9a4=_0x5e7386['plugins']['get'](o),_0x4eb59b=_0x5e7386['plugins']['get'](O);this['listenTo'](_0x50f9a4,'addCommentThread',(_0x335501,{threadId:_0x5079c5})=>{const _0xf70cd5=_0x50f9a4['getCommentThread'](_0x5079c5);_0xf70cd5['archivedAt']&&this['archivedThreads']['add'](_0xf70cd5,this['_calculatePosition'](_0xf70cd5['archivedAt'])),this['listenTo'](_0xf70cd5,'change:archivedAt',(_0x38a215,_0x2ebe95,_0x46b829)=>{_0x46b829?this['archivedThreads']['has'](_0xf70cd5)||this['archivedThreads']['add'](_0xf70cd5,this['_calculatePosition'](_0xf70cd5['archivedAt'])):this['archivedThreads']['has'](_0xf70cd5)&&this['archivedThreads']['remove'](_0xf70cd5);});}),this['listenTo'](_0x50f9a4,'removeCommentThread',(_0x375db0,{threadId:_0x4ef15d})=>{const _0x5b5e07=_0x50f9a4['getCommentThread'](_0x4ef15d);this['stopListening'](_0x5b5e07),this['archivedThreads']['has'](_0x5b5e07)&&this['archivedThreads']['remove'](_0x5b5e07);},{'priority':'highest'}),this['listenTo'](_0x4eb59b['collection'],'focus',(_0x246e3e,_0x2fa28b)=>{_0x2fa28b['isVisible']||(_0x2fa28b['isActive']=!0x0,_0x4eb59b['activate'](_0x2fa28b));});}['_calculatePosition'](_0x1fc047){const _0x3b9ed6=[...this['archivedThreads']]['findIndex'](_0xa9329d=>_0xa9329d['archivedAt']<_0x1fc047);return _0x3b9ed6>-0x1?_0x3b9ed6:this['archivedThreads']['length'];}}class a extends _0x584d8b{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[f,_0x1b29cc];}constructor(_0x57d22a){super(_0x57d22a),this['annotationViews']=new _0x291d35(),this['_pendingThreads']=[];}['init'](){const _0x593e2b=this['editor'],_0x8d3b8a=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x593e2b['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x9d10e1,!0x0)),_0x593e2b['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0xba94e1=this['_createCommentsArchiveButton'](_0x27809a);return _0xba94e1['set']({'role':'menuitemcheckbox'}),_0xba94e1;});const _0x77fa61=_0x593e2b['plugins']['get'](f),_0x578808=_0x593e2b['plugins']['get']('Annotations'),_0x176a7b=_0x593e2b['plugins']['get']('CommentsRepository');_0x77fa61['archivedThreads']['forEach'](_0x118da4=>{this['_handleNewThread'](_0x118da4);}),this['listenTo'](_0x77fa61['archivedThreads'],'add',(_0x397e6d,_0x27915a)=>{this['_handleNewThread'](_0x27915a);}),this['listenTo'](_0x578808['collection'],'add',(_0x2d1357,_0x362618)=>{const _0x3743e0=this['_pendingThreads']['find'](_0x1a4641=>{const _0x294748=_0x176a7b['_threadToController']['get'](_0x1a4641);return _0x294748&&_0x362618['innerView']===_0x294748['view'];});if(_0x3743e0){const _0x39b0f5=this['_calculatePosition'](_0x3743e0['archivedAt']);this['annotationViews']['add'](_0x362618['view'],_0x39b0f5),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x3743e0),0x1);}}),this['listenTo'](_0x77fa61['archivedThreads'],'remove',(_0xee131c,_0x1f5ad0)=>{const _0x554b42=_0x593e2b['config']['get']('collaboration.channelId');if(!_0x554b42||_0x1f5ad0['channelId']===_0x554b42){if(this['_pendingThreads']['includes'](_0x1f5ad0))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x1f5ad0),0x1);else{const _0x40e0cf=_0x176a7b['_threadToController']['get'](_0x1f5ad0),_0x5cc55f=_0x578808['getByInnerView'](_0x40e0cf['view']);this['annotationViews']['remove'](_0x5cc55f['view']),this['stopListening'](_0x5cc55f['focusableElements']);}}}),this['listenTo'](_0x578808['collection'],'add',(_0x131544,_0x5bdaa1)=>{this['listenTo'](_0x5bdaa1,'escape',_0x8d3b8a);}),this['listenTo'](_0x578808['collection'],'remove',(_0x33526a,_0x94de5f)=>{this['stopListening'](_0x94de5f,'escape',_0x8d3b8a);});}['_handleNewThread'](_0x2303c7){const _0x550562=this['editor']['plugins']['get']('CommentsRepository'),_0x14f2da=this['editor']['plugins']['get']('Annotations'),_0x823dbd=this['editor']['config']['get']('collaboration.channelId');if(!_0x823dbd||_0x2303c7['channelId']===_0x823dbd){const _0x489391=_0x550562['_threadToController']['get'](_0x2303c7);if(!_0x489391)return void this['_pendingThreads']['push'](_0x2303c7);const _0x6c7c87=this['_calculatePosition'](_0x2303c7['archivedAt']),_0x41875d=_0x14f2da['getByInnerView'](_0x489391['view']);_0x41875d['isVisible']&&_0x14f2da['_visibleAnnotations']['remove'](_0x41875d),this['annotationViews']['add'](_0x41875d['view'],_0x6c7c87);}}['_calculatePosition'](_0x312a44){const _0x441943=this['editor']['config']['get']('collaboration.channelId'),_0x5d30de=[...this['editor']['plugins']['get'](f)['archivedThreads']]['filter'](_0x2121e6=>_0x2121e6['channelId']===_0x441943)['findIndex'](_0x5d3a7a=>_0x5d3a7a['archivedAt']<_0x312a44);return _0x5d30de<0x0||_0x5d30de>this['annotationViews']['length']?this['annotationViews']['length']:_0x5d30de-0x1;}['_toggleDialog'](){const _0x447bb3=this['editor'],_0x324652=_0x447bb3['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new tt(_0x447bb3['locale'],this['annotationViews'])),'commentsArchive'===_0x324652['id']?_0x324652['hide']():_0x324652['show']({'id':'commentsArchive','title':E(_0x447bb3['locale'],'COMMENTS_ARCHIVE'),'icon':_0x58018f,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x15f97d['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x2c4301,_0x30b9d3=!0x1){const _0x4d6739=this['editor']['locale'],_0x38aabe=this['editor']['plugins']['get']('Dialog'),_0x35db09=new _0x2c4301(_0x4d6739);return _0x35db09['bind']('isEnabled')['to'](this,'isEnabled'),_0x35db09['bind']('isOn')['to'](_0x38aabe,'id',_0x1b531d=>'commentsArchive'===_0x1b531d),_0x35db09['set']({'label':E(_0x4d6739,'COMMENTS_ARCHIVE'),'icon':_0x58018f,'isToggleable':!0x0}),_0x30b9d3&&(_0x35db09['tooltip']=!0x0),this['listenTo'](_0x35db09,'execute',()=>this['_toggleDialog']()),_0x35db09;}['_hideDialogOnAnnotationEscape']=_0x5c6bce=>{const _0x229588=_0x5c6bce['source'];if(!this['annotationViews']['has'](_0x229588['view']))return;const _0x296166=this['editor']['plugins']['get']('Dialog');_0x296166['isOpen']&&'commentsArchive'===_0x296166['id']&&(_0x296166['hide'](),_0x5c6bce['stop']());};}class p extends _0x584d8b{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 _0x4e56ff,ContextPlugin as _0x3ec28c,PendingActions as ht,Command as _0x3fcef6,Plugin as _0x599ac2,Context as _0x282b9f}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x4a1ea7,uid as _0x1ddcfe,KeystrokeHandler as jt,FocusTracker as _0xb3b6d4,diff as _0x3511a1,Collection as _0xfcf14,Rect as _0x66e728,CKEditorError as _0x167eaf,first as _0x2ae980,priorities as Wt,scrollViewportToShowTarget as rt,getEnvKeystrokeText as nt,toUnit as xt,DomEmitterMixin as _0x40c581,keyCodes as _0x31f6cb}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x2d7e2b,AriaDescriptionView as Yt,setupThreadKeyboardNavigation as Zt,ConfirmMixin as ti,LateFocusButtonView as _0x1a1a41,trimHtml as _0x2e9651,LateFocusDropdownButtonView as _0x3f95e4,Users as it,getDateTimeFormatter as lt,hashObject as pt,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as ot,FOCUS_ANNOTATION_KEYSTROKE as _0x3eb3e1}from'ckeditor5-collaboration/dist/index.js';import{throttle as Dt,isEqual as wt,cloneDeep as It,set as At,unset as yt,debounce as _0x41a349}from'es-toolkit/compat';import{IconUndo as _0x3c8e41,IconCheck as _0x19ad54,IconPencil as _0x5003a5,IconRemoveComment as _0x3f5217,IconThreeVerticalDots as _0xd7df7e,IconAddComment as _0x352b6e,IconCommentsArchive as _0x13e233}from'@ckeditor/ckeditor5-icons/dist/index.js';import{EditorUIView as Vt,InlineEditableUIView as $t,EditorUI as Rt,View as kt,FocusCycler as _0x2db88c,ButtonView as _0x181f25,ViewCollection as _0x58f26f,createDropdown as _0x223503,ListView as _0x6df86f,focusChildOnDropdownOpen as _0x3cf47f,ListItemView as _0x13383a,MenuBarMenuListItemButtonView as _0x66c319,BodyCollection as _0x24189d,BalloonPanelView as _0x4865ab,ContextualBalloon as _0x2f55da,Dialog as _0x3f2689,DialogViewPosition as _0xd26c9f}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disablePlaceholder as St,enablePlaceholder as Ft,MouseObserver as _0xbf6260}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 _0x5a7967}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{toWidget as _0x1690d4}from'@ckeditor/ckeditor5-widget/dist/index.js';class Ct extends/* #__PURE__ -- @preserve */
24
+ _0x4a1ea7(){['model'];['view'];constructor(_0x2a86de,_0x24feab){super(),this['model']=_0x2a86de,this['model']['_isAttached']=!0x0,this['view']=_0x24feab,this['listenTo'](_0x24feab,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x24feab,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x24feab,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x24feab,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x24feab,'addComment',(_0x244588,_0x75a965)=>this['addComment'](_0x75a965)),this['listenTo'](_0x24feab,'updateComment',(_0x582c78,_0x13deb3,_0x425b14)=>this['updateComment'](_0x13deb3,_0x425b14)),this['listenTo'](_0x24feab,'removeComment',(_0x2aa773,_0xf811d0)=>this['removeComment'](_0xf811d0));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x402581){this['model']['addComment']({'content':_0x402581,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x283693,_0x5599fb){this['model']['getComment'](_0x283693)['update']({'content':_0x5599fb});}['removeComment'](_0x1e41fa){this['model']['getComment'](_0x1e41fa)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function E(_0x483f39,_0x3a320f,_0x4dbb80){const t=_0x483f39['t'];switch(_0x3a320f){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'},_0x4dbb80);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'},_0x4dbb80);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'},_0x4dbb80);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'},_0x4dbb80);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x4dbb80);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'},_0x4dbb80);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'},_0x4dbb80);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'},_0x4dbb80);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(_0x58b589,_0x16f174){super(_0x58b589);const _0x21af61=_0x1ddcfe();this['main']=this['createCollection'](),this['editable']=new $t(_0x58b589,_0x16f174,void 0x0,{'label':()=>E(_0x58b589,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x58b589['uiLanguageDirection'],'lang':_0x58b589['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x21af61},'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(_0x4949a6){super(_0x4949a6),this['view']=new Ut(_0x4949a6['locale'],_0x4949a6['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x2d9297=this['editor']['editing']['view'],_0x4fb546=this['view']['editable'],_0x3275e8=_0x2d9297['document']['getRoot']();_0x4fb546['name']=_0x3275e8['rootName'],this['view']['render']();const _0x26435a=_0x4fb546['element'];this['setEditableElement'](_0x4fb546['name'],_0x26435a),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2d9297['attachDomRoot'](_0x26435a),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Nt=[qt,zt,Bt,Et,Gt,Jt,Kt];class Qt extends/* #__PURE__ -- @preserve */
25
+ _0x4a1ea7(_0x4e56ff){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
26
+ ((()=>Nt)());constructor(_0x20a7f5={}){function _0x13901e(_0x5ec5fb){return _0x5ec5fb['map'](_0x2261ee=>String['fromCharCode'](_0x2261ee))['join']('');}(_0x20a7f5=Object['assign']({},_0x20a7f5))['plugins']||(_0x20a7f5['plugins']=Qt['defaultPlugins']),super(_0x20a7f5),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[_0x13901e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x13901e([0x76,0x69,0x65,0x77])][_0x13901e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x13901e([0x61,0x75,0x74,0x6f]),this[_0x13901e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x13901e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x13901e([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x13901e([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x13901e([0x6f,0x6b])});}['create'](){const _0x30bb50=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x30bb50))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x2766a9=>{const _0x56e147=this['model']['document']['getRoot'](),_0x1522e6=_0x56e147&&_0x56e147['getChild'](_0x56e147['childCount']-0x1);_0x2766a9['setSelection'](_0x1522e6,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x3cfa0e=this['editing']['view'],_0x3c0b1d=_0x3cfa0e['document']['getRoot'](),_0x12ef43=_0x3c0b1d['getChild'](0x0);_0x3c0b1d['childCount']>0x1||!_0x12ef43||'p'!=_0x12ef43['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(St(_0x3cfa0e,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x12ef43['placeholder']=this['placeholder']),Ft({'view':_0x3cfa0e,'element':_0x12ef43,'keepOnFocus':!0x0}),this['placeholderElement']=_0x12ef43);}}class os extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x7733f1,_0x3fa020={}){super(_0x7733f1),this['editor']=null,this['_editorConfig']=_0x3fa020,this['set']('value',_0x3fa020['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',E(_0x7733f1,'Reply...')),this['set']('submitLabel',E(_0x7733f1,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0xb3b6d4(),this['focusCycler']=new _0x2db88c({'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',(_0x4f9632,_0x15f276)=>{this['cancelButtonView']['fire']('execute'),_0x15f276();}),this['keystrokes']['set']('Ctrl+Enter',(_0x3952f3,_0x3ee4eb)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x3ee4eb());}),this['on']('submit',(_0xf8fd1e,_0x15c00d)=>{_0x15c00d['length']>0xfde8?(alert(E(_0x7733f1,'TOO_LONG_COMMENT_ALERT',[_0x15c00d['length'],0xfde8])),_0xf8fd1e['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 _0x5c7dad=this['editor'];this['element']['insertBefore'](_0x5c7dad['ui']['element'],this['element']['firstChild']),_0x5c7dad['model']['document']['on']('change',()=>this['value']=_0x5c7dad['getData']()),_0x5c7dad['bind']('placeholder')['to'](this),this['focusables']['add'](_0x5c7dad['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x192947){-0x1===_0x192947?(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:_0xf4ba15}=this,_0x1a6036=new _0x181f25(_0xf4ba15);return _0x1a6036['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x1a6036['withText']=!0x0,_0x1a6036['bind']('label')['to'](this,'submitLabel'),_0x1a6036['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x1a6036['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x85e08d,_0x495832)=>!_0x495832&&!!_0x85e08d['trim']()),_0x1a6036;}['_createCancelButton'](){const {locale:_0x52525}=this,_0xa52103=new _0x181f25(_0x52525);return _0xa52103['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0xa52103['label']=E(_0x52525,'Cancel'),_0xa52103['withText']=!0x0,_0xa52103['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0xa52103;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x4c0a61=>{this['focusTracker']['add'](_0x4c0a61['element']);}),this['focusables']['on']('change',(_0x4e0a36,_0x5719e9)=>{for(const _0x5a6d73 of Array['from'](_0x5719e9['added'])['reverse']())this['focusTracker']['add'](_0x5a6d73['element']);});}}class ie extends kt{constructor(_0xd4794b,_0x3969e1,_0x3c97e3){super(_0xd4794b),this['commentInputView']=new os(_0xd4794b,_0x3c97e3),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x58a567,_0x302a01)=>_0x58a567||!!_0x302a01),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 _0x2d7e2b(_0xd4794b,_0x3969e1),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'](_0x336e52){this['commentInputView']['focus'](_0x336e52);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x2481bb,_0x31e721)=>{const {submitButtonView:_0x321beb,cancelButtonView:_0x4d4b42,editor:_0x28d93d}=this['commentInputView'];[_0x321beb['element'],_0x4d4b42['element'],_0x28d93d?_0x28d93d['editing']['view']['getDomRoot']():null]['filter'](_0x2fcb9b=>_0x2fcb9b)['some'](_0x6e64c3=>_0x6e64c3['contains'](_0x31e721['target']))||(this['focus'](),_0x31e721['preventDefault']());});}}class cs extends kt{constructor(_0x56c36d){super(_0x56c36d);const _0x192544=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x192544['to']('count',_0x9b0563=>E(_0x56c36d,'NUMBER_OF_COMMENTS',_0x9b0563))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0xccd786,_0x148bb3,_0x2604eb){super(_0xccd786);const _0xf40831=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x148bb3['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x148bb3,this['_config']=_0x2604eb,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0xb3b6d4(),this['keystrokes']=new jt(),this['focusCycler']=new _0x2db88c({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x1767c9=>this['commentViews']['map'](_0x2c3c4d=>_0x2c3c4d['element'])['includes'](_0x1767c9['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new cs(_0xccd786),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x43abea=>_0x43abea-this['_config']['maxCommentsWhenCollapsed']);for(const _0x1ead71 of _0x148bb3['comments'])this['_handleNewCommentModel'](_0x1ead71);this['_handleInfoComment'](),this['listenTo'](_0x148bb3['comments'],'add',(_0x3be26d,_0x13c11d)=>{const _0x32386c=this['_calculatePosition'](_0x13c11d);this['length']++,this['_handleNewCommentModel'](_0x13c11d,_0x32386c),this['refreshVisibleViews']();}),this['listenTo'](_0x148bb3['comments'],'remove',(_0x27363e,_0x5221e7)=>{this['length']--,this['_handleRemoveCommentModel'](_0x5221e7),this['refreshVisibleViews']();}),this['listenTo'](_0x148bb3,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x148bb3,'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',_0xf40831['if']('length','ck-hidden',_0x32d2e3=>!_0x32d2e3)],'aria-label':E(_0xccd786,'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'](_0x4184c1){-0x1===_0x4184c1?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x18b5bc of this['commentViews'])_0x18b5bc['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x3449b6,_0x1daafa){const _0x23c469=new this['_config']['CommentView'](this['locale'],_0x3449b6,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x23c469['viewUid']=_0x3449b6['id'],_0x23c469['delegate']('removeComment')['to'](this),_0x23c469['delegate']('updateComment')['to'](this),_0x23c469['delegate']('resolveCommentThread')['to'](this),_0x23c469['delegate']('editorReady')['to'](this),_0x23c469['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x23c469,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x23c469,_0x1daafa);}['_calculatePosition'](_0x520651){const _0x397900=this['_model']['_findOptimalIndex'](_0x520651);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x520651['authoredAt']?_0x397900-0x1:_0x397900:_0x397900-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x40c8b7={'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'],_0x40c8b7,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x40c8b7));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x1aea7f){const _0x2f6938=this['commentViews']['remove'](_0x1aea7f['id']);this['stopListening'](_0x2f6938),_0x2f6938['isEditMode']&&this['_updateHasDirtyComment'](),_0x2f6938['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x4a6544=>_0x4a6544['isEditMode']);}['_rearrangeCollapse'](){const _0x3df489=function(_0xecdaf3){const _0x28736b=new _0xfcf14();for(const _0x451f1a of _0xecdaf3)_0x28736b['add'](_0x451f1a);return _0x28736b;}(this['commentViews']),_0x2d03e6=this['_collapsedCommentsView']['count'];for(let _0x41dd6f=0x1;_0x41dd6f<=_0x2d03e6;_0x41dd6f++)_0x3df489['remove'](0x1);for(const _0x2fdc8e of _0x3df489)_0x2fdc8e['collapse']();_0x2d03e6>0x0&&_0x3df489['add'](this['_collapsedCommentsView'],0x1),ns(_0x3511a1(Array['from'](this['visibleViews']),Array['from'](_0x3df489)),this['visibleViews'],_0x3df489);}['_rearrangeExpand'](){ns(_0x3511a1(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x32be06 of this['visibleViews'])_0x32be06['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x579c8d=>{this['focusTracker']['add'](_0x579c8d['element']),this['keystrokes']['listenTo'](_0x579c8d['element']);}),this['commentViews']['on']('change',(_0x525b92,_0xc81409)=>{for(const _0x494258 of _0xc81409['removed'])this['focusTracker']['remove'](_0x494258['element']),this['keystrokes']['stopListening'](_0x494258['element']);for(const _0x5bd4b2 of Array['from'](_0xc81409['added'])['reverse']())this['focusTracker']['add'](_0x5bd4b2['element']),this['keystrokes']['listenTo'](_0x5bd4b2['element']);});}}function ns(_0x3112f9,_0x39c3ee,_0x9def23){let _0xd139e0=0x0;for(const _0x4650c1 of _0x3112f9)switch(_0x4650c1){case'insert':_0x39c3ee['add'](_0x9def23['get'](_0xd139e0),_0xd139e0),_0xd139e0++;break;case'delete':_0x39c3ee['remove'](_0xd139e0);break;case'equal':_0xd139e0++;}}class as extends kt{constructor(_0x595eac){super(_0x595eac);const _0x17b2f2=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x17b2f2['to']('contextValue',_0x52e8b9=>E(_0x595eac,'THREAD_CONTEXT_LABEL',_0x52e8b9)),'tabindex':-0x1},'children':[{'text':_0x17b2f2['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Xt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x2f591d,_0x13f76e){super(_0x2f591d);const _0x2e2e50=this['bindTemplate'];this['_model']=_0x13f76e,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0xb3b6d4(),this['keystrokes']=new jt(),this['focusCycler']=new _0x2db88c({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x5be380=>!!_0x5be380),this['bind']('contextValue')['to'](this['_model'],'context',_0x57e7b9=>_0x57e7b9&&_0x57e7b9['value']?this['_trimContextValue'](_0x57e7b9['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',_0x2e2e50['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 _0x187f13=new _0x181f25(this['locale']);return _0x187f13['label']=E(this['locale'],'Reopen'),_0x187f13['tooltip']=E(this['locale'],'Reopen'),_0x187f13['icon']=_0x3c8e41,_0x187f13['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1d68c8=>!_0x1d68c8),_0x187f13['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x31035f,_0x4b15a8)=>_0x31035f&&_0x4b15a8),_0x187f13['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x187f13;}['_trimContextValue'](_0x2fce12){if(_0x2fce12['length']<0x96)return _0x2fce12;const _0x27958f=_0x2fce12['lastIndexOf']('\x20',0x93);return _0x2fce12['substring'](0x0,_0x27958f>-0x1?_0x27958f:0x93)+'...';}['_attachContextActions'](){const _0x5d751b=this['element']['querySelector']('.ck-context'),_0x4eaf01=_0x5d751b['querySelector']('.ck-context__value');this['listenTo'](_0x5d751b,'mouseenter',()=>{_0x4eaf01['offsetWidth']<_0x4eaf01['scrollWidth']&&_0x5d751b['classList']['add']('overlay');}),this['listenTo'](_0x5d751b,'mouseleave',()=>{_0x5d751b['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x24ba76 of this['focusables'])this['focusTracker']['add'](_0x24ba76['element']),this['keystrokes']['listenTo'](_0x24ba76['element']);}['_createContextView'](){const _0x996202=new as(this['locale']);return _0x996202['bind']('contextValue')['to'](this),_0x996202;}}class ts extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x5802e1,_0x3d4c69,_0x3b5929,_0x27d02c){super(_0x5802e1),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x3d4c69,this['_localUser']=_0x3b5929,this['_config']=_0x27d02c,this['commentThreadHeaderView']=new Xt(_0x5802e1,_0x3d4c69),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Yt(_0x5802e1,E(_0x5802e1,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x5802e1,_0x3d4c69,Object['assign']({'CommentView':this['_config']['CommentView']},_0x27d02c)),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',(_0x31b633,_0x1a6e76)=>_0x31b633||!!_0x1a6e76),this['bind']('isUnlinked')['to'](_0x3d4c69,'unlinkedAt',_0x5eabe7=>!!_0x5eabe7),this['bind']('ariaLabel')['to'](this,'length',_0x5a0af7=>{const _0x1fe5dc=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return E(this['locale'],'COMMENT_THREAD_LABEL',[_0x5a0af7,_0x1fe5dc]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0xb3b6d4(),this['keystrokes']=new jt(),this['focusCycler']=new _0x2db88c({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x34e764=>_0x34e764['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 _0x4bb081=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x1cac86=_0x4bb081['commentInputView'];return _0x4bb081['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x1cac86,'value',(_0x414fb0,_0x55ab02,_0x295a09,_0x3dd913,_0x2f80e9)=>!!_0x2f80e9||!!_0x3dd913&&_0x295a09&&!_0x55ab02||_0x414fb0&&_0x295a09&&!_0x55ab02),_0x1cac86['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x21e1d0,_0xdd4da7,_0x456b79)=>{let _0x154000;return _0x154000=_0x456b79&&_0xdd4da7?'Reply\x20to\x20reopen\x20discussion...':_0x21e1d0?'Reply...':'Write\x20a\x20comment...',E(this['locale'],_0x154000);}),_0x1cac86['bind']('submitLabel')['to'](this,'length',_0xe8f7fb=>E(this['locale'],_0xe8f7fb?'Reply':'Comment')),_0x1cac86['on']('submit',(_0x25af2b,_0x8dd848)=>{this['fire']('addComment',_0x8dd848),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x1cac86['on']('cancel',()=>{this['focus']();}),_0x1cac86['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x1cac86['on']('cancel',_0x2274df=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x2274df['stop']());}),this['on']('change:isActive',(_0x5b9cdd,_0x17281b,_0x3f6075)=>{_0x3f6075||this['length']||_0x1cac86['value']||this['fire']('removeCommentThread');}),_0x4bb081;}}class vt extends/* #__PURE__ -- @preserve */
27
+ ti(ts){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x55c29f,_0x13aede,_0x1c5f08,_0x134a10){super(_0x55c29f,_0x13aede,_0x1c5f08,_0x134a10),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x55c29f,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x2859d5,_0x182b55,_0x492d13)=>{_0x492d13||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x192069,_0x6f528e,_0x3b5ef3)=>{_0x3b5ef3&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x2c2ed8=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x2c2ed8['if']('isActive','ck-thread--active'),_0x2c2ed8['if']('isUnlinked','ck-thread--unlinked'),_0x2c2ed8['if']('isConfirm','ck-thread--remove-confirmation'),_0x2c2ed8['to']('actionIndicator',_0x506278=>_0x506278?'ck-thread--'+_0x506278:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x2c2ed8['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 _0x538d3a of this['commentsListView']['commentViews'])_0x538d3a['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x540a9c}=this,_0x4fb6c7=this['commentsListView']['commentViews']['get'](0x0);_0x4fb6c7===this['_boundFirstCommentView']||_0x4fb6c7['isSystemComment']||(this['_boundFirstCommentView']=_0x4fb6c7,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x4fb6c7,'actionIndicator',_0x11b2ba=>'remove'===_0x11b2ba?'remove':null),_0x4fb6c7['placeholder']=E(_0x540a9c,'Write\x20a\x20comment...'),_0x4fb6c7['removeButton']['on']('execute',_0x204471=>{_0x204471['stop'](),this['showConfirm'](E(_0x540a9c,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x4fb6c7['focus']();}),_0x4fb6c7['actionBar']['add'](this['resolveButton'],0x0),_0x4fb6c7['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x5b4d49=new _0x1a1a41(this['locale']);return _0x5b4d49['label']=E(this['locale'],'Resolve'),_0x5b4d49['tooltip']=E(this['locale'],'Resolve'),_0x5b4d49['icon']=_0x19ad54,_0x5b4d49['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x5b4d49['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x56e434=>!_0x56e434),_0x5b4d49['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x45de14,_0x44754d)=>_0x45de14&&!_0x44754d),_0x5b4d49['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x5b4d49;}['_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(_0xccd169){super(_0xccd169),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0xc75236,_0x2a2e58,_0x34f9e8)=>{this['element']['innerHTML']=_0x34f9e8;}),this['element']['innerHTML']=this['content'];}}class hs extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x395d0e,_0x1b4c5e,_0x44c93a){super(_0x395d0e),this['_model']=_0x1b4c5e,this['_config']=_0x44c93a,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x1b4c5e,'content',_0x1b4c5e,'authoredAt',(_0x25d39a,_0x49fd69)=>E(_0x395d0e,'COMMENT_ARIA_LABEL',[_0x1b4c5e['author']['name'],_0x44c93a['formatDateTime'](_0x49fd69),new DOMParser()['parseFromString'](_0x25d39a,'text/html')['body']['textContent'],_0x1b4c5e['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Yt(_0x395d0e,E(_0x395d0e,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x58f26f(),this['focusTracker']=new _0xb3b6d4(),this['keystrokes']=new jt(),this['focusCycler']=new _0x2db88c({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x5a9174=>_0x5a9174['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 _0x94f819=new es(this['locale']);return _0x94f819['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x1c9cc5,_0x140ebf)=>_0x140ebf?_0x2e9651(_0x1c9cc5,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x1c9cc5),_0x94f819;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x457ca6=new os(this['locale'],this['_config']['editorConfig']);return _0x457ca6['value']=this['_model']['content'],_0x457ca6['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x457ca6['submitLabel']=E(this['locale'],'Save'),_0x457ca6['on']('submit',(_0x4ed79d,_0x971e7d)=>{this['fire']('updateComment',this['_model']['id'],_0x971e7d),this['switchToDisplayMode'](),this['focus']();}),_0x457ca6['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x457ca6['once']('editorReady',()=>{_0x457ca6['focus']();}),_0x457ca6['createEditor'](),_0x457ca6['delegate']('editorReady')['to'](this),_0x457ca6['delegate']('editorDestroyed')['to'](this),_0x457ca6;}['_setupKeyboardNavigation'](){const _0x5ad79c=this['element'];this['keystrokes']['listenTo'](_0x5ad79c);for(const _0x13bc20 of this['focusables'])this['focusTracker']['add'](_0x13bc20['element']),this['keystrokes']['listenTo'](_0x13bc20['element']);this['focusables']['on']('change',(_0x2061a3,_0xe0a26f)=>{for(const _0x538e4e of _0xe0a26f['removed'])this['focusTracker']['remove'](_0x538e4e['element']),this['keystrokes']['stopListening'](_0x538e4e['element']);for(const _0x142d61 of _0xe0a26f['added'])this['focusTracker']['add'](_0x142d61['element']),this['keystrokes']['listenTo'](_0x142d61['element']);}),this['keystrokes']['set']('enter',(_0xf35720,_0xc9781d)=>{_0x5ad79c===_0xf35720['target']&&(this['focusCycler']['focusFirst'](),_0xc9781d());}),this['keystrokes']['set']('esc',(_0x343562,_0x8c50b0)=>{_0x5ad79c!==_0x343562['target']&&(this['focus'](),_0x8c50b0());});}}class gt extends/* #__PURE__ -- @preserve */
28
+ ti(hs){['actionBar'];['userView'];constructor(_0x5af7b9,_0x1de014,_0x2dd0e0){super(_0x5af7b9,_0x1de014,_0x2dd0e0),this['set']('actionIndicator',null),this['set']('placeholder',E(_0x5af7b9,'Reply...')),this['bind']('authoredAt')['to'](_0x1de014),this['bind']('resolvedAt')['to'](_0x1de014),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 _0x2d7e2b(_0x5af7b9,_0x1de014['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x1de014,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x8c3d8e=this['bindTemplate'],_0x332e98=[{'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':_0x8c3d8e['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x8c3d8e['to']('authoredAt',_0x3c1daf=>this['_config']['formatDateTime'](_0x3c1daf))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x8c3d8e['if']('isEditMode','ck-comment__actions--hidden'),_0x8c3d8e['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']&&_0x332e98['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x8c3d8e['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x8c3d8e['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x8c3d8e['if']('isEditMode','ck-comment--edit'),_0x8c3d8e['if']('isSystemComment','ck-comment--info'),_0x8c3d8e['to']('actionIndicator',_0x3b6ffd=>_0x3b6ffd?'ck-comment--'+_0x3b6ffd:'')],'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':_0x332e98}]}]};}['_createEditButton'](){const _0x13a969=new _0x181f25(this['locale']);return _0x13a969['label']=E(this['locale'],'Edit'),_0x13a969['icon']=_0x5003a5,_0x13a969['withText']=!0x0,_0x13a969['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x13a969['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3c15a3=>!_0x3c15a3),_0x13a969['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x13a969['on']('execute',()=>this['switchToEditMode']()),_0x13a969;}['_createRemoveButton'](){const _0x55e779=new _0x181f25(this['locale']);return _0x55e779['label']=E(this['locale'],'Remove'),_0x55e779['icon']=_0x3f5217,_0x55e779['withText']=!0x0,_0x55e779['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x55e779['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x39effa=>!_0x39effa),_0x55e779['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x55e779['on']('execute',()=>{this['showConfirm'](E(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x55e779;}['_createDropdown'](){const _0x53599e=_0x223503(this['locale'],_0x3f95e4),_0x290e25=_0x53599e['panelView']['children'],_0x2cdaaa=new _0x6df86f(this['locale']),_0x2df23d=_0x53599e['bindTemplate'];_0x3cf47f(_0x53599e,()=>this['items']['find'](_0xcf5a5d=>_0xcf5a5d['isVisible'])),_0x53599e['extendTemplate']({'attributes':{'class':[_0x2df23d['if']('isVisible','ck-hidden',_0x3d9084=>!_0x3d9084)]}});const _0x37382d=(_0x495e24,_0x4a8319=-0x1)=>{const _0x331a9f=new _0x13383a(this['locale']);_0x331a9f['children']['add'](_0x495e24);const _0x2176c8=_0x4a8319>-0x1?_0x4a8319:_0x2cdaaa['items']['length'];_0x2cdaaa['items']['add'](_0x331a9f,_0x2176c8);const _0x11071b=Array['from'](this['items']);_0x53599e['unbind']('isEnabled','isVisible'),_0x53599e['bind']('isEnabled')['toMany'](_0x11071b,'isEnabled',(..._0x1c599d)=>_0x1c599d['some'](_0x57a11b=>_0x57a11b)),_0x53599e['bind']('isVisible')['toMany'](_0x11071b,'isVisible',(..._0xc2a229)=>_0xc2a229['some'](_0x35c141=>_0x35c141));};_0x53599e['panelPosition']='sw',_0x53599e['buttonView']['set']({'label':E(this['locale'],'Show\x20more\x20items'),'icon':_0xd7df7e});for(const _0x356c50 of this['items'])_0x37382d(_0x356c50);return _0x290e25['add'](_0x2cdaaa),_0x53599e['listenTo'](this['items'],'add',(_0x1bbb28,_0x4ff4b9,_0x5741cd)=>{_0x37382d(_0x4ff4b9,_0x5741cd);}),_0x53599e['listenTo'](this['items'],'remove',(_0x8e1315,_0x81f644,_0x431693)=>{_0x2cdaaa['items']['remove'](_0x431693);}),_0x53599e;}['_attachActions'](_0x398062,_0x5f4da9){const _0x4a0170=_0x398062&&_0x398062['element'];_0x4a0170&&(this['listenTo'](_0x4a0170,'mouseenter',()=>this['actionIndicator']=_0x5f4da9),this['listenTo'](_0x4a0170,'focus',()=>this['actionIndicator']=_0x5f4da9),this['listenTo'](_0x4a0170,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x4a0170,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x5d06a0=super['_createCommentInputView']();return _0x5d06a0['bind']('placeholder')['to'](this),_0x5d06a0;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function Lt(_0x1277d2){const _0x1e43f3=Dt(_0x1277d2,0x1e),_0x583218=new MutationObserver(_0x48d050=>{for(const _0xe79a2f of _0x48d050)('attributes'==_0xe79a2f['type']&&'class'==_0xe79a2f['attributeName']||'childList'==_0xe79a2f['type']||'characterData'==_0xe79a2f['type'])&&_0x1e43f3();});return{'attach'(_0x2049fc){_0x583218['observe'](_0x2049fc,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x583218['disconnect'](),_0x1e43f3['cancel']();}};}class S extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x3f7e3b,_0x41fd8f){super(_0x3f7e3b),this['id']=_0x1ddcfe(),this['focusTracker']=new _0xb3b6d4(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0xa8cb8b,_0x857a4d)=>this['fire']('Esc',_0x857a4d)),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'](_0x41fd8f),this['mainView']=_0x41fd8f;const _0x37e46f=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x37e46f['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 _0x37db22=this['element']['clientHeight'];_0x37db22&&(this['height']=_0x37db22);}}class d extends/* #__PURE__ -- @preserve */
29
+ _0x4a1ea7(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x50fd56,target:_0x4cac29,type:_0x5efd02,isVisible:_0x58692c=!0x0}){super(),this['view']=_0x50fd56,this['view']['element']||this['view']['render'](),this['_type']=_0x5efd02,this['_target']=_0x4cac29,d['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0xfcf14([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x4a2233,_0x91e37b)=>{this['view']['focusTracker']['add'](_0x91e37b);}),this['focusableElements']['on']('remove',(_0x5936f3,_0x563b7c)=>{this['view']['focusTracker']['remove'](_0x563b7c);}),this['set']('isVisible',_0x58692c);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x57d7e0=this['_getNormalizedTarget']();return d['_assertCorrectTarget'](_0x57d7e0),_0x57d7e0;}get['targetRect'](){const _0x3e1989=this['target'];if(null===_0x3e1989)return null;if(_0x3e1989 instanceof _0x66e728)return _0x3e1989;const _0x198748=_0x3e1989['filter'](_0x2d4231=>function(_0x1e91bf){const _0x4ecfb9=_0x1e91bf['offsetParent'];if(_0x4ecfb9)return!0x0;const _0x2176e3=_0x1e91bf['getClientRects']()['item'](0x0);return!!_0x2176e3;}(_0x2d4231));return 0x0===_0x198748['length']?null:new _0x66e728(_0x198748[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x4452fa){this['view']['isActive']=_0x4452fa,this['view']['mainView']['isActive']=_0x4452fa;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x3795ae){if(!(null===_0x3795ae||_0x3795ae instanceof _0x66e728||Array['isArray'](_0x3795ae)&&_0x3795ae['every'](_0x25b23d=>li(_0x25b23d))))throw new _0x167eaf('annotation-invalid-target',null,{'target':_0x3795ae});}['_getNormalizedTarget'](){const _0x5d0fa2='function'==typeof this['_target']?this['_target']():this['_target'];return li(_0x5d0fa2)?[_0x5d0fa2]:_0x5d0fa2;}}function li(_0x8d0146){return null!==_0x8d0146&&'object'==typeof _0x8d0146&&'nodeType'in _0x8d0146&&0x1===_0x8d0146['nodeType'];}class _ extends _0xfcf14{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x1c3272=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0xb3b6d4(),this['_focusTracker']['on']('change:isFocused',(_0x3a7cde,_0x2b854e,_0x1c67ed)=>{_0x1c67ed||this['fire']('blur');});for(const _0x35bf45 of _0x1c3272)this['add'](_0x35bf45);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0xd427cc){if(this['has'](_0xd427cc))throw new _0x167eaf('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0xd427cc['innerView'],_0xd427cc),this['_viewToAnnotation']['set'](_0xd427cc['view'],_0xd427cc);for(const _0x51e8a4 of _0xd427cc['focusableElements'])this['_focusTracker']['add'](_0x51e8a4);this['listenTo'](_0xd427cc['focusableElements'],'add',(_0x1bb2fa,_0x149231)=>{this['_focusTracker']['add'](_0x149231);}),this['listenTo'](_0xd427cc['focusableElements'],'remove',(_0x333e5a,_0x3a0365)=>{this['_focusTracker']['remove'](_0x3a0365);}),this['listenTo'](_0xd427cc['view']['focusTracker'],'change:isFocused',(_0x4b21ca,_0x6daee9,_0x5bd626)=>{_0x5bd626&&this['fire']('focus',_0xd427cc);}),_0xd427cc['updateTargetRect']();const _0x45ee3b=this['_getOrderInContent'](_0xd427cc['view']['targetRect']);return super['add'](_0xd427cc,_0x45ee3b);}['remove'](_0x152c1a){if(!this['has'](_0x152c1a))throw new _0x167eaf('annotationcollection-not-existing-item',null);this['stopListening'](_0x152c1a['view']['focusTracker']),this['stopListening'](_0x152c1a['focusableElements']);for(const _0x5317c5 of _0x152c1a['focusableElements'])this['_focusTracker']['remove'](_0x5317c5);return this['_viewToAnnotation']['delete'](_0x152c1a['view']),this['_innerViewToAnnotation']['delete'](_0x152c1a['innerView']),super['remove'](_0x152c1a);}['getByInnerView'](_0x13480b){return this['_innerViewToAnnotation']['get'](_0x13480b);}['getByView'](_0x10f575){return this['_viewToAnnotation']['get'](_0x10f575);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x19e959 of this)_0x19e959['updateTargetRect']();this['_sort']();}['_sort'](){const _0x14401f=Array['from'](this)['sort']((_0x46f74c,_0x332b89)=>v(_0x46f74c['view']['targetRect'],_0x332b89['view']['targetRect']));for(let _0xb40b3f=_0x14401f['length']-0x1;_0xb40b3f>0x0;_0xb40b3f--){const _0x5925f7=_0x14401f[_0xb40b3f];_0xb40b3f!==this['getIndex'](_0x5925f7)&&(this['remove'](_0x5925f7),this['add'](_0x5925f7));}}['_getOrderInContent'](_0xbe6185){let _0x2c7782=0x0;if(!_0xbe6185)return this['length'];for(const _0x3ddb04 of this){const _0x21c50c=_0x3ddb04['view']['targetRect'];if(_0x21c50c){if(v(_0xbe6185,_0x21c50c)<0x0)return _0x2c7782;_0x2c7782++;}}return _0x2c7782;}}function v(_0x109f53,_0x375b5e){if(null===_0x109f53&&null===_0x375b5e)return 0x0;if(null===_0x109f53)return-0x1;if(null===_0x375b5e)return 0x1;const _0xccb8c3=_0x109f53['top']-_0x375b5e['top'];return 0x0==_0xccb8c3?_0x109f53['left']-_0x375b5e['left']:_0xccb8c3;}class O extends _0x3ec28c{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4eff5f){if(super(_0x4eff5f),this['collection']=new _(),this['_visibleAnnotations']=new _(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x4eff5f instanceof _0x4e56ff){const _0x1bd15c=_0x4eff5f['locale'];_0x4eff5f['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':E(_0x1bd15c,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x3b4ef6){this['collection']['add'](_0x3b4ef6);}['remove'](_0x4f2ecc){this['collection']['remove'](_0x4f2ecc),_0x4f2ecc['destroy']();}['refreshVisibility'](){for(const _0x20da00 of this['collection'])_0x20da00['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x7170f9){return this['collection']['getByInnerView'](_0x7170f9);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x4a3eba of this['collection'])_0x4a3eba['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x20eb2a){this['fire']('_activateAnnotation',_0x20eb2a);}['createAnnotation'](_0x372a7d){return new d(_0x372a7d);}['createAnnotationView'](_0x4d56dd,_0x27bb72){return new S(_0x4d56dd,_0x27bb72);}['_addActiveAnnotation'](_0x1c2602){const _0x1899ae=new Set(this['activeAnnotations']);_0x1899ae['add'](_0x1c2602),this['activeAnnotations']=_0x1899ae;}['_removeActiveAnnotation'](_0x130a18){const _0x123425=new Set(this['activeAnnotations']);_0x123425['delete'](_0x130a18),this['activeAnnotations']=_0x123425;}['_bindAnnotationsToVisibleAnnotations'](){const _0x25f159=this['collection'],_0x22ef92=this['_visibleAnnotations'];function _0x1ccf88(_0x4458b5){const _0x411156=_0x4458b5['source'];_0x411156['isVisible']&&!_0x22ef92['has'](_0x411156)?_0x22ef92['add'](_0x411156):!_0x411156['isVisible']&&_0x22ef92['has'](_0x411156)&&_0x22ef92['remove'](_0x411156),_0x411156['view']['focusTracker']['remove'](_0x411156['view']['element']),_0x411156['view']['focusTracker']['add'](_0x411156['view']['element']);}this['listenTo'](_0x25f159,'add',(_0x3de444,_0xfffcfa)=>{_0xfffcfa['isVisible']&&_0x22ef92['add'](_0xfffcfa),this['listenTo'](_0xfffcfa,'change:isVisible',_0x1ccf88);}),this['listenTo'](_0x25f159,'remove',(_0x852bc9,_0x1ca47d)=>{_0x22ef92['has'](_0x1ca47d)&&_0x22ef92['remove'](_0x1ca47d),this['stopListening'](_0x1ca47d,'change:isVisible',_0x1ccf88);});}['_setupEnterAnnotationKeystroke'](){const _0x2fe1f8=_0x557396=>{_0x557396['on']('ready',()=>{_0x557396['keystrokes']['set'](_0x5a7967,(_0x1328fd,_0x11c9ab)=>{const _0x228a33=_0x2ae980(this['activeAnnotations']['values']());_0x228a33&&(_0x228a33['view']['focus'](),_0x11c9ab());});});};this['context']instanceof _0x4e56ff?_0x2fe1f8(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x4928ac,_0x56b194)=>{_0x2fe1f8(_0x56b194);});}['_setupEscapeAnnotationHandling'](){const _0x547396=_0x56b395=>{const _0x2702fc=_0x56b395['source'],_0x4e8ea7=[];let _0x4760b7;if(Array['isArray'](_0x2702fc['target'])){_0x4760b7=_0x2702fc['target'][0x0],this['context']instanceof _0x4e56ff?_0x4e8ea7['push'](this['context']):this['context']['editors']&&_0x4e8ea7['push'](...this['context']['editors']);for(const _0x10bca9 of _0x4e8ea7)for(const _0x33c043 of _0x10bca9['editing']['view']['domRoots']['values']())if(_0x33c043['contains'](_0x4760b7))return void _0x10bca9['editing']['view']['focus']();_0x4760b7['focus']();}};this['listenTo'](this['collection'],'add',(_0x24ee84,_0x9e1dab)=>{this['listenTo'](_0x9e1dab,'escape',_0x547396,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x5abc4e,_0x318b9d)=>{this['stopListening'](_0x318b9d,'escape',_0x547396);});}}const Tt=Symbol('noChannel'),_t={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x3ec28c{['_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(_0x3fc50a){super(_0x3fc50a),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x2f465d=this['context']['config'];_0x2f465d['define']('comments.maxCommentsWhenCollapsed',0x2),_0x2f465d['define']('comments.maxThreadTotalWeight',0x1f4),_0x2f465d['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x2f465d['define']('comments.CommentThreadView',vt),_0x2f465d['define']('comments.CommentView',gt),_0x2f465d['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x5cc75f=this['context']['plugins']['get'](O);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x294be3,_0x2663c1)=>this['_addCommentThread'](_0x2663c1)),this['on']('submitCommentThread',(_0x201d80,_0x4f928d)=>this['_submitCommentThread'](_0x4f928d)),this['on']('resolveCommentThread',(_0x40cb6b,_0x33d724)=>this['_resolveCommentThread'](_0x33d724)),this['on']('resolveCommentThread',(_0x3d6652,_0x1942ca)=>this['_updateActiveAnnotation'](_0x1942ca),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x34685e,_0x23ddf2)=>this['_reopenCommentThread'](_0x23ddf2)),this['on']('reopenCommentThread',(_0xde1c64,_0x456779)=>this['_updateActiveAnnotation'](_0x456779),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x17b274,_0x153ed1)=>this['_removeCommentThread'](_0x153ed1)),this['on']('updateCommentThread',(_0x724466,_0x2ff892)=>this['_updateCommentThread'](_0x2ff892)),this['on']('updateCommentThread',(_0x21ab08,_0x1e0cc1)=>this['_updateActiveAnnotation'](_0x1e0cc1),{'priority':'lowest'}),this['on']('addComment',(_0x59b4b8,_0x57c2e9)=>this['_addComment'](_0x57c2e9)),this['on']('updateComment',(_0x270950,_0x3a21dc)=>this['_updateComment'](_0x3a21dc)),this['on']('removeComment',(_0x3574fa,_0x2a5db3)=>this['_removeComment'](_0x2a5db3)),this['on']('addComment',(_0x33ce14,{threadId:_0x1d6a59,isFromAdapter:_0x3e61b8})=>{if(_0x3e61b8)return;const _0xfa578f=this['getCommentThread'](_0x1d6a59),_0x2fa0ec=_0xfa578f&&this['_threadToController']['get'](_0xfa578f);_0x2fa0ec&&_0x2fa0ec['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x5cc75f,'change:activeAnnotations',(_0x3962f4,_0xc7c1ba,_0x38a175)=>{const _0x4c9260=Array['from'](_0x38a175)['map'](_0x24143a=>this['_viewToController']['get'](_0x24143a['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x4c9260?_0x4c9260['model']:null;});}set['adapter'](_0x4159f2){if(this['_adapter'])throw new _0x167eaf('commentsrepository-adapter-already-set');this['_adapter']=_0x4159f2;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x326073=Tt,threadId:_0x26dd82=_0x1ddcfe(),comments:_0x276587=[],unlinkedAt:_0x629976=null,resolvedAt:_0x578d65=null,resolvedBy:_0x4a917a=null,target:_0x6c546d=null,context:_0x576034=null,attributes:_0x36a924={},isResolvable:_0x299087=!0x0,isSubmitted:_0x14a6a7=!0x1,isFromAdapter:_0x4504ef=!0x1}={}){return this['fire'](bt('addCommentThread',_0x326073),{'channelId':_0x326073,'threadId':_0x26dd82,'comments':_0x276587,'unlinkedAt':_0x629976,'resolvedAt':_0x578d65,'resolvedBy':_0x4a917a,'target':_0x6c546d,'context':_0x576034,'attributes':_0x36a924,'isFromAdapter':_0x4504ef,'isResolvable':_0x299087,'isSubmitted':_0x14a6a7}),this['getCommentThread'](_0x26dd82);}['openNewCommentThread']({channelId:_0x3fece2=Tt,threadId:_0x208bdd=_0x1ddcfe(),target:_0x4a1bdc,context:_0x3ef29f=null,isResolvable:_0x541c9f=!0x0}){if(this['_readOnlyChannels']['has'](_0x3fece2)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x4a1bdc)throw new _0x167eaf('commentsrepository-missing-target');const _0x49b6c2=this['addCommentThread']({'channelId':_0x3fece2,'threadId':_0x208bdd,'target':_0x4a1bdc,'context':_0x3ef29f,'isResolvable':_0x541c9f});if(!_0x49b6c2)return null;const _0x48758d=this['_threadToController']['get'](_0x49b6c2),_0x6b9ca2=_0x48758d['view']['commentThreadInputView']['commentInputView'],_0x12be96=this['context']['plugins']['get'](O),_0x3d434d=_0x12be96['getByInnerView'](_0x48758d['view']);return _0x12be96['activate'](_0x3d434d),_0x6b9ca2['once']('editorReady',()=>_0x6b9ca2['focus']()),_0x49b6c2;}['hasCommentThread'](_0x54a82c){if('string'!=typeof _0x54a82c)throw new _0x167eaf('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x54a82c);}['updateCommentThread']({channelId:_0x3d1dc1=Tt,threadId:_0x519258,context:_0x44e905,unlinkedAt:_0x3e2e3a,attributes:_0x5aa6ed,isFromAdapter:_0x417393=!0x1}){return this['fire'](bt('updateCommentThread',_0x3d1dc1),{'channelId':_0x3d1dc1,'threadId':_0x519258,'context':_0x44e905,'unlinkedAt':_0x3e2e3a,'attributes':_0x5aa6ed,'isFromAdapter':_0x417393}),this['getCommentThread'](_0x519258);}['getCommentThread'](_0x5416d8){if('string'!=typeof _0x5416d8)throw new _0x167eaf('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x5416d8);}['fetchCommentThread']({channelId:_0x594613,threadId:_0x4b8160}={}){const _0x13a20c=this['getCommentThread'](_0x4b8160);if(_0x13a20c)return Promise['resolve'](_0x13a20c);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x167eaf('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x594613,'threadId':_0x4b8160})['then'](_0x1820f3=>this['hasCommentThread'](_0x4b8160)?this['getCommentThread'](_0x4b8160):_0x1820f3?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x594613},_0x1820f3)):void 0x0)['catch'](_0x4f1e6d=>{throw console['error'](_0x4f1e6d),new _0x167eaf('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x509fa9,skipNotAttached:_0x1c978b=!0x1,skipEmpty:_0x2556cb=!0x1,toJSON:_0x12a852=!0x1}={}){const _0x494dc9=[];for(const _0x530b20 of this['_threads']['values']())_0x509fa9&&_0x530b20['channelId']!==_0x509fa9||_0x1c978b&&!_0x530b20['isAttached']||_0x2556cb&&0x0===_0x530b20['length']||_0x494dc9['push'](_0x530b20);return _0x12a852?_0x494dc9['map'](_0x3e76a6=>_0x3e76a6['toJSON']()):_0x494dc9;}['setActiveCommentThread'](_0x213a3e){const _0x33d52e=this['context']['plugins']['get'](O);if(!_0x213a3e)return void(this['activeCommentThread']&&_0x33d52e['deactivateAll']());const _0x161a3d=this['getCommentThread'](_0x213a3e);if(!_0x161a3d)throw new _0x167eaf('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x213a3e});if(!this['_threadToController']['has'](_0x161a3d))throw new _0x167eaf('commentsrepository-active-not-attached',null,{'threadId':_0x213a3e});const _0x2c6cd2=_0x33d52e['getByInnerView'](this['_threadToController']['get'](_0x161a3d)['view']);_0x33d52e['activate'](_0x2c6cd2);}['switchReadOnly'](_0x1e4259,_0x253d2a){_0x1e4259?this['_readOnlyChannels']['add'](_0x253d2a):this['_readOnlyChannels']['delete'](_0x253d2a),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x573d77){return this['_readOnlyChannels']['has'](_0x573d77)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x296d09,_0x1c7795){return new Ct(_0x296d09,_0x1c7795);}['setPermissions'](_0x39b0e4,_0x4e6810=Tt){this['_permissions']['set'](_0x4e6810,_0x39b0e4),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x29676e=Tt){return this['_permissions']['has'](_0x29676e)?this['_permissions']['get'](_0x29676e):_t;}['_addCommentThread']({channelId:_0x545549,threadId:_0x562e22,comments:_0x187fb4,unlinkedAt:_0x3d9c5d,resolvedAt:_0x6ff3bf,resolvedBy:_0x4aa1e4,target:_0x1950e6,context:_0x4d2f0f,attributes:_0x50dda0,isFromAdapter:_0x39003c,isResolvable:_0x34b781,isSubmitted:_0x6f6401}){if('string'!=typeof _0x562e22)throw new _0x167eaf('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x562e22});if(this['hasCommentThread'](_0x562e22))throw new _0x167eaf('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x562e22});const _0xe6efdf=new ui(this,{'channelId':_0x545549,'id':_0x562e22,'context':_0x4d2f0f,'attributes':_0x50dda0,'unlinkedAt':_0x3d9c5d,'resolvedAt':_0x6ff3bf,'resolvedBy':_0x4aa1e4?this['context']['plugins']['get'](it)['getUser'](_0x4aa1e4):null,'isResolvable':_0x34b781,'isSubmitted':_0x6f6401||_0x39003c});this['_threads']['set'](_0x562e22,_0xe6efdf);for(const _0x86f2ef of _0x187fb4)_0xe6efdf['_add'](this['_createNewComment']({'threadId':_0x562e22,..._0x86f2ef}));return _0x1950e6&&_0xe6efdf['attachTo'](_0x1950e6),_0x39003c||!_0xe6efdf['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x545549,'threadId':_0x562e22});}['_submitCommentThread']({channelId:_0x489f0f,threadId:_0x4751f2}){if(!this['hasCommentThread'](_0x4751f2))throw new _0x167eaf('commentsrepository-missing-comment-thread',this);const _0xf93181=this['getCommentThread'](_0x4751f2);if(_0xf93181['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x217075,comments:_0x8e03e2,resolvedAt:_0x2275ac,resolvedBy:_0x1b2ff8,context:_0x49e811,attributes:_0x1445e3}=_0xf93181,_0x4bff2a=this['context']['plugins']['get']('PendingActions'),_0x215d40=_0x4bff2a['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x489f0f,'threadId':_0x217075,'comments':_0x8e03e2['map'](_0x129522=>_0x129522['toJSON']()),'resolvedAt':_0x2275ac,'resolvedBy':_0x1b2ff8?_0x1b2ff8['id']:_0x1b2ff8,'context':_0x49e811,'attributes':_0x1445e3})['then'](({comments:_0x3af6db})=>{_0x4bff2a['remove'](_0x215d40);for(const _0x2ffd26 of _0x3af6db)this['_updateComment']({'channelId':_0x489f0f,'threadId':_0x4751f2,'commentId':_0x2ffd26['commentId'],'createdAt':_0x2ffd26['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x21f766=>{throw console['error'](_0x21f766),new _0x167eaf('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0xe4ebf2,target:_0x50493a}){const _0x3bca23=this['getCommentThread'](_0xe4ebf2);if(!_0x3bca23)throw new _0x167eaf('commentsrepository-attach-missing-comment-thread',this);const _0x584192=this['context']['plugins']['get']('PendingActions'),_0x488d65=this['context']['plugins']['get'](O),_0x3dcc17=this['_createCommentThreadView'](_0x3bca23),_0x2d3548=new Ct(_0x3bca23,_0x3dcc17);let _0x355e48=null;_0x3dcc17['on']('change:isDirty',(_0x15863f,_0x51a432,_0x5afe72)=>{_0x5afe72?_0x355e48=_0x584192['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x355e48&&(_0x584192['remove'](_0x355e48),_0x355e48=null);}),this['_threadToController']['set'](_0x3bca23,_0x2d3548),this['_viewToController']['set'](_0x3dcc17,_0x2d3548);const _0x48a83d=new S(this['context']['locale'],_0x3dcc17);_0x48a83d['bind']('length')['to'](_0x3dcc17),_0x48a83d['bind']('isDirty')['to'](_0x3dcc17,'isDirty',_0x3dcc17,'length',(_0x2f51ae,_0xa47d8a)=>_0x2f51ae||!_0xa47d8a),_0x48a83d['bind']('isActive')['to'](_0x3dcc17),_0x48a83d['type']='comment';const _0x2d4596=new d({'view':_0x48a83d,'target':_0x50493a,'type':'comment','isVisible':!_0x3bca23['archivedAt']});return _0x3dcc17['on']('escape',()=>{_0x2d4596['fire']('escape');}),this['_bindAnnotationToEditors'](_0x3dcc17,_0x2d4596),_0x488d65['add'](_0x2d4596),_0x2d4596;}['_bindAnnotationToEditors'](_0x501cba,_0x269a07){this['listenTo'](_0x501cba,'editorReady',(_0x21a47b,_0x5e9ee4)=>{const _0x29ce99=_0x5e9ee4['ui']['view']['body']['bodyCollectionContainer'];_0x269a07['focusableElements']['add'](_0x29ce99),this['context']instanceof _0x4e56ff&&this['context']['ui']['focusTracker']['add'](_0x29ce99);},{'priority':'highest'}),this['listenTo'](_0x501cba,'editorDestroyed',(_0x1e3481,_0x5d0f87)=>{const _0x160241=_0x5d0f87['ui']['view']['body']['bodyCollectionContainer'];_0x269a07['focusableElements']['has'](_0x160241)&&_0x269a07['focusableElements']['remove'](_0x160241),this['context']instanceof _0x4e56ff&&this['context']['ui']['focusTracker']['remove'](_0x160241);});}['_unbindEditors'](_0x13ce39){this['stopListening'](_0x13ce39,'editorReady'),this['stopListening'](_0x13ce39,'editorDestroyed');}['_createCommentThreadView'](_0x3cab83){const _0x398758=this['context']['plugins']['get'](it),{config:_0x527f2e,locale:_0x534642}=this['context'],_0x4d878b=lt(_0x527f2e['get']('locale'),_0x534642);return new(0x0,(_0x527f2e['get']('comments'))['CommentThreadView'])(_0x534642,_0x3cab83,_0x398758['me'],{'editorConfig':{..._0x527f2e['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x527f2e['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x527f2e['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x527f2e['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x527f2e['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x4d878b,'CommentView':_0x527f2e['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x1317ca,channelId:_0x1855a2,resolvedAt:_0x23d5b2,resolvedBy:_0x319999,isFromAdapter:_0x3752c8}){if(!this['hasCommentThread'](_0x1317ca))throw new _0x167eaf('commentsrepository-missing-comment-thread',null,{'threadId':_0x1317ca});const _0x24fe1b=this['getCommentThread'](_0x1317ca);if(_0x24fe1b['isResolved'])throw new _0x167eaf('commentsrepository-resolved-comment-thread',null,{'threadId':_0x1317ca});const _0x5c1137=this['context']['plugins']['get'](it);if(_0x24fe1b['resolvedBy']=_0x5c1137['getUser'](_0x319999),_0x24fe1b['resolvedAt']=_0x23d5b2,_0x3752c8||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x46d8aa=this['context']['plugins']['get']('PendingActions'),_0x4562b7=_0x46d8aa['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x1855a2,'threadId':_0x1317ca})['then'](({resolvedAt:_0x49b35a,resolvedBy:_0x1aa70a})=>{_0x46d8aa['remove'](_0x4562b7),_0x24fe1b['resolvedBy']['id']!==_0x1aa70a&&(_0x24fe1b['resolvedBy']=_0x5c1137['getUser'](_0x1aa70a)),_0x24fe1b['resolvedAt']=_0x49b35a;})['catch'](_0xbf45a8=>{throw console['error'](_0xbf45a8),new _0x167eaf('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x8aae3,channelId:_0x133e1a,isFromAdapter:_0x535ad5}){if(!this['hasCommentThread'](_0x8aae3))throw new _0x167eaf('commentsrepository-missing-comment-thread',null,{'threadId':_0x8aae3});const _0x468d67=this['getCommentThread'](_0x8aae3);if(!_0x468d67['isResolved'])throw new _0x167eaf('commentsrepository-reopen-comment-thread',null,{'threadId':_0x8aae3});if(_0x468d67['resolvedBy']=null,_0x468d67['resolvedAt']=null,_0x535ad5||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x5974a3=this['context']['plugins']['get']('PendingActions'),_0x3d4a16=_0x5974a3['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x133e1a,'threadId':_0x8aae3})['then'](()=>_0x5974a3['remove'](_0x3d4a16))['catch'](_0x326fde=>{throw console['error'](_0x326fde),new _0x167eaf('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x50ed93,isFromAdapter:_0x37e560}){const _0x69e48b=this['getCommentThread'](_0x50ed93);if(!_0x69e48b)throw new _0x167eaf('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x50ed93),this['_threads']['delete'](_0x50ed93),!_0x69e48b['isSubmitted']||_0x37e560||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x1c65c4=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4fe14f}=_0x69e48b,_0x3ff56a=_0x1c65c4['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x4fe14f,'threadId':_0x50ed93})['then'](()=>_0x1c65c4['remove'](_0x3ff56a))['catch'](_0x481d19=>{throw console['error'](_0x481d19),new _0x167eaf('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x59e4a6,unlinkedAt:_0x4aa786,context:_0x2b528d,attributes:_0x21d0bd,isFromAdapter:_0x53befc}){if('string'!=typeof _0x59e4a6)throw new _0x167eaf('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x59e4a6});if(!this['hasCommentThread'](_0x59e4a6))throw new _0x167eaf('commentsrepository-missing-comment-thread',null,{'threadId':_0x59e4a6});const _0x1a5f95=this['getCommentThread'](_0x59e4a6);let _0x439623=!0x1;if(void 0x0!==_0x2b528d&&_0x1a5f95['context']!==_0x2b528d&&(_0x1a5f95['context']=_0x2b528d,_0x439623=!0x0),void 0x0!==_0x4aa786&&_0x1a5f95['unlinkedAt']!==_0x4aa786&&(_0x1a5f95['unlinkedAt']=_0x4aa786,_0x439623=!0x0),_0x21d0bd&&!wt(_0x21d0bd,_0x1a5f95['attributes'])&&(_0x1a5f95['attributes']=_0x21d0bd,_0x439623=!0x0),!_0x439623)return Promise['resolve']();if(!_0x1a5f95['isSubmitted']||_0x53befc||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x32c83f=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5a0848}=_0x1a5f95,_0x49d3de=_0x32c83f['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x5a0848,'threadId':_0x59e4a6,'context':_0x2b528d,'unlinkedAt':_0x4aa786,'attributes':_0x21d0bd})['then'](()=>_0x32c83f['remove'](_0x49d3de))['catch'](_0x2f0d1b=>{throw console['error'](_0x2f0d1b),new _0x167eaf('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x1eeb7e){const _0x538d9d=this['context']['plugins']['get'](O),_0xf338b6=this['getCommentThread'](_0x1eeb7e);if(_0xf338b6['_isAttached']=!0x1,this['_threadToController']['has'](_0xf338b6)){const _0x5cfc79=this['_threadToController']['get'](_0xf338b6),_0xa6a350=_0x5cfc79['view'],_0x58a4b0=_0x538d9d['getByInnerView'](_0xa6a350);this['_threadToController']['delete'](_0xf338b6),this['_viewToController']['delete'](_0xa6a350),_0x58a4b0&&_0x538d9d['remove'](_0x58a4b0),_0x5cfc79['destroy'](),_0xa6a350['destroy']()['then'](()=>{this['_unbindEditors'](_0xa6a350);});}}['_updateActiveAnnotation']({threadId:_0x29b59d,resolvedAt:_0x364044,unlinkedAt:_0x1624b0}){const _0x35d95d=!!_0x364044,_0x5526e7=this['context']['plugins']['get'](O),_0x38cb1d=this['getCommentThread'](_0x29b59d);if(this['_threadToController']['has'](_0x38cb1d)){const _0x19d9f2=this['_threadToController']['get'](_0x38cb1d)['view'],_0x1ba1f5=_0x5526e7['getByInnerView'](_0x19d9f2);_0x1ba1f5&&(_0x35d95d&&_0x5526e7['_removeActiveAnnotation'](_0x1ba1f5),_0x1624b0?_0x1ba1f5['isVisible']=!0x1:_0x1ba1f5['refreshVisibility']());}}['_getExternalAuthor'](_0x59b3f9){const _0x597241=this['context']['plugins']['get'](it),_0x193d51=pt('external:'+_0x59b3f9),_0x11a7dc=_0x597241['getUser'](_0x193d51);return _0x11a7dc||_0x597241['addUser']({'id':_0x193d51,'name':_0x59b3f9});}['_createNewComment']({threadId:_0x5c88d4,commentId:_0x452937=_0x1ddcfe(),content:_0x35928d,authorId:_0x28dd3c,createdAt:_0x43f2f4,attributes:_0x498c84}){if('string'!=typeof _0x452937)throw new _0x167eaf('commentsrepository-invalid-commentid');if('string'!=typeof _0x28dd3c)throw new _0x167eaf('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x35928d||!_0x35928d['trim']())throw new _0x167eaf('commentsrepository-invalid-comment-content');const _0x46b726=this['context']['plugins']['get'](it)['getUser'](_0x28dd3c);if(!_0x46b726)throw new _0x167eaf('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x28dd3c});let _0x207e68=null,_0x29f648=_0x43f2f4;return _0x498c84?.['@external']&&(_0x207e68=this['_getExternalAuthor'](_0x498c84['@external']['authorName']),_0x29f648=new Date(_0x498c84['@external']['createdAt'])),new fi(this,{'threadId':_0x5c88d4,'id':_0x452937,'author':_0x207e68||_0x46b726,'creator':_0x46b726,'content':_0x35928d,'createdAt':_0x43f2f4,'authoredAt':_0x29f648,'attributes':_0x498c84});}['_addComment'](_0x314cd1){let {threadId:_0x89bc21,content:_0x45abfd,attributes:_0x3a7dc4,isFromAdapter:_0x58ece4}=_0x314cd1;const _0x3b4000=this['getCommentThread'](_0x314cd1['threadId']);if(!_0x3b4000)throw new _0x167eaf('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x497f31=this['_createNewComment'](_0x314cd1),{id:_0x596dc9}=_0x497f31;if(_0x3b4000['_add'](_0x497f31),_0x58ece4||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x3b4000['isSubmitted'])return Promise['resolve']();const _0x55260b=this['context']['plugins']['get']('PendingActions'),{channelId:_0x55623c}=_0x3b4000,_0xb44c42=_0x55260b['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x3a7dc4||(_0x3a7dc4={}),this['adapter']['addComment']({'channelId':_0x55623c,'threadId':_0x89bc21,'commentId':_0x596dc9,'content':_0x45abfd,'attributes':_0x3a7dc4})['then'](_0x5780a5=>{_0x55260b['remove'](_0xb44c42),_0x5780a5&&this['_updateComment']({'channelId':_0x55623c,'threadId':_0x89bc21,'commentId':_0x596dc9,'createdAt':_0x5780a5['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x39fdb3=>{throw console['error'](_0x39fdb3),new _0x167eaf('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x2c1c5f,commentId:_0x134c40,content:_0x4bd8f2,createdAt:_0x10d2a6,attributes:_0x2f58ba,isFromAdapter:_0x2d288c}){if(void 0x0!==_0x4bd8f2&&('string'!=typeof _0x4bd8f2||!_0x4bd8f2['trim']()['length']))throw new _0x167eaf('commentsrepository-update-comment-invalid-content');const _0x275afe=this['getCommentThread'](_0x2c1c5f),_0x1e9688=_0x275afe['getComment'](_0x134c40);if(!_0x1e9688)throw new _0x167eaf('commentsrepository-update-missing-comment',this);let _0x4faff4=!0x1;if(_0x4bd8f2&&_0x4bd8f2!==_0x1e9688['content']&&(_0x1e9688['isEditable']||_0x2d288c)&&(_0x1e9688['content']=_0x4bd8f2,_0x4faff4=!0x0),_0x10d2a6&&_0x10d2a6!==_0x1e9688['createdAt']&&(_0x1e9688['createdAt']=_0x10d2a6,_0x1e9688['attributes']&&_0x1e9688['attributes']['@external']||(_0x1e9688['authoredAt']=_0x10d2a6),_0x4faff4=!0x0),_0x2f58ba&&!wt(_0x2f58ba,_0x1e9688['attributes'])&&(_0x1e9688['attributes']=_0x2f58ba,_0x4faff4=!0x0),!_0x4faff4)return Promise['resolve']();if(_0x275afe['fire']('commentUpdated'),_0x2d288c||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x219e54=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3d7ebe}=this['getCommentThread'](_0x1e9688['threadId']),_0xcca5b3=_0x219e54['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x3d7ebe,'threadId':_0x2c1c5f,'commentId':_0x134c40,'content':_0x4bd8f2,'attributes':_0x2f58ba})['then'](()=>_0x219e54['remove'](_0xcca5b3))['catch'](_0x11ef8f=>{throw console['error'](_0x11ef8f),new _0x167eaf('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x128de7,commentId:_0x1a1c1c,isFromAdapter:_0xad5a77}){const _0x322397=this['getCommentThread'](_0x128de7),_0x354739=_0x322397['getComment'](_0x1a1c1c);if(!_0x354739)throw new _0x167eaf('commentsrepository-remove-missing-comment',this);if(_0x322397['_remove'](_0x354739),_0xad5a77||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x38673c=this['context']['plugins']['get']('PendingActions'),{channelId:_0x5dbf1d}=_0x322397,_0x2e66aa=_0x38673c['add'](E(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x5dbf1d,'threadId':_0x128de7,'commentId':_0x1a1c1c})['then'](()=>_0x38673c['remove'](_0x2e66aa))['catch'](_0x1bd71f=>{throw console['error'](_0x1bd71f),new _0x167eaf('commentsrepository-remove-comment-internal-error',this);});}}class ui extends/* #__PURE__ -- @preserve */
30
+ _0x4a1ea7(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x49d017,_0x49c4cb){super();const _0x2440b1=_0x49c4cb['isResolvable'];this['channelId']=_0x49c4cb['channelId'],this['id']=_0x49c4cb['id'],this['comments']=new _0xfcf14(),this['_repository']=_0x49d017,this['_isAttached']=!0x1,this['_isSubmitted']=_0x49c4cb['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x49d017,'_permissions',_0x49d017,'_readOnlyChannels',()=>_0x49d017['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x49d017,'_permissions',()=>_0x49d017['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x49d017,'_permissions',()=>{const _0x34c649=_0x49d017['getPermissions'](this['channelId']);return _0x34c649['write']||_0x34c649['admin'];}),this['bind']('isResolvable')['to'](_0x49d017,'_permissions',()=>_0x2440b1&&_0x49d017['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x49c4cb['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x123c26,_0xecd2d)=>_0x123c26?_0xecd2d?_0x123c26<_0xecd2d?_0x123c26:_0xecd2d:_0x123c26:_0xecd2d),this['set']('unlinkedAt',_0x49c4cb['unlinkedAt']||null),this['set']('resolvedAt',_0x49c4cb['resolvedAt']||null),this['set']('resolvedBy',_0x49c4cb['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x4b631d=>!!_0x4b631d),this['set']('attributes',_0x49c4cb['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x52fda0,_0x43a906)=>_0x52fda0+_0x43a906['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x5ee122,id:_0x4df351}=this;this['_repository']['fire'](bt('submitCommentThread',_0x5ee122),{'channelId':_0x5ee122,'threadId':_0x4df351});}['setUnlinkedAt'](_0x4cef2e){this['_update']({'unlinkedAt':_0x4cef2e});}['resolve']({resolvedAt:_0x522b52=new Date(),resolvedBy:_0xb52a41=null,isFromAdapter:_0x4b597c=!0x1}={}){const _0x18ff7e=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x1d50c4,id:_0x36c02a}=this;this['_repository']['fire'](bt('resolveCommentThread',_0x1d50c4),{'channelId':_0x1d50c4,'threadId':_0x36c02a,'resolvedAt':_0x522b52,'resolvedBy':_0xb52a41||_0x18ff7e['id'],'isFromAdapter':_0x4b597c});}['reopen']({isFromAdapter:_0x5f2f26=!0x1}={}){const {channelId:_0x211650,id:_0x388e7c}=this;this['_repository']['fire'](bt('reopenCommentThread',_0x211650),{'channelId':_0x211650,'threadId':_0x388e7c,'isFromAdapter':_0x5f2f26});}['setContext'](_0x529e4c){this['context']||this['_update']({'context':_0x529e4c});}['setAttribute'](_0x281cae,_0x37280f){const _0x3f048b=It(this['attributes']);At(_0x3f048b,_0x281cae,_0x37280f),this['_update']({'attributes':_0x3f048b});}['removeAttribute'](_0x306d88){const _0x1d3b1b=It(this['attributes']);yt(_0x1d3b1b,_0x306d88),this['_update']({'attributes':_0x1d3b1b});}['remove']({isFromAdapter:_0x5e049f=!0x1}={}){const {channelId:_0x5f58b6,id:_0x5be07e}=this;this['_repository']['fire'](bt('removeCommentThread',_0x5f58b6),{'channelId':_0x5f58b6,'threadId':_0x5be07e,'isFromAdapter':_0x5e049f});}['attachTo'](_0x231feb){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x231feb});}['addComment'](_0xfc466c){const {channelId:_0x12a624,id:_0x57b167}=this;this['_repository']['fire'](bt('addComment',_0x12a624,_0x57b167),Object['assign']({'channelId':_0x12a624,'threadId':_0x57b167},_0xfc466c));}['getComment'](_0x29854b){if('string'!=typeof _0x29854b)throw new _0x167eaf('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x29854b});return this['comments']['get'](_0x29854b);}['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'](_0xec490a=>_0xec490a['toJSON']()),'attributes':this['attributes']};}['_add'](_0x279e4d){return this['listenTo'](_0x279e4d,'change:authoredAt',()=>{const _0x11d402=this['_findOptimalIndex'](_0x279e4d),_0x37dd1a=this['comments'];_0x11d402-0x1!=_0x37dd1a['getIndex'](_0x279e4d)&&_0x11d402+0x1!=_0x37dd1a['getIndex'](_0x279e4d)&&(this['_remove'](_0x279e4d),this['_add'](_0x279e4d));}),this['comments']['add'](_0x279e4d,this['_findOptimalIndex'](_0x279e4d));}['_update'](_0x5066d8){const {channelId:_0x12d108,id:_0x2f8c6d}=this;this['_repository']['fire'](bt('updateCommentThread',_0x12d108),{..._0x5066d8,'channelId':_0x12d108,'threadId':_0x2f8c6d});}['_remove'](_0x177d8d){return this['stopListening'](_0x177d8d),_0x177d8d['destroy'](),this['comments']['remove'](_0x177d8d);}['_findOptimalIndex'](_0x3d1c74){const _0x56957e=this['comments']['find'](_0x1340a3=>new Date(_0x1340a3['authoredAt'])['getTime']()>new Date(_0x3d1c74['authoredAt'])['getTime']());return _0x56957e?this['comments']['getIndex'](_0x56957e):this['length'];}}class fi extends/* #__PURE__ -- @preserve */
31
+ _0x4a1ea7(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x261897,_0xf37174){super();const _0x465d24=_0x261897['context']['plugins']['get'](it)['me'],_0x3aea47=_0x261897['getCommentThread'](_0xf37174['threadId']),_0x2d2581=0x0===_0x3aea47['comments']['length'],_0x28322a=_0x465d24===_0xf37174['author'];this['id']=_0xf37174['id'],this['threadId']=_0xf37174['threadId'],this['author']=_0xf37174['author'],this['creator']=_0xf37174['creator'],this['isExternal']=Boolean(_0xf37174['attributes']&&_0xf37174['attributes']['@external']),this['set']('content',_0xf37174['content']),this['createdAt']=_0xf37174['createdAt']||new Date(),this['set']('authoredAt',_0xf37174['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x3aea47,'resolvedAt'),this['set']('attributes',_0xf37174['attributes']||{}),this['bind']('isEditable')['to'](_0x261897,'_permissions',()=>{const _0x4f69ff=_0x261897['getPermissions'](_0x3aea47['channelId'])['write'],_0xe07f63=_0x261897['getPermissions'](_0x3aea47['channelId'])['modifyAll'];return _0x28322a&&_0x4f69ff||!_0x28322a&&_0xe07f63;}),this['bind']('isRemovable')['to'](_0x3aea47,'isRemovable',_0x261897,'_permissions',_0x4282c7=>{const _0x54675a=_0x261897['getPermissions'](_0x3aea47['channelId'])['write'],_0x51c110=_0x261897['getPermissions'](_0x3aea47['channelId'])['modifyAll'];return _0x28322a&&_0x54675a||_0x4282c7&&_0x2d2581||!_0x28322a&&_0x51c110&&!_0x2d2581;}),this['bind']('isReadOnly')['to'](_0x3aea47,'isReadOnly'),this['_repository']=_0x261897;}get['weight'](){return Math['max'](function(_0x10c315){const _0x4be5ea=document['createElement']('div');return _0x4be5ea['innerHTML']=_0x10c315,_0x4be5ea['textContent']['length'];}(this['content']),0xc8);}['update'](_0x5323cc){const {threadId:_0x1a10a9,id:_0x3ae35f}=this;if(!this['_repository']['hasCommentThread'](_0x1a10a9))throw new _0x167eaf('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x194e8e}=this['_repository']['getCommentThread'](_0x1a10a9);this['_repository']['fire'](bt('updateComment',_0x194e8e,_0x1a10a9),{'channelId':_0x194e8e,'threadId':_0x1a10a9,'commentId':_0x3ae35f,..._0x5323cc});}['setAttribute'](_0x2db2ad,_0x3d564a){const _0x5e35cd=It(this['attributes']);At(_0x5e35cd,_0x2db2ad,_0x3d564a),this['update']({'attributes':_0x5e35cd});}['removeAttribute'](_0x37620a){const _0x2c5cff=It(this['attributes']);yt(_0x2c5cff,_0x37620a),this['update']({'attributes':_0x2c5cff});}['remove'](_0x2767ee={}){if(!_0x2767ee['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x494a6c,id:_0x3211fb}=this;if(!this['_repository']['hasCommentThread'](_0x494a6c))throw new _0x167eaf('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x116f1e}=this['_repository']['getCommentThread'](_0x494a6c);this['_repository']['fire'](bt('removeComment',_0x116f1e,_0x494a6c),{'channelId':_0x116f1e,'threadId':_0x494a6c,'commentId':_0x3211fb,..._0x2767ee});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function bt(_0x412d59,..._0xf415ef){for(const _0x135bb0 of _0xf415ef)void 0x0!==_0x135bb0&&(_0x412d59+=':'+String(_0x135bb0));return _0x412d59;}class J extends _0x3fcef6{['refresh'](){const _0x1f6b8d=this['editor']['model']['document']['selection'];for(const _0x36349e of _0x1f6b8d['getRanges']())if(this['_hasContent'](_0x36349e))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['execute']({threadId:_0x1ef97a=_0x1ddcfe()}={}){const _0x108fa8=this['editor']['model'],_0x4ce335=[];for(const _0x1f6236 of _0x108fa8['document']['selection']['getRanges']())this['_hasContent'](_0x1f6236)&&_0x4ce335['push'](this['_trimToContent'](_0x1f6236));_0x108fa8['change'](_0x3289de=>{for(const _0x3b65f2 of _0x4ce335){const _0x1d8940=_0x1ddcfe()['substr'](0x1,0x5),_0x15e391='comment:'+_0x1ef97a+':'+_0x1d8940;_0x3289de['addMarker'](_0x15e391,{'range':_0x3b65f2,'usingOperation':!0x1,'affectsData':!0x1});}});}['_hasContent'](_0x56e05f){for(const _0x3080ca of _0x56e05f['getItems']())if(this['_itemIsContent'](_0x3080ca))return!0x0;return!0x1;}['_itemIsContent'](_0x196652){return _0x196652['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x196652)&&!_0x196652['is']('element','tableCell');}['_trimToContent'](_0x811d30){const _0x5d2b7f=_0x2441d6=>!this['_itemIsContent'](_0x2441d6['item']),_0x110b9a=_0x811d30['start']['getLastMatchingPosition'](_0x5d2b7f),_0x52cbc7=_0x811d30['end']['getLastMatchingPosition'](_0x5d2b7f,{'direction':'backward'});return this['editor']['model']['createRange'](_0x110b9a,_0x52cbc7);}}class P extends _0x599ac2{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[O];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x353a9a){super(_0x353a9a),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x191b06=this['editor'],_0x22f341=_0x191b06['model']['document']['selection'],_0x225ee5=_0x41a349(()=>this['refreshSelectedViews'](),0xa);_0x22f341['on']('change:range',(_0x5105ee,_0x185600)=>{_0x185600['directChange']&&(_0x225ee5['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x191b06['editing']['view']['document'],'change:isFocused',(_0x5a0ba9,_0x3bbb0c,_0x28cce7)=>{_0x28cce7&&_0x225ee5();}),this['listenTo'](_0x191b06['ui']['focusTracker'],'change:isFocused',(_0x3de478,_0xdd7f99,_0x2291e0)=>{_0x2291e0||_0x191b06['isReadOnly']||this['fire']('blur',{'isAnnotationTracked':_0x2169b7=>this['_editorAnnotationsData']['has'](_0x2169b7['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x3f2336){if(this['_editorAnnotations']['has'](_0x3f2336['view']))return;this['_editorAnnotations']['add'](_0x3f2336['view']),this['editor']['ui']['focusTracker']['add'](_0x3f2336['view']['element']);const _0x3eaccf=this['editor']['plugins']['get'](O);this['listenTo'](_0x3eaccf['collection'],'remove',(_0x1bc4e0,_0x1c5482)=>{this['editor']['ui']['focusTracker']['remove'](_0x1c5482['view']['element']),this['_editorAnnotations']['delete'](_0x1c5482['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x5978d3){if('function'!=typeof _0x5978d3)throw new _0x167eaf('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x5978d3);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x49d129,annotations:_0x1643fb}){const _0x44f2d7=[],_0x413c13=this['editor']['model']['document']['selection'],_0x2eee24=Array['from'](_0x413c13['getRanges']());for(const [_0x63119e,_0x14467c]of this['_editorAnnotationsData']){const _0x45f089=_0x330c2b(_0x14467c),_0x410fe1=_0x1643fb['getByInnerView'](_0x63119e);_0x45f089&&_0x410fe1&&_0x44f2d7['push']({'annotation':_0x410fe1,'range':_0x45f089});}function _0x330c2b(_0x193199){for(const _0x4c0cda of _0x193199)for(const _0x42c401 of _0x2eee24)if(_0x4c0cda['containsRange'](_0x42c401,!_0x413c13['isCollapsed']))return _0x4c0cda;return null;}return _0x44f2d7['sort']((_0x3709d4,_0x48759a)=>{const _0x142079=_0x3709d4['range'],_0xf41949=_0x48759a['range'];if(!_0x142079['isEqual'](_0xf41949)){if(_0x142079['containsRange'](_0xf41949,!0x0))return 0x1;if(_0xf41949['containsRange'](_0x142079,!0x0))return-0x1;}return _0x3709d4['annotation']==_0x49d129?-0x1:_0x48759a['annotation']==_0x49d129?0x1:0x0;})['map'](_0x2819a2=>_0x2819a2['annotation']);}get['_editorAnnotationsData'](){const _0x3e38be=new Map();for(const _0x180526 of Array['from'](this['_dataCollectors']))for(const [_0x2db46c,_0x174c4f]of _0x180526())_0x3e38be['set'](_0x2db46c,_0x174c4f);return _0x3e38be;}}class st extends _0x599ac2{['afterInit'](){const _0x38af18=this['editor'];if(!_0x38af18['plugins']['has']('RestrictedEditingModeEditing'))return;_0x38af18['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x599ac2{constructor(_0x4ef147){super(_0x4ef147),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x3baa0b=this['editor'],_0x1d6230=_0x3baa0b['commands']['get']('importWord'),_0x4ff45d=_0x3baa0b['plugins']['get'](it);_0x1d6230&&(_0x1d6230['on']('execute',(_0x5c0ca7,[,_0x2270f6])=>{_0x2270f6['collaboration_features']={'comments':!0x0,'user_id':_0x4ff45d['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x1d6230,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x10d0ae,_0x493269){const {comment_threads:_0x1926c7}=_0x493269;_0x1926c7&&_0x1926c7['forEach'](({thread_id:_0x54c8ec,comments:_0x5d90e7,is_resolved:_0x1d766f})=>{const _0x2a09d4=new Date(),_0x404aff=_0x5d90e7['map'](({author:_0x52bbe4,content:_0x2a7d3c,created_at:_0x36f35b})=>({'content':_0x2a7d3c,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x2a09d4,'attributes':{'@external':{'authorName':_0x52bbe4,'createdAt':_0x36f35b?new Date(_0x36f35b):new Date(),'source':'importWord'}}})),_0x499870=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x499870,'threadId':_0x54c8ec,'comments':_0x404aff,'resolvedAt':_0x1d766f?_0x2a09d4:null});});}}class at extends _0x599ac2{constructor(_0x125d35){super(_0x125d35),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x5c4fc0=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x5c4fc0,'contentInsertion',(_0x5d37d7,_0x345005)=>this['_removeMarkersWithoutThreads'](_0x345005['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x399e49){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x399e49;const _0x2ab344=this['editor']['plugins']['get']('CommentsRepository');for(const _0xbeee6b of _0x399e49['keys']()){const [_0x50c357,_0x5d01e1]=_0xbeee6b['split'](':');'comment'!=_0x50c357||_0x2ab344['hasCommentThread'](_0x5d01e1)||_0x399e49['delete'](_0xbeee6b);}return _0x399e49;}['_registerMarkerInClipboardPipeline'](){const _0x4daf3c=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x79514e=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x79514e&&_0x4daf3c['_registerMarkerToCopy']('comment',_0x79514e);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x55a514){switch(_0x55a514){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 _0x599ac2{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x5f2f53,_0x2ec9b4)=>{if(!_0x2ec9b4['options']['showCommentHighlights'])return null;if(_0x2ec9b4['options']['ignoreResolvedComments']){const {id:_0x28e50b}=er(_0x5f2f53['markerName']),_0x208f0e=this['editor']['plugins']['get'](o);if(_0x208f0e['getCommentThread'](_0x28e50b)?.['isResolved']&&_0x5f2f53['item'])return _0x2ec9b4['consumable']['consume'](_0x5f2f53['item'],'addMarker:'+_0x5f2f53['markerName']),_0x2ec9b4['consumable']['consume'](_0x5f2f53['item'],'removeMarker:'+_0x5f2f53['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x3ef4f6=>{_0x3ef4f6['on']('addMarker:comment',(_0xdac9e1,_0x287017,_0x34c86d)=>{if(!_0x34c86d['options']['showCommentHighlights'])return;const _0x1518a2=_0x287017['item'];if(!_0x1518a2)return;const _0x30b5a6=_0x34c86d['mapper']['toViewElement'](_0x1518a2);this['editor']['model']['schema']['isObject'](_0x1518a2)&&_0x30b5a6&&!_0x30b5a6['getCustomProperty']('widget')&&_0x30b5a6['is']('containerElement')&&_0x1690d4(_0x30b5a6,_0x34c86d['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x33d065,{writer:_0x14d4dc,options:_0x276f1c})=>{if(!_0x276f1c['showCommentHighlights'])return null;const _0x2a44e8=_0x14d4dc['createContainerElement']('div'),_0x33953=_0x14d4dc['createEmptyElement']('hr');return _0x14d4dc['addClass']('ck-horizontal-line',_0x2a44e8),_0x14d4dc['insert'](_0x14d4dc['createPositionAt'](_0x2a44e8,0x0),_0x33953),_0x2a44e8;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x28c9b4,{writer:_0x326d27,options:_0x47f3a1})=>{if(!_0x47f3a1['showCommentHighlights'])return null;const _0x2ec752=_0x326d27['createContainerElement']('span'),_0x3cb517=_0x326d27['createEmptyElement']('img');return _0x326d27['addClass']('image-inline',_0x2ec752),_0x326d27['insert'](_0x326d27['createPositionAt'](_0x2ec752,0x0),_0x3cb517),_0x2ec752;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x413612,{writer:_0x16efb1,options:_0x1644c9})=>{if(_0x1644c9['showCommentHighlights'])return _0x16efb1['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x26ec34,_0x1aa730,_0x294a39)=>{_0x294a39['options']['showCommentHighlights']&&_0x26ec34['stop']();},{'priority':'high'});}}class r extends _0x599ac2{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(_0x2f2524){super(_0x2f2524),this['set']('isThreadsLoadingPaused',!0x0),_0x2f2524['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x504ff6,_0x4953de,_0x4e0004,_0x332efd)=>{const _0x46f7df=_0x2f2524['plugins']['get'](o),_0x55a5ee=_0x4e0004?er(_0x4e0004)['id']:null;_0x2f2524['model']['change'](()=>{if(_0x55a5ee){const _0x367986=this['getAllMarkersForId'](_0x55a5ee);for(const _0x4939f4 of _0x367986)_0x2f2524['editing']['reconvertMarker'](_0x4939f4);}if(_0x332efd){const {id:_0x4e8a8e}=er(_0x332efd),_0x3da078=_0x46f7df['getCommentThread'](_0x4e8a8e);if(_0x3da078&&_0x3da078['unlinkedAt'])return;if(_0x3da078&&!_0x3da078['isAttached'])return;const _0x54d760=this['getAllMarkersForId'](_0x4e8a8e);for(const _0x4c7383 of _0x54d760)_0x2f2524['editing']['reconvertMarker'](_0x4c7383);}}),_0x55a5ee&&this['scrollToThreadMarker'](_0x55a5ee);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x4102bd=this['editor'],_0x50b936=_0x4102bd['plugins']['get'](o),_0x2a81b3=_0x4102bd['config']['get']('collaboration.channelId'),_0x8b0598=_0x50b936['getCommentThreads']()['filter'](_0x374f91=>_0x374f91['channelId']!==_0x2a81b3);_0x4102bd['commands']['add']('addCommentThread',new J(_0x4102bd)),this['listenTo'](_0x4102bd,'change:isReadOnly',(_0x4eb67b,_0x31907d,_0x21a6e6)=>{_0x50b936['switchReadOnly'](_0x21a6e6,_0x4102bd['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x50b936,ft('addCommentThread',_0x2a81b3),(_0x3bf421,{threadId:_0x824a34})=>{const _0xa0449e=this['editor']['plugins']['get'](o)['getCommentThread'](_0x824a34);_0xa0449e?.['unlinkedAt']&&this['_attachArchivedThread'](_0x824a34);}),this['listenTo'](_0x50b936,ft('removeCommentThread',_0x2a81b3),(_0x2befe9,{threadId:_0x1f06e0})=>{_0x4102bd['model']['enqueueChange']({'isUndoable':!0x1},_0x1af05a=>{const _0x346977=this['getAllMarkersForId'](_0x1f06e0);for(const _0x19d90e of _0x346977)_0x1af05a['removeMarker'](_0x19d90e);});}),this['listenTo'](_0x50b936,ft('resolveCommentThread',_0x2a81b3),(_0x55b597,{threadId:_0x2b7776})=>{(this['_reconvertMarkers'](_0x2b7776),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x2b7776)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x50b936,ft('reopenCommentThread',_0x2a81b3),(_0x3cd3c4,{threadId:_0x54d1e1})=>{this['_reconvertMarkers'](_0x54d1e1);},{'priority':'low'}),this['listenTo'](_0x50b936,ft('addComment',_0x2a81b3),(_0x19621d,{threadId:_0x68a915,isFromAdapter:_0x48c6fd})=>{const _0x2c92fd=this['getAllMarkersForId'](_0x68a915);if(_0x48c6fd||0x0==_0x2c92fd['length']||!_0x50b936['hasCommentThread'](_0x68a915))return;0x1===_0x50b936['getCommentThread'](_0x68a915)['length']&&_0x4102bd['model']['enqueueChange']({'isUndoable':!0x1},_0x120f2=>{for(const _0x1d2c2f of _0x2c92fd)_0x120f2['updateMarker'](_0x1d2c2f,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x8b0598);}['afterInit'](){!async function(_0x1e7f20){const _0x3ede8d=_0x4c9ed1([0x36,0x4f,0x66,0x55,0x50,0x49,0x6a,0x41,0x75,0x38,0x71,0x4d,0x62,0x56,0x42,0x4c,0x44,0x33,0x35,0x51,0x52,0x4b,0x32,0x79,0x74,0x39,0x67,0x53,0x70,0x65,0x64,0x6e,0x6c,0x69,0x5a,0x57,0x34,0x46,0x47,0x48,0x58,0x77,0x76,0x30,0x59,0x63,0x7a,0x73,0x6b,0x31,0x45,0x68,0x4a,0x6d,0x43,0x78,0x72,0x54,0x37,0x4e,0x61,0x6f]),_0x50ec53=0x4b21b64a,_0x33493c=0x4b26d13a^_0x50ec53,_0x3d5561=window[_0x4c9ed1([0x44,0x61,0x74,0x65])][_0x4c9ed1([0x6e,0x6f,0x77])](),_0x5e9576=_0x1e7f20[_0x4c9ed1([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x30c6a1=new window[(_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1007db=>{_0x5e9576[_0x4c9ed1([0x6f,0x6e,0x63,0x65])](_0x4c9ed1([0x72,0x65,0x61,0x64,0x79]),_0x1007db);}),_0x276561={[_0x4c9ed1([0x6b,0x74,0x79])]:_0x4c9ed1([0x45,0x43]),[_0x4c9ed1([0x75,0x73,0x65])]:_0x4c9ed1([0x73,0x69,0x67]),[_0x4c9ed1([0x63,0x72,0x76])]:_0x4c9ed1([0x50,0x2d,0x32,0x35,0x36]),[_0x4c9ed1([0x78])]:_0x4c9ed1([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]),[_0x4c9ed1([0x79])]:_0x4c9ed1([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]),[_0x4c9ed1([0x61,0x6c,0x67])]:_0x4c9ed1([0x45,0x53,0x32,0x35,0x36])},_0xe5e143=_0x5e9576[_0x4c9ed1([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4c9ed1([0x67,0x65,0x74])](_0x4c9ed1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3b3f34(){let _0x2e9ef3,_0x48b199=null,_0x5e0c6a=null;try{if(_0xe5e143==_0x4c9ed1([0x47,0x50,0x4c]))return _0x4c9ed1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2e9ef3=_0x497433(),!_0x2e9ef3)return _0x4c9ed1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2e9ef3[_0x4c9ed1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5e0c6a=_0x210246(_0x2e9ef3[_0x4c9ed1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2e9ef3[_0x4c9ed1([0x6a,0x74,0x69])])),await _0x1281f2()?_0x49de67()?_0x4749e9()?_0x4c9ed1([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x34b8cc()?(_0x2e9ef3[_0x4c9ed1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4c9ed1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x48b199=_0x3dd12d(_0x4c9ed1([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2e9ef3[_0x4c9ed1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4c9ed1([0x74,0x72,0x69,0x61,0x6c])&&(_0x48b199=_0x3dd12d(_0x4c9ed1([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2f0595()):_0x4c9ed1([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4c9ed1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4c9ed1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x420b63){return _0x4c9ed1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4749e9(){const _0x4826ce=[_0x4c9ed1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4c9ed1([0x74,0x72,0x69,0x61,0x6c])][_0x4c9ed1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e9ef3[_0x4c9ed1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3d5561/0x3e8:0xe10*_0x33493c;return _0x2e9ef3[_0x4c9ed1([0x65,0x78,0x70])]<_0x4826ce;}function _0x49de67(){const _0x2a4110=_0x2e9ef3[_0x4c9ed1([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2a4110)return!0x1;if(_0x2a4110[_0x4c9ed1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c9ed1([0x2a])))return!0x0;if(_0x2a4110[_0x4c9ed1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c9ed1([0x43,0x4d,0x54])))return!0x0;if(_0x2a4110[_0x4c9ed1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c9ed1([0x52,0x43,0x4d,0x54]))){if(_0x58120e())return!0x0;if(_0x230539()||_0x3b1fe2())return!0x0;}return!0x1;}function _0x34b8cc(){const _0x57ed67=_0x2e9ef3[_0x4c9ed1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x57ed67||0x0==_0x57ed67[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4526f7}=new URL(window[_0x4c9ed1([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x57ed67[_0x4c9ed1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4526f7))return!0x0;const _0x3e3695=_0x4526f7[_0x4c9ed1([0x73,0x70,0x6c,0x69,0x74])](_0x4c9ed1([0x2e]));return _0x57ed67[_0x4c9ed1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1f3405=>_0x1f3405[_0x4c9ed1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c9ed1([0x2a])))[_0x4c9ed1([0x6d,0x61,0x70])](_0x457f7d=>_0x457f7d[_0x4c9ed1([0x73,0x70,0x6c,0x69,0x74])](_0x4c9ed1([0x2e])))[_0x4c9ed1([0x73,0x6f,0x6d,0x65])](_0x54e936=>_0x3e3695[_0x4c9ed1([0x65,0x76,0x65,0x72,0x79])]((_0x283b95,_0x18474e)=>_0x54e936[_0x18474e]===_0x283b95||_0x54e936[_0x18474e]===_0x4c9ed1([0x2a])));}function _0x2f0595(){return _0x48b199&&_0x5e0c6a?new window[(_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1922fb,_0x7367da)=>{_0x48b199[_0x4c9ed1([0x74,0x68,0x65,0x6e])](_0x1922fb,_0x7367da),_0x5e0c6a[_0x4c9ed1([0x74,0x68,0x65,0x6e])](_0x1affbb=>{_0x1affbb!=_0x4c9ed1([0x56,0x61,0x6c,0x69,0x64])&&_0x1922fb(_0x1affbb);},_0x7367da);}):_0x48b199||_0x5e0c6a||_0x4c9ed1([0x56,0x61,0x6c,0x69,0x64]);}}function _0x210246(_0x2165fd,_0x50dc23){return new window[(_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1f2d68=>{if(_0x22f8bc())return _0x1f2d68(_0x4c9ed1([0x56,0x61,0x6c,0x69,0x64]));_0x57ba3f(),_0x5e9576[_0x4c9ed1([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4c9ed1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x24cb95=!0x1;const _0x453b7c=_0x1ddcfe();function _0x5026c9(_0x5bdb13){return!!_0x5bdb13&&(typeof _0x5bdb13===_0x4c9ed1([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5bdb13===_0x4c9ed1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5bdb13[_0x4c9ed1([0x74,0x68,0x65,0x6e])]===_0x4c9ed1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5bdb13[_0x4c9ed1([0x63,0x61,0x74,0x63,0x68])]===_0x4c9ed1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x15c02c(_0x30d2bb){_0x5a497a(_0x30d2bb)[_0x4c9ed1([0x74,0x68,0x65,0x6e])](_0x29795a=>{if(!_0x29795a||_0x29795a[_0x4c9ed1([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4c9ed1([0x6f,0x6b]))return _0x4c9ed1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3cfd2b(_0x4855c6(_0x453b7c+_0x50dc23))!=_0x29795a[_0x4c9ed1([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4c9ed1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4c9ed1([0x56,0x61,0x6c,0x69,0x64]);})[_0x4c9ed1([0x74,0x68,0x65,0x6e])](_0x32a94a=>(_0x130a2a(),_0x32a94a),()=>{const _0x2a054a=_0x35c6fa();return null==_0x2a054a?(_0x130a2a(),_0x4c9ed1([0x56,0x61,0x6c,0x69,0x64])):_0x4c9ed1(_0x3d5561-_0x2a054a>(0x6f2d324a^_0x50ec53)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4c9ed1([0x74,0x68,0x65,0x6e])](_0x1f2d68)[_0x4c9ed1([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1f2d68(_0x4c9ed1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0xd6dbf4=0x4b1758ca^_0x50ec53;function _0x130a2a(){const _0x5cf540=_0x4c9ed1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3cfd2b(_0x4855c6(_0x2165fd)),_0x169328=_0xa5b738(_0x3cfd2b(window[_0x4c9ed1([0x4d,0x61,0x74,0x68])][_0x4c9ed1([0x63,0x65,0x69,0x6c])](_0x3d5561/_0xd6dbf4)));window[_0x4c9ed1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4c9ed1([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5cf540,_0x169328);}function _0x35c6fa(){const _0x4f8063=_0x4c9ed1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3cfd2b(_0x4855c6(_0x2165fd)),_0x710ea5=window[_0x4c9ed1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4c9ed1([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4f8063);return _0x710ea5?window[_0x4c9ed1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xa5b738(_0x710ea5),0x10)*_0xd6dbf4:null;}function _0x5a497a(_0x535fea){return new window[(_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4dfedb,_0x55178b)=>{_0x535fea[_0x4c9ed1([0x74,0x68,0x65,0x6e])](_0x4dfedb,_0x55178b),window[_0x4c9ed1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x55178b,0x4b20628a^_0x50ec53);});}}_0x5e9576[_0x4c9ed1([0x6f,0x6e])](_0x4c9ed1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x52bd97,_0x36afe4)=>{if(_0x36afe4[0x0]!=_0x2165fd)return _0x1f2d68(_0x4c9ed1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x36afe4[0x1]={..._0x36afe4[0x1],[_0x4c9ed1([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x453b7c};},{[_0x4c9ed1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4c9ed1([0x68,0x69,0x67,0x68])}),_0x5e9576[_0x4c9ed1([0x6f,0x6e])](_0x4c9ed1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x358ec8=>{_0x5026c9(_0x358ec8[_0x4c9ed1([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x24cb95=!0x0,_0x15c02c(_0x358ec8[_0x4c9ed1([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4c9ed1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4c9ed1([0x6c,0x6f,0x77])}),_0x30c6a1[_0x4c9ed1([0x74,0x68,0x65,0x6e])](()=>{_0x24cb95||_0x1f2d68(_0x4c9ed1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x22f8bc(){return _0x5e9576[_0x4c9ed1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4c9ed1([0x76,0x69,0x65,0x77])][_0x4c9ed1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4c9ed1([0x61,0x75,0x74,0x6f]);}function _0x57ba3f(){_0x5e9576[_0x4c9ed1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4c9ed1([0x76,0x69,0x65,0x77])][_0x4c9ed1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4c9ed1([0x61,0x75,0x74,0x6f]);}}function _0x3dd12d(_0x3abdcd){const _0x2d5704=[new window[(_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x560f69=>setTimeout(_0x560f69,0x4b288886^_0x50ec53)),_0x30c6a1[_0x4c9ed1([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x16d590=>{let _0x41712a=0x0;_0x5e9576[_0x4c9ed1([0x6d,0x6f,0x64,0x65,0x6c])][_0x4c9ed1([0x6f,0x6e])](_0x4c9ed1([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x5cbcbd,_0x3cef50)=>{_0x3cef50[0x0][_0x4c9ed1([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x41712a++,_0x41712a==(0x4b21b7b2^_0x50ec53)&&(_0x16d590(),_0x5cbcbd[_0x4c9ed1([0x6f,0x66,0x66])]());});}))];return window[_0x4c9ed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4c9ed1([0x72,0x61,0x63,0x65])](_0x2d5704)[_0x4c9ed1([0x74,0x68,0x65,0x6e])](()=>_0x3abdcd);}async function _0x530fab(){await _0x30c6a1,_0x5e9576[_0x4c9ed1([0x6d,0x6f,0x64,0x65,0x6c])][_0x4c9ed1([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x37c2ca,_0x5e9576[_0x4c9ed1([0x6d,0x6f,0x64,0x65,0x6c])][_0x4c9ed1([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x37c2ca,_0x5e9576[_0x4c9ed1([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4c9ed1([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x58120e(){return _0x8037bd(_0x4c9ed1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x436fa1(_0x4c9ed1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4c9ed1([0x73,0x74,0x61,0x74,0x65])]==_0x4c9ed1([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x230539(){return _0x8037bd(_0x4c9ed1([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 _0x3b1fe2(){return _0x8037bd(_0x4c9ed1([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4a0bf5(_0x2ffe45){const _0x27c0f6=_0x17934e();_0x5e9576[_0x27c0f6]=_0x4c9ed1([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x2ffe45,_0x2ffe45!=_0x4c9ed1([0x56,0x61,0x6c,0x69,0x64])&&_0x530fab();}function _0x17934e(){const _0x14cd49=window[_0x4c9ed1([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4c9ed1([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4c9ed1([0x6e,0x6f,0x77])]())[_0x4c9ed1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4c9ed1([0x2e]),'');let _0x13fbaf=_0x4c9ed1([0x4f]);for(let _0x24008c=0x0;_0x24008c<_0x14cd49[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x24008c+=0x2){let _0x460780=window[_0x4c9ed1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x14cd49[_0x4c9ed1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x24008c,_0x24008c+0x2));_0x460780>=_0x3ede8d[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x460780-=_0x3ede8d[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x13fbaf+=_0x3ede8d[_0x460780];}return _0x13fbaf;}function _0x497433(){const _0x94183c=_0xe5e143[_0x4c9ed1([0x73,0x70,0x6c,0x69,0x74])](_0x4c9ed1([0x2e]));if(0x3!=_0x94183c[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x706092(_0x94183c[0x1]);function _0x706092(_0x910e5b){const _0x226f6f=_0x31371(_0x910e5b);return _0x226f6f&&_0x3a695b()?_0x226f6f:null;function _0x3a695b(){const _0x15dd01=_0x226f6f[_0x4c9ed1([0x6a,0x74,0x69])],_0x4f2e15=window[_0x4c9ed1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x15dd01[_0x4c9ed1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x15dd01[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1b9031={..._0x226f6f,[_0x4c9ed1([0x6a,0x74,0x69])]:_0x15dd01[_0x4c9ed1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x15dd01[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1b9031[_0x4c9ed1([0x76,0x63])],_0x4855c6(_0x1b9031)==_0x4f2e15;}}}async function _0x1281f2(){let _0x5465c9=!0x0;try{const _0x2aa1b2=_0xe5e143[_0x4c9ed1([0x73,0x70,0x6c,0x69,0x74])](_0x4c9ed1([0x2e])),[_0x23c19a,_0x376fdb,_0x53fa11]=_0x2aa1b2;return _0xb65da2(_0x23c19a),await _0x21563e(_0x23c19a,_0x376fdb,_0x53fa11),_0x5465c9;}catch(_0x545d2c){return!0x1;}function _0xb65da2(_0x539e96){const _0x38d63b=_0x31371(_0x539e96);_0x38d63b&&_0x38d63b[_0x4c9ed1([0x61,0x6c,0x67])]==_0x4c9ed1([0x45,0x53,0x32,0x35,0x36])||(_0x5465c9=!0x1);}async function _0x21563e(_0xcdf07c,_0x54db78,_0x42f128){const _0x586f9c=window[_0x4c9ed1([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4c9ed1([0x66,0x72,0x6f,0x6d])](_0x33725b(_0x42f128),_0x2c7b39=>_0x2c7b39[_0x4c9ed1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x187630=new window[(_0x4c9ed1([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4c9ed1([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xcdf07c+_0x4c9ed1([0x2e])+_0x54db78),_0x2bb23b=window[_0x4c9ed1([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4c9ed1([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x2bb23b)return;const _0x599c31=await _0x2bb23b[_0x4c9ed1([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4c9ed1([0x6a,0x77,0x6b]),_0x276561,{[_0x4c9ed1([0x6e,0x61,0x6d,0x65])]:_0x4c9ed1([0x45,0x43,0x44,0x53,0x41]),[_0x4c9ed1([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4c9ed1([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4c9ed1([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x2bb23b[_0x4c9ed1([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4c9ed1([0x6e,0x61,0x6d,0x65])]:_0x4c9ed1([0x45,0x43,0x44,0x53,0x41]),[_0x4c9ed1([0x68,0x61,0x73,0x68])]:{[_0x4c9ed1([0x6e,0x61,0x6d,0x65])]:_0x4c9ed1([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x599c31,_0x586f9c,_0x187630)||(_0x5465c9=!0x1);}}function _0x31371(_0x3c257e){return _0x3c257e[_0x4c9ed1([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4c9ed1([0x65,0x79]))?JSON[_0x4c9ed1([0x70,0x61,0x72,0x73,0x65])](_0x33725b(_0x3c257e)):null;}function _0x33725b(_0x4cdb3b){return window[_0x4c9ed1([0x61,0x74,0x6f,0x62])](_0x4cdb3b[_0x4c9ed1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4c9ed1([0x2b]))[_0x4c9ed1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4c9ed1([0x2f])));}function _0x4855c6(_0x4b49a7){let _0x319c67=0x1505;function _0xaf3dc3(_0x213b99){for(let _0x46c192=0x0;_0x46c192<_0x213b99[_0x4c9ed1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x46c192++){const _0x547414=_0x213b99[_0x4c9ed1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x46c192);_0x319c67=(_0x319c67<<0x5)+_0x319c67+_0x547414,_0x319c67&=_0x319c67;}}function _0x3098ba(_0x50cf12){Array[_0x4c9ed1([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x50cf12)?_0x50cf12[_0x4c9ed1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3098ba):_0x50cf12&&typeof _0x50cf12==_0x4c9ed1([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4c9ed1([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x50cf12)[_0x4c9ed1([0x73,0x6f,0x72,0x74])]()[_0x4c9ed1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x9f2b05,_0x3d7687])=>{_0xaf3dc3(_0x9f2b05),_0x3098ba(_0x3d7687);}):_0xaf3dc3(window[_0x4c9ed1([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x50cf12));}return _0x3098ba(_0x4b49a7),_0x319c67>>>0x0;}function _0x3cfd2b(_0x163788){return _0x163788[_0x4c9ed1([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4c9ed1([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4c9ed1([0x30]));}function _0xa5b738(_0x1d0dfb){return _0x1d0dfb[_0x4c9ed1([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4c9ed1([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4c9ed1([0x6a,0x6f,0x69,0x6e])]('');}function _0x8037bd(_0x3ee2de){return _0x5e9576[_0x4c9ed1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4c9ed1([0x68,0x61,0x73])](_0x3ee2de);}function _0x436fa1(_0x59c77a){return _0x5e9576[_0x4c9ed1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4c9ed1([0x67,0x65,0x74])](_0x59c77a);}function _0x37c2ca(){}function _0x4c9ed1(_0x1fd390){return _0x1fd390['map'](_0x3238cc=>String['fromCharCode'](_0x3238cc))['join']('');}_0x4a0bf5(await _0x3b3f34());}(this);}['destroy'](){const _0x42ebe1=this['editor']['plugins']['get'](o),_0x2c99bf=this['editor']['config']['get']('collaboration.channelId');for(const _0x5569e2 of _0x42ebe1['getCommentThreads']({'channelId':_0x2c99bf}))_0x42ebe1['_detachCommentThread'](_0x5569e2['id']),_0x42ebe1['_threads']['delete'](_0x5569e2['id']);super['destroy']();}['hasMarkerForId'](_0x59b56a){return this['getAllMarkersForId'](_0x59b56a)['length']>0x0;}['getAllMarkersForId'](_0x197a98){const _0x2ae34c=[];for(const _0x46ec60 of this['editor']['model']['markers'])_0x46ec60['name']['startsWith']('comment:'+_0x197a98)&&_0x2ae34c['push'](_0x46ec60);return _0x2ae34c;}['scrollToThreadMarker'](_0x29a45a){const _0x6e6d2e=this['_getTargetForId'](_0x29a45a);_0x6e6d2e&&setTimeout(()=>{this['activeMarker']&&er(this['activeMarker'])['id']===_0x29a45a&&rt({'target':_0x6e6d2e[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x1bcbab){this['editor']['model']['change'](()=>{for(const _0x3be0fa of this['getAllMarkersForId'](_0x1bcbab))this['editor']['editing']['reconvertMarker'](_0x3be0fa);});}['_attachArchivedThread'](_0x3666e7){const _0x5be4c8=this['editor']['plugins']['get'](o),_0x49094b=this['editor']['plugins']['get'](P),_0x3d6a0c=_0x5be4c8['getCommentThread'](_0x3666e7);if(!_0x3d6a0c['isAttached']){const _0x150eac=_0x3d6a0c['attachTo'](()=>this['_getTargetForId'](_0x3d6a0c['id']));_0x49094b['registerAnnotation'](_0x150eac),_0x3d6a0c['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x5419c9=this['editor'],_0x21ecc6=_0x5419c9['plugins']['get'](it);_0x5419c9['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x3274b7,_0x491693)=>{const {id:_0x4e114a}=er(_0x3274b7['markerName']),_0x43124d=_0x5419c9['plugins']['get'](o)['getCommentThread'](_0x4e114a),_0xfd006a=this['activeMarker']&&er(this['activeMarker'])['id']===_0x4e114a;let _0x498117;if(_0x43124d&&_0x43124d['isResolved']&&!_0xfd006a&&_0x3274b7['item'])return _0x491693['consumable']['consume'](_0x3274b7['item'],'addMarker:'+_0x3274b7['markerName']),_0x491693['consumable']['consume'](_0x3274b7['item'],'removeMarker:'+_0x3274b7['markerName']),null;const _0x1a4d4=['ck-comment-marker'];return _0xfd006a&&_0x1a4d4['push']('ck-comment-marker--active'),_0x498117=_0x43124d?.['length']?_0x43124d['comments']['first']['author']['id']:_0x21ecc6['me']['id'],{'classes':_0x1a4d4,'attributes':{'data-comment':_0x4e114a,'data-author-id':_0x498117}};}}),_0x5419c9['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x594b0e,{options:_0xa2225})=>{if(_0xa2225['showCommentHighlights'])return null;const _0x27c6da=_0x5419c9['plugins']['get'](o),_0x5cd5f7=_0x5419c9['model']['markers']['get'](_0x594b0e),{id:_0x49ddec,part:_0x2749e9}=er(_0x594b0e);return _0x5cd5f7&&!_0x5cd5f7['affectsData']||_0xa2225['ignoreResolvedComments']&&_0x27c6da['getCommentThread'](_0x49ddec)?.['isResolved']?null:{'group':'comment','name':_0x2749e9?_0x49ddec+':'+_0x2749e9:_0x49ddec};}}),_0x5419c9['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x3f1df8,{writer:_0x9736f6})=>_0x9736f6['createElement']('$marker',{'data-name':'comment:'+_0x3f1df8['getAttribute']('id')})}),_0x5419c9['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x5dd974=this['editor'],_0x2d5dfd=_0x5dd974['plugins']['get'](o),_0x52183a=new Set(),_0x3d08f3=new Set();_0x5dd974['model']['document']['registerPostFixer'](_0x147254=>{let _0x57826e=!0x1;for(const {name:_0x29afe8,data:_0x3c7610}of _0x5dd974['model']['document']['differ']['getChangedMarkers']()){const {group:_0x3d382f,id:_0x4073f6}=er(_0x29afe8);let _0x3ba360=_0x3c7610['newRange'];if('comment'!==_0x3d382f||!_0x3ba360)continue;const _0x334f69='$graveyard'===_0x3ba360['root']['rootName'];_0x334f69||(_0x3ba360=dt(_0x3ba360,_0x5dd974['model']),!_0x3ba360||_0x3ba360['isCollapsed']||!_0x3c7610['newRange']||_0x3ba360['isEqual'](_0x3c7610['newRange']))?_0x5dd974['model']['hasContent'](_0x3ba360)&&!_0x334f69?this['isThreadsLoadingPaused']?_0x52183a['add'](_0x29afe8):this['_handleThreadMarker'](_0x29afe8,_0x4073f6):(_0x3d08f3['add'](_0x29afe8),_0x52183a['delete'](_0x29afe8),_0x147254['removeMarker'](_0x29afe8),_0x57826e=!0x0):(_0x147254['updateMarker'](_0x29afe8,{'range':_0x3ba360}),_0x57826e=!0x0);}return _0x57826e;}),this['on']('change:isThreadsLoadingPaused',(_0x19668d,_0x4000e8,_0x5255d8)=>{if(!_0x5255d8&&_0x52183a['size'])for(const _0x1f06f5 of _0x52183a){const {id:_0x4fcee2}=er(_0x1f06f5);_0x52183a['delete'](_0x1f06f5),_0x5dd974['model']['markers']['get'](_0x1f06f5)&&this['_handleThreadMarker'](_0x1f06f5,_0x4fcee2);}}),this['listenTo'](_0x5dd974['model']['document'],'change',()=>{for(const {name:_0x3913e2,data:{newRange:_0x3b5d1b}}of _0x5dd974['model']['document']['differ']['getChangedMarkers']()){const {group:_0xa77cee,id:_0x3126eb}=er(_0x3913e2);if('comment'!==_0xa77cee)continue;const _0x35cf18=_0x2d5dfd['getCommentThread'](_0x3126eb),_0x29b421=this['hasMarkerForId'](_0x3126eb);_0x35cf18&&(!_0x35cf18['_hasTargetInContent']&&_0x3b5d1b&&_0x5dd974['editing']['view']['once']('render',()=>{const _0x405eee=_0x5dd974['plugins']['get'](O),_0x2e9c5f=_0x2d5dfd['_threadToController']['get'](_0x35cf18)['view'];_0x405eee['getByInnerView'](_0x2e9c5f)['refreshVisibility']();},{'priority':'low'}),_0x35cf18['_hasTargetInContent']=_0x29b421||!!_0x3b5d1b),_0x3b5d1b||(_0x3d08f3['add'](_0x3913e2),_0x52183a['delete'](_0x3913e2));}for(const _0x1074bd of _0x3d08f3){const {id:_0x20e500}=er(_0x1074bd),_0x2439b4=_0x2d5dfd['getCommentThread'](_0x20e500);if(_0x52183a['delete'](_0x1074bd),!_0x2439b4)continue;const _0x311a18=this['hasMarkerForId'](_0x20e500);_0x311a18||_0x2439b4['isSubmitted']?_0x311a18||_0x2439b4['unlinkedAt']||_0x2439b4['setUnlinkedAt'](new Date()):_0x2439b4['remove']();}_0x3d08f3['clear']();});}['_handleInitialThreads'](_0x18c644){_0x18c644['forEach'](_0x35ebce=>{_0x35ebce['unlinkedAt']&&this['_attachArchivedThread'](_0x35ebce['id']);});}['_getTargetForId'](_0x26207c){const _0x464ae1=this['editor'],_0x316e0c=this['getAllMarkersForId'](_0x26207c);return et(_0x464ae1['editing'],_0x316e0c);}['_getTextContext'](_0x4572db){const _0x24e014=this['getAllMarkersForId'](_0x4572db);let _0x43adcc='',_0x8efa63=!0x1;for(const _0x58b0f5 of _0x24e014){const _0x412e2f=_0x58b0f5['getRange']();for(const _0x59fd0a of Array['from'](_0x412e2f['getItems']()))_0x59fd0a['is']('$textProxy')?(_0x43adcc&&_0x8efa63&&(_0x43adcc+='\x20',_0x8efa63=!0x1),_0x43adcc+=_0x59fd0a['data']):_0x8efa63=!0x0;_0x8efa63=!0x0;}return _0x43adcc['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x201d4e,_0x38873f){const _0x4306d1=this['editor'],_0x2ef5d5=_0x4306d1['plugins']['get'](o);let _0x930562=_0x2ef5d5['getCommentThread'](_0x38873f);const _0x2d094e=_0x4306d1['config']['get']('collaboration.channelId'),_0x444461=_0x4306d1['plugins']['get'](P);if(_0x930562&&(_0x930562['unlinkedAt']&&_0x930562['setUnlinkedAt'](null),_0x930562['isAttached']))return _0x930562;return!this['getAllMarkersForId'](_0x38873f)[0x0]['managedUsingOperations']?_0x4306d1['editing']['view']['once']('render',()=>{if(_0x2ef5d5['getCommentThread'](_0x38873f))return;const _0x527971=_0x4306d1['plugins']['get'](O);_0x930562=_0x2ef5d5['openNewCommentThread']({'channelId':_0x2d094e,'threadId':_0x38873f,'target':()=>this['_getTargetForId'](_0x38873f),'context':{'type':'text','value':this['_getTextContext'](_0x38873f)}});const _0x5d5cdc=_0x2ef5d5['_threadToController']['get'](_0x930562)['view'],_0x28d8e6=_0x527971['getByInnerView'](_0x5d5cdc);_0x28d8e6&&_0x444461['registerAnnotation'](_0x28d8e6);},{'priority':'low'}):_0x2ef5d5['fetchCommentThread']({'channelId':_0x2d094e,'threadId':_0x38873f})['then'](_0x570a0a=>{if('destroyed'!==_0x4306d1['state']){if(_0x930562=_0x570a0a,_0x930562&&!_0x930562['isAttached']){const _0x3c6b3d=_0x930562['attachTo'](()=>this['_getTargetForId'](_0x38873f));_0x444461['registerAnnotation'](_0x3c6b3d),_0x930562['isResolved']&&this['_reconvertMarkers'](_0x38873f);}else{if(!_0x930562){const _0x2bde08=this['getAllMarkersForId'](_0x38873f);_0x4306d1['model']['change'](_0x24f528=>{for(const _0x20b381 of _0x2bde08)_0x24f528['removeMarker'](_0x20b381);});}}}}),_0x930562;}['_handleThreadMarker'](_0x5762fa,_0x938eed){const _0x467c5a=this['_attachMarkerToThread'](_0x5762fa,_0x938eed);_0x467c5a&&!_0x467c5a['context']&&_0x467c5a['setContext']({'type':'text','value':this['_getTextContext'](_0x938eed)});}['_initAriaMarkerChangeAnnouncements'](){const _0x45501f=this['editor'];ot(_0x45501f['model'],({left:_0x375386,entered:_0x3cd66c})=>{for(const _0x55c3f2 of _0x375386)if(mt(_0x55c3f2)){_0x45501f['ui']['ariaLiveAnnouncer']['announce'](E(_0x45501f['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0xc2c781 of _0x3cd66c)if(mt(_0xc2c781)){_0x45501f['ui']['ariaLiveAnnouncer']['announce'](E(_0x45501f['locale'],'ENTER_COMMENT_ANNOUNCEMENT',nt(_0x3eb3e1)));break;}});}}function ft(_0x4f6611,_0x3bd949){return _0x3bd949?_0x4f6611+':'+_0x3bd949:_0x4f6611;}function er(_0x3b5ba9){const _0x24257b=_0x3b5ba9['split'](':');return{'group':_0x24257b[0x0],'id':_0x24257b[0x1],'part':_0x24257b[0x2]};}function dt(_0x51e8f7,_0x5e575b){const _0xe88b8e=_0x5e575b['schema'],_0x7c69da=_0x5e575b['createRange'](_0x51e8f7['start']);for(const _0x3c419e of _0x51e8f7['getWalker']()){const {type:_0xf3f4fb,item:_0x2fac3a,nextPosition:_0x40a194}=_0x3c419e;if('text'===_0xf3f4fb||_0xe88b8e['isObject'](_0x2fac3a)){const _0x235f1d=_0x5e575b['createPositionBefore'](_0x2fac3a);_0x7c69da['isCollapsed']&&(_0x7c69da['start']=_0x235f1d),_0x7c69da['end']=_0x40a194;}}return _0x7c69da;}function mt(_0x4d3c94){return'comment'===er(_0x4d3c94['name'])['group'];}class i extends _0x599ac2{['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 _0x2531a9=this['editor'],_0xd59aec=_0x2531a9['plugins']['get'](o),_0x19660e=_0x2531a9['plugins']['get'](r),_0x3e6949=_0x2531a9['plugins']['get'](O),_0x24a107=_0x2531a9['plugins']['get'](P);_0x2531a9['ui']['componentFactory']['add']('comment',()=>{const _0x241d9f=this['_createUIButton'](_0x181f25);return _0x241d9f['tooltip']=!0x0,_0x241d9f;}),_0x2531a9['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x66c319)),_0x24a107['addSourceCollector'](()=>{const _0x2ada63=[];for(const [_0x232dfc,_0x48d249]of _0xd59aec['_threadToController']){const _0x45db32=_0x19660e['getAllMarkersForId'](_0x232dfc['id']),_0x96e8a7=_0x45db32['map'](_0x424eeb=>_0x424eeb['getRange']());_0x45db32['length']>0x0&&_0x2ada63['push']([_0x48d249['view'],_0x96e8a7]);}return _0x2ada63;}),this['listenTo'](_0x3e6949,'change:activeAnnotations',(_0x34d2a8,_0x586edb,_0x5337d9)=>{const _0x10ded5=Array['from'](_0x5337d9)['map'](_0x5a9fab=>_0x5a9fab['innerView'])['find'](_0x4d25b6=>_0xd59aec['_viewToController']['has'](_0x4d25b6));if(!_0x10ded5)return void(_0x19660e['activeMarker']=null);const _0x246bcc=_0xd59aec['_viewToController']['get'](_0x10ded5)['model']['id'],_0x1be84b='comment:'+_0x246bcc;_0x246bcc&&_0x19660e['hasMarkerForId'](_0x246bcc)?_0x19660e['activeMarker']=_0x1be84b:_0x19660e['activeMarker']&&(_0x19660e['activeMarker']=null);}),this['listenTo'](_0xd59aec,'removeCommentThread',(_0x2b8a15,{threadId:_0x22ba5e,isFromAdapter:_0x434fcd})=>{!_0x434fcd&&_0x2531a9['ui']['focusTracker']['isFocused']&&_0x19660e['hasMarkerForId'](_0x22ba5e)&&_0x2531a9['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0xd59aec,'addComment',(_0x3a872e,{threadId:_0x55b38a,isFromAdapter:_0x2e2a56})=>{if(_0x2e2a56||!_0x19660e['hasMarkerForId'](_0x55b38a)||!_0xd59aec['hasCommentThread'](_0x55b38a))return;0x1===_0xd59aec['getCommentThread'](_0x55b38a)['length']&&(_0x2531a9['editing']['view']['focus'](),_0x3a872e['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x516614=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x322db0;for(const _0x11677e in _0x516614){const _0x2e3504=_0x11677e,_0x49cced=_0x516614[_0x2e3504];if('commentsLicenseKeyValid'==_0x49cced||'commentsLicenseKeyInvalid'==_0x49cced||'commentsLicenseKeyExpired'==_0x49cced||'commentsLicenseKeyDomainLimit'==_0x49cced||'commentsLicenseKeyNotAllowed'==_0x49cced||'commentsLicenseKeyEvaluationLimit'==_0x49cced||'commentsLicenseKeyTrialLimit'==_0x49cced||'commentsLicenseKeyUsageLimit'==_0x49cced){delete _0x516614[_0x2e3504],_0x322db0=_0x49cced,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x322db0&&_0x516614['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x322db0&&_0x516614['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x322db0&&_0x516614['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x322db0&&_0x516614['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x322db0&&_0x516614['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x322db0&&_0x516614['_showLicenseError']('trialLimit'),'commentsLicenseKeyUsageLimit'==_0x322db0&&_0x516614['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x39d667){const _0x3a8b56=this['editor'],_0x85e030=new _0x39d667(_0x3a8b56['locale']),_0x342ebd=_0x3a8b56['commands']['get']('addCommentThread');return _0x85e030['set']({'label':E(_0x3a8b56['locale'],'Comment'),'icon':_0x352b6e}),_0x85e030['bind']('isEnabled')['to'](_0x342ebd),this['listenTo'](_0x85e030,'execute',()=>{_0x342ebd['execute']();}),_0x85e030;}}class s extends _0x599ac2{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x29655b){super(_0x29655b),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x5edfc4,_0x1d5efa,_0x2f5c8b)=>{_0x2f5c8b?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x1c102e,_0xc56935]of this['editor']['commands'])_0xc56935['affectsData']&&'addCommentThread'!==_0x1c102e&&_0xc56935['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 _0x2bb87e=this['editor']['editing']['view']['document'];this['listenTo'](_0x2bb87e,'cut',_0x42f9a7=>_0x42f9a7['stop'](),{'priority':'highest'}),this['listenTo'](_0x2bb87e,'clipboardInput',_0x23c2c9=>_0x23c2c9['stop'](),{'priority':'highest'}),this['listenTo'](_0x2bb87e,'delete',_0x4ada39=>_0x4ada39['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x55d1cc,_0x51fd51]of this['editor']['commands'])_0x51fd51['affectsData']&&'addCommentThread'!==_0x55d1cc&&_0x51fd51['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 _0x3ec28c{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[O];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1b079d){super(_0x1b079d),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x4a1f6b=this['context']['plugins']['get'](O);this['listenTo'](_0x4a1f6b,'_activateAnnotation',(_0x5c88aa,_0x10c3eb)=>{for(const _0x44d8c2 of this['activeUIs']){const _0x44b1aa=this['_uis']['get'](_0x44d8c2);(0x0,this['uisData']['get'](_0x44d8c2)['filter'])(_0x10c3eb)&&_0x44b1aa['setActiveAnnotation'](_0x10c3eb);}}),this['listenTo'](_0x4a1f6b,'_deactivateAllAnnotations',()=>{for(const _0x473eae of this['activeUIs']){this['_uis']['get'](_0x473eae)['setActiveAnnotation'](null);}}),this['listenTo'](_0x4a1f6b['_visibleAnnotations'],'add',(_0x4d6324,_0x176c33)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x176c33);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x51720b){return this['activeUIs']['has'](_0x51720b);}['activate'](_0x406691,_0xdb0921=this['defaultFilter']){const _0x5761ab=this['context']['plugins']['get'](O);if(!this['_uis']['has'](_0x406691))throw new _0x167eaf('annotationsuis-missing-ui',this,{'uiName':_0x406691});this['isActive'](_0x406691)&&this['deactivate'](_0x406691),this['activeUIs']['add'](_0x406691);const _0x5a353e=new _();!function({source:_0x473967,target:_0x11d3ad,filter:_0x447fd7}){for(const _0x2d43c5 of _0x473967)_0x447fd7(_0x2d43c5)&&_0x11d3ad['add'](_0x2d43c5);_0x11d3ad['listenTo'](_0x473967,'add',(_0x392405,_0x341352)=>{_0x447fd7(_0x341352)&&_0x11d3ad['add'](_0x341352);}),_0x11d3ad['listenTo'](_0x473967,'remove',(_0x19dedc,_0x2475e5)=>{_0x11d3ad['has'](_0x2475e5)&&_0x11d3ad['remove'](_0x2475e5);});}({'source':_0x5761ab['_visibleAnnotations'],'target':_0x5a353e,'filter':_0xdb0921}),this['uisData']['set'](_0x406691,{'collection':_0x5a353e,'filter':_0xdb0921});const _0x545181=this['_uis']['get'](_0x406691);_0x545181['attach'](_0x5a353e),this['listenTo'](_0x545181,'change:activeAnnotation',(_0x14e7fb,_0xb272ef,_0x2a4e40,_0x48cca0)=>{_0x48cca0&&_0x5761ab['_removeActiveAnnotation'](_0x48cca0),_0x2a4e40&&_0x5761ab['_addActiveAnnotation'](_0x2a4e40);});}['deactivate'](_0x18539c){if(this['activeUIs']['delete'](_0x18539c),!this['_uis']['has'](_0x18539c))throw new _0x167eaf('annotationsuis-missing-ui',this,{'uiName':_0x18539c});const _0x1a2cc9=this['_uis']['get'](_0x18539c);_0x1a2cc9['detach'](),this['stopListening'](_0x1a2cc9),this['uisData']['get'](_0x18539c)['collection']['destroy'](),this['uisData']['delete'](_0x18539c);}['switchTo'](_0x28ae5b){if(!this['_uis']['has'](_0x28ae5b))throw new _0x167eaf('annotationsuis-missing-ui',this,{'uiName':_0x28ae5b});const _0x427937=this['context']['plugins']['get'](O),_0x105657=Array['from'](_0x427937['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x28ae5b);const _0x5018a9=this['_uis']['get'](_0x28ae5b);_0x5018a9['setActiveAnnotation'](_0x105657),_0x5018a9['_setSelectedAnnotations']&&_0x105657&&_0x5018a9['_setSelectedAnnotations']([_0x105657]);}['deactivateAll'](){for(const _0x10bcb8 of this['activeUIs'])this['deactivate'](_0x10bcb8);}['register'](_0x223caf,_0x181c61){if(this['_uis']['has'](_0x223caf))throw new _0x167eaf('annotationsuis-register-already-registered');if('function'!=typeof _0x181c61['attach']||'function'!=typeof _0x181c61['detach']||'function'!=typeof _0x181c61['setActiveAnnotation'])throw new _0x167eaf('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x223caf,_0x181c61);}['refilterAnnotations'](){const _0x17391e=this['context']['plugins']['get'](O)['collection'],_0x15e444=new Map(),_0x39d1d0=Array['from'](this['activeUIs']);for(const _0x5be02e of this['activeUIs']){const _0x544eb0=this['uisData']['get'](_0x5be02e)['collection'];for(const _0x548b7a of _0x544eb0)_0x15e444['set'](_0x548b7a,_0x5be02e);}for(const _0x5999c0 of _0x17391e){const _0x48a7b5=_0x15e444['get'](_0x5999c0);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x5999c0);const _0xc69be8=_0x39d1d0['find'](_0x113770=>this['uisData']['get'](_0x113770)['filter'](_0x5999c0));_0x48a7b5!==_0xc69be8&&(_0x48a7b5&&this['uisData']['get'](_0x48a7b5)['collection']['remove'](_0x5999c0),_0xc69be8&&this['uisData']['get'](_0xc69be8)['collection']['add'](_0x5999c0));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x18263c){const _0x18bb92=[];for(const _0x528dd4 of this['activeUIs']){(0x0,this['uisData']['get'](_0x528dd4)['filter'])(_0x18263c)&&_0x18bb92['push'](_0x528dd4);}if(_0x18bb92['length']>0x1)throw new _0x167eaf('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x18bb92,'annotationType':_0x18263c['type']});}}const pi=xt('px');class F extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x5e1fca){super(_0x5e1fca);const _0x5892ba=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 _0xb3b6d4(),this['focusCycler']=new _0x2db88c({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x5892ba['to']('class')],'style':{'minHeight':_0x5892ba['to']('minHeight',_0x1fd586=>'number'==typeof _0x1fd586?pi(_0x1fd586+0xa):null)},'dir':_0x5e1fca['uiLanguageDirection'],'role':'application','aria-label':E(_0x5e1fca,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':E(_0x5e1fca,'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',_0x4ec178=>{this['_updateItemPositionInFocusables'](_0x4ec178['source']);}),this['list']['forEach'](_0x4c66e5=>{this['focusTracker']['add'](_0x4c66e5['element']),this['_updateItemPositionInFocusables'](_0x4c66e5);}),this['list']['on']('change',(_0x3b5056,_0x19d2d2)=>{for(const _0x16f091 of _0x19d2d2['removed'])this['focusTracker']['remove'](_0x16f091['element']),this['focusables']['remove'](_0x16f091);for(const _0x24acf8 of _0x19d2d2['added'])this['focusTracker']['add'](_0x24acf8['element']),this['_updateItemPositionInFocusables'](_0x24acf8);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x2873fd){const _0x4a6581=this['focusables']['getIndex'](_0x2873fd);let _0x58d0fa,_0x73ae84;for(const _0x5d677d of this['focusables'])if(_0x2873fd['top']<_0x5d677d['top']){_0x58d0fa=_0x5d677d;break;}if(_0x73ae84=_0x58d0fa?this['focusables']['getIndex'](_0x58d0fa):this['focusables']['length'],-0x1!==_0x4a6581){if(_0x4a6581===_0x73ae84-0x1)return;this['focusables']['remove'](_0x2873fd),_0x73ae84=_0x58d0fa?this['focusables']['getIndex'](_0x58d0fa):this['focusables']['length'];}this['focusables']['add'](_0x2873fd,_0x73ae84);}}const Ht=xt('px');class H extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x194561){super(_0x194561),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x13608b,_0x245c79)=>_0x13608b+_0x245c79),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Lt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x6e1e75=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x6e1e75['to']('isAnimationDisabled',_0x1cde77=>_0x1cde77?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x6e1e75['to']('top',_0x10ebb6=>Ht(_0x10ebb6))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x2c19e0=this['element']['clientHeight'];_0x2c19e0&&(this['height']=_0x2c19e0);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x3ec28c{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x330a68){super(_0x330a68),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 _0x5aca91=this['context']['config']['get']('sidebar.container');_0x5aca91&&this['setContainer'](_0x5aca91);}['setContainer'](_0x44ae7f){if(!y(_0x44ae7f))throw new _0x167eaf('sidebar-setcontainer-invalid-element');this['container']=_0x44ae7f;}['_attachToContainer']({viewClass:_0x4b4093='',spaceBetweenItems:_0x20256e=0x19}={}){if(!y(this['container']))throw new _0x167eaf('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x4b4093,this['_spaceBetweenItems']=_0x20256e;}['rearrange']({removedAnnotation:_0x123061,previousAnnotation:_0x221914,nextAnnotation:_0x3e92b}){const _0x31ca61=this['getSidebarItemView'](_0x123061);this['view']['list']['remove'](_0x31ca61),this['_destroySidebarItemView'](_0x123061),_0x221914&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x221914)),_0x3e92b&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x3e92b)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x1bb52c,activatedAnnotation:_0x46a96b,disableAnimationOnActivatedAnnotation:_0x266bb0}){if(this['_activeAnnotation']=_0x46a96b,_0x1bb52c){_0x1bb52c['isActive']=!0x1;const _0x52d4a6=this['getSidebarItemView'](_0x1bb52c);_0x52d4a6&&_0x266bb0&&(_0x52d4a6['isAnimationDisabled']=!0x1);}if(_0x46a96b){const _0x2871c2=this['getSidebarItemView'](_0x46a96b);_0x2871c2&&(_0x46a96b['isActive']=!0x0,_0x266bb0&&(_0x2871c2['isAnimationDisabled']=!0x0,_0x2871c2['top']+=0x1),this['_alignToTargetRect'](_0x2871c2));}}['_detachFromContainer'](_0xe2fdff){if(this['view']['element']['remove'](),_0xe2fdff){for(const _0x37fa13 of _0xe2fdff)this['_destroySidebarItemView'](_0x37fa13);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x3aa6b6,_0x5997c4){_0x5997c4||(_0x5997c4=_0x3aa6b6['view']);const _0x23ffcb=new H(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x23ffcb,_0x3aa6b6),this['_annotationToSidebarItemView']['set'](_0x3aa6b6,_0x23ffcb),_0x23ffcb['content']['add'](_0x5997c4),this['listenTo'](_0x3aa6b6['view'],'change:targetRect',(_0x1670d1,_0x2c3755,_0x13f662)=>{const _0x19264f=this['_getTargetTop'](_0x3aa6b6,_0x13f662);_0x23ffcb['_targetTop']!=_0x19264f&&(_0x23ffcb['_targetTop']=_0x19264f,this['_setItemTop'](_0x23ffcb,_0x19264f));}),this['listenTo'](_0x23ffcb,'change:top',()=>{this['_recalculate'](_0x23ffcb,'top');}),this['listenTo'](_0x23ffcb,'change:bottom',()=>{this['_recalculate'](_0x23ffcb,'bottom');}),this['_alignToTargetRect'](_0x23ffcb);const _0x249ba5=this['_getItemBefore'](_0x23ffcb);if(_0x249ba5)this['_alignAfterItem'](_0x249ba5,_0x23ffcb)||this['_alignToTargetRect'](_0x23ffcb);else this['_alignToTargetRect'](_0x23ffcb);return this['_updateLastItem'](),this['view']['list']['add'](_0x23ffcb),_0x23ffcb;}['_alignForTopChange'](_0x5d0a2d){if(!_0x5d0a2d['content']['length'])return;const _0x60ae8f=this['_getItemBefore'](_0x5d0a2d);if(!_0x60ae8f)return;const _0x3f859d=this['_sidebarItemViewToAnnotation']['get'](_0x60ae8f),_0x45a5d7=this['_activeAnnotation'];_0x45a5d7&&_0x45a5d7===_0x3f859d?this['_alignAfterItem'](_0x60ae8f,_0x5d0a2d):this['_alignBeforeItem'](_0x5d0a2d,_0x60ae8f);}['_alignForBottomChange'](_0x2e1c0a){if(!_0x2e1c0a['content']['length'])return;const _0x11dce4=this['_getItemAfter'](_0x2e1c0a);if(!_0x11dce4)return;const _0x53a973=this['_sidebarItemViewToAnnotation']['get'](_0x11dce4),_0x487226=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x2c4428=this['_activeAnnotation'];_0x2c4428&&_0x2c4428===_0x53a973&&_0x487226?(this['_alignBeforeItem'](_0x11dce4,_0x2e1c0a),this['_alignAfterItem'](_0x2e1c0a,_0x11dce4)):_0x2c4428&&_0x2c4428===_0x53a973?this['_alignBeforeItem'](_0x11dce4,_0x2e1c0a):this['_alignAfterItem'](_0x2e1c0a,_0x11dce4);}['_recalculate'](_0x2d3675,_0x46c81a){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x24b344,changedProp:_0x94b874}of this['_recalculateBuffer'])'top'===_0x94b874?this['_alignForTopChange'](_0x24b344):this['_alignForBottomChange'](_0x24b344);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x2d3675,'changedProp':_0x46c81a});}['getSidebarItemView'](_0xfa906e){return this['_annotationToSidebarItemView']['get'](_0xfa906e);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x242f2d){const _0x1a5a64=this['getSidebarItemView'](_0x242f2d);this['stopListening'](_0x1a5a64),this['stopListening'](_0x242f2d['view']),_0x1a5a64['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x242f2d),this['_sidebarItemViewToAnnotation']['delete'](_0x1a5a64);}['_createSidebarView'](){const _0x51f151=new F(this['context']['locale']);return _0x51f151['render'](),this['on']('change:_lastItem',(_0x2976ef,_0xe57a4c,_0x3820bc,_0x223c92)=>{_0x223c92&&_0x51f151['unbind']('minHeight'),_0x3820bc?_0x51f151['bind']('minHeight')['to'](_0x3820bc,'bottom'):_0x51f151['minHeight']=null;}),_0x51f151;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x4b7beb){const _0x37a5f9=this['_sidebarItemViewToAnnotation']['get'](_0x4b7beb),_0x2c1ee6=_0x37a5f9&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x37a5f9)-0x1);return _0x2c1ee6&&this['getSidebarItemView'](_0x2c1ee6)||null;}['_getItemAfter'](_0x3299b5){const _0x537a29=this['_sidebarItemViewToAnnotation']['get'](_0x3299b5),_0x13904e=_0x537a29&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x537a29)+0x1);return _0x13904e&&this['getSidebarItemView'](_0x13904e)||null;}['_alignBeforeItem'](_0x486e6e,_0x54366a){_0x486e6e['updateHeight']();const _0x65cdf4=R(_0x54366a['bottom']+this['_spaceBetweenItems'],_0x486e6e['top']);return!!_0x65cdf4&&(this['_setItemTop'](_0x54366a,_0x54366a['top']-_0x65cdf4),!0x0);}['_alignAfterItem'](_0x122a28,_0x1ed775){_0x122a28['updateHeight']();const _0x3ddb26=R(_0x122a28['bottom']+this['_spaceBetweenItems'],_0x1ed775['top']);return!!_0x3ddb26&&(this['_setItemTop'](_0x1ed775,_0x1ed775['top']+_0x3ddb26,!0x1),!0x0);}['_alignToTargetRect'](_0x35e8f9){const _0x2644e6=this['_sidebarItemViewToAnnotation']['get'](_0x35e8f9);if(!_0x2644e6||!_0x2644e6['target']||!_0x2644e6['targetRect'])return;const _0x4a39e3=this['_getTargetTop'](_0x2644e6,_0x2644e6['targetRect']);this['_setItemTop'](_0x35e8f9,_0x4a39e3);}['_getTargetTop'](_0x45d8b4,_0x40e110){if(null===_0x40e110)return 0x0;if(_0x45d8b4['target']instanceof _0x66e728)return _0x40e110['top'];{const _0x355b45=new _0x66e728(this['view']['element'])['top'];return _0x40e110['top']-_0x355b45;}}['_setItemTop'](_0x507d53,_0x3f6ce9,_0x337691=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x337691&&(_0x3f6ce9=Math['max'](_0x3f6ce9,this['_getMaxAvailableTop'](_0x507d53))),_0x507d53['top']=_0x3f6ce9;}['_getMaxAvailableTop'](_0x4c9d96){let _0x6949c7=this['_getItemBefore'](_0x4c9d96),_0x52e607=0x0;for(;_0x6949c7;)_0x6949c7['updateHeight'](),_0x52e607+=this['_spaceBetweenItems']+_0x6949c7['height'],_0x6949c7=this['_getItemBefore'](_0x6949c7);return _0x52e607;}}function R(_0x4a8a63,_0x1c932b){return Math['max'](_0x4a8a63-_0x1c932b,0x0);}function y(_0x95c5b3){return null!==_0x95c5b3&&'object'==typeof _0x95c5b3&&0x1===_0x95c5b3['nodeType'];}class e extends _0x3ec28c{['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(_0x4d70aa){super(_0x4d70aa),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0xfcf14(),this['_refreshPositioningDebounced']=_0x41a349(()=>{this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x3161a4=this['context']['plugins']['get'](M),_0x4b836e=this['context']['plugins']['get'](z);_0x3161a4['register']('wideSidebar',this),_0x4b836e['container']&&_0x3161a4['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x1a4756){if(_0x1a4756===this['activeAnnotation'])return;const _0x57ec5d=this['context']['plugins']['get'](z);_0x57ec5d['_activeAnnotation']=_0x1a4756;const _0x347e9d=this['activeAnnotation'];_0x57ec5d['refresh']({'blurredAnnotation':_0x347e9d,'activatedAnnotation':_0x1a4756}),this['activeAnnotation']=_0x1a4756;}['attach'](_0x3b3b6b){this['annotations']=_0x3b3b6b;const _0x234057=this['context']['plugins']['get'](z);if(_0x234057['_annotations']=_0x3b3b6b,this['isAttached'])throw new _0x167eaf('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x234057,'set:container',()=>{this['detach'](),this['listenTo'](_0x234057,'change:container',_0x32092b=>{_0x32092b['off'](),this['attach'](_0x3b3b6b);});}),_0x234057['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x3aea3f=_0x3904d0=>{_0x3904d0['updateTargetRect'](),_0x234057['addAnnotation'](_0x3904d0);};for(const _0xbb1306 of _0x3b3b6b)_0x3aea3f(_0xbb1306);this['listenTo'](_0x3b3b6b,'add',(_0x25a88e,_0x9dcc1)=>{_0x3aea3f(_0x9dcc1);}),this['listenTo'](_0x3b3b6b,'remove',(_0x97a8a2,_0x3fafc5,_0x12fa44)=>{_0x234057['rearrange']({'removedAnnotation':_0x3fafc5,'previousAnnotation':_0x3b3b6b['get'](_0x12fa44-0x1),'nextAnnotation':_0x3b3b6b['get'](_0x12fa44+0x1)}),_0x3fafc5===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x3b3b6b,'focus',(_0x42c3b9,_0x5c1c1f)=>{this['setActiveAnnotation'](_0x5c1c1f);}),this['listenTo'](_0x3b3b6b,'blur',()=>{this['setActiveAnnotation'](null);});const _0x5cee67=this['context']instanceof _0x282b9f?this['context']['editors']:new _0xfcf14([this['context']]);for(const _0x16b048 of _0x5cee67)this['_integrateWithEditorAnnotations'](_0x16b048);this['listenTo'](_0x5cee67,'add',(_0x2fc85c,_0xabc803)=>{this['listenTo'](_0xabc803,'ready',()=>{this['_integrateWithEditorAnnotations'](_0xabc803);});}),this['listenTo'](_0x5cee67,'remove',(_0x44c2fe,_0x2aec0c)=>{_0x2aec0c['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x2aec0c['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x167eaf('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x5f7d6a=this['context']['plugins']['get'](z);_0x5f7d6a['_detachFromContainer'](this['annotations']),this['stopListening'](_0x5f7d6a),this['stopListening'](this['annotations']),this['context']instanceof _0x282b9f&&this['stopListening'](this['context']['editors']);for(const _0x4d0b47 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x4d0b47);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x2b710b){if(!_0x2b710b['plugins']['has']('EditorAnnotations'))return;const _0x4f07a5=_0x2b710b['plugins']['get']('EditorAnnotations'),_0x31813f=()=>{const _0x4c757c=_0x4f07a5['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x4c757c[0x0]||null);};this['listenTo'](_0x4f07a5,'refresh',_0x31813f),this['listenTo'](_0x4f07a5,'blur',(_0x3746d2,{isAnnotationTracked:_0x39c709})=>{this['activeAnnotation']&&_0x39c709(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x4f07a5,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x921321=>{_0x4f07a5['hasDomSelection']()&&(_0x31813f(),_0x921321['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x4f07a5);}['_destroyEditorAnnotationsIntegration'](_0x3961b1){this['stopListening'](_0x3961b1),this['_editorAnnotations']['remove'](_0x3961b1);}}class C extends _0x181f25{['counterView'];constructor(_0x3951a7){super(_0x3951a7);const _0xffce6c=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x35ee77,_0x997582)=>_0x35ee77?'...':_0x997582['toString']()),this['set']('annotationType',''),this['icon']=_0x352b6e,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0xffce6c['to']('annotationType',_0x55120f=>'ck-annotation-counter__badge--'+_0x55120f),_0xffce6c['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0xffce6c['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x3ec28c{['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(_0x400f33){super(_0x400f33),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=Object['create'](_0x40c581),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0xfcf14(),this['_refreshPositioningDebounced']=_0x41a349(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](M)['register']('narrowSidebar',this),this['bodyCollection']=new _0x24189d(this['context']['locale']),this['balloonPanelView']=new _0x4865ab(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x40e401){this['annotations']=_0x40e401;const _0x1c27d1=this['context']['plugins']['get'](z),_0x1c17ef=this['balloonPanelView'];if(_0x1c27d1['_annotations']=_0x40e401,this['isAttached'])throw new _0x167eaf('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x1c27d1,'set:container',()=>{this['detach'](),this['listenTo'](_0x1c27d1,'change:container',_0x541e0d=>{_0x541e0d['off'](),this['attach'](_0x40e401);});}),_0x1c27d1['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x32e26d=_0x4eba66=>{const _0x51481f=new C(this['context']['locale']);_0x1c27d1['addAnnotation'](_0x4eba66,_0x51481f),this['_annotationToNarrowView']['set'](_0x4eba66,_0x51481f),_0x51481f['bind']('isDirty','annotationType','number')['to'](_0x4eba66['view'],'isDirty','type','length'),_0x51481f['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x1c17ef['content']['first']!==_0x4eba66['view']?(this['_showBalloon'](_0x4eba66),_0x4eba66['view']['element']['focus'](),this['setActiveAnnotation'](_0x4eba66)):this['setActiveAnnotation'](null);});};for(const _0x1a882f of _0x40e401)_0x32e26d(_0x1a882f);this['listenTo'](_0x40e401,'add',(_0x5adc78,_0x872dc0)=>{_0x32e26d(_0x872dc0);}),this['listenTo'](_0x40e401,'remove',(_0x279894,_0x3cae7c,_0x225f89)=>{this['_annotationToNarrowView']['get'](_0x3cae7c)['destroy'](),this['_annotationToNarrowView']['delete'](_0x3cae7c),_0x1c27d1['rearrange']({'removedAnnotation':_0x3cae7c,'previousAnnotation':_0x40e401['get'](_0x225f89-0x1),'nextAnnotation':_0x40e401['get'](_0x225f89+0x1)}),_0x3cae7c===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x40e401,'focus',(_0x218ca4,_0x4180d9)=>{this['setActiveAnnotation'](_0x4180d9);}),this['listenTo'](_0x40e401,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x34c28c,_0xb8cd21)=>{_0xb8cd21['keyCode']===_0x31f6cb['esc']&&_0x1c17ef['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x1c17ef['content']['first']),this['_hideBalloon'](),_0xb8cd21['stopPropagation'](),_0xb8cd21['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x3ba834,_0x13ff92)=>{const _0x52f861=_0x13ff92['target'];_0x1c17ef['isVisible']&&_0x1c17ef['element']['contains'](_0x52f861)||_0x1c27d1['view']['element']['contains'](_0x52f861)||_0x3ba834['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x37ec24=>_0x37ec24['contains'](_0x52f861))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x49dc44=this['context']instanceof _0x282b9f?this['context']['editors']:new _0xfcf14([this['context']]);for(const _0x524b7e of _0x49dc44)this['_integrateWithEditorAnnotations'](_0x524b7e);this['listenTo'](_0x49dc44,'add',(_0x4aa3ae,_0x2a91c5)=>{this['listenTo'](_0x2a91c5,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x2a91c5);});}),this['listenTo'](_0x49dc44,'remove',(_0x29ae5c,_0x39ffc6)=>{_0x39ffc6['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x39ffc6['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x3cb042){if(_0x3cb042===this['activeAnnotation'])return;const _0x1b4bc3=this['context']['plugins']['get'](z);if(_0x1b4bc3['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x3cb042,'disableAnimationOnActivatedAnnotation':!0x0}),_0x3cb042)_0x1b4bc3['getSidebarItemView'](_0x3cb042)?this['_showBalloon'](_0x3cb042):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x3cb042;}['detach'](){if(!this['isAttached'])throw new _0x167eaf('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x204290=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x1c384c=>_0x1c384c['destroy']()),this['_annotationToNarrowView']['clear'](),_0x204290['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x282b9f&&this['stopListening'](this['context']['editors']);for(const _0x151779 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x151779);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'](_0x5a2350){if(!_0x5a2350['plugins']['has']('EditorAnnotations'))return;const _0x353780=_0x5a2350['plugins']['get']('EditorAnnotations'),_0xde2089=this['context']['plugins']['get'](z),_0x16b6ae=this['annotations'],_0x1831b9=this['balloonPanelView'],_0x420efa=()=>{const _0x2cf180=_0x353780['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x2cf180),this['setActiveAnnotation'](_0x2cf180[0x0]||null);};this['listenTo'](_0x353780,'refresh',_0x420efa),this['listenTo'](_0x353780,'blur',(_0x4d87fb,{isAnnotationTracked:_0x67c434})=>{this['activeAnnotation']&&_0x67c434(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x353780,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x16b6ae,'blur',_0x549f6a=>{_0x353780['hasDomSelection']()&&_0x549f6a['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x315112,_0x2ea84c)=>{const _0x2aa99a=_0x2ea84c['target'];_0x1831b9['isVisible']&&_0x1831b9['element']['contains'](_0x2aa99a)||_0xde2089['view']['element']['contains'](_0x2aa99a)||this['activeAnnotation']&&_0x353780['hasDomSelection']()&&(_0x420efa(),_0x315112['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x353780);}['_destroyEditorAnnotationsIntegration'](_0x3aad14){_0x3aad14&&(this['stopListening'](_0x3aad14),this['_editorAnnotations']['remove'](_0x3aad14));}['_setSelectedAnnotations'](_0x12aeaa){for(const _0x304325 of this['_selectedAnnotations'])_0x12aeaa['includes'](_0x304325)||this['_manuallyClosedAnnotationViews']['delete'](_0x304325['view']);this['_selectedAnnotations']=_0x12aeaa;}['_refreshPositioning'](){const _0x2c6899=this['balloonPanelView'];this['annotations']['refreshPositioning'](),_0x2c6899['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x328f37){if(this['_manuallyClosedAnnotationViews']['has'](_0x328f37['view']))return;const _0x1295d1=this['balloonPanelView']['content']['first'];_0x1295d1!==_0x328f37['view']?(_0x1295d1&&this['_detachListeners'](_0x1295d1),this['_attachListeners'](_0x328f37['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x328f37['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x4d694e=this['balloonPanelView']['content']['first'],_0x48d0b7=_0x4d694e&&this['annotations']['getByView'](_0x4d694e);if(!_0x48d0b7||!this['_annotationToNarrowView']['has'](_0x48d0b7))return;const _0xe93da5=this['_annotationToNarrowView']['get'](_0x48d0b7)['element'],_0x10f5c9=(function(){const _0x5f4e8d=_0x4865ab['defaultPositions'];return[_0x5f4e8d['southArrowNorthEast'],_0x5f4e8d['northArrowSouthEast'],_0x5f4e8d['southArrowNorth'],_0x5f4e8d['northArrowSouth'],_0x5f4e8d['southArrowNorthWest'],_0x5f4e8d['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0xe93da5,'positions':_0x10f5c9});}['_hideBalloon'](){const _0x4dc346=this['balloonPanelView'],_0x1ca78e=_0x4dc346['content']['first'];_0x1ca78e&&(this['_detachListeners'](_0x1ca78e),_0x4dc346['unpin'](),_0x4dc346['content']['clear']());}['_attachListeners'](_0x28edee){this['listenTo'](_0x28edee,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x28edee,'Esc',(_0x300491,_0x59b528)=>{this['_manuallyClosedAnnotationViews']['add'](_0x28edee),this['_hideBalloon'](),_0x59b528();});}['_detachListeners'](_0x31348c){this['stopListening'](_0x31348c);}}class c extends _0x599ac2{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[P,_0x2f55da,M];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xce9ad9){super(_0xce9ad9),_0xce9ad9['editing']['view']['addObserver'](_0xbf6260),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0xce9ad9['plugins']['get'](_0x2f55da),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x188bfc=this['editor']['plugins']['get'](M);_0x188bfc['context']===this['editor']&&(_0x188bfc['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x2c367b,_0x16311d)=>{const _0x4f935b=this['_balloon'];if(this['isAttached']&&_0x4f935b['visibleView']){const _0x3bdf83=this['annotations']['getByView'](_0x4f935b['visibleView']);_0x3bdf83&&this['_closeAnnotation'](_0x3bdf83),_0x16311d();}}));}['afterInit'](){const _0xf9103b=this['editor']['plugins']['get'](M);_0xf9103b['context']===this['editor']&&(_0xf9103b['hasActive']()||_0xf9103b['switchTo']('inline'));}['setActiveAnnotation'](_0x4dc6fb){_0x4dc6fb!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x4dc6fb&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x4dc6fb)&&this['_addAnnotationToBalloon'](_0x4dc6fb,!0x0),_0x4dc6fb['isActive']=!0x0),_0x4dc6fb||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x4dc6fb);}['attach'](_0x29eb2c){this['annotations']=_0x29eb2c;const _0x2c9e08=this['editor']['plugins']['get'](M),_0x333fb5=this['_balloon'];if(this['isAttached'])throw new _0x167eaf('inlineannotations-attach-already-attached',this);if(_0x2c9e08['context']!==this['editor'])throw new _0x167eaf('inlineannotations-not-allowed-with-context',this);const _0x104e30=this['editor']['plugins']['get'](P);this['listenTo'](_0x104e30,'refresh',()=>{const _0x30c95f=_0x104e30['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x58ebee,_0x43dabc;!this['_forceRefresh']&&(_0x58ebee=_0x30c95f,_0x43dabc=this['_selectedAnnotations'],_0x58ebee['length']===_0x43dabc['length']&&_0x58ebee['every'](_0x5aff5d=>_0x43dabc['includes'](_0x5aff5d)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x30c95f),this['setActiveAnnotation'](_0x30c95f[0x0]||null));}),this['listenTo'](_0x104e30,'blur',(_0xead1f2,{isAnnotationTracked:_0x4fbb48})=>{this['activeAnnotation']&&_0x4fbb48(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x546f93,_0x10930d,_0x3b9f51)=>{_0x3b9f51||this['setActiveAnnotation'](null);}),this['listenTo'](_0x29eb2c,'remove',(_0x3eb7a1,_0x194b97)=>{this['_removeAnnotationFromBalloon'](_0x194b97),_0x194b97===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x333fb5,'change:visibleView',(_0x29df6c,_0x440c6a,_0x447029,_0x498f37)=>{_0x498f37&&this['stopListening'](_0x498f37);const _0x181b5a=_0x29eb2c['getByView'](_0x447029);_0x447029&&_0x181b5a&&(this['listenTo'](_0x447029,'change:height',()=>{_0x333fb5['updatePosition']();}),this['listenTo'](_0x447029,'Esc',()=>{this['_closeAnnotation'](_0x181b5a),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x181b5a&&this['setActiveAnnotation'](_0x181b5a));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x333fb5['visibleView']&&(_0x29eb2c['getByView'](_0x333fb5['visibleView'])&&_0x333fb5['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 _0x167eaf('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x308020 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x308020);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x2c5f31){for(const _0x551ea3 of this['_selectedAnnotations'])_0x2c5f31['includes'](_0x551ea3)||this['_manuallyClosed']['delete'](_0x551ea3);for(const _0x2e5921 of this['annotations'])_0x2c5f31['includes'](_0x2e5921)||this['_removeAnnotationFromBalloon'](_0x2e5921);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x4932bb of _0x2c5f31)this['_addAnnotationToBalloon'](_0x4932bb);}this['_selectedAnnotations']=_0x2c5f31;}['_addAnnotationToBalloon'](_0x405f0c,_0xcdb559=!0x1){this['_manuallyClosed']['has'](_0x405f0c)||(this['_addedAnnotations']['has'](_0x405f0c)||this['_balloon']['hasView'](_0x405f0c['view'])||(this['_addedAnnotations']['add'](_0x405f0c),this['_balloon']['add']({'stackId':_0x405f0c['view']['id'],'view':_0x405f0c['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x405f0c)}})),_0xcdb559&&this['_balloon']['showStack'](_0x405f0c['view']['id']));}['_getBalloonTargetForAnnotation'](_0x1ebcad){const _0x21998a=_0x1ebcad['target'],_0x7871f5=this['editor']['editing']['view'],_0x16b9db=_0x7871f5['document']['selection']['getFirstRange'](),_0x96fe9f=_0x7871f5['domConverter']['viewRangeToDom'](_0x16b9db);if(_0x96fe9f['collapse'](!0x0),_0x21998a){if(_0x21998a instanceof _0x66e728)return _0x21998a;let _0x586c83=[];for(const _0x418969 of _0x21998a)_0x586c83['push'](...(_0xe925b2=_0x418969['getClientRects'](),Array['from'](_0xe925b2)['map'](DOMRect['fromRect'])));_0x586c83=function(_0x55b982){const _0x407ae4=[];let _0x115e42=_0x55b982[0x0];for(let _0x67809f=0x1;_0x67809f<_0x55b982['length'];_0x67809f++)B(_0x115e42,_0x55b982[_0x67809f])?_0x115e42['width']+=_0x55b982[_0x67809f]['width']:(_0x407ae4['push'](_0x115e42),_0x115e42=_0x55b982[_0x67809f]);return _0x407ae4['push'](_0x115e42),_0x407ae4;}(_0x586c83);const _0x1b193c=_0x96fe9f['getBoundingClientRect']();return _0x586c83['find'](_0x15270b=>_0x15270b['top']<=_0x1b193c['top']&&_0x15270b['bottom']>=_0x1b193c['bottom']&&_0x15270b['left']<=_0x1b193c['left']&&_0x15270b['right']>=_0x1b193c['right'])||_0x586c83[0x0];}var _0xe925b2;return _0x1ebcad['targetRect']||_0x96fe9f;}['_removeAnnotationFromBalloon'](_0x54060b){this['_addedAnnotations']['has'](_0x54060b)&&this['_balloon']['hasView'](_0x54060b['view'])&&(this['_addedAnnotations']['delete'](_0x54060b),this['_balloon']['remove'](_0x54060b['view']));}['_closeAnnotation'](_0x391097){this['_manuallyClosed']['add'](_0x391097),this['_removeAnnotationFromBalloon'](_0x391097);}}function B(_0x50ff60,_0x3f86c7){return _0x50ff60['top']===_0x3f86c7['top']&&_0x50ff60['bottom']===_0x3f86c7['bottom']&&_0x50ff60['right']===_0x3f86c7['left'];}class tt extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x27b07a,_0x4762c1){super(_0x27b07a),this['set']('isEmpty',!_0x4762c1['length']),this['focusTracker']=new _0xb3b6d4(),this['_annotationViews']=_0x4762c1,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new _0x2db88c({'focusables':_0x4762c1,'focusTracker':this['focusTracker']}),this['listenTo'](_0x4762c1,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x4762c1,'remove',(_0x78eab9,_0x508191)=>{_0x508191['isActive']&&this['focus'](),_0x4762c1['length']||(this['isEmpty']=!0x0);});const _0xca9c45=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':E(_0x27b07a,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x4762c1},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0xca9c45['if']('isEmpty','ck-hidden',_0x1407c9=>!_0x1407c9)]},'children':[{'text':E(_0x27b07a,'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 _0xfa1339 of this['_annotationViews'])this['focusTracker']['add'](_0xfa1339['element']);this['_annotationViews']['on']('change',(_0x42369e,{added:_0x565a15,removed:_0x2d7c3f})=>{for(const _0x321e08 of _0x565a15)this['focusTracker']['add'](_0x321e08['element']);for(const _0x250859 of _0x2d7c3f)this['focusTracker']['remove'](_0x250859['element']);});}}class f extends _0x3ec28c{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,O];}constructor(_0x5c5492){super(_0x5c5492),this['archivedThreads']=new _0xfcf14();}['init'](){const _0x492052=this['context'],_0x1c4be6=_0x492052['plugins']['get'](o),_0x1f68b4=_0x492052['plugins']['get'](O);this['listenTo'](_0x1c4be6,'addCommentThread',(_0x1490c0,{threadId:_0x2f7953})=>{const _0x5f4a1d=_0x1c4be6['getCommentThread'](_0x2f7953);_0x5f4a1d['archivedAt']&&this['archivedThreads']['add'](_0x5f4a1d,this['_calculatePosition'](_0x5f4a1d['archivedAt'])),this['listenTo'](_0x5f4a1d,'change:archivedAt',(_0x3585bd,_0x393579,_0x5751b0)=>{_0x5751b0?this['archivedThreads']['has'](_0x5f4a1d)||this['archivedThreads']['add'](_0x5f4a1d,this['_calculatePosition'](_0x5f4a1d['archivedAt'])):this['archivedThreads']['has'](_0x5f4a1d)&&this['archivedThreads']['remove'](_0x5f4a1d);});}),this['listenTo'](_0x1c4be6,'removeCommentThread',(_0x492686,{threadId:_0x15afad})=>{const _0x166471=_0x1c4be6['getCommentThread'](_0x15afad);this['stopListening'](_0x166471),this['archivedThreads']['has'](_0x166471)&&this['archivedThreads']['remove'](_0x166471);},{'priority':'highest'}),this['listenTo'](_0x1f68b4['collection'],'focus',(_0x3151af,_0xf2f161)=>{_0xf2f161['isVisible']||(_0xf2f161['isActive']=!0x0,_0x1f68b4['activate'](_0xf2f161));});}['_calculatePosition'](_0x370b0c){const _0xa5dd6a=[...this['archivedThreads']]['findIndex'](_0x4ab005=>_0x4ab005['archivedAt']<_0x370b0c);return _0xa5dd6a>-0x1?_0xa5dd6a:this['archivedThreads']['length'];}}class a extends _0x599ac2{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[f,_0x3f2689];}constructor(_0x4f7323){super(_0x4f7323),this['annotationViews']=new _0x58f26f(),this['_pendingThreads']=[];}['init'](){const _0x5e4beb=this['editor'],_0x672815=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x5e4beb['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x181f25,!0x0)),_0x5e4beb['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0xa89214=this['_createCommentsArchiveButton'](_0x66c319);return _0xa89214['set']({'role':'menuitemcheckbox'}),_0xa89214;});const _0x3d573a=_0x5e4beb['plugins']['get'](f),_0x1019e7=_0x5e4beb['plugins']['get']('Annotations'),_0x180609=_0x5e4beb['plugins']['get']('CommentsRepository');_0x3d573a['archivedThreads']['forEach'](_0x68c296=>{this['_handleNewThread'](_0x68c296);}),this['listenTo'](_0x3d573a['archivedThreads'],'add',(_0x384f91,_0x2fca6d)=>{this['_handleNewThread'](_0x2fca6d);}),this['listenTo'](_0x1019e7['collection'],'add',(_0x4cea26,_0xdcf3e0)=>{const _0x296528=this['_pendingThreads']['find'](_0x51f344=>{const _0x3b67d2=_0x180609['_threadToController']['get'](_0x51f344);return _0x3b67d2&&_0xdcf3e0['innerView']===_0x3b67d2['view'];});if(_0x296528){const _0x587865=this['_calculatePosition'](_0x296528['archivedAt']);this['annotationViews']['add'](_0xdcf3e0['view'],_0x587865),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x296528),0x1);}}),this['listenTo'](_0x3d573a['archivedThreads'],'remove',(_0x166933,_0x2b03cb)=>{const _0x9f07d7=_0x5e4beb['config']['get']('collaboration.channelId');if(!_0x9f07d7||_0x2b03cb['channelId']===_0x9f07d7){if(this['_pendingThreads']['includes'](_0x2b03cb))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x2b03cb),0x1);else{const _0x39dc65=_0x180609['_threadToController']['get'](_0x2b03cb),_0x32da5f=_0x1019e7['getByInnerView'](_0x39dc65['view']);this['annotationViews']['remove'](_0x32da5f['view']),this['stopListening'](_0x32da5f['focusableElements']);}}}),this['listenTo'](_0x1019e7['collection'],'add',(_0x440e61,_0x4aea39)=>{this['listenTo'](_0x4aea39,'escape',_0x672815);}),this['listenTo'](_0x1019e7['collection'],'remove',(_0x7690d9,_0x1e6299)=>{this['stopListening'](_0x1e6299,'escape',_0x672815);});}['_handleNewThread'](_0xa2fc5f){const _0x320649=this['editor']['plugins']['get']('CommentsRepository'),_0xc39b33=this['editor']['plugins']['get']('Annotations'),_0x11ec1e=this['editor']['config']['get']('collaboration.channelId');if(!_0x11ec1e||_0xa2fc5f['channelId']===_0x11ec1e){const _0x589193=_0x320649['_threadToController']['get'](_0xa2fc5f);if(!_0x589193)return void this['_pendingThreads']['push'](_0xa2fc5f);const _0x52e644=this['_calculatePosition'](_0xa2fc5f['archivedAt']),_0x505bb0=_0xc39b33['getByInnerView'](_0x589193['view']);_0x505bb0['isVisible']&&_0xc39b33['_visibleAnnotations']['remove'](_0x505bb0),this['annotationViews']['add'](_0x505bb0['view'],_0x52e644);}}['_calculatePosition'](_0x574ec8){const _0x447261=this['editor']['config']['get']('collaboration.channelId'),_0x249122=[...this['editor']['plugins']['get'](f)['archivedThreads']]['filter'](_0x263399=>_0x263399['channelId']===_0x447261)['findIndex'](_0x145988=>_0x145988['archivedAt']<_0x574ec8);return _0x249122<0x0||_0x249122>this['annotationViews']['length']?this['annotationViews']['length']:_0x249122-0x1;}['_toggleDialog'](){const _0x2a6133=this['editor'],_0x363c2f=_0x2a6133['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new tt(_0x2a6133['locale'],this['annotationViews'])),'commentsArchive'===_0x363c2f['id']?_0x363c2f['hide']():_0x363c2f['show']({'id':'commentsArchive','title':E(_0x2a6133['locale'],'COMMENTS_ARCHIVE'),'icon':_0x13e233,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0xd26c9f['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x293955,_0x44cc88=!0x1){const _0x53d2cf=this['editor']['locale'],_0x128c2f=this['editor']['plugins']['get']('Dialog'),_0x3c6d34=new _0x293955(_0x53d2cf);return _0x3c6d34['bind']('isEnabled')['to'](this,'isEnabled'),_0x3c6d34['bind']('isOn')['to'](_0x128c2f,'id',_0xbd890e=>'commentsArchive'===_0xbd890e),_0x3c6d34['set']({'label':E(_0x53d2cf,'COMMENTS_ARCHIVE'),'icon':_0x13e233,'isToggleable':!0x0}),_0x44cc88&&(_0x3c6d34['tooltip']=!0x0),this['listenTo'](_0x3c6d34,'execute',()=>this['_toggleDialog']()),_0x3c6d34;}['_hideDialogOnAnnotationEscape']=_0x3f9d2d=>{const _0x3234aa=_0x3f9d2d['source'];if(!this['annotationViews']['has'](_0x3234aa['view']))return;const _0x320ee2=this['editor']['plugins']['get']('Dialog');_0x320ee2['isOpen']&&'commentsArchive'===_0x320ee2['id']&&(_0x320ee2['hide'](),_0x3f9d2d['stop']());};}class p extends _0x599ac2{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};