@ckeditor/ckeditor5-comments 44.0.0-alpha.3 → 44.0.0-alpha.5
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/build/comments.js +1 -1
- package/dist/index.js +9 -9
- package/package.json +15 -15
- package/src/comments/commentsediting.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{Editor as
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
((()=>Qt)());constructor(_0x171ba9={}){function _0x33b0b7(_0x589b6d){return _0x589b6d['map'](_0x37d88d=>String['fromCharCode'](_0x37d88d))['join']('');}(_0x171ba9=Object['assign']({},_0x171ba9))['plugins']||(_0x171ba9['plugins']=Rt['defaultPlugins']),super(_0x171ba9),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[_0x33b0b7([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x33b0b7([0x76,0x69,0x65,0x77])][_0x33b0b7([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x33b0b7([0x61,0x75,0x74,0x6f]),this[_0x33b0b7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x33b0b7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x33b0b7([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x33b0b7([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x33b0b7([0x6f,0x6b])});}['create'](){const _0x14b874=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x14b874))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x3c9fd2=>{const _0x312377=this['model']['document']['getRoot'](),_0xd9ed2e=_0x312377&&_0x312377['getChild'](_0x312377['childCount']-0x1);_0x3c9fd2['setSelection'](_0xd9ed2e,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x14ec01=this['editing']['view'],_0x472383=_0x14ec01['document']['getRoot'](),_0x8f035d=_0x472383['getChild'](0x0);_0x472383['childCount']>0x1||!_0x8f035d||'p'!=_0x8f035d['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(zt(_0x14ec01,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x8f035d['placeholder']=this['placeholder']),St({'view':_0x14ec01,'element':_0x8f035d,'keepOnFocus':!0x0}),this['placeholderElement']=_0x8f035d);}}class hs extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x4fe4b4,_0x24627f={}){super(_0x4fe4b4),this['editor']=null,this['_editorConfig']=_0x24627f,this['set']('value',_0x24627f['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',S(_0x4fe4b4,'Reply...')),this['set']('submitLabel',S(_0x4fe4b4,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x424f41(),this['focusCycler']=new Ft({'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',(_0x37d56c,_0x4bc0de)=>{this['cancelButtonView']['fire']('execute'),_0x4bc0de();}),this['keystrokes']['set']('Ctrl+Enter',(_0x1760d7,_0x5a0e74)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x5a0e74());}),this['on']('submit',(_0x3fddaf,_0x2e9b22)=>{_0x2e9b22['length']>0xfde8?(alert(S(_0x4fe4b4,'TOO_LONG_COMMENT_ALERT',[_0x2e9b22['length'],0xfde8])),_0x3fddaf['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Rt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0x397829=this['editor'];this['element']['insertBefore'](_0x397829['ui']['element'],this['element']['firstChild']),_0x397829['model']['document']['on']('change',()=>this['value']=_0x397829['getData']()),_0x397829['bind']('placeholder')['to'](this),this['focusables']['add'](_0x397829['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0xa1b8ad){-0x1===_0xa1b8ad?(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:_0x507155}=this,_0x173617=new _0x57b97b(_0x507155);return _0x173617['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x173617['withText']=!0x0,_0x173617['bind']('label')['to'](this,'submitLabel'),_0x173617['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x173617['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x361b72,_0x334589)=>!_0x334589&&!!_0x361b72['trim']()),_0x173617;}['_createCancelButton'](){const {locale:_0x247bd8}=this,_0x418ed8=new _0x57b97b(_0x247bd8);return _0x418ed8['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x418ed8['label']=S(_0x247bd8,'Cancel'),_0x418ed8['withText']=!0x0,_0x418ed8['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x418ed8;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x5e514c=>{this['focusTracker']['add'](_0x5e514c['element']);}),this['focusables']['on']('change',(_0x5d26ca,_0x55dfad)=>{for(const _0x119952 of Array['from'](_0x55dfad['added'])['reverse']())this['focusTracker']['add'](_0x119952['element']);});}}class ie extends kt{constructor(_0x121568,_0xef0d54,_0x1f5461){super(_0x121568),this['commentInputView']=new hs(_0x121568,_0x1f5461),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x21d528,_0x55877a)=>_0x21d528||!!_0x55877a),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 _0x27b058(_0x121568,_0xef0d54),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'](_0x440896){this['commentInputView']['focus'](_0x440896);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x503bcf,_0x4e196b)=>{const {submitButtonView:_0x2aa1c3,cancelButtonView:_0x4f2843,editor:_0x46b373}=this['commentInputView'];[_0x2aa1c3['element'],_0x4f2843['element'],_0x46b373?_0x46b373['editing']['view']['getDomRoot']():null]['filter'](_0x23c88e=>_0x23c88e)['some'](_0x151308=>_0x151308['contains'](_0x4e196b['target']))||(this['focus'](),_0x4e196b['preventDefault']());});}}class cs extends kt{constructor(_0x32a77e){super(_0x32a77e);const _0x1e3c34=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x1e3c34['to']('count',_0x43bd20=>S(_0x32a77e,'NUMBER_OF_COMMENTS',_0x43bd20))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x5077a4,_0x18f2d2,_0x370c02){super(_0x5077a4);const _0x411bc1=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x18f2d2['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x18f2d2,this['_config']=_0x370c02,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x424f41(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x35e451=>this['commentViews']['map'](_0x512f8d=>_0x512f8d['element'])['includes'](_0x35e451['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new cs(_0x5077a4),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x3d40d3=>_0x3d40d3-this['_config']['maxCommentsWhenCollapsed']);for(const _0x58369c of _0x18f2d2['comments'])this['_handleNewCommentModel'](_0x58369c);this['_handleInfoComment'](),this['listenTo'](_0x18f2d2['comments'],'add',(_0x221057,_0x455c44)=>{const _0x5dcbf0=this['_calculatePosition'](_0x455c44);this['length']++,this['_handleNewCommentModel'](_0x455c44,_0x5dcbf0),this['refreshVisibleViews']();}),this['listenTo'](_0x18f2d2['comments'],'remove',(_0x118c4b,_0x598c91)=>{this['length']--,this['_handleRemoveCommentModel'](_0x598c91),this['refreshVisibleViews']();}),this['listenTo'](_0x18f2d2,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x18f2d2,'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',_0x411bc1['if']('length','ck-hidden',_0x4ed09f=>!_0x4ed09f)],'aria-label':S(_0x5077a4,'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'](_0x59956f){-0x1===_0x59956f?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0xd5d6e3 of this['commentViews'])_0xd5d6e3['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x561460,_0x3f7771){const _0x3baa02=new this['_config']['CommentView'](this['locale'],_0x561460,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x3baa02['viewUid']=_0x561460['id'],_0x3baa02['delegate']('removeComment')['to'](this),_0x3baa02['delegate']('updateComment')['to'](this),_0x3baa02['delegate']('resolveCommentThread')['to'](this),_0x3baa02['delegate']('editorReady')['to'](this),_0x3baa02['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x3baa02,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x3baa02,_0x3f7771);}['_calculatePosition'](_0x375c4e){const _0x3da4bb=this['_model']['_findOptimalIndex'](_0x375c4e);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x375c4e['authoredAt']?_0x3da4bb-0x1:_0x3da4bb:_0x3da4bb-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x4d0f80={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':S(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x4d0f80,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x4d0f80));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x2cea96){const _0x461601=this['commentViews']['remove'](_0x2cea96['id']);this['stopListening'](_0x461601),_0x461601['isEditMode']&&this['_updateHasDirtyComment'](),_0x461601['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x561b73=>_0x561b73['isEditMode']);}['_rearrangeCollapse'](){const _0x14da2c=function(_0x1e09e6){const _0x3984e0=new _0x4fd75f();for(const _0x5918b9 of _0x1e09e6)_0x3984e0['add'](_0x5918b9);return _0x3984e0;}(this['commentViews']),_0x47917b=this['_collapsedCommentsView']['count'];for(let _0x421026=0x1;_0x421026<=_0x47917b;_0x421026++)_0x14da2c['remove'](0x1);for(const _0x55f774 of _0x14da2c)_0x55f774['collapse']();_0x47917b>0x0&&_0x14da2c['add'](this['_collapsedCommentsView'],0x1),ns(_0x1f30c1(Array['from'](this['visibleViews']),Array['from'](_0x14da2c)),this['visibleViews'],_0x14da2c);}['_rearrangeExpand'](){ns(_0x1f30c1(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x59a69d of this['visibleViews'])_0x59a69d['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x439f37=>{this['focusTracker']['add'](_0x439f37['element']),this['keystrokes']['listenTo'](_0x439f37['element']);}),this['commentViews']['on']('change',(_0x374b12,_0x3c2a4a)=>{for(const _0x380580 of _0x3c2a4a['removed'])this['focusTracker']['remove'](_0x380580['element']),this['keystrokes']['stopListening'](_0x380580['element']);for(const _0x553b7e of Array['from'](_0x3c2a4a['added'])['reverse']())this['focusTracker']['add'](_0x553b7e['element']),this['keystrokes']['listenTo'](_0x553b7e['element']);});}}function ns(_0x2f15a6,_0x3ce50f,_0x15fee3){let _0x5483ab=0x0;for(const _0x54923b of _0x2f15a6)switch(_0x54923b){case'insert':_0x3ce50f['add'](_0x15fee3['get'](_0x5483ab),_0x5483ab),_0x5483ab++;break;case'delete':_0x3ce50f['remove'](_0x5483ab);break;case'equal':_0x5483ab++;}}class as extends kt{constructor(_0x45cb0b){super(_0x45cb0b);const _0x19f943=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x19f943['to']('contextValue',_0x58ab70=>S(_0x45cb0b,'THREAD_CONTEXT_LABEL',_0x58ab70)),'tabindex':-0x1},'children':[{'text':_0x19f943['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Yt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x301fc5,_0x22a8c7){super(_0x301fc5);const _0x5d4662=this['bindTemplate'];this['_model']=_0x22a8c7,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x424f41(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x2934aa=>!!_0x2934aa),this['bind']('contextValue')['to'](this['_model'],'context',_0x55b696=>_0x55b696&&_0x55b696['value']?this['_trimContextValue'](_0x55b696['value']):S(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',_0x5d4662['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 _0x960e0=new _0x57b97b(this['locale']);return _0x960e0['label']=S(this['locale'],'Reopen'),_0x960e0['tooltip']=S(this['locale'],'Reopen'),_0x960e0['icon']='<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22m5.042\x209.367\x202.189\x201.837a.75.75\x200\x200\x201-.965\x201.149l-3.788-3.18a.747.747\x200\x200\x201-.21-.284.75.75\x200\x200\x201\x20.17-.945L6.23\x204.762a.75.75\x200\x201\x201\x20.964\x201.15L4.863\x207.866h8.917A.75.75\x200\x200\x201\x2014\x207.9a4\x204\x200\x201\x201-1.477\x207.718l.344-1.489a2.5\x202.5\x200\x201\x200\x201.094-4.73l.008-.032H5.042z\x22/></svg>',_0x960e0['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x27ad5c=>!_0x27ad5c),_0x960e0['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x3c4492,_0x3b5a3b)=>_0x3c4492&&_0x3b5a3b),_0x960e0['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x960e0;}['_trimContextValue'](_0x2b7da3){if(_0x2b7da3['length']<0x96)return _0x2b7da3;const _0x44a8e2=_0x2b7da3['lastIndexOf']('\x20',0x93);return _0x2b7da3['substring'](0x0,_0x44a8e2>-0x1?_0x44a8e2:0x93)+'...';}['_attachContextActions'](){const _0x5cf42d=this['element']['querySelector']('.ck-context'),_0x2a3694=_0x5cf42d['querySelector']('.ck-context__value');this['listenTo'](_0x5cf42d,'mouseenter',()=>{_0x2a3694['offsetWidth']<_0x2a3694['scrollWidth']&&_0x5cf42d['classList']['add']('overlay');}),this['listenTo'](_0x5cf42d,'mouseleave',()=>{_0x5cf42d['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x2e4071 of this['focusables'])this['focusTracker']['add'](_0x2e4071['element']),this['keystrokes']['listenTo'](_0x2e4071['element']);}['_createContextView'](){const _0x58b1d9=new as(this['locale']);return _0x58b1d9['bind']('contextValue')['to'](this),_0x58b1d9;}}class ss extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x1a15ed,_0x46d274,_0xf1a24c,_0x4a4962){super(_0x1a15ed),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x46d274,this['_localUser']=_0xf1a24c,this['_config']=_0x4a4962,this['commentThreadHeaderView']=new Yt(_0x1a15ed,_0x46d274),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Zt(_0x1a15ed,S(_0x1a15ed,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x1a15ed,_0x46d274,Object['assign']({'CommentView':this['_config']['CommentView']},_0x4a4962)),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',(_0x4047db,_0x5a562c)=>_0x4047db||!!_0x5a562c),this['bind']('isUnlinked')['to'](_0x46d274,'unlinkedAt',_0x19ff10=>!!_0x19ff10),this['bind']('ariaLabel')['to'](this,'length',_0x861375=>{const _0x44239f=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return S(this['locale'],'COMMENT_THREAD_LABEL',[_0x861375,_0x44239f]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x424f41(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x3cd305=>_0x3cd305['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),ts(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x4e958e=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0xb727bb=_0x4e958e['commentInputView'];return _0x4e958e['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0xb727bb,'value',(_0x251a5b,_0x5a7f1b,_0x1a8082,_0x4fd5bd,_0x1ae194)=>!!_0x1ae194||!!_0x4fd5bd&&_0x1a8082&&!_0x5a7f1b||_0x251a5b&&_0x1a8082&&!_0x5a7f1b),_0xb727bb['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x4a1897,_0x4cf1d0,_0x4f74a3)=>{let _0x4f3fcd;return _0x4f3fcd=_0x4f74a3&&_0x4cf1d0?'Reply\x20to\x20reopen\x20discussion...':_0x4a1897?'Reply...':'Write\x20a\x20comment...',S(this['locale'],_0x4f3fcd);}),_0xb727bb['bind']('submitLabel')['to'](this,'length',_0x5e34ea=>S(this['locale'],_0x5e34ea?'Reply':'Comment')),_0xb727bb['on']('submit',(_0x3b02d0,_0xdce29)=>{this['fire']('addComment',_0xdce29),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0xb727bb['on']('cancel',()=>{this['focus']();}),_0xb727bb['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0xb727bb['on']('cancel',_0x57d64b=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x57d64b['stop']());}),this['on']('change:isActive',(_0x1ada75,_0x660b71,_0x5cbbf4)=>{_0x5cbbf4||this['length']||_0xb727bb['value']||this['fire']('removeCommentThread');}),_0x4e958e;}}class Ct extends/* #__PURE__ -- @preserve */
|
|
27
|
-
ti(ss){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(
|
|
28
|
-
ti(os){['actionBar'];['userView'];constructor(
|
|
29
|
-
_0x13a315(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x361f7c,target:_0x37bda1,type:_0x495bcd,isVisible:_0x21edcb=!0x0}){super(),this['view']=_0x361f7c,this['view']['element']||this['view']['render'](),this['_type']=_0x495bcd,this['_target']=_0x37bda1,d['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x4fd75f([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x4f5c0c,_0x2d8b6b)=>{this['view']['focusTracker']['add'](_0x2d8b6b);}),this['focusableElements']['on']('remove',(_0x58082c,_0x43beb7)=>{this['view']['focusTracker']['remove'](_0x43beb7);}),this['set']('isVisible',_0x21edcb);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x352e25=this['_getNormalizedTarget']();return d['_assertCorrectTarget'](_0x352e25),_0x352e25;}get['targetRect'](){const _0x424fd7=this['target'];if(null===_0x424fd7)return null;if(_0x424fd7 instanceof _0x44fba6)return _0x424fd7;const _0x373765=_0x424fd7['filter'](_0x23d786=>function(_0x1481a0){const _0x566edf=_0x1481a0['offsetParent'];if(_0x566edf)return!0x0;const _0x466120=_0x1481a0['getClientRects']()['item'](0x0);return!!_0x466120;}(_0x23d786));return 0x0===_0x373765['length']?null:new _0x44fba6(_0x373765[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x4c0ccb){this['view']['isActive']=_0x4c0ccb,this['view']['mainView']['isActive']=_0x4c0ccb;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x5210de){if(!(null===_0x5210de||_0x5210de instanceof _0x44fba6||Array['isArray'](_0x5210de)&&_0x5210de['every'](_0x8255fe=>ne(_0x8255fe))))throw new _0x59ce32('annotation-invalid-target',null,{'target':_0x5210de});}['_getNormalizedTarget'](){const _0x46a3a4='function'==typeof this['_target']?this['_target']():this['_target'];return ne(_0x46a3a4)?[_0x46a3a4]:_0x46a3a4;}}function ne(_0xb22586){return null!==_0xb22586&&'object'==typeof _0xb22586&&'nodeType'in _0xb22586&&0x1===_0xb22586['nodeType'];}class x extends _0x4fd75f{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x3cff97=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x424f41(),this['_focusTracker']['on']('change:isFocused',(_0x550f08,_0x541c50,_0x5535a4)=>{_0x5535a4||this['fire']('blur');});for(const _0x4af03d of _0x3cff97)this['add'](_0x4af03d);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x3111cb){if(this['has'](_0x3111cb))throw new _0x59ce32('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x3111cb['innerView'],_0x3111cb),this['_viewToAnnotation']['set'](_0x3111cb['view'],_0x3111cb);for(const _0x50cbd1 of _0x3111cb['focusableElements'])this['_focusTracker']['add'](_0x50cbd1);this['listenTo'](_0x3111cb['focusableElements'],'add',(_0x26a185,_0x9adb65)=>{this['_focusTracker']['add'](_0x9adb65);}),this['listenTo'](_0x3111cb['focusableElements'],'remove',(_0x41c0b7,_0x590466)=>{this['_focusTracker']['remove'](_0x590466);}),this['listenTo'](_0x3111cb['view']['focusTracker'],'change:isFocused',(_0x346f59,_0xb32a78,_0x14c231)=>{_0x14c231&&this['fire']('focus',_0x3111cb);}),_0x3111cb['updateTargetRect']();const _0x562b81=this['_getOrderInContent'](_0x3111cb['view']['targetRect']);return super['add'](_0x3111cb,_0x562b81);}['remove'](_0x2256f2){if(!this['has'](_0x2256f2))throw new _0x59ce32('annotationcollection-not-existing-item',null);this['stopListening'](_0x2256f2['view']['focusTracker']),this['stopListening'](_0x2256f2['focusableElements']);for(const _0x2a3dde of _0x2256f2['focusableElements'])this['_focusTracker']['remove'](_0x2a3dde);return this['_viewToAnnotation']['delete'](_0x2256f2['view']),this['_innerViewToAnnotation']['delete'](_0x2256f2['innerView']),super['remove'](_0x2256f2);}['getByInnerView'](_0x4342a6){return this['_innerViewToAnnotation']['get'](_0x4342a6);}['getByView'](_0xf63f69){return this['_viewToAnnotation']['get'](_0xf63f69);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x3e1361 of this)_0x3e1361['updateTargetRect']();this['_sort']();}['_sort'](){const _0x109482=Array['from'](this)['sort']((_0x9fadb4,_0x52577a)=>v(_0x9fadb4['view']['targetRect'],_0x52577a['view']['targetRect']));for(let _0x3446d2=_0x109482['length']-0x1;_0x3446d2>0x0;_0x3446d2--){const _0x30178c=_0x109482[_0x3446d2];_0x3446d2!==this['getIndex'](_0x30178c)&&(this['remove'](_0x30178c),this['add'](_0x30178c));}}['_getOrderInContent'](_0x2276c9){let _0x1ed96c=0x0;if(!_0x2276c9)return this['length'];for(const _0x44f569 of this){const _0x1aaa5f=_0x44f569['view']['targetRect'];if(_0x1aaa5f){if(v(_0x2276c9,_0x1aaa5f)<0x0)return _0x1ed96c;_0x1ed96c++;}}return _0x1ed96c;}}function v(_0x4cb0ad,_0x3db833){if(null===_0x4cb0ad&&null===_0x3db833)return 0x0;if(null===_0x4cb0ad)return-0x1;if(null===_0x3db833)return 0x1;const _0x323d7e=_0x4cb0ad['top']-_0x3db833['top'];return 0x0==_0x323d7e?_0x4cb0ad['left']-_0x3db833['left']:_0x323d7e;}class N extends _0x529673{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4d0e67){if(super(_0x4d0e67),this['collection']=new x(),this['_visibleAnnotations']=new x(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x4d0e67 instanceof _0x2e1330){const _0x5db016=_0x4d0e67['locale'];_0x4d0e67['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':S(_0x5db016,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x194840){this['collection']['add'](_0x194840);}['remove'](_0xa988ac){this['collection']['remove'](_0xa988ac),_0xa988ac['destroy']();}['refreshVisibility'](){for(const _0x47bf34 of this['collection'])_0x47bf34['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x11a5ea){return this['collection']['getByInnerView'](_0x11a5ea);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x2a14c1 of this['collection'])_0x2a14c1['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x479090){this['fire']('_activateAnnotation',_0x479090);}['createAnnotation'](_0xf92782){return new d(_0xf92782);}['createAnnotationView'](_0x3110de,_0x2034a1){return new T(_0x3110de,_0x2034a1);}['_addActiveAnnotation'](_0x3076f4){const _0x504b43=new Set(this['activeAnnotations']);_0x504b43['add'](_0x3076f4),this['activeAnnotations']=_0x504b43;}['_removeActiveAnnotation'](_0x55b3a7){const _0x7166d1=new Set(this['activeAnnotations']);_0x7166d1['delete'](_0x55b3a7),this['activeAnnotations']=_0x7166d1;}['_bindAnnotationsToVisibleAnnotations'](){const _0x5e231c=this['collection'],_0x5b01f7=this['_visibleAnnotations'];function _0x180c72(_0x24405d){const _0x11df1c=_0x24405d['source'];_0x11df1c['isVisible']&&!_0x5b01f7['has'](_0x11df1c)?_0x5b01f7['add'](_0x11df1c):!_0x11df1c['isVisible']&&_0x5b01f7['has'](_0x11df1c)&&_0x5b01f7['remove'](_0x11df1c),_0x11df1c['view']['focusTracker']['remove'](_0x11df1c['view']['element']),_0x11df1c['view']['focusTracker']['add'](_0x11df1c['view']['element']);}this['listenTo'](_0x5e231c,'add',(_0x4155b3,_0x6b2d78)=>{_0x6b2d78['isVisible']&&_0x5b01f7['add'](_0x6b2d78),this['listenTo'](_0x6b2d78,'change:isVisible',_0x180c72);}),this['listenTo'](_0x5e231c,'remove',(_0x47309b,_0x36563d)=>{_0x5b01f7['has'](_0x36563d)&&_0x5b01f7['remove'](_0x36563d),this['stopListening'](_0x36563d,'change:isVisible',_0x180c72);});}['_setupEnterAnnotationKeystroke'](){const _0x3c71c0=_0x5aa21b=>{_0x5aa21b['on']('ready',()=>{_0x5aa21b['keystrokes']['set'](_0x38fb47,(_0x2c3cda,_0x3a0548)=>{const _0x3c6c99=_0x1f6fa1(this['activeAnnotations']['values']());_0x3c6c99&&(_0x3c6c99['view']['focus'](),_0x3a0548());});});};this['context']instanceof _0x2e1330?_0x3c71c0(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x3a5296,_0x3d2b72)=>{_0x3c71c0(_0x3d2b72);});}['_setupEscapeAnnotationHandling'](){const _0x26fe42=_0x50ecea=>{const _0xdd9d94=_0x50ecea['source'],_0x296746=[];let _0x1fa263;if(Array['isArray'](_0xdd9d94['target'])){_0x1fa263=_0xdd9d94['target'][0x0],this['context']instanceof _0x2e1330?_0x296746['push'](this['context']):this['context']['editors']&&_0x296746['push'](...this['context']['editors']);for(const _0x21af5b of _0x296746)for(const _0x44d68a of _0x21af5b['editing']['view']['domRoots']['values']())if(_0x44d68a['contains'](_0x1fa263))return void _0x21af5b['editing']['view']['focus']();_0x1fa263['focus']();}};this['listenTo'](this['collection'],'add',(_0xc0a311,_0x3c565f)=>{this['listenTo'](_0x3c565f,'escape',_0x26fe42,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x9e5a86,_0x1b556b)=>{this['stopListening'](_0x1b556b,'escape',_0x26fe42);});}}const gt=Symbol('noChannel'),Tt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x529673{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[N,ht,it];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xf2f3dd){super(_0xf2f3dd),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x460c2e=this['context']['config'];_0x460c2e['define']('comments.maxCommentsWhenCollapsed',0x2),_0x460c2e['define']('comments.maxThreadTotalWeight',0x1f4),_0x460c2e['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x460c2e['define']('comments.CommentThreadView',Ct),_0x460c2e['define']('comments.CommentView',vt),_0x460c2e['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x3488d8=this['context']['plugins']['get'](N);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x47f071,_0x5c36f5)=>this['_addCommentThread'](_0x5c36f5)),this['on']('submitCommentThread',(_0x34aed6,_0x49488e)=>this['_submitCommentThread'](_0x49488e)),this['on']('resolveCommentThread',(_0x124032,_0x10ad91)=>this['_resolveCommentThread'](_0x10ad91)),this['on']('resolveCommentThread',(_0x39ede4,_0x5294f8)=>this['_updateActiveAnnotation'](_0x5294f8),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x5445ab,_0x27fcb2)=>this['_reopenCommentThread'](_0x27fcb2)),this['on']('reopenCommentThread',(_0x312252,_0x46a0b3)=>this['_updateActiveAnnotation'](_0x46a0b3),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x19e87b,_0x4471a7)=>this['_removeCommentThread'](_0x4471a7)),this['on']('updateCommentThread',(_0xf62f0,_0x26bf94)=>this['_updateCommentThread'](_0x26bf94)),this['on']('updateCommentThread',(_0x54f23b,_0x23cbde)=>this['_updateActiveAnnotation'](_0x23cbde),{'priority':'lowest'}),this['on']('addComment',(_0xaff96e,_0x2e82de)=>this['_addComment'](_0x2e82de)),this['on']('updateComment',(_0xf5dfc8,_0x36e0b6)=>this['_updateComment'](_0x36e0b6)),this['on']('removeComment',(_0x4d60ff,_0x5d5b78)=>this['_removeComment'](_0x5d5b78)),this['on']('addComment',(_0x400848,{threadId:_0x30a11b,isFromAdapter:_0x277e91})=>{if(_0x277e91)return;const _0xef7224=this['getCommentThread'](_0x30a11b),_0x36665b=_0xef7224&&this['_threadToController']['get'](_0xef7224);_0x36665b&&_0x36665b['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x3488d8,'change:activeAnnotations',(_0x1ce5df,_0x16622d,_0x39c21c)=>{const _0x5e687d=Array['from'](_0x39c21c)['map'](_0x392ac1=>this['_viewToController']['get'](_0x392ac1['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x5e687d?_0x5e687d['model']:null;});}set['adapter'](_0x5271e2){if(this['_adapter'])throw new _0x59ce32('commentsrepository-adapter-already-set');this['_adapter']=_0x5271e2;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x148487=gt,threadId:_0x1b7ab7=_0xa3844f(),comments:_0x3d763a=[],unlinkedAt:_0x4c4e98=null,resolvedAt:_0x2f9ef0=null,resolvedBy:_0x33fc98=null,target:_0x5be366=null,context:_0x2ba9b6=null,attributes:_0x1d1f4d={},isResolvable:_0x3de7ae=!0x0,isSubmitted:_0x1deb78=!0x1,isFromAdapter:_0x2a789e=!0x1}={}){return this['fire'](_t('addCommentThread',_0x148487),{'channelId':_0x148487,'threadId':_0x1b7ab7,'comments':_0x3d763a,'unlinkedAt':_0x4c4e98,'resolvedAt':_0x2f9ef0,'resolvedBy':_0x33fc98,'target':_0x5be366,'context':_0x2ba9b6,'attributes':_0x1d1f4d,'isFromAdapter':_0x2a789e,'isResolvable':_0x3de7ae,'isSubmitted':_0x1deb78}),this['getCommentThread'](_0x1b7ab7);}['openNewCommentThread']({channelId:_0x126ed8=gt,threadId:_0x337e43=_0xa3844f(),target:_0x586b4a,context:_0x4fd46e=null,isResolvable:_0x39e16d=!0x0}){if(this['_readOnlyChannels']['has'](_0x126ed8)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x586b4a)throw new _0x59ce32('commentsrepository-missing-target');const _0x900db3=this['addCommentThread']({'channelId':_0x126ed8,'threadId':_0x337e43,'target':_0x586b4a,'context':_0x4fd46e,'isResolvable':_0x39e16d});if(!_0x900db3)return null;const _0x52552d=this['_threadToController']['get'](_0x900db3),_0x4f12d2=_0x52552d['view']['commentThreadInputView']['commentInputView'],_0x428257=this['context']['plugins']['get'](N),_0x211ef0=_0x428257['getByInnerView'](_0x52552d['view']);return _0x428257['activate'](_0x211ef0),_0x4f12d2['once']('editorReady',()=>_0x4f12d2['focus']()),_0x900db3;}['hasCommentThread'](_0xb44c73){if('string'!=typeof _0xb44c73)throw new _0x59ce32('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0xb44c73);}['updateCommentThread']({channelId:_0x4b3bb8=gt,threadId:_0x3fd373,context:_0x3952f4,unlinkedAt:_0x39dda4,attributes:_0x93f012,isFromAdapter:_0x5d2d3b=!0x1}){return this['fire'](_t('updateCommentThread',_0x4b3bb8),{'channelId':_0x4b3bb8,'threadId':_0x3fd373,'context':_0x3952f4,'unlinkedAt':_0x39dda4,'attributes':_0x93f012,'isFromAdapter':_0x5d2d3b}),this['getCommentThread'](_0x3fd373);}['getCommentThread'](_0x2e0bea){if('string'!=typeof _0x2e0bea)throw new _0x59ce32('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x2e0bea);}['fetchCommentThread']({channelId:_0x5a156f,threadId:_0x13d56b}={}){const _0x5118c5=this['getCommentThread'](_0x13d56b);if(_0x5118c5)return Promise['resolve'](_0x5118c5);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x59ce32('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x5a156f,'threadId':_0x13d56b})['then'](_0x4a9335=>this['hasCommentThread'](_0x13d56b)?this['getCommentThread'](_0x13d56b):_0x4a9335?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x5a156f},_0x4a9335)):void 0x0)['catch'](_0x354605=>{throw console['error'](_0x354605),new _0x59ce32('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x139412,skipNotAttached:_0x15188e=!0x1,skipEmpty:_0x20822f=!0x1,toJSON:_0x51da3c=!0x1}={}){const _0x200082=[];for(const _0x3bc955 of this['_threads']['values']())_0x139412&&_0x3bc955['channelId']!==_0x139412||_0x15188e&&!_0x3bc955['isAttached']||_0x20822f&&0x0===_0x3bc955['length']||_0x200082['push'](_0x3bc955);return _0x51da3c?_0x200082['map'](_0x2431a5=>_0x2431a5['toJSON']()):_0x200082;}['setActiveCommentThread'](_0x280c8f){const _0x226536=this['context']['plugins']['get'](N);if(!_0x280c8f)return void(this['activeCommentThread']&&_0x226536['deactivateAll']());const _0xf76bf6=this['getCommentThread'](_0x280c8f);if(!_0xf76bf6)throw new _0x59ce32('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x280c8f});if(!this['_threadToController']['has'](_0xf76bf6))throw new _0x59ce32('commentsrepository-active-not-attached',null,{'threadId':_0x280c8f});const _0x2ff35c=_0x226536['getByInnerView'](this['_threadToController']['get'](_0xf76bf6)['view']);_0x226536['activate'](_0x2ff35c);}['switchReadOnly'](_0x118ae1,_0x2ba0b9){_0x118ae1?this['_readOnlyChannels']['add'](_0x2ba0b9):this['_readOnlyChannels']['delete'](_0x2ba0b9),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x32ae67){return this['_readOnlyChannels']['has'](_0x32ae67)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x34328d,_0x4b09c9){return new yt(_0x34328d,_0x4b09c9);}['setPermissions'](_0x475772,_0x37193d=gt){this['_permissions']['set'](_0x37193d,_0x475772),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x379c31=gt){return this['_permissions']['has'](_0x379c31)?this['_permissions']['get'](_0x379c31):Tt;}['_addCommentThread']({channelId:_0x526b33,threadId:_0x154d57,comments:_0x14cc4c,unlinkedAt:_0x51229b,resolvedAt:_0x33b753,resolvedBy:_0x22adf6,target:_0x1679e0,context:_0x415032,attributes:_0xcd2cfe,isFromAdapter:_0x31d7ec,isResolvable:_0x3b3fd7,isSubmitted:_0x1b588c}){if('string'!=typeof _0x154d57)throw new _0x59ce32('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x154d57});if(this['hasCommentThread'](_0x154d57))throw new _0x59ce32('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x154d57});const _0x166282=new oe(this,{'channelId':_0x526b33,'id':_0x154d57,'context':_0x415032,'attributes':_0xcd2cfe,'unlinkedAt':_0x51229b,'resolvedAt':_0x33b753,'resolvedBy':_0x22adf6?this['context']['plugins']['get'](it)['getUser'](_0x22adf6):null,'isResolvable':_0x3b3fd7,'isSubmitted':_0x1b588c||_0x31d7ec});this['_threads']['set'](_0x154d57,_0x166282);for(const _0x2ee50a of _0x14cc4c)_0x166282['_add'](this['_createNewComment']({'threadId':_0x154d57,..._0x2ee50a}));return _0x1679e0&&_0x166282['attachTo'](_0x1679e0),_0x31d7ec||!_0x166282['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x526b33,'threadId':_0x154d57});}['_submitCommentThread']({channelId:_0x1afeb8,threadId:_0x1697e8}){if(!this['hasCommentThread'](_0x1697e8))throw new _0x59ce32('commentsrepository-missing-comment-thread',this);const _0x1043ea=this['getCommentThread'](_0x1697e8);if(_0x1043ea['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x12480d,comments:_0x345789,resolvedAt:_0x5844e3,resolvedBy:_0x97c414,context:_0x7c2170,attributes:_0x39adbe}=_0x1043ea,_0x5280b3=this['context']['plugins']['get']('PendingActions'),_0x4d2d63=_0x5280b3['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x1afeb8,'threadId':_0x12480d,'comments':_0x345789['map'](_0xf7c88b=>_0xf7c88b['toJSON']()),'resolvedAt':_0x5844e3,'resolvedBy':_0x97c414?_0x97c414['id']:_0x97c414,'context':_0x7c2170,'attributes':_0x39adbe})['then'](({comments:_0x14c039})=>{_0x5280b3['remove'](_0x4d2d63);for(const _0x54bbbd of _0x14c039)this['_updateComment']({'channelId':_0x1afeb8,'threadId':_0x1697e8,'commentId':_0x54bbbd['commentId'],'createdAt':_0x54bbbd['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x3b9232=>{throw console['error'](_0x3b9232),new _0x59ce32('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x2c7773,target:_0x5a5720}){const _0x57a10a=this['getCommentThread'](_0x2c7773);if(!_0x57a10a)throw new _0x59ce32('commentsrepository-attach-missing-comment-thread',this);const _0xac9410=this['context']['plugins']['get']('PendingActions'),_0x4db9dc=this['context']['plugins']['get'](N),_0x37d1a7=this['_createCommentThreadView'](_0x57a10a),_0xbaf4ab=new yt(_0x57a10a,_0x37d1a7);let _0x114acf=null;_0x37d1a7['on']('change:isDirty',(_0x14a1b7,_0x11344c,_0x2551b7)=>{_0x2551b7?_0x114acf=_0xac9410['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x114acf&&(_0xac9410['remove'](_0x114acf),_0x114acf=null);}),this['_threadToController']['set'](_0x57a10a,_0xbaf4ab),this['_viewToController']['set'](_0x37d1a7,_0xbaf4ab);const _0x20aea6=new T(this['context']['locale'],_0x37d1a7);_0x20aea6['bind']('length')['to'](_0x37d1a7),_0x20aea6['bind']('isDirty')['to'](_0x37d1a7,'isDirty',_0x37d1a7,'length',(_0x3ff682,_0x2671cb)=>_0x3ff682||!_0x2671cb),_0x20aea6['bind']('isActive')['to'](_0x37d1a7),_0x20aea6['type']='comment';const _0xecc39d=new d({'view':_0x20aea6,'target':_0x5a5720,'type':'comment','isVisible':!_0x57a10a['isResolved']});return _0x37d1a7['on']('escape',()=>{_0xecc39d['fire']('escape');}),this['_bindAnnotationToEditors'](_0x37d1a7,_0xecc39d),_0x4db9dc['add'](_0xecc39d),_0xecc39d;}['_bindAnnotationToEditors'](_0x2d50ea,_0x4d5af3){this['listenTo'](_0x2d50ea,'editorReady',(_0x25f92c,_0x48bbfd)=>{const _0x3a95c6=_0x48bbfd['ui']['view']['body']['bodyCollectionContainer'];_0x4d5af3['focusableElements']['add'](_0x3a95c6),this['context']instanceof _0x2e1330&&this['context']['ui']['focusTracker']['add'](_0x3a95c6);},{'priority':'highest'}),this['listenTo'](_0x2d50ea,'editorDestroyed',(_0x2134d7,_0x44273d)=>{const _0x483dcd=_0x44273d['ui']['view']['body']['bodyCollectionContainer'];_0x4d5af3['focusableElements']['has'](_0x483dcd)&&_0x4d5af3['focusableElements']['remove'](_0x483dcd),this['context']instanceof _0x2e1330&&this['context']['ui']['focusTracker']['remove'](_0x483dcd);});}['_unbindEditors'](_0x41a668){this['stopListening'](_0x41a668,'editorReady'),this['stopListening'](_0x41a668,'editorDestroyed');}['_createCommentThreadView'](_0x5885f1){const _0x18d740=this['context']['plugins']['get'](it),{config:_0x13021e,locale:_0x174e42}=this['context'],_0xe55c97=mt(_0x13021e['get']('locale'));return new(0x0,(_0x13021e['get']('comments'))['CommentThreadView'])(_0x174e42,_0x5885f1,_0x18d740['me'],{'editorConfig':{..._0x13021e['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x13021e['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x13021e['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x13021e['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x13021e['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0xe55c97,'CommentView':_0x13021e['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x205b54,channelId:_0x2745d4,resolvedAt:_0x2adc76,resolvedBy:_0x237f5f,isFromAdapter:_0x1e3022}){if(!this['hasCommentThread'](_0x205b54))throw new _0x59ce32('commentsrepository-missing-comment-thread',null,{'threadId':_0x205b54});const _0x2699de=this['getCommentThread'](_0x205b54);if(_0x2699de['isResolved'])throw new _0x59ce32('commentsrepository-resolved-comment-thread',null,{'threadId':_0x205b54});const _0x5a9ed3=this['context']['plugins']['get'](it);if(_0x2699de['resolvedBy']=_0x5a9ed3['getUser'](_0x237f5f),_0x2699de['resolvedAt']=_0x2adc76,_0x1e3022||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x48d213=this['context']['plugins']['get']('PendingActions'),_0x33bb2a=_0x48d213['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x2745d4,'threadId':_0x205b54})['then'](({resolvedAt:_0x1d29be,resolvedBy:_0x2473ec})=>{_0x48d213['remove'](_0x33bb2a),_0x2699de['resolvedBy']['id']!==_0x2473ec&&(_0x2699de['resolvedBy']=_0x5a9ed3['getUser'](_0x2473ec)),_0x2699de['resolvedAt']=_0x1d29be;})['catch'](_0xbc1ce7=>{throw console['error'](_0xbc1ce7),new _0x59ce32('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x2bed3b,channelId:_0x26de09,isFromAdapter:_0x5d48be}){if(!this['hasCommentThread'](_0x2bed3b))throw new _0x59ce32('commentsrepository-missing-comment-thread',null,{'threadId':_0x2bed3b});const _0x5d2739=this['getCommentThread'](_0x2bed3b);if(!_0x5d2739['isResolved'])throw new _0x59ce32('commentsrepository-reopen-comment-thread',null,{'threadId':_0x2bed3b});if(_0x5d2739['resolvedBy']=null,_0x5d2739['resolvedAt']=null,_0x5d48be||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x1d27da=this['context']['plugins']['get']('PendingActions'),_0x51d278=_0x1d27da['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x26de09,'threadId':_0x2bed3b})['then'](()=>_0x1d27da['remove'](_0x51d278))['catch'](_0x59b2f1=>{throw console['error'](_0x59b2f1),new _0x59ce32('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0xc65efc,isFromAdapter:_0x18d587}){const _0x2299b1=this['getCommentThread'](_0xc65efc);if(!_0x2299b1)throw new _0x59ce32('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0xc65efc),this['_threads']['delete'](_0xc65efc),!_0x2299b1['isSubmitted']||_0x18d587||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x1484ac=this['context']['plugins']['get']('PendingActions'),{channelId:_0x56cd61}=_0x2299b1,_0x3ca91d=_0x1484ac['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x56cd61,'threadId':_0xc65efc})['then'](()=>_0x1484ac['remove'](_0x3ca91d))['catch'](_0x2ed107=>{throw console['error'](_0x2ed107),new _0x59ce32('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x5b0a23,unlinkedAt:_0x2de72d,context:_0x444792,attributes:_0xa79d2d,isFromAdapter:_0x5d1a4f}){if('string'!=typeof _0x5b0a23)throw new _0x59ce32('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x5b0a23});if(!this['hasCommentThread'](_0x5b0a23))throw new _0x59ce32('commentsrepository-missing-comment-thread',null,{'threadId':_0x5b0a23});const _0x766fd1=this['getCommentThread'](_0x5b0a23);let _0x2b7ed4=!0x1;if(void 0x0!==_0x444792&&_0x766fd1['context']!==_0x444792&&(_0x766fd1['context']=_0x444792,_0x2b7ed4=!0x0),void 0x0!==_0x2de72d&&_0x766fd1['unlinkedAt']!==_0x2de72d&&(_0x766fd1['unlinkedAt']=_0x2de72d,_0x2b7ed4=!0x0),_0xa79d2d&&!It(_0xa79d2d,_0x766fd1['attributes'])&&(_0x766fd1['attributes']=_0xa79d2d,_0x2b7ed4=!0x0),!_0x2b7ed4)return Promise['resolve']();if(!_0x766fd1['isSubmitted']||_0x5d1a4f||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x261844=this['context']['plugins']['get']('PendingActions'),{channelId:_0x371f6d}=_0x766fd1,_0x37c301=_0x261844['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x371f6d,'threadId':_0x5b0a23,'context':_0x444792,'unlinkedAt':_0x2de72d,'attributes':_0xa79d2d})['then'](()=>_0x261844['remove'](_0x37c301))['catch'](_0x3f333f=>{throw console['error'](_0x3f333f),new _0x59ce32('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x3fe9a3){const _0x4c0e8f=this['context']['plugins']['get'](N),_0x4baa71=this['getCommentThread'](_0x3fe9a3);if(this['_threadToController']['has'](_0x4baa71)){const _0xe29ef9=this['_threadToController']['get'](_0x4baa71),_0x5ec60a=_0xe29ef9['view'],_0x312909=_0x4c0e8f['getByInnerView'](_0x5ec60a);this['_threadToController']['delete'](_0x4baa71),this['_viewToController']['delete'](_0x5ec60a),_0x312909&&_0x4c0e8f['remove'](_0x312909),_0xe29ef9['destroy'](),_0x5ec60a['destroy']()['then'](()=>{this['_unbindEditors'](_0x5ec60a);});}}['_updateActiveAnnotation']({threadId:_0x324eda,resolvedAt:_0x17e247}){const _0x2692d3=!!_0x17e247,_0xa4ce63=this['context']['plugins']['get'](N),_0xf124b7=this['getCommentThread'](_0x324eda);if(this['_threadToController']['has'](_0xf124b7)){const _0x5bcbeb=this['_threadToController']['get'](_0xf124b7)['view'],_0x3a78da=_0xa4ce63['getByInnerView'](_0x5bcbeb);_0x3a78da&&(_0x2692d3&&_0xa4ce63['_removeActiveAnnotation'](_0x3a78da),_0x3a78da['refreshVisibility']());}}['_getExternalAuthor'](_0x4f5e2f){const _0x1ec059=this['context']['plugins']['get'](it),_0x143c28=lt('external:'+_0x4f5e2f),_0xd260a0=_0x1ec059['getUser'](_0x143c28);return _0xd260a0||_0x1ec059['addUser']({'id':_0x143c28,'name':_0x4f5e2f});}['_createNewComment']({threadId:_0x3cfad1,commentId:_0x1e6c78=_0xa3844f(),content:_0x1cd48a,authorId:_0x57de5b,createdAt:_0x3c0c5c,attributes:_0x431d6a}){if('string'!=typeof _0x1e6c78)throw new _0x59ce32('commentsrepository-invalid-commentid');if('string'!=typeof _0x57de5b)throw new _0x59ce32('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x1cd48a||!_0x1cd48a['trim']())throw new _0x59ce32('commentsrepository-invalid-comment-content');const _0xb625d6=this['context']['plugins']['get'](it)['getUser'](_0x57de5b);if(!_0xb625d6)throw new _0x59ce32('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x57de5b});let _0x216b6c=null,_0x394b42=_0x3c0c5c;return _0x431d6a&&_0x431d6a['@external']&&(_0x216b6c=this['_getExternalAuthor'](_0x431d6a['@external']['authorName']),_0x394b42=new Date(_0x431d6a['@external']['createdAt'])),new re(this,{'threadId':_0x3cfad1,'id':_0x1e6c78,'author':_0x216b6c||_0xb625d6,'creator':_0xb625d6,'content':_0x1cd48a,'createdAt':_0x3c0c5c,'authoredAt':_0x394b42,'attributes':_0x431d6a});}['_addComment'](_0x299944){let {threadId:_0x1645f7,content:_0x864c1a,attributes:_0x3e68a7,isFromAdapter:_0x13beef}=_0x299944;const _0xf2fb30=this['getCommentThread'](_0x299944['threadId']);if(!_0xf2fb30)throw new _0x59ce32('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x524f40=this['_createNewComment'](_0x299944),{id:_0x5403d3}=_0x524f40;if(_0xf2fb30['_add'](_0x524f40),_0x13beef||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0xf2fb30['isSubmitted'])return Promise['resolve']();const _0x3e4c12=this['context']['plugins']['get']('PendingActions'),{channelId:_0x2df261}=_0xf2fb30,_0x5080e8=_0x3e4c12['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x3e68a7||(_0x3e68a7={}),this['adapter']['addComment']({'channelId':_0x2df261,'threadId':_0x1645f7,'commentId':_0x5403d3,'content':_0x864c1a,'attributes':_0x3e68a7})['then'](_0x3e19ae=>{_0x3e4c12['remove'](_0x5080e8),_0x3e19ae&&this['_updateComment']({'channelId':_0x2df261,'threadId':_0x1645f7,'commentId':_0x5403d3,'createdAt':_0x3e19ae['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x4218f9=>{throw console['error'](_0x4218f9),new _0x59ce32('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x40ee64,commentId:_0xe7a398,content:_0x4ab564,createdAt:_0x5c00ac,attributes:_0x7f7a90,isFromAdapter:_0x18d118}){if(void 0x0!==_0x4ab564&&('string'!=typeof _0x4ab564||!_0x4ab564['trim']()['length']))throw new _0x59ce32('commentsrepository-update-comment-invalid-content');const _0x16130d=this['getCommentThread'](_0x40ee64),_0x1451d4=_0x16130d['getComment'](_0xe7a398);if(!_0x1451d4)throw new _0x59ce32('commentsrepository-update-missing-comment',this);let _0x51e520=!0x1;if(_0x4ab564&&_0x4ab564!==_0x1451d4['content']&&(_0x1451d4['isEditable']||_0x18d118)&&(_0x1451d4['content']=_0x4ab564,_0x51e520=!0x0),_0x5c00ac&&_0x5c00ac!==_0x1451d4['createdAt']&&(_0x1451d4['createdAt']=_0x5c00ac,_0x1451d4['attributes']&&_0x1451d4['attributes']['@external']||(_0x1451d4['authoredAt']=_0x5c00ac),_0x51e520=!0x0),_0x7f7a90&&!It(_0x7f7a90,_0x1451d4['attributes'])&&(_0x1451d4['attributes']=_0x7f7a90,_0x51e520=!0x0),!_0x51e520)return Promise['resolve']();if(_0x16130d['fire']('commentUpdated'),_0x18d118||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x18f448=this['context']['plugins']['get']('PendingActions'),{channelId:_0x19ecae}=this['getCommentThread'](_0x1451d4['threadId']),_0x56b343=_0x18f448['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x19ecae,'threadId':_0x40ee64,'commentId':_0xe7a398,'content':_0x4ab564,'attributes':_0x7f7a90})['then'](()=>_0x18f448['remove'](_0x56b343))['catch'](_0x4361d3=>{throw console['error'](_0x4361d3),new _0x59ce32('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0xad6941,commentId:_0xba9261,isFromAdapter:_0x102b34}){const _0x396657=this['getCommentThread'](_0xad6941),_0x290516=_0x396657['getComment'](_0xba9261);if(!_0x290516)throw new _0x59ce32('commentsrepository-remove-missing-comment',this);if(_0x396657['_remove'](_0x290516),_0x102b34||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x8bc850=this['context']['plugins']['get']('PendingActions'),{channelId:_0x1ddfdb}=_0x396657,_0x108d54=_0x8bc850['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x1ddfdb,'threadId':_0xad6941,'commentId':_0xba9261})['then'](()=>_0x8bc850['remove'](_0x108d54))['catch'](_0xa4def4=>{throw console['error'](_0xa4def4),new _0x59ce32('commentsrepository-remove-comment-internal-error',this);});}}class oe extends/* #__PURE__ -- @preserve */
|
|
30
|
-
|
|
31
|
-
_0x13a315(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x112f79,_0x4d6d42){super();const _0x10890a=_0x112f79['context']['plugins']['get'](it)['me'],_0x5dc0d8=_0x112f79['getCommentThread'](_0x4d6d42['threadId']),_0x2f7285=0x0===_0x5dc0d8['comments']['length'],_0x2417f4=_0x10890a===_0x4d6d42['author'];this['id']=_0x4d6d42['id'],this['threadId']=_0x4d6d42['threadId'],this['author']=_0x4d6d42['author'],this['creator']=_0x4d6d42['creator'],this['isExternal']=Boolean(_0x4d6d42['attributes']&&_0x4d6d42['attributes']['@external']),this['set']('content',_0x4d6d42['content']),this['createdAt']=_0x4d6d42['createdAt']||new Date(),this['set']('authoredAt',_0x4d6d42['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x5dc0d8,'resolvedAt'),this['set']('attributes',_0x4d6d42['attributes']||{}),this['bind']('isEditable')['to'](_0x112f79,'_permissions',()=>{const _0x35e17c=_0x112f79['getPermissions'](_0x5dc0d8['channelId'])['write'],_0x4e1c00=_0x112f79['getPermissions'](_0x5dc0d8['channelId'])['modifyAll'];return _0x2417f4&&_0x35e17c||!_0x2417f4&&_0x4e1c00;}),this['bind']('isRemovable')['to'](_0x5dc0d8,'isRemovable',_0x112f79,'_permissions',_0x5b36c1=>{const _0x52a4a4=_0x112f79['getPermissions'](_0x5dc0d8['channelId'])['write'],_0x3c04d7=_0x112f79['getPermissions'](_0x5dc0d8['channelId'])['modifyAll'];return _0x2417f4&&_0x52a4a4||_0x5b36c1&&_0x2f7285||!_0x2417f4&&_0x3c04d7&&!_0x2f7285;}),this['bind']('isReadOnly')['to'](_0x5dc0d8,'isReadOnly'),this['_repository']=_0x112f79;}get['weight'](){return Math['max'](function(_0x37786){const _0x56a275=document['createElement']('div');return _0x56a275['innerHTML']=_0x37786,_0x56a275['textContent']['length'];}(this['content']),0xc8);}['update'](_0x14165f){const {threadId:_0x213236,id:_0x2c2259}=this;if(!this['_repository']['hasCommentThread'](_0x213236))throw new _0x59ce32('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x44763c}=this['_repository']['getCommentThread'](_0x213236);this['_repository']['fire'](_t('updateComment',_0x44763c,_0x213236),{'channelId':_0x44763c,'threadId':_0x213236,'commentId':_0x2c2259,..._0x14165f});}['setAttribute'](_0x53fb5f,_0x25d66e){const _0x192169=pt(this['attributes']);wt(_0x192169,_0x53fb5f,_0x25d66e),this['update']({'attributes':_0x192169});}['removeAttribute'](_0x8a8930){const _0x20403b=pt(this['attributes']);At(_0x20403b,_0x8a8930),this['update']({'attributes':_0x20403b});}['remove'](_0x3539ad={}){if(!_0x3539ad['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x5e93b7,id:_0x1a874f}=this;if(!this['_repository']['hasCommentThread'](_0x5e93b7))throw new _0x59ce32('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x22c0f4}=this['_repository']['getCommentThread'](_0x5e93b7);this['_repository']['fire'](_t('removeComment',_0x22c0f4,_0x5e93b7),{'channelId':_0x22c0f4,'threadId':_0x5e93b7,'commentId':_0x1a874f,..._0x3539ad});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function _t(_0x26f452,..._0x5f4b69){for(const _0x7b0b78 of _0x5f4b69)void 0x0!==_0x7b0b78&&(_0x26f452+=':'+String(_0x7b0b78));return _0x26f452;}class J extends _0x324c72{['refresh'](){const _0x3f693c=this['editor']['model']['document']['selection'];for(const _0x273ae4 of _0x3f693c['getRanges']())if(this['_hasContent'](_0x273ae4))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['execute']({threadId:_0x3ef2ca=_0xa3844f()}={}){const _0x3f27b6=this['editor']['model'],_0x131a07=[];for(const _0x107581 of _0x3f27b6['document']['selection']['getRanges']())this['_hasContent'](_0x107581)&&_0x131a07['push'](this['_trimToContent'](_0x107581));_0x3f27b6['change'](_0xb24d76=>{for(const _0xabaa58 of _0x131a07){const _0x739951=_0xa3844f()['substr'](0x1,0x5),_0x331855='comment:'+_0x3ef2ca+':'+_0x739951;_0xb24d76['addMarker'](_0x331855,{'range':_0xabaa58,'usingOperation':!0x1,'affectsData':!0x1});}});}['_hasContent'](_0x539992){for(const _0x5b1988 of _0x539992['getItems']())if(this['_itemIsContent'](_0x5b1988))return!0x0;return!0x1;}['_itemIsContent'](_0x3f220a){return _0x3f220a['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x3f220a)&&!_0x3f220a['is']('element','tableCell');}['_trimToContent'](_0x5c63e9){const _0x5af134=_0xd4e7c8=>!this['_itemIsContent'](_0xd4e7c8['item']),_0x1585e0=_0x5c63e9['start']['getLastMatchingPosition'](_0x5af134),_0x757914=_0x5c63e9['end']['getLastMatchingPosition'](_0x5af134,{'direction':'backward'});return this['editor']['model']['createRange'](_0x1585e0,_0x757914);}}class P extends _0x5a85ea{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[N];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3a80f8){super(_0x3a80f8),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x13646b=this['editor'],_0x2c3017=_0x13646b['model']['document']['selection'],_0x2f0c5e=_0x58a7c2(()=>this['refreshSelectedViews'](),0xa);_0x2c3017['on']('change:range',(_0x3a0bd9,_0x5bf5fe)=>{_0x5bf5fe['directChange']&&(_0x2f0c5e['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x13646b['editing']['view']['document'],'change:isFocused',(_0x678d63,_0x1ee3e4,_0x3d4cd2)=>{_0x3d4cd2&&_0x2f0c5e();}),this['listenTo'](_0x13646b['ui']['focusTracker'],'change:isFocused',(_0xb87857,_0x245fb7,_0x2baeb1)=>{_0x2baeb1||_0x13646b['isReadOnly']||this['fire']('blur',{'isAnnotationTracked':_0x4831c2=>this['_editorAnnotationsData']['has'](_0x4831c2['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x400dd4){if(this['_editorAnnotations']['has'](_0x400dd4['view']))return;this['_editorAnnotations']['add'](_0x400dd4['view']),this['editor']['ui']['focusTracker']['add'](_0x400dd4['view']['element']);const _0x4e74fd=this['editor']['plugins']['get'](N);this['listenTo'](_0x4e74fd['collection'],'remove',(_0x56d5bb,_0x131c42)=>{this['editor']['ui']['focusTracker']['remove'](_0x131c42['view']['element']),this['_editorAnnotations']['delete'](_0x131c42['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x8d5c89){if('function'!=typeof _0x8d5c89)throw new _0x59ce32('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x8d5c89);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x410826,annotations:_0x3b6eb9}){const _0x322d49=[],_0x182edb=this['editor']['model']['document']['selection'],_0xa96da6=Array['from'](_0x182edb['getRanges']());for(const [_0x607f92,_0x570a8e]of this['_editorAnnotationsData']){const _0x514580=_0x44c6f4(_0x570a8e),_0x1492b8=_0x3b6eb9['getByInnerView'](_0x607f92);_0x514580&&_0x1492b8&&_0x322d49['push']({'annotation':_0x1492b8,'range':_0x514580});}function _0x44c6f4(_0x2bf330){for(const _0x26c30f of _0x2bf330)for(const _0x12100f of _0xa96da6)if(_0x26c30f['containsRange'](_0x12100f,!_0x182edb['isCollapsed']))return _0x26c30f;return null;}return _0x322d49['sort']((_0x1de607,_0x3322ea)=>{const _0x2bb788=_0x1de607['range'],_0x5ecf65=_0x3322ea['range'];if(!_0x2bb788['isEqual'](_0x5ecf65)){if(_0x2bb788['containsRange'](_0x5ecf65,!0x0))return 0x1;if(_0x5ecf65['containsRange'](_0x2bb788,!0x0))return-0x1;}return _0x1de607['annotation']==_0x410826?-0x1:_0x3322ea['annotation']==_0x410826?0x1:0x0;})['map'](_0x1925f6=>_0x1925f6['annotation']);}get['_editorAnnotationsData'](){const _0x1901eb=new Map();for(const _0x17a796 of Array['from'](this['_dataCollectors']))for(const [_0x2da105,_0x314cac]of _0x17a796())_0x1901eb['set'](_0x2da105,_0x314cac);return _0x1901eb;}}class st extends _0x5a85ea{['afterInit'](){const _0x194fb4=this['editor'];if(!_0x194fb4['plugins']['has']('RestrictedEditingModeEditing'))return;_0x194fb4['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x5a85ea{constructor(_0x71c272){super(_0x71c272),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x575e30=this['editor'],_0x3c97ae=_0x575e30['commands']['get']('importWord'),_0x4b34b3=_0x575e30['plugins']['get'](it);_0x3c97ae&&(_0x3c97ae['on']('execute',(_0x5e1b23,[,_0x30670b])=>{_0x30670b['collaboration_features']={'comments':!0x0,'user_id':_0x4b34b3['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x3c97ae,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x47d3b8,_0x483b36){const {comment_threads:_0x55c10f}=_0x483b36;_0x55c10f&&_0x55c10f['forEach'](({thread_id:_0x223b8b,comments:_0x1d03f1,is_resolved:_0x51bc23})=>{const _0x290a99=new Date(),_0x328ece=_0x1d03f1['map'](({author:_0x70aef5,content:_0x446304,created_at:_0x3f9504})=>({'content':_0x446304,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x290a99,'attributes':{'@external':{'authorName':_0x70aef5,'createdAt':_0x3f9504?new Date(_0x3f9504):new Date(),'source':'importWord'}}})),_0x471c9d=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x471c9d,'threadId':_0x223b8b,'comments':_0x328ece,'resolvedAt':_0x51bc23?_0x290a99:null});});}}class at extends _0x5a85ea{constructor(_0x5126be){super(_0x5126be),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x2b31b1=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x2b31b1,'contentInsertion',(_0x54c39d,_0x5b1afc)=>this['_removeMarkersWithoutThreads'](_0x5b1afc['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x2cc56a){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x2cc56a;const _0x20010a=this['editor']['plugins']['get']('CommentsRepository');for(const _0x19feba of _0x2cc56a['keys']()){const [_0x2fc51b,_0x7af4b7]=_0x19feba['split'](':');'comment'!=_0x2fc51b||_0x20010a['hasCommentThread'](_0x7af4b7)||_0x2cc56a['delete'](_0x19feba);}return _0x2cc56a;}['_registerMarkerInClipboardPipeline'](){const _0x10a69d=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x28e4e9=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x28e4e9&&_0x10a69d['_registerMarkerToCopy']('comment',_0x28e4e9);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x3a42ad){switch(_0x3a42ad){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}class r extends _0x5a85ea{static get['requires'](){return[o,P,it,st,ct,at];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3479e0){super(_0x3479e0),this['set']('isThreadsLoadingPaused',!0x0),_0x3479e0['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x63a8d3,_0x36ed82,_0x4d17bf,_0x45186e)=>{const _0x2f1e61=_0x4d17bf?he(_0x4d17bf)['id']:null;if(_0x3479e0['model']['change'](()=>{if(_0x2f1e61){const _0x26342e=this['getAllMarkersForId'](_0x2f1e61);for(const _0x31f24d of _0x26342e)_0x3479e0['editing']['reconvertMarker'](_0x31f24d);}if(_0x45186e){const {id:_0x587d8d}=he(_0x45186e),_0x112a02=this['getAllMarkersForId'](_0x587d8d);for(const _0x23d68b of _0x112a02)_0x3479e0['editing']['reconvertMarker'](_0x23d68b);}}),_0x2f1e61){const _0x52cdee=_0x3479e0['plugins']['get'](o)['getCommentThread'](_0x2f1e61);_0x52cdee&&_0x52cdee['isResolved']&&this['scrollToThreadMarker'](_0x2f1e61);}}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x3c6bfa=this['editor'],_0x5cb012=_0x3c6bfa['plugins']['get'](o),_0x1a76e1=_0x3c6bfa['config']['get']('collaboration.channelId');_0x3c6bfa['commands']['add']('addCommentThread',new J(_0x3c6bfa)),this['listenTo'](_0x3c6bfa,'change:isReadOnly',(_0x454dfb,_0x328461,_0x57b9d3)=>{_0x5cb012['switchReadOnly'](_0x57b9d3,_0x3c6bfa['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x5cb012,ut('addCommentThread',_0x1a76e1),(_0x55cfef,{threadId:_0x5aa0da})=>{const _0x273c3e=this['editor']['plugins']['get'](o)['getCommentThread'](_0x5aa0da);_0x273c3e&&_0x273c3e['unlinkedAt']&&this['_attachArchivedThread'](_0x5aa0da);}),this['listenTo'](_0x5cb012,ut('removeCommentThread',_0x1a76e1),(_0xbf2224,{threadId:_0x402458})=>{_0x3c6bfa['model']['enqueueChange']({'isUndoable':!0x1},_0x276773=>{const _0x5d9e20=this['getAllMarkersForId'](_0x402458);for(const _0x4eec99 of _0x5d9e20)_0x276773['removeMarker'](_0x4eec99);});}),this['listenTo'](_0x5cb012,ut('resolveCommentThread',_0x1a76e1),(_0x1f18e2,{threadId:_0x361080})=>{(this['_reconvertMarkers'](_0x361080),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x361080)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x5cb012,ut('reopenCommentThread',_0x1a76e1),(_0x575e0f,{threadId:_0x4e01a4})=>{this['_reconvertMarkers'](_0x4e01a4);},{'priority':'low'}),this['listenTo'](_0x5cb012,ut('addComment',_0x1a76e1),(_0x36792d,{threadId:_0x119b60,isFromAdapter:_0x22bde7})=>{const _0x1df4e4=this['getAllMarkersForId'](_0x119b60);if(_0x22bde7||0x0==_0x1df4e4['length']||!_0x5cb012['hasCommentThread'](_0x119b60))return;0x1===_0x5cb012['getCommentThread'](_0x119b60)['length']&&_0x3c6bfa['model']['enqueueChange']({'isUndoable':!0x1},_0x13ad23=>{for(const _0x2b4c85 of _0x1df4e4)_0x13ad23['updateMarker'](_0x2b4c85,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove']();}['afterInit'](){!async function(_0x363409){const _0x40c19b=_0x46cc79([0x52,0x44,0x5a,0x78,0x37,0x6b,0x58,0x53,0x42,0x65,0x41,0x4d,0x55,0x51,0x4b,0x69,0x31,0x6c,0x4e,0x6d,0x61,0x64,0x70,0x35,0x68,0x46,0x76,0x4a,0x54,0x4f,0x39,0x50,0x34,0x45,0x6a,0x38,0x33,0x48,0x72,0x75,0x57,0x4c,0x56,0x74,0x59,0x77,0x47,0x32,0x67,0x63,0x6e,0x71,0x62,0x79,0x49,0x7a,0x73,0x66,0x36,0x43,0x6f,0x30]),_0xe11ba9=0x2420b81d,_0x548369=0x2427efad^_0xe11ba9,_0x27b6f7=window[_0x46cc79([0x44,0x61,0x74,0x65])][_0x46cc79([0x6e,0x6f,0x77])](),_0x93ebdf=_0x363409[_0x46cc79([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x10f132=new window[(_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x30222c=>{_0x93ebdf[_0x46cc79([0x6f,0x6e,0x63,0x65])](_0x46cc79([0x72,0x65,0x61,0x64,0x79]),_0x30222c);}),_0x19464c={[_0x46cc79([0x6b,0x74,0x79])]:_0x46cc79([0x45,0x43]),[_0x46cc79([0x75,0x73,0x65])]:_0x46cc79([0x73,0x69,0x67]),[_0x46cc79([0x63,0x72,0x76])]:_0x46cc79([0x50,0x2d,0x32,0x35,0x36]),[_0x46cc79([0x78])]:_0x46cc79([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]),[_0x46cc79([0x79])]:_0x46cc79([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]),[_0x46cc79([0x61,0x6c,0x67])]:_0x46cc79([0x45,0x53,0x32,0x35,0x36])},_0x12bc25=_0x93ebdf[_0x46cc79([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x46cc79([0x67,0x65,0x74])](_0x46cc79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x565055(){let _0x16757d,_0x351d03=null,_0x257eff=null;try{if(_0x12bc25==_0x46cc79([0x47,0x50,0x4c]))return _0x46cc79([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x16757d=_0x3f19fc(),!_0x16757d)return _0x46cc79([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x16757d[_0x46cc79([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x257eff=_0x24864a(_0x16757d[_0x46cc79([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x16757d[_0x46cc79([0x6a,0x74,0x69])])),await _0x52161b()?_0x226a24()?_0x5f13a4()?_0x46cc79([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x38ecd3()?(_0x16757d[_0x46cc79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x46cc79([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x351d03=_0x1ddd7e(_0x46cc79([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x16757d[_0x46cc79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x46cc79([0x74,0x72,0x69,0x61,0x6c])&&(_0x351d03=_0x1ddd7e(_0x46cc79([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x16757d[_0x46cc79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x46cc79([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x351d03=_0x1ddd7e(_0x46cc79([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4399b2()):_0x46cc79([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x46cc79([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x46cc79([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x4c5cb3){return _0x46cc79([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5f13a4(){const _0x53cfb9=[_0x46cc79([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x46cc79([0x74,0x72,0x69,0x61,0x6c])][_0x46cc79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16757d[_0x46cc79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x27b6f7/0x3e8:0xe10*_0x548369;return _0x16757d[_0x46cc79([0x65,0x78,0x70])]<_0x53cfb9;}function _0x226a24(){const _0xbea261=_0x16757d[_0x46cc79([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0xbea261&&(!!_0xbea261[_0x46cc79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x46cc79([0x2a]))||(!!_0xbea261[_0x46cc79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x46cc79([0x43,0x4d,0x54]))||!(!_0xbea261[_0x46cc79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x46cc79([0x52,0x43,0x4d,0x54]))||!_0x43c7d7())));}function _0x38ecd3(){const _0x37ff53=_0x16757d[_0x46cc79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x37ff53||0x0==_0x37ff53[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xafd193}=new URL(window[_0x46cc79([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x37ff53[_0x46cc79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xafd193))return!0x0;const _0x147069=_0xafd193[_0x46cc79([0x73,0x70,0x6c,0x69,0x74])](_0x46cc79([0x2e]));return _0x37ff53[_0x46cc79([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5941de=>_0x5941de[_0x46cc79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x46cc79([0x2a])))[_0x46cc79([0x6d,0x61,0x70])](_0x3de973=>_0x3de973[_0x46cc79([0x73,0x70,0x6c,0x69,0x74])](_0x46cc79([0x2e])))[_0x46cc79([0x73,0x6f,0x6d,0x65])](_0x1a834f=>_0x147069[_0x46cc79([0x65,0x76,0x65,0x72,0x79])]((_0x95c913,_0x971965)=>_0x1a834f[_0x971965]===_0x95c913||_0x1a834f[_0x971965]===_0x46cc79([0x2a])));}function _0x4399b2(){return _0x351d03&&_0x257eff?new window[(_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2d81de,_0x357282)=>{_0x351d03[_0x46cc79([0x74,0x68,0x65,0x6e])](_0x2d81de,_0x357282),_0x257eff[_0x46cc79([0x74,0x68,0x65,0x6e])](_0x46aa05=>{_0x46aa05!=_0x46cc79([0x56,0x61,0x6c,0x69,0x64])&&_0x2d81de(_0x46aa05);},_0x357282);}):_0x351d03||_0x257eff||_0x46cc79([0x56,0x61,0x6c,0x69,0x64]);}}function _0x24864a(_0x17935f,_0xc0ffc7){return new window[(_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x68d4fc=>{if(_0x24bd3e())return _0x68d4fc(_0x46cc79([0x56,0x61,0x6c,0x69,0x64]));_0x12ba3d(),_0x93ebdf[_0x46cc79([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x46cc79([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x13b5ed=!0x1;const _0x1d0929=_0xa3844f();function _0x116cf7(_0x339a47){return!!_0x339a47&&(typeof _0x339a47===_0x46cc79([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x339a47===_0x46cc79([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x339a47[_0x46cc79([0x74,0x68,0x65,0x6e])]===_0x46cc79([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x339a47[_0x46cc79([0x63,0x61,0x74,0x63,0x68])]===_0x46cc79([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4eea0e(_0x59cd1b){_0x1c1aa4(_0x59cd1b)[_0x46cc79([0x74,0x68,0x65,0x6e])](_0x4e723c=>{if(!_0x4e723c||_0x4e723c[_0x46cc79([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x46cc79([0x6f,0x6b]))return _0x46cc79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3f9954(_0x243639(_0x1d0929+_0xc0ffc7))!=_0x4e723c[_0x46cc79([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x46cc79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x46cc79([0x56,0x61,0x6c,0x69,0x64]);})[_0x46cc79([0x74,0x68,0x65,0x6e])](_0x3024ff=>(_0x424e37(),_0x3024ff),()=>{const _0x190458=_0xf8e87a();return null==_0x190458?(_0x424e37(),_0x46cc79([0x56,0x61,0x6c,0x69,0x64])):_0x46cc79(_0x27b6f7-_0x190458>(0x2c3c1d^_0xe11ba9)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x46cc79([0x74,0x68,0x65,0x6e])](_0x68d4fc)[_0x46cc79([0x63,0x61,0x74,0x63,0x68])](()=>{_0x68d4fc(_0x46cc79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x2191b7=0x2416569d^_0xe11ba9;function _0x424e37(){const _0x2a701a=_0x46cc79([0x6c,0x6c,0x63,0x74,0x2d])+_0x3f9954(_0x243639(_0x17935f)),_0x3b8e70=_0x1233e1(_0x3f9954(window[_0x46cc79([0x4d,0x61,0x74,0x68])][_0x46cc79([0x63,0x65,0x69,0x6c])](_0x27b6f7/_0x2191b7)));window[_0x46cc79([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x46cc79([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2a701a,_0x3b8e70);}function _0xf8e87a(){const _0x258820=_0x46cc79([0x6c,0x6c,0x63,0x74,0x2d])+_0x3f9954(_0x243639(_0x17935f)),_0xf3534f=window[_0x46cc79([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x46cc79([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x258820);return _0xf3534f?window[_0x46cc79([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1233e1(_0xf3534f),0x10)*_0x2191b7:null;}function _0x1c1aa4(_0x46ebb4){return new window[(_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2f4e3d,_0x2d42a4)=>{_0x46ebb4[_0x46cc79([0x74,0x68,0x65,0x6e])](_0x2f4e3d,_0x2d42a4),window[_0x46cc79([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2d42a4,0x24216cdd^_0xe11ba9);});}}_0x93ebdf[_0x46cc79([0x6f,0x6e])](_0x46cc79([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5012a2,_0x1c8e67)=>{if(_0x1c8e67[0x0]!=_0x17935f)return _0x68d4fc(_0x46cc79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1c8e67[0x1]={..._0x1c8e67[0x1],[_0x46cc79([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1d0929};},{[_0x46cc79([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x46cc79([0x68,0x69,0x67,0x68])}),_0x93ebdf[_0x46cc79([0x6f,0x6e])](_0x46cc79([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4bb611=>{_0x116cf7(_0x4bb611[_0x46cc79([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x13b5ed=!0x0,_0x4eea0e(_0x4bb611[_0x46cc79([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x46cc79([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x46cc79([0x6c,0x6f,0x77])}),_0x10f132[_0x46cc79([0x74,0x68,0x65,0x6e])](()=>{_0x13b5ed||_0x68d4fc(_0x46cc79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x24bd3e(){return _0x93ebdf[_0x46cc79([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x46cc79([0x76,0x69,0x65,0x77])][_0x46cc79([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x46cc79([0x61,0x75,0x74,0x6f]);}function _0x12ba3d(){_0x93ebdf[_0x46cc79([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x46cc79([0x76,0x69,0x65,0x77])][_0x46cc79([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x46cc79([0x61,0x75,0x74,0x6f]);}}function _0x1ddd7e(_0x1c85d3){const _0x5d9f53=[new window[(_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3f18ca=>setTimeout(_0x3f18ca,0x242986d1^_0xe11ba9)),_0x10f132[_0x46cc79([0x74,0x68,0x65,0x6e])](()=>new window[(_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1d1756=>{let _0x1141e8=0x0;_0x93ebdf[_0x46cc79([0x6d,0x6f,0x64,0x65,0x6c])][_0x46cc79([0x6f,0x6e])](_0x46cc79([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x5099c9,_0x181335)=>{_0x181335[0x0][_0x46cc79([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x1141e8++,_0x1141e8==(0x2420b9e5^_0xe11ba9)&&(_0x1d1756(),_0x5099c9[_0x46cc79([0x6f,0x66,0x66])]());});}))];return window[_0x46cc79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x46cc79([0x72,0x61,0x63,0x65])](_0x5d9f53)[_0x46cc79([0x74,0x68,0x65,0x6e])](()=>_0x1c85d3);}async function _0x365782(){await _0x10f132,_0x93ebdf[_0x46cc79([0x6d,0x6f,0x64,0x65,0x6c])][_0x46cc79([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5c432c,_0x93ebdf[_0x46cc79([0x6d,0x6f,0x64,0x65,0x6c])][_0x46cc79([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5c432c,_0x93ebdf[_0x46cc79([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x46cc79([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x43c7d7(){return _0x2d7b50(_0x46cc79([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x444bfd(_0x46cc79([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x46cc79([0x73,0x74,0x61,0x74,0x65])]==_0x46cc79([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x21e127(_0x54f547){const _0x5ce997=_0x398dc8();_0x93ebdf[_0x5ce997]=_0x46cc79([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x54f547,_0x54f547!=_0x46cc79([0x56,0x61,0x6c,0x69,0x64])&&_0x365782();}function _0x398dc8(){const _0x48e7eb=window[_0x46cc79([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x46cc79([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x46cc79([0x6e,0x6f,0x77])]())[_0x46cc79([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x46cc79([0x2e]),'');let _0x2f644d=_0x46cc79([0x52]);for(let _0x583ed4=0x0;_0x583ed4<_0x48e7eb[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x583ed4+=0x2){let _0x5246d2=window[_0x46cc79([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x48e7eb[_0x46cc79([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x583ed4,_0x583ed4+0x2));_0x5246d2>=_0x40c19b[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5246d2-=_0x40c19b[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2f644d+=_0x40c19b[_0x5246d2];}return _0x2f644d;}function _0x3f19fc(){const _0x20518e=_0x12bc25[_0x46cc79([0x73,0x70,0x6c,0x69,0x74])](_0x46cc79([0x2e]));if(0x3!=_0x20518e[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x369037(_0x20518e[0x1]);function _0x369037(_0x3df452){const _0x40c7ce=_0x1bd07c(_0x3df452);return _0x40c7ce&&_0x4da2df()?_0x40c7ce:null;function _0x4da2df(){const _0x348116=_0x40c7ce[_0x46cc79([0x6a,0x74,0x69])],_0x1e5297=window[_0x46cc79([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x348116[_0x46cc79([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x348116[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x56286e={..._0x40c7ce,[_0x46cc79([0x6a,0x74,0x69])]:_0x348116[_0x46cc79([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x348116[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x56286e[_0x46cc79([0x76,0x63])],_0x243639(_0x56286e)==_0x1e5297;}}}async function _0x52161b(){let _0x1ba3f6=!0x0;try{const _0x5791d2=_0x12bc25[_0x46cc79([0x73,0x70,0x6c,0x69,0x74])](_0x46cc79([0x2e])),[_0x4005f6,_0x5d4993,_0x338a9a]=_0x5791d2;return _0x4bd681(_0x4005f6),await _0x3132b0(_0x4005f6,_0x5d4993,_0x338a9a),_0x1ba3f6;}catch(_0x9b5620){return!0x1;}function _0x4bd681(_0x285f89){const _0xab85a3=_0x1bd07c(_0x285f89);_0xab85a3&&_0xab85a3[_0x46cc79([0x61,0x6c,0x67])]==_0x46cc79([0x45,0x53,0x32,0x35,0x36])||(_0x1ba3f6=!0x1);}async function _0x3132b0(_0x223496,_0x36a5de,_0x5412c9){const _0x2a3309=window[_0x46cc79([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x46cc79([0x66,0x72,0x6f,0x6d])](_0x59bd12(_0x5412c9),_0x40e7b0=>_0x40e7b0[_0x46cc79([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x510d98=new window[(_0x46cc79([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x46cc79([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x223496+_0x46cc79([0x2e])+_0x36a5de),_0x236521=window[_0x46cc79([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x46cc79([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x236521)return;const _0xd10069=await _0x236521[_0x46cc79([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x46cc79([0x6a,0x77,0x6b]),_0x19464c,{[_0x46cc79([0x6e,0x61,0x6d,0x65])]:_0x46cc79([0x45,0x43,0x44,0x53,0x41]),[_0x46cc79([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x46cc79([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x46cc79([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x236521[_0x46cc79([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x46cc79([0x6e,0x61,0x6d,0x65])]:_0x46cc79([0x45,0x43,0x44,0x53,0x41]),[_0x46cc79([0x68,0x61,0x73,0x68])]:{[_0x46cc79([0x6e,0x61,0x6d,0x65])]:_0x46cc79([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xd10069,_0x2a3309,_0x510d98)||(_0x1ba3f6=!0x1);}}function _0x1bd07c(_0x4ef68f){return _0x4ef68f[_0x46cc79([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x46cc79([0x65,0x79]))?JSON[_0x46cc79([0x70,0x61,0x72,0x73,0x65])](_0x59bd12(_0x4ef68f)):null;}function _0x59bd12(_0x3643bb){return window[_0x46cc79([0x61,0x74,0x6f,0x62])](_0x3643bb[_0x46cc79([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x46cc79([0x2b]))[_0x46cc79([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x46cc79([0x2f])));}function _0x243639(_0x49f381){let _0x5642ef=0x1505;function _0x1f32a1(_0x26d5d6){for(let _0x1cc6f6=0x0;_0x1cc6f6<_0x26d5d6[_0x46cc79([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1cc6f6++){const _0x429176=_0x26d5d6[_0x46cc79([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1cc6f6);_0x5642ef=(_0x5642ef<<0x5)+_0x5642ef+_0x429176,_0x5642ef&=_0x5642ef;}}function _0x305edd(_0x39a80d){Array[_0x46cc79([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x39a80d)?_0x39a80d[_0x46cc79([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x305edd):_0x39a80d&&typeof _0x39a80d==_0x46cc79([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x46cc79([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x39a80d)[_0x46cc79([0x73,0x6f,0x72,0x74])]()[_0x46cc79([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2e7513,_0x2e1eba])=>{_0x1f32a1(_0x2e7513),_0x305edd(_0x2e1eba);}):_0x1f32a1(window[_0x46cc79([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x39a80d));}return _0x305edd(_0x49f381),_0x5642ef>>>0x0;}function _0x3f9954(_0x4db49e){return _0x4db49e[_0x46cc79([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x46cc79([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x46cc79([0x30]));}function _0x1233e1(_0x2823b1){return _0x2823b1[_0x46cc79([0x73,0x70,0x6c,0x69,0x74])]('')[_0x46cc79([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x46cc79([0x6a,0x6f,0x69,0x6e])]('');}function _0x2d7b50(_0x58dc75){return _0x93ebdf[_0x46cc79([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x46cc79([0x68,0x61,0x73])](_0x58dc75);}function _0x444bfd(_0x2a7fbb){return _0x93ebdf[_0x46cc79([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x46cc79([0x67,0x65,0x74])](_0x2a7fbb);}function _0x5c432c(){}function _0x46cc79(_0x55acc3){return _0x55acc3['map'](_0x8c9cd4=>String['fromCharCode'](_0x8c9cd4))['join']('');}_0x21e127(await _0x565055());}(this);}['destroy'](){const _0x4d5e55=this['editor']['plugins']['get'](o),_0x36a125=this['editor']['config']['get']('collaboration.channelId');for(const _0xa0eb59 of _0x4d5e55['getCommentThreads']({'channelId':_0x36a125}))_0x4d5e55['_detachCommentThread'](_0xa0eb59['id']),_0x4d5e55['_threads']['delete'](_0xa0eb59['id']);super['destroy']();}['hasMarkerForId'](_0x33bb47){return this['getAllMarkersForId'](_0x33bb47)['length']>0x0;}['getAllMarkersForId'](_0x4a101d){const _0x2400f7=[];for(const _0x5e6d1f of this['editor']['model']['markers'])_0x5e6d1f['name']['startsWith']('comment:'+_0x4a101d)&&_0x2400f7['push'](_0x5e6d1f);return _0x2400f7;}['scrollToThreadMarker'](_0x4094c5){const _0x409de4=this['_getTargetForId'](_0x4094c5);_0x409de4&&setTimeout(()=>{this['activeMarker']&&he(this['activeMarker'])['id']===_0x4094c5&&rt({'target':_0x409de4[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x20032c){this['editor']['model']['change'](()=>{for(const _0x15e16f of this['getAllMarkersForId'](_0x20032c))this['editor']['editing']['reconvertMarker'](_0x15e16f);});}['_attachArchivedThread'](_0x295eba){const _0x5cbefb=this['editor']['plugins']['get'](o),_0x3a929c=this['editor']['plugins']['get'](P),_0x1b1635=_0x5cbefb['getCommentThread'](_0x295eba);if(!_0x1b1635['isAttached']){const _0x486e3b=_0x1b1635['attachTo'](()=>this['_getTargetForId'](_0x1b1635['id']));_0x3a929c['registerAnnotation'](_0x486e3b),_0x1b1635['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x5b13e8=this['editor'],_0x5228ce=_0x5b13e8['plugins']['get'](it);_0x5b13e8['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x51e9ed,_0x109d58)=>{const {id:_0x10ec19}=he(_0x51e9ed['markerName']),_0x5a6826=_0x5b13e8['plugins']['get'](o)['getCommentThread'](_0x10ec19),_0x1f2954=this['activeMarker']&&he(this['activeMarker'])['id']===_0x10ec19;let _0xd9a287;if(_0x5a6826&&_0x5a6826['isResolved']&&!_0x1f2954&&_0x51e9ed['item'])return _0x109d58['consumable']['consume'](_0x51e9ed['item'],'addMarker:'+_0x51e9ed['markerName']),_0x109d58['consumable']['consume'](_0x51e9ed['item'],'removeMarker:'+_0x51e9ed['markerName']),null;const _0x250575=['ck-comment-marker'];return _0x1f2954&&_0x250575['push']('ck-comment-marker--active'),_0xd9a287=_0x5a6826&&_0x5a6826['length']?_0x5a6826['comments']['first']['author']['id']:_0x5228ce['me']['id'],{'classes':_0x250575,'attributes':{'data-comment':_0x10ec19,'data-author-id':_0xd9a287}};}}),_0x5b13e8['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x3ed982,{options:_0xe3dcc1})=>{const _0x406a91=_0x5b13e8['plugins']['get'](o),_0x484c15=_0x5b13e8['model']['markers']['get'](_0x3ed982),{id:_0x444d1a,part:_0x3240ed}=he(_0x3ed982);if(_0x484c15&&!_0x484c15['affectsData'])return null;if(_0xe3dcc1['ignoreResolvedComments']){const _0xcc1b48=_0x406a91['getCommentThread'](_0x444d1a);if(_0xcc1b48&&_0xcc1b48['isResolved'])return null;}return{'group':'comment','name':_0x3240ed?_0x444d1a+':'+_0x3240ed:_0x444d1a};}}),_0x5b13e8['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x45c5c1,{writer:_0x57813d})=>_0x57813d['createElement']('$marker',{'data-name':'comment:'+_0x45c5c1['getAttribute']('id')})}),_0x5b13e8['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x2ae4fb=this['editor'],_0x5d1f5c=_0x2ae4fb['plugins']['get'](o),_0x4f852a=new Set(),_0x1f8b12=new Set();_0x2ae4fb['model']['document']['registerPostFixer'](_0x25ab17=>{let _0x1ae12d=!0x1;for(const {name:_0x767c53,data:_0x29e794}of _0x2ae4fb['model']['document']['differ']['getChangedMarkers']()){const {group:_0x44b45b,id:_0xa5785e}=he(_0x767c53);let _0x4ccd67=_0x29e794['newRange'];if('comment'!==_0x44b45b||!_0x4ccd67)continue;const _0x5e6d2e='$graveyard'===_0x4ccd67['root']['rootName'];_0x5e6d2e||(_0x4ccd67=ft(_0x4ccd67,_0x2ae4fb['model']),!_0x4ccd67||_0x4ccd67['isCollapsed']||!_0x29e794['newRange']||_0x4ccd67['isEqual'](_0x29e794['newRange']))?_0x2ae4fb['model']['hasContent'](_0x4ccd67)&&!_0x5e6d2e?this['isThreadsLoadingPaused']?_0x4f852a['add'](_0x767c53):this['_handleThreadMarker'](_0x767c53,_0xa5785e):(_0x1f8b12['add'](_0x767c53),_0x4f852a['delete'](_0x767c53),_0x25ab17['removeMarker'](_0x767c53),_0x1ae12d=!0x0):(_0x25ab17['updateMarker'](_0x767c53,{'range':_0x4ccd67}),_0x1ae12d=!0x0);}return _0x1ae12d;}),this['on']('change:isThreadsLoadingPaused',(_0x5d9d64,_0x8f8849,_0x488ac5)=>{if(!_0x488ac5&&_0x4f852a['size'])for(const _0x345664 of _0x4f852a){const {id:_0x5b4278}=he(_0x345664);_0x4f852a['delete'](_0x345664),_0x2ae4fb['model']['markers']['get'](_0x345664)&&this['_handleThreadMarker'](_0x345664,_0x5b4278);}}),this['listenTo'](_0x2ae4fb['model']['document'],'change',(_0x518bdb,_0x21741a)=>{for(const {name:_0x1f8bda,data:{newRange:_0x2b68de}}of _0x2ae4fb['model']['document']['differ']['getChangedMarkers']()){const {group:_0x3a2c94,id:_0x37d1b1}=he(_0x1f8bda);if('comment'!==_0x3a2c94)continue;const _0x14b569=_0x5d1f5c['getCommentThread'](_0x37d1b1),_0x31c5eb=this['hasMarkerForId'](_0x37d1b1);_0x14b569&&(!_0x14b569['_hasTargetInContent']&&_0x2b68de&&_0x2ae4fb['editing']['view']['once']('render',()=>{const _0x596e30=_0x2ae4fb['plugins']['get'](N),_0x4ede58=_0x5d1f5c['_threadToController']['get'](_0x14b569)['view'];_0x596e30['getByInnerView'](_0x4ede58)['refreshVisibility']();},{'priority':'low'}),_0x14b569['_hasTargetInContent']=_0x31c5eb||!!_0x2b68de),_0x2b68de||(_0x1f8b12['add'](_0x1f8bda),_0x4f852a['delete'](_0x1f8bda));}if(_0x21741a['isLocal'])for(const _0x4ad88c of _0x1f8b12){const {id:_0x7c9d2b}=he(_0x4ad88c),_0x327c03=_0x5d1f5c['getCommentThread'](_0x7c9d2b),_0x1938a9=this['hasMarkerForId'](_0x7c9d2b);_0x4f852a['delete'](_0x4ad88c),!_0x327c03||_0x1938a9||_0x327c03['unlinkedAt']||_0x327c03['setUnlinkedAt'](new Date());}_0x1f8b12['clear']();});}['_getTargetForId'](_0xb02909){const _0x392021=this['editor'],_0x2353dc=this['getAllMarkersForId'](_0xb02909);return et(_0x392021['editing'],_0x2353dc);}['_getTextContext'](_0x365005){const _0x3922b9=this['getAllMarkersForId'](_0x365005);let _0x5b66b7='',_0xf7fbb=!0x1;for(const _0x7c5b85 of _0x3922b9){const _0x168416=_0x7c5b85['getRange']();for(const _0xab953c of Array['from'](_0x168416['getItems']()))_0xab953c['is']('$textProxy')?(_0x5b66b7&&_0xf7fbb&&(_0x5b66b7+='\x20',_0xf7fbb=!0x1),_0x5b66b7+=_0xab953c['data']):_0xf7fbb=!0x0;_0xf7fbb=!0x0;}return _0x5b66b7['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x3f60cb,_0x41d9a1){const _0x4e96be=this['editor'],_0x499484=_0x4e96be['plugins']['get'](o);let _0x388fcc=_0x499484['getCommentThread'](_0x41d9a1);const _0xeb3e7d=_0x4e96be['config']['get']('collaboration.channelId'),_0x542c7f=_0x4e96be['plugins']['get'](P);if(_0x388fcc&&(_0x388fcc['unlinkedAt']&&_0x388fcc['setUnlinkedAt'](null),_0x388fcc['isAttached']))return _0x388fcc;return!this['getAllMarkersForId'](_0x41d9a1)[0x0]['managedUsingOperations']?_0x4e96be['editing']['view']['once']('render',()=>{if(_0x499484['getCommentThread'](_0x41d9a1))return;const _0xe4e087=_0x4e96be['plugins']['get'](N);_0x388fcc=_0x499484['openNewCommentThread']({'channelId':_0xeb3e7d,'threadId':_0x41d9a1,'target':()=>this['_getTargetForId'](_0x41d9a1),'context':{'type':'text','value':this['_getTextContext'](_0x41d9a1)}});const _0x1cc2fa=_0x499484['_threadToController']['get'](_0x388fcc)['view'],_0x53316a=_0xe4e087['getByInnerView'](_0x1cc2fa);_0x53316a&&_0x542c7f['registerAnnotation'](_0x53316a);},{'priority':'low'}):_0x499484['fetchCommentThread']({'channelId':_0xeb3e7d,'threadId':_0x41d9a1})['then'](_0x3997ac=>{if('destroyed'!==_0x4e96be['state']){if(_0x388fcc=_0x3997ac,_0x388fcc&&!_0x388fcc['isAttached']){const _0xb51890=_0x388fcc['attachTo'](()=>this['_getTargetForId'](_0x41d9a1));_0x542c7f['registerAnnotation'](_0xb51890),_0x388fcc['isResolved']&&this['_reconvertMarkers'](_0x41d9a1);}else{if(!_0x388fcc){const _0x5ac16b=this['getAllMarkersForId'](_0x41d9a1);_0x4e96be['model']['change'](_0x5795a1=>{for(const _0x586c2b of _0x5ac16b)_0x5795a1['removeMarker'](_0x586c2b);});}}}}),_0x388fcc;}['_handleThreadMarker'](_0x1fa655,_0x2c9fce){const _0x26cd5c=this['_attachMarkerToThread'](_0x1fa655,_0x2c9fce);_0x26cd5c&&!_0x26cd5c['context']&&_0x26cd5c['setContext']({'type':'text','value':this['_getTextContext'](_0x2c9fce)});}['_initAriaMarkerChangeAnnouncements'](){const _0x36661f=this['editor'];ot(_0x36661f['model'],({left:_0x1b3be6,entered:_0x1187ee})=>{for(const _0x5236fe of _0x1b3be6)if(dt(_0x5236fe)){_0x36661f['ui']['ariaLiveAnnouncer']['announce'](S(_0x36661f['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x45ac5e of _0x1187ee)if(dt(_0x45ac5e)){_0x36661f['ui']['ariaLiveAnnouncer']['announce'](S(_0x36661f['locale'],'ENTER_COMMENT_ANNOUNCEMENT',nt(_0x36a9ce)));break;}});}}function ut(_0x237d8c,_0x4b7661){return _0x4b7661?_0x237d8c+':'+_0x4b7661:_0x237d8c;}function he(_0x23a8bc){const _0x33e100=_0x23a8bc['split'](':');return{'group':_0x33e100[0x0],'id':_0x33e100[0x1],'part':_0x33e100[0x2]};}function ft(_0xc14c3a,_0x246115){const _0x32ee50=_0x246115['schema'],_0x20e64f=_0x246115['createRange'](_0xc14c3a['start']);for(const _0x2b0faa of _0xc14c3a['getWalker']()){const {type:_0x9257fa,item:_0x46445b,nextPosition:_0x523da3}=_0x2b0faa;if('text'===_0x9257fa||_0x32ee50['isObject'](_0x46445b)){const _0x2407e6=_0x246115['createPositionBefore'](_0x46445b);_0x20e64f['isCollapsed']&&(_0x20e64f['start']=_0x2407e6),_0x20e64f['end']=_0x523da3;}}return _0x20e64f;}function dt(_0x392b15){return'comment'===he(_0x392b15['name'])['group'];}var xt='<!--\x0a\x0a\x20What\x20you\x27re\x20currently\x20looking\x20at\x20is\x20the\x20source\x20code\x20of\x20a\x20legally\x20protected,\x20proprietary\x20software.\x0a\x20CKEditor\x205\x20Collaboration\x20is\x20licensed\x20under\x20a\x20commercial\x20license\x20and\x20protected\x20by\x20copyright\x20law.\x20Where\x20not\x20otherwise\x20indicated,\x0a\x20all\x20CKEditor\x205\x20Collaboration\x20content\x20is\x20authored\x20by\x20CKSource\x20engineers\x20and\x20consists\x20of\x20CKSource-owned\x20intellectual\x20property.\x0a\x0a\x20Copyright\x20(c)\x202003-2024,\x20CKSource\x20Holding\x20sp.\x20z\x20o.o.\x20All\x20rights\x20reserved.\x0a\x0a!-->\x0a\x0a<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M4\x201.5h12A3.5\x203.5\x200\x200\x201\x2019.5\x205v8l-.005.192a3.5\x203.5\x200\x200\x201-2.927\x203.262l-.062.008v1.813a1.5\x201.5\x200\x200\x201-2.193\x201.33l-.371-.193-.38-.212a13.452\x2013.452\x200\x200\x201-3.271-2.63l-.062-.07H4A3.5\x203.5\x200\x200\x201\x20.5\x2013V5A3.5\x203.5\x200\x200\x201\x204\x201.5ZM4\x203a2\x202\x200\x200\x200-2\x202v8a2\x202\x200\x200\x200\x202\x202h6.924a11.917\x2011.917\x200\x200\x200\x203.71\x203.081l.372.194v-3.268L14.962\x2015H16a2\x202\x200\x200\x200\x202-2V5a2\x202\x200\x200\x200-2-2H4Z\x22/><path\x20d=\x22M9.75\x205a.75.75\x200\x200\x200-.75.75v2.5H6.5a.75.75\x200\x200\x200\x200\x201.5H9v2.5a.75.75\x200\x200\x200\x201.5\x200v-2.5H13a.75.75\x200\x200\x200\x200-1.5h-2.5v-2.5A.75.75\x200\x200\x200\x209.75\x205Z\x22/></svg>\x0a';class i extends _0x5a85ea{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,r,P,N];}get['CommentsListView'](){return te;}get['CommentThreadInputView'](){return ie;}['init'](){const _0x189476=this['editor'],_0x39c201=_0x189476['plugins']['get'](o),_0x31be0b=_0x189476['plugins']['get'](r),_0x2c8fcb=_0x189476['plugins']['get'](N),_0x265ff7=_0x189476['plugins']['get'](P);_0x189476['ui']['componentFactory']['add']('comment',()=>{const _0x2cd8e3=this['_createUIButton'](_0x57b97b);return _0x2cd8e3['tooltip']=!0x0,_0x2cd8e3;}),_0x189476['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x9c1b58)),_0x265ff7['addSourceCollector'](()=>{const _0x542e92=[];for(const [_0x47dc5b,_0x5cd5d2]of _0x39c201['_threadToController']){const _0x39c81f=_0x31be0b['getAllMarkersForId'](_0x47dc5b['id']),_0x2d2980=_0x39c81f['map'](_0x229ac1=>_0x229ac1['getRange']());_0x39c81f['length']>0x0&&_0x542e92['push']([_0x5cd5d2['view'],_0x2d2980]);}return _0x542e92;}),this['listenTo'](_0x2c8fcb,'change:activeAnnotations',(_0x2eb083,_0x18497d,_0xe0a22c)=>{const _0x439100=Array['from'](_0xe0a22c)['map'](_0x340fd1=>_0x340fd1['innerView'])['find'](_0x116c00=>_0x39c201['_viewToController']['has'](_0x116c00));if(!_0x439100)return void(_0x31be0b['activeMarker']=null);const _0x2ec894=_0x39c201['_viewToController']['get'](_0x439100)['model']['id'],_0x346f2c='comment:'+_0x2ec894;_0x2ec894&&_0x31be0b['hasMarkerForId'](_0x2ec894)?_0x31be0b['activeMarker']=_0x346f2c:_0x31be0b['activeMarker']&&(_0x31be0b['activeMarker']=null);}),this['listenTo'](_0x39c201,'removeCommentThread',(_0x105283,{threadId:_0x29e047,isFromAdapter:_0x203a27})=>{!_0x203a27&&_0x189476['ui']['focusTracker']['isFocused']&&_0x31be0b['hasMarkerForId'](_0x29e047)&&_0x189476['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x39c201,'addComment',(_0x3032f2,{threadId:_0x1f2fd1,isFromAdapter:_0x6cd9ed})=>{if(_0x6cd9ed||!_0x31be0b['hasMarkerForId'](_0x1f2fd1)||!_0x39c201['hasCommentThread'](_0x1f2fd1))return;0x1===_0x39c201['getCommentThread'](_0x1f2fd1)['length']&&(_0x189476['editing']['view']['focus'](),_0x3032f2['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x58eb4a=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x3bf537;for(const _0xf19dce in _0x58eb4a){const _0x4cd925=_0xf19dce,_0x446456=_0x58eb4a[_0x4cd925];if('commentsLicenseKeyValid'==_0x446456||'commentsLicenseKeyInvalid'==_0x446456||'commentsLicenseKeyExpired'==_0x446456||'commentsLicenseKeyDomainLimit'==_0x446456||'commentsLicenseKeyNotAllowed'==_0x446456||'commentsLicenseKeyEvaluationLimit'==_0x446456||'commentsLicenseKeyTrialLimit'==_0x446456||'commentsLicenseKeyDevelopmentLimit'==_0x446456||'commentsLicenseKeyUsageLimit'==_0x446456){delete _0x58eb4a[_0x4cd925],_0x3bf537=_0x446456,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x3bf537&&_0x58eb4a['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x3bf537&&_0x58eb4a['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x3bf537&&_0x58eb4a['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x3bf537&&_0x58eb4a['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x3bf537&&_0x58eb4a['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x3bf537&&_0x58eb4a['_showLicenseError']('trialLimit'),'commentsLicenseKeyDevelopmentLimit'==_0x3bf537&&_0x58eb4a['_showLicenseError']('developmentLimit'),'commentsLicenseKeyUsageLimit'==_0x3bf537&&_0x58eb4a['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0xe2f1d0){const _0x469c82=this['editor'],_0x2985f1=new _0xe2f1d0(_0x469c82['locale']),_0x28ffe6=_0x469c82['commands']['get']('addCommentThread');return _0x2985f1['set']({'label':S(_0x469c82['locale'],'Comment'),'icon':xt}),_0x2985f1['bind']('isEnabled')['to'](_0x28ffe6),this['listenTo'](_0x2985f1,'execute',()=>_0x28ffe6['execute']()),_0x2985f1;}}class s extends _0x5a85ea{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x329306){super(_0x329306),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x1c4452,_0x32e890,_0x541f97)=>{_0x541f97?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x5c47de,_0x133d50]of this['editor']['commands'])_0x133d50['affectsData']&&'addCommentThread'!==_0x5c47de&&_0x133d50['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode');const _0x45b9cc=this['editor']['editing']['view']['document'];this['listenTo'](_0x45b9cc,'cut',_0x5dce89=>_0x5dce89['stop'](),{'priority':'highest'}),this['listenTo'](_0x45b9cc,'clipboardInput',_0x5bed11=>_0x5bed11['stop'](),{'priority':'highest'}),this['listenTo'](_0x45b9cc,'delete',_0x1e54fa=>_0x1e54fa['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x5634f7,_0x5535dc]of this['editor']['commands'])_0x5535dc['affectsData']&&'addCommentThread'!==_0x5634f7&&_0x5535dc['clearForceDisabled']('commentsOnlyMode');this['stopListening'](this['editor']['editing']['view']['document']);}}class M extends _0x529673{['activeUIs'];['_uis'];['_uisData'];static get['requires'](){return[N];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5b136b){super(_0x5b136b),this['activeUIs']=new Set(),this['_uis']=new Map(),this['_uisData']=new Map();}['init'](){const _0x4a63f2=this['context']['plugins']['get'](N);this['listenTo'](_0x4a63f2,'_activateAnnotation',(_0x418292,_0x338e82)=>{for(const _0x25a990 of this['activeUIs']){const _0x422aec=this['_uis']['get'](_0x25a990);(0x0,this['_uisData']['get'](_0x25a990)['filter'])(_0x338e82)&&_0x422aec['setActiveAnnotation'](_0x338e82);}}),this['listenTo'](_0x4a63f2,'_deactivateAllAnnotations',()=>{for(const _0x40a48a of this['activeUIs']){this['_uis']['get'](_0x40a48a)['setActiveAnnotation'](null);}}),this['listenTo'](_0x4a63f2['_visibleAnnotations'],'add',(_0x3c73ce,_0x40009f)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x40009f);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x5de610){return this['activeUIs']['has'](_0x5de610);}['activate'](_0x53d8c4,_0x1498c0=()=>!0x0){const _0x1aa840=this['context']['plugins']['get'](N);if(!this['_uis']['has'](_0x53d8c4))throw new _0x59ce32('annotationsuis-missing-ui',this,{'uiName':_0x53d8c4});this['isActive'](_0x53d8c4)&&this['deactivate'](_0x53d8c4),this['activeUIs']['add'](_0x53d8c4);const _0x1ad298=new x();!function({source:_0x316ce1,target:_0x3d414a,filter:_0x361662}){for(const _0x25f485 of _0x316ce1)_0x361662(_0x25f485)&&_0x3d414a['add'](_0x25f485);_0x3d414a['listenTo'](_0x316ce1,'add',(_0x2d16c4,_0x1c038e)=>{_0x361662(_0x1c038e)&&_0x3d414a['add'](_0x1c038e);}),_0x3d414a['listenTo'](_0x316ce1,'remove',(_0x3b98ee,_0x379f34)=>{_0x3d414a['has'](_0x379f34)&&_0x3d414a['remove'](_0x379f34);});}({'source':_0x1aa840['_visibleAnnotations'],'target':_0x1ad298,'filter':_0x1498c0}),this['_uisData']['set'](_0x53d8c4,{'collection':_0x1ad298,'filter':_0x1498c0});const _0x5d5430=this['_uis']['get'](_0x53d8c4);_0x5d5430['attach'](_0x1ad298),this['listenTo'](_0x5d5430,'change:activeAnnotation',(_0x5f4fc7,_0x532f9a,_0xd93e92,_0x3f17f9)=>{_0x3f17f9&&_0x1aa840['_removeActiveAnnotation'](_0x3f17f9),_0xd93e92&&_0x1aa840['_addActiveAnnotation'](_0xd93e92);});}['deactivate'](_0x2c90b1){if(this['activeUIs']['delete'](_0x2c90b1),!this['_uis']['has'](_0x2c90b1))throw new _0x59ce32('annotationsuis-missing-ui',this,{'uiName':_0x2c90b1});const _0x11783f=this['_uis']['get'](_0x2c90b1);_0x11783f['detach'](),this['stopListening'](_0x11783f),this['_uisData']['get'](_0x2c90b1)['collection']['destroy'](),this['_uisData']['delete'](_0x2c90b1);}['switchTo'](_0xbbd887){if(!this['_uis']['has'](_0xbbd887))throw new _0x59ce32('annotationsuis-missing-ui',this,{'uiName':_0xbbd887});const _0x4a53fc=this['context']['plugins']['get'](N),_0x2832e2=Array['from'](_0x4a53fc['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0xbbd887);const _0x3faf80=this['_uis']['get'](_0xbbd887);_0x3faf80['setActiveAnnotation'](_0x2832e2),_0x3faf80['_setSelectedAnnotations']&&_0x2832e2&&_0x3faf80['_setSelectedAnnotations']([_0x2832e2]);}['deactivateAll'](){for(const _0x2742ca of this['activeUIs'])this['deactivate'](_0x2742ca);}['register'](_0x2c4597,_0x5904fd){if(this['_uis']['has'](_0x2c4597))throw new _0x59ce32('annotationsuis-register-already-registered');if('function'!=typeof _0x5904fd['attach']||'function'!=typeof _0x5904fd['detach']||'function'!=typeof _0x5904fd['setActiveAnnotation'])throw new _0x59ce32('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x2c4597,_0x5904fd);}['refilterAnnotations'](){const _0x5baf65=this['context']['plugins']['get'](N)['collection'],_0x283308=new Map(),_0x39a424=Array['from'](this['activeUIs']);for(const _0x5b8884 of this['activeUIs']){const _0x1764dd=this['_uisData']['get'](_0x5b8884)['collection'];for(const _0x5dae72 of _0x1764dd)_0x283308['set'](_0x5dae72,_0x5b8884);}for(const _0x33dacc of _0x5baf65){const _0x53df2f=_0x283308['get'](_0x33dacc);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x33dacc);const _0x1e757a=_0x39a424['find'](_0x1c8af3=>this['_uisData']['get'](_0x1c8af3)['filter'](_0x33dacc));_0x53df2f!==_0x1e757a&&(_0x53df2f&&this['_uisData']['get'](_0x53df2f)['collection']['remove'](_0x33dacc),_0x1e757a&&this['_uisData']['get'](_0x1e757a)['collection']['add'](_0x33dacc));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x57631e){const _0x441b55=[];for(const _0x22418d of this['activeUIs']){(0x0,this['_uisData']['get'](_0x22418d)['filter'])(_0x57631e)&&_0x441b55['push'](_0x22418d);}if(_0x441b55['length']>0x1)throw new _0x59ce32('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x441b55,'annotationType':_0x57631e['type']});}}const ae=Ht('px');class V extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x1383cf){super(_0x1383cf);const _0x4ca4a6=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 _0x424f41(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x4ca4a6['to']('class')],'style':{'minHeight':_0x4ca4a6['to']('minHeight',_0x58c0ce=>'number'==typeof _0x58c0ce?ae(_0x58c0ce+0xa):null)},'dir':_0x1383cf['uiLanguageDirection'],'role':'application','aria-label':S(_0x1383cf,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':S(_0x1383cf,'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',_0x524f96=>{this['_updateItemPositionInFocusables'](_0x524f96['source']);}),this['list']['forEach'](_0x26f60d=>{this['focusTracker']['add'](_0x26f60d['element']),this['_updateItemPositionInFocusables'](_0x26f60d);}),this['list']['on']('change',(_0x35a92e,_0x22ef9d)=>{for(const _0x244169 of _0x22ef9d['removed'])this['focusTracker']['remove'](_0x244169['element']),this['focusables']['remove'](_0x244169);for(const _0x3873b1 of _0x22ef9d['added'])this['focusTracker']['add'](_0x3873b1['element']),this['_updateItemPositionInFocusables'](_0x3873b1);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x244ebf){const _0x1e5ee8=this['focusables']['getIndex'](_0x244ebf);let _0x141a2f,_0x7e16a6;for(const _0x1408c6 of this['focusables'])if(_0x244ebf['top']<_0x1408c6['top']){_0x141a2f=_0x1408c6;break;}if(_0x7e16a6=_0x141a2f?this['focusables']['getIndex'](_0x141a2f):this['focusables']['length'],-0x1!==_0x1e5ee8){if(_0x1e5ee8===_0x7e16a6-0x1)return;this['focusables']['remove'](_0x244ebf),_0x7e16a6=_0x141a2f?this['focusables']['getIndex'](_0x141a2f):this['focusables']['length'];}this['focusables']['add'](_0x244ebf,_0x7e16a6);}}const qt=Ht('px');class H extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x18c515){super(_0x18c515),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0xe686d4,_0x456ed9)=>_0xe686d4+_0x456ed9),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Dt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x57ce68=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x57ce68['to']('isAnimationDisabled',_0x428ae0=>_0x428ae0?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x57ce68['to']('top',_0x592ee7=>qt(_0x592ee7))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x5d0066=this['element']['clientHeight'];_0x5d0066&&(this['height']=_0x5d0066);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x529673{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1f62e5){super(_0x1f62e5),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 _0x557380=this['context']['config']['get']('sidebar.container');_0x557380&&this['setContainer'](_0x557380);}['setContainer'](_0x3ab333){if(!y(_0x3ab333))throw new _0x59ce32('sidebar-setcontainer-invalid-element');this['container']=_0x3ab333;}['_attachToContainer']({viewClass:_0x3bfa22='',spaceBetweenItems:_0x1ef4dc=0x19}={}){if(!y(this['container']))throw new _0x59ce32('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x3bfa22,this['_spaceBetweenItems']=_0x1ef4dc;}['rearrange']({removedAnnotation:_0x3480c6,previousAnnotation:_0x260b73,nextAnnotation:_0x8d82a0}){const _0x1a61b0=this['getSidebarItemView'](_0x3480c6);this['view']['list']['remove'](_0x1a61b0),this['_destroySidebarItemView'](_0x3480c6),_0x260b73&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x260b73)),_0x8d82a0&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x8d82a0)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x18e8ec,activatedAnnotation:_0x148b3a,disableAnimationOnActivatedAnnotation:_0x4cabda}){if(this['_activeAnnotation']=_0x148b3a,_0x18e8ec){_0x18e8ec['isActive']=!0x1;const _0x426b09=this['getSidebarItemView'](_0x18e8ec);_0x426b09&&_0x4cabda&&(_0x426b09['isAnimationDisabled']=!0x1);}if(_0x148b3a){const _0xc03924=this['getSidebarItemView'](_0x148b3a);_0xc03924&&(_0x148b3a['isActive']=!0x0,_0x4cabda&&(_0xc03924['isAnimationDisabled']=!0x0,_0xc03924['top']+=0x1),this['_alignToTargetRect'](_0xc03924));}}['_detachFromContainer'](_0x1bbb60){if(this['view']['element']['remove'](),_0x1bbb60){for(const _0x3b8672 of _0x1bbb60)this['_destroySidebarItemView'](_0x3b8672);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x3c3338,_0x1ea22f){_0x1ea22f||(_0x1ea22f=_0x3c3338['view']);const _0x42fe7c=new H(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x42fe7c,_0x3c3338),this['_annotationToSidebarItemView']['set'](_0x3c3338,_0x42fe7c),_0x42fe7c['content']['add'](_0x1ea22f),this['listenTo'](_0x3c3338['view'],'change:targetRect',(_0x269294,_0x1ce9b6,_0x527684)=>{const _0x399166=this['_getTargetTop'](_0x3c3338,_0x527684);_0x42fe7c['_targetTop']!=_0x399166&&(_0x42fe7c['_targetTop']=_0x399166,this['_setItemTop'](_0x42fe7c,_0x399166));}),this['listenTo'](_0x42fe7c,'change:top',()=>{this['_recalculate'](_0x42fe7c,'top');}),this['listenTo'](_0x42fe7c,'change:bottom',()=>{this['_recalculate'](_0x42fe7c,'bottom');}),this['_alignToTargetRect'](_0x42fe7c);const _0x5a0f16=this['_getItemBefore'](_0x42fe7c);if(_0x5a0f16)this['_alignAfterItem'](_0x5a0f16,_0x42fe7c)||this['_alignToTargetRect'](_0x42fe7c);else this['_alignToTargetRect'](_0x42fe7c);return this['_updateLastItem'](),this['view']['list']['add'](_0x42fe7c),_0x42fe7c;}['_alignForTopChange'](_0x4dec00){if(!_0x4dec00['content']['length'])return;const _0x3b2781=this['_getItemBefore'](_0x4dec00);if(!_0x3b2781)return;const _0x55d19b=this['_sidebarItemViewToAnnotation']['get'](_0x3b2781),_0x4a8472=this['_activeAnnotation'];_0x4a8472&&_0x4a8472===_0x55d19b?this['_alignAfterItem'](_0x3b2781,_0x4dec00):this['_alignBeforeItem'](_0x4dec00,_0x3b2781);}['_alignForBottomChange'](_0x3257ea){if(!_0x3257ea['content']['length'])return;const _0x23ab2a=this['_getItemAfter'](_0x3257ea);if(!_0x23ab2a)return;const _0x45ec3a=this['_sidebarItemViewToAnnotation']['get'](_0x23ab2a),_0x2a7561=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x17c8d0=this['_activeAnnotation'];_0x17c8d0&&_0x17c8d0===_0x45ec3a&&_0x2a7561?(this['_alignBeforeItem'](_0x23ab2a,_0x3257ea),this['_alignAfterItem'](_0x3257ea,_0x23ab2a)):_0x17c8d0&&_0x17c8d0===_0x45ec3a?this['_alignBeforeItem'](_0x23ab2a,_0x3257ea):this['_alignAfterItem'](_0x3257ea,_0x23ab2a);}['_recalculate'](_0x148640,_0x12c5de){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0xae416a,changedProp:_0xb7bf61}of this['_recalculateBuffer'])'top'===_0xb7bf61?this['_alignForTopChange'](_0xae416a):this['_alignForBottomChange'](_0xae416a);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x148640,'changedProp':_0x12c5de});}['getSidebarItemView'](_0xf9fefa){return this['_annotationToSidebarItemView']['get'](_0xf9fefa);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x4c966e){const _0x4422aa=this['getSidebarItemView'](_0x4c966e);this['stopListening'](_0x4422aa),this['stopListening'](_0x4c966e['view']),_0x4422aa['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x4c966e),this['_sidebarItemViewToAnnotation']['delete'](_0x4422aa);}['_createSidebarView'](){const _0x26c2b9=new V(this['context']['locale']);return _0x26c2b9['render'](),this['on']('change:_lastItem',(_0x451bbd,_0x447963,_0x19f4de,_0x17b25a)=>{_0x17b25a&&_0x26c2b9['unbind']('minHeight'),_0x19f4de?_0x26c2b9['bind']('minHeight')['to'](_0x19f4de,'bottom'):_0x26c2b9['minHeight']=null;}),_0x26c2b9;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x3eb56e){const _0xfd051e=this['_sidebarItemViewToAnnotation']['get'](_0x3eb56e),_0x42d005=_0xfd051e&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0xfd051e)-0x1);return _0x42d005&&this['getSidebarItemView'](_0x42d005)||null;}['_getItemAfter'](_0x2b123b){const _0x9c2d92=this['_sidebarItemViewToAnnotation']['get'](_0x2b123b),_0x20d4c8=_0x9c2d92&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x9c2d92)+0x1);return _0x20d4c8&&this['getSidebarItemView'](_0x20d4c8)||null;}['_alignBeforeItem'](_0x27540b,_0x49d44f){_0x27540b['updateHeight']();const _0x33dbd6=R(_0x49d44f['bottom']+this['_spaceBetweenItems'],_0x27540b['top']);return!!_0x33dbd6&&(this['_setItemTop'](_0x49d44f,_0x49d44f['top']-_0x33dbd6),!0x0);}['_alignAfterItem'](_0x4a9500,_0x19073a){_0x4a9500['updateHeight']();const _0x3d8770=R(_0x4a9500['bottom']+this['_spaceBetweenItems'],_0x19073a['top']);return!!_0x3d8770&&(this['_setItemTop'](_0x19073a,_0x19073a['top']+_0x3d8770,!0x1),!0x0);}['_alignToTargetRect'](_0x4eddb9){const _0x53c8b5=this['_sidebarItemViewToAnnotation']['get'](_0x4eddb9);if(!_0x53c8b5||!_0x53c8b5['target']||!_0x53c8b5['targetRect'])return;const _0x1a640d=this['_getTargetTop'](_0x53c8b5,_0x53c8b5['targetRect']);this['_setItemTop'](_0x4eddb9,_0x1a640d);}['_getTargetTop'](_0x1bd6f2,_0x25c79f){if(null===_0x25c79f)return 0x0;if(_0x1bd6f2['target']instanceof _0x44fba6)return _0x25c79f['top'];{const _0x352493=new _0x44fba6(this['view']['element'])['top'];return _0x25c79f['top']-_0x352493;}}['_setItemTop'](_0x452f0d,_0x14cc95,_0x3a0c48=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x3a0c48&&(_0x14cc95=Math['max'](_0x14cc95,this['_getMaxAvailableTop'](_0x452f0d))),_0x452f0d['top']=_0x14cc95;}['_getMaxAvailableTop'](_0xbb10be){let _0x5a550c=this['_getItemBefore'](_0xbb10be),_0x59ad26=0x0;for(;_0x5a550c;)_0x5a550c['updateHeight'](),_0x59ad26+=this['_spaceBetweenItems']+_0x5a550c['height'],_0x5a550c=this['_getItemBefore'](_0x5a550c);return _0x59ad26;}}function R(_0x8b3216,_0x3cf6eb){return Math['max'](_0x8b3216-_0x3cf6eb,0x0);}function y(_0x2060b5){return null!==_0x2060b5&&'object'==typeof _0x2060b5&&0x1===_0x2060b5['nodeType'];}class e extends _0x529673{['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(_0x206b51){super(_0x206b51),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x4fd75f(),this['_refreshPositioningDebounced']=_0x58a7c2(()=>{this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x5b9cd3=this['context']['plugins']['get'](M),_0x2a0f5e=this['context']['plugins']['get'](z);_0x5b9cd3['register']('wideSidebar',this),_0x2a0f5e['container']&&_0x5b9cd3['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x3708b7){if(_0x3708b7===this['activeAnnotation'])return;const _0x492bd8=this['context']['plugins']['get'](z);_0x492bd8['_activeAnnotation']=_0x3708b7;const _0x73236a=this['activeAnnotation'];this['activeAnnotation']=_0x3708b7,_0x492bd8['refresh']({'blurredAnnotation':_0x73236a,'activatedAnnotation':this['activeAnnotation']});}['attach'](_0x16b57b){this['annotations']=_0x16b57b;const _0x3dbdc6=this['context']['plugins']['get'](z);if(_0x3dbdc6['_annotations']=_0x16b57b,this['isAttached'])throw new _0x59ce32('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x3dbdc6,'set:container',()=>{this['detach'](),this['listenTo'](_0x3dbdc6,'change:container',_0x5076c4=>{_0x5076c4['off'](),this['attach'](_0x16b57b);});}),_0x3dbdc6['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x27a529=_0x24eebf=>{_0x24eebf['updateTargetRect'](),_0x3dbdc6['addAnnotation'](_0x24eebf);};for(const _0x9ab2f3 of _0x16b57b)_0x27a529(_0x9ab2f3);this['listenTo'](_0x16b57b,'add',(_0x32f080,_0x536094)=>{_0x27a529(_0x536094);}),this['listenTo'](_0x16b57b,'remove',(_0x21f34a,_0x545227,_0x44cb27)=>{_0x3dbdc6['rearrange']({'removedAnnotation':_0x545227,'previousAnnotation':_0x16b57b['get'](_0x44cb27-0x1),'nextAnnotation':_0x16b57b['get'](_0x44cb27+0x1)}),_0x545227===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x16b57b,'focus',(_0x392b5d,_0x277e95)=>{this['setActiveAnnotation'](_0x277e95);}),this['listenTo'](_0x16b57b,'blur',()=>{this['setActiveAnnotation'](null);});const _0xa6072c=this['context']instanceof _0x15790e?this['context']['editors']:new _0x4fd75f([this['context']]);for(const _0x7e754b of _0xa6072c)this['_integrateWithEditorAnnotations'](_0x7e754b);this['listenTo'](_0xa6072c,'add',(_0x1a67c4,_0xb298e3)=>{this['listenTo'](_0xb298e3,'ready',()=>{this['_integrateWithEditorAnnotations'](_0xb298e3);});}),this['listenTo'](_0xa6072c,'remove',(_0x95e573,_0x18deff)=>{_0x18deff['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x18deff['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x59ce32('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0xf2c42c=this['context']['plugins']['get'](z);_0xf2c42c['_detachFromContainer'](this['annotations']),this['stopListening'](_0xf2c42c),this['stopListening'](this['annotations']),this['context']instanceof _0x15790e&&this['stopListening'](this['context']['editors']);for(const _0x106c6e of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x106c6e);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0xb9bacd){if(!_0xb9bacd['plugins']['has']('EditorAnnotations'))return;const _0xcada75=_0xb9bacd['plugins']['get']('EditorAnnotations'),_0x4747f8=()=>{const _0x1d1db4=_0xcada75['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x1d1db4[0x0]||null);};this['listenTo'](_0xcada75,'refresh',_0x4747f8),this['listenTo'](_0xcada75,'blur',(_0x22027c,{isAnnotationTracked:_0x470b14})=>{this['activeAnnotation']&&_0x470b14(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0xcada75,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x16fc35=>{_0xcada75['hasDomSelection']()&&(_0x4747f8(),_0x16fc35['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0xcada75);}['_destroyEditorAnnotationsIntegration'](_0x225d9c){this['stopListening'](_0x225d9c),this['_editorAnnotations']['remove'](_0x225d9c);}}class D extends _0x57b97b{['counterView'];constructor(_0x559d3c){super(_0x559d3c);const _0x4c03f2=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x45b912,_0x3a8dab)=>_0x45b912?'...':_0x3a8dab['toString']()),this['set']('annotationType',''),this['icon']=xt,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x4c03f2['to']('annotationType',_0x36a91f=>'ck-annotation-counter__badge--'+_0x36a91f),_0x4c03f2['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x4c03f2['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x529673{['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(_0x14b629){super(_0x14b629),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=Object['create'](_0x3e18d9),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x4fd75f(),this['_refreshPositioningDebounced']=_0x58a7c2(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](M)['register']('narrowSidebar',this),this['bodyCollection']=new _0x558ff7(this['context']['locale']),this['balloonPanelView']=new _0xf453e3(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0xb1f697){this['annotations']=_0xb1f697;const _0x43b1bf=this['context']['plugins']['get'](z),_0x277a8b=this['balloonPanelView'];if(_0x43b1bf['_annotations']=_0xb1f697,this['isAttached'])throw new _0x59ce32('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x43b1bf,'set:container',()=>{this['detach'](),this['listenTo'](_0x43b1bf,'change:container',_0x3eed66=>{_0x3eed66['off'](),this['attach'](_0xb1f697);});}),_0x43b1bf['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x1b0e32=_0x437a0d=>{const _0x28a947=new D(this['context']['locale']);_0x43b1bf['addAnnotation'](_0x437a0d,_0x28a947),this['_annotationToNarrowView']['set'](_0x437a0d,_0x28a947),_0x28a947['bind']('isDirty','annotationType','number')['to'](_0x437a0d['view'],'isDirty','type','length'),_0x28a947['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x277a8b['content']['first']!==_0x437a0d['view']?(this['_showBalloon'](_0x437a0d),_0x437a0d['view']['element']['focus'](),this['setActiveAnnotation'](_0x437a0d)):this['setActiveAnnotation'](null);});};for(const _0x2da08b of _0xb1f697)_0x1b0e32(_0x2da08b);this['listenTo'](_0xb1f697,'add',(_0x45fa35,_0x2926b8)=>{_0x1b0e32(_0x2926b8);}),this['listenTo'](_0xb1f697,'remove',(_0x2dbb9b,_0x1430be,_0xe33b0f)=>{this['_annotationToNarrowView']['get'](_0x1430be)['destroy'](),this['_annotationToNarrowView']['delete'](_0x1430be),_0x43b1bf['rearrange']({'removedAnnotation':_0x1430be,'previousAnnotation':_0xb1f697['get'](_0xe33b0f-0x1),'nextAnnotation':_0xb1f697['get'](_0xe33b0f+0x1)}),_0x1430be===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0xb1f697,'focus',(_0x353d8e,_0x22e978)=>{this['setActiveAnnotation'](_0x22e978);}),this['listenTo'](_0xb1f697,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0xfec27a,_0x260a11)=>{_0x260a11['keyCode']===_0x5ad4b8['esc']&&_0x277a8b['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x277a8b['content']['first']),this['_hideBalloon'](),_0x260a11['stopPropagation'](),_0x260a11['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x48e979,_0xe23c75)=>{const _0xc6fbdf=_0xe23c75['target'];_0x277a8b['isVisible']&&_0x277a8b['element']['contains'](_0xc6fbdf)||_0x43b1bf['view']['element']['contains'](_0xc6fbdf)||_0x48e979['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x433df4=>_0x433df4['contains'](_0xc6fbdf))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0xfaf337=this['context']instanceof _0x15790e?this['context']['editors']:new _0x4fd75f([this['context']]);for(const _0x19920a of _0xfaf337)this['_integrateWithEditorAnnotations'](_0x19920a);this['listenTo'](_0xfaf337,'add',(_0x210917,_0x29d2a3)=>{this['listenTo'](_0x29d2a3,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x29d2a3);});}),this['listenTo'](_0xfaf337,'remove',(_0x52dac6,_0xfd5af2)=>{_0xfd5af2['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0xfd5af2['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0xd55000){if(_0xd55000===this['activeAnnotation'])return;const _0x23fb07=this['context']['plugins']['get'](z);if(_0x23fb07['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0xd55000,'disableAnimationOnActivatedAnnotation':!0x0}),_0xd55000)_0x23fb07['getSidebarItemView'](_0xd55000)?this['_showBalloon'](_0xd55000):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0xd55000;}['detach'](){if(!this['isAttached'])throw new _0x59ce32('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x3435de=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x3bca82=>_0x3bca82['destroy']()),this['_annotationToNarrowView']['clear'](),_0x3435de['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x15790e&&this['stopListening'](this['context']['editors']);for(const _0x3f4501 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x3f4501);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'](_0x50b02d){if(!_0x50b02d['plugins']['has']('EditorAnnotations'))return;const _0x53691e=_0x50b02d['plugins']['get']('EditorAnnotations'),_0x411727=this['context']['plugins']['get'](z),_0x51800c=this['annotations'],_0x3574b4=this['balloonPanelView'],_0x1729fc=()=>{const _0x552e40=_0x53691e['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x552e40),this['setActiveAnnotation'](_0x552e40[0x0]||null);};this['listenTo'](_0x53691e,'refresh',_0x1729fc),this['listenTo'](_0x53691e,'blur',(_0x39bc73,{isAnnotationTracked:_0x11ba54})=>{this['activeAnnotation']&&_0x11ba54(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x53691e,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x51800c,'blur',_0x362311=>{_0x53691e['hasDomSelection']()&&_0x362311['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x4e5d11,_0x410503)=>{const _0x533201=_0x410503['target'];_0x3574b4['isVisible']&&_0x3574b4['element']['contains'](_0x533201)||_0x411727['view']['element']['contains'](_0x533201)||this['activeAnnotation']&&_0x53691e['hasDomSelection']()&&(_0x1729fc(),_0x4e5d11['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x53691e);}['_destroyEditorAnnotationsIntegration'](_0x1bb131){_0x1bb131&&(this['stopListening'](_0x1bb131),this['_editorAnnotations']['remove'](_0x1bb131));}['_setSelectedAnnotations'](_0x35c067){for(const _0x138ccd of this['_selectedAnnotations'])_0x35c067['includes'](_0x138ccd)||this['_manuallyClosedAnnotationViews']['delete'](_0x138ccd['view']);this['_selectedAnnotations']=_0x35c067;}['_refreshPositioning'](){const _0x57f124=this['balloonPanelView'];this['annotations']['refreshPositioning'](),_0x57f124['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x355f5f){if(this['_manuallyClosedAnnotationViews']['has'](_0x355f5f['view']))return;const _0x596372=this['balloonPanelView']['content']['first'];_0x596372!==_0x355f5f['view']?(_0x596372&&this['_detachListeners'](_0x596372),this['_attachListeners'](_0x355f5f['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x355f5f['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x56498c=this['balloonPanelView']['content']['first'],_0x3a7c16=_0x56498c&&this['annotations']['getByView'](_0x56498c);if(!_0x3a7c16||!this['_annotationToNarrowView']['has'](_0x3a7c16))return;const _0xca5337=this['_annotationToNarrowView']['get'](_0x3a7c16)['element'],_0x1096b9=(function(){const _0x5c73bd=_0xf453e3['defaultPositions'];return[_0x5c73bd['southArrowNorthEast'],_0x5c73bd['northArrowSouthEast'],_0x5c73bd['southArrowNorth'],_0x5c73bd['northArrowSouth'],_0x5c73bd['southArrowNorthWest'],_0x5c73bd['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0xca5337,'positions':_0x1096b9});}['_hideBalloon'](){const _0x1db0d1=this['balloonPanelView'],_0x5e8a17=_0x1db0d1['content']['first'];_0x5e8a17&&(this['_detachListeners'](_0x5e8a17),_0x1db0d1['unpin'](),_0x1db0d1['content']['clear']());}['_attachListeners'](_0x27a77b){this['listenTo'](_0x27a77b,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x27a77b,'Esc',(_0x50c83b,_0x484014)=>{this['_manuallyClosedAnnotationViews']['add'](_0x27a77b),this['_hideBalloon'](),_0x484014();});}['_detachListeners'](_0x2cba9f){this['stopListening'](_0x2cba9f);}}class c extends _0x5a85ea{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[P,_0x1a348e,M];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x381079){super(_0x381079),_0x381079['editing']['view']['addObserver'](_0x4bab8c),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x381079['plugins']['get'](_0x1a348e),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x481e05=this['editor']['plugins']['get'](M);_0x481e05['context']===this['editor']&&(_0x481e05['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x3539c4,_0x86df35)=>{const _0x7e144e=this['_balloon'];if(this['isAttached']&&_0x7e144e['visibleView']){const _0xb47f51=this['annotations']['getByView'](_0x7e144e['visibleView']);_0xb47f51&&this['_closeAnnotation'](_0xb47f51),_0x86df35();}}));}['afterInit'](){const _0xd673f=this['editor']['plugins']['get'](M);_0xd673f['context']===this['editor']&&(_0xd673f['hasActive']()||_0xd673f['switchTo']('inline'));}['setActiveAnnotation'](_0x281f25){_0x281f25!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x281f25&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x281f25)&&this['_addAnnotationToBalloon'](_0x281f25,!0x0),_0x281f25['isActive']=!0x0),_0x281f25||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x281f25);}['attach'](_0x3dabdd){this['annotations']=_0x3dabdd;const _0x486d0c=this['editor']['plugins']['get'](M),_0x6fc5ee=this['_balloon'];if(this['isAttached'])throw new _0x59ce32('inlineannotations-attach-already-attached',this);if(_0x486d0c['context']!==this['editor'])throw new _0x59ce32('inlineannotations-not-allowed-with-context',this);const _0x15d6c8=this['editor']['plugins']['get'](P);this['listenTo'](_0x15d6c8,'refresh',()=>{const _0x4a41f3=_0x15d6c8['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x1eec2b,_0x40f756;!this['_forceRefresh']&&(_0x1eec2b=_0x4a41f3,_0x40f756=this['_selectedAnnotations'],_0x1eec2b['length']===_0x40f756['length']&&_0x1eec2b['every'](_0x113065=>_0x40f756['includes'](_0x113065)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x4a41f3),this['setActiveAnnotation'](_0x4a41f3[0x0]||null));}),this['listenTo'](_0x15d6c8,'blur',(_0xcb1fec,{isAnnotationTracked:_0x9b4f07})=>{this['activeAnnotation']&&_0x9b4f07(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x3d602b,_0x19d261,_0x7126d4)=>{_0x7126d4||this['setActiveAnnotation'](null);}),this['listenTo'](_0x3dabdd,'remove',(_0x47b88f,_0x5be1c9)=>{this['_removeAnnotationFromBalloon'](_0x5be1c9),_0x5be1c9===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x6fc5ee,'change:visibleView',(_0x1ea944,_0xa74b6,_0x398fa6,_0x3641e3)=>{_0x3641e3&&this['stopListening'](_0x3641e3);const _0x1e827b=_0x3dabdd['getByView'](_0x398fa6);_0x398fa6&&_0x1e827b&&(this['listenTo'](_0x398fa6,'change:height',()=>{_0x6fc5ee['updatePosition']();}),this['listenTo'](_0x398fa6,'Esc',()=>{this['_closeAnnotation'](_0x1e827b),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x1e827b&&this['setActiveAnnotation'](_0x1e827b));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x6fc5ee['visibleView']&&(_0x3dabdd['getByView'](_0x6fc5ee['visibleView'])&&_0x6fc5ee['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 _0x59ce32('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x33d664 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x33d664);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0x53c230){for(const _0x202a77 of this['_selectedAnnotations'])_0x53c230['includes'](_0x202a77)||this['_manuallyClosed']['delete'](_0x202a77);for(const _0x4d04c2 of this['annotations'])_0x53c230['includes'](_0x4d04c2)||this['_removeAnnotationFromBalloon'](_0x4d04c2);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x38219c of _0x53c230)this['_addAnnotationToBalloon'](_0x38219c);}this['_selectedAnnotations']=_0x53c230;}['_addAnnotationToBalloon'](_0x2375d2,_0x498db2=!0x1){this['_manuallyClosed']['has'](_0x2375d2)||(this['_addedAnnotations']['has'](_0x2375d2)||this['_balloon']['hasView'](_0x2375d2['view'])||(this['_addedAnnotations']['add'](_0x2375d2),this['_balloon']['add']({'stackId':_0x2375d2['view']['id'],'view':_0x2375d2['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x2375d2)}})),_0x498db2&&this['_balloon']['showStack'](_0x2375d2['view']['id']));}['_getBalloonTargetForAnnotation'](_0x3a2369){const _0x2de242=_0x3a2369['target'],_0x4b7992=this['editor']['editing']['view'],_0x2e8c26=_0x4b7992['document']['selection']['getFirstRange'](),_0x56a20d=_0x4b7992['domConverter']['viewRangeToDom'](_0x2e8c26);if(_0x56a20d['collapse'](!0x0),_0x2de242){if(_0x2de242 instanceof _0x44fba6)return _0x2de242;let _0x233824=[];for(const _0x2c66d9 of _0x2de242)_0x233824['push'](...(_0x4fda02=_0x2c66d9['getClientRects'](),Array['from'](_0x4fda02)['map'](DOMRect['fromRect'])));_0x233824=function(_0x2ad494){const _0x43dee0=[];let _0x20aa89=_0x2ad494[0x0];for(let _0x2cdd2f=0x1;_0x2cdd2f<_0x2ad494['length'];_0x2cdd2f++)b(_0x20aa89,_0x2ad494[_0x2cdd2f])?_0x20aa89['width']+=_0x2ad494[_0x2cdd2f]['width']:(_0x43dee0['push'](_0x20aa89),_0x20aa89=_0x2ad494[_0x2cdd2f]);return _0x43dee0['push'](_0x20aa89),_0x43dee0;}(_0x233824);const _0x58f3fa=_0x56a20d['getBoundingClientRect']();return _0x233824['find'](_0x59c4d4=>_0x59c4d4['top']<=_0x58f3fa['top']&&_0x59c4d4['bottom']>=_0x58f3fa['bottom']&&_0x59c4d4['left']<=_0x58f3fa['left']&&_0x59c4d4['right']>=_0x58f3fa['right'])||_0x233824[0x0];}var _0x4fda02;return _0x3a2369['targetRect']||_0x56a20d;}['_removeAnnotationFromBalloon'](_0x4e2391){this['_addedAnnotations']['has'](_0x4e2391)&&this['_balloon']['hasView'](_0x4e2391['view'])&&(this['_addedAnnotations']['delete'](_0x4e2391),this['_balloon']['remove'](_0x4e2391['view']));}['_closeAnnotation'](_0x35413f){this['_manuallyClosed']['add'](_0x35413f),this['_removeAnnotationFromBalloon'](_0x35413f);}}function b(_0x4278ca,_0x975916){return _0x4278ca['top']===_0x975916['top']&&_0x4278ca['bottom']===_0x975916['bottom']&&_0x4278ca['right']===_0x975916['left'];}var Z='<!--\x0a\x0a\x20What\x20you\x27re\x20currently\x20looking\x20at\x20is\x20the\x20source\x20code\x20of\x20a\x20legally\x20protected,\x20proprietary\x20software.\x0a\x20CKEditor\x205\x20Collaboration\x20is\x20licensed\x20under\x20a\x20commercial\x20license\x20and\x20protected\x20by\x20copyright\x20law.\x20Where\x20not\x20otherwise\x20indicated,\x0a\x20all\x20CKEditor\x205\x20Collaboration\x20content\x20is\x20authored\x20by\x20CKSource\x20engineers\x20and\x20consists\x20of\x20CKSource-owned\x20intellectual\x20property.\x0a\x0a\x20Copyright\x20(c)\x202003-2024,\x20CKSource\x20Holding\x20sp.\x20z\x20o.o.\x20All\x20rights\x20reserved.\x0a\x0a!-->\x0a\x0a<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20clip-rule=\x22evenodd\x22\x20d=\x22M14\x203.5A3.5\x203.5\x200\x200\x201\x2017.5\x207v6l-.005.192a3.501\x203.501\x200\x200\x201-2.927\x203.262l-.062.008v1.813a1.5\x201.5\x200\x200\x201-2.193\x201.33l-.37-.193-.38-.212a13.452\x2013.452\x200\x200\x201-3.272-2.63l-.062-.07-4.729-.046a3.5\x203.5\x200\x200\x201-3.5-3.5v-6a3.5\x203.5\x200\x200\x201\x203.5-3.5L14\x203.5ZM3.5\x204.954a2\x202\x200\x200\x200-2\x202v6a2\x202\x200\x200\x200\x202\x202L8.924\x2015a11.917\x2011.917\x200\x200\x200\x203.71\x203.081l.372.194v-3.268L12.962\x2015H14a2\x202\x200\x200\x200\x202-2V7a2\x202\x200\x200\x200-2-2L3.5\x204.954Z\x22/><path\x20d=\x22M16.5.5h-10a3.5\x203.5\x200\x200\x200-3.162\x202h1.84A2\x202\x200\x200\x201\x206.5\x202h10a2\x202\x200\x200\x201\x202\x202v8.873a3.502\x203.502\x200\x200\x200\x201.495-2.681L20\x2010V4A3.5\x203.5\x200\x200\x200\x2016.5.5Z\x22/><path\x20clip-rule=\x22evenodd\x22\x20d=\x22M12.013\x207.453a.75.75\x200\x200\x201\x20.034\x201.06l-3.75\x204a.75.75\x200\x200\x201-1.045.048l-2.25-2a.75.75\x200\x200\x201\x20.996-1.122l1.704\x201.515\x203.25-3.467a.75.75\x200\x200\x201\x201.061-.034Z\x22/></svg>\x0a';class tt extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x3bc702,_0x35b13d){super(_0x3bc702),this['set']('isEmpty',!_0x35b13d['length']),this['focusTracker']=new _0x424f41(),this['_annotationViews']=_0x35b13d,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new Ft({'focusables':_0x35b13d,'focusTracker':this['focusTracker']}),this['listenTo'](_0x35b13d,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x35b13d,'remove',(_0x58372,_0x511d69)=>{_0x511d69['isActive']&&this['focus'](),_0x35b13d['length']||(this['isEmpty']=!0x0);});const _0x4755e4=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':S(_0x3bc702,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x35b13d},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x4755e4['if']('isEmpty','ck-hidden',_0x435c11=>!_0x435c11)]},'children':[{'text':S(_0x3bc702,'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 _0x33690b of this['_annotationViews'])this['focusTracker']['add'](_0x33690b['element']);this['_annotationViews']['on']('change',(_0x5c0427,{added:_0x2b9f22,removed:_0x2fb71e})=>{for(const _0x3b4437 of _0x2b9f22)this['focusTracker']['add'](_0x3b4437['element']);for(const _0x571fcd of _0x2fb71e)this['focusTracker']['remove'](_0x571fcd['element']);});}}class f extends _0x529673{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,N];}constructor(_0x2b623f){super(_0x2b623f),this['archivedThreads']=new _0x4fd75f();}['init'](){const _0x5eb7a6=this['context'],_0x3ee311=_0x5eb7a6['plugins']['get'](o),_0x348282=_0x5eb7a6['plugins']['get'](N);this['listenTo'](_0x3ee311,'addCommentThread',(_0x57a76a,{threadId:_0x45eefc})=>{const _0x1c22fa=_0x3ee311['getCommentThread'](_0x45eefc);_0x1c22fa['archivedAt']&&this['archivedThreads']['add'](_0x1c22fa,this['_calculatePosition'](_0x1c22fa['archivedAt'])),this['listenTo'](_0x1c22fa,'change:archivedAt',(_0x75c924,_0x59d6e4,_0x285285)=>{_0x285285?this['archivedThreads']['has'](_0x1c22fa)||this['archivedThreads']['add'](_0x1c22fa,this['_calculatePosition'](_0x1c22fa['archivedAt'])):this['archivedThreads']['has'](_0x1c22fa)&&this['archivedThreads']['remove'](_0x1c22fa);});}),this['listenTo'](_0x3ee311,'removeCommentThread',(_0x463c53,{threadId:_0x411d21})=>{const _0x4eeef8=_0x3ee311['getCommentThread'](_0x411d21);this['stopListening'](_0x4eeef8),this['archivedThreads']['has'](_0x4eeef8)&&this['archivedThreads']['remove'](_0x4eeef8);},{'priority':'highest'}),this['listenTo'](_0x348282['collection'],'focus',(_0x59a0d1,_0x4c3687)=>{_0x4c3687['isVisible']||(_0x4c3687['isActive']=!0x0,_0x348282['activate'](_0x4c3687));});}['_calculatePosition'](_0x1b3dcf){const _0x3ee6b8=[...this['archivedThreads']]['findIndex'](_0x13e170=>_0x13e170['archivedAt']<_0x1b3dcf);return _0x3ee6b8>-0x1?_0x3ee6b8:this['archivedThreads']['length'];}}class a extends _0x5a85ea{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[f,_0x48623b];}constructor(_0x129b16){super(_0x129b16),this['annotationViews']=new _0x17461a(),this['_pendingThreads']=[];}['init'](){const _0x296566=this['editor'],_0x525d98=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x296566['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x57b97b,!0x0)),_0x296566['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x51ce57=this['_createCommentsArchiveButton'](_0x9c1b58);return _0x51ce57['set']({'role':'menuitemcheckbox'}),_0x51ce57;});const _0x2a8cd5=_0x296566['plugins']['get'](f),_0x12c7c1=_0x296566['plugins']['get']('Annotations'),_0x39f08e=_0x296566['plugins']['get']('CommentsRepository');this['listenTo'](_0x2a8cd5['archivedThreads'],'add',(_0x1d6389,_0x188044)=>{const _0x4225c1=_0x296566['config']['get']('collaboration.channelId');if(!_0x4225c1||_0x188044['channelId']===_0x4225c1){const _0x2a66db=_0x39f08e['_threadToController']['get'](_0x188044);if(!_0x2a66db)return void this['_pendingThreads']['push'](_0x188044);const _0x183461=this['_calculatePosition'](_0x188044['archivedAt']),_0x4e7af8=_0x12c7c1['getByInnerView'](_0x2a66db['view']);_0x4e7af8['isVisible']&&_0x12c7c1['_visibleAnnotations']['remove'](_0x4e7af8),this['annotationViews']['add'](_0x4e7af8['view'],_0x183461);}}),this['listenTo'](_0x12c7c1['collection'],'add',(_0x50576c,_0x314d88)=>{const _0x3d7cb1=this['_pendingThreads']['find'](_0xd89d05=>{const _0x3cf9b4=_0x39f08e['_threadToController']['get'](_0xd89d05);return _0x3cf9b4&&_0x314d88['innerView']===_0x3cf9b4['view'];});if(_0x3d7cb1){const _0x31ad86=this['_calculatePosition'](_0x3d7cb1['archivedAt']);this['annotationViews']['add'](_0x314d88['view'],_0x31ad86),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x3d7cb1),0x1);}}),this['listenTo'](_0x2a8cd5['archivedThreads'],'remove',(_0x1aec5c,_0x58ea45)=>{const _0x19b3aa=_0x296566['config']['get']('collaboration.channelId');if(!_0x19b3aa||_0x58ea45['channelId']===_0x19b3aa){const _0x374f95=_0x39f08e['_threadToController']['get'](_0x58ea45),_0x54125c=_0x12c7c1['getByInnerView'](_0x374f95['view']);this['annotationViews']['remove'](_0x54125c['view']),this['stopListening'](_0x54125c['focusableElements']);}}),this['listenTo'](_0x12c7c1['collection'],'add',(_0x20dbf6,_0x3b2b09)=>{this['listenTo'](_0x3b2b09,'escape',_0x525d98);}),this['listenTo'](_0x12c7c1['collection'],'remove',(_0x314329,_0x1bc489)=>{this['stopListening'](_0x1bc489,'escape',_0x525d98);});}['_calculatePosition'](_0xf77080){const _0x5618eb=this['editor']['config']['get']('collaboration.channelId'),_0x5f5933=[...this['editor']['plugins']['get'](f)['archivedThreads']]['filter'](_0x1dd3f4=>_0x1dd3f4['channelId']===_0x5618eb)['findIndex'](_0x2473b9=>_0x2473b9['archivedAt']<_0xf77080);return _0x5f5933<0x0||_0x5f5933>this['annotationViews']['length']?this['annotationViews']['length']:_0x5f5933-0x1;}['_toggleDialog'](){const _0x3207ef=this['editor'],_0x9f6135=_0x3207ef['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new tt(_0x3207ef['locale'],this['annotationViews'])),'commentsArchive'===_0x9f6135['id']?_0x9f6135['hide']():_0x9f6135['show']({'id':'commentsArchive','title':S(_0x3207ef['locale'],'COMMENTS_ARCHIVE'),'icon':Z,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0xe69b5f['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x34c7c5,_0xc98889=!0x1){const _0x549994=this['editor']['locale'],_0x33cba9=this['editor']['plugins']['get']('Dialog'),_0x50f768=new _0x34c7c5(_0x549994);return _0x50f768['bind']('isEnabled')['to'](this,'isEnabled'),_0x50f768['bind']('isOn')['to'](_0x33cba9,'id',_0x5dd5b7=>'commentsArchive'===_0x5dd5b7),_0x50f768['set']({'label':S(_0x549994,'COMMENTS_ARCHIVE'),'icon':Z,'isToggleable':!0x0}),_0xc98889&&(_0x50f768['tooltip']=!0x0),this['listenTo'](_0x50f768,'execute',()=>this['_toggleDialog']()),_0x50f768;}['_hideDialogOnAnnotationEscape']=_0x25f055=>{const _0x48778f=_0x25f055['source'];if(!this['annotationViews']['has'](_0x48778f['view']))return;const _0x2de759=this['editor']['plugins']['get']('Dialog');_0x2de759['isOpen']&&'commentsArchive'===_0x2de759['id']&&(_0x2de759['hide'](),_0x25f055['stop']());};}class p extends _0x5a85ea{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,x as AnnotationCollection,T as AnnotationView,N as Annotations,M as AnnotationsUIs,ss as BaseCommentThreadView,os as BaseCommentView,re as Comment,oe as CommentThread,yt as CommentThreadController,ie as CommentThreadInputView,Ct as CommentThreadView,vt 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,e as WideSidebar};
|
|
23
|
+
import{Editor as _0xff7e8f,icons as _0xc88a75,ContextPlugin as _0x3e81dd,PendingActions as ht,Command as _0x572075,Plugin as _0x21992c,Context as _0x128a45}from'@ckeditor/ckeditor5-core/dist/index.js';import{ObservableMixin as _0x4137b1,uid as _0x494a46,KeystrokeHandler as jt,FocusTracker as _0x32f229,diff as _0x3c49e1,Collection as _0xc5674b,Rect as _0x2e5438,CKEditorError as _0x28de93,first as _0x51e4e3,priorities as Wt,scrollViewportToShowTarget as rt,getEnvKeystrokeText as nt,toUnit as Ht,DomEmitterMixin as _0x1e87d2,keyCodes as _0x2c759f}from'@ckeditor/ckeditor5-utils/dist/index.js';import{UserView as _0x35602c,AriaDescriptionView as Zt,setupThreadKeyboardNavigation as ts,ConfirmMixin as ti,LateFocusButtonView as _0x471721,trimHtml as _0xb5bdeb,LateFocusDropdownButtonView as _0x110559,Users as it,getDateTimeFormatter as mt,hashObject as lt,getAllMarkersDomElementsSorted as et,surroundingMarkersDetector as ot,FOCUS_ANNOTATION_KEYSTROKE as _0xe426d9}from'ckeditor5-collaboration/dist/index.js';import{throttle as bt,isEqual as It,cloneDeep as pt,set as wt,unset as At,debounce as _0x3c02bb}from'lodash-es';import{EditorUIView as Xt,InlineEditableUIView as $t,EditorUI as Ut,View as kt,FocusCycler as Ft,ButtonView as _0x59646e,ViewCollection as _0x4f3352,createDropdown as _0x22144c,ListView as _0x4d3f96,focusChildOnDropdownOpen as _0x266581,ListItemView as _0x49fbdb,MenuBarMenuListItemButtonView as _0x5c043a,BodyCollection as _0x58f719,BalloonPanelView as _0x2895cc,ContextualBalloon as _0x178c54,Dialog as _0x270df8,DialogViewPosition as _0x372112}from'@ckeditor/ckeditor5-ui/dist/index.js';import{disablePlaceholder as zt,enablePlaceholder as St,MouseObserver as _0xa9273a}from'@ckeditor/ckeditor5-engine/dist/index.js';import{Clipboard as Bt,ClipboardMarkersUtils as Mt,ClipboardPipeline as Pt}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{Enter as Et,ShiftEnter as Gt}from'@ckeditor/ckeditor5-enter/dist/index.js';import{SelectAll as Jt}from'@ckeditor/ckeditor5-select-all/dist/index.js';import{Typing as Kt}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Undo as Lt}from'@ckeditor/ckeditor5-undo/dist/index.js';import{Paragraph as Nt}from'@ckeditor/ckeditor5-paragraph/dist/index.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x153f39}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';class yt extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x4137b1(){['model'];['view'];constructor(_0x2908d,_0x24e9e5){super(),this['model']=_0x2908d,this['model']['_isAttached']=!0x0,this['view']=_0x24e9e5,this['listenTo'](_0x24e9e5,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x24e9e5,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x24e9e5,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x24e9e5,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x24e9e5,'addComment',(_0x3df646,_0x12f09f)=>this['addComment'](_0x12f09f)),this['listenTo'](_0x24e9e5,'updateComment',(_0x1a6551,_0x273d55,_0x20a49d)=>this['updateComment'](_0x273d55,_0x20a49d)),this['listenTo'](_0x24e9e5,'removeComment',(_0x1f0c06,_0x5e9109)=>this['removeComment'](_0x5e9109));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x5c7d70){this['model']['addComment']({'content':_0x5c7d70,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0x48c5bf,_0x17fa45){this['model']['getComment'](_0x48c5bf)['update']({'content':_0x17fa45});}['removeComment'](_0x389325){this['model']['getComment'](_0x389325)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}}function S(_0xf6a89e,_0x300447,_0x5d1494){const t=_0xf6a89e['t'];switch(_0x300447){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'},_0x5d1494);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'},_0x5d1494);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'},_0x5d1494);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'},_0x5d1494);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x5d1494);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'},_0x5d1494);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'},_0x5d1494);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'},_0x5d1494);case'COMMENTS_ARCHIVE':return t({'string':'Comments\x20archive','id':'COMMENTS_ARCHIVE'});case'EMPTY_COMMENTS_ARCHIVE':return t({'string':'There\x20are\x20no\x20archived\x20comment\x20threads.','id':'EMPTY_COMMENTS_ARCHIVE'});case'COMMENTS_ARCHIVE_LIST_LABEL':return t({'string':'List\x20of\x20comments','id':'COMMENTS_ARCHIVE_LIST_LABEL'});case'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP':return t({'string':'Keystrokes\x20for\x20interacting\x20with\x20annotation\x20threads\x20(e.g.\x20comments,\x20track\x20changes\x20suggestions)','id':'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'});case'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO':return t({'string':'Move\x20focus\x20to\x20the\x20thread\x20when\x20the\x20selection\x20is\x20anchored\x20in\x20its\x20marker','id':'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'});case'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT':return t({'string':'Exit\x20the\x20annotation\x20and\x20move\x20focus\x20back\x20to\x20the\x20edited\x20content','id':'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER':return t({'string':'Browse\x20the\x20focused\x20annotation\x20thread\x20or\x20thread\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'});case'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS':return t({'string':'Move\x20across\x20internals\x20of\x20the\x20annotation\x20thread','id':'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'});case'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT':return t({'string':'Submit\x20the\x20reply\x20while\x20writing\x20a\x20comment','id':'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'});case'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS':return t({'string':'Move\x20to\x20the\x20previous\x20or\x20next\x20thread\x20in\x20the\x20annotations\x20sidebar\x20or\x20comments\x20archive','id':'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'});default:return'';}}class Vt extends Xt{['main'];['editable'];constructor(_0x2ff387,_0x3999bc){super(_0x2ff387);const _0x328ef4=_0x494a46();this['main']=this['createCollection'](),this['editable']=new $t(_0x2ff387,_0x3999bc,void 0x0,{'label':()=>S(_0x2ff387,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x2ff387['uiLanguageDirection'],'lang':_0x2ff387['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x328ef4},'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 Ut{['view'];constructor(_0x2b342f){super(_0x2b342f),this['view']=new Vt(_0x2b342f['locale'],_0x2b342f['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x11dbaf=this['editor']['editing']['view'],_0x40a311=this['view']['editable'],_0x45d02d=_0x11dbaf['document']['getRoot']();_0x40a311['name']=_0x45d02d['rootName'],this['view']['render']();const _0x19a090=_0x40a311['element'];this['setEditableElement'](_0x40a311['name'],_0x19a090),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x11dbaf['attachDomRoot'](_0x19a090),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}}const Qt=[Bt,Et,Gt,Jt,Kt,Lt,Nt];class Rt extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x4137b1(_0xff7e8f){static ['defaultPlugins']=/* #__PURE__ -- @preserve */
|
|
26
|
+
((()=>Qt)());constructor(_0x2c1aff={}){function _0xd34125(_0x1d5a73){return _0x1d5a73['map'](_0x411b6e=>String['fromCharCode'](_0x411b6e))['join']('');}(_0x2c1aff=Object['assign']({},_0x2c1aff))['plugins']||(_0x2c1aff['plugins']=Rt['defaultPlugins']),super(_0x2c1aff),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[_0xd34125([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xd34125([0x76,0x69,0x65,0x77])][_0xd34125([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xd34125([0x61,0x75,0x74,0x6f]),this[_0xd34125([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xd34125([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xd34125([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xd34125([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xd34125([0x6f,0x6b])});}['create'](){const _0x5ede1b=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x5ede1b))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x3166ab=>{const _0x122e29=this['model']['document']['getRoot'](),_0x3fe5a5=_0x122e29&&_0x122e29['getChild'](_0x122e29['childCount']-0x1);_0x3166ab['setSelection'](_0x3fe5a5,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x832334=this['editing']['view'],_0x1925c0=_0x832334['document']['getRoot'](),_0x44008f=_0x1925c0['getChild'](0x0);_0x1925c0['childCount']>0x1||!_0x44008f||'p'!=_0x44008f['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(zt(_0x832334,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x44008f['placeholder']=this['placeholder']),St({'view':_0x832334,'element':_0x44008f,'keepOnFocus':!0x0}),this['placeholderElement']=_0x44008f);}}class hs extends kt{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x55cbc2,_0x32e1a8={}){super(_0x55cbc2),this['editor']=null,this['_editorConfig']=_0x32e1a8,this['set']('value',_0x32e1a8['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',S(_0x55cbc2,'Reply...')),this['set']('submitLabel',S(_0x55cbc2,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new jt(),this['focusTracker']=new _0x32f229(),this['focusCycler']=new Ft({'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',(_0x3d1772,_0x589907)=>{this['cancelButtonView']['fire']('execute'),_0x589907();}),this['keystrokes']['set']('Ctrl+Enter',(_0x210a60,_0x5a3fdc)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x5a3fdc());}),this['on']('submit',(_0x4be7fa,_0x4cdc45)=>{_0x4cdc45['length']>0xfde8?(alert(S(_0x55cbc2,'TOO_LONG_COMMENT_ALERT',[_0x4cdc45['length'],0xfde8])),_0x4be7fa['stop']()):this['editor']['setData']('');},{'priority':'high'});}['render'](){super['render'](),this['_setupKeyboardNavigation']();}['createEditor'](){return this['editor']||(this['editor']=new Rt(this['_editorConfig']),this['_editorCreationPromise']=this['editor']['create']()['then'](()=>{if(this['_isDestroyed'])return;const _0xa0cba5=this['editor'];this['element']['insertBefore'](_0xa0cba5['ui']['element'],this['element']['firstChild']),_0xa0cba5['model']['document']['on']('change',()=>this['value']=_0xa0cba5['getData']()),_0xa0cba5['bind']('placeholder')['to'](this),this['focusables']['add'](_0xa0cba5['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x2acb70){-0x1===_0x2acb70?(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:_0x21f937}=this,_0x2a73c9=new _0x59646e(_0x21f937);return _0x2a73c9['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x2a73c9['withText']=!0x0,_0x2a73c9['bind']('label')['to'](this,'submitLabel'),_0x2a73c9['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x2a73c9['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0xe01513,_0x5d0cd1)=>!_0x5d0cd1&&!!_0xe01513['trim']()),_0x2a73c9;}['_createCancelButton'](){const {locale:_0xe19519}=this,_0x1d8073=new _0x59646e(_0xe19519);return _0x1d8073['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x1d8073['label']=S(_0xe19519,'Cancel'),_0x1d8073['withText']=!0x0,_0x1d8073['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x1d8073;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x504ee4=>{this['focusTracker']['add'](_0x504ee4['element']);}),this['focusables']['on']('change',(_0x49a585,_0x1986a3)=>{for(const _0x32ef07 of Array['from'](_0x1986a3['added'])['reverse']())this['focusTracker']['add'](_0x32ef07['element']);});}}class ie extends kt{constructor(_0x458b63,_0x96033e,_0xdfab94){super(_0x458b63),this['commentInputView']=new hs(_0x458b63,_0xdfab94),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x3c7e4b,_0x1973c1)=>_0x3c7e4b||!!_0x1973c1),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 _0x35602c(_0x458b63,_0x96033e),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'](_0x232206){this['commentInputView']['focus'](_0x232206);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x4ee98a,_0x5057c2)=>{const {submitButtonView:_0x461eb4,cancelButtonView:_0x319e83,editor:_0x5e4e6a}=this['commentInputView'];[_0x461eb4['element'],_0x319e83['element'],_0x5e4e6a?_0x5e4e6a['editing']['view']['getDomRoot']():null]['filter'](_0x13798e=>_0x13798e)['some'](_0x5aaed4=>_0x5aaed4['contains'](_0x5057c2['target']))||(this['focus'](),_0x5057c2['preventDefault']());});}}class cs extends kt{constructor(_0x8392aa){super(_0x8392aa);const _0x14574a=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x14574a['to']('count',_0x180cba=>S(_0x8392aa,'NUMBER_OF_COMMENTS',_0x180cba))}]});}}class te extends kt{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x107ab3,_0x4512b0,_0x493477){super(_0x107ab3);const _0x5f0e3b=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x4512b0['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x4512b0,this['_config']=_0x493477,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x32f229(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0xfb66c1=>this['commentViews']['map'](_0x3885a5=>_0x3885a5['element'])['includes'](_0xfb66c1['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new cs(_0x107ab3),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x2b0435=>_0x2b0435-this['_config']['maxCommentsWhenCollapsed']);for(const _0x5edc8f of _0x4512b0['comments'])this['_handleNewCommentModel'](_0x5edc8f);this['_handleInfoComment'](),this['listenTo'](_0x4512b0['comments'],'add',(_0x33a749,_0xbce3de)=>{const _0x251df5=this['_calculatePosition'](_0xbce3de);this['length']++,this['_handleNewCommentModel'](_0xbce3de,_0x251df5),this['refreshVisibleViews']();}),this['listenTo'](_0x4512b0['comments'],'remove',(_0x3447e7,_0x3648c3)=>{this['length']--,this['_handleRemoveCommentModel'](_0x3648c3),this['refreshVisibleViews']();}),this['listenTo'](_0x4512b0,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x4512b0,'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',_0x5f0e3b['if']('length','ck-hidden',_0x3abaa8=>!_0x3abaa8)],'aria-label':S(_0x107ab3,'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'](_0x1eb148){-0x1===_0x1eb148?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0xf0d0f7 of this['commentViews'])_0xf0d0f7['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x1c1da2,_0x16c8cf){const _0xae5c33=new this['_config']['CommentView'](this['locale'],_0x1c1da2,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0xae5c33['viewUid']=_0x1c1da2['id'],_0xae5c33['delegate']('removeComment')['to'](this),_0xae5c33['delegate']('updateComment')['to'](this),_0xae5c33['delegate']('resolveCommentThread')['to'](this),_0xae5c33['delegate']('editorReady')['to'](this),_0xae5c33['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0xae5c33,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0xae5c33,_0x16c8cf);}['_calculatePosition'](_0x2c67a0){const _0x4ec017=this['_model']['_findOptimalIndex'](_0x2c67a0);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x2c67a0['authoredAt']?_0x4ec017-0x1:_0x4ec017:_0x4ec017-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0xb399d3={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':S(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0xb399d3,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0xb399d3));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x5e4e7a){const _0x1c8394=this['commentViews']['remove'](_0x5e4e7a['id']);this['stopListening'](_0x1c8394),_0x1c8394['isEditMode']&&this['_updateHasDirtyComment'](),_0x1c8394['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0xb30dad=>_0xb30dad['isEditMode']);}['_rearrangeCollapse'](){const _0x532880=function(_0x3a2b38){const _0x40b983=new _0xc5674b();for(const _0x3424a7 of _0x3a2b38)_0x40b983['add'](_0x3424a7);return _0x40b983;}(this['commentViews']),_0x4a3a36=this['_collapsedCommentsView']['count'];for(let _0x4800c5=0x1;_0x4800c5<=_0x4a3a36;_0x4800c5++)_0x532880['remove'](0x1);for(const _0x248687 of _0x532880)_0x248687['collapse']();_0x4a3a36>0x0&&_0x532880['add'](this['_collapsedCommentsView'],0x1),ns(_0x3c49e1(Array['from'](this['visibleViews']),Array['from'](_0x532880)),this['visibleViews'],_0x532880);}['_rearrangeExpand'](){ns(_0x3c49e1(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x338cbd of this['visibleViews'])_0x338cbd['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x58c608=>{this['focusTracker']['add'](_0x58c608['element']),this['keystrokes']['listenTo'](_0x58c608['element']);}),this['commentViews']['on']('change',(_0x30a9ca,_0x1cb2f2)=>{for(const _0x5be392 of _0x1cb2f2['removed'])this['focusTracker']['remove'](_0x5be392['element']),this['keystrokes']['stopListening'](_0x5be392['element']);for(const _0x4b21b8 of Array['from'](_0x1cb2f2['added'])['reverse']())this['focusTracker']['add'](_0x4b21b8['element']),this['keystrokes']['listenTo'](_0x4b21b8['element']);});}}function ns(_0x565c53,_0x2a6bb0,_0x4daf8c){let _0x2fc6a9=0x0;for(const _0x285b2d of _0x565c53)switch(_0x285b2d){case'insert':_0x2a6bb0['add'](_0x4daf8c['get'](_0x2fc6a9),_0x2fc6a9),_0x2fc6a9++;break;case'delete':_0x2a6bb0['remove'](_0x2fc6a9);break;case'equal':_0x2fc6a9++;}}class as extends kt{constructor(_0x1d8f89){super(_0x1d8f89);const _0x2a3486=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x2a3486['to']('contextValue',_0x233af7=>S(_0x1d8f89,'THREAD_CONTEXT_LABEL',_0x233af7)),'tabindex':-0x1},'children':[{'text':_0x2a3486['to']('contextValue')}]});}['focus'](){this['element']['focus']();}}class Yt extends kt{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x14614d,_0x1dd361){super(_0x14614d);const _0x32d8cb=this['bindTemplate'];this['_model']=_0x1dd361,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x32f229(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x3753ff=>!!_0x3753ff),this['bind']('contextValue')['to'](this['_model'],'context',_0x5a9ea1=>_0x5a9ea1&&_0x5a9ea1['value']?this['_trimContextValue'](_0x5a9ea1['value']):S(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',_0x32d8cb['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 _0x4f18f5=new _0x59646e(this['locale']);return _0x4f18f5['label']=S(this['locale'],'Reopen'),_0x4f18f5['tooltip']=S(this['locale'],'Reopen'),_0x4f18f5['icon']='<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22m5.042\x209.367\x202.189\x201.837a.75.75\x200\x200\x201-.965\x201.149l-3.788-3.18a.747.747\x200\x200\x201-.21-.284.75.75\x200\x200\x201\x20.17-.945L6.23\x204.762a.75.75\x200\x201\x201\x20.964\x201.15L4.863\x207.866h8.917A.75.75\x200\x200\x201\x2014\x207.9a4\x204\x200\x201\x201-1.477\x207.718l.344-1.489a2.5\x202.5\x200\x201\x200\x201.094-4.73l.008-.032H5.042z\x22/></svg>',_0x4f18f5['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3d52ba=>!_0x3d52ba),_0x4f18f5['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x279fb4,_0x42fdcc)=>_0x279fb4&&_0x42fdcc),_0x4f18f5['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x4f18f5;}['_trimContextValue'](_0x4d7f63){if(_0x4d7f63['length']<0x96)return _0x4d7f63;const _0x29be61=_0x4d7f63['lastIndexOf']('\x20',0x93);return _0x4d7f63['substring'](0x0,_0x29be61>-0x1?_0x29be61:0x93)+'...';}['_attachContextActions'](){const _0x2819c1=this['element']['querySelector']('.ck-context'),_0xdce3a0=_0x2819c1['querySelector']('.ck-context__value');this['listenTo'](_0x2819c1,'mouseenter',()=>{_0xdce3a0['offsetWidth']<_0xdce3a0['scrollWidth']&&_0x2819c1['classList']['add']('overlay');}),this['listenTo'](_0x2819c1,'mouseleave',()=>{_0x2819c1['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x10efd1 of this['focusables'])this['focusTracker']['add'](_0x10efd1['element']),this['keystrokes']['listenTo'](_0x10efd1['element']);}['_createContextView'](){const _0x5b8c2d=new as(this['locale']);return _0x5b8c2d['bind']('contextValue')['to'](this),_0x5b8c2d;}}class ss extends kt{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x48e5a1,_0xd9c367,_0x1b99f4,_0x91275e){super(_0x48e5a1),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0xd9c367,this['_localUser']=_0x1b99f4,this['_config']=_0x91275e,this['commentThreadHeaderView']=new Yt(_0x48e5a1,_0xd9c367),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new Zt(_0x48e5a1,S(_0x48e5a1,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new te(_0x48e5a1,_0xd9c367,Object['assign']({'CommentView':this['_config']['CommentView']},_0x91275e)),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',(_0x5cf4b5,_0x396290)=>_0x5cf4b5||!!_0x396290),this['bind']('isUnlinked')['to'](_0xd9c367,'unlinkedAt',_0x40e75a=>!!_0x40e75a),this['bind']('ariaLabel')['to'](this,'length',_0x3d1f46=>{const _0x416a66=this['_model']['comments']['first']?this['_model']['comments']['first']['author']['name']:this['_localUser']['name'];return S(this['locale'],'COMMENT_THREAD_LABEL',[_0x3d1f46,_0x416a66]);}),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x32f229(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x510f8e=>_0x510f8e['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),ts(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x343fd5=new ie(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x424d85=_0x343fd5['commentInputView'];return _0x343fd5['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x424d85,'value',(_0x4367c1,_0x33b22a,_0x221fa4,_0x8f5af5,_0x28e5d4)=>!!_0x28e5d4||!!_0x8f5af5&&_0x221fa4&&!_0x33b22a||_0x4367c1&&_0x221fa4&&!_0x33b22a),_0x424d85['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x418867,_0x4f7bf5,_0x2c456b)=>{let _0x8eab63;return _0x8eab63=_0x2c456b&&_0x4f7bf5?'Reply\x20to\x20reopen\x20discussion...':_0x418867?'Reply...':'Write\x20a\x20comment...',S(this['locale'],_0x8eab63);}),_0x424d85['bind']('submitLabel')['to'](this,'length',_0x16c8f6=>S(this['locale'],_0x16c8f6?'Reply':'Comment')),_0x424d85['on']('submit',(_0xae4b19,_0x4c8e01)=>{this['fire']('addComment',_0x4c8e01),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x424d85['on']('cancel',()=>{this['focus']();}),_0x424d85['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x424d85['on']('cancel',_0x539c86=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x539c86['stop']());}),this['on']('change:isActive',(_0x315fd1,_0x9efdce,_0x262563)=>{_0x262563||this['length']||_0x424d85['value']||this['fire']('removeCommentThread');}),_0x343fd5;}}class Ct extends/* #__PURE__ -- @preserve */
|
|
27
|
+
ti(ss){['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x591264,_0x434b6d,_0x18b96d,_0x20bab2){super(_0x591264,_0x434b6d,_0x18b96d,_0x20bab2),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x591264,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x14dc86,_0x2498c7,_0x318454)=>{_0x318454||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x1f439a,_0xff9043,_0x26826a)=>{_0x26826a&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x548ed2=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x548ed2['if']('isActive','ck-thread--active'),_0x548ed2['if']('isUnlinked','ck-thread--unlinked'),_0x548ed2['if']('isConfirm','ck-thread--remove-confirmation'),_0x548ed2['to']('actionIndicator',_0x51792c=>_0x51792c?'ck-thread--'+_0x51792c:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x548ed2['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 _0x29323b of this['commentsListView']['commentViews'])_0x29323b['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x3bf8c3}=this,_0x2df8d0=this['commentsListView']['commentViews']['get'](0x0);_0x2df8d0===this['_boundFirstCommentView']||_0x2df8d0['isSystemComment']||(this['_boundFirstCommentView']=_0x2df8d0,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x2df8d0,'actionIndicator',_0x7a9a5a=>'remove'===_0x7a9a5a?'remove':null),_0x2df8d0['placeholder']=S(_0x3bf8c3,'Write\x20a\x20comment...'),_0x2df8d0['removeButton']['on']('execute',_0x59cc71=>{_0x59cc71['stop'](),this['showConfirm'](S(_0x3bf8c3,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x2df8d0['focus']();}),_0x2df8d0['actionBar']['add'](this['resolveButton'],0x0),_0x2df8d0['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x215b68=new _0x471721(this['locale']);return _0x215b68['label']=S(this['locale'],'Resolve'),_0x215b68['tooltip']=S(this['locale'],'Resolve'),_0x215b68['icon']=_0xc88a75['check'],_0x215b68['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x215b68['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1c9762=>!_0x1c9762),_0x215b68['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x179ee9,_0x16571e)=>_0x179ee9&&!_0x16571e),_0x215b68['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x215b68;}['_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(_0x1959a2){super(_0x1959a2),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x2130d0,_0x102856,_0x36199d)=>{this['element']['innerHTML']=_0x36199d;}),this['element']['innerHTML']=this['content'];}}class os extends kt{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x5ab90a,_0x454527,_0xa28398){super(_0x5ab90a),this['_model']=_0x454527,this['_config']=_0xa28398,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x454527,'content',_0x454527,'authoredAt',(_0x1edd10,_0x2090a5)=>S(_0x5ab90a,'COMMENT_ARIA_LABEL',[_0x454527['author']['name'],_0xa28398['formatDateTime'](_0x2090a5),new DOMParser()['parseFromString'](_0x1edd10,'text/html')['body']['textContent'],_0x454527['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new Zt(_0x5ab90a,S(_0x5ab90a,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new _0x4f3352(),this['focusTracker']=new _0x32f229(),this['keystrokes']=new jt(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x597d59=>_0x597d59['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']?S(this['locale'],'EXTERNAL_IMPORT_WORD_COMMENT'):S(this['locale'],'EXTERNAL_COMMENT');}['getUserViewNotificationText'](){return this['_model']['isExternal']?'importWord'===this['_model']['attributes']['@external']['source']?S(this['locale'],'EXTERNAL_IMPORT_WORD_AVATAR',this['_model']['creator']['name']):S(this['locale'],'EXTERNAL_AVATAR',this['_model']['creator']['name']):null;}['_createCommentContentView'](){const _0x319772=new es(this['locale']);return _0x319772['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x54efe1,_0x59e372)=>_0x59e372?_0xb5bdeb(_0x54efe1,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x54efe1),_0x319772;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0x235613=new hs(this['locale'],this['_config']['editorConfig']);return _0x235613['value']=this['_model']['content'],_0x235613['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x235613['submitLabel']=S(this['locale'],'Save'),_0x235613['on']('submit',(_0x8c88b,_0x7e646a)=>{this['fire']('updateComment',this['_model']['id'],_0x7e646a),this['switchToDisplayMode'](),this['focus']();}),_0x235613['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0x235613['once']('editorReady',()=>{_0x235613['focus']();}),_0x235613['createEditor'](),_0x235613['delegate']('editorReady')['to'](this),_0x235613['delegate']('editorDestroyed')['to'](this),_0x235613;}['_setupKeyboardNavigation'](){const _0x1d542e=this['element'];this['keystrokes']['listenTo'](_0x1d542e);for(const _0x3a8266 of this['focusables'])this['focusTracker']['add'](_0x3a8266['element']),this['keystrokes']['listenTo'](_0x3a8266['element']);this['focusables']['on']('change',(_0x4ee380,_0x59e452)=>{for(const _0x305ef0 of _0x59e452['removed'])this['focusTracker']['remove'](_0x305ef0['element']),this['keystrokes']['stopListening'](_0x305ef0['element']);for(const _0x440078 of _0x59e452['added'])this['focusTracker']['add'](_0x440078['element']),this['keystrokes']['listenTo'](_0x440078['element']);}),this['keystrokes']['set']('enter',(_0x487356,_0x4d8b79)=>{_0x1d542e===_0x487356['target']&&(this['focusCycler']['focusFirst'](),_0x4d8b79());}),this['keystrokes']['set']('esc',(_0x2926ab,_0x154225)=>{_0x1d542e!==_0x2926ab['target']&&(this['focus'](),_0x154225());});}}class vt extends/* #__PURE__ -- @preserve */
|
|
28
|
+
ti(os){['actionBar'];['userView'];constructor(_0x3f0e40,_0x17f451,_0x5a992a){super(_0x3f0e40,_0x17f451,_0x5a992a),this['set']('actionIndicator',null),this['set']('placeholder',S(_0x3f0e40,'Reply...')),this['bind']('authoredAt')['to'](_0x17f451),this['bind']('resolvedAt')['to'](_0x17f451),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 _0x35602c(_0x3f0e40,_0x17f451['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x17f451,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x2d0006=this['bindTemplate'],_0x48694e=[{'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']}},{'tag':'time','attributes':{'datetime':_0x2d0006['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x2d0006['to']('authoredAt',_0x2d2880=>this['_config']['formatDateTime'](_0x2d2880))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x2d0006['if']('isEditMode','ck-comment__actions--hidden'),_0x2d0006['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']&&_0x48694e['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper',_0x2d0006['if']('isConfirm','ck-comment--remove-confirmation')],'tabindex':-0x1,'aria-label':_0x2d0006['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x2d0006['if']('isEditMode','ck-comment--edit'),_0x2d0006['if']('isSystemComment','ck-comment--info'),_0x2d0006['to']('actionIndicator',_0x1c4961=>_0x1c4961?'ck-comment--'+_0x1c4961:'')],'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':_0x48694e}]}]};}['_createEditButton'](){const _0x2d69da=new _0x59646e(this['locale']);return _0x2d69da['label']=S(this['locale'],'Edit'),_0x2d69da['icon']=_0xc88a75['pencil'],_0x2d69da['withText']=!0x0,_0x2d69da['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0x2d69da['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x3d9053=>!_0x3d9053),_0x2d69da['bind']('isVisible')['to'](this['_model'],'isEditable'),_0x2d69da['on']('execute',()=>this['switchToEditMode']()),_0x2d69da;}['_createRemoveButton'](){const _0x16abc4=new _0x59646e(this['locale']);return _0x16abc4['label']=S(this['locale'],'Remove'),_0x16abc4['icon']='<!--\x0a\x0a\x20What\x20you\x27re\x20currently\x20looking\x20at\x20is\x20the\x20source\x20code\x20of\x20a\x20legally\x20protected,\x20proprietary\x20software.\x0a\x20CKEditor\x205\x20Collaboration\x20is\x20licensed\x20under\x20a\x20commercial\x20license\x20and\x20protected\x20by\x20copyright\x20law.\x20Where\x20not\x20otherwise\x20indicated,\x0a\x20all\x20CKEditor\x205\x20Collaboration\x20content\x20is\x20authored\x20by\x20CKSource\x20engineers\x20and\x20consists\x20of\x20CKSource-owned\x20intellectual\x20property.\x0a\x0a\x20Copyright\x20(c)\x202003-2024,\x20CKSource\x20Holding\x20sp.\x20z\x20o.o.\x20All\x20rights\x20reserved.\x0a\x0a!-->\x0a\x0a<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M5.2\x207h9.2c.6\x200\x201\x20.4\x201\x201v9.9c0\x20.5-.4\x201-1\x201H5.2a1\x201\x200\x200\x201-1-1V8c0-.6.4-1\x201-1zm1\x201.5c-.3\x200-.5.2-.5.5v8c0\x20.3.2.5.5.5h.5c.2\x200\x20.5-.2.5-.5V9c0-.3-.3-.5-.5-.5h-.5zm3.2\x200c-.2\x200-.5.2-.5.5v8c0\x20.3.3.5.5.5h.5c.3\x200\x20.5-.2.5-.5V9c0-.3-.2-.5-.5-.5h-.4zm3.5\x200c-.2\x200-.5.2-.5.5v8c0\x20.3.3.5.5.5h.5c.3\x200\x20.5-.2.5-.5V9c0-.3-.2-.5-.5-.5h-.5zm-1.4-7.1H8.3L6.5\x203.6H3.8c-.5\x200-.7.3-.7.8s.2.7.7.7h12c.6\x200\x20.9-.2.9-.7\x200-.5-.3-.8-1-.8h-2.4l-1.8-2.2z\x22/></svg>\x0a',_0x16abc4['withText']=!0x0,_0x16abc4['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x16abc4['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x11b901=>!_0x11b901),_0x16abc4['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x16abc4['on']('execute',()=>{this['showConfirm'](S(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x16abc4;}['_createDropdown'](){const _0x3e1a8c=_0x22144c(this['locale'],_0x110559),_0x215689=_0x3e1a8c['panelView']['children'],_0x289488=new _0x4d3f96(this['locale']),_0x386310=_0x3e1a8c['bindTemplate'];_0x266581(_0x3e1a8c,()=>this['items']['find'](_0x1096bf=>_0x1096bf['isVisible'])),_0x3e1a8c['extendTemplate']({'attributes':{'class':[_0x386310['if']('isVisible','ck-hidden',_0x2e0b0a=>!_0x2e0b0a)]}});const _0x32f997=(_0x5a74e0,_0x1e8850=-0x1)=>{const _0x2a9673=new _0x49fbdb(this['locale']);_0x2a9673['children']['add'](_0x5a74e0);const _0x17b2c6=_0x1e8850>-0x1?_0x1e8850:_0x289488['items']['length'];_0x289488['items']['add'](_0x2a9673,_0x17b2c6);const _0x5397c0=Array['from'](this['items']);_0x3e1a8c['unbind']('isEnabled','isVisible'),_0x3e1a8c['bind']('isEnabled')['toMany'](_0x5397c0,'isEnabled',(..._0x3e08e8)=>_0x3e08e8['some'](_0x65ff8e=>_0x65ff8e)),_0x3e1a8c['bind']('isVisible')['toMany'](_0x5397c0,'isVisible',(..._0x3aedea)=>_0x3aedea['some'](_0x1184a9=>_0x1184a9));};_0x3e1a8c['panelPosition']='sw',_0x3e1a8c['buttonView']['set']({'label':S(this['locale'],'Show\x20more\x20items'),'icon':_0xc88a75['threeVerticalDots']});for(const _0x28850a of this['items'])_0x32f997(_0x28850a);return _0x215689['add'](_0x289488),_0x3e1a8c['listenTo'](this['items'],'add',(_0x10dbd8,_0x1a6a78,_0x3c8d9d)=>{_0x32f997(_0x1a6a78,_0x3c8d9d);}),_0x3e1a8c['listenTo'](this['items'],'remove',(_0x256d40,_0x308de2,_0xfcea89)=>{_0x289488['items']['remove'](_0xfcea89);}),_0x3e1a8c;}['_attachActions'](_0x968f25,_0x581b0e){const _0x21d3f5=_0x968f25&&_0x968f25['element'];_0x21d3f5&&(this['listenTo'](_0x21d3f5,'mouseenter',()=>this['actionIndicator']=_0x581b0e),this['listenTo'](_0x21d3f5,'focus',()=>this['actionIndicator']=_0x581b0e),this['listenTo'](_0x21d3f5,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x21d3f5,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x23017e=super['_createCommentInputView']();return _0x23017e['bind']('placeholder')['to'](this),_0x23017e;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}}function Dt(_0x4bf89f){const _0x3eeca2=bt(_0x4bf89f,0x1e),_0xe1e607=new MutationObserver(_0x252260=>{for(const _0x3b196f of _0x252260)('attributes'==_0x3b196f['type']&&'class'==_0x3b196f['attributeName']||'childList'==_0x3b196f['type']||'characterData'==_0x3b196f['type'])&&_0x3eeca2();});return{'attach'(_0x1c1dbc){_0xe1e607['observe'](_0x1c1dbc,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0xe1e607['disconnect'](),_0x3eeca2['cancel']();}};}class T extends kt{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x5c0ae2,_0x5f51a2){super(_0x5c0ae2),this['id']=_0x494a46(),this['focusTracker']=new _0x32f229(),this['keystrokes']=new jt(),this['keystrokes']['set']('Esc',(_0x12865e,_0x3f2900)=>this['fire']('Esc',_0x3f2900)),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']=Dt(()=>this['_updateHeight']()),this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this),this['content']['add'](_0x5f51a2),this['mainView']=_0x5f51a2;const _0x21c384=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x21c384['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 _0x43c6bd=this['element']['clientHeight'];_0x43c6bd&&(this['height']=_0x43c6bd);}}class d extends/* #__PURE__ -- @preserve */
|
|
29
|
+
_0x4137b1(){['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x88120b,target:_0x3580fe,type:_0x345cb0,isVisible:_0x37ac94=!0x0}){super(),this['view']=_0x88120b,this['view']['element']||this['view']['render'](),this['_type']=_0x345cb0,this['_target']=_0x3580fe,d['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0xc5674b([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x3cfcf9,_0x51370b)=>{this['view']['focusTracker']['add'](_0x51370b);}),this['focusableElements']['on']('remove',(_0x314995,_0x2db1e0)=>{this['view']['focusTracker']['remove'](_0x2db1e0);}),this['set']('isVisible',_0x37ac94);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x35ca7c=this['_getNormalizedTarget']();return d['_assertCorrectTarget'](_0x35ca7c),_0x35ca7c;}get['targetRect'](){const _0x365241=this['target'];if(null===_0x365241)return null;if(_0x365241 instanceof _0x2e5438)return _0x365241;const _0x498a98=_0x365241['filter'](_0x29ada1=>function(_0x33eefc){const _0x838488=_0x33eefc['offsetParent'];if(_0x838488)return!0x0;const _0x22415a=_0x33eefc['getClientRects']()['item'](0x0);return!!_0x22415a;}(_0x29ada1));return 0x0===_0x498a98['length']?null:new _0x2e5438(_0x498a98[0x0]['getClientRects']()['item'](0x0));}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x431abd){this['view']['isActive']=_0x431abd,this['view']['mainView']['isActive']=_0x431abd;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x3c1874){if(!(null===_0x3c1874||_0x3c1874 instanceof _0x2e5438||Array['isArray'](_0x3c1874)&&_0x3c1874['every'](_0x290f26=>ne(_0x290f26))))throw new _0x28de93('annotation-invalid-target',null,{'target':_0x3c1874});}['_getNormalizedTarget'](){const _0x172a2f='function'==typeof this['_target']?this['_target']():this['_target'];return ne(_0x172a2f)?[_0x172a2f]:_0x172a2f;}}function ne(_0x3ab31b){return null!==_0x3ab31b&&'object'==typeof _0x3ab31b&&'nodeType'in _0x3ab31b&&0x1===_0x3ab31b['nodeType'];}class x extends _0xc5674b{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x39e6fe=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x32f229(),this['_focusTracker']['on']('change:isFocused',(_0x568203,_0x582e22,_0x45cac0)=>{_0x45cac0||this['fire']('blur');});for(const _0x2443ce of _0x39e6fe)this['add'](_0x2443ce);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x2588c9){if(this['has'](_0x2588c9))throw new _0x28de93('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x2588c9['innerView'],_0x2588c9),this['_viewToAnnotation']['set'](_0x2588c9['view'],_0x2588c9);for(const _0x32f77b of _0x2588c9['focusableElements'])this['_focusTracker']['add'](_0x32f77b);this['listenTo'](_0x2588c9['focusableElements'],'add',(_0x80fab1,_0x47d84a)=>{this['_focusTracker']['add'](_0x47d84a);}),this['listenTo'](_0x2588c9['focusableElements'],'remove',(_0x2d4dcd,_0x421b35)=>{this['_focusTracker']['remove'](_0x421b35);}),this['listenTo'](_0x2588c9['view']['focusTracker'],'change:isFocused',(_0x5e228e,_0x393cbe,_0x456358)=>{_0x456358&&this['fire']('focus',_0x2588c9);}),_0x2588c9['updateTargetRect']();const _0x3672ac=this['_getOrderInContent'](_0x2588c9['view']['targetRect']);return super['add'](_0x2588c9,_0x3672ac);}['remove'](_0x4ce378){if(!this['has'](_0x4ce378))throw new _0x28de93('annotationcollection-not-existing-item',null);this['stopListening'](_0x4ce378['view']['focusTracker']),this['stopListening'](_0x4ce378['focusableElements']);for(const _0xd04cfa of _0x4ce378['focusableElements'])this['_focusTracker']['remove'](_0xd04cfa);return this['_viewToAnnotation']['delete'](_0x4ce378['view']),this['_innerViewToAnnotation']['delete'](_0x4ce378['innerView']),super['remove'](_0x4ce378);}['getByInnerView'](_0x599e99){return this['_innerViewToAnnotation']['get'](_0x599e99);}['getByView'](_0x41cb0f){return this['_viewToAnnotation']['get'](_0x41cb0f);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x4dedba of this)_0x4dedba['updateTargetRect']();this['_sort']();}['_sort'](){const _0x383bcf=Array['from'](this)['sort']((_0x387118,_0x214c76)=>v(_0x387118['view']['targetRect'],_0x214c76['view']['targetRect']));for(let _0x1c576e=_0x383bcf['length']-0x1;_0x1c576e>0x0;_0x1c576e--){const _0x3a31c2=_0x383bcf[_0x1c576e];_0x1c576e!==this['getIndex'](_0x3a31c2)&&(this['remove'](_0x3a31c2),this['add'](_0x3a31c2));}}['_getOrderInContent'](_0x16781d){let _0x4c206d=0x0;if(!_0x16781d)return this['length'];for(const _0x19cd33 of this){const _0x2915c2=_0x19cd33['view']['targetRect'];if(_0x2915c2){if(v(_0x16781d,_0x2915c2)<0x0)return _0x4c206d;_0x4c206d++;}}return _0x4c206d;}}function v(_0x4df721,_0x2bcc55){if(null===_0x4df721&&null===_0x2bcc55)return 0x0;if(null===_0x4df721)return-0x1;if(null===_0x2bcc55)return 0x1;const _0x14e563=_0x4df721['top']-_0x2bcc55['top'];return 0x0==_0x14e563?_0x4df721['left']-_0x2bcc55['left']:_0x14e563;}class N extends _0x3e81dd{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5143f3){if(super(_0x5143f3),this['collection']=new x(),this['_visibleAnnotations']=new x(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x5143f3 instanceof _0xff7e8f){const _0x3d6fe3=_0x5143f3['locale'];_0x5143f3['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':S(_0x3d6fe3,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x3bac84){this['collection']['add'](_0x3bac84);}['remove'](_0x5c68b0){this['collection']['remove'](_0x5c68b0),_0x5c68b0['destroy']();}['refreshVisibility'](){for(const _0x5782ed of this['collection'])_0x5782ed['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x277bad){return this['collection']['getByInnerView'](_0x277bad);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x1b0611 of this['collection'])_0x1b0611['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x93e05d){this['fire']('_activateAnnotation',_0x93e05d);}['createAnnotation'](_0x441f88){return new d(_0x441f88);}['createAnnotationView'](_0x4f8189,_0x570fac){return new T(_0x4f8189,_0x570fac);}['_addActiveAnnotation'](_0x323cb0){const _0x1a2530=new Set(this['activeAnnotations']);_0x1a2530['add'](_0x323cb0),this['activeAnnotations']=_0x1a2530;}['_removeActiveAnnotation'](_0x23d589){const _0x403d78=new Set(this['activeAnnotations']);_0x403d78['delete'](_0x23d589),this['activeAnnotations']=_0x403d78;}['_bindAnnotationsToVisibleAnnotations'](){const _0x3d7de6=this['collection'],_0x599cc1=this['_visibleAnnotations'];function _0xdf5d2a(_0x23b887){const _0x58c3ae=_0x23b887['source'];_0x58c3ae['isVisible']&&!_0x599cc1['has'](_0x58c3ae)?_0x599cc1['add'](_0x58c3ae):!_0x58c3ae['isVisible']&&_0x599cc1['has'](_0x58c3ae)&&_0x599cc1['remove'](_0x58c3ae),_0x58c3ae['view']['focusTracker']['remove'](_0x58c3ae['view']['element']),_0x58c3ae['view']['focusTracker']['add'](_0x58c3ae['view']['element']);}this['listenTo'](_0x3d7de6,'add',(_0x2a69d4,_0x599ef3)=>{_0x599ef3['isVisible']&&_0x599cc1['add'](_0x599ef3),this['listenTo'](_0x599ef3,'change:isVisible',_0xdf5d2a);}),this['listenTo'](_0x3d7de6,'remove',(_0x55d956,_0xd239a9)=>{_0x599cc1['has'](_0xd239a9)&&_0x599cc1['remove'](_0xd239a9),this['stopListening'](_0xd239a9,'change:isVisible',_0xdf5d2a);});}['_setupEnterAnnotationKeystroke'](){const _0x231073=_0x40eaf6=>{_0x40eaf6['on']('ready',()=>{_0x40eaf6['keystrokes']['set'](_0x153f39,(_0x4963bd,_0xc34a5)=>{const _0x51c3e5=_0x51e4e3(this['activeAnnotations']['values']());_0x51c3e5&&(_0x51c3e5['view']['focus'](),_0xc34a5());});});};this['context']instanceof _0xff7e8f?_0x231073(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x2006f0,_0x3c6d8b)=>{_0x231073(_0x3c6d8b);});}['_setupEscapeAnnotationHandling'](){const _0x3234dc=_0x1c1618=>{const _0x4373f8=_0x1c1618['source'],_0x17f398=[];let _0xb7aa8e;if(Array['isArray'](_0x4373f8['target'])){_0xb7aa8e=_0x4373f8['target'][0x0],this['context']instanceof _0xff7e8f?_0x17f398['push'](this['context']):this['context']['editors']&&_0x17f398['push'](...this['context']['editors']);for(const _0x386205 of _0x17f398)for(const _0x59e741 of _0x386205['editing']['view']['domRoots']['values']())if(_0x59e741['contains'](_0xb7aa8e))return void _0x386205['editing']['view']['focus']();_0xb7aa8e['focus']();}};this['listenTo'](this['collection'],'add',(_0x1f9386,_0x35d470)=>{this['listenTo'](_0x35d470,'escape',_0x3234dc,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x7e30dc,_0x43e832)=>{this['stopListening'](_0x43e832,'escape',_0x3234dc);});}}const gt=Symbol('noChannel'),Tt={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0};class o extends _0x3e81dd{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[N,ht,it];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xd92ea){super(_0xd92ea),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x4f3e64=this['context']['config'];_0x4f3e64['define']('comments.maxCommentsWhenCollapsed',0x2),_0x4f3e64['define']('comments.maxThreadTotalWeight',0x1f4),_0x4f3e64['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x4f3e64['define']('comments.CommentThreadView',Ct),_0x4f3e64['define']('comments.CommentView',vt),_0x4f3e64['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0xad309f=this['context']['plugins']['get'](N);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x26fe7a,_0x4a6ab9)=>this['_addCommentThread'](_0x4a6ab9)),this['on']('submitCommentThread',(_0x5a3b83,_0x425cd8)=>this['_submitCommentThread'](_0x425cd8)),this['on']('resolveCommentThread',(_0x2212c4,_0x62985e)=>this['_resolveCommentThread'](_0x62985e)),this['on']('resolveCommentThread',(_0x430ff5,_0x2542a9)=>this['_updateActiveAnnotation'](_0x2542a9),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x96886b,_0x47597b)=>this['_reopenCommentThread'](_0x47597b)),this['on']('reopenCommentThread',(_0x272d9e,_0x8c2518)=>this['_updateActiveAnnotation'](_0x8c2518),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x4bd937,_0x9e80be)=>this['_removeCommentThread'](_0x9e80be)),this['on']('updateCommentThread',(_0x35ba26,_0x38d723)=>this['_updateCommentThread'](_0x38d723)),this['on']('updateCommentThread',(_0x211856,_0x56ed77)=>this['_updateActiveAnnotation'](_0x56ed77),{'priority':'lowest'}),this['on']('addComment',(_0x3c8ee4,_0x1055a1)=>this['_addComment'](_0x1055a1)),this['on']('updateComment',(_0x376812,_0x1d8bfb)=>this['_updateComment'](_0x1d8bfb)),this['on']('removeComment',(_0x16d370,_0x364d69)=>this['_removeComment'](_0x364d69)),this['on']('addComment',(_0x3c08f8,{threadId:_0x42753a,isFromAdapter:_0x264856})=>{if(_0x264856)return;const _0x220f74=this['getCommentThread'](_0x42753a),_0x102e14=_0x220f74&&this['_threadToController']['get'](_0x220f74);_0x102e14&&_0x102e14['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0xad309f,'change:activeAnnotations',(_0x329445,_0x781786,_0x320f01)=>{const _0x3c1a11=Array['from'](_0x320f01)['map'](_0x382731=>this['_viewToController']['get'](_0x382731['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x3c1a11?_0x3c1a11['model']:null;});}set['adapter'](_0x50a2d2){if(this['_adapter'])throw new _0x28de93('commentsrepository-adapter-already-set');this['_adapter']=_0x50a2d2;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x5ec6c0=gt,threadId:_0x3fc4df=_0x494a46(),comments:_0x585f97=[],unlinkedAt:_0x549a75=null,resolvedAt:_0x4dd11b=null,resolvedBy:_0x5aaaee=null,target:_0x1b9c05=null,context:_0x295447=null,attributes:_0x32510a={},isResolvable:_0x1cdd0f=!0x0,isSubmitted:_0x1caf27=!0x1,isFromAdapter:_0x58d924=!0x1}={}){return this['fire'](_t('addCommentThread',_0x5ec6c0),{'channelId':_0x5ec6c0,'threadId':_0x3fc4df,'comments':_0x585f97,'unlinkedAt':_0x549a75,'resolvedAt':_0x4dd11b,'resolvedBy':_0x5aaaee,'target':_0x1b9c05,'context':_0x295447,'attributes':_0x32510a,'isFromAdapter':_0x58d924,'isResolvable':_0x1cdd0f,'isSubmitted':_0x1caf27}),this['getCommentThread'](_0x3fc4df);}['openNewCommentThread']({channelId:_0x54a3e0=gt,threadId:_0x58a44=_0x494a46(),target:_0x423ab5,context:_0x2842ec=null,isResolvable:_0x544b6d=!0x0}){if(this['_readOnlyChannels']['has'](_0x54a3e0)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x423ab5)throw new _0x28de93('commentsrepository-missing-target');const _0x2fce71=this['addCommentThread']({'channelId':_0x54a3e0,'threadId':_0x58a44,'target':_0x423ab5,'context':_0x2842ec,'isResolvable':_0x544b6d});if(!_0x2fce71)return null;const _0x33d005=this['_threadToController']['get'](_0x2fce71),_0x879945=_0x33d005['view']['commentThreadInputView']['commentInputView'],_0x2b3bd5=this['context']['plugins']['get'](N),_0x507e2f=_0x2b3bd5['getByInnerView'](_0x33d005['view']);return _0x2b3bd5['activate'](_0x507e2f),_0x879945['once']('editorReady',()=>_0x879945['focus']()),_0x2fce71;}['hasCommentThread'](_0x5dc743){if('string'!=typeof _0x5dc743)throw new _0x28de93('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x5dc743);}['updateCommentThread']({channelId:_0x5745f0=gt,threadId:_0x5ac523,context:_0x50886c,unlinkedAt:_0x5616be,attributes:_0x399edc,isFromAdapter:_0x46f5b9=!0x1}){return this['fire'](_t('updateCommentThread',_0x5745f0),{'channelId':_0x5745f0,'threadId':_0x5ac523,'context':_0x50886c,'unlinkedAt':_0x5616be,'attributes':_0x399edc,'isFromAdapter':_0x46f5b9}),this['getCommentThread'](_0x5ac523);}['getCommentThread'](_0x5632f6){if('string'!=typeof _0x5632f6)throw new _0x28de93('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x5632f6);}['fetchCommentThread']({channelId:_0x3d8b3a,threadId:_0x28b11e}={}){const _0x2cf742=this['getCommentThread'](_0x28b11e);if(_0x2cf742)return Promise['resolve'](_0x2cf742);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x28de93('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x3d8b3a,'threadId':_0x28b11e})['then'](_0x57049a=>this['hasCommentThread'](_0x28b11e)?this['getCommentThread'](_0x28b11e):_0x57049a?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x3d8b3a},_0x57049a)):void 0x0)['catch'](_0x268ce0=>{throw console['error'](_0x268ce0),new _0x28de93('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x3d9f29,skipNotAttached:_0x1833c6=!0x1,skipEmpty:_0x5cf3b7=!0x1,toJSON:_0xed2fff=!0x1}={}){const _0x5c1574=[];for(const _0x415f9e of this['_threads']['values']())_0x3d9f29&&_0x415f9e['channelId']!==_0x3d9f29||_0x1833c6&&!_0x415f9e['isAttached']||_0x5cf3b7&&0x0===_0x415f9e['length']||_0x5c1574['push'](_0x415f9e);return _0xed2fff?_0x5c1574['map'](_0xd43d03=>_0xd43d03['toJSON']()):_0x5c1574;}['setActiveCommentThread'](_0x813ba3){const _0x12979c=this['context']['plugins']['get'](N);if(!_0x813ba3)return void(this['activeCommentThread']&&_0x12979c['deactivateAll']());const _0xcb3852=this['getCommentThread'](_0x813ba3);if(!_0xcb3852)throw new _0x28de93('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x813ba3});if(!this['_threadToController']['has'](_0xcb3852))throw new _0x28de93('commentsrepository-active-not-attached',null,{'threadId':_0x813ba3});const _0x2f77c4=_0x12979c['getByInnerView'](this['_threadToController']['get'](_0xcb3852)['view']);_0x12979c['activate'](_0x2f77c4);}['switchReadOnly'](_0x1e405f,_0x4d7d03){_0x1e405f?this['_readOnlyChannels']['add'](_0x4d7d03):this['_readOnlyChannels']['delete'](_0x4d7d03),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x4158d7){return this['_readOnlyChannels']['has'](_0x4158d7)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x2cdf7f,_0x292f2b){return new yt(_0x2cdf7f,_0x292f2b);}['setPermissions'](_0x592338,_0x29649f=gt){this['_permissions']['set'](_0x29649f,_0x592338),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x169464=gt){return this['_permissions']['has'](_0x169464)?this['_permissions']['get'](_0x169464):Tt;}['_addCommentThread']({channelId:_0x23f9cc,threadId:_0x30d693,comments:_0xedfd1c,unlinkedAt:_0x423849,resolvedAt:_0x357206,resolvedBy:_0x2c43fe,target:_0x2c2261,context:_0x4c8399,attributes:_0x42207b,isFromAdapter:_0x49efcc,isResolvable:_0x54224a,isSubmitted:_0x5ca569}){if('string'!=typeof _0x30d693)throw new _0x28de93('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x30d693});if(this['hasCommentThread'](_0x30d693))throw new _0x28de93('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x30d693});const _0x4867c5=new oe(this,{'channelId':_0x23f9cc,'id':_0x30d693,'context':_0x4c8399,'attributes':_0x42207b,'unlinkedAt':_0x423849,'resolvedAt':_0x357206,'resolvedBy':_0x2c43fe?this['context']['plugins']['get'](it)['getUser'](_0x2c43fe):null,'isResolvable':_0x54224a,'isSubmitted':_0x5ca569||_0x49efcc});this['_threads']['set'](_0x30d693,_0x4867c5);for(const _0x585025 of _0xedfd1c)_0x4867c5['_add'](this['_createNewComment']({'threadId':_0x30d693,..._0x585025}));return _0x2c2261&&_0x4867c5['attachTo'](_0x2c2261),_0x49efcc||!_0x4867c5['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x23f9cc,'threadId':_0x30d693});}['_submitCommentThread']({channelId:_0xdac162,threadId:_0x57be69}){if(!this['hasCommentThread'](_0x57be69))throw new _0x28de93('commentsrepository-missing-comment-thread',this);const _0x2c6a36=this['getCommentThread'](_0x57be69);if(_0x2c6a36['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x3ce2d5,comments:_0x5d7991,resolvedAt:_0x50e854,resolvedBy:_0x4a14b3,context:_0xb4dac1,attributes:_0x6ce066}=_0x2c6a36,_0xfc94dd=this['context']['plugins']['get']('PendingActions'),_0x4196e3=_0xfc94dd['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0xdac162,'threadId':_0x3ce2d5,'comments':_0x5d7991['map'](_0x43017f=>_0x43017f['toJSON']()),'resolvedAt':_0x50e854,'resolvedBy':_0x4a14b3?_0x4a14b3['id']:_0x4a14b3,'context':_0xb4dac1,'attributes':_0x6ce066})['then'](({comments:_0x4db99d})=>{_0xfc94dd['remove'](_0x4196e3);for(const _0x4b796f of _0x4db99d)this['_updateComment']({'channelId':_0xdac162,'threadId':_0x57be69,'commentId':_0x4b796f['commentId'],'createdAt':_0x4b796f['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x5a216a=>{throw console['error'](_0x5a216a),new _0x28de93('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x6737f5,target:_0x2884e4}){const _0x4ba568=this['getCommentThread'](_0x6737f5);if(!_0x4ba568)throw new _0x28de93('commentsrepository-attach-missing-comment-thread',this);const _0x134071=this['context']['plugins']['get']('PendingActions'),_0xedc55d=this['context']['plugins']['get'](N),_0x2e119e=this['_createCommentThreadView'](_0x4ba568),_0x340425=new yt(_0x4ba568,_0x2e119e);let _0x302694=null;_0x2e119e['on']('change:isDirty',(_0x438d60,_0x58665f,_0x27b266)=>{_0x27b266?_0x302694=_0x134071['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x302694&&(_0x134071['remove'](_0x302694),_0x302694=null);}),this['_threadToController']['set'](_0x4ba568,_0x340425),this['_viewToController']['set'](_0x2e119e,_0x340425);const _0x5d92b7=new T(this['context']['locale'],_0x2e119e);_0x5d92b7['bind']('length')['to'](_0x2e119e),_0x5d92b7['bind']('isDirty')['to'](_0x2e119e,'isDirty',_0x2e119e,'length',(_0x5a509d,_0x45bec4)=>_0x5a509d||!_0x45bec4),_0x5d92b7['bind']('isActive')['to'](_0x2e119e),_0x5d92b7['type']='comment';const _0x4ef1e7=new d({'view':_0x5d92b7,'target':_0x2884e4,'type':'comment','isVisible':!_0x4ba568['isResolved']});return _0x2e119e['on']('escape',()=>{_0x4ef1e7['fire']('escape');}),this['_bindAnnotationToEditors'](_0x2e119e,_0x4ef1e7),_0xedc55d['add'](_0x4ef1e7),_0x4ef1e7;}['_bindAnnotationToEditors'](_0x684f5,_0x49df1b){this['listenTo'](_0x684f5,'editorReady',(_0x59c007,_0x44df44)=>{const _0x1355c4=_0x44df44['ui']['view']['body']['bodyCollectionContainer'];_0x49df1b['focusableElements']['add'](_0x1355c4),this['context']instanceof _0xff7e8f&&this['context']['ui']['focusTracker']['add'](_0x1355c4);},{'priority':'highest'}),this['listenTo'](_0x684f5,'editorDestroyed',(_0x3d532b,_0x4c2cf3)=>{const _0xe1c8ca=_0x4c2cf3['ui']['view']['body']['bodyCollectionContainer'];_0x49df1b['focusableElements']['has'](_0xe1c8ca)&&_0x49df1b['focusableElements']['remove'](_0xe1c8ca),this['context']instanceof _0xff7e8f&&this['context']['ui']['focusTracker']['remove'](_0xe1c8ca);});}['_unbindEditors'](_0x5a1470){this['stopListening'](_0x5a1470,'editorReady'),this['stopListening'](_0x5a1470,'editorDestroyed');}['_createCommentThreadView'](_0xeb4c97){const _0x5353bf=this['context']['plugins']['get'](it),{config:_0x2dced5,locale:_0x56197f}=this['context'],_0x2377dd=mt(_0x2dced5['get']('locale'));return new(0x0,(_0x2dced5['get']('comments'))['CommentThreadView'])(_0x56197f,_0xeb4c97,_0x5353bf['me'],{'editorConfig':{..._0x2dced5['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x2dced5['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x2dced5['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x2dced5['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x2dced5['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x2377dd,'CommentView':_0x2dced5['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x4ee061,channelId:_0x5b51d8,resolvedAt:_0x9ae654,resolvedBy:_0x2f64fb,isFromAdapter:_0x231eaf}){if(!this['hasCommentThread'](_0x4ee061))throw new _0x28de93('commentsrepository-missing-comment-thread',null,{'threadId':_0x4ee061});const _0x3977d7=this['getCommentThread'](_0x4ee061);if(_0x3977d7['isResolved'])throw new _0x28de93('commentsrepository-resolved-comment-thread',null,{'threadId':_0x4ee061});const _0x2a9eba=this['context']['plugins']['get'](it);if(_0x3977d7['resolvedBy']=_0x2a9eba['getUser'](_0x2f64fb),_0x3977d7['resolvedAt']=_0x9ae654,_0x231eaf||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x1c3c9b=this['context']['plugins']['get']('PendingActions'),_0x538160=_0x1c3c9b['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x5b51d8,'threadId':_0x4ee061})['then'](({resolvedAt:_0x4cd2b6,resolvedBy:_0x560d81})=>{_0x1c3c9b['remove'](_0x538160),_0x3977d7['resolvedBy']['id']!==_0x560d81&&(_0x3977d7['resolvedBy']=_0x2a9eba['getUser'](_0x560d81)),_0x3977d7['resolvedAt']=_0x4cd2b6;})['catch'](_0x5b86a0=>{throw console['error'](_0x5b86a0),new _0x28de93('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x347b6e,channelId:_0x205732,isFromAdapter:_0xc934f0}){if(!this['hasCommentThread'](_0x347b6e))throw new _0x28de93('commentsrepository-missing-comment-thread',null,{'threadId':_0x347b6e});const _0x598bb0=this['getCommentThread'](_0x347b6e);if(!_0x598bb0['isResolved'])throw new _0x28de93('commentsrepository-reopen-comment-thread',null,{'threadId':_0x347b6e});if(_0x598bb0['resolvedBy']=null,_0x598bb0['resolvedAt']=null,_0xc934f0||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0xcba835=this['context']['plugins']['get']('PendingActions'),_0x345c63=_0xcba835['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x205732,'threadId':_0x347b6e})['then'](()=>_0xcba835['remove'](_0x345c63))['catch'](_0x1ceb4a=>{throw console['error'](_0x1ceb4a),new _0x28de93('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x1a39b0,isFromAdapter:_0x1c2f8b}){const _0x564f11=this['getCommentThread'](_0x1a39b0);if(!_0x564f11)throw new _0x28de93('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x1a39b0),this['_threads']['delete'](_0x1a39b0),!_0x564f11['isSubmitted']||_0x1c2f8b||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x5c6450=this['context']['plugins']['get']('PendingActions'),{channelId:_0x2fb0f0}=_0x564f11,_0x23c9be=_0x5c6450['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x2fb0f0,'threadId':_0x1a39b0})['then'](()=>_0x5c6450['remove'](_0x23c9be))['catch'](_0xcbda7b=>{throw console['error'](_0xcbda7b),new _0x28de93('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0xfe4101,unlinkedAt:_0x574410,context:_0x203728,attributes:_0x1d65ed,isFromAdapter:_0x1e1c7c}){if('string'!=typeof _0xfe4101)throw new _0x28de93('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0xfe4101});if(!this['hasCommentThread'](_0xfe4101))throw new _0x28de93('commentsrepository-missing-comment-thread',null,{'threadId':_0xfe4101});const _0x3eb446=this['getCommentThread'](_0xfe4101);let _0x2c3441=!0x1;if(void 0x0!==_0x203728&&_0x3eb446['context']!==_0x203728&&(_0x3eb446['context']=_0x203728,_0x2c3441=!0x0),void 0x0!==_0x574410&&_0x3eb446['unlinkedAt']!==_0x574410&&(_0x3eb446['unlinkedAt']=_0x574410,_0x2c3441=!0x0),_0x1d65ed&&!It(_0x1d65ed,_0x3eb446['attributes'])&&(_0x3eb446['attributes']=_0x1d65ed,_0x2c3441=!0x0),!_0x2c3441)return Promise['resolve']();if(!_0x3eb446['isSubmitted']||_0x1e1c7c||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x21b0fd=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3dd0ec}=_0x3eb446,_0x149485=_0x21b0fd['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x3dd0ec,'threadId':_0xfe4101,'context':_0x203728,'unlinkedAt':_0x574410,'attributes':_0x1d65ed})['then'](()=>_0x21b0fd['remove'](_0x149485))['catch'](_0xfa84ff=>{throw console['error'](_0xfa84ff),new _0x28de93('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x5c836d){const _0x225441=this['context']['plugins']['get'](N),_0x499abc=this['getCommentThread'](_0x5c836d);if(this['_threadToController']['has'](_0x499abc)){const _0x26acc4=this['_threadToController']['get'](_0x499abc),_0x466497=_0x26acc4['view'],_0x1513cd=_0x225441['getByInnerView'](_0x466497);this['_threadToController']['delete'](_0x499abc),this['_viewToController']['delete'](_0x466497),_0x1513cd&&_0x225441['remove'](_0x1513cd),_0x26acc4['destroy'](),_0x466497['destroy']()['then'](()=>{this['_unbindEditors'](_0x466497);});}}['_updateActiveAnnotation']({threadId:_0x2db66f,resolvedAt:_0xac583d}){const _0x58a801=!!_0xac583d,_0xdaabfc=this['context']['plugins']['get'](N),_0x56da95=this['getCommentThread'](_0x2db66f);if(this['_threadToController']['has'](_0x56da95)){const _0x5efad2=this['_threadToController']['get'](_0x56da95)['view'],_0x5f30ef=_0xdaabfc['getByInnerView'](_0x5efad2);_0x5f30ef&&(_0x58a801&&_0xdaabfc['_removeActiveAnnotation'](_0x5f30ef),_0x5f30ef['refreshVisibility']());}}['_getExternalAuthor'](_0x1c10c4){const _0x36091c=this['context']['plugins']['get'](it),_0x12eaf1=lt('external:'+_0x1c10c4),_0x3f04c5=_0x36091c['getUser'](_0x12eaf1);return _0x3f04c5||_0x36091c['addUser']({'id':_0x12eaf1,'name':_0x1c10c4});}['_createNewComment']({threadId:_0x38abd9,commentId:_0x5e2025=_0x494a46(),content:_0x3c389a,authorId:_0x2ff8b4,createdAt:_0x2caa72,attributes:_0x345419}){if('string'!=typeof _0x5e2025)throw new _0x28de93('commentsrepository-invalid-commentid');if('string'!=typeof _0x2ff8b4)throw new _0x28de93('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x3c389a||!_0x3c389a['trim']())throw new _0x28de93('commentsrepository-invalid-comment-content');const _0x2fbec=this['context']['plugins']['get'](it)['getUser'](_0x2ff8b4);if(!_0x2fbec)throw new _0x28de93('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x2ff8b4});let _0x47da6e=null,_0x7c60a7=_0x2caa72;return _0x345419&&_0x345419['@external']&&(_0x47da6e=this['_getExternalAuthor'](_0x345419['@external']['authorName']),_0x7c60a7=new Date(_0x345419['@external']['createdAt'])),new re(this,{'threadId':_0x38abd9,'id':_0x5e2025,'author':_0x47da6e||_0x2fbec,'creator':_0x2fbec,'content':_0x3c389a,'createdAt':_0x2caa72,'authoredAt':_0x7c60a7,'attributes':_0x345419});}['_addComment'](_0x296b55){let {threadId:_0x1c7789,content:_0x57e528,attributes:_0x3f1588,isFromAdapter:_0x55722b}=_0x296b55;const _0x17d378=this['getCommentThread'](_0x296b55['threadId']);if(!_0x17d378)throw new _0x28de93('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x197301=this['_createNewComment'](_0x296b55),{id:_0x4438e3}=_0x197301;if(_0x17d378['_add'](_0x197301),_0x55722b||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x17d378['isSubmitted'])return Promise['resolve']();const _0x3adc6a=this['context']['plugins']['get']('PendingActions'),{channelId:_0xe25566}=_0x17d378,_0x3a399f=_0x3adc6a['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x3f1588||(_0x3f1588={}),this['adapter']['addComment']({'channelId':_0xe25566,'threadId':_0x1c7789,'commentId':_0x4438e3,'content':_0x57e528,'attributes':_0x3f1588})['then'](_0x35d4dc=>{_0x3adc6a['remove'](_0x3a399f),_0x35d4dc&&this['_updateComment']({'channelId':_0xe25566,'threadId':_0x1c7789,'commentId':_0x4438e3,'createdAt':_0x35d4dc['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x3a8d69=>{throw console['error'](_0x3a8d69),new _0x28de93('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x1c03d6,commentId:_0x801382,content:_0xcb3392,createdAt:_0x49cd6e,attributes:_0xbef46f,isFromAdapter:_0x40fc88}){if(void 0x0!==_0xcb3392&&('string'!=typeof _0xcb3392||!_0xcb3392['trim']()['length']))throw new _0x28de93('commentsrepository-update-comment-invalid-content');const _0x4dbd65=this['getCommentThread'](_0x1c03d6),_0x54e14c=_0x4dbd65['getComment'](_0x801382);if(!_0x54e14c)throw new _0x28de93('commentsrepository-update-missing-comment',this);let _0x8dd221=!0x1;if(_0xcb3392&&_0xcb3392!==_0x54e14c['content']&&(_0x54e14c['isEditable']||_0x40fc88)&&(_0x54e14c['content']=_0xcb3392,_0x8dd221=!0x0),_0x49cd6e&&_0x49cd6e!==_0x54e14c['createdAt']&&(_0x54e14c['createdAt']=_0x49cd6e,_0x54e14c['attributes']&&_0x54e14c['attributes']['@external']||(_0x54e14c['authoredAt']=_0x49cd6e),_0x8dd221=!0x0),_0xbef46f&&!It(_0xbef46f,_0x54e14c['attributes'])&&(_0x54e14c['attributes']=_0xbef46f,_0x8dd221=!0x0),!_0x8dd221)return Promise['resolve']();if(_0x4dbd65['fire']('commentUpdated'),_0x40fc88||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x49a04a=this['context']['plugins']['get']('PendingActions'),{channelId:_0x4bf34b}=this['getCommentThread'](_0x54e14c['threadId']),_0x5c16b8=_0x49a04a['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x4bf34b,'threadId':_0x1c03d6,'commentId':_0x801382,'content':_0xcb3392,'attributes':_0xbef46f})['then'](()=>_0x49a04a['remove'](_0x5c16b8))['catch'](_0xf5d2ea=>{throw console['error'](_0xf5d2ea),new _0x28de93('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x2b4044,commentId:_0x512a95,isFromAdapter:_0x2a88e1}){const _0x4fc7aa=this['getCommentThread'](_0x2b4044),_0x3c8b87=_0x4fc7aa['getComment'](_0x512a95);if(!_0x3c8b87)throw new _0x28de93('commentsrepository-remove-missing-comment',this);if(_0x4fc7aa['_remove'](_0x3c8b87),_0x2a88e1||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x207ea4=this['context']['plugins']['get']('PendingActions'),{channelId:_0x3cf5ea}=_0x4fc7aa,_0x474146=_0x207ea4['add'](S(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x3cf5ea,'threadId':_0x2b4044,'commentId':_0x512a95})['then'](()=>_0x207ea4['remove'](_0x474146))['catch'](_0x3cae0d=>{throw console['error'](_0x3cae0d),new _0x28de93('commentsrepository-remove-comment-internal-error',this);});}}class oe extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x4137b1(){['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x5769f4,_0x1ead5e){super();const _0x315b38=_0x1ead5e['isResolvable'];this['channelId']=_0x1ead5e['channelId'],this['id']=_0x1ead5e['id'],this['comments']=new _0xc5674b(),this['_repository']=_0x5769f4,this['_isAttached']=!0x1,this['_isSubmitted']=_0x1ead5e['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x5769f4,'_permissions',_0x5769f4,'_readOnlyChannels',()=>_0x5769f4['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x5769f4,'_permissions',()=>_0x5769f4['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x5769f4,'_permissions',()=>{const _0x5803f2=_0x5769f4['getPermissions'](this['channelId']);return _0x5803f2['write']||_0x5803f2['admin'];}),this['bind']('isResolvable')['to'](_0x5769f4,'_permissions',()=>_0x315b38&&_0x5769f4['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x1ead5e['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x2c2f4e,_0x654d2e)=>_0x2c2f4e?_0x654d2e?_0x2c2f4e<_0x654d2e?_0x2c2f4e:_0x654d2e:_0x2c2f4e:_0x654d2e),this['set']('unlinkedAt',_0x1ead5e['unlinkedAt']||null),this['set']('resolvedAt',_0x1ead5e['resolvedAt']||null),this['set']('resolvedBy',_0x1ead5e['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x1b35f1=>!!_0x1b35f1),this['set']('attributes',_0x1ead5e['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x172a4d,_0x33b116)=>_0x172a4d+_0x33b116['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x1c84d5,id:_0x320f6c}=this;this['_repository']['fire'](_t('submitCommentThread',_0x1c84d5),{'channelId':_0x1c84d5,'threadId':_0x320f6c});}['setUnlinkedAt'](_0x5a2178){this['_update']({'unlinkedAt':_0x5a2178});}['resolve']({resolvedAt:_0x385d04=new Date(),resolvedBy:_0xfdfb78=null,isFromAdapter:_0x4c5bce=!0x1}={}){const _0x12b11b=this['_repository']['context']['plugins']['get'](it)['me'],{channelId:_0x406e90,id:_0x4ee3a2}=this;this['_repository']['fire'](_t('resolveCommentThread',_0x406e90),{'channelId':_0x406e90,'threadId':_0x4ee3a2,'resolvedAt':_0x385d04,'resolvedBy':_0xfdfb78||_0x12b11b['id'],'isFromAdapter':_0x4c5bce});}['reopen']({isFromAdapter:_0x111779=!0x1}={}){const {channelId:_0x4a5585,id:_0x2a9f2d}=this;this['_repository']['fire'](_t('reopenCommentThread',_0x4a5585),{'channelId':_0x4a5585,'threadId':_0x2a9f2d,'isFromAdapter':_0x111779});}['setContext'](_0xd21789){this['context']||this['_update']({'context':_0xd21789});}['setAttribute'](_0x42ee46,_0x398e3e){const _0x23b6f3=pt(this['attributes']);wt(_0x23b6f3,_0x42ee46,_0x398e3e),this['_update']({'attributes':_0x23b6f3});}['removeAttribute'](_0x544474){const _0x18beb2=pt(this['attributes']);At(_0x18beb2,_0x544474),this['_update']({'attributes':_0x18beb2});}['remove']({isFromAdapter:_0x3a06ac=!0x1}={}){const {channelId:_0x37c3db,id:_0x26dd13}=this;this['_repository']['fire'](_t('removeCommentThread',_0x37c3db),{'channelId':_0x37c3db,'threadId':_0x26dd13,'isFromAdapter':_0x3a06ac});}['attachTo'](_0x22111e){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x22111e});}['addComment'](_0x45d349){const {channelId:_0x1b4904,id:_0x4cad7d}=this;this['_repository']['fire'](_t('addComment',_0x1b4904,_0x4cad7d),Object['assign']({'channelId':_0x1b4904,'threadId':_0x4cad7d},_0x45d349));}['getComment'](_0x3895c4){if('string'!=typeof _0x3895c4)throw new _0x28de93('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x3895c4});return this['comments']['get'](_0x3895c4);}['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'](_0x39811d=>_0x39811d['toJSON']()),'attributes':this['attributes']};}['_add'](_0xfb0d6){return this['listenTo'](_0xfb0d6,'change:authoredAt',()=>{const _0x39862d=this['_findOptimalIndex'](_0xfb0d6),_0x248ba4=this['comments'];_0x39862d-0x1!=_0x248ba4['getIndex'](_0xfb0d6)&&_0x39862d+0x1!=_0x248ba4['getIndex'](_0xfb0d6)&&(this['_remove'](_0xfb0d6),this['_add'](_0xfb0d6));}),this['comments']['add'](_0xfb0d6,this['_findOptimalIndex'](_0xfb0d6));}['_update'](_0x2bfdf1){const {channelId:_0x468f5a,id:_0x2debad}=this;this['_repository']['fire'](_t('updateCommentThread',_0x468f5a),{..._0x2bfdf1,'channelId':_0x468f5a,'threadId':_0x2debad});}['_remove'](_0x489d67){return this['stopListening'](_0x489d67),_0x489d67['destroy'](),this['comments']['remove'](_0x489d67);}['_findOptimalIndex'](_0xe92577){const _0x2c1685=this['comments']['find'](_0x566d7a=>new Date(_0x566d7a['authoredAt'])['getTime']()>new Date(_0xe92577['authoredAt'])['getTime']());return _0x2c1685?this['comments']['getIndex'](_0x2c1685):this['length'];}}class re extends/* #__PURE__ -- @preserve */
|
|
31
|
+
_0x4137b1(){['id'];['threadId'];['author'];['creator'];['isExternal'];['createdAt'];['_repository'];constructor(_0x50673a,_0x6aa44f){super();const _0x1e1627=_0x50673a['context']['plugins']['get'](it)['me'],_0x37c8eb=_0x50673a['getCommentThread'](_0x6aa44f['threadId']),_0x748a52=0x0===_0x37c8eb['comments']['length'],_0x512bd6=_0x1e1627===_0x6aa44f['author'];this['id']=_0x6aa44f['id'],this['threadId']=_0x6aa44f['threadId'],this['author']=_0x6aa44f['author'],this['creator']=_0x6aa44f['creator'],this['isExternal']=Boolean(_0x6aa44f['attributes']&&_0x6aa44f['attributes']['@external']),this['set']('content',_0x6aa44f['content']),this['createdAt']=_0x6aa44f['createdAt']||new Date(),this['set']('authoredAt',_0x6aa44f['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x37c8eb,'resolvedAt'),this['set']('attributes',_0x6aa44f['attributes']||{}),this['bind']('isEditable')['to'](_0x50673a,'_permissions',()=>{const _0x59e086=_0x50673a['getPermissions'](_0x37c8eb['channelId'])['write'],_0x26247a=_0x50673a['getPermissions'](_0x37c8eb['channelId'])['modifyAll'];return _0x512bd6&&_0x59e086||!_0x512bd6&&_0x26247a;}),this['bind']('isRemovable')['to'](_0x37c8eb,'isRemovable',_0x50673a,'_permissions',_0x5157ad=>{const _0x2abd2f=_0x50673a['getPermissions'](_0x37c8eb['channelId'])['write'],_0x309971=_0x50673a['getPermissions'](_0x37c8eb['channelId'])['modifyAll'];return _0x512bd6&&_0x2abd2f||_0x5157ad&&_0x748a52||!_0x512bd6&&_0x309971&&!_0x748a52;}),this['bind']('isReadOnly')['to'](_0x37c8eb,'isReadOnly'),this['_repository']=_0x50673a;}get['weight'](){return Math['max'](function(_0x49959a){const _0x1527b2=document['createElement']('div');return _0x1527b2['innerHTML']=_0x49959a,_0x1527b2['textContent']['length'];}(this['content']),0xc8);}['update'](_0x537644){const {threadId:_0x2bf02c,id:_0x982cfb}=this;if(!this['_repository']['hasCommentThread'](_0x2bf02c))throw new _0x28de93('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x2d4451}=this['_repository']['getCommentThread'](_0x2bf02c);this['_repository']['fire'](_t('updateComment',_0x2d4451,_0x2bf02c),{'channelId':_0x2d4451,'threadId':_0x2bf02c,'commentId':_0x982cfb,..._0x537644});}['setAttribute'](_0x1f7cb0,_0x31770a){const _0x1a7025=pt(this['attributes']);wt(_0x1a7025,_0x1f7cb0,_0x31770a),this['update']({'attributes':_0x1a7025});}['removeAttribute'](_0x8cd5d5){const _0x1d3308=pt(this['attributes']);At(_0x1d3308,_0x8cd5d5),this['update']({'attributes':_0x1d3308});}['remove'](_0x1bb246={}){if(!_0x1bb246['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x5977ff,id:_0x4286cf}=this;if(!this['_repository']['hasCommentThread'](_0x5977ff))throw new _0x28de93('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x5520e3}=this['_repository']['getCommentThread'](_0x5977ff);this['_repository']['fire'](_t('removeComment',_0x5520e3,_0x5977ff),{'channelId':_0x5520e3,'threadId':_0x5977ff,'commentId':_0x4286cf,..._0x1bb246});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}}function _t(_0x4d0b13,..._0x577bba){for(const _0x2890b2 of _0x577bba)void 0x0!==_0x2890b2&&(_0x4d0b13+=':'+String(_0x2890b2));return _0x4d0b13;}class J extends _0x572075{['refresh'](){const _0x3cbd01=this['editor']['model']['document']['selection'];for(const _0x124828 of _0x3cbd01['getRanges']())if(this['_hasContent'](_0x124828))return void(this['isEnabled']=!0x0);this['isEnabled']=!0x1;}['execute']({threadId:_0x2b1bea=_0x494a46()}={}){const _0x442daf=this['editor']['model'],_0x36be80=[];for(const _0x5d0c33 of _0x442daf['document']['selection']['getRanges']())this['_hasContent'](_0x5d0c33)&&_0x36be80['push'](this['_trimToContent'](_0x5d0c33));_0x442daf['change'](_0x35702a=>{for(const _0x22021a of _0x36be80){const _0x2b251c=_0x494a46()['substr'](0x1,0x5),_0x4427cc='comment:'+_0x2b1bea+':'+_0x2b251c;_0x35702a['addMarker'](_0x4427cc,{'range':_0x22021a,'usingOperation':!0x1,'affectsData':!0x1});}});}['_hasContent'](_0x3182a8){for(const _0x35cd53 of _0x3182a8['getItems']())if(this['_itemIsContent'](_0x35cd53))return!0x0;return!0x1;}['_itemIsContent'](_0x1f5a74){return _0x1f5a74['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x1f5a74)&&!_0x1f5a74['is']('element','tableCell');}['_trimToContent'](_0x18e4fb){const _0x2f9712=_0x4edead=>!this['_itemIsContent'](_0x4edead['item']),_0x319ee0=_0x18e4fb['start']['getLastMatchingPosition'](_0x2f9712),_0x123018=_0x18e4fb['end']['getLastMatchingPosition'](_0x2f9712,{'direction':'backward'});return this['editor']['model']['createRange'](_0x319ee0,_0x123018);}}class P extends _0x21992c{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[N];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3ce825){super(_0x3ce825),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x148d70=this['editor'],_0xf90d23=_0x148d70['model']['document']['selection'],_0x37b4ee=_0x3c02bb(()=>this['refreshSelectedViews'](),0xa);_0xf90d23['on']('change:range',(_0x26e308,_0x350cca)=>{_0x350cca['directChange']&&(_0x37b4ee['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x148d70['editing']['view']['document'],'change:isFocused',(_0x44dfb6,_0x5d4262,_0x438da2)=>{_0x438da2&&_0x37b4ee();}),this['listenTo'](_0x148d70['ui']['focusTracker'],'change:isFocused',(_0x59dac9,_0x526db4,_0x44a5dc)=>{_0x44a5dc||_0x148d70['isReadOnly']||this['fire']('blur',{'isAnnotationTracked':_0x371e6b=>this['_editorAnnotationsData']['has'](_0x371e6b['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x28ec3f){if(this['_editorAnnotations']['has'](_0x28ec3f['view']))return;this['_editorAnnotations']['add'](_0x28ec3f['view']),this['editor']['ui']['focusTracker']['add'](_0x28ec3f['view']['element']);const _0x4710de=this['editor']['plugins']['get'](N);this['listenTo'](_0x4710de['collection'],'remove',(_0x43f3a3,_0x315af3)=>{this['editor']['ui']['focusTracker']['remove'](_0x315af3['view']['element']),this['_editorAnnotations']['delete'](_0x315af3['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x35b082){if('function'!=typeof _0x35b082)throw new _0x28de93('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x35b082);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x4864b6,annotations:_0xc4c2d4}){const _0x1b3d24=[],_0x4c6cb4=this['editor']['model']['document']['selection'],_0x23a9c3=Array['from'](_0x4c6cb4['getRanges']());for(const [_0x5f3a15,_0x483661]of this['_editorAnnotationsData']){const _0x44b038=_0x45149c(_0x483661),_0x439470=_0xc4c2d4['getByInnerView'](_0x5f3a15);_0x44b038&&_0x439470&&_0x1b3d24['push']({'annotation':_0x439470,'range':_0x44b038});}function _0x45149c(_0x45b4a5){for(const _0x33ecdc of _0x45b4a5)for(const _0x7613b of _0x23a9c3)if(_0x33ecdc['containsRange'](_0x7613b,!_0x4c6cb4['isCollapsed']))return _0x33ecdc;return null;}return _0x1b3d24['sort']((_0x15596d,_0x1b5445)=>{const _0x21c3b8=_0x15596d['range'],_0x3b3704=_0x1b5445['range'];if(!_0x21c3b8['isEqual'](_0x3b3704)){if(_0x21c3b8['containsRange'](_0x3b3704,!0x0))return 0x1;if(_0x3b3704['containsRange'](_0x21c3b8,!0x0))return-0x1;}return _0x15596d['annotation']==_0x4864b6?-0x1:_0x1b5445['annotation']==_0x4864b6?0x1:0x0;})['map'](_0x275d95=>_0x275d95['annotation']);}get['_editorAnnotationsData'](){const _0x4b5607=new Map();for(const _0x4e7f96 of Array['from'](this['_dataCollectors']))for(const [_0x12a9ce,_0x2bc253]of _0x4e7f96())_0x4b5607['set'](_0x12a9ce,_0x2bc253);return _0x4b5607;}}class st extends _0x21992c{['afterInit'](){const _0x4ffa1d=this['editor'];if(!_0x4ffa1d['plugins']['has']('RestrictedEditingModeEditing'))return;_0x4ffa1d['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}}class ct extends _0x21992c{constructor(_0x4e962b){super(_0x4e962b),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x6ec2ae=this['editor'],_0x55253e=_0x6ec2ae['commands']['get']('importWord'),_0x86f4da=_0x6ec2ae['plugins']['get'](it);_0x55253e&&(_0x55253e['on']('execute',(_0x48c988,[,_0x80bf91])=>{_0x80bf91['collaboration_features']={'comments':!0x0,'user_id':_0x86f4da['me']['id']};},{'priority':Wt['high']+0xa}),this['listenTo'](_0x55253e,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x2658d5,_0x3642c3){const {comment_threads:_0x332508}=_0x3642c3;_0x332508&&_0x332508['forEach'](({thread_id:_0x111ffb,comments:_0x4f5e9a,is_resolved:_0x4c1050})=>{const _0x4c6ef9=new Date(),_0x313823=_0x4f5e9a['map'](({author:_0x3e8455,content:_0x199893,created_at:_0x3af0e6})=>({'content':_0x199893,'authorId':this['editor']['plugins']['get'](it)['me']['id'],'createdAt':_0x4c6ef9,'attributes':{'@external':{'authorName':_0x3e8455,'createdAt':_0x3af0e6?new Date(_0x3af0e6):new Date(),'source':'importWord'}}})),_0x23ea4a=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](o)['addCommentThread']({'channelId':_0x23ea4a,'threadId':_0x111ffb,'comments':_0x313823,'resolvedAt':_0x4c1050?_0x4c6ef9:null});});}}class at extends _0x21992c{constructor(_0x564d98){super(_0x564d98),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[Mt,Pt];}['afterInit'](){const _0x478521=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x478521,'contentInsertion',(_0x599e86,_0x1508fc)=>this['_removeMarkersWithoutThreads'](_0x1508fc['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x108a30){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x108a30;const _0x52205a=this['editor']['plugins']['get']('CommentsRepository');for(const _0x366a22 of _0x108a30['keys']()){const [_0x127fc1,_0x23cc1e]=_0x366a22['split'](':');'comment'!=_0x127fc1||_0x52205a['hasCommentThread'](_0x23cc1e)||_0x108a30['delete'](_0x366a22);}return _0x108a30;}['_registerMarkerInClipboardPipeline'](){const _0x113579=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x5ae5db=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x5ae5db&&_0x113579['_registerMarkerToCopy']('comment',_0x5ae5db);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x1bb1a8){switch(_0x1bb1a8){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}}class r extends _0x21992c{static get['requires'](){return[o,P,it,st,ct,at];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x129c7e){super(_0x129c7e),this['set']('isThreadsLoadingPaused',!0x0),_0x129c7e['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x40c84f,_0x19059e,_0x3409f2,_0x495001)=>{const _0x54b1f1=_0x3409f2?he(_0x3409f2)['id']:null;if(_0x129c7e['model']['change'](()=>{if(_0x54b1f1){const _0xe038e6=this['getAllMarkersForId'](_0x54b1f1);for(const _0x4bb60b of _0xe038e6)_0x129c7e['editing']['reconvertMarker'](_0x4bb60b);}if(_0x495001){const {id:_0x2b6c7b}=he(_0x495001),_0xc66512=this['getAllMarkersForId'](_0x2b6c7b);for(const _0xcc2e82 of _0xc66512)_0x129c7e['editing']['reconvertMarker'](_0xcc2e82);}}),_0x54b1f1){const _0x39674a=_0x129c7e['plugins']['get'](o)['getCommentThread'](_0x54b1f1);_0x39674a&&_0x39674a['isResolved']&&this['scrollToThreadMarker'](_0x54b1f1);}}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x370688=this['editor'],_0x53a7ab=_0x370688['plugins']['get'](o),_0x2c5ace=_0x370688['config']['get']('collaboration.channelId');_0x370688['commands']['add']('addCommentThread',new J(_0x370688)),this['listenTo'](_0x370688,'change:isReadOnly',(_0x1579a2,_0x3455b0,_0x427714)=>{_0x53a7ab['switchReadOnly'](_0x427714,_0x370688['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x53a7ab,ut('addCommentThread',_0x2c5ace),(_0x1fb8ae,{threadId:_0x340e4a})=>{const _0x1b7079=this['editor']['plugins']['get'](o)['getCommentThread'](_0x340e4a);_0x1b7079&&_0x1b7079['unlinkedAt']&&this['_attachArchivedThread'](_0x340e4a);}),this['listenTo'](_0x53a7ab,ut('removeCommentThread',_0x2c5ace),(_0x56ad7e,{threadId:_0x45608b})=>{_0x370688['model']['enqueueChange']({'isUndoable':!0x1},_0x3d6841=>{const _0x164373=this['getAllMarkersForId'](_0x45608b);for(const _0x1517aa of _0x164373)_0x3d6841['removeMarker'](_0x1517aa);});}),this['listenTo'](_0x53a7ab,ut('resolveCommentThread',_0x2c5ace),(_0x50253b,{threadId:_0x2b3ba9})=>{(this['_reconvertMarkers'](_0x2b3ba9),this['editor']['editing']['view']['hasDomSelection'])&&(this['editor']['plugins']['get'](o)['getCommentThread'](_0x2b3ba9)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x53a7ab,ut('reopenCommentThread',_0x2c5ace),(_0xcb8b7c,{threadId:_0x2eac6d})=>{this['_reconvertMarkers'](_0x2eac6d);},{'priority':'low'}),this['listenTo'](_0x53a7ab,ut('addComment',_0x2c5ace),(_0x311cfe,{threadId:_0x19a6f7,isFromAdapter:_0xf87b3f})=>{const _0x184393=this['getAllMarkersForId'](_0x19a6f7);if(_0xf87b3f||0x0==_0x184393['length']||!_0x53a7ab['hasCommentThread'](_0x19a6f7))return;0x1===_0x53a7ab['getCommentThread'](_0x19a6f7)['length']&&_0x370688['model']['enqueueChange']({'isUndoable':!0x1},_0xbfce74=>{for(const _0x150860 of _0x184393)_0xbfce74['updateMarker'](_0x150860,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove']();}['afterInit'](){!async function(_0x4c6969){const _0x30f42f=_0x228153([0x50,0x76,0x70,0x43,0x6d,0x58,0x68,0x41,0x75,0x5a,0x59,0x79,0x73,0x51,0x71,0x4d,0x61,0x6a,0x44,0x78,0x32,0x39,0x46,0x37,0x48,0x53,0x62,0x38,0x57,0x4f,0x4b,0x64,0x4e,0x67,0x72,0x52,0x6f,0x31,0x6e,0x74,0x6b,0x35,0x47,0x36,0x4a,0x56,0x69,0x65,0x63,0x30,0x6c,0x34,0x55,0x33,0x45,0x7a,0x4c,0x66,0x77,0x49,0x42,0x54]),_0x4bb805=0x2cf76b42,_0x46a6d0=0x2cf03ca2^_0x4bb805,_0x141c75=window[_0x228153([0x44,0x61,0x74,0x65])][_0x228153([0x6e,0x6f,0x77])](),_0x4b2fd9=_0x4c6969[_0x228153([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4e38e4=new window[(_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4de5cc=>{_0x4b2fd9[_0x228153([0x6f,0x6e,0x63,0x65])](_0x228153([0x72,0x65,0x61,0x64,0x79]),_0x4de5cc);}),_0x3be310={[_0x228153([0x6b,0x74,0x79])]:_0x228153([0x45,0x43]),[_0x228153([0x75,0x73,0x65])]:_0x228153([0x73,0x69,0x67]),[_0x228153([0x63,0x72,0x76])]:_0x228153([0x50,0x2d,0x32,0x35,0x36]),[_0x228153([0x78])]:_0x228153([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]),[_0x228153([0x79])]:_0x228153([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]),[_0x228153([0x61,0x6c,0x67])]:_0x228153([0x45,0x53,0x32,0x35,0x36])},_0x44aac5=_0x4b2fd9[_0x228153([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x228153([0x67,0x65,0x74])](_0x228153([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3282cd(){let _0x47edda,_0x4ab542=null,_0x4ba472=null;try{if(_0x44aac5==_0x228153([0x47,0x50,0x4c]))return _0x228153([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x47edda=_0x398fe5(),!_0x47edda)return _0x228153([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x47edda[_0x228153([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x4ba472=_0x3110b1(_0x47edda[_0x228153([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x47edda[_0x228153([0x6a,0x74,0x69])])),await _0x773259()?_0xb7c96()?_0x12527a()?_0x228153([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x353fbe()?(_0x47edda[_0x228153([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x228153([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4ab542=_0x333939(_0x228153([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x47edda[_0x228153([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x228153([0x74,0x72,0x69,0x61,0x6c])&&(_0x4ab542=_0x333939(_0x228153([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x47edda[_0x228153([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x228153([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x4ab542=_0x333939(_0x228153([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1d28fb()):_0x228153([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x228153([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x228153([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x50dfe3){return _0x228153([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x12527a(){const _0x22e3a1=[_0x228153([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x228153([0x74,0x72,0x69,0x61,0x6c])][_0x228153([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x47edda[_0x228153([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x141c75/0x3e8:0xe10*_0x46a6d0;return _0x47edda[_0x228153([0x65,0x78,0x70])]<_0x22e3a1;}function _0xb7c96(){const _0x109fbd=_0x47edda[_0x228153([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x109fbd&&(!!_0x109fbd[_0x228153([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x228153([0x2a]))||(!!_0x109fbd[_0x228153([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x228153([0x43,0x4d,0x54]))||!(!_0x109fbd[_0x228153([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x228153([0x52,0x43,0x4d,0x54]))||!_0x4d3e1a())));}function _0x353fbe(){const _0x43b613=_0x47edda[_0x228153([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x43b613||0x0==_0x43b613[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2e1b47}=new URL(window[_0x228153([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x43b613[_0x228153([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e1b47))return!0x0;const _0x5084ae=_0x2e1b47[_0x228153([0x73,0x70,0x6c,0x69,0x74])](_0x228153([0x2e]));return _0x43b613[_0x228153([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x340141=>_0x340141[_0x228153([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x228153([0x2a])))[_0x228153([0x6d,0x61,0x70])](_0x459dbf=>_0x459dbf[_0x228153([0x73,0x70,0x6c,0x69,0x74])](_0x228153([0x2e])))[_0x228153([0x73,0x6f,0x6d,0x65])](_0x702f01=>_0x5084ae[_0x228153([0x65,0x76,0x65,0x72,0x79])]((_0x241007,_0x4e6111)=>_0x702f01[_0x4e6111]===_0x241007||_0x702f01[_0x4e6111]===_0x228153([0x2a])));}function _0x1d28fb(){return _0x4ab542&&_0x4ba472?new window[(_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x488f65,_0x4d9d5e)=>{_0x4ab542[_0x228153([0x74,0x68,0x65,0x6e])](_0x488f65,_0x4d9d5e),_0x4ba472[_0x228153([0x74,0x68,0x65,0x6e])](_0x5c2194=>{_0x5c2194!=_0x228153([0x56,0x61,0x6c,0x69,0x64])&&_0x488f65(_0x5c2194);},_0x4d9d5e);}):_0x4ab542||_0x4ba472||_0x228153([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3110b1(_0x59f7f3,_0x3d014b){return new window[(_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x191aaa=>{if(_0x3c3666())return _0x191aaa(_0x228153([0x56,0x61,0x6c,0x69,0x64]));_0x477d1e(),_0x4b2fd9[_0x228153([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x228153([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x2a737b=!0x1;const _0x3269b6=_0x494a46();function _0x4a0c27(_0x3f25df){return!!_0x3f25df&&(typeof _0x3f25df===_0x228153([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3f25df===_0x228153([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3f25df[_0x228153([0x74,0x68,0x65,0x6e])]===_0x228153([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3f25df[_0x228153([0x63,0x61,0x74,0x63,0x68])]===_0x228153([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1dc9d8(_0x2d5e10){_0x39e5a4(_0x2d5e10)[_0x228153([0x74,0x68,0x65,0x6e])](_0xd46138=>{if(!_0xd46138||_0xd46138[_0x228153([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x228153([0x6f,0x6b]))return _0x228153([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x4af623(_0x51b84d(_0x3269b6+_0x3d014b))!=_0xd46138[_0x228153([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x228153([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x228153([0x56,0x61,0x6c,0x69,0x64]);})[_0x228153([0x74,0x68,0x65,0x6e])](_0x17a7d1=>(_0x2884d9(),_0x17a7d1),()=>{const _0x37a282=_0xd102c6();return null==_0x37a282?(_0x2884d9(),_0x228153([0x56,0x61,0x6c,0x69,0x64])):_0x228153(_0x141c75-_0x37a282>(0x8fbef42^_0x4bb805)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x228153([0x74,0x68,0x65,0x6e])](_0x191aaa)[_0x228153([0x63,0x61,0x74,0x63,0x68])](()=>{_0x191aaa(_0x228153([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x495524=0x2cc185c2^_0x4bb805;function _0x2884d9(){const _0x40fc27=_0x228153([0x6c,0x6c,0x63,0x74,0x2d])+_0x4af623(_0x51b84d(_0x59f7f3)),_0x4115c5=_0x33e56f(_0x4af623(window[_0x228153([0x4d,0x61,0x74,0x68])][_0x228153([0x63,0x65,0x69,0x6c])](_0x141c75/_0x495524)));window[_0x228153([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x228153([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x40fc27,_0x4115c5);}function _0xd102c6(){const _0x6a7370=_0x228153([0x6c,0x6c,0x63,0x74,0x2d])+_0x4af623(_0x51b84d(_0x59f7f3)),_0x222390=window[_0x228153([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x228153([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x6a7370);return _0x222390?window[_0x228153([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x33e56f(_0x222390),0x10)*_0x495524:null;}function _0x39e5a4(_0x470005){return new window[(_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1393af,_0x5d5932)=>{_0x470005[_0x228153([0x74,0x68,0x65,0x6e])](_0x1393af,_0x5d5932),window[_0x228153([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5d5932,0x2cf6bf82^_0x4bb805);});}}_0x4b2fd9[_0x228153([0x6f,0x6e])](_0x228153([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x45d1fb,_0x361814)=>{if(_0x361814[0x0]!=_0x59f7f3)return _0x191aaa(_0x228153([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x361814[0x1]={..._0x361814[0x1],[_0x228153([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3269b6};},{[_0x228153([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x228153([0x68,0x69,0x67,0x68])}),_0x4b2fd9[_0x228153([0x6f,0x6e])](_0x228153([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x169ded=>{_0x4a0c27(_0x169ded[_0x228153([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x2a737b=!0x0,_0x1dc9d8(_0x169ded[_0x228153([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x228153([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x228153([0x6c,0x6f,0x77])}),_0x4e38e4[_0x228153([0x74,0x68,0x65,0x6e])](()=>{_0x2a737b||_0x191aaa(_0x228153([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3c3666(){return _0x4b2fd9[_0x228153([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x228153([0x76,0x69,0x65,0x77])][_0x228153([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x228153([0x61,0x75,0x74,0x6f]);}function _0x477d1e(){_0x4b2fd9[_0x228153([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x228153([0x76,0x69,0x65,0x77])][_0x228153([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x228153([0x61,0x75,0x74,0x6f]);}}function _0x333939(_0x4fde33){const _0x246e39=[new window[(_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1fa0c9=>setTimeout(_0x1fa0c9,0x2cfe558e^_0x4bb805)),_0x4e38e4[_0x228153([0x74,0x68,0x65,0x6e])](()=>new window[(_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x470859=>{let _0x27d791=0x0;_0x4b2fd9[_0x228153([0x6d,0x6f,0x64,0x65,0x6c])][_0x228153([0x6f,0x6e])](_0x228153([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x51d8de,_0x22392e)=>{_0x22392e[0x0][_0x228153([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x27d791++,_0x27d791==(0x2cf76aba^_0x4bb805)&&(_0x470859(),_0x51d8de[_0x228153([0x6f,0x66,0x66])]());});}))];return window[_0x228153([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x228153([0x72,0x61,0x63,0x65])](_0x246e39)[_0x228153([0x74,0x68,0x65,0x6e])](()=>_0x4fde33);}async function _0x545e57(){await _0x4e38e4,_0x4b2fd9[_0x228153([0x6d,0x6f,0x64,0x65,0x6c])][_0x228153([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x54f21a,_0x4b2fd9[_0x228153([0x6d,0x6f,0x64,0x65,0x6c])][_0x228153([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x54f21a,_0x4b2fd9[_0x228153([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x228153([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4d3e1a(){return _0x3cff1a(_0x228153([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x379275(_0x228153([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x228153([0x73,0x74,0x61,0x74,0x65])]==_0x228153([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x60dff6(_0x198f55){const _0x18c392=_0x197f11();_0x4b2fd9[_0x18c392]=_0x228153([0x63,0x6f,0x6d,0x6d,0x65,0x6e,0x74,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x198f55,_0x198f55!=_0x228153([0x56,0x61,0x6c,0x69,0x64])&&_0x545e57();}function _0x197f11(){const _0x4d070f=window[_0x228153([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x228153([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x228153([0x6e,0x6f,0x77])]())[_0x228153([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x228153([0x2e]),'');let _0x10a6c6=_0x228153([0x50]);for(let _0x564347=0x0;_0x564347<_0x4d070f[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x564347+=0x2){let _0x384c63=window[_0x228153([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4d070f[_0x228153([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x564347,_0x564347+0x2));_0x384c63>=_0x30f42f[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x384c63-=_0x30f42f[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x10a6c6+=_0x30f42f[_0x384c63];}return _0x10a6c6;}function _0x398fe5(){const _0x21f3e0=_0x44aac5[_0x228153([0x73,0x70,0x6c,0x69,0x74])](_0x228153([0x2e]));if(0x3!=_0x21f3e0[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x34fdee(_0x21f3e0[0x1]);function _0x34fdee(_0x90edd8){const _0x34ab17=_0x1ceabc(_0x90edd8);return _0x34ab17&&_0x39af15()?_0x34ab17:null;function _0x39af15(){const _0x317361=_0x34ab17[_0x228153([0x6a,0x74,0x69])],_0x2618eb=window[_0x228153([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x317361[_0x228153([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x317361[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x19b375={..._0x34ab17,[_0x228153([0x6a,0x74,0x69])]:_0x317361[_0x228153([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x317361[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x19b375[_0x228153([0x76,0x63])],_0x51b84d(_0x19b375)==_0x2618eb;}}}async function _0x773259(){let _0x1e47b9=!0x0;try{const _0x279046=_0x44aac5[_0x228153([0x73,0x70,0x6c,0x69,0x74])](_0x228153([0x2e])),[_0x45df03,_0x1d83d7,_0x48e5e9]=_0x279046;return _0xcd0268(_0x45df03),await _0x2b705a(_0x45df03,_0x1d83d7,_0x48e5e9),_0x1e47b9;}catch(_0x19ccda){return!0x1;}function _0xcd0268(_0x404f7b){const _0x42ad6a=_0x1ceabc(_0x404f7b);_0x42ad6a&&_0x42ad6a[_0x228153([0x61,0x6c,0x67])]==_0x228153([0x45,0x53,0x32,0x35,0x36])||(_0x1e47b9=!0x1);}async function _0x2b705a(_0x19e338,_0x5cbf6b,_0x1a34d7){const _0x5e3e99=window[_0x228153([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x228153([0x66,0x72,0x6f,0x6d])](_0x121d6e(_0x1a34d7),_0x1403f8=>_0x1403f8[_0x228153([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x12ece1=new window[(_0x228153([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x228153([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x19e338+_0x228153([0x2e])+_0x5cbf6b),_0x4b2d15=window[_0x228153([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x228153([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4b2d15)return;const _0x292d55=await _0x4b2d15[_0x228153([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x228153([0x6a,0x77,0x6b]),_0x3be310,{[_0x228153([0x6e,0x61,0x6d,0x65])]:_0x228153([0x45,0x43,0x44,0x53,0x41]),[_0x228153([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x228153([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x228153([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4b2d15[_0x228153([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x228153([0x6e,0x61,0x6d,0x65])]:_0x228153([0x45,0x43,0x44,0x53,0x41]),[_0x228153([0x68,0x61,0x73,0x68])]:{[_0x228153([0x6e,0x61,0x6d,0x65])]:_0x228153([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x292d55,_0x5e3e99,_0x12ece1)||(_0x1e47b9=!0x1);}}function _0x1ceabc(_0x5ca8eb){return _0x5ca8eb[_0x228153([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x228153([0x65,0x79]))?JSON[_0x228153([0x70,0x61,0x72,0x73,0x65])](_0x121d6e(_0x5ca8eb)):null;}function _0x121d6e(_0x1ffc05){return window[_0x228153([0x61,0x74,0x6f,0x62])](_0x1ffc05[_0x228153([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x228153([0x2b]))[_0x228153([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x228153([0x2f])));}function _0x51b84d(_0x3f92b3){let _0x43df6b=0x1505;function _0x1114b0(_0x124237){for(let _0x652aa9=0x0;_0x652aa9<_0x124237[_0x228153([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x652aa9++){const _0x2c66c0=_0x124237[_0x228153([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x652aa9);_0x43df6b=(_0x43df6b<<0x5)+_0x43df6b+_0x2c66c0,_0x43df6b&=_0x43df6b;}}function _0x496c3c(_0x7fb3d0){Array[_0x228153([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x7fb3d0)?_0x7fb3d0[_0x228153([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x496c3c):_0x7fb3d0&&typeof _0x7fb3d0==_0x228153([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x228153([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x7fb3d0)[_0x228153([0x73,0x6f,0x72,0x74])]()[_0x228153([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x45aa2e,_0x5c33ca])=>{_0x1114b0(_0x45aa2e),_0x496c3c(_0x5c33ca);}):_0x1114b0(window[_0x228153([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x7fb3d0));}return _0x496c3c(_0x3f92b3),_0x43df6b>>>0x0;}function _0x4af623(_0x1045c0){return _0x1045c0[_0x228153([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x228153([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x228153([0x30]));}function _0x33e56f(_0x259b66){return _0x259b66[_0x228153([0x73,0x70,0x6c,0x69,0x74])]('')[_0x228153([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x228153([0x6a,0x6f,0x69,0x6e])]('');}function _0x3cff1a(_0x2aaab0){return _0x4b2fd9[_0x228153([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x228153([0x68,0x61,0x73])](_0x2aaab0);}function _0x379275(_0x402341){return _0x4b2fd9[_0x228153([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x228153([0x67,0x65,0x74])](_0x402341);}function _0x54f21a(){}function _0x228153(_0x207243){return _0x207243['map'](_0x3622a1=>String['fromCharCode'](_0x3622a1))['join']('');}_0x60dff6(await _0x3282cd());}(this);}['destroy'](){const _0x9b4a75=this['editor']['plugins']['get'](o),_0x1bdc66=this['editor']['config']['get']('collaboration.channelId');for(const _0x592ecb of _0x9b4a75['getCommentThreads']({'channelId':_0x1bdc66}))_0x9b4a75['_detachCommentThread'](_0x592ecb['id']),_0x9b4a75['_threads']['delete'](_0x592ecb['id']);super['destroy']();}['hasMarkerForId'](_0x1df304){return this['getAllMarkersForId'](_0x1df304)['length']>0x0;}['getAllMarkersForId'](_0x5561ab){const _0x7c83ad=[];for(const _0xa0f1a2 of this['editor']['model']['markers'])_0xa0f1a2['name']['startsWith']('comment:'+_0x5561ab)&&_0x7c83ad['push'](_0xa0f1a2);return _0x7c83ad;}['scrollToThreadMarker'](_0x36d493){const _0xa0df2f=this['_getTargetForId'](_0x36d493);_0xa0df2f&&setTimeout(()=>{this['activeMarker']&&he(this['activeMarker'])['id']===_0x36d493&&rt({'target':_0xa0df2f[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x4ff258){this['editor']['model']['change'](()=>{for(const _0xe3271b of this['getAllMarkersForId'](_0x4ff258))this['editor']['editing']['reconvertMarker'](_0xe3271b);});}['_attachArchivedThread'](_0x26b5f1){const _0x173365=this['editor']['plugins']['get'](o),_0x290ed7=this['editor']['plugins']['get'](P),_0x1ee5c7=_0x173365['getCommentThread'](_0x26b5f1);if(!_0x1ee5c7['isAttached']){const _0x1f76f4=_0x1ee5c7['attachTo'](()=>this['_getTargetForId'](_0x1ee5c7['id']));_0x290ed7['registerAnnotation'](_0x1f76f4),_0x1ee5c7['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x311580=this['editor'],_0x41d19b=_0x311580['plugins']['get'](it);_0x311580['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x54fcbc,_0x2e5770)=>{const {id:_0x5d3783}=he(_0x54fcbc['markerName']),_0x2c563b=_0x311580['plugins']['get'](o)['getCommentThread'](_0x5d3783),_0x28887e=this['activeMarker']&&he(this['activeMarker'])['id']===_0x5d3783;let _0x350344;if(_0x2c563b&&_0x2c563b['isResolved']&&!_0x28887e&&_0x54fcbc['item'])return _0x2e5770['consumable']['consume'](_0x54fcbc['item'],'addMarker:'+_0x54fcbc['markerName']),_0x2e5770['consumable']['consume'](_0x54fcbc['item'],'removeMarker:'+_0x54fcbc['markerName']),null;const _0xf9e321=['ck-comment-marker'];return _0x28887e&&_0xf9e321['push']('ck-comment-marker--active'),_0x350344=_0x2c563b&&_0x2c563b['length']?_0x2c563b['comments']['first']['author']['id']:_0x41d19b['me']['id'],{'classes':_0xf9e321,'attributes':{'data-comment':_0x5d3783,'data-author-id':_0x350344}};}}),_0x311580['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x51666d,{options:_0x5af847})=>{const _0x3edb0c=_0x311580['plugins']['get'](o),_0x99c594=_0x311580['model']['markers']['get'](_0x51666d),{id:_0x7031b3,part:_0x28bdbc}=he(_0x51666d);if(_0x99c594&&!_0x99c594['affectsData'])return null;if(_0x5af847['ignoreResolvedComments']){const _0x588950=_0x3edb0c['getCommentThread'](_0x7031b3);if(_0x588950&&_0x588950['isResolved'])return null;}return{'group':'comment','name':_0x28bdbc?_0x7031b3+':'+_0x28bdbc:_0x7031b3};}}),_0x311580['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x5e1bf9,{writer:_0x5b88bd})=>_0x5b88bd['createElement']('$marker',{'data-name':'comment:'+_0x5e1bf9['getAttribute']('id')})}),_0x311580['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x16b686=this['editor'],_0x5683b1=_0x16b686['plugins']['get'](o),_0x15de84=new Set(),_0x33537d=new Set();_0x16b686['model']['document']['registerPostFixer'](_0x55126c=>{let _0xcc0c8=!0x1;for(const {name:_0x7520bc,data:_0x41c77b}of _0x16b686['model']['document']['differ']['getChangedMarkers']()){const {group:_0x248560,id:_0x58c7fe}=he(_0x7520bc);let _0x86c1a7=_0x41c77b['newRange'];if('comment'!==_0x248560||!_0x86c1a7)continue;const _0x2d4126='$graveyard'===_0x86c1a7['root']['rootName'];_0x2d4126||(_0x86c1a7=ft(_0x86c1a7,_0x16b686['model']),!_0x86c1a7||_0x86c1a7['isCollapsed']||!_0x41c77b['newRange']||_0x86c1a7['isEqual'](_0x41c77b['newRange']))?_0x16b686['model']['hasContent'](_0x86c1a7)&&!_0x2d4126?this['isThreadsLoadingPaused']?_0x15de84['add'](_0x7520bc):this['_handleThreadMarker'](_0x7520bc,_0x58c7fe):(_0x33537d['add'](_0x7520bc),_0x15de84['delete'](_0x7520bc),_0x55126c['removeMarker'](_0x7520bc),_0xcc0c8=!0x0):(_0x55126c['updateMarker'](_0x7520bc,{'range':_0x86c1a7}),_0xcc0c8=!0x0);}return _0xcc0c8;}),this['on']('change:isThreadsLoadingPaused',(_0x305e50,_0x60b3e2,_0x55954d)=>{if(!_0x55954d&&_0x15de84['size'])for(const _0x3d1a2a of _0x15de84){const {id:_0x5e2e7b}=he(_0x3d1a2a);_0x15de84['delete'](_0x3d1a2a),_0x16b686['model']['markers']['get'](_0x3d1a2a)&&this['_handleThreadMarker'](_0x3d1a2a,_0x5e2e7b);}}),this['listenTo'](_0x16b686['model']['document'],'change',(_0x5c79ff,_0x4dabfa)=>{for(const {name:_0x4b32a7,data:{newRange:_0x31ce55}}of _0x16b686['model']['document']['differ']['getChangedMarkers']()){const {group:_0x5416be,id:_0x35a02e}=he(_0x4b32a7);if('comment'!==_0x5416be)continue;const _0x5b9a3e=_0x5683b1['getCommentThread'](_0x35a02e),_0x15ddd0=this['hasMarkerForId'](_0x35a02e);_0x5b9a3e&&(!_0x5b9a3e['_hasTargetInContent']&&_0x31ce55&&_0x16b686['editing']['view']['once']('render',()=>{const _0x491c57=_0x16b686['plugins']['get'](N),_0x4e14e1=_0x5683b1['_threadToController']['get'](_0x5b9a3e)['view'];_0x491c57['getByInnerView'](_0x4e14e1)['refreshVisibility']();},{'priority':'low'}),_0x5b9a3e['_hasTargetInContent']=_0x15ddd0||!!_0x31ce55),_0x31ce55||(_0x33537d['add'](_0x4b32a7),_0x15de84['delete'](_0x4b32a7));}if(_0x4dabfa['isLocal'])for(const _0x2af8ad of _0x33537d){const {id:_0x257226}=he(_0x2af8ad),_0x2670ae=_0x5683b1['getCommentThread'](_0x257226),_0x1f62d3=this['hasMarkerForId'](_0x257226);_0x15de84['delete'](_0x2af8ad),!_0x2670ae||_0x1f62d3||_0x2670ae['unlinkedAt']||_0x2670ae['setUnlinkedAt'](new Date());}_0x33537d['clear']();});}['_getTargetForId'](_0x20d6c7){const _0x53d949=this['editor'],_0x1d3466=this['getAllMarkersForId'](_0x20d6c7);return et(_0x53d949['editing'],_0x1d3466);}['_getTextContext'](_0x3d6e77){const _0x32a893=this['getAllMarkersForId'](_0x3d6e77);let _0x178c30='',_0x522ae6=!0x1;for(const _0x433a89 of _0x32a893){const _0x4b5f6d=_0x433a89['getRange']();for(const _0x46e5d3 of Array['from'](_0x4b5f6d['getItems']()))_0x46e5d3['is']('$textProxy')?(_0x178c30&&_0x522ae6&&(_0x178c30+='\x20',_0x522ae6=!0x1),_0x178c30+=_0x46e5d3['data']):_0x522ae6=!0x0;_0x522ae6=!0x0;}return _0x178c30['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x3d9bac,_0x21edde){const _0x335c79=this['editor'],_0x11589b=_0x335c79['plugins']['get'](o);let _0x14bec5=_0x11589b['getCommentThread'](_0x21edde);const _0x4d4c3e=_0x335c79['config']['get']('collaboration.channelId'),_0x35cf7e=_0x335c79['plugins']['get'](P);if(_0x14bec5&&(_0x14bec5['unlinkedAt']&&_0x14bec5['setUnlinkedAt'](null),_0x14bec5['isAttached']))return _0x14bec5;return!this['getAllMarkersForId'](_0x21edde)[0x0]['managedUsingOperations']?_0x335c79['editing']['view']['once']('render',()=>{if(_0x11589b['getCommentThread'](_0x21edde))return;const _0x230ebc=_0x335c79['plugins']['get'](N);_0x14bec5=_0x11589b['openNewCommentThread']({'channelId':_0x4d4c3e,'threadId':_0x21edde,'target':()=>this['_getTargetForId'](_0x21edde),'context':{'type':'text','value':this['_getTextContext'](_0x21edde)}});const _0x4497bf=_0x11589b['_threadToController']['get'](_0x14bec5)['view'],_0x3f35a1=_0x230ebc['getByInnerView'](_0x4497bf);_0x3f35a1&&_0x35cf7e['registerAnnotation'](_0x3f35a1);},{'priority':'low'}):_0x11589b['fetchCommentThread']({'channelId':_0x4d4c3e,'threadId':_0x21edde})['then'](_0x2031cc=>{if('destroyed'!==_0x335c79['state']){if(_0x14bec5=_0x2031cc,_0x14bec5&&!_0x14bec5['isAttached']){const _0x427936=_0x14bec5['attachTo'](()=>this['_getTargetForId'](_0x21edde));_0x35cf7e['registerAnnotation'](_0x427936),_0x14bec5['isResolved']&&this['_reconvertMarkers'](_0x21edde);}else{if(!_0x14bec5){const _0x5cff68=this['getAllMarkersForId'](_0x21edde);_0x335c79['model']['change'](_0x574ed1=>{for(const _0x91268a of _0x5cff68)_0x574ed1['removeMarker'](_0x91268a);});}}}}),_0x14bec5;}['_handleThreadMarker'](_0x36e12a,_0x1c3e47){const _0x15eaff=this['_attachMarkerToThread'](_0x36e12a,_0x1c3e47);_0x15eaff&&!_0x15eaff['context']&&_0x15eaff['setContext']({'type':'text','value':this['_getTextContext'](_0x1c3e47)});}['_initAriaMarkerChangeAnnouncements'](){const _0x4357bc=this['editor'];ot(_0x4357bc['model'],({left:_0x51ad28,entered:_0xa42608})=>{for(const _0x2342e5 of _0x51ad28)if(dt(_0x2342e5)){_0x4357bc['ui']['ariaLiveAnnouncer']['announce'](S(_0x4357bc['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x705fb8 of _0xa42608)if(dt(_0x705fb8)){_0x4357bc['ui']['ariaLiveAnnouncer']['announce'](S(_0x4357bc['locale'],'ENTER_COMMENT_ANNOUNCEMENT',nt(_0xe426d9)));break;}});}}function ut(_0x4b0e6f,_0x167219){return _0x167219?_0x4b0e6f+':'+_0x167219:_0x4b0e6f;}function he(_0x17d0bc){const _0x3f5a98=_0x17d0bc['split'](':');return{'group':_0x3f5a98[0x0],'id':_0x3f5a98[0x1],'part':_0x3f5a98[0x2]};}function ft(_0x1a3562,_0x145671){const _0x5aaa25=_0x145671['schema'],_0x407eef=_0x145671['createRange'](_0x1a3562['start']);for(const _0x4907a1 of _0x1a3562['getWalker']()){const {type:_0x5c972d,item:_0x1433ad,nextPosition:_0xc89726}=_0x4907a1;if('text'===_0x5c972d||_0x5aaa25['isObject'](_0x1433ad)){const _0x3253bd=_0x145671['createPositionBefore'](_0x1433ad);_0x407eef['isCollapsed']&&(_0x407eef['start']=_0x3253bd),_0x407eef['end']=_0xc89726;}}return _0x407eef;}function dt(_0x9e4caa){return'comment'===he(_0x9e4caa['name'])['group'];}var xt='<!--\x0a\x0a\x20What\x20you\x27re\x20currently\x20looking\x20at\x20is\x20the\x20source\x20code\x20of\x20a\x20legally\x20protected,\x20proprietary\x20software.\x0a\x20CKEditor\x205\x20Collaboration\x20is\x20licensed\x20under\x20a\x20commercial\x20license\x20and\x20protected\x20by\x20copyright\x20law.\x20Where\x20not\x20otherwise\x20indicated,\x0a\x20all\x20CKEditor\x205\x20Collaboration\x20content\x20is\x20authored\x20by\x20CKSource\x20engineers\x20and\x20consists\x20of\x20CKSource-owned\x20intellectual\x20property.\x0a\x0a\x20Copyright\x20(c)\x202003-2024,\x20CKSource\x20Holding\x20sp.\x20z\x20o.o.\x20All\x20rights\x20reserved.\x0a\x0a!-->\x0a\x0a<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M4\x201.5h12A3.5\x203.5\x200\x200\x201\x2019.5\x205v8l-.005.192a3.5\x203.5\x200\x200\x201-2.927\x203.262l-.062.008v1.813a1.5\x201.5\x200\x200\x201-2.193\x201.33l-.371-.193-.38-.212a13.452\x2013.452\x200\x200\x201-3.271-2.63l-.062-.07H4A3.5\x203.5\x200\x200\x201\x20.5\x2013V5A3.5\x203.5\x200\x200\x201\x204\x201.5ZM4\x203a2\x202\x200\x200\x200-2\x202v8a2\x202\x200\x200\x200\x202\x202h6.924a11.917\x2011.917\x200\x200\x200\x203.71\x203.081l.372.194v-3.268L14.962\x2015H16a2\x202\x200\x200\x200\x202-2V5a2\x202\x200\x200\x200-2-2H4Z\x22/><path\x20d=\x22M9.75\x205a.75.75\x200\x200\x200-.75.75v2.5H6.5a.75.75\x200\x200\x200\x200\x201.5H9v2.5a.75.75\x200\x200\x200\x201.5\x200v-2.5H13a.75.75\x200\x200\x200\x200-1.5h-2.5v-2.5A.75.75\x200\x200\x200\x209.75\x205Z\x22/></svg>\x0a';class i extends _0x21992c{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,r,P,N];}get['CommentsListView'](){return te;}get['CommentThreadInputView'](){return ie;}['init'](){const _0x364c48=this['editor'],_0x267484=_0x364c48['plugins']['get'](o),_0x2da6a6=_0x364c48['plugins']['get'](r),_0x19495a=_0x364c48['plugins']['get'](N),_0x5ac365=_0x364c48['plugins']['get'](P);_0x364c48['ui']['componentFactory']['add']('comment',()=>{const _0x46b2c4=this['_createUIButton'](_0x59646e);return _0x46b2c4['tooltip']=!0x0,_0x46b2c4;}),_0x364c48['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](_0x5c043a)),_0x5ac365['addSourceCollector'](()=>{const _0x566c46=[];for(const [_0x27a554,_0x1e01a5]of _0x267484['_threadToController']){const _0x5df4bd=_0x2da6a6['getAllMarkersForId'](_0x27a554['id']),_0x37e712=_0x5df4bd['map'](_0x178162=>_0x178162['getRange']());_0x5df4bd['length']>0x0&&_0x566c46['push']([_0x1e01a5['view'],_0x37e712]);}return _0x566c46;}),this['listenTo'](_0x19495a,'change:activeAnnotations',(_0x1e24c7,_0x422ed3,_0x4575c6)=>{const _0x428a72=Array['from'](_0x4575c6)['map'](_0x5b6127=>_0x5b6127['innerView'])['find'](_0x478047=>_0x267484['_viewToController']['has'](_0x478047));if(!_0x428a72)return void(_0x2da6a6['activeMarker']=null);const _0x1a1d5e=_0x267484['_viewToController']['get'](_0x428a72)['model']['id'],_0x2e9a02='comment:'+_0x1a1d5e;_0x1a1d5e&&_0x2da6a6['hasMarkerForId'](_0x1a1d5e)?_0x2da6a6['activeMarker']=_0x2e9a02:_0x2da6a6['activeMarker']&&(_0x2da6a6['activeMarker']=null);}),this['listenTo'](_0x267484,'removeCommentThread',(_0x29241d,{threadId:_0x882d06,isFromAdapter:_0x27238d})=>{!_0x27238d&&_0x364c48['ui']['focusTracker']['isFocused']&&_0x2da6a6['hasMarkerForId'](_0x882d06)&&_0x364c48['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x267484,'addComment',(_0x3d66d5,{threadId:_0x2bee30,isFromAdapter:_0x11047c})=>{if(_0x11047c||!_0x2da6a6['hasMarkerForId'](_0x2bee30)||!_0x267484['hasCommentThread'](_0x2bee30))return;0x1===_0x267484['getCommentThread'](_0x2bee30)['length']&&(_0x364c48['editing']['view']['focus'](),_0x3d66d5['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1b42fe=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2ef43d;for(const _0x50b806 in _0x1b42fe){const _0x2bf727=_0x50b806,_0x140e91=_0x1b42fe[_0x2bf727];if('commentsLicenseKeyValid'==_0x140e91||'commentsLicenseKeyInvalid'==_0x140e91||'commentsLicenseKeyExpired'==_0x140e91||'commentsLicenseKeyDomainLimit'==_0x140e91||'commentsLicenseKeyNotAllowed'==_0x140e91||'commentsLicenseKeyEvaluationLimit'==_0x140e91||'commentsLicenseKeyTrialLimit'==_0x140e91||'commentsLicenseKeyDevelopmentLimit'==_0x140e91||'commentsLicenseKeyUsageLimit'==_0x140e91){delete _0x1b42fe[_0x2bf727],_0x2ef43d=_0x140e91,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyTrialLimit'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('trialLimit'),'commentsLicenseKeyDevelopmentLimit'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('developmentLimit'),'commentsLicenseKeyUsageLimit'==_0x2ef43d&&_0x1b42fe['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0x1449d7){const _0x1251a5=this['editor'],_0x4ed8e4=new _0x1449d7(_0x1251a5['locale']),_0x298be0=_0x1251a5['commands']['get']('addCommentThread');return _0x4ed8e4['set']({'label':S(_0x1251a5['locale'],'Comment'),'icon':xt}),_0x4ed8e4['bind']('isEnabled')['to'](_0x298be0),this['listenTo'](_0x4ed8e4,'execute',()=>_0x298be0['execute']()),_0x4ed8e4;}}class s extends _0x21992c{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[r];}constructor(_0x4df038){super(_0x4df038),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x28bfab,_0x1a7d83,_0x18c006)=>{_0x18c006?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x1a5176,_0xf33215]of this['editor']['commands'])_0xf33215['affectsData']&&'addCommentThread'!==_0x1a5176&&_0xf33215['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode');const _0x322b3e=this['editor']['editing']['view']['document'];this['listenTo'](_0x322b3e,'cut',_0x20b153=>_0x20b153['stop'](),{'priority':'highest'}),this['listenTo'](_0x322b3e,'clipboardInput',_0x4a504d=>_0x4a504d['stop'](),{'priority':'highest'}),this['listenTo'](_0x322b3e,'delete',_0x5f15f6=>_0x5f15f6['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x314816,_0x362c07]of this['editor']['commands'])_0x362c07['affectsData']&&'addCommentThread'!==_0x314816&&_0x362c07['clearForceDisabled']('commentsOnlyMode');this['stopListening'](this['editor']['editing']['view']['document']);}}class M extends _0x3e81dd{['activeUIs'];['_uis'];['_uisData'];static get['requires'](){return[N];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5246ae){super(_0x5246ae),this['activeUIs']=new Set(),this['_uis']=new Map(),this['_uisData']=new Map();}['init'](){const _0x1f8ead=this['context']['plugins']['get'](N);this['listenTo'](_0x1f8ead,'_activateAnnotation',(_0x3d7088,_0x4579d3)=>{for(const _0x162931 of this['activeUIs']){const _0x313a39=this['_uis']['get'](_0x162931);(0x0,this['_uisData']['get'](_0x162931)['filter'])(_0x4579d3)&&_0x313a39['setActiveAnnotation'](_0x4579d3);}}),this['listenTo'](_0x1f8ead,'_deactivateAllAnnotations',()=>{for(const _0x154421 of this['activeUIs']){this['_uis']['get'](_0x154421)['setActiveAnnotation'](null);}}),this['listenTo'](_0x1f8ead['_visibleAnnotations'],'add',(_0x57abc6,_0xf315a3)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0xf315a3);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x4c3329){return this['activeUIs']['has'](_0x4c3329);}['activate'](_0x2f35dc,_0x3a8f90=()=>!0x0){const _0x5515ad=this['context']['plugins']['get'](N);if(!this['_uis']['has'](_0x2f35dc))throw new _0x28de93('annotationsuis-missing-ui',this,{'uiName':_0x2f35dc});this['isActive'](_0x2f35dc)&&this['deactivate'](_0x2f35dc),this['activeUIs']['add'](_0x2f35dc);const _0x472d83=new x();!function({source:_0x198d99,target:_0x20fbd1,filter:_0x27ed7f}){for(const _0x1a4134 of _0x198d99)_0x27ed7f(_0x1a4134)&&_0x20fbd1['add'](_0x1a4134);_0x20fbd1['listenTo'](_0x198d99,'add',(_0x1d97b4,_0x9681f4)=>{_0x27ed7f(_0x9681f4)&&_0x20fbd1['add'](_0x9681f4);}),_0x20fbd1['listenTo'](_0x198d99,'remove',(_0x29659e,_0x17f3af)=>{_0x20fbd1['has'](_0x17f3af)&&_0x20fbd1['remove'](_0x17f3af);});}({'source':_0x5515ad['_visibleAnnotations'],'target':_0x472d83,'filter':_0x3a8f90}),this['_uisData']['set'](_0x2f35dc,{'collection':_0x472d83,'filter':_0x3a8f90});const _0x1cbe9b=this['_uis']['get'](_0x2f35dc);_0x1cbe9b['attach'](_0x472d83),this['listenTo'](_0x1cbe9b,'change:activeAnnotation',(_0x84d536,_0x5630ea,_0xc4327f,_0x209a5a)=>{_0x209a5a&&_0x5515ad['_removeActiveAnnotation'](_0x209a5a),_0xc4327f&&_0x5515ad['_addActiveAnnotation'](_0xc4327f);});}['deactivate'](_0x43035e){if(this['activeUIs']['delete'](_0x43035e),!this['_uis']['has'](_0x43035e))throw new _0x28de93('annotationsuis-missing-ui',this,{'uiName':_0x43035e});const _0x5f5244=this['_uis']['get'](_0x43035e);_0x5f5244['detach'](),this['stopListening'](_0x5f5244),this['_uisData']['get'](_0x43035e)['collection']['destroy'](),this['_uisData']['delete'](_0x43035e);}['switchTo'](_0x18c883){if(!this['_uis']['has'](_0x18c883))throw new _0x28de93('annotationsuis-missing-ui',this,{'uiName':_0x18c883});const _0x3fd70b=this['context']['plugins']['get'](N),_0x3cdaa8=Array['from'](_0x3fd70b['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x18c883);const _0x47780f=this['_uis']['get'](_0x18c883);_0x47780f['setActiveAnnotation'](_0x3cdaa8),_0x47780f['_setSelectedAnnotations']&&_0x3cdaa8&&_0x47780f['_setSelectedAnnotations']([_0x3cdaa8]);}['deactivateAll'](){for(const _0x517a92 of this['activeUIs'])this['deactivate'](_0x517a92);}['register'](_0x2ec999,_0x165a4b){if(this['_uis']['has'](_0x2ec999))throw new _0x28de93('annotationsuis-register-already-registered');if('function'!=typeof _0x165a4b['attach']||'function'!=typeof _0x165a4b['detach']||'function'!=typeof _0x165a4b['setActiveAnnotation'])throw new _0x28de93('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x2ec999,_0x165a4b);}['refilterAnnotations'](){const _0x5d838c=this['context']['plugins']['get'](N)['collection'],_0x3d8a50=new Map(),_0x1f788a=Array['from'](this['activeUIs']);for(const _0x527e09 of this['activeUIs']){const _0x28e313=this['_uisData']['get'](_0x527e09)['collection'];for(const _0x130fab of _0x28e313)_0x3d8a50['set'](_0x130fab,_0x527e09);}for(const _0x2c1f87 of _0x5d838c){const _0x338ba9=_0x3d8a50['get'](_0x2c1f87);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x2c1f87);const _0x3e2f1a=_0x1f788a['find'](_0x49b8e1=>this['_uisData']['get'](_0x49b8e1)['filter'](_0x2c1f87));_0x338ba9!==_0x3e2f1a&&(_0x338ba9&&this['_uisData']['get'](_0x338ba9)['collection']['remove'](_0x2c1f87),_0x3e2f1a&&this['_uisData']['get'](_0x3e2f1a)['collection']['add'](_0x2c1f87));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x2d4866){const _0x506cc9=[];for(const _0xcdc396 of this['activeUIs']){(0x0,this['_uisData']['get'](_0xcdc396)['filter'])(_0x2d4866)&&_0x506cc9['push'](_0xcdc396);}if(_0x506cc9['length']>0x1)throw new _0x28de93('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x506cc9,'annotationType':_0x2d4866['type']});}}const ae=Ht('px');class V extends kt{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x2780e6){super(_0x2780e6);const _0x5c8364=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 _0x32f229(),this['focusCycler']=new Ft({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x5c8364['to']('class')],'style':{'minHeight':_0x5c8364['to']('minHeight',_0xe8a862=>'number'==typeof _0xe8a862?ae(_0xe8a862+0xa):null)},'dir':_0x2780e6['uiLanguageDirection'],'role':'application','aria-label':S(_0x2780e6,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':S(_0x2780e6,'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',_0x3749b6=>{this['_updateItemPositionInFocusables'](_0x3749b6['source']);}),this['list']['forEach'](_0x50e3af=>{this['focusTracker']['add'](_0x50e3af['element']),this['_updateItemPositionInFocusables'](_0x50e3af);}),this['list']['on']('change',(_0x5b029c,_0x3e59c9)=>{for(const _0xa90cb5 of _0x3e59c9['removed'])this['focusTracker']['remove'](_0xa90cb5['element']),this['focusables']['remove'](_0xa90cb5);for(const _0x572c8a of _0x3e59c9['added'])this['focusTracker']['add'](_0x572c8a['element']),this['_updateItemPositionInFocusables'](_0x572c8a);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x37ddf6){const _0x5d059b=this['focusables']['getIndex'](_0x37ddf6);let _0x43d010,_0x368562;for(const _0x53d4a1 of this['focusables'])if(_0x37ddf6['top']<_0x53d4a1['top']){_0x43d010=_0x53d4a1;break;}if(_0x368562=_0x43d010?this['focusables']['getIndex'](_0x43d010):this['focusables']['length'],-0x1!==_0x5d059b){if(_0x5d059b===_0x368562-0x1)return;this['focusables']['remove'](_0x37ddf6),_0x368562=_0x43d010?this['focusables']['getIndex'](_0x43d010):this['focusables']['length'];}this['focusables']['add'](_0x37ddf6,_0x368562);}}const qt=Ht('px');class H extends kt{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x115b56){super(_0x115b56),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x463eb0,_0x4be4b3)=>_0x463eb0+_0x4be4b3),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Dt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x1097d0=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x1097d0['to']('isAnimationDisabled',_0x4f476f=>_0x4f476f?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x1097d0['to']('top',_0x804f60=>qt(_0x804f60))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x10a79d=this['element']['clientHeight'];_0x10a79d&&(this['height']=_0x10a79d);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}}class z extends _0x3e81dd{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xda0cda){super(_0xda0cda),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 _0x1f4ff9=this['context']['config']['get']('sidebar.container');_0x1f4ff9&&this['setContainer'](_0x1f4ff9);}['setContainer'](_0x469df2){if(!y(_0x469df2))throw new _0x28de93('sidebar-setcontainer-invalid-element');this['container']=_0x469df2;}['_attachToContainer']({viewClass:_0x542973='',spaceBetweenItems:_0x756e59=0x19}={}){if(!y(this['container']))throw new _0x28de93('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x542973,this['_spaceBetweenItems']=_0x756e59;}['rearrange']({removedAnnotation:_0x332052,previousAnnotation:_0x2efeba,nextAnnotation:_0x4778b6}){const _0x1f8a45=this['getSidebarItemView'](_0x332052);this['view']['list']['remove'](_0x1f8a45),this['_destroySidebarItemView'](_0x332052),_0x2efeba&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x2efeba)),_0x4778b6&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x4778b6)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x4b9732,activatedAnnotation:_0x3f6220,disableAnimationOnActivatedAnnotation:_0x58fe0e}){if(this['_activeAnnotation']=_0x3f6220,_0x4b9732){_0x4b9732['isActive']=!0x1;const _0x3acc96=this['getSidebarItemView'](_0x4b9732);_0x3acc96&&_0x58fe0e&&(_0x3acc96['isAnimationDisabled']=!0x1);}if(_0x3f6220){const _0xa60ebc=this['getSidebarItemView'](_0x3f6220);_0xa60ebc&&(_0x3f6220['isActive']=!0x0,_0x58fe0e&&(_0xa60ebc['isAnimationDisabled']=!0x0,_0xa60ebc['top']+=0x1),this['_alignToTargetRect'](_0xa60ebc));}}['_detachFromContainer'](_0x289b87){if(this['view']['element']['remove'](),_0x289b87){for(const _0x3289ef of _0x289b87)this['_destroySidebarItemView'](_0x3289ef);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x4d4935,_0x1474db){_0x1474db||(_0x1474db=_0x4d4935['view']);const _0x46574d=new H(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x46574d,_0x4d4935),this['_annotationToSidebarItemView']['set'](_0x4d4935,_0x46574d),_0x46574d['content']['add'](_0x1474db),this['listenTo'](_0x4d4935['view'],'change:targetRect',(_0x54c6cf,_0x182438,_0x142b17)=>{const _0x40329f=this['_getTargetTop'](_0x4d4935,_0x142b17);_0x46574d['_targetTop']!=_0x40329f&&(_0x46574d['_targetTop']=_0x40329f,this['_setItemTop'](_0x46574d,_0x40329f));}),this['listenTo'](_0x46574d,'change:top',()=>{this['_recalculate'](_0x46574d,'top');}),this['listenTo'](_0x46574d,'change:bottom',()=>{this['_recalculate'](_0x46574d,'bottom');}),this['_alignToTargetRect'](_0x46574d);const _0x4bcc80=this['_getItemBefore'](_0x46574d);if(_0x4bcc80)this['_alignAfterItem'](_0x4bcc80,_0x46574d)||this['_alignToTargetRect'](_0x46574d);else this['_alignToTargetRect'](_0x46574d);return this['_updateLastItem'](),this['view']['list']['add'](_0x46574d),_0x46574d;}['_alignForTopChange'](_0xab2c42){if(!_0xab2c42['content']['length'])return;const _0x500407=this['_getItemBefore'](_0xab2c42);if(!_0x500407)return;const _0x4a5d95=this['_sidebarItemViewToAnnotation']['get'](_0x500407),_0x149e5f=this['_activeAnnotation'];_0x149e5f&&_0x149e5f===_0x4a5d95?this['_alignAfterItem'](_0x500407,_0xab2c42):this['_alignBeforeItem'](_0xab2c42,_0x500407);}['_alignForBottomChange'](_0xbc5683){if(!_0xbc5683['content']['length'])return;const _0x2c2fbd=this['_getItemAfter'](_0xbc5683);if(!_0x2c2fbd)return;const _0x5b7fe5=this['_sidebarItemViewToAnnotation']['get'](_0x2c2fbd),_0x2ebf54=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x5a258f=this['_activeAnnotation'];_0x5a258f&&_0x5a258f===_0x5b7fe5&&_0x2ebf54?(this['_alignBeforeItem'](_0x2c2fbd,_0xbc5683),this['_alignAfterItem'](_0xbc5683,_0x2c2fbd)):_0x5a258f&&_0x5a258f===_0x5b7fe5?this['_alignBeforeItem'](_0x2c2fbd,_0xbc5683):this['_alignAfterItem'](_0xbc5683,_0x2c2fbd);}['_recalculate'](_0x435a85,_0x416930){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x23e6b9,changedProp:_0x25e8d2}of this['_recalculateBuffer'])'top'===_0x25e8d2?this['_alignForTopChange'](_0x23e6b9):this['_alignForBottomChange'](_0x23e6b9);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x435a85,'changedProp':_0x416930});}['getSidebarItemView'](_0xcd61d8){return this['_annotationToSidebarItemView']['get'](_0xcd61d8);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x435434){const _0x24d840=this['getSidebarItemView'](_0x435434);this['stopListening'](_0x24d840),this['stopListening'](_0x435434['view']),_0x24d840['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x435434),this['_sidebarItemViewToAnnotation']['delete'](_0x24d840);}['_createSidebarView'](){const _0x571954=new V(this['context']['locale']);return _0x571954['render'](),this['on']('change:_lastItem',(_0x266b6e,_0xc22555,_0x9a5699,_0x3dab77)=>{_0x3dab77&&_0x571954['unbind']('minHeight'),_0x9a5699?_0x571954['bind']('minHeight')['to'](_0x9a5699,'bottom'):_0x571954['minHeight']=null;}),_0x571954;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x7bb0c0){const _0x11ddd=this['_sidebarItemViewToAnnotation']['get'](_0x7bb0c0),_0x7731aa=_0x11ddd&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x11ddd)-0x1);return _0x7731aa&&this['getSidebarItemView'](_0x7731aa)||null;}['_getItemAfter'](_0x38cda9){const _0x45ddfe=this['_sidebarItemViewToAnnotation']['get'](_0x38cda9),_0x56daec=_0x45ddfe&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x45ddfe)+0x1);return _0x56daec&&this['getSidebarItemView'](_0x56daec)||null;}['_alignBeforeItem'](_0x4845eb,_0x1e7568){_0x4845eb['updateHeight']();const _0x302fa=R(_0x1e7568['bottom']+this['_spaceBetweenItems'],_0x4845eb['top']);return!!_0x302fa&&(this['_setItemTop'](_0x1e7568,_0x1e7568['top']-_0x302fa),!0x0);}['_alignAfterItem'](_0x2e9ec9,_0x3ad14e){_0x2e9ec9['updateHeight']();const _0x1b4a57=R(_0x2e9ec9['bottom']+this['_spaceBetweenItems'],_0x3ad14e['top']);return!!_0x1b4a57&&(this['_setItemTop'](_0x3ad14e,_0x3ad14e['top']+_0x1b4a57,!0x1),!0x0);}['_alignToTargetRect'](_0x158a45){const _0x4eb7b7=this['_sidebarItemViewToAnnotation']['get'](_0x158a45);if(!_0x4eb7b7||!_0x4eb7b7['target']||!_0x4eb7b7['targetRect'])return;const _0x50dc12=this['_getTargetTop'](_0x4eb7b7,_0x4eb7b7['targetRect']);this['_setItemTop'](_0x158a45,_0x50dc12);}['_getTargetTop'](_0x52e331,_0x59188f){if(null===_0x59188f)return 0x0;if(_0x52e331['target']instanceof _0x2e5438)return _0x59188f['top'];{const _0x146ba3=new _0x2e5438(this['view']['element'])['top'];return _0x59188f['top']-_0x146ba3;}}['_setItemTop'](_0x2bd4f9,_0x5817a4,_0x5cef3f=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x5cef3f&&(_0x5817a4=Math['max'](_0x5817a4,this['_getMaxAvailableTop'](_0x2bd4f9))),_0x2bd4f9['top']=_0x5817a4;}['_getMaxAvailableTop'](_0x11d414){let _0x110765=this['_getItemBefore'](_0x11d414),_0x22db3f=0x0;for(;_0x110765;)_0x110765['updateHeight'](),_0x22db3f+=this['_spaceBetweenItems']+_0x110765['height'],_0x110765=this['_getItemBefore'](_0x110765);return _0x22db3f;}}function R(_0x2cfae5,_0x5b864f){return Math['max'](_0x2cfae5-_0x5b864f,0x0);}function y(_0xcea622){return null!==_0xcea622&&'object'==typeof _0xcea622&&0x1===_0xcea622['nodeType'];}class e extends _0x3e81dd{['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(_0x3fbd1d){super(_0x3fbd1d),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0xc5674b(),this['_refreshPositioningDebounced']=_0x3c02bb(()=>{this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x5b8ca8=this['context']['plugins']['get'](M),_0x18b72e=this['context']['plugins']['get'](z);_0x5b8ca8['register']('wideSidebar',this),_0x18b72e['container']&&_0x5b8ca8['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x2c69ab){if(_0x2c69ab===this['activeAnnotation'])return;const _0x1b5d4f=this['context']['plugins']['get'](z);_0x1b5d4f['_activeAnnotation']=_0x2c69ab;const _0x5edf78=this['activeAnnotation'];this['activeAnnotation']=_0x2c69ab,_0x1b5d4f['refresh']({'blurredAnnotation':_0x5edf78,'activatedAnnotation':this['activeAnnotation']});}['attach'](_0x12eced){this['annotations']=_0x12eced;const _0x43224a=this['context']['plugins']['get'](z);if(_0x43224a['_annotations']=_0x12eced,this['isAttached'])throw new _0x28de93('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x43224a,'set:container',()=>{this['detach'](),this['listenTo'](_0x43224a,'change:container',_0x2b7983=>{_0x2b7983['off'](),this['attach'](_0x12eced);});}),_0x43224a['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x143bb2=_0x5d286a=>{_0x5d286a['updateTargetRect'](),_0x43224a['addAnnotation'](_0x5d286a);};for(const _0x527c2e of _0x12eced)_0x143bb2(_0x527c2e);this['listenTo'](_0x12eced,'add',(_0x5a730e,_0x385039)=>{_0x143bb2(_0x385039);}),this['listenTo'](_0x12eced,'remove',(_0x37a025,_0x44b24e,_0x5b8ac5)=>{_0x43224a['rearrange']({'removedAnnotation':_0x44b24e,'previousAnnotation':_0x12eced['get'](_0x5b8ac5-0x1),'nextAnnotation':_0x12eced['get'](_0x5b8ac5+0x1)}),_0x44b24e===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x12eced,'focus',(_0x52185d,_0x282067)=>{this['setActiveAnnotation'](_0x282067);}),this['listenTo'](_0x12eced,'blur',()=>{this['setActiveAnnotation'](null);});const _0x4280f8=this['context']instanceof _0x128a45?this['context']['editors']:new _0xc5674b([this['context']]);for(const _0xf58ac0 of _0x4280f8)this['_integrateWithEditorAnnotations'](_0xf58ac0);this['listenTo'](_0x4280f8,'add',(_0x37547b,_0x193b4f)=>{this['listenTo'](_0x193b4f,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x193b4f);});}),this['listenTo'](_0x4280f8,'remove',(_0x202e5d,_0x3f2dd9)=>{_0x3f2dd9['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x3f2dd9['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x28de93('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x37cff0=this['context']['plugins']['get'](z);_0x37cff0['_detachFromContainer'](this['annotations']),this['stopListening'](_0x37cff0),this['stopListening'](this['annotations']),this['context']instanceof _0x128a45&&this['stopListening'](this['context']['editors']);for(const _0x40b08c of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x40b08c);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x4ea214){if(!_0x4ea214['plugins']['has']('EditorAnnotations'))return;const _0x8bee14=_0x4ea214['plugins']['get']('EditorAnnotations'),_0x126cbb=()=>{const _0x163290=_0x8bee14['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x163290[0x0]||null);};this['listenTo'](_0x8bee14,'refresh',_0x126cbb),this['listenTo'](_0x8bee14,'blur',(_0x4239db,{isAnnotationTracked:_0x4a633a})=>{this['activeAnnotation']&&_0x4a633a(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x8bee14,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x28d3de=>{_0x8bee14['hasDomSelection']()&&(_0x126cbb(),_0x28d3de['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x8bee14);}['_destroyEditorAnnotationsIntegration'](_0x70f971){this['stopListening'](_0x70f971),this['_editorAnnotations']['remove'](_0x70f971);}}class D extends _0x59646e{['counterView'];constructor(_0x3e1ab9){super(_0x3e1ab9);const _0x4cd1e7=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x1b4c95,_0x178b87)=>_0x1b4c95?'...':_0x178b87['toString']()),this['set']('annotationType',''),this['icon']=xt,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new kt(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x4cd1e7['to']('annotationType',_0x800dfa=>'ck-annotation-counter__badge--'+_0x800dfa),_0x4cd1e7['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x4cd1e7['to']('_badge')}]}),this['children']['add'](this['counterView']);}}class n extends _0x3e81dd{['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(_0x47e504){super(_0x47e504),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=Object['create'](_0x1e87d2),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0xc5674b(),this['_refreshPositioningDebounced']=_0x3c02bb(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](M)['register']('narrowSidebar',this),this['bodyCollection']=new _0x58f719(this['context']['locale']),this['balloonPanelView']=new _0x2895cc(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x26c4f9){this['annotations']=_0x26c4f9;const _0xd78b8c=this['context']['plugins']['get'](z),_0x541400=this['balloonPanelView'];if(_0xd78b8c['_annotations']=_0x26c4f9,this['isAttached'])throw new _0x28de93('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0xd78b8c,'set:container',()=>{this['detach'](),this['listenTo'](_0xd78b8c,'change:container',_0x2988f1=>{_0x2988f1['off'](),this['attach'](_0x26c4f9);});}),_0xd78b8c['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0xd4104d=_0x250800=>{const _0x42dc21=new D(this['context']['locale']);_0xd78b8c['addAnnotation'](_0x250800,_0x42dc21),this['_annotationToNarrowView']['set'](_0x250800,_0x42dc21),_0x42dc21['bind']('isDirty','annotationType','number')['to'](_0x250800['view'],'isDirty','type','length'),_0x42dc21['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x541400['content']['first']!==_0x250800['view']?(this['_showBalloon'](_0x250800),_0x250800['view']['element']['focus'](),this['setActiveAnnotation'](_0x250800)):this['setActiveAnnotation'](null);});};for(const _0x1f5b6a of _0x26c4f9)_0xd4104d(_0x1f5b6a);this['listenTo'](_0x26c4f9,'add',(_0x3b7823,_0x12185a)=>{_0xd4104d(_0x12185a);}),this['listenTo'](_0x26c4f9,'remove',(_0x1f12a1,_0x599777,_0x2ac2ea)=>{this['_annotationToNarrowView']['get'](_0x599777)['destroy'](),this['_annotationToNarrowView']['delete'](_0x599777),_0xd78b8c['rearrange']({'removedAnnotation':_0x599777,'previousAnnotation':_0x26c4f9['get'](_0x2ac2ea-0x1),'nextAnnotation':_0x26c4f9['get'](_0x2ac2ea+0x1)}),_0x599777===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x26c4f9,'focus',(_0x3d6c4a,_0x4fb8e1)=>{this['setActiveAnnotation'](_0x4fb8e1);}),this['listenTo'](_0x26c4f9,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x531296,_0x5deaf7)=>{_0x5deaf7['keyCode']===_0x2c759f['esc']&&_0x541400['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x541400['content']['first']),this['_hideBalloon'](),_0x5deaf7['stopPropagation'](),_0x5deaf7['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x17223c,_0x1b11d8)=>{const _0x402ded=_0x1b11d8['target'];_0x541400['isVisible']&&_0x541400['element']['contains'](_0x402ded)||_0xd78b8c['view']['element']['contains'](_0x402ded)||_0x17223c['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x2eee7d=>_0x2eee7d['contains'](_0x402ded))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0x5e1925=this['context']instanceof _0x128a45?this['context']['editors']:new _0xc5674b([this['context']]);for(const _0x4d8934 of _0x5e1925)this['_integrateWithEditorAnnotations'](_0x4d8934);this['listenTo'](_0x5e1925,'add',(_0x398846,_0x510e4d)=>{this['listenTo'](_0x510e4d,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x510e4d);});}),this['listenTo'](_0x5e1925,'remove',(_0x2c4592,_0x37ec0d)=>{_0x37ec0d['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x37ec0d['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x4d6eec){if(_0x4d6eec===this['activeAnnotation'])return;const _0x53995b=this['context']['plugins']['get'](z);if(_0x53995b['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x4d6eec,'disableAnimationOnActivatedAnnotation':!0x0}),_0x4d6eec)_0x53995b['getSidebarItemView'](_0x4d6eec)?this['_showBalloon'](_0x4d6eec):this['_hideBalloon']();else this['_hideBalloon']();this['activeAnnotation']=_0x4d6eec;}['detach'](){if(!this['isAttached'])throw new _0x28de93('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x25976f=this['context']['plugins']['get'](z);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x5002db=>_0x5002db['destroy']()),this['_annotationToNarrowView']['clear'](),_0x25976f['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x128a45&&this['stopListening'](this['context']['editors']);for(const _0x1427e5 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x1427e5);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'](_0x232ee7){if(!_0x232ee7['plugins']['has']('EditorAnnotations'))return;const _0x48f5ed=_0x232ee7['plugins']['get']('EditorAnnotations'),_0x192606=this['context']['plugins']['get'](z),_0x5f0a87=this['annotations'],_0x3a01b8=this['balloonPanelView'],_0x4e499b=()=>{const _0x43292f=_0x48f5ed['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x43292f),this['setActiveAnnotation'](_0x43292f[0x0]||null);};this['listenTo'](_0x48f5ed,'refresh',_0x4e499b),this['listenTo'](_0x48f5ed,'blur',(_0x1c4a3f,{isAnnotationTracked:_0x15870e})=>{this['activeAnnotation']&&_0x15870e(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x48f5ed,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x5f0a87,'blur',_0x53f03d=>{_0x48f5ed['hasDomSelection']()&&_0x53f03d['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x1416b4,_0x1e9699)=>{const _0x4bdf23=_0x1e9699['target'];_0x3a01b8['isVisible']&&_0x3a01b8['element']['contains'](_0x4bdf23)||_0x192606['view']['element']['contains'](_0x4bdf23)||this['activeAnnotation']&&_0x48f5ed['hasDomSelection']()&&(_0x4e499b(),_0x1416b4['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x48f5ed);}['_destroyEditorAnnotationsIntegration'](_0x48cdfd){_0x48cdfd&&(this['stopListening'](_0x48cdfd),this['_editorAnnotations']['remove'](_0x48cdfd));}['_setSelectedAnnotations'](_0x380ff9){for(const _0x4135c8 of this['_selectedAnnotations'])_0x380ff9['includes'](_0x4135c8)||this['_manuallyClosedAnnotationViews']['delete'](_0x4135c8['view']);this['_selectedAnnotations']=_0x380ff9;}['_refreshPositioning'](){const _0x5dbf6e=this['balloonPanelView'];this['annotations']['refreshPositioning'](),_0x5dbf6e['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0xcda783){if(this['_manuallyClosedAnnotationViews']['has'](_0xcda783['view']))return;const _0x7c1732=this['balloonPanelView']['content']['first'];_0x7c1732!==_0xcda783['view']?(_0x7c1732&&this['_detachListeners'](_0x7c1732),this['_attachListeners'](_0xcda783['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0xcda783['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x940e5b=this['balloonPanelView']['content']['first'],_0x56d3f5=_0x940e5b&&this['annotations']['getByView'](_0x940e5b);if(!_0x56d3f5||!this['_annotationToNarrowView']['has'](_0x56d3f5))return;const _0x3ba409=this['_annotationToNarrowView']['get'](_0x56d3f5)['element'],_0x4cd459=(function(){const _0x3e1f17=_0x2895cc['defaultPositions'];return[_0x3e1f17['southArrowNorthEast'],_0x3e1f17['northArrowSouthEast'],_0x3e1f17['southArrowNorth'],_0x3e1f17['northArrowSouth'],_0x3e1f17['southArrowNorthWest'],_0x3e1f17['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x3ba409,'positions':_0x4cd459});}['_hideBalloon'](){const _0x55c86e=this['balloonPanelView'],_0x2bac46=_0x55c86e['content']['first'];_0x2bac46&&(this['_detachListeners'](_0x2bac46),_0x55c86e['unpin'](),_0x55c86e['content']['clear']());}['_attachListeners'](_0x1c2cce){this['listenTo'](_0x1c2cce,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x1c2cce,'Esc',(_0x90a2c2,_0x538ade)=>{this['_manuallyClosedAnnotationViews']['add'](_0x1c2cce),this['_hideBalloon'](),_0x538ade();});}['_detachListeners'](_0x3ce38a){this['stopListening'](_0x3ce38a);}}class c extends _0x21992c{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];static get['requires'](){return[P,_0x178c54,M];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3b879b){super(_0x3b879b),_0x3b879b['editing']['view']['addObserver'](_0xa9273a),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x3b879b['plugins']['get'](_0x178c54),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1;}['init'](){const _0x5d8464=this['editor']['plugins']['get'](M);_0x5d8464['context']===this['editor']&&(_0x5d8464['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x57fe6d,_0x481f59)=>{const _0x21f03c=this['_balloon'];if(this['isAttached']&&_0x21f03c['visibleView']){const _0x5293e0=this['annotations']['getByView'](_0x21f03c['visibleView']);_0x5293e0&&this['_closeAnnotation'](_0x5293e0),_0x481f59();}}));}['afterInit'](){const _0x9a248a=this['editor']['plugins']['get'](M);_0x9a248a['context']===this['editor']&&(_0x9a248a['hasActive']()||_0x9a248a['switchTo']('inline'));}['setActiveAnnotation'](_0x3d1963){_0x3d1963!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x3d1963&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x3d1963)&&this['_addAnnotationToBalloon'](_0x3d1963,!0x0),_0x3d1963['isActive']=!0x0),_0x3d1963||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x3d1963);}['attach'](_0x4876c5){this['annotations']=_0x4876c5;const _0x15142f=this['editor']['plugins']['get'](M),_0x44d18b=this['_balloon'];if(this['isAttached'])throw new _0x28de93('inlineannotations-attach-already-attached',this);if(_0x15142f['context']!==this['editor'])throw new _0x28de93('inlineannotations-not-allowed-with-context',this);const _0x123827=this['editor']['plugins']['get'](P);this['listenTo'](_0x123827,'refresh',()=>{const _0x56a3e3=_0x123827['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x5a1de7,_0x4cc801;!this['_forceRefresh']&&(_0x5a1de7=_0x56a3e3,_0x4cc801=this['_selectedAnnotations'],_0x5a1de7['length']===_0x4cc801['length']&&_0x5a1de7['every'](_0x34f55e=>_0x4cc801['includes'](_0x34f55e)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x56a3e3),this['setActiveAnnotation'](_0x56a3e3[0x0]||null));}),this['listenTo'](_0x123827,'blur',(_0x21a9e3,{isAnnotationTracked:_0x436385})=>{this['activeAnnotation']&&_0x436385(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x5b9963,_0x34ff69,_0x4b49f)=>{_0x4b49f||this['setActiveAnnotation'](null);}),this['listenTo'](_0x4876c5,'remove',(_0x3443af,_0x2bea16)=>{this['_removeAnnotationFromBalloon'](_0x2bea16),_0x2bea16===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x44d18b,'change:visibleView',(_0x18db85,_0x367e6a,_0x7529aa,_0x456a1b)=>{_0x456a1b&&this['stopListening'](_0x456a1b);const _0x21e3c3=_0x4876c5['getByView'](_0x7529aa);_0x7529aa&&_0x21e3c3&&(this['listenTo'](_0x7529aa,'change:height',()=>{_0x44d18b['updatePosition']();}),this['listenTo'](_0x7529aa,'Esc',()=>{this['_closeAnnotation'](_0x21e3c3),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x21e3c3&&this['setActiveAnnotation'](_0x21e3c3));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x44d18b['visibleView']&&(_0x4876c5['getByView'](_0x44d18b['visibleView'])&&_0x44d18b['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 _0x28de93('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x45695b of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x45695b);this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_setSelectedAnnotations'](_0xe32485){for(const _0x5223df of this['_selectedAnnotations'])_0xe32485['includes'](_0x5223df)||this['_manuallyClosed']['delete'](_0x5223df);for(const _0x5d2726 of this['annotations'])_0xe32485['includes'](_0x5d2726)||this['_removeAnnotationFromBalloon'](_0x5d2726);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x3debf of _0xe32485)this['_addAnnotationToBalloon'](_0x3debf);}this['_selectedAnnotations']=_0xe32485;}['_addAnnotationToBalloon'](_0x3a0143,_0x4c1360=!0x1){this['_manuallyClosed']['has'](_0x3a0143)||(this['_addedAnnotations']['has'](_0x3a0143)||this['_balloon']['hasView'](_0x3a0143['view'])||(this['_addedAnnotations']['add'](_0x3a0143),this['_balloon']['add']({'stackId':_0x3a0143['view']['id'],'view':_0x3a0143['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x3a0143)}})),_0x4c1360&&this['_balloon']['showStack'](_0x3a0143['view']['id']));}['_getBalloonTargetForAnnotation'](_0x430f5f){const _0x4dff38=_0x430f5f['target'],_0x98acad=this['editor']['editing']['view'],_0x4b31e5=_0x98acad['document']['selection']['getFirstRange'](),_0x573580=_0x98acad['domConverter']['viewRangeToDom'](_0x4b31e5);if(_0x573580['collapse'](!0x0),_0x4dff38){if(_0x4dff38 instanceof _0x2e5438)return _0x4dff38;let _0x17e720=[];for(const _0x48cdd6 of _0x4dff38)_0x17e720['push'](...(_0x53fdd2=_0x48cdd6['getClientRects'](),Array['from'](_0x53fdd2)['map'](DOMRect['fromRect'])));_0x17e720=function(_0x24d5ec){const _0x50e4e1=[];let _0x47f43e=_0x24d5ec[0x0];for(let _0x1ecc06=0x1;_0x1ecc06<_0x24d5ec['length'];_0x1ecc06++)b(_0x47f43e,_0x24d5ec[_0x1ecc06])?_0x47f43e['width']+=_0x24d5ec[_0x1ecc06]['width']:(_0x50e4e1['push'](_0x47f43e),_0x47f43e=_0x24d5ec[_0x1ecc06]);return _0x50e4e1['push'](_0x47f43e),_0x50e4e1;}(_0x17e720);const _0x347c78=_0x573580['getBoundingClientRect']();return _0x17e720['find'](_0x2a40c5=>_0x2a40c5['top']<=_0x347c78['top']&&_0x2a40c5['bottom']>=_0x347c78['bottom']&&_0x2a40c5['left']<=_0x347c78['left']&&_0x2a40c5['right']>=_0x347c78['right'])||_0x17e720[0x0];}var _0x53fdd2;return _0x430f5f['targetRect']||_0x573580;}['_removeAnnotationFromBalloon'](_0x4893ff){this['_addedAnnotations']['has'](_0x4893ff)&&this['_balloon']['hasView'](_0x4893ff['view'])&&(this['_addedAnnotations']['delete'](_0x4893ff),this['_balloon']['remove'](_0x4893ff['view']));}['_closeAnnotation'](_0x3eb1c3){this['_manuallyClosed']['add'](_0x3eb1c3),this['_removeAnnotationFromBalloon'](_0x3eb1c3);}}function b(_0x9d76c8,_0x28bc9b){return _0x9d76c8['top']===_0x28bc9b['top']&&_0x9d76c8['bottom']===_0x28bc9b['bottom']&&_0x9d76c8['right']===_0x28bc9b['left'];}var Z='<!--\x0a\x0a\x20What\x20you\x27re\x20currently\x20looking\x20at\x20is\x20the\x20source\x20code\x20of\x20a\x20legally\x20protected,\x20proprietary\x20software.\x0a\x20CKEditor\x205\x20Collaboration\x20is\x20licensed\x20under\x20a\x20commercial\x20license\x20and\x20protected\x20by\x20copyright\x20law.\x20Where\x20not\x20otherwise\x20indicated,\x0a\x20all\x20CKEditor\x205\x20Collaboration\x20content\x20is\x20authored\x20by\x20CKSource\x20engineers\x20and\x20consists\x20of\x20CKSource-owned\x20intellectual\x20property.\x0a\x0a\x20Copyright\x20(c)\x202003-2024,\x20CKSource\x20Holding\x20sp.\x20z\x20o.o.\x20All\x20rights\x20reserved.\x0a\x0a!-->\x0a\x0a<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20clip-rule=\x22evenodd\x22\x20d=\x22M14\x203.5A3.5\x203.5\x200\x200\x201\x2017.5\x207v6l-.005.192a3.501\x203.501\x200\x200\x201-2.927\x203.262l-.062.008v1.813a1.5\x201.5\x200\x200\x201-2.193\x201.33l-.37-.193-.38-.212a13.452\x2013.452\x200\x200\x201-3.272-2.63l-.062-.07-4.729-.046a3.5\x203.5\x200\x200\x201-3.5-3.5v-6a3.5\x203.5\x200\x200\x201\x203.5-3.5L14\x203.5ZM3.5\x204.954a2\x202\x200\x200\x200-2\x202v6a2\x202\x200\x200\x200\x202\x202L8.924\x2015a11.917\x2011.917\x200\x200\x200\x203.71\x203.081l.372.194v-3.268L12.962\x2015H14a2\x202\x200\x200\x200\x202-2V7a2\x202\x200\x200\x200-2-2L3.5\x204.954Z\x22/><path\x20d=\x22M16.5.5h-10a3.5\x203.5\x200\x200\x200-3.162\x202h1.84A2\x202\x200\x200\x201\x206.5\x202h10a2\x202\x200\x200\x201\x202\x202v8.873a3.502\x203.502\x200\x200\x200\x201.495-2.681L20\x2010V4A3.5\x203.5\x200\x200\x200\x2016.5.5Z\x22/><path\x20clip-rule=\x22evenodd\x22\x20d=\x22M12.013\x207.453a.75.75\x200\x200\x201\x20.034\x201.06l-3.75\x204a.75.75\x200\x200\x201-1.045.048l-2.25-2a.75.75\x200\x200\x201\x20.996-1.122l1.704\x201.515\x203.25-3.467a.75.75\x200\x200\x201\x201.061-.034Z\x22/></svg>\x0a';class tt extends kt{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x4b7553,_0x32fec3){super(_0x4b7553),this['set']('isEmpty',!_0x32fec3['length']),this['focusTracker']=new _0x32f229(),this['_annotationViews']=_0x32fec3,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new Ft({'focusables':_0x32fec3,'focusTracker':this['focusTracker']}),this['listenTo'](_0x32fec3,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x32fec3,'remove',(_0x5355d5,_0x2e65ab)=>{_0x2e65ab['isActive']&&this['focus'](),_0x32fec3['length']||(this['isEmpty']=!0x0);});const _0x2d0bd0=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':S(_0x4b7553,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x32fec3},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x2d0bd0['if']('isEmpty','ck-hidden',_0x29151d=>!_0x29151d)]},'children':[{'text':S(_0x4b7553,'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 _0x35d160 of this['_annotationViews'])this['focusTracker']['add'](_0x35d160['element']);this['_annotationViews']['on']('change',(_0x513dff,{added:_0x5ea89e,removed:_0x5b9b43})=>{for(const _0x598e92 of _0x5ea89e)this['focusTracker']['add'](_0x598e92['element']);for(const _0x5dc421 of _0x5b9b43)this['focusTracker']['remove'](_0x5dc421['element']);});}}class f extends _0x3e81dd{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[o,N];}constructor(_0xfb1e9e){super(_0xfb1e9e),this['archivedThreads']=new _0xc5674b();}['init'](){const _0x2cea97=this['context'],_0x23bf0f=_0x2cea97['plugins']['get'](o),_0x3ed4d7=_0x2cea97['plugins']['get'](N);this['listenTo'](_0x23bf0f,'addCommentThread',(_0xfc91b1,{threadId:_0xf6fd9a})=>{const _0x241c0a=_0x23bf0f['getCommentThread'](_0xf6fd9a);_0x241c0a['archivedAt']&&this['archivedThreads']['add'](_0x241c0a,this['_calculatePosition'](_0x241c0a['archivedAt'])),this['listenTo'](_0x241c0a,'change:archivedAt',(_0x878309,_0x106cf6,_0x41a987)=>{_0x41a987?this['archivedThreads']['has'](_0x241c0a)||this['archivedThreads']['add'](_0x241c0a,this['_calculatePosition'](_0x241c0a['archivedAt'])):this['archivedThreads']['has'](_0x241c0a)&&this['archivedThreads']['remove'](_0x241c0a);});}),this['listenTo'](_0x23bf0f,'removeCommentThread',(_0x57b0fa,{threadId:_0x435cab})=>{const _0x5e886a=_0x23bf0f['getCommentThread'](_0x435cab);this['stopListening'](_0x5e886a),this['archivedThreads']['has'](_0x5e886a)&&this['archivedThreads']['remove'](_0x5e886a);},{'priority':'highest'}),this['listenTo'](_0x3ed4d7['collection'],'focus',(_0x4b10fb,_0x4d7e12)=>{_0x4d7e12['isVisible']||(_0x4d7e12['isActive']=!0x0,_0x3ed4d7['activate'](_0x4d7e12));});}['_calculatePosition'](_0x407a04){const _0x40964e=[...this['archivedThreads']]['findIndex'](_0x12fd73=>_0x12fd73['archivedAt']<_0x407a04);return _0x40964e>-0x1?_0x40964e:this['archivedThreads']['length'];}}class a extends _0x21992c{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[f,_0x270df8];}constructor(_0x3f39eb){super(_0x3f39eb),this['annotationViews']=new _0x4f3352(),this['_pendingThreads']=[];}['init'](){const _0xb8bcd9=this['editor'],_0x1291ed=this['_hideDialogOnAnnotationEscape']['bind'](this);_0xb8bcd9['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x59646e,!0x0)),_0xb8bcd9['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x4825da=this['_createCommentsArchiveButton'](_0x5c043a);return _0x4825da['set']({'role':'menuitemcheckbox'}),_0x4825da;});const _0x13e13e=_0xb8bcd9['plugins']['get'](f),_0x5c480c=_0xb8bcd9['plugins']['get']('Annotations'),_0x1faf15=_0xb8bcd9['plugins']['get']('CommentsRepository');this['listenTo'](_0x13e13e['archivedThreads'],'add',(_0x22d4e1,_0x126d3c)=>{const _0x4fd8cd=_0xb8bcd9['config']['get']('collaboration.channelId');if(!_0x4fd8cd||_0x126d3c['channelId']===_0x4fd8cd){const _0x2491ba=_0x1faf15['_threadToController']['get'](_0x126d3c);if(!_0x2491ba)return void this['_pendingThreads']['push'](_0x126d3c);const _0x4c4d69=this['_calculatePosition'](_0x126d3c['archivedAt']),_0x13d49d=_0x5c480c['getByInnerView'](_0x2491ba['view']);_0x13d49d['isVisible']&&_0x5c480c['_visibleAnnotations']['remove'](_0x13d49d),this['annotationViews']['add'](_0x13d49d['view'],_0x4c4d69);}}),this['listenTo'](_0x5c480c['collection'],'add',(_0x1bc64e,_0xa81856)=>{const _0x4fd9fc=this['_pendingThreads']['find'](_0x1924ed=>{const _0x47236c=_0x1faf15['_threadToController']['get'](_0x1924ed);return _0x47236c&&_0xa81856['innerView']===_0x47236c['view'];});if(_0x4fd9fc){const _0x1f03c0=this['_calculatePosition'](_0x4fd9fc['archivedAt']);this['annotationViews']['add'](_0xa81856['view'],_0x1f03c0),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x4fd9fc),0x1);}}),this['listenTo'](_0x13e13e['archivedThreads'],'remove',(_0x4989cc,_0x61f957)=>{const _0x54c2f7=_0xb8bcd9['config']['get']('collaboration.channelId');if(!_0x54c2f7||_0x61f957['channelId']===_0x54c2f7){const _0x38a397=_0x1faf15['_threadToController']['get'](_0x61f957),_0x2a1376=_0x5c480c['getByInnerView'](_0x38a397['view']);this['annotationViews']['remove'](_0x2a1376['view']),this['stopListening'](_0x2a1376['focusableElements']);}}),this['listenTo'](_0x5c480c['collection'],'add',(_0x4996bf,_0x7a8140)=>{this['listenTo'](_0x7a8140,'escape',_0x1291ed);}),this['listenTo'](_0x5c480c['collection'],'remove',(_0x178cd4,_0x1016cc)=>{this['stopListening'](_0x1016cc,'escape',_0x1291ed);});}['_calculatePosition'](_0x2817d6){const _0x5736ce=this['editor']['config']['get']('collaboration.channelId'),_0x5bcd33=[...this['editor']['plugins']['get'](f)['archivedThreads']]['filter'](_0x416014=>_0x416014['channelId']===_0x5736ce)['findIndex'](_0x88043=>_0x88043['archivedAt']<_0x2817d6);return _0x5bcd33<0x0||_0x5bcd33>this['annotationViews']['length']?this['annotationViews']['length']:_0x5bcd33-0x1;}['_toggleDialog'](){const _0x4409ff=this['editor'],_0x5566ef=_0x4409ff['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new tt(_0x4409ff['locale'],this['annotationViews'])),'commentsArchive'===_0x5566ef['id']?_0x5566ef['hide']():_0x5566ef['show']({'id':'commentsArchive','title':S(_0x4409ff['locale'],'COMMENTS_ARCHIVE'),'icon':Z,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x372112['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x318a77,_0x397e73=!0x1){const _0x35e299=this['editor']['locale'],_0x534732=this['editor']['plugins']['get']('Dialog'),_0x3849ef=new _0x318a77(_0x35e299);return _0x3849ef['bind']('isEnabled')['to'](this,'isEnabled'),_0x3849ef['bind']('isOn')['to'](_0x534732,'id',_0x429f2e=>'commentsArchive'===_0x429f2e),_0x3849ef['set']({'label':S(_0x35e299,'COMMENTS_ARCHIVE'),'icon':Z,'isToggleable':!0x0}),_0x397e73&&(_0x3849ef['tooltip']=!0x0),this['listenTo'](_0x3849ef,'execute',()=>this['_toggleDialog']()),_0x3849ef;}['_hideDialogOnAnnotationEscape']=_0x32cc5d=>{const _0x185168=_0x32cc5d['source'];if(!this['annotationViews']['has'](_0x185168['view']))return;const _0x23708c=this['editor']['plugins']['get']('Dialog');_0x23708c['isOpen']&&'commentsArchive'===_0x23708c['id']&&(_0x23708c['hide'](),_0x32cc5d['stop']());};}class p extends _0x21992c{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,x as AnnotationCollection,T as AnnotationView,N as Annotations,M as AnnotationsUIs,ss as BaseCommentThreadView,os as BaseCommentView,re as Comment,oe as CommentThread,yt as CommentThreadController,ie as CommentThreadInputView,Ct as CommentThreadView,vt 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,e as WideSidebar};
|