@ckeditor/ckeditor5-comments 48.3.0-alpha.6 → 48.3.0-alpha.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +11 -11
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +16 -16
package/dist/index.js
CHANGED
|
@@ -20,14 +20,14 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{Command as
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
((()=>Ot)());constructor(_0x30d825={}){(_0x30d825=Object['assign']({},_0x30d825))['plugins']||(_0x30d825['plugins']=CommentEditor['defaultPlugins']),super(_0x30d825),this['ui']=new Nt(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this['editing']['view']['_overlayModeHint']='auto',this['_sendUsageRequest']=()=>window['Promise']['resolve']({'status':'ok'});}['create'](){const _0x2faa8d=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0x2faa8d))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x3a57f2=>{const _0x219ab1=this['model']['document']['getRoot'](),_0x1083e0=_0x219ab1&&_0x219ab1['getChild'](_0x219ab1['childCount']-0x1);_0x3a57f2['setSelection'](_0x1083e0,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x19deda=this['editing']['view'],_0x4873d6=_0x19deda['document']['getRoot'](),_0x2023ca=_0x4873d6['getChild'](0x0);_0x4873d6['childCount']>0x1||!_0x2023ca||'p'!=_0x2023ca['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(mt(_0x19deda,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x2023ca['placeholder']=this['placeholder']),ut({'view':_0x19deda,'element':_0x2023ca,'keepOnFocus':!0x0}),this['placeholderElement']=_0x2023ca);}},St=class extends ht{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x509ef2,_0x3e9028={}){super(_0x509ef2),this['editor']=null,this['_editorConfig']=_0x3e9028,this['set']('value',_0x3e9028['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',Et(_0x509ef2,'Reply...')),this['set']('submitLabel',Et(_0x509ef2,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new _0x17fd77(),this['focusTracker']=new _0x17ba74(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x31bceb=>!_0x31bceb['defaultPrevented']},'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',(_0x480e7e,_0x132654)=>{this['cancelButtonView']['fire']('execute'),_0x132654();}),this['keystrokes']['set']('Ctrl+Enter',(_0x5ec59e,_0x4ef645)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x4ef645());}),this['on']('submit',(_0x47d16b,_0xd4205a)=>{_0xd4205a['length']>0xfde8?(alert(Et(_0x509ef2,'TOO_LONG_COMMENT_ALERT',[_0xd4205a['length'],0xfde8])),_0x47d16b['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 _0x3dbd58=this['editor'];this['element']['insertBefore'](_0x3dbd58['ui']['element'],this['element']['firstChild']),_0x3dbd58['model']['document']['on']('change',()=>this['value']=_0x3dbd58['getData']()),_0x3dbd58['bind']('placeholder')['to'](this),this['focusables']['add'](_0x3dbd58['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x14cc95){-0x1===_0x14cc95?(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:_0x1d2dab}=this,_0x5b528c=new _0x352ef3(_0x1d2dab);return _0x5b528c['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x5b528c['withText']=!0x0,_0x5b528c['bind']('label')['to'](this,'submitLabel'),_0x5b528c['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x5b528c['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0xd373a2,_0x213354)=>!_0x213354&&!!_0xd373a2['trim']()),_0x5b528c;}['_createCancelButton'](){const {locale:_0x428bde}=this,_0x551ab4=new _0x352ef3(_0x428bde);return _0x551ab4['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x551ab4['label']=Et(_0x428bde,'Cancel'),_0x551ab4['withText']=!0x0,_0x551ab4['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x551ab4;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0xb832aa=>{this['focusTracker']['add'](_0xb832aa['element']);}),this['focusables']['on']('change',(_0x536e41,_0x4e3a6d)=>{for(const _0xb23926 of Array['from'](_0x4e3a6d['added'])['reverse']())this['focusTracker']['add'](_0xb23926['element']);});}},xt=class extends ht{constructor(_0x332a1b,_0xf71272,_0x41ee7a){super(_0x332a1b),this['commentInputView']=new St(_0x332a1b,_0x41ee7a),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x53af5c,_0x10eb16)=>_0x53af5c||!!_0x10eb16),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 _0x394548(_0x332a1b,_0xf71272),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'](_0x6037ff){this['commentInputView']['focus'](_0x6037ff);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x5d9b9d,_0x3411ad)=>{const {submitButtonView:_0x113f5a,cancelButtonView:_0x3b4581,editor:_0x5ea000}=this['commentInputView'];[_0x113f5a['element'],_0x3b4581['element'],_0x5ea000?_0x5ea000['editing']['view']['getDomRoot']():null]['filter'](_0x1a7aa0=>_0x1a7aa0)['some'](_0x118aa1=>_0x118aa1['contains'](_0x3411ad['target']))||(this['focus'](),_0x3411ad['preventDefault']());});}},Pt=class extends ht{constructor(_0xa89095){super(_0xa89095);const _0x4eddfe=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x4eddfe['to']('count',_0x5beed2=>Et(_0xa89095,'NUMBER_OF_COMMENTS',_0x5beed2))}]});}},Lt=class extends ht{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x12d4f9,_0x40da95,_0xa504a8){super(_0x12d4f9);const _0x5dfda2=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x40da95['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x40da95,this['_config']=_0xa504a8,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x17ba74(),this['keystrokes']=new _0x17fd77(),this['focusCycler']=new et({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x300990=>this['commentViews']['map'](_0x53ccac=>_0x53ccac['element'])['includes'](_0x300990['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new Pt(_0x12d4f9),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x348ca3=>_0x348ca3-this['_config']['maxCommentsWhenCollapsed']);for(const _0x21c7f3 of _0x40da95['comments'])this['_handleNewCommentModel'](_0x21c7f3);this['_handleInfoComment'](),this['listenTo'](_0x40da95['comments'],'add',(_0x76d944,_0x16658b)=>{const _0x3f6d51=this['_calculatePosition'](_0x16658b);this['length']++,this['_handleNewCommentModel'](_0x16658b,_0x3f6d51),this['refreshVisibleViews']();}),this['listenTo'](_0x40da95['comments'],'remove',(_0x154aaf,_0x41d54f)=>{this['length']--,this['_handleRemoveCommentModel'](_0x41d54f),this['refreshVisibleViews']();}),this['listenTo'](_0x40da95,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x40da95,'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',_0x5dfda2['if']('length','ck-hidden',_0x6be7a=>!_0x6be7a)],'aria-label':Et(_0x12d4f9,'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'](_0x54a63a){-0x1===_0x54a63a?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x454713 of this['commentViews'])_0x454713['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x480365,_0x2f380e){const _0xceb03e=new this['_config']['CommentView'](this['locale'],_0x480365,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0xceb03e['viewUid']=_0x480365['id'],_0xceb03e['delegate']('removeComment')['to'](this),_0xceb03e['delegate']('updateComment')['to'](this),_0xceb03e['delegate']('resolveCommentThread')['to'](this),_0xceb03e['delegate']('editorReady')['to'](this),_0xceb03e['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0xceb03e,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0xceb03e,_0x2f380e);}['_calculatePosition'](_0x5446d9){const _0x335701=this['_model']['_findOptimalIndex'](_0x5446d9);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x5446d9['authoredAt']?_0x335701-0x1:_0x335701:_0x335701-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x315f19={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':Et(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x315f19,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x315f19));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x4d6684){const _0x2469c2=this['commentViews']['remove'](_0x4d6684['id']);this['stopListening'](_0x2469c2),_0x2469c2['isEditMode']&&this['_updateHasDirtyComment'](),_0x2469c2['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x45b055=>_0x45b055['isEditMode']);}['_rearrangeCollapse'](){const _0x3a22da=function(_0x2426cb){const _0x3a8445=new _0x55d760();for(const _0x7582ed of _0x2426cb)_0x3a8445['add'](_0x7582ed);return _0x3a8445;}(this['commentViews']),_0x1797d5=this['_collapsedCommentsView']['count'];for(let _0xfc087e=0x1;_0xfc087e<=_0x1797d5;_0xfc087e++)_0x3a22da['remove'](0x1);for(const _0x502ea6 of _0x3a22da)_0x502ea6['collapse']();_0x1797d5>0x0&&_0x3a22da['add'](this['_collapsedCommentsView'],0x1),Dt(_0x1de298(Array['from'](this['visibleViews']),Array['from'](_0x3a22da)),this['visibleViews'],_0x3a22da);}['_rearrangeExpand'](){Dt(_0x1de298(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0x1bbba0 of this['visibleViews'])_0x1bbba0['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x10aff2=>{this['focusTracker']['add'](_0x10aff2['element']),this['keystrokes']['listenTo'](_0x10aff2['element']);}),this['commentViews']['on']('change',(_0x3c8631,_0x8ce7d7)=>{for(const _0x5346e8 of _0x8ce7d7['removed'])this['focusTracker']['remove'](_0x5346e8['element']),this['keystrokes']['stopListening'](_0x5346e8['element']);for(const _0x523346 of Array['from'](_0x8ce7d7['added'])['reverse']())this['focusTracker']['add'](_0x523346['element']),this['keystrokes']['listenTo'](_0x523346['element']);});}};function Dt(_0x1ac181,_0x1eb36b,_0x1ddee9){let _0x5b0d27=0x0;for(const _0x3d0829 of _0x1ac181)switch(_0x3d0829){case'insert':_0x1eb36b['add'](_0x1ddee9['get'](_0x5b0d27),_0x5b0d27),_0x5b0d27++;break;case'delete':_0x1eb36b['remove'](_0x5b0d27);break;case'equal':_0x5b0d27++;}}var Vt=class extends ht{constructor(_0x5be532){super(_0x5be532);const _0xa3cccd=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0xa3cccd['to']('contextValue',_0x288406=>Et(_0x5be532,'THREAD_CONTEXT_LABEL',_0x288406)),'tabindex':-0x1},'children':[{'text':_0xa3cccd['to']('contextValue')}]});}['focus'](){this['element']['focus']();}},Bt=class extends ht{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x26319a,_0xafb6e8){super(_0x26319a);const _0x10490b=this['bindTemplate'];this['_model']=_0xafb6e8,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x17ba74(),this['keystrokes']=new _0x17fd77(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x1316a5=>!!_0x1316a5),this['bind']('contextValue')['to'](this['_model'],'context',_0x861025=>_0x861025&&_0x861025['value']?this['_trimContextValue'](_0x861025['value']):Et(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',_0x10490b['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 _0x11357e=new _0x352ef3(this['locale']);return _0x11357e['label']=Et(this['locale'],'Reopen'),_0x11357e['tooltip']=Et(this['locale'],'Reopen'),_0x11357e['icon']=_0xae80cd,_0x11357e['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x9507a2=>!_0x9507a2),_0x11357e['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x27f023,_0x592c11)=>_0x27f023&&_0x592c11),_0x11357e['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x11357e;}['_trimContextValue'](_0x548583){if(_0x548583['length']<0x96)return _0x548583;const _0x4dfc87=_0x548583['lastIndexOf']('\x20',0x93);return _0x548583['substring'](0x0,_0x4dfc87>-0x1?_0x4dfc87:0x93)+'...';}['_attachContextActions'](){const _0x512972=this['element']['querySelector']('.ck-context'),_0x1d6fb7=_0x512972['querySelector']('.ck-context__value');this['listenTo'](_0x512972,'mouseenter',()=>{_0x1d6fb7['offsetWidth']<_0x1d6fb7['scrollWidth']&&_0x512972['classList']['add']('overlay');}),this['listenTo'](_0x512972,'mouseleave',()=>{_0x512972['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x388d78 of this['focusables'])this['focusTracker']['add'](_0x388d78['element']),this['keystrokes']['listenTo'](_0x388d78['element']);}['_createContextView'](){const _0x530595=new Vt(this['locale']);return _0x530595['bind']('contextValue')['to'](this),_0x530595;}},Ht=class extends ht{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x3685a0,_0x3400b6,_0x7e816d,_0x44710f){super(_0x3685a0),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x3400b6,this['_localUser']=_0x7e816d,this['_config']=_0x44710f,this['commentThreadHeaderView']=new Bt(_0x3685a0,_0x3400b6),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new _0x3592bf(_0x3685a0,Et(_0x3685a0,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new Lt(_0x3685a0,_0x3400b6,Object['assign']({'CommentView':this['_config']['CommentView']},_0x44710f)),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',(_0x49f338,_0xea1136)=>_0x49f338||!!_0xea1136),this['bind']('isUnlinked')['to'](_0x3400b6,'unlinkedAt',_0x597b4b=>!!_0x597b4b);let _0x378c8e=null;const _0x58896c=()=>{const _0x341a12=this['_model']['comments']['first']||null;_0x341a12!==_0x378c8e&&(_0x378c8e&&this['stopListening'](_0x378c8e,'change:content'),_0x378c8e=_0x341a12,_0x341a12&&this['listenTo'](_0x341a12,'change:content',_0x58896c));const _0x37a8d3=_0x341a12?_0x341a12['author']['name']:this['_localUser']['name'],_0x8ed02d=_0x341a12?new DOMParser()['parseFromString'](_0x23e7f7(_0x341a12['content'],{'limit':this['_config']['maxCommentCharsWhenCollapsed']}),'text/html')['body']['textContent']:'',_0x420428=Et(this['locale'],'COMMENT_THREAD_LABEL',[this['length'],_0x37a8d3]);this['set']('ariaLabel',_0x8ed02d?_0x420428+'\x20'+_0x8ed02d:_0x420428);};this['listenTo'](this['_model']['comments'],'change',_0x58896c),_0x58896c(),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x17ba74(),this['keystrokes']=new _0x17fd77(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x55e5ed=>_0x55e5ed['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),_0x550d39(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0x48732c=new xt(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x299ebd=_0x48732c['commentInputView'];return _0x48732c['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x299ebd,'value',(_0x245b3d,_0x64d1d1,_0x59bef5,_0x440f74,_0x4ca0e7)=>!!_0x4ca0e7||!!_0x440f74&&_0x59bef5&&!_0x64d1d1||_0x245b3d&&_0x59bef5&&!_0x64d1d1),_0x299ebd['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x2d13aa,_0x41650e,_0x42d148)=>{let _0x1564a8;return _0x1564a8=_0x42d148&&_0x41650e?'Reply\x20to\x20reopen\x20discussion...':_0x2d13aa?'Reply...':'Write\x20a\x20comment...',Et(this['locale'],_0x1564a8);}),_0x299ebd['bind']('submitLabel')['to'](this,'length',_0x2dcf77=>Et(this['locale'],_0x2dcf77?'Reply':'Comment')),_0x299ebd['on']('submit',(_0x135d86,_0x1755b1)=>{this['fire']('addComment',_0x1755b1),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x299ebd['on']('cancel',()=>{this['focus']();}),_0x299ebd['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x299ebd['on']('cancel',_0x59484f=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x59484f['stop']());}),this['on']('change:isActive',(_0x6ce874,_0x5e1dc,_0x1085e7)=>{_0x1085e7||this['length']||_0x299ebd['value']||this['fire']('removeCommentThread');}),_0x48732c;}};const Ft=/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
_0x50d712();var $t=class Annotation extends jt{['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x22b9c9,target:_0x1c067a,type:_0xcfd672,isVisible:_0x35a798=!0x0}){super(),this['view']=_0x22b9c9,this['view']['element']||this['view']['render'](),this['_type']=_0xcfd672,this['_target']=_0x1c067a,Annotation['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x55d760([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x45961e,_0x47a497)=>{this['view']['focusTracker']['add'](_0x47a497);}),this['focusableElements']['on']('remove',(_0x4cbb39,_0x1dda16)=>{this['view']['focusTracker']['remove'](_0x1dda16);}),this['set']('isVisible',_0x35a798);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0xe3a007=this['_getNormalizedTarget']();return Annotation['_assertCorrectTarget'](_0xe3a007),_0xe3a007;}get['targetRect'](){const _0x400535=this['target'];if(null===_0x400535)return null;if(_0x400535 instanceof _0x3f7499)return _0x400535;const _0x1207cf=_0x400535['filter'](_0x2d36cc=>function(_0x129678){return!!_0x129678['offsetParent']||!!_0x129678['getClientRects']()['item'](0x0);}(_0x2d36cc));return 0x0===_0x1207cf['length']?null:_0x3f7499['getDomElementRects'](_0x1207cf[0x0])[0x0];}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x3af2fe){this['view']['isActive']=_0x3af2fe,this['view']['mainView']['isActive']=_0x3af2fe;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x3e7e59){if(!(null===_0x3e7e59||_0x3e7e59 instanceof _0x3f7499||Array['isArray'](_0x3e7e59)&&_0x3e7e59['every'](_0x1fef9f=>zt(_0x1fef9f))))throw new _0x3973a7('annotation-invalid-target',null,{'target':_0x3e7e59});}['_getNormalizedTarget'](){const _0x1cc140='function'==typeof this['_target']?this['_target']():this['_target'];return zt(_0x1cc140)?[_0x1cc140]:_0x1cc140;}};function zt(_0x1daedd){return null!==_0x1daedd&&'object'==typeof _0x1daedd&&'nodeType'in _0x1daedd&&0x1===_0x1daedd['nodeType'];}var Jt=class extends _0x55d760{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x2d172e=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x17ba74(),this['_focusTracker']['on']('change:isFocused',(_0x16710b,_0x361ab6,_0x22233e)=>{_0x22233e||this['fire']('blur');});for(const _0xc9abba of _0x2d172e)this['add'](_0xc9abba);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x5eae5b){if(this['has'](_0x5eae5b))throw new _0x3973a7('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x5eae5b['innerView'],_0x5eae5b),this['_viewToAnnotation']['set'](_0x5eae5b['view'],_0x5eae5b);for(const _0x1fdd18 of _0x5eae5b['focusableElements'])this['_focusTracker']['add'](_0x1fdd18);if(this['listenTo'](_0x5eae5b['focusableElements'],'add',(_0x91f6c1,_0x135fce)=>{this['_focusTracker']['add'](_0x135fce);}),this['listenTo'](_0x5eae5b['focusableElements'],'remove',(_0x52cbcc,_0x365d12)=>{this['_focusTracker']['remove'](_0x365d12);}),this['listenTo'](_0x5eae5b['view']['focusTracker'],'change:isFocused',(_0x259a9e,_0x20c20d,_0x28b66d)=>{_0x28b66d&&this['fire']('focus',_0x5eae5b);}),_0x5eae5b['updateTargetRect'](),this['_areCachedRectsStale']()){for(const _0x3e32cf of this)_0x3e32cf['updateTargetRect']();}const _0x4ad341=this['_getOrderInContent'](_0x5eae5b['view']['targetRect']);return super['add'](_0x5eae5b,_0x4ad341);}['remove'](_0x49c5b7){if(!this['has'](_0x49c5b7))throw new _0x3973a7('annotationcollection-not-existing-item',null);this['stopListening'](_0x49c5b7['view']['focusTracker']),this['stopListening'](_0x49c5b7['focusableElements']);for(const _0x2867e3 of _0x49c5b7['focusableElements'])this['_focusTracker']['remove'](_0x2867e3);return this['_viewToAnnotation']['delete'](_0x49c5b7['view']),this['_innerViewToAnnotation']['delete'](_0x49c5b7['innerView']),super['remove'](_0x49c5b7);}['getByInnerView'](_0x38b2e6){return this['_innerViewToAnnotation']['get'](_0x38b2e6);}['getByView'](_0x2e9fed){return this['_viewToAnnotation']['get'](_0x2e9fed);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x27459c of this)_0x27459c['updateTargetRect']();this['_sort']();}['_sort'](){const _0x252629=Array['from'](this)['sort']((_0x386fa9,_0x5c5e72)=>Zt(_0x386fa9['view']['targetRect'],_0x5c5e72['view']['targetRect']));for(let _0x3aa15d=_0x252629['length']-0x1;_0x3aa15d>0x0;_0x3aa15d--){const _0x47a936=_0x252629[_0x3aa15d];_0x3aa15d!==this['getIndex'](_0x47a936)&&(this['remove'](_0x47a936),this['add'](_0x47a936));}}['_getOrderInContent'](_0x265710){let _0x424e7a=0x0;if(!_0x265710)return this['length'];for(const _0x5575c5 of this){const _0x1824be=_0x5575c5['view']['targetRect'];if(_0x1824be){if(Zt(_0x265710,_0x1824be)<0x0)return _0x424e7a;_0x424e7a++;}}return _0x424e7a;}['_areCachedRectsStale'](){const _0x26c495=this['get'](0x0);if(!_0x26c495)return!0x1;const _0x3c8ed9=_0x26c495['view']['targetRect'],_0x22ca52=_0x26c495['targetRect'];return!(!_0x3c8ed9||!_0x22ca52)&&(_0x3c8ed9['top']!==_0x22ca52['top']||_0x3c8ed9['left']!==_0x22ca52['left']);}};function Qt({source:_0x4f3b33,target:_0x47b8c7,filter:_0x14377a}){for(const _0x4f4804 of _0x4f3b33)_0x14377a(_0x4f4804)&&_0x47b8c7['add'](_0x4f4804);_0x47b8c7['listenTo'](_0x4f3b33,'add',(_0x4795ba,_0x452c9e)=>{_0x14377a(_0x452c9e)&&_0x47b8c7['add'](_0x452c9e);}),_0x47b8c7['listenTo'](_0x4f3b33,'remove',(_0x337301,_0x4c5e3f)=>{_0x47b8c7['has'](_0x4c5e3f)&&_0x47b8c7['remove'](_0x4c5e3f);});}function Zt(_0x5b40cf,_0x401e9d){if(null===_0x5b40cf&&null===_0x401e9d)return 0x0;if(null===_0x5b40cf)return-0x1;if(null===_0x401e9d)return 0x1;const _0x3ca39f=_0x5b40cf['top']-_0x401e9d['top'];return 0x0==_0x3ca39f?_0x5b40cf['left']-_0x401e9d['left']:_0x3ca39f;}var ti=class extends _0x584f12{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x129a91){if(super(_0x129a91),this['collection']=new Jt(),this['_visibleAnnotations']=new Jt(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x129a91 instanceof _0x3c4137){const _0x2edd72=_0x129a91['locale'];_0x129a91['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':Et(_0x2edd72,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x1094b4){this['collection']['add'](_0x1094b4);}['remove'](_0x173c19){this['collection']['remove'](_0x173c19),_0x173c19['destroy']();}['refreshVisibility'](){for(const _0x471fa8 of this['collection'])_0x471fa8['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0xb43232){return this['collection']['getByInnerView'](_0xb43232);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x5237be of this['collection'])_0x5237be['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x851989){this['fire']('_activateAnnotation',_0x851989);}['createAnnotation'](_0xc6bbf6){return new $t(_0xc6bbf6);}['createAnnotationView'](_0x12b121,_0x166002){return new qt(_0x12b121,_0x166002);}['_addActiveAnnotation'](_0x3eb8b9){const _0xcabf99=new Set(this['activeAnnotations']);_0xcabf99['add'](_0x3eb8b9),this['activeAnnotations']=_0xcabf99;}['_removeActiveAnnotation'](_0x10c441){const _0x2abb56=new Set(this['activeAnnotations']);_0x2abb56['delete'](_0x10c441),this['activeAnnotations']=_0x2abb56;}['_bindAnnotationsToVisibleAnnotations'](){const _0x29f2ac=this['collection'],_0x329315=this['_visibleAnnotations'];function _0x36778e(_0x389549){const _0x541727=_0x389549['source'];_0x541727['isVisible']&&!_0x329315['has'](_0x541727)?_0x329315['add'](_0x541727):!_0x541727['isVisible']&&_0x329315['has'](_0x541727)&&_0x329315['remove'](_0x541727),_0x541727['view']['focusTracker']['remove'](_0x541727['view']['element']),_0x541727['view']['focusTracker']['add'](_0x541727['view']['element']);}this['listenTo'](_0x29f2ac,'add',(_0x513a47,_0x242574)=>{_0x242574['isVisible']&&_0x329315['add'](_0x242574),this['listenTo'](_0x242574,'change:isVisible',_0x36778e);}),this['listenTo'](_0x29f2ac,'remove',(_0x3f66fd,_0x3f50c5)=>{_0x329315['has'](_0x3f50c5)&&_0x329315['remove'](_0x3f50c5),this['stopListening'](_0x3f50c5,'change:isVisible',_0x36778e);});}['_setupEnterAnnotationKeystroke'](){const _0x58ebee=_0x10383a=>{_0x10383a['on']('ready',()=>{_0x10383a['keystrokes']['set'](_0x2f877e,(_0x5873b1,_0x30039b)=>{const _0x348dd6=_0x90b9b4(this['activeAnnotations']['values']());_0x348dd6&&(_0x348dd6['view']['focus'](),_0x30039b());});});};this['context']instanceof _0x3c4137?_0x58ebee(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x4a7efa,_0x33a55b)=>{_0x58ebee(_0x33a55b);});}['_setupEscapeAnnotationHandling'](){const _0x2b4869=_0x54730c=>{const _0x2268e2=_0x54730c['source'],_0x1025fb=[];let _0x942d53;if(Array['isArray'](_0x2268e2['target'])){_0x942d53=_0x2268e2['target'][0x0],this['context']instanceof _0x3c4137?_0x1025fb['push'](this['context']):this['context']['editors']&&_0x1025fb['push'](...this['context']['editors']);for(const _0xd6d08a of _0x1025fb)for(const _0x2d78bd of _0xd6d08a['editing']['view']['domRoots']['values']())if(_0x2d78bd['contains'](_0x942d53))return void _0xd6d08a['editing']['view']['focus']();_0x942d53['focus']();}};this['listenTo'](this['collection'],'add',(_0xfe2a7,_0x1b69f8)=>{this['listenTo'](_0x1b69f8,'escape',_0x2b4869,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x5c7237,_0x8eb3a0)=>{this['stopListening'](_0x8eb3a0,'escape',_0x2b4869);});}};const ii=Symbol('noChannel'),ei={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0},si=/* #__PURE__ -- @preserve */
|
|
30
|
-
|
|
31
|
-
_0x50d712();var oi=class extends _0x584f12{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[ti,_0x5a9d3d,_0x29eb39];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4ee1f0){super(_0x4ee1f0),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x38a6b0=this['context']['config'];_0x38a6b0['define']('comments.maxCommentsWhenCollapsed',0x2),_0x38a6b0['define']('comments.maxThreadTotalWeight',0x1f4),_0x38a6b0['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x38a6b0['define']('comments.CommentThreadView',Ut),_0x38a6b0['define']('comments.CommentView',Yt),_0x38a6b0['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0x3f1b6b=this['context']['plugins']['get'](ti);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x391438,_0x5a5f76)=>this['_addCommentThread'](_0x5a5f76)),this['on']('submitCommentThread',(_0x594012,_0x5a3d3d)=>this['_submitCommentThread'](_0x5a3d3d)),this['on']('resolveCommentThread',(_0x484140,_0x32f940)=>this['_resolveCommentThread'](_0x32f940)),this['on']('resolveCommentThread',(_0x49a9e6,_0x6d5d72)=>this['_updateActiveAnnotation'](_0x6d5d72),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x488e0f,_0x2879f7)=>this['_reopenCommentThread'](_0x2879f7)),this['on']('reopenCommentThread',(_0x2093da,_0x1f254c)=>this['_updateActiveAnnotation'](_0x1f254c),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x4f19a0,_0x395baa)=>this['_removeCommentThread'](_0x395baa)),this['on']('updateCommentThread',(_0x2cade3,_0x2f38b0)=>this['_updateCommentThread'](_0x2f38b0)),this['on']('updateCommentThread',(_0x2afd8d,_0x5c1114)=>this['_updateActiveAnnotation'](_0x5c1114),{'priority':'lowest'}),this['on']('addComment',(_0x235b1e,_0x1a92e7)=>this['_addComment'](_0x1a92e7)),this['on']('updateComment',(_0x347273,_0x2e40e1)=>this['_updateComment'](_0x2e40e1)),this['on']('removeComment',(_0x315b00,_0x104052)=>this['_removeComment'](_0x104052)),this['on']('addComment',(_0x35e204,{threadId:_0x56850,isFromAdapter:_0x34cb8c})=>{if(_0x34cb8c)return;const _0x3796d6=this['getCommentThread'](_0x56850),_0x51b59a=_0x3796d6&&this['_threadToController']['get'](_0x3796d6);_0x51b59a&&_0x51b59a['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0x3f1b6b,'change:activeAnnotations',(_0x5bf035,_0x44583d,_0x555c00)=>{const _0x1d4dc8=Array['from'](_0x555c00)['map'](_0x4b80b6=>this['_viewToController']['get'](_0x4b80b6['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x1d4dc8?_0x1d4dc8['model']:null;});}set['adapter'](_0xe6bd1f){if(this['_adapter'])throw new _0x3973a7('commentsrepository-adapter-already-set');this['_adapter']=_0xe6bd1f;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x374eea=ii,threadId:_0x36afbf=_0x228023(),comments:_0x447d34=[],unlinkedAt:_0x815bf6=null,resolvedAt:_0x32db8d=null,resolvedBy:_0x407a2a=null,target:_0x107f5a=null,context:_0x5e2496=null,attributes:_0x4e39a8={},isResolvable:_0x488740=!0x0,isSubmitted:_0xa8560b=!0x1,isFromAdapter:_0x53d593=!0x1}={}){return this['fire'](ai('addCommentThread',_0x374eea),{'channelId':_0x374eea,'threadId':_0x36afbf,'comments':_0x447d34,'unlinkedAt':_0x815bf6,'resolvedAt':_0x32db8d,'resolvedBy':_0x407a2a,'target':_0x107f5a,'context':_0x5e2496,'attributes':_0x4e39a8,'isFromAdapter':_0x53d593,'isResolvable':_0x488740,'isSubmitted':_0xa8560b}),this['getCommentThread'](_0x36afbf);}['openNewCommentThread']({channelId:_0x559653=ii,threadId:_0x24eef5=_0x228023(),target:_0x4af00c,context:_0x14c59d=null,isResolvable:_0x4d863b=!0x0}){if(this['_readOnlyChannels']['has'](_0x559653)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x4af00c)throw new _0x3973a7('commentsrepository-missing-target');const _0x3af8e1=this['addCommentThread']({'channelId':_0x559653,'threadId':_0x24eef5,'target':_0x4af00c,'context':_0x14c59d,'isResolvable':_0x4d863b});if(!_0x3af8e1)return null;const _0x18311e=this['_threadToController']['get'](_0x3af8e1),_0x2777f5=_0x18311e['view']['commentThreadInputView']['commentInputView'],_0x2744ee=this['context']['plugins']['get'](ti),_0x159f31=_0x2744ee['getByInnerView'](_0x18311e['view']);return _0x2744ee['activate'](_0x159f31),_0x2777f5['once']('editorReady',()=>_0x2777f5['focus']()),_0x3af8e1;}['hasCommentThread'](_0x393f04){if('string'!=typeof _0x393f04)throw new _0x3973a7('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x393f04);}['updateCommentThread']({channelId:_0x407e2b=ii,threadId:_0x41acb6,context:_0x5a6513,unlinkedAt:_0x32e252,attributes:_0x4c87da,isFromAdapter:_0x2fdafe=!0x1}){return this['fire'](ai('updateCommentThread',_0x407e2b),{'channelId':_0x407e2b,'threadId':_0x41acb6,'context':_0x5a6513,'unlinkedAt':_0x32e252,'attributes':_0x4c87da,'isFromAdapter':_0x2fdafe}),this['getCommentThread'](_0x41acb6);}['getCommentThread'](_0xa3095d){if('string'!=typeof _0xa3095d)throw new _0x3973a7('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0xa3095d);}['fetchCommentThread']({channelId:_0x26354a,threadId:_0x1e95d1}={}){const _0x530a46=this['getCommentThread'](_0x1e95d1);if(_0x530a46)return Promise['resolve'](_0x530a46);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x3973a7('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x26354a,'threadId':_0x1e95d1})['then'](_0x555fba=>this['hasCommentThread'](_0x1e95d1)?this['getCommentThread'](_0x1e95d1):_0x555fba?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x26354a},_0x555fba)):void 0x0)['catch'](_0xd44b2a=>{throw console['error'](_0xd44b2a),new _0x3973a7('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x8f9908,skipNotAttached:_0x1f5634=!0x1,skipEmpty:_0xcf5af1=!0x1,toJSON:_0x52c32f=!0x1}={}){const _0x44a78a=[];for(const _0x5b3146 of this['_threads']['values']())_0x8f9908&&_0x5b3146['channelId']!==_0x8f9908||_0x1f5634&&!_0x5b3146['isAttached']||_0xcf5af1&&0x0===_0x5b3146['length']||_0x44a78a['push'](_0x5b3146);return _0x52c32f?_0x44a78a['map'](_0x377208=>_0x377208['toJSON']()):_0x44a78a;}['getAnnotationForCommentThread'](_0x220808){const _0x35b657=this['_threadToController']['get'](_0x220808);return _0x35b657&&this['context']['plugins']['get'](ti)['getByInnerView'](_0x35b657['view'])||null;}['getCommentThreadForAnnotation'](_0x58bdf0){const _0x4a9257=this['_viewToController']['get'](_0x58bdf0['innerView']);return _0x4a9257?_0x4a9257['model']:null;}['setActiveCommentThread'](_0x73228){const _0x3f277c=this['context']['plugins']['get'](ti);if(!_0x73228)return void(this['activeCommentThread']&&_0x3f277c['deactivateAll']());const _0x3d6cf3=this['getCommentThread'](_0x73228);if(!_0x3d6cf3)throw new _0x3973a7('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x73228});if(!this['_threadToController']['has'](_0x3d6cf3))throw new _0x3973a7('commentsrepository-active-not-attached',null,{'threadId':_0x73228});const _0x363d5f=_0x3f277c['getByInnerView'](this['_threadToController']['get'](_0x3d6cf3)['view']);_0x3f277c['activate'](_0x363d5f);}['switchReadOnly'](_0x570d37,_0x4475bd){_0x570d37?this['_readOnlyChannels']['add'](_0x4475bd):this['_readOnlyChannels']['delete'](_0x4475bd),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x41f852){return this['_readOnlyChannels']['has'](_0x41f852)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x3bc956,_0x123372){return new bt(_0x3bc956,_0x123372);}['setPermissions'](_0x11ed2f,_0x4b4333=ii){this['_permissions']['set'](_0x4b4333,_0x11ed2f),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x22de91=ii){return this['_permissions']['has'](_0x22de91)?this['_permissions']['get'](_0x22de91):ei;}['_addCommentThread']({channelId:_0x5f0ab0,threadId:_0x40c375,comments:_0x1fc163,unlinkedAt:_0x25931d,resolvedAt:_0x40761a,resolvedBy:_0x22b63d,target:_0x3b1411,context:_0xc66627,attributes:_0x24b47e,isFromAdapter:_0x1f417c,isResolvable:_0x256b1b,isSubmitted:_0x5aa50c}){if('string'!=typeof _0x40c375)throw new _0x3973a7('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x40c375});if(this['hasCommentThread'](_0x40c375))throw new _0x3973a7('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x40c375});const _0x21a972=new ri(this,{'channelId':_0x5f0ab0,'id':_0x40c375,'context':_0xc66627,'attributes':_0x24b47e,'unlinkedAt':_0x25931d,'resolvedAt':_0x40761a,'resolvedBy':_0x22b63d?this['context']['plugins']['get'](_0x29eb39)['getUser'](_0x22b63d):null,'isResolvable':_0x256b1b,'isSubmitted':_0x5aa50c||_0x1f417c});this['_threads']['set'](_0x40c375,_0x21a972);for(const _0x1b9f18 of _0x1fc163)_0x21a972['_add'](this['_createNewComment']({'threadId':_0x40c375,..._0x1b9f18}));return _0x3b1411&&_0x21a972['attachTo'](_0x3b1411),_0x1f417c||!_0x21a972['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x5f0ab0,'threadId':_0x40c375});}['_submitCommentThread']({channelId:_0xa71acf,threadId:_0x40202b}){if(!this['hasCommentThread'](_0x40202b))throw new _0x3973a7('commentsrepository-missing-comment-thread',this);const _0x2e093d=this['getCommentThread'](_0x40202b);if(_0x2e093d['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x2f5214,comments:_0x6faac,resolvedAt:_0x19aa26,resolvedBy:_0x56fd1b,context:_0x2151b4,attributes:_0x43a8fe}=_0x2e093d,_0x4f1647=this['context']['plugins']['get']('PendingActions'),_0x23dbe6=_0x4f1647['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0xa71acf,'threadId':_0x2f5214,'comments':_0x6faac['map'](_0x1869a1=>_0x1869a1['toJSON']()),'resolvedAt':_0x19aa26,'resolvedBy':_0x56fd1b?_0x56fd1b['id']:_0x56fd1b,'context':_0x2151b4,'attributes':_0x43a8fe})['then'](({comments:_0x4ac47f})=>{_0x4f1647['remove'](_0x23dbe6);for(const _0x248d6f of _0x4ac47f)this['_updateComment']({'channelId':_0xa71acf,'threadId':_0x40202b,'commentId':_0x248d6f['commentId'],'createdAt':_0x248d6f['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x215a02=>{throw console['error'](_0x215a02),new _0x3973a7('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x4f6e78,target:_0x1314ba}){const _0x1b0f8e=this['getCommentThread'](_0x4f6e78);if(!_0x1b0f8e)throw new _0x3973a7('commentsrepository-attach-missing-comment-thread',this);const _0x75edfb=this['context']['plugins']['get']('PendingActions'),_0x435146=this['context']['plugins']['get'](ti),_0x4c597d=this['_createCommentThreadView'](_0x1b0f8e),_0x3183c9=new bt(_0x1b0f8e,_0x4c597d);let _0x3ca647=null;_0x4c597d['on']('change:isDirty',(_0x147550,_0x13084f,_0x1d690b)=>{_0x1d690b?_0x3ca647=_0x75edfb['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x3ca647&&(_0x75edfb['remove'](_0x3ca647),_0x3ca647=null);}),this['_threadToController']['set'](_0x1b0f8e,_0x3183c9),this['_viewToController']['set'](_0x4c597d,_0x3183c9);const _0x452661=new qt(this['context']['locale'],_0x4c597d);_0x452661['bind']('length')['to'](_0x4c597d),_0x452661['bind']('isDirty')['to'](_0x4c597d,'isDirty',_0x4c597d,'length',(_0x26b1b6,_0x50974b)=>_0x26b1b6||!_0x50974b),_0x452661['bind']('isActive')['to'](_0x4c597d),_0x452661['type']='comment';const _0x49f247=new $t({'view':_0x452661,'target':_0x1314ba,'type':'comment','isVisible':!_0x1b0f8e['archivedAt']&&!!('function'==typeof _0x1314ba?_0x1314ba():_0x1314ba)});return _0x4c597d['on']('escape',()=>{_0x49f247['fire']('escape');}),this['_bindAnnotationToEditors'](_0x4c597d,_0x49f247),_0x435146['add'](_0x49f247),_0x49f247;}['_bindAnnotationToEditors'](_0x2c7b9e,_0x1d6ab5){this['listenTo'](_0x2c7b9e,'editorReady',(_0x1e2f29,_0x30a3ee)=>{const _0x38208a=_0x30a3ee['ui']['view']['body']['bodyCollectionContainer'];_0x1d6ab5['focusableElements']['add'](_0x38208a),this['context']instanceof _0x3c4137&&this['context']['ui']['focusTracker']['add'](_0x38208a);},{'priority':'highest'}),this['listenTo'](_0x2c7b9e,'editorDestroyed',(_0x22a16a,_0x424b6c)=>{const _0x12e114=_0x424b6c['ui']['view']['body']['bodyCollectionContainer'];_0x1d6ab5['focusableElements']['has'](_0x12e114)&&_0x1d6ab5['focusableElements']['remove'](_0x12e114),this['context']instanceof _0x3c4137&&this['context']['ui']['focusTracker']['remove'](_0x12e114);});}['_unbindEditors'](_0x291a89){this['stopListening'](_0x291a89,'editorReady'),this['stopListening'](_0x291a89,'editorDestroyed');}['_createCommentThreadView'](_0x3c5edc){const _0x287141=this['context']['plugins']['get'](_0x29eb39),{config:_0x4174ba,locale:_0x33fb35}=this['context'],_0x3fa20a=_0x120c49(_0x4174ba['get']('locale'),_0x33fb35);return new(0x0,(_0x4174ba['get']('comments'))['CommentThreadView'])(_0x33fb35,_0x3c5edc,_0x287141['me'],{'editorConfig':{..._0x4174ba['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x4174ba['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x4174ba['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x4174ba['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x4174ba['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x3fa20a,'CommentView':_0x4174ba['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x50608f,channelId:_0x2f34b4,resolvedAt:_0x341d7c,resolvedBy:_0x3d27de,isFromAdapter:_0x2ced30}){if(!this['hasCommentThread'](_0x50608f))throw new _0x3973a7('commentsrepository-missing-comment-thread',null,{'threadId':_0x50608f});const _0x2b0fa0=this['getCommentThread'](_0x50608f);if(_0x2b0fa0['isResolved'])throw new _0x3973a7('commentsrepository-resolved-comment-thread',null,{'threadId':_0x50608f});const _0x18d694=this['context']['plugins']['get'](_0x29eb39);if(_0x2b0fa0['resolvedBy']=_0x18d694['getUser'](_0x3d27de),_0x2b0fa0['resolvedAt']=_0x341d7c,_0x2ced30||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x480de8=this['context']['plugins']['get']('PendingActions'),_0x53701c=_0x480de8['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x2f34b4,'threadId':_0x50608f})['then'](({resolvedAt:_0x5453c8,resolvedBy:_0x1978b6})=>{_0x480de8['remove'](_0x53701c),_0x2b0fa0['resolvedBy']['id']!==_0x1978b6&&(_0x2b0fa0['resolvedBy']=_0x18d694['getUser'](_0x1978b6)),_0x2b0fa0['resolvedAt']=_0x5453c8;})['catch'](_0x222640=>{throw console['error'](_0x222640),new _0x3973a7('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x218867,channelId:_0x59dea9,isFromAdapter:_0x1c959a}){if(!this['hasCommentThread'](_0x218867))throw new _0x3973a7('commentsrepository-missing-comment-thread',null,{'threadId':_0x218867});const _0x139042=this['getCommentThread'](_0x218867);if(!_0x139042['isResolved'])throw new _0x3973a7('commentsrepository-reopen-comment-thread',null,{'threadId':_0x218867});if(_0x139042['resolvedBy']=null,_0x139042['resolvedAt']=null,_0x1c959a||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x4fd6ba=this['context']['plugins']['get']('PendingActions'),_0xab7686=_0x4fd6ba['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x59dea9,'threadId':_0x218867})['then'](()=>_0x4fd6ba['remove'](_0xab7686))['catch'](_0x1dfe4c=>{throw console['error'](_0x1dfe4c),new _0x3973a7('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x13cda2,isFromAdapter:_0x98a159}){const _0x113d82=this['getCommentThread'](_0x13cda2);if(!_0x113d82)throw new _0x3973a7('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x13cda2),this['_threads']['delete'](_0x13cda2),!_0x113d82['isSubmitted']||_0x98a159||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x563c52=this['context']['plugins']['get']('PendingActions'),{channelId:_0x346830}=_0x113d82,_0x524b77=_0x563c52['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x346830,'threadId':_0x13cda2})['then'](()=>_0x563c52['remove'](_0x524b77))['catch'](_0x40fe54=>{throw console['error'](_0x40fe54),new _0x3973a7('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x3c06d6,unlinkedAt:_0x5ec88e,context:_0x585dc8,attributes:_0x9ec9f5,isFromAdapter:_0x21db14}){if('string'!=typeof _0x3c06d6)throw new _0x3973a7('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x3c06d6});if(!this['hasCommentThread'](_0x3c06d6))throw new _0x3973a7('commentsrepository-missing-comment-thread',null,{'threadId':_0x3c06d6});const _0x5b1860=this['getCommentThread'](_0x3c06d6);let _0x140f96=!0x1;if(void 0x0!==_0x585dc8&&_0x5b1860['context']!==_0x585dc8&&(_0x5b1860['context']=_0x585dc8,_0x140f96=!0x0),void 0x0!==_0x5ec88e&&_0x5b1860['unlinkedAt']!==_0x5ec88e&&(_0x5b1860['unlinkedAt']=_0x5ec88e,_0x140f96=!0x0),_0x9ec9f5&&!_0x3a45f3(_0x9ec9f5,_0x5b1860['attributes'])&&(_0x5b1860['attributes']=_0x9ec9f5,_0x140f96=!0x0),!_0x140f96)return Promise['resolve']();if(!_0x5b1860['isSubmitted']||_0x21db14||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x286b91=this['context']['plugins']['get']('PendingActions'),{channelId:_0x2df400}=_0x5b1860,_0x217f1d=_0x286b91['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x2df400,'threadId':_0x3c06d6,'context':_0x585dc8,'unlinkedAt':_0x5ec88e,'attributes':_0x9ec9f5})['then'](()=>_0x286b91['remove'](_0x217f1d))['catch'](_0x41c863=>{throw console['error'](_0x41c863),new _0x3973a7('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x33d949){const _0xfc9d35=this['context']['plugins']['get'](ti),_0x25db5e=this['getCommentThread'](_0x33d949);if(_0x25db5e['_isAttached']=!0x1,this['_threadToController']['has'](_0x25db5e)){const _0x2f8f66=this['_threadToController']['get'](_0x25db5e),_0x2fdaf4=_0x2f8f66['view'],_0x27c365=_0xfc9d35['getByInnerView'](_0x2fdaf4);this['_threadToController']['delete'](_0x25db5e),this['_viewToController']['delete'](_0x2fdaf4),_0x27c365&&_0xfc9d35['remove'](_0x27c365),_0x2f8f66['destroy'](),_0x2fdaf4['destroy']()['then'](()=>{this['_unbindEditors'](_0x2fdaf4);});}}['_updateActiveAnnotation']({threadId:_0x2a0c6d,resolvedAt:_0x3d14bf,unlinkedAt:_0x35a338}){const _0x148c69=!!_0x3d14bf,_0x233dde=this['context']['plugins']['get'](ti),_0x4f8424=this['getCommentThread'](_0x2a0c6d);if(this['_threadToController']['has'](_0x4f8424)){const _0x53308e=this['_threadToController']['get'](_0x4f8424)['view'],_0x57459b=_0x233dde['getByInnerView'](_0x53308e);_0x57459b&&(_0x148c69&&_0x233dde['_removeActiveAnnotation'](_0x57459b),_0x35a338?_0x57459b['isVisible']=!0x1:_0x57459b['refreshVisibility']());}}['_getExternalAuthor'](_0x41d4ac){const _0x5c993f=this['context']['plugins']['get'](_0x29eb39),_0x13bd80=_0x191b3b('external:'+_0x41d4ac),_0x518f00=_0x5c993f['getUser'](_0x13bd80);return _0x518f00||_0x5c993f['addUser']({'id':_0x13bd80,'name':_0x41d4ac});}['_createNewComment']({threadId:_0x1c05e3,commentId:_0x11ed8a=_0x228023(),content:_0x3292b5,authorId:_0x5cb21a,createdAt:_0x1ae0a2,attributes:_0x447f6e}){if('string'!=typeof _0x11ed8a)throw new _0x3973a7('commentsrepository-invalid-commentid');if('string'!=typeof _0x5cb21a)throw new _0x3973a7('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x3292b5||!_0x3292b5['trim']())throw new _0x3973a7('commentsrepository-invalid-comment-content');const _0x1ede43=this['context']['plugins']['get'](_0x29eb39)['getUser'](_0x5cb21a);if(!_0x1ede43)throw new _0x3973a7('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x5cb21a});let _0x1a0cc9=null,_0x3edbfe=_0x1ae0a2;return _0x447f6e?.['@external']&&(_0x1a0cc9=this['_getExternalAuthor'](_0x447f6e['@external']['authorName']),_0x3edbfe=new Date(_0x447f6e['@external']['createdAt'])),new hi(this,{'threadId':_0x1c05e3,'id':_0x11ed8a,'author':_0x1a0cc9||_0x1ede43,'creator':_0x1ede43,'content':_0x3292b5,'createdAt':_0x1ae0a2,'authoredAt':_0x3edbfe,'attributes':_0x447f6e});}['_addComment'](_0x2733bc){let {threadId:_0xc78b3b,content:_0x2758e8,attributes:_0x24d543,isFromAdapter:_0x159aaa}=_0x2733bc;const _0x8b38fa=this['getCommentThread'](_0x2733bc['threadId']);if(!_0x8b38fa)throw new _0x3973a7('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x2cf414=this['_createNewComment'](_0x2733bc),{id:_0x44c5d0}=_0x2cf414;if(_0x8b38fa['_add'](_0x2cf414),_0x159aaa||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0x8b38fa['isSubmitted'])return Promise['resolve']();const _0x5410fb=this['context']['plugins']['get']('PendingActions'),{channelId:_0x524730}=_0x8b38fa,_0x522738=_0x5410fb['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x24d543||(_0x24d543={}),this['adapter']['addComment']({'channelId':_0x524730,'threadId':_0xc78b3b,'commentId':_0x44c5d0,'content':_0x2758e8,'attributes':_0x24d543})['then'](_0xcf835f=>{_0x5410fb['remove'](_0x522738),_0xcf835f&&this['_updateComment']({'channelId':_0x524730,'threadId':_0xc78b3b,'commentId':_0x44c5d0,'createdAt':_0xcf835f['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x53903f=>{throw console['error'](_0x53903f),new _0x3973a7('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x3d7129,commentId:_0x154b1b,content:_0x237be2,createdAt:_0x4a449d,attributes:_0x296459,isFromAdapter:_0x8c8b89}){if(void 0x0!==_0x237be2&&('string'!=typeof _0x237be2||!_0x237be2['trim']()['length']))throw new _0x3973a7('commentsrepository-update-comment-invalid-content');const _0x51aae2=this['getCommentThread'](_0x3d7129),_0x2ae94a=_0x51aae2['getComment'](_0x154b1b);if(!_0x2ae94a)throw new _0x3973a7('commentsrepository-update-missing-comment',this);let _0x514229=!0x1;if(_0x237be2&&_0x237be2!==_0x2ae94a['content']&&(_0x2ae94a['isEditable']||_0x8c8b89)&&(_0x2ae94a['content']=_0x237be2,_0x514229=!0x0),_0x4a449d&&_0x4a449d!==_0x2ae94a['createdAt']&&(_0x2ae94a['createdAt']=_0x4a449d,_0x2ae94a['isExternal']||(_0x2ae94a['authoredAt']=_0x4a449d),_0x514229=!0x0),_0x296459&&!_0x3a45f3(_0x296459,_0x2ae94a['attributes'])&&(_0x2ae94a['attributes']=_0x296459,_0x514229=!0x0),!_0x514229)return Promise['resolve']();if(_0x51aae2['fire']('commentUpdated'),_0x8c8b89||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0x37f0dd=this['context']['plugins']['get']('PendingActions'),{channelId:_0x202ab3}=this['getCommentThread'](_0x2ae94a['threadId']),_0x398a38=_0x37f0dd['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x202ab3,'threadId':_0x3d7129,'commentId':_0x154b1b,'content':_0x237be2,'attributes':_0x296459})['then'](()=>_0x37f0dd['remove'](_0x398a38))['catch'](_0x4747fe=>{throw console['error'](_0x4747fe),new _0x3973a7('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0x3379c6,commentId:_0x1b69af,isFromAdapter:_0x319eb7}){const _0x3354cb=this['getCommentThread'](_0x3379c6),_0x574b2e=_0x3354cb['getComment'](_0x1b69af);if(!_0x574b2e)throw new _0x3973a7('commentsrepository-remove-missing-comment',this);if(_0x3354cb['_remove'](_0x574b2e),_0x319eb7||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x5adb41=this['context']['plugins']['get']('PendingActions'),{channelId:_0x30239c}=_0x3354cb,_0x4d640f=_0x5adb41['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x30239c,'threadId':_0x3379c6,'commentId':_0x1b69af})['then'](()=>_0x5adb41['remove'](_0x4d640f))['catch'](_0x3f7752=>{throw console['error'](_0x3f7752),new _0x3973a7('commentsrepository-remove-comment-internal-error',this);});}},ri=class extends si{['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x2e47d9,_0x556baf){super();const _0x17942b=_0x556baf['isResolvable'];this['channelId']=_0x556baf['channelId'],this['id']=_0x556baf['id'],this['comments']=new _0x55d760(),this['_repository']=_0x2e47d9,this['_isAttached']=!0x1,this['_isSubmitted']=_0x556baf['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x2e47d9,'_permissions',_0x2e47d9,'_readOnlyChannels',()=>_0x2e47d9['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x2e47d9,'_permissions',()=>_0x2e47d9['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x2e47d9,'_permissions',()=>{const _0x1cc8ce=_0x2e47d9['getPermissions'](this['channelId']);return _0x1cc8ce['write']||_0x1cc8ce['admin'];}),this['bind']('isResolvable')['to'](_0x2e47d9,'_permissions',()=>_0x17942b&&_0x2e47d9['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x556baf['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x5f5db3,_0x3bc357)=>_0x5f5db3?_0x3bc357?_0x5f5db3<_0x3bc357?_0x5f5db3:_0x3bc357:_0x5f5db3:_0x3bc357),this['set']('unlinkedAt',_0x556baf['unlinkedAt']||null),this['set']('resolvedAt',_0x556baf['resolvedAt']||null),this['set']('resolvedBy',_0x556baf['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x1fa938=>!!_0x1fa938),this['set']('attributes',_0x556baf['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0xc85afd,_0x3c1bfc)=>_0xc85afd+_0x3c1bfc['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x5c685d,id:_0xd51693}=this;this['_repository']['fire'](ai('submitCommentThread',_0x5c685d),{'channelId':_0x5c685d,'threadId':_0xd51693});}['setUnlinkedAt'](_0x5a491d){this['_update']({'unlinkedAt':_0x5a491d});}['resolve']({resolvedAt:_0x5afb52=new Date(),resolvedBy:_0x5d2f60='',isFromAdapter:_0x31018b=!0x1}={}){const _0x4d1923=this['_repository']['context']['plugins']['get'](_0x29eb39)['me'],{channelId:_0x4d9141,id:_0x2889c0}=this;this['_repository']['fire'](ai('resolveCommentThread',_0x4d9141),{'channelId':_0x4d9141,'threadId':_0x2889c0,'resolvedAt':_0x5afb52,'resolvedBy':_0x5d2f60||_0x4d1923['id'],'isFromAdapter':_0x31018b});}['reopen']({isFromAdapter:_0x486042=!0x1}={}){const {channelId:_0x3cd7d8,id:_0x42fdae}=this;this['_repository']['fire'](ai('reopenCommentThread',_0x3cd7d8),{'channelId':_0x3cd7d8,'threadId':_0x42fdae,'isFromAdapter':_0x486042});}['setContext'](_0xbcecb8){this['context']||this['_update']({'context':_0xbcecb8});}['setAttribute'](_0x33b216,_0x58a8cc){const _0x141610=_0x3bbce8(this['attributes']);_0x1c2903(_0x141610,_0x33b216,_0x58a8cc),this['_update']({'attributes':_0x141610});}['removeAttribute'](_0x4f09da){const _0x2985da=_0x3bbce8(this['attributes']);_0x4899cc(_0x2985da,_0x4f09da),this['_update']({'attributes':_0x2985da});}['remove']({isFromAdapter:_0x4432c8=!0x1}={}){const {channelId:_0x12f726,id:_0x317a60}=this;this['_repository']['fire'](ai('removeCommentThread',_0x12f726),{'channelId':_0x12f726,'threadId':_0x317a60,'isFromAdapter':_0x4432c8});}['attachTo'](_0x435176){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0x435176});}['addComment'](_0x1861c4){const {channelId:_0x56738e,id:_0x31f7ef}=this;this['_repository']['fire'](ai('addComment',_0x56738e,_0x31f7ef),Object['assign']({'channelId':_0x56738e,'threadId':_0x31f7ef},_0x1861c4));}['getComment'](_0x6a9043){if('string'!=typeof _0x6a9043)throw new _0x3973a7('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x6a9043});return this['comments']['get'](_0x6a9043);}['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'](_0x2f4cc7=>_0x2f4cc7['toJSON']()),'attributes':this['attributes']};}['_add'](_0x12089d){return this['listenTo'](_0x12089d,'change:authoredAt',()=>{const _0x52bf76=this['_findOptimalIndex'](_0x12089d),_0x1175a5=this['comments'];_0x52bf76-0x1!=_0x1175a5['getIndex'](_0x12089d)&&_0x52bf76+0x1!=_0x1175a5['getIndex'](_0x12089d)&&(this['_remove'](_0x12089d),this['_add'](_0x12089d));}),this['comments']['add'](_0x12089d,this['_findOptimalIndex'](_0x12089d));}['_update'](_0x5c1dc8){const {channelId:_0x3a5346,id:_0x90df5a}=this;this['_repository']['fire'](ai('updateCommentThread',_0x3a5346),{..._0x5c1dc8,'channelId':_0x3a5346,'threadId':_0x90df5a});}['_remove'](_0x56c889){return this['stopListening'](_0x56c889),_0x56c889['destroy'](),this['comments']['remove'](_0x56c889);}['_findOptimalIndex'](_0x1da091){const _0x7f9742=this['comments']['find'](_0x2f5487=>new Date(_0x2f5487['authoredAt'])['getTime']()>new Date(_0x1da091['authoredAt'])['getTime']());return _0x7f9742?this['comments']['getIndex'](_0x7f9742):this['length'];}},hi=class extends ni{['id'];['threadId'];['author'];['creator'];['createdAt'];['_repository'];constructor(_0x258c66,_0x3d69c4){super();const _0x1bbca0=_0x258c66['context']['plugins']['get'](_0x29eb39)['me'],_0x5b13b0=_0x258c66['getCommentThread'](_0x3d69c4['threadId']),_0x54379b=0x0===_0x5b13b0['comments']['length'],_0x26593f=_0x1bbca0===_0x3d69c4['author'];this['id']=_0x3d69c4['id'],this['threadId']=_0x3d69c4['threadId'],this['author']=_0x3d69c4['author'],this['creator']=_0x3d69c4['creator'],this['set']('content',_0x3d69c4['content']),this['createdAt']=_0x3d69c4['createdAt']||new Date(),this['set']('authoredAt',_0x3d69c4['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x5b13b0,'resolvedAt'),this['set']('attributes',_0x3d69c4['attributes']||{}),this['bind']('isEditable')['to'](_0x258c66,'_permissions',()=>{const _0x1db467=_0x258c66['getPermissions'](_0x5b13b0['channelId'])['write'],_0x18a054=_0x258c66['getPermissions'](_0x5b13b0['channelId'])['modifyAll'];return _0x26593f&&_0x1db467||!_0x26593f&&_0x18a054;}),this['bind']('isRemovable')['to'](_0x5b13b0,'isRemovable',_0x258c66,'_permissions',_0x3c827c=>{const _0xaeac37=_0x258c66['getPermissions'](_0x5b13b0['channelId'])['write'],_0xe109a4=_0x258c66['getPermissions'](_0x5b13b0['channelId'])['modifyAll'];return _0x26593f&&_0xaeac37||_0x3c827c&&_0x54379b||!_0x26593f&&_0xe109a4&&!_0x54379b;}),this['bind']('isReadOnly')['to'](_0x5b13b0,'isReadOnly'),this['_repository']=_0x258c66;}get['isExternal'](){return Boolean(this['attributes']&&this['attributes']['@external']);}get['weight'](){return Math['max'](function(_0x1297d1){const _0x57a809=document['createElement']('div');return _0x57a809['innerHTML']=_0x1297d1,_0x57a809['textContent']['length'];}(this['content']),0xc8);}['update'](_0x3c63d4){const {threadId:_0x1865d2,id:_0x360c67}=this;if(!this['_repository']['hasCommentThread'](_0x1865d2))throw new _0x3973a7('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x23f2d3}=this['_repository']['getCommentThread'](_0x1865d2);this['_repository']['fire'](ai('updateComment',_0x23f2d3,_0x1865d2),{'channelId':_0x23f2d3,'threadId':_0x1865d2,'commentId':_0x360c67,..._0x3c63d4});}['setAttribute'](_0x4cc897,_0x2491a4){const _0x4d2f92=_0x3bbce8(this['attributes']);_0x1c2903(_0x4d2f92,_0x4cc897,_0x2491a4),this['update']({'attributes':_0x4d2f92});}['removeAttribute'](_0x320bea){const _0x29e55a=_0x3bbce8(this['attributes']);_0x4899cc(_0x29e55a,_0x320bea),this['update']({'attributes':_0x29e55a});}['remove'](_0x42c0a3={}){if(!_0x42c0a3['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x1339b1,id:_0x4dba15}=this;if(!this['_repository']['hasCommentThread'](_0x1339b1))throw new _0x3973a7('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x5912bc}=this['_repository']['getCommentThread'](_0x1339b1);this['_repository']['fire'](ai('removeComment',_0x5912bc,_0x1339b1),{'channelId':_0x5912bc,'threadId':_0x1339b1,'commentId':_0x4dba15,..._0x42c0a3});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}};function ai(_0x2a9096,..._0x3cc62b){for(const _0x5e902c of _0x3cc62b)void 0x0!==_0x5e902c&&(_0x2a9096+=':'+String(_0x5e902c));return _0x2a9096;}var ci=class extends _0x25fd83{constructor(_0x1deb36){super(_0x1deb36),this['set']('hasContent',!0x1);}['refresh'](){const _0x21014b=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x1bc33e of _0x21014b['getRanges']())if(this['_hasContent'](_0x1bc33e))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x309e39=_0x228023(),ranges:_0x1d6a25,comment:_0x209604}={}){const _0x342c76=this['editor']['model'],_0x82f962=_0x1d6a25??Array['from'](_0x342c76['document']['selection']['getRanges']()),_0x50b929=[];for(const _0x307388 of _0x82f962)this['_hasContent'](_0x307388)&&_0x50b929['push'](this['_trimToContent'](_0x307388));if(!_0x50b929['length'])throw new _0x3973a7('addcommentthreadcommand-incorrect-ranges',null);_0x209604&&this['_createCommentThread'](_0x309e39,_0x209604),this['_createMarkersFromRanges'](_0x309e39,_0x50b929,!!_0x209604);}['_createMarkersFromRanges'](_0x2fa52e,_0x40f117,_0x12e0e1){this['editor']['model']['change'](_0x28c973=>{for(const _0x51fe6a of _0x40f117){const _0x36ccbd='comment:'+_0x2fa52e+':'+_0x228023()['substr'](0x1,0x5);_0x28c973['addMarker'](_0x36ccbd,{'range':_0x51fe6a,'usingOperation':_0x12e0e1,'affectsData':_0x12e0e1});}});}['_createCommentThread'](_0x5c8042,_0x43a4b3){const _0x4bae5b=this['editor']['plugins']['get']('CommentsRepository'),_0x465311=this['editor']['config']['get']('collaboration.channelId'),_0x4e282c=this['editor']['plugins']['get']('Users')['me'];if(!_0x4e282c)throw new _0x3973a7('addcommentthreadcommand-user-not-found',null);_0x4bae5b['addCommentThread']({'threadId':_0x5c8042,'channelId':_0x465311,'comments':[{'authorId':_0x4e282c['id'],'content':_0x43a4b3,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x1aba4a){for(const _0x2b8e84 of _0x1aba4a['getItems']())if(this['_itemIsContent'](_0x2b8e84))return!0x0;return!0x1;}['_itemIsContent'](_0x302ab7){return _0x302ab7['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x302ab7)&&!_0x302ab7['is']('element','tableCell');}['_trimToContent'](_0x481332){const _0x1dbe04=_0x5af515=>!this['_itemIsContent'](_0x5af515['item']),_0x3f13f4=_0x481332['start']['getLastMatchingPosition'](_0x1dbe04),_0x44b39e=_0x481332['end']['getLastMatchingPosition'](_0x1dbe04,{'direction':'backward'});return this['editor']['model']['createRange'](_0x3f13f4,_0x44b39e);}},di=class extends _0x580aef{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[ti];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xad3598){super(_0xad3598),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0x14a158=this['editor'],_0x35070d=_0x14a158['model']['document']['selection'],_0xfb2df7=_0x488046(()=>this['refreshSelectedViews'](),0xa);_0x35070d['on']('change:range',(_0x259b4c,_0x53bb53)=>{_0x53bb53['directChange']&&(_0xfb2df7['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0x14a158['editing']['view']['document'],'change:isFocused',(_0x2968f8,_0x1607a0,_0x34e9aa)=>{_0x34e9aa&&_0xfb2df7();}),this['listenTo'](_0x14a158['ui']['focusTracker'],'change:isFocused',(_0x2ece4f,_0x395b23,_0x290315)=>{_0x290315||this['fire']('blur',{'isAnnotationTracked':_0x2b7a23=>this['_editorAnnotationsData']['has'](_0x2b7a23['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x32b8f6){if(this['_editorAnnotations']['has'](_0x32b8f6['view']))return;this['_editorAnnotations']['add'](_0x32b8f6['view']),this['editor']['ui']['focusTracker']['add'](_0x32b8f6['view']['element']);const _0x44eda7=this['editor']['plugins']['get'](ti);this['listenTo'](_0x44eda7['collection'],'remove',(_0x274b90,_0xefc0fc)=>{this['editor']['ui']['focusTracker']['remove'](_0xefc0fc['view']['element']),this['_editorAnnotations']['delete'](_0xefc0fc['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x10cb26){if('function'!=typeof _0x10cb26)throw new _0x3973a7('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x10cb26);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x426a89,annotations:_0x393c2c}){const _0x52aefb=[],_0x16c83a=this['editor']['model']['document']['selection'],_0x365037=Array['from'](_0x16c83a['getRanges']());for(const [_0x3b5712,_0x5e2a0e]of this['_editorAnnotationsData']){const _0x501bfa=_0x2043df(_0x5e2a0e),_0x7d239a=_0x393c2c['getByInnerView'](_0x3b5712);_0x501bfa&&_0x7d239a&&_0x52aefb['push']({'annotation':_0x7d239a,'range':_0x501bfa});}function _0x2043df(_0x11d8fe){for(const _0x1981ae of _0x11d8fe)for(const _0xa12117 of _0x365037)if(_0x1981ae['containsRange'](_0xa12117,!_0x16c83a['isCollapsed']))return _0x1981ae;return null;}return _0x52aefb['sort']((_0x1180bf,_0x543fcf)=>{const _0x33fd77=_0x1180bf['range'],_0x4a062b=_0x543fcf['range'];if(!_0x33fd77['isEqual'](_0x4a062b)){if(_0x33fd77['containsRange'](_0x4a062b,!0x0))return 0x1;if(_0x4a062b['containsRange'](_0x33fd77,!0x0))return-0x1;}return _0x1180bf['annotation']==_0x426a89?-0x1:_0x543fcf['annotation']==_0x426a89?0x1:0x0;})['map'](_0x19beca=>_0x19beca['annotation']);}get['_editorAnnotationsData'](){const _0x57444f=new Map();for(const _0x25d508 of Array['from'](this['_dataCollectors']))for(const [_0x45a707,_0x24d2de]of _0x25d508())_0x57444f['set'](_0x45a707,_0x24d2de);return _0x57444f;}},li=class extends _0x580aef{['afterInit'](){const _0x459262=this['editor'];_0x459262['plugins']['has']('RestrictedEditingModeEditing')&&_0x459262['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}},mi=class extends _0x580aef{constructor(_0x51307c){super(_0x51307c),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x2948a0=this['editor'],_0xc0d08c=_0x2948a0['commands']['get']('importWord'),_0x2a4bd2=_0x2948a0['plugins']['get'](_0x29eb39);_0xc0d08c&&(_0xc0d08c['on']('execute',(_0x4614cc,[,_0x21b80a])=>{_0x21b80a['collaboration_features']={'comments':!0x0,'user_id':_0x2a4bd2['me']['id']};},{'priority':_0x454ece['high']+0xa}),this['listenTo'](_0xc0d08c,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x3b0bbf,_0x5e0ffc){const {comment_threads:_0x285700}=_0x5e0ffc;_0x285700&&_0x285700['forEach'](({thread_id:_0x31e578,comments:_0x19aab4,is_resolved:_0x1fff39})=>{const _0x239045=new Date(),_0x14dc9c=_0x19aab4['map'](({author:_0x213655,content:_0x4bb0e3,created_at:_0x326086})=>({'content':_0x4bb0e3,'authorId':this['editor']['plugins']['get'](_0x29eb39)['me']['id'],'createdAt':_0x239045,'attributes':{'@external':{'authorName':_0x213655,'createdAt':_0x326086?new Date(_0x326086):new Date(),'source':'importWord'}}})),_0x246749=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](oi)['addCommentThread']({'channelId':_0x246749,'threadId':_0x31e578,'comments':_0x14dc9c,'resolvedAt':_0x1fff39?_0x239045:null});});}},ui=class extends _0x580aef{constructor(_0x57fcba){super(_0x57fcba),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[pt,wt];}['afterInit'](){const _0x4c8d37=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x4c8d37,'contentInsertion',(_0x54f1f2,_0x412b32)=>this['_removeMarkersWithoutThreads'](_0x412b32['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x408f61){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x408f61;const _0x48c0a2=this['editor']['plugins']['get']('CommentsRepository');for(const _0x5a0b11 of _0x408f61['keys']()){const [_0x57e3ec,_0x30de25]=_0x5a0b11['split'](':');'comment'!=_0x57e3ec||_0x48c0a2['hasCommentThread'](_0x30de25)||_0x408f61['delete'](_0x5a0b11);}return _0x408f61;}['_registerMarkerInClipboardPipeline'](){const _0x1e62ec=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x5971db=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x5971db&&_0x1e62ec['_registerMarkerToCopy']('comment',_0x5971db);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x3bc4b9){switch(_0x3bc4b9){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}};function fi(_0xb20474){const _0x1a9cf9=_0xb20474['split'](':');return{'group':_0x1a9cf9[0x0],'id':_0x1a9cf9[0x1],'part':_0x1a9cf9[0x2]};}var pi=class extends _0x580aef{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x481d3d,_0x390c97)=>{if(!_0x390c97['options']['showCommentHighlights'])return null;if(_0x390c97['options']['ignoreResolvedComments']){const {id:_0x248160}=fi(_0x481d3d['markerName']);if(this['editor']['plugins']['get'](oi)['getCommentThread'](_0x248160)?.['isResolved']&&_0x481d3d['item'])return _0x390c97['consumable']['consume'](_0x481d3d['item'],'addMarker:'+_0x481d3d['markerName']),_0x390c97['consumable']['consume'](_0x481d3d['item'],'removeMarker:'+_0x481d3d['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x19b2f7=>{_0x19b2f7['on']('addMarker:comment',(_0x1b6bc6,_0x569ea3,_0x2d034f)=>{if(!_0x2d034f['options']['showCommentHighlights'])return;const _0x5a877e=_0x569ea3['item'];if(!_0x5a877e)return;const _0x3f1695=_0x2d034f['mapper']['toViewElement'](_0x5a877e);this['editor']['model']['schema']['isObject'](_0x5a877e)&&_0x3f1695&&!_0x3f1695['getCustomProperty']('widget')&&_0x3f1695['is']('containerElement')&&Ct(_0x3f1695,_0x2d034f['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x4efbdc,{writer:_0x466e20,options:_0x45a58d})=>{if(!_0x45a58d['showCommentHighlights'])return null;const _0x2c5cf7=_0x466e20['createContainerElement']('div'),_0x2bf859=_0x466e20['createEmptyElement']('hr');return _0x466e20['addClass']('ck-horizontal-line',_0x2c5cf7),_0x466e20['insert'](_0x466e20['createPositionAt'](_0x2c5cf7,0x0),_0x2bf859),_0x2c5cf7;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x3ab856,{writer:_0x29b7d9,options:_0xc7e717})=>{if(!_0xc7e717['showCommentHighlights'])return null;const _0x58b399=_0x29b7d9['createContainerElement']('span'),_0x3054ca=_0x29b7d9['createEmptyElement']('img');return _0x29b7d9['addClass']('image-inline',_0x58b399),_0x29b7d9['insert'](_0x29b7d9['createPositionAt'](_0x58b399,0x0),_0x3054ca),_0x58b399;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x190421,{writer:_0x4651d5,options:_0x8ad628})=>{if(_0x8ad628['showCommentHighlights'])return _0x4651d5['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x1c68b5,_0x3da35a,_0x36cbbd)=>{_0x36cbbd['options']['showCommentHighlights']&&_0x1c68b5['stop']();},{'priority':'high'});}},wi=class extends _0x580aef{static get['requires'](){return[oi,di,_0x29eb39,li,mi,ui,pi];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2d7218){super(_0x2d7218),this['set']('isThreadsLoadingPaused',!0x0),_0x2d7218['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x3c760e,_0x24333d,_0x5c3f52,_0x1da73f)=>{const _0x3c9858=_0x2d7218['plugins']['get'](oi),_0x571d9b=_0x5c3f52?fi(_0x5c3f52)['id']:null;_0x2d7218['model']['change'](()=>{if(_0x571d9b){const _0x14cdff=this['getAllMarkersForId'](_0x571d9b);for(const _0x31224d of _0x14cdff)_0x2d7218['editing']['reconvertMarker'](_0x31224d);}if(_0x1da73f){const {id:_0x4b3ead}=fi(_0x1da73f),_0x2c8da4=_0x3c9858['getCommentThread'](_0x4b3ead);if(_0x2c8da4&&_0x2c8da4['unlinkedAt'])return;if(_0x2c8da4&&!_0x2c8da4['isAttached'])return;const _0x21a2ea=this['getAllMarkersForId'](_0x4b3ead);for(const _0x49cc84 of _0x21a2ea)_0x2d7218['editing']['reconvertMarker'](_0x49cc84);}}),_0x571d9b&&this['scrollToThreadMarker'](_0x571d9b);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x2f8c10=this['editor'],_0x32d2f3=_0x2f8c10['plugins']['get'](oi),_0x30ef1b=_0x2f8c10['config']['get']('collaboration.channelId'),_0x30def9=_0x32d2f3['getCommentThreads']()['filter'](_0x41d47e=>_0x41d47e['channelId']!==_0x30ef1b);_0x2f8c10['commands']['add']('addCommentThread',new ci(_0x2f8c10)),this['listenTo'](_0x2f8c10,'change:isReadOnly',(_0x1b5491,_0x4dd554,_0x1f8b90)=>{_0x32d2f3['switchReadOnly'](_0x1f8b90,_0x2f8c10['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x32d2f3,gi('addCommentThread',_0x30ef1b),(_0x21f347,{threadId:_0x42f755})=>{this['editor']['plugins']['get'](oi)['getCommentThread'](_0x42f755)?.['unlinkedAt']&&this['_attachArchivedThread'](_0x42f755);}),this['listenTo'](_0x32d2f3,gi('removeCommentThread',_0x30ef1b),(_0x57cd01,{threadId:_0xe3cc8a})=>{_0x2f8c10['model']['enqueueChange']({'isUndoable':!0x1},_0x114a64=>{const _0x3b34a9=this['getAllMarkersForId'](_0xe3cc8a);for(const _0x4797cf of _0x3b34a9)_0x114a64['removeMarker'](_0x4797cf);});}),this['listenTo'](_0x32d2f3,gi('resolveCommentThread',_0x30ef1b),(_0x10ab4a,{threadId:_0x2a3c22})=>{this['_reconvertMarkers'](_0x2a3c22);const _0x573646=this['editor']['plugins']['get'](ti);(this['editor']['editing']['view']['hasDomSelection']||_0x573646['collection']['isFocused'])&&(this['editor']['plugins']['get'](oi)['getCommentThread'](_0x2a3c22)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x32d2f3,gi('reopenCommentThread',_0x30ef1b),(_0x4def81,{threadId:_0x500f5f})=>{this['_reconvertMarkers'](_0x500f5f);},{'priority':'low'}),this['listenTo'](_0x32d2f3,gi('addComment',_0x30ef1b),(_0x3b4d72,{threadId:_0x210dfa,isFromAdapter:_0x4e65f0})=>{const _0x5183c7=this['getAllMarkersForId'](_0x210dfa);!_0x4e65f0&&0x0!=_0x5183c7['length']&&_0x32d2f3['hasCommentThread'](_0x210dfa)&&0x1===_0x32d2f3['getCommentThread'](_0x210dfa)['length']&&_0x2f8c10['model']['enqueueChange']({'isUndoable':!0x1},_0x47330e=>{for(const _0x4be70f of _0x5183c7)_0x47330e['updateMarker'](_0x4be70f,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x30def9);}['afterInit'](){!async function(_0x57c772){const _0x4581ac='KpOBJGNSEgqCyfVF1kZ8lbnRjM7eIzAsDQHw9aThu6rcYi05UmPL4d3X2Wotvx',_0x55865f=0x78e58,_0x3397e9=window['Date']['now'](),_0x807ae8=_0x57c772['editor'],_0x52bd34=new window['Promise'](_0x2413e7=>{_0x807ae8['once']('ready',_0x2413e7);}),_0x4e49e7={'kty':'EC','use':'sig','crv':'P-256','x':'iCjOCvDFI6lQHHT18jVwRfkfHQ2a_MymT35LQVoFSAI','y':'kXIyJ4evtCEFRmxKSUpK9fDW459vXOvVrhf6uQAeOio','alg':'ES256'},_0x5e71d3=_0x807ae8['config']['get']('licenseKey');async function _0x5b0ea5(){let _0x441da0,_0x5aa7dc=null,_0x369b67=null;try{return'GPL'==_0x5e71d3?'NotAllowed':(_0x441da0=_0x4fcdf1(),_0x441da0?(_0x441da0['usageEndpoint']&&(_0x369b67=_0x57c05b(_0x441da0['usageEndpoint'],_0x441da0['jti'])),await _0x34584d()?_0x345fa1()?_0x1eb3f0()?'Expired':_0x2bcaf8()?('evaluation'==_0x441da0['licenseType']&&(_0x5aa7dc=_0x2ac3ff('EvaluationLimit')),await _0x282795()):'DomainLimit':'NotAllowed':'Invalid'):'Invalid');}catch{return'Invalid';}function _0x1eb3f0(){const _0x7284aa=['evaluation','trial']['includes'](_0x441da0['licenseType'])?_0x3397e9/0x3e8:0xe10*_0x55865f;return _0x441da0['exp']<_0x7284aa;}function _0x345fa1(){const _0x4982aa=_0x441da0['features'];if(!_0x4982aa)return!0x1;if(_0x4982aa['includes']('*'))return!0x0;if(_0x4982aa['includes']('CMT'))return!0x0;if(_0x4982aa['includes']('TRILIUM')&&_0x1cd196())return!0x0;if(_0x4982aa['includes']('RCMT')){if(_0x587ad3())return!0x0;if(_0x2b34b3()||_0x1b3953())return!0x0;}return!0x1;}function _0x2bcaf8(){const _0x7316e3=_0x441da0['licensedHosts'];if(!_0x7316e3||0x0==_0x7316e3['length'])return!0x0;const {hostname:_0x88ecb6}=new URL(window['location']['href']);if(_0x7316e3['includes'](_0x88ecb6))return!0x0;const _0x3ab719=_0x88ecb6['split']('.');return _0x7316e3['filter'](_0x1db525=>_0x1db525['includes']('*'))['map'](_0x19bbe2=>_0x19bbe2['split']('.'))['filter'](_0x53e09a=>_0x53e09a['length']<=_0x3ab719['length'])['map'](_0x508a28=>Array(_0x3ab719['length']-_0x508a28['length'])['fill']('*'===_0x508a28[0x0]?'*':'')['concat'](_0x508a28))['some'](_0x514c79=>_0x3ab719['every']((_0x349e38,_0x228e13)=>_0x514c79[_0x228e13]===_0x349e38||'*'===_0x514c79[_0x228e13]));}function _0x282795(){return _0x5aa7dc&&_0x369b67?new window['Promise']((_0x35afe0,_0x511825)=>{_0x5aa7dc['then'](_0x35afe0,_0x511825),_0x369b67['then'](_0xd75116=>{'Valid'!=_0xd75116&&_0x35afe0(_0xd75116);},_0x511825);}):_0x5aa7dc||_0x369b67||'Valid';}}function _0x57c05b(_0x5a4e93,_0x5144fb){return new window['Promise'](_0x5d5536=>{if(_0x397633())return _0x5d5536('Valid');_0x3a6023(),_0x807ae8['decorate']('_sendUsageRequest');let _0xf364f7=!0x1;const _0x2d0917=_0x228023();function _0x547d5e(_0xa61184){return!!_0xa61184&&('object'==typeof _0xa61184||'function'==typeof _0xa61184)&&'function'==typeof _0xa61184['then']&&'function'==typeof _0xa61184['catch'];}function _0x274598(_0x3c56cf){_0x302c84(_0x3c56cf)['then'](_0x3b3bef=>_0x3b3bef&&'ok'==_0x3b3bef['status']?_0x1510bb(_0xa29369(_0x2d0917+_0x5144fb))!=_0x3b3bef['verification']?'UsageLimit':'Valid':'UsageLimit')['then'](_0x547618=>(_0x358ef1(),_0x547618),()=>{const _0x404678=_0x3e36b9();return null==_0x404678?(_0x358ef1(),'Valid'):_0x3397e9-_0x404678>0x240c8400?'UsageLimit':'Valid';})['then'](_0x5d5536)['catch'](()=>{_0x5d5536('UsageLimit');});const _0x64a7ef=0x36ee80;function _0x358ef1(){const _0x11bd73='llct-'+_0x1510bb(_0xa29369(_0x5a4e93)),_0x46a05c=_0x443bbb(_0x1510bb(window['Math']['ceil'](_0x3397e9/_0x64a7ef)));window['localStorage']['setItem'](_0x11bd73,_0x46a05c);}function _0x3e36b9(){const _0xd74521='llct-'+_0x1510bb(_0xa29369(_0x5a4e93)),_0x58e6b4=window['localStorage']['getItem'](_0xd74521);return _0x58e6b4?window['parseInt'](_0x443bbb(_0x58e6b4),0x10)*_0x64a7ef:null;}function _0x302c84(_0x241efb){return new window['Promise']((_0x356643,_0x7699ce)=>{_0x241efb['then'](_0x356643,_0x7699ce),window['setTimeout'](_0x7699ce,0x1d4c0);});}}_0x807ae8['on']('_sendUsageRequest',(_0x47726d,_0xf7a26c)=>{if(_0xf7a26c[0x0]!=_0x5a4e93)return _0x5d5536('UsageLimit');_0xf7a26c[0x1]={..._0xf7a26c[0x1],'requestId':_0x2d0917};},{'priority':'high'}),_0x807ae8['on']('_sendUsageRequest',_0x1c5fca=>{_0x547d5e(_0x1c5fca['return'])&&(_0xf364f7=!0x0,_0x274598(_0x1c5fca['return']));},{'priority':'low'}),_0x52bd34['then'](()=>{_0xf364f7||_0x5d5536('UsageLimit');});});function _0x397633(){return'auto'==_0x807ae8['editing']['view']['_overlayModeHint'];}function _0x3a6023(){_0x807ae8['editing']['view']['_overlayModeHint']='auto';}}function _0x2ac3ff(_0x30af07){const _0x12460b=[new window['Promise'](_0x38d551=>setTimeout(_0x38d551,0x93ecc)),_0x52bd34['then'](()=>new window['Promise'](_0x5f1cda=>{let _0x402470=0x0;_0x807ae8['model']['on']('applyOperation',(_0x28fa73,_0x56562b)=>{_0x56562b[0x0]['isDocumentOperation']&&_0x402470++,0x5e8==_0x402470&&(_0x5f1cda(),_0x28fa73['off']());});}))];return window['Promise']['race'](_0x12460b)['then'](()=>_0x30af07);}async function _0x46e5ce(){await _0x52bd34,_0x807ae8['model']['change']=_0x367c34,_0x807ae8['model']['enqueueChange']=_0x367c34,_0x807ae8['enableReadOnlyMode']('model');}function _0x1cd196(){return window['glob']&&window['glob']['triliumVersion'];}function _0x587ad3(){return _0x309677('WebSocketGateway')&&'connected'==_0x239b8a('WebSocketGateway')['state'];}function _0x2b34b3(){return _0x309677('RevisionViewerIntegration');}function _0x1b3953(){return _0x309677('TrackChangesDataGetter');}function _0x312667(_0x305fd2){const _0x12e180=_0x45108d();_0x807ae8[_0x12e180]='commentsLicenseKey'+_0x305fd2,'Valid'!=_0x305fd2&&_0x46e5ce();}function _0x45108d(){const _0x12b92=window['String'](window['performance']['now']())['replace']('.','');let _0x1a80cc='K';for(let _0x3d3445=0x0;_0x3d3445<_0x12b92['length'];_0x3d3445+=0x2){let _0x2adb03=window['parseInt'](_0x12b92['substring'](_0x3d3445,_0x3d3445+0x2));_0x2adb03>=0x3e&&(_0x2adb03-=0x3e),_0x1a80cc+=_0x4581ac[_0x2adb03];}return _0x1a80cc;}function _0x4fcdf1(){const _0x58d97a=_0x5e71d3['split']('.');if(0x3!=_0x58d97a['length'])return null;return _0x4d375b(_0x58d97a[0x1]);function _0x4d375b(_0x2f67ea){const _0x1e0e1b=_0x30b7b3(_0x2f67ea);return _0x1e0e1b&&_0x5c706a()?_0x1e0e1b:null;function _0x5c706a(){const _0x4196c3=_0x1e0e1b['jti'],_0x39dc00=window['parseInt'](_0x4196c3['substring'](_0x4196c3['length']-0x8),0x10),_0x11b029={..._0x1e0e1b,'jti':_0x4196c3['substring'](0x0,_0x4196c3['length']-0x8)};return delete _0x11b029['vc'],_0xa29369(_0x11b029)==_0x39dc00;}}}async function _0x34584d(){let _0x4ef82f=!0x0;try{const [_0xd4ed3a,_0x5b40ba,_0x3569b7]=_0x5e71d3['split']('.');return _0x14b1c5(_0xd4ed3a),await _0x48448f(_0xd4ed3a,_0x5b40ba,_0x3569b7),_0x4ef82f;}catch{return!0x1;}function _0x14b1c5(_0x11da0d){const _0x5bd00c=_0x30b7b3(_0x11da0d);_0x5bd00c&&'ES256'==_0x5bd00c['alg']||(_0x4ef82f=!0x1);}async function _0x48448f(_0xb2b6c2,_0x7de9fe,_0x5453d0){const _0x30cf9b=window['Uint8Array']['from'](_0x109a68(_0x5453d0),_0x21512d=>_0x21512d['charCodeAt'](0x0)),_0x64be48=new window['TextEncoder']()['encode'](_0xb2b6c2+'.'+_0x7de9fe),_0x476daa=window['crypto']['subtle'];if(!_0x476daa)return;const _0x5dc8db=await _0x476daa['importKey']('jwk',_0x4e49e7,{'name':'ECDSA','namedCurve':'P-256'},!0x1,['verify']);await _0x476daa['verify']({'name':'ECDSA','hash':{'name':'SHA-256'}},_0x5dc8db,_0x30cf9b,_0x64be48)||(_0x4ef82f=!0x1);}}function _0x30b7b3(_0x115c60){return _0x115c60['startsWith']('ey')?JSON['parse'](_0x109a68(_0x115c60)):null;}function _0x109a68(_0x1b3cab){return window['atob'](_0x1b3cab['replace'](/-/g,'+')['replace'](/_/g,'/'));}function _0xa29369(_0x147c97){let _0x30bc71=0x1505;function _0x36c096(_0x4fee32){for(let _0x1501da=0x0;_0x1501da<_0x4fee32['length'];_0x1501da++){const _0x16f838=_0x4fee32['charCodeAt'](_0x1501da);_0x30bc71=(_0x30bc71<<0x5)+_0x30bc71+_0x16f838,_0x30bc71&=_0x30bc71;}}function _0x27c1e6(_0x39fe2f){Array['isArray'](_0x39fe2f)?_0x39fe2f['forEach'](_0x27c1e6):_0x39fe2f&&'object'==typeof _0x39fe2f?Object['entries'](_0x39fe2f)['sort']()['forEach'](([_0x534adb,_0x2ed328])=>{_0x36c096(_0x534adb),_0x27c1e6(_0x2ed328);}):_0x36c096(window['String'](_0x39fe2f));}return _0x27c1e6(_0x147c97),_0x30bc71>>>0x0;}function _0x1510bb(_0x815ba2){return _0x815ba2['toString'](0x10)['padStart'](0x8,'0');}function _0x443bbb(_0x473b0e){return _0x473b0e['split']('')['reverse']()['join']('');}function _0x309677(_0x56396f){return _0x807ae8['plugins']['has'](_0x56396f);}function _0x239b8a(_0x1c788e){return _0x807ae8['plugins']['get'](_0x1c788e);}function _0x367c34(){}_0x312667(await _0x5b0ea5());}(this);}['destroy'](){const _0x36f777=this['editor']['plugins']['get'](oi),_0xc3e13b=this['editor']['config']['get']('collaboration.channelId');for(const _0x16031c of _0x36f777['getCommentThreads']({'channelId':_0xc3e13b}))_0x36f777['_detachCommentThread'](_0x16031c['id']),_0x36f777['_threads']['delete'](_0x16031c['id']);super['destroy']();}['hasMarkerForId'](_0x8235db){return this['getAllMarkersForId'](_0x8235db)['length']>0x0;}['getAllMarkersForId'](_0x228719){const _0x47ef8e=[];for(const _0x15a264 of this['editor']['model']['markers'])_0x15a264['name']['startsWith']('comment:'+_0x228719)&&_0x47ef8e['push'](_0x15a264);return _0x47ef8e;}['scrollToThreadMarker'](_0x20bf3a){setTimeout(()=>{const _0x2b8aed=this['_getTargetForId'](_0x20bf3a);_0x2b8aed&&this['activeMarker']&&fi(this['activeMarker'])['id']===_0x20bf3a&&_0x3650d4({'target':_0x2b8aed[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0x5cdc32){this['editor']['model']['change'](()=>{for(const _0x40f0fa of this['getAllMarkersForId'](_0x5cdc32))this['editor']['editing']['reconvertMarker'](_0x40f0fa);});}['_attachArchivedThread'](_0x4cb7f1){const _0x3ccd95=this['editor']['plugins']['get'](oi),_0x22304f=this['editor']['plugins']['get'](di),_0x3683e0=_0x3ccd95['getCommentThread'](_0x4cb7f1);if(!_0x3683e0['isAttached']){const _0x317a02=_0x3683e0['attachTo'](()=>this['_getTargetForId'](_0x3683e0['id']));_0x22304f['registerAnnotation'](_0x317a02),_0x3683e0['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0x275f09=this['editor'],_0x556583=_0x275f09['plugins']['get'](_0x29eb39);_0x275f09['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x37d592,_0x5a105e)=>{const {id:_0x4a77bf}=fi(_0x37d592['markerName']),_0x101175=_0x275f09['plugins']['get'](oi)['getCommentThread'](_0x4a77bf),_0xe9c135=this['activeMarker']&&fi(this['activeMarker'])['id']===_0x4a77bf;let _0x23f946;if(_0x101175&&_0x101175['isResolved']&&!_0xe9c135&&_0x37d592['item'])return _0x5a105e['consumable']['consume'](_0x37d592['item'],'addMarker:'+_0x37d592['markerName']),_0x5a105e['consumable']['consume'](_0x37d592['item'],'removeMarker:'+_0x37d592['markerName']),null;const _0x4d3952=['ck-comment-marker'];return _0xe9c135&&_0x4d3952['push']('ck-comment-marker--active'),_0x23f946=_0x101175?.['length']?_0x101175['comments']['first']['author']['id']:_0x556583['me']['id'],{'classes':_0x4d3952,'attributes':{'data-comment':_0x4a77bf,'data-author-id':_0x23f946}};}}),_0x275f09['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x3b85cb,{options:_0x4396ff})=>{if(_0x4396ff['showCommentHighlights'])return null;const _0x1bb2d7=_0x275f09['plugins']['get'](oi),_0x282a6f=_0x275f09['model']['markers']['get'](_0x3b85cb),{id:_0x4e4729,part:_0x172891}=fi(_0x3b85cb);return _0x282a6f&&!_0x282a6f['affectsData']||_0x4396ff['ignoreResolvedComments']&&_0x1bb2d7['getCommentThread'](_0x4e4729)?.['isResolved']?null:{'group':'comment','name':_0x172891?_0x4e4729+':'+_0x172891:_0x4e4729};}}),_0x275f09['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0x3c9b39,{writer:_0x42fc13})=>_0x42fc13['createElement']('$marker',{'data-name':'comment:'+_0x3c9b39['getAttribute']('id')})}),_0x275f09['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x4f79e7=this['editor'],_0x5c3316=_0x4f79e7['plugins']['get'](oi),_0x579d8d=new Set(),_0x2c1863=new Set();_0x4f79e7['model']['document']['registerPostFixer'](_0x279f2a=>{let _0x32e734=!0x1;for(const {name:_0x730740,data:_0x31c3b0}of _0x4f79e7['model']['document']['differ']['getChangedMarkers']()){const {group:_0x50c848,id:_0xa9862c}=fi(_0x730740);let _0x196dd1=_0x31c3b0['newRange'];if('comment'!==_0x50c848||!_0x196dd1)continue;const _0xd98212='$graveyard'===_0x196dd1['root']['rootName'];_0xd98212||(_0x196dd1=_i(_0x196dd1,_0x4f79e7['model']),!_0x196dd1||_0x196dd1['isCollapsed']||!_0x31c3b0['newRange']||_0x196dd1['isEqual'](_0x31c3b0['newRange']))?_0x4f79e7['model']['hasContent'](_0x196dd1)&&!_0xd98212?this['isThreadsLoadingPaused']?_0x579d8d['add'](_0x730740):this['_handleThreadMarker'](_0x730740,_0xa9862c):(_0x2c1863['add'](_0x730740),_0x579d8d['delete'](_0x730740),_0x279f2a['removeMarker'](_0x730740),_0x32e734=!0x0):(_0x279f2a['updateMarker'](_0x730740,{'range':_0x196dd1}),_0x32e734=!0x0);}return _0x32e734;}),this['on']('change:isThreadsLoadingPaused',(_0x2a4ce0,_0x3f3076,_0x3e0d3a)=>{if(!_0x3e0d3a&&_0x579d8d['size'])for(const _0x448efd of _0x579d8d){const {id:_0x536f63}=fi(_0x448efd);_0x579d8d['delete'](_0x448efd),_0x4f79e7['model']['markers']['get'](_0x448efd)&&this['_handleThreadMarker'](_0x448efd,_0x536f63);}}),this['listenTo'](_0x4f79e7['model']['document'],'change',()=>{for(const {name:_0x25789c,data:{newRange:_0x3e7b2c}}of _0x4f79e7['model']['document']['differ']['getChangedMarkers']()){const {group:_0x564cc0,id:_0x2ba1a4}=fi(_0x25789c);if('comment'!==_0x564cc0)continue;const _0x190316=_0x5c3316['getCommentThread'](_0x2ba1a4),_0x25d8e1=this['hasMarkerForId'](_0x2ba1a4);_0x190316&&(!_0x190316['_hasTargetInContent']&&_0x3e7b2c&&_0x4f79e7['editing']['view']['once']('render',()=>{const _0x10adcb=_0x4f79e7['plugins']['get'](ti),_0x50c95f=_0x5c3316['_threadToController']['get'](_0x190316)['view'];_0x10adcb['getByInnerView'](_0x50c95f)['refreshVisibility']();},{'priority':'low'}),_0x190316['_hasTargetInContent']=_0x25d8e1||!!_0x3e7b2c),_0x3e7b2c||(_0x2c1863['add'](_0x25789c),_0x579d8d['delete'](_0x25789c));}for(const _0x28d2c0 of _0x2c1863){const {id:_0x70b39f}=fi(_0x28d2c0),_0xf02f1=_0x5c3316['getCommentThread'](_0x70b39f);if(_0x579d8d['delete'](_0x28d2c0),!_0xf02f1)continue;const _0x1f0cb4=this['hasMarkerForId'](_0x70b39f);_0x1f0cb4||_0xf02f1['isSubmitted']?_0x1f0cb4||_0xf02f1['unlinkedAt']||_0xf02f1['setUnlinkedAt'](new Date()):_0xf02f1['remove']();}_0x2c1863['clear']();});}['_handleInitialThreads'](_0xfad73b){_0xfad73b['forEach'](_0xdbfa25=>{_0xdbfa25['unlinkedAt']&&this['_attachArchivedThread'](_0xdbfa25['id']);});}['_getTargetForId'](_0x41bddd){const _0x4c02c9=this['editor'],_0x264bce=this['getAllMarkersForId'](_0x41bddd);return _0x1bc54f(_0x4c02c9['editing'],_0x264bce);}['_getTextContext'](_0x33d30f){const _0x3e4bd0=this['getAllMarkersForId'](_0x33d30f);let _0x1b203c='',_0x4b5ef4=!0x1;for(const _0x58ba9c of _0x3e4bd0){const _0x5c9272=_0x58ba9c['getRange']();for(const _0x2b9266 of Array['from'](_0x5c9272['getItems']()))_0x2b9266['is']('$textProxy')?(_0x1b203c&&_0x4b5ef4&&(_0x1b203c+='\x20',_0x4b5ef4=!0x1),_0x1b203c+=_0x2b9266['data']):_0x4b5ef4=!0x0;_0x4b5ef4=!0x0;}return _0x1b203c['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x2b41c5,_0xdcb77d){const _0x2c56d7=this['editor'],_0x4018e4=_0x2c56d7['plugins']['get'](oi);let _0x47d979=_0x4018e4['getCommentThread'](_0xdcb77d);const _0x196a6e=_0x2c56d7['config']['get']('collaboration.channelId'),_0x2c6983=_0x2c56d7['plugins']['get'](di);return _0x47d979&&(_0x47d979['unlinkedAt']&&_0x47d979['setUnlinkedAt'](null),_0x47d979['isAttached'])||(this['getAllMarkersForId'](_0xdcb77d)[0x0]['managedUsingOperations']?_0x4018e4['fetchCommentThread']({'channelId':_0x196a6e,'threadId':_0xdcb77d})['then'](_0x3c7776=>{if('destroyed'!==_0x2c56d7['state']){if(_0x47d979=_0x3c7776,_0x47d979&&!_0x47d979['isAttached']){const _0x1f2b78=_0x47d979['attachTo'](()=>this['_getTargetForId'](_0xdcb77d));_0x2c6983['registerAnnotation'](_0x1f2b78),_0x47d979['isResolved']&&this['_reconvertMarkers'](_0xdcb77d);}else{if(!_0x47d979){const _0x219d23=this['getAllMarkersForId'](_0xdcb77d);_0x2c56d7['model']['change'](_0xdf2eee=>{for(const _0x1a0437 of _0x219d23)_0xdf2eee['removeMarker'](_0x1a0437);});}}}}):_0x2c56d7['editing']['view']['once']('render',()=>{if(_0x4018e4['getCommentThread'](_0xdcb77d))return;const _0xbee152=_0x2c56d7['plugins']['get'](ti);_0x47d979=_0x4018e4['openNewCommentThread']({'channelId':_0x196a6e,'threadId':_0xdcb77d,'target':()=>this['_getTargetForId'](_0xdcb77d),'context':{'type':'text','value':this['_getTextContext'](_0xdcb77d)}});const _0x3ace55=_0x4018e4['_threadToController']['get'](_0x47d979)['view'],_0x1b1b03=_0xbee152['getByInnerView'](_0x3ace55);_0x1b1b03&&_0x2c6983['registerAnnotation'](_0x1b1b03);},{'priority':'low'})),_0x47d979;}['_handleThreadMarker'](_0x20233b,_0x3b3a97){const _0x580706=this['_attachMarkerToThread'](_0x20233b,_0x3b3a97);_0x580706&&!_0x580706['context']&&_0x580706['setContext']({'type':'text','value':this['_getTextContext'](_0x3b3a97)});}['_initAriaMarkerChangeAnnouncements'](){const _0x534f2b=this['editor'];_0x969ef6(_0x534f2b['model'],({left:_0x177a55,entered:_0x2dd665})=>{for(const _0x563d87 of _0x177a55)if(Ai(_0x563d87)){_0x534f2b['ui']['ariaLiveAnnouncer']['announce'](Et(_0x534f2b['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x5de91c of _0x2dd665)if(Ai(_0x5de91c)){_0x534f2b['ui']['ariaLiveAnnouncer']['announce'](Et(_0x534f2b['locale'],'ENTER_COMMENT_ANNOUNCEMENT',_0x470c6f(_0x2f877e)));break;}});}};function gi(_0x419803,_0x501a70){return _0x501a70?_0x419803+':'+_0x501a70:_0x419803;}function _i(_0x541e01,_0xc41390){const _0xcfb923=_0xc41390['schema'],_0x8043ee=_0xc41390['createRange'](_0x541e01['start']);for(const _0x597805 of _0x541e01['getWalker']()){const {type:_0x4748f7,item:_0x844bcf,nextPosition:_0x35ba42}=_0x597805;if('text'===_0x4748f7||_0xcfb923['isObject'](_0x844bcf)){const _0x44528f=_0xc41390['createPositionBefore'](_0x844bcf);_0x8043ee['isCollapsed']&&(_0x8043ee['start']=_0x44528f),_0x8043ee['end']=_0x35ba42;}}return _0x8043ee;}function Ai(_0x22cd68){return'comment'===fi(_0x22cd68['name'])['group'];}var vi=class extends _0x580aef{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[oi,wi,di,ti];}get['CommentsListView'](){return Lt;}get['CommentThreadInputView'](){return xt;}['init'](){const _0x439616=this['editor'],_0x247edf=_0x439616['plugins']['get'](oi),_0xc3b06d=_0x439616['plugins']['get'](wi),_0x29812e=_0x439616['plugins']['get'](ti),_0x451944=_0x439616['plugins']['get'](di);_0x439616['ui']['componentFactory']['add']('comment',()=>{const _0x14b747=this['_createUIButton'](_0x352ef3);return _0x14b747['tooltip']=!0x0,_0x14b747;}),_0x439616['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](rt)),_0x451944['addSourceCollector'](()=>{const _0x6c95a0=[];for(const [_0x46850e,_0x333d9a]of _0x247edf['_threadToController']){const _0x43bb46=_0xc3b06d['getAllMarkersForId'](_0x46850e['id']),_0x341de0=_0x43bb46['map'](_0x5125b4=>_0x5125b4['getRange']());_0x43bb46['length']>0x0&&_0x6c95a0['push']([_0x333d9a['view'],_0x341de0]);}return _0x6c95a0;}),this['listenTo'](_0x29812e,'change:activeAnnotations',(_0x5c8da1,_0x26c8ee,_0x4731a4)=>{const _0x226399=Array['from'](_0x4731a4)['map'](_0x4ed1ac=>_0x4ed1ac['innerView'])['find'](_0x5515c4=>_0x247edf['_viewToController']['has'](_0x5515c4));if(!_0x226399)return void(_0xc3b06d['activeMarker']=null);const _0x38fdbb=_0x247edf['_viewToController']['get'](_0x226399)['model']['id'],_0x1192fc='comment:'+_0x38fdbb;_0x38fdbb&&_0xc3b06d['hasMarkerForId'](_0x38fdbb)?_0xc3b06d['activeMarker']=_0x1192fc:_0xc3b06d['activeMarker']&&(_0xc3b06d['activeMarker']=null);}),this['listenTo'](_0x247edf,'removeCommentThread',(_0x3910eb,{threadId:_0x4363e8,isFromAdapter:_0x4e7502})=>{!_0x4e7502&&_0x439616['ui']['focusTracker']['isFocused']&&_0xc3b06d['hasMarkerForId'](_0x4363e8)&&_0x439616['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x247edf,'addComment',(_0x24ab65,{threadId:_0x16cef4,isFromAdapter:_0x45831d})=>{!_0x45831d&&_0xc3b06d['hasMarkerForId'](_0x16cef4)&&_0x247edf['hasCommentThread'](_0x16cef4)&&0x1===_0x247edf['getCommentThread'](_0x16cef4)['length']&&(_0x439616['editing']['view']['focus'](),_0x24ab65['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x16742f=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x45e4bf;for(const _0x427f50 in _0x16742f){const _0x20e3ea=_0x427f50,_0x3530f0=_0x16742f[_0x20e3ea];if('commentsLicenseKeyValid'==_0x3530f0||'commentsLicenseKeyInvalid'==_0x3530f0||'commentsLicenseKeyExpired'==_0x3530f0||'commentsLicenseKeyDomainLimit'==_0x3530f0||'commentsLicenseKeyNotAllowed'==_0x3530f0||'commentsLicenseKeyEvaluationLimit'==_0x3530f0||'commentsLicenseKeyUsageLimit'==_0x3530f0){delete _0x16742f[_0x20e3ea],_0x45e4bf=_0x3530f0,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x45e4bf&&_0x16742f['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x45e4bf&&_0x16742f['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x45e4bf&&_0x16742f['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x45e4bf&&_0x16742f['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x45e4bf&&_0x16742f['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyUsageLimit'==_0x45e4bf&&_0x16742f['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0xff2d1d){const _0x1d98ee=this['editor'],_0x189a46=new _0xff2d1d(_0x1d98ee['locale']),_0x1500df=_0x1d98ee['commands']['get']('addCommentThread');return _0x189a46['set']({'label':Et(_0x1d98ee['locale'],'Comment'),'icon':_0x52d241}),_0x189a46['bind']('isEnabled')['to'](_0x1500df,'isEnabled',_0x1500df,'hasContent',(_0x26d5be,_0xfe102d)=>_0x26d5be&&_0xfe102d),this['listenTo'](_0x189a46,'execute',()=>{_0x1500df['execute']();}),_0x189a46;}},yi=class extends _0x580aef{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[wi];}constructor(_0x3c5a05){super(_0x3c5a05),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x1b8bb4,_0x5a8c4c,_0x5162ee)=>{_0x5162ee?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x1f251e,_0x134a1d]of this['editor']['commands'])_0x134a1d['affectsData']&&'addCommentThread'!==_0x1f251e&&_0x134a1d['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0x1cef63=this['editor']['editing']['view']['document'];this['listenTo'](_0x1cef63,'cut',_0x3fd5b9=>_0x3fd5b9['stop'](),{'priority':'highest'}),this['listenTo'](_0x1cef63,'clipboardInput',_0x3b8d43=>_0x3b8d43['stop'](),{'priority':'highest'}),this['listenTo'](_0x1cef63,'delete',_0x4138c2=>_0x4138c2['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x413022,_0x3705a9]of this['editor']['commands'])_0x3705a9['affectsData']&&'addCommentThread'!==_0x413022&&_0x3705a9['clearForceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['clearForceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['clearForceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['clearForceDisabled']('commentsOnlyMode'),this['stopListening'](this['editor']['editing']['view']['document']);}},Ti=class extends _0x584f12{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[ti];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x558930){super(_0x558930),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x127e7d=this['context']['plugins']['get'](ti);this['listenTo'](_0x127e7d,'_activateAnnotation',(_0x1acde2,_0x24ec4c)=>{for(const _0x17326d of this['activeUIs']){const _0x24e9a4=this['_uis']['get'](_0x17326d);(0x0,this['uisData']['get'](_0x17326d)['filter'])(_0x24ec4c)&&_0x24e9a4['setActiveAnnotation'](_0x24ec4c);}}),this['listenTo'](_0x127e7d,'_deactivateAllAnnotations',()=>{for(const _0x1e548c of this['activeUIs'])this['_uis']['get'](_0x1e548c)['setActiveAnnotation'](null);}),this['listenTo'](_0x127e7d['_visibleAnnotations'],'add',(_0x5e3339,_0x4c989e)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x4c989e);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x21ad2c){return this['activeUIs']['has'](_0x21ad2c);}['activate'](_0x8c089e,_0xf98d30=this['defaultFilter']){const _0x1b7531=this['context']['plugins']['get'](ti);if(!this['_uis']['has'](_0x8c089e))throw new _0x3973a7('annotationsuis-missing-ui',this,{'uiName':_0x8c089e});this['isActive'](_0x8c089e)&&this['deactivate'](_0x8c089e),this['activeUIs']['add'](_0x8c089e);const _0x29af05=new Jt();Qt({'source':_0x1b7531['_visibleAnnotations'],'target':_0x29af05,'filter':_0xf98d30}),this['uisData']['set'](_0x8c089e,{'collection':_0x29af05,'filter':_0xf98d30});const _0x33a382=this['_uis']['get'](_0x8c089e);_0x33a382['attach'](_0x29af05),this['listenTo'](_0x33a382,'change:activeAnnotation',(_0x4caa54,_0x47401b,_0x22279f,_0x4cb0ef)=>{_0x4cb0ef&&_0x1b7531['_removeActiveAnnotation'](_0x4cb0ef),_0x22279f&&_0x1b7531['_addActiveAnnotation'](_0x22279f);});}['deactivate'](_0x39dd9e){if(this['activeUIs']['delete'](_0x39dd9e),!this['_uis']['has'](_0x39dd9e))throw new _0x3973a7('annotationsuis-missing-ui',this,{'uiName':_0x39dd9e});const _0xa60959=this['_uis']['get'](_0x39dd9e);_0xa60959['detach'](),this['stopListening'](_0xa60959),this['uisData']['get'](_0x39dd9e)['collection']['destroy'](),this['uisData']['delete'](_0x39dd9e);}['switchTo'](_0x4c4f28){if(!this['_uis']['has'](_0x4c4f28))throw new _0x3973a7('annotationsuis-missing-ui',this,{'uiName':_0x4c4f28});const _0x5473f4=this['context']['plugins']['get'](ti),_0x8ba770=Array['from'](_0x5473f4['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x4c4f28);const _0x42f150=this['_uis']['get'](_0x4c4f28);_0x42f150['setActiveAnnotation'](_0x8ba770),_0x42f150['_setSelectedAnnotations']&&_0x8ba770&&_0x42f150['_setSelectedAnnotations']([_0x8ba770]);}['deactivateAll'](){for(const _0x226fb1 of this['activeUIs'])this['deactivate'](_0x226fb1);}['register'](_0x2ec7b9,_0x5bedc3){if(this['_uis']['has'](_0x2ec7b9))throw new _0x3973a7('annotationsuis-register-already-registered');if('function'!=typeof _0x5bedc3['attach']||'function'!=typeof _0x5bedc3['detach']||'function'!=typeof _0x5bedc3['setActiveAnnotation'])throw new _0x3973a7('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x2ec7b9,_0x5bedc3);}['refilterAnnotations'](){const _0x2898f1=this['context']['plugins']['get'](ti)['collection'],_0x246215=new Map(),_0x3013b3=Array['from'](this['activeUIs']);for(const _0x325f86 of this['activeUIs']){const _0x5203db=this['uisData']['get'](_0x325f86)['collection'];for(const _0x41f40c of _0x5203db)_0x246215['set'](_0x41f40c,_0x325f86);}for(const _0x4bed5e of _0x2898f1){const _0x2dd5e6=_0x246215['get'](_0x4bed5e);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x4bed5e);const _0xb97570=_0x3013b3['find'](_0x4a789f=>this['uisData']['get'](_0x4a789f)['filter'](_0x4bed5e));_0x2dd5e6!==_0xb97570&&(_0x2dd5e6&&this['uisData']['get'](_0x2dd5e6)['collection']['remove'](_0x4bed5e),_0xb97570&&this['uisData']['get'](_0xb97570)['collection']['add'](_0x4bed5e));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x494769){const _0x5bca94=[];for(const _0x5cae09 of this['activeUIs']){(0x0,this['uisData']['get'](_0x5cae09)['filter'])(_0x494769)&&_0x5bca94['push'](_0x5cae09);}if(_0x5bca94['length']>0x1)throw new _0x3973a7('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x5bca94,'annotationType':_0x494769['type']});}};const Ci=/* #__PURE__ -- @preserve */
|
|
32
|
-
|
|
33
|
-
_0x3b2cc3('px');var Ei=class extends ht{['content'];['_targetTop'];['_mutationObserver'];constructor(_0x5ba3f0){super(_0x5ba3f0),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x5137cf,_0xda0773)=>_0x5137cf+_0xda0773),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x352a08=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x352a08['to']('isAnimationDisabled',_0x202280=>_0x202280?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x352a08['to']('top',_0x5c89c0=>bi(_0x5c89c0))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x1fb676=this['element']['clientHeight'];_0x1fb676&&(this['height']=_0x1fb676);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}},ki=class extends _0x584f12{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2c92ab){super(_0x2c92ab),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 _0x1f017e=this['context']['config']['get']('sidebar.container');_0x1f017e&&this['setContainer'](_0x1f017e);}['setContainer'](_0x3de092){if(!Oi(_0x3de092))throw new _0x3973a7('sidebar-setcontainer-invalid-element');this['container']=_0x3de092;}['_attachToContainer']({viewClass:_0x5d06b2='',spaceBetweenItems:_0x126e1e=0x19}={}){if(!Oi(this['container']))throw new _0x3973a7('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x5d06b2,this['_spaceBetweenItems']=_0x126e1e;}['rearrange']({removedAnnotation:_0xb88bda,previousAnnotation:_0x2bdb37,nextAnnotation:_0x292400}){const _0x589a14=this['getSidebarItemView'](_0xb88bda);this['view']['list']['remove'](_0x589a14),this['_destroySidebarItemView'](_0xb88bda),_0x2bdb37&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x2bdb37)),_0x292400&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x292400)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x393cbe,activatedAnnotation:_0x4dbea9,disableAnimationOnActivatedAnnotation:_0x452fa3}){if(this['_activeAnnotation']=_0x4dbea9,_0x393cbe){_0x393cbe['isActive']=!0x1;const _0x58de96=this['getSidebarItemView'](_0x393cbe);_0x58de96&&_0x452fa3&&(_0x58de96['isAnimationDisabled']=!0x1);}if(_0x4dbea9){const _0x4db1d6=this['getSidebarItemView'](_0x4dbea9);_0x4db1d6&&(_0x4dbea9['isActive']=!0x0,_0x452fa3&&(_0x4db1d6['isAnimationDisabled']=!0x0,_0x4db1d6['top']+=0x1),this['_alignToTargetRect'](_0x4db1d6));}}['_detachFromContainer'](_0x4edc83){if(this['view']['element']['remove'](),_0x4edc83){for(const _0x2cdfb3 of _0x4edc83)this['_destroySidebarItemView'](_0x2cdfb3);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x415856,_0x3c9cc9){_0x3c9cc9||(_0x3c9cc9=_0x415856['view']);const _0x29db2f=new Ei(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0x29db2f,_0x415856),this['_annotationToSidebarItemView']['set'](_0x415856,_0x29db2f),_0x29db2f['content']['add'](_0x3c9cc9),this['listenTo'](_0x415856['view'],'change:targetRect',(_0x2cfd5f,_0x332389,_0x2f0f10)=>{const _0x137cec=this['_getTargetTop'](_0x415856,_0x2f0f10);_0x29db2f['_targetTop']!=_0x137cec&&(_0x29db2f['_targetTop']=_0x137cec,this['_setItemTop'](_0x29db2f,_0x137cec));}),this['listenTo'](_0x29db2f,'change:top',()=>{this['_recalculate'](_0x29db2f,'top');}),this['listenTo'](_0x29db2f,'change:bottom',()=>{this['_recalculate'](_0x29db2f,'bottom');}),this['_alignToTargetRect'](_0x29db2f);const _0x13db97=this['_getItemBefore'](_0x29db2f);return _0x13db97&&this['_alignAfterItem'](_0x13db97,_0x29db2f)||this['_alignToTargetRect'](_0x29db2f),this['_updateLastItem'](),this['view']['list']['add'](_0x29db2f),_0x29db2f;}['_alignForTopChange'](_0x358492){if(!_0x358492['content']['length'])return;const _0x2d4b3e=this['_getItemBefore'](_0x358492);if(!_0x2d4b3e)return;const _0x216bf3=this['_sidebarItemViewToAnnotation']['get'](_0x2d4b3e),_0x463484=this['_activeAnnotation'];_0x463484&&_0x463484===_0x216bf3?this['_alignAfterItem'](_0x2d4b3e,_0x358492):this['_alignBeforeItem'](_0x358492,_0x2d4b3e);}['_alignForBottomChange'](_0x255e81){if(!_0x255e81['content']['length'])return;const _0x28a217=this['_getItemAfter'](_0x255e81);if(!_0x28a217)return;const _0x41690f=this['_sidebarItemViewToAnnotation']['get'](_0x28a217),_0x3cb8bf=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x36958d=this['_activeAnnotation'];_0x36958d&&_0x36958d===_0x41690f&&_0x3cb8bf?(this['_alignBeforeItem'](_0x28a217,_0x255e81),this['_alignAfterItem'](_0x255e81,_0x28a217)):_0x36958d&&_0x36958d===_0x41690f?this['_alignBeforeItem'](_0x28a217,_0x255e81):this['_alignAfterItem'](_0x255e81,_0x28a217);}['_recalculate'](_0x464099,_0xebfad7){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x2f87c2,changedProp:_0x33458d}of this['_recalculateBuffer'])'top'===_0x33458d?this['_alignForTopChange'](_0x2f87c2):this['_alignForBottomChange'](_0x2f87c2);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x464099,'changedProp':_0xebfad7});}['getSidebarItemView'](_0x1f79db){return this['_annotationToSidebarItemView']['get'](_0x1f79db);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x419d4a){const _0x1402b7=this['getSidebarItemView'](_0x419d4a);this['stopListening'](_0x1402b7),this['stopListening'](_0x419d4a['view']),_0x1402b7['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x419d4a),this['_sidebarItemViewToAnnotation']['delete'](_0x1402b7);}['_createSidebarView'](){const _0x499e10=new Ii(this['context']['locale']);return _0x499e10['render'](),this['on']('change:_lastItem',(_0x52110f,_0x2e602e,_0x327b00,_0x5618f4)=>{_0x5618f4&&_0x499e10['unbind']('minHeight'),_0x327b00?_0x499e10['bind']('minHeight')['to'](_0x327b00,'bottom'):_0x499e10['minHeight']=null;}),_0x499e10;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x3c9c18){const _0x31a2f1=this['_sidebarItemViewToAnnotation']['get'](_0x3c9c18),_0x5f711c=_0x31a2f1&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x31a2f1)-0x1);return _0x5f711c&&this['getSidebarItemView'](_0x5f711c)||null;}['_getItemAfter'](_0x1c7f7b){const _0x107cc9=this['_sidebarItemViewToAnnotation']['get'](_0x1c7f7b),_0x3fa642=_0x107cc9&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x107cc9)+0x1);return _0x3fa642&&this['getSidebarItemView'](_0x3fa642)||null;}['_alignBeforeItem'](_0x5bbe61,_0xeef54a){_0x5bbe61['updateHeight']();const _0x3f41de=Ni(_0xeef54a['bottom']+this['_spaceBetweenItems'],_0x5bbe61['top']);return!!_0x3f41de&&(this['_setItemTop'](_0xeef54a,_0xeef54a['top']-_0x3f41de),!0x0);}['_alignAfterItem'](_0x217d49,_0x5c5332){_0x217d49['updateHeight']();const _0x2321f6=Ni(_0x217d49['bottom']+this['_spaceBetweenItems'],_0x5c5332['top']);return!!_0x2321f6&&(this['_setItemTop'](_0x5c5332,_0x5c5332['top']+_0x2321f6,!0x1),!0x0);}['_alignToTargetRect'](_0x44325f){const _0x82ca5c=this['_sidebarItemViewToAnnotation']['get'](_0x44325f);if(!_0x82ca5c||!_0x82ca5c['target']||!_0x82ca5c['targetRect'])return;const _0x405229=this['_getTargetTop'](_0x82ca5c,_0x82ca5c['targetRect']);this['_setItemTop'](_0x44325f,_0x405229);}['_getTargetTop'](_0x2b3ff1,_0x151181){if(null===_0x151181)return 0x0;if(_0x2b3ff1['target']instanceof _0x3f7499)return _0x151181['top'];{const _0x11bc99=new _0x3f7499(this['view']['element'])['top'];return _0x151181['top']-_0x11bc99;}}['_setItemTop'](_0x1fb9b9,_0x5908b1,_0x53f521=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x53f521&&(_0x5908b1=Math['max'](_0x5908b1,this['_getMaxAvailableTop'](_0x1fb9b9))),_0x1fb9b9['top']=_0x5908b1;}['_getMaxAvailableTop'](_0x46fbd8){let _0x574e24=this['_getItemBefore'](_0x46fbd8),_0x49ce47=0x0;for(;_0x574e24;)_0x574e24['updateHeight'](),_0x49ce47+=this['_spaceBetweenItems']+_0x574e24['height'],_0x574e24=this['_getItemBefore'](_0x574e24);return _0x49ce47;}};function Ni(_0x35595f,_0x419e3f){return Math['max'](_0x35595f-_0x419e3f,0x0);}function Oi(_0x3dadb6){return null!==_0x3dadb6&&'object'==typeof _0x3dadb6&&0x1===_0x3dadb6['nodeType'];}var Mi=class extends _0x584f12{['isAttached'];['annotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[ki,Ti];}static get['pluginName'](){return'WideSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x231dc3){super(_0x231dc3),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x55d760(),this['_refreshPositioningDebounced']=_0x488046(()=>{_0x231dc3['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x373faf=this['context']['plugins']['get'](Ti),_0x328209=this['context']['plugins']['get'](ki);_0x373faf['register']('wideSidebar',this),_0x328209['container']&&_0x373faf['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x571afa){if(_0x571afa===this['activeAnnotation'])return;const _0x5ef8d4=this['context']['plugins']['get'](ki);_0x5ef8d4['_activeAnnotation']=_0x571afa;const _0xe43231=this['activeAnnotation'];_0x5ef8d4['refresh']({'blurredAnnotation':_0xe43231,'activatedAnnotation':_0x571afa}),this['activeAnnotation']=_0x571afa;}['attach'](_0x2271c4){this['annotations']=_0x2271c4;const _0x23d98e=this['context']['plugins']['get'](ki);if(_0x23d98e['_annotations']=_0x2271c4,this['isAttached'])throw new _0x3973a7('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x23d98e,'set:container',()=>{this['detach'](),this['listenTo'](_0x23d98e,'change:container',_0x32ad37=>{_0x32ad37['off'](),this['attach'](_0x2271c4);});}),_0x23d98e['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x5e07ed=_0x14af5c=>{_0x14af5c['updateTargetRect'](),_0x23d98e['addAnnotation'](_0x14af5c);};for(const _0x2d74f8 of _0x2271c4)_0x5e07ed(_0x2d74f8);this['listenTo'](_0x2271c4,'add',(_0xd8323,_0x774b2e)=>{_0x5e07ed(_0x774b2e);}),this['listenTo'](_0x2271c4,'remove',(_0x48f45f,_0x10f984,_0x3f8893)=>{_0x23d98e['rearrange']({'removedAnnotation':_0x10f984,'previousAnnotation':_0x2271c4['get'](_0x3f8893-0x1),'nextAnnotation':_0x2271c4['get'](_0x3f8893+0x1)}),_0x10f984===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x2271c4,'focus',(_0x143ce2,_0x286218)=>{this['setActiveAnnotation'](_0x286218);}),this['listenTo'](_0x2271c4,'blur',()=>{this['setActiveAnnotation'](null);});const _0x2101e7=this['context']instanceof _0x3ea8d1?this['context']['editors']:new _0x55d760([this['context']]);for(const _0x1a7a79 of _0x2101e7)this['_integrateWithEditorAnnotations'](_0x1a7a79);this['listenTo'](_0x2101e7,'add',(_0x51f8d1,_0x15e302)=>{this['listenTo'](_0x15e302,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x15e302);});}),this['listenTo'](_0x2101e7,'remove',(_0x592a87,_0x73b8b7)=>{_0x73b8b7['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x73b8b7['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x3973a7('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x3160ad=this['context']['plugins']['get'](ki);_0x3160ad['_detachFromContainer'](this['annotations']),this['stopListening'](_0x3160ad),this['stopListening'](this['annotations']),this['context']instanceof _0x3ea8d1&&this['stopListening'](this['context']['editors']);for(const _0x361226 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x361226);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x593db4){if(!_0x593db4['plugins']['has']('EditorAnnotations'))return;const _0x8a5e1d=_0x593db4['plugins']['get']('EditorAnnotations'),_0x38b4f2=()=>{const _0x269f6c=_0x8a5e1d['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x269f6c[0x0]||null);};this['listenTo'](_0x8a5e1d,'refresh',_0x38b4f2),this['listenTo'](_0x8a5e1d,'blur',(_0x16101f,{isAnnotationTracked:_0x17ced6})=>{this['activeAnnotation']&&_0x17ced6(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x8a5e1d,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x3a55e6=>{_0x8a5e1d['hasDomSelection']()&&(_0x38b4f2(),_0x3a55e6['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x8a5e1d);}['_destroyEditorAnnotationsIntegration'](_0x2fd0a1){this['stopListening'](_0x2fd0a1),this['_editorAnnotations']['remove'](_0x2fd0a1);}},Ri=class extends _0x352ef3{['counterView'];constructor(_0x4822a2){super(_0x4822a2);const _0x52eca3=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x19156c,_0x4523eb)=>_0x19156c?'...':_0x4523eb['toString']()),this['set']('annotationType',''),this['icon']=_0x52d241,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new ht(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x52eca3['to']('annotationType',_0x44f5af=>'ck-annotation-counter__badge--'+_0x44f5af),_0x52eca3['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x52eca3['to']('_badge')}]}),this['children']['add'](this['counterView']);}},Si=class extends _0x584f12{['isAttached'];['annotations'];['_manuallyClosedAnnotationViews'];['_domEmitter'];['_annotationToNarrowView'];['_selectedAnnotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[ki,Ti];}static get['pluginName'](){return'NarrowSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2ffb2f){super(_0x2ffb2f),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0x4c115d())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x55d760(),this['_refreshPositioningDebounced']=_0x488046(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](Ti)['register']('narrowSidebar',this),this['bodyCollection']=new _0x4b697d(this['context']['locale']),this['balloonPanelView']=new _0x162878(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x11c8b0){this['annotations']=_0x11c8b0;const _0x513248=this['context']['plugins']['get'](ki),_0x20b2de=this['balloonPanelView'];if(_0x513248['_annotations']=_0x11c8b0,this['isAttached'])throw new _0x3973a7('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x513248,'set:container',()=>{this['detach'](),this['listenTo'](_0x513248,'change:container',_0x26180c=>{_0x26180c['off'](),this['attach'](_0x11c8b0);});}),_0x513248['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x4be20a=_0x1053cd=>{const _0x7c1489=new Ri(this['context']['locale']);_0x513248['addAnnotation'](_0x1053cd,_0x7c1489),this['_annotationToNarrowView']['set'](_0x1053cd,_0x7c1489),_0x7c1489['bind']('isDirty','annotationType','number')['to'](_0x1053cd['view'],'isDirty','type','length'),_0x7c1489['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x20b2de['content']['first']!==_0x1053cd['view']?(this['_showBalloon'](_0x1053cd),_0x1053cd['view']['element']['focus'](),this['setActiveAnnotation'](_0x1053cd)):this['setActiveAnnotation'](null);});};for(const _0x49eb6f of _0x11c8b0)_0x4be20a(_0x49eb6f);this['listenTo'](_0x11c8b0,'add',(_0x1063de,_0x50787c)=>{_0x4be20a(_0x50787c);}),this['listenTo'](_0x11c8b0,'remove',(_0xf66c0f,_0x11bfb7,_0x27aa5e)=>{this['_annotationToNarrowView']['get'](_0x11bfb7)['destroy'](),this['_annotationToNarrowView']['delete'](_0x11bfb7),_0x513248['rearrange']({'removedAnnotation':_0x11bfb7,'previousAnnotation':_0x11c8b0['get'](_0x27aa5e-0x1),'nextAnnotation':_0x11c8b0['get'](_0x27aa5e+0x1)}),_0x11bfb7===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x11c8b0,'focus',(_0x332a19,_0x5efd76)=>{this['setActiveAnnotation'](_0x5efd76);}),this['listenTo'](_0x11c8b0,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x2bc0c8,_0x3029a8)=>{_0x3029a8['keyCode']===_0x31d699['esc']&&_0x20b2de['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x20b2de['content']['first']),this['_hideBalloon'](),_0x3029a8['stopPropagation'](),_0x3029a8['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x566e1b,_0x94d6bb)=>{const _0x7a57c2=_0x94d6bb['target'];_0x20b2de['isVisible']&&_0x20b2de['element']['contains'](_0x7a57c2)||_0x513248['view']['element']['contains'](_0x7a57c2)||_0x566e1b['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x3e6a4e=>_0x3e6a4e['contains'](_0x7a57c2))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0xd12715=this['context']instanceof _0x3ea8d1?this['context']['editors']:new _0x55d760([this['context']]);for(const _0x2303da of _0xd12715)this['_integrateWithEditorAnnotations'](_0x2303da);this['listenTo'](_0xd12715,'add',(_0x58ae09,_0x2f6d60)=>{this['listenTo'](_0x2f6d60,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x2f6d60);});}),this['listenTo'](_0xd12715,'remove',(_0x577598,_0x22d3bf)=>{_0x22d3bf['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x22d3bf['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x89188c){if(_0x89188c===this['activeAnnotation'])return;const _0x9caffb=this['context']['plugins']['get'](ki);_0x9caffb['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x89188c,'disableAnimationOnActivatedAnnotation':!0x0}),_0x89188c&&_0x9caffb['getSidebarItemView'](_0x89188c)?this['_showBalloon'](_0x89188c):this['_hideBalloon'](),this['activeAnnotation']=_0x89188c;}['detach'](){if(!this['isAttached'])throw new _0x3973a7('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x289beb=this['context']['plugins']['get'](ki);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x1c2c3b=>_0x1c2c3b['destroy']()),this['_annotationToNarrowView']['clear'](),_0x289beb['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x3ea8d1&&this['stopListening'](this['context']['editors']);for(const _0x2eb3bb of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x2eb3bb);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'](_0x1f3933){if(!_0x1f3933['plugins']['has']('EditorAnnotations'))return;const _0x452eba=_0x1f3933['plugins']['get']('EditorAnnotations'),_0x5691c8=this['context']['plugins']['get'](ki),_0x51bb54=this['annotations'],_0x26e1fc=this['balloonPanelView'],_0x5751d3=()=>{const _0x407023=_0x452eba['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x407023),this['setActiveAnnotation'](_0x407023[0x0]||null);};this['listenTo'](_0x452eba,'refresh',_0x5751d3),this['listenTo'](_0x452eba,'blur',(_0x4cf845,{isAnnotationTracked:_0x2bd7b9})=>{this['activeAnnotation']&&_0x2bd7b9(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x452eba,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x51bb54,'blur',_0x4638ca=>{_0x452eba['hasDomSelection']()&&_0x4638ca['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x341fbb,_0x2027a1)=>{const _0x52e4b2=_0x2027a1['target'];_0x26e1fc['isVisible']&&_0x26e1fc['element']['contains'](_0x52e4b2)||_0x5691c8['view']['element']['contains'](_0x52e4b2)||this['activeAnnotation']&&_0x452eba['hasDomSelection']()&&(_0x5751d3(),_0x341fbb['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x452eba);}['_destroyEditorAnnotationsIntegration'](_0x21e7d7){_0x21e7d7&&(this['stopListening'](_0x21e7d7),this['_editorAnnotations']['remove'](_0x21e7d7));}['_setSelectedAnnotations'](_0x5a4fd9){for(const _0xf3c9ba of this['_selectedAnnotations'])_0x5a4fd9['includes'](_0xf3c9ba)||this['_manuallyClosedAnnotationViews']['delete'](_0xf3c9ba['view']);this['_selectedAnnotations']=_0x5a4fd9;}['_refreshPositioning'](){const _0x53a315=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x53a315['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0x24e4db){if(this['_manuallyClosedAnnotationViews']['has'](_0x24e4db['view']))return;const _0x3ea459=this['balloonPanelView']['content']['first'];_0x3ea459!==_0x24e4db['view']?(_0x3ea459&&this['_detachListeners'](_0x3ea459),this['_attachListeners'](_0x24e4db['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0x24e4db['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x1dddcd=this['balloonPanelView']['content']['first'],_0x1d58ec=_0x1dddcd&&this['annotations']['getByView'](_0x1dddcd);if(!_0x1d58ec||!this['_annotationToNarrowView']['has'](_0x1d58ec))return;const _0x44fc0a=this['_annotationToNarrowView']['get'](_0x1d58ec)['element'],_0x296c2d=(function(){const _0x39e99c=_0x162878['defaultPositions'];return[_0x39e99c['southArrowNorthEast'],_0x39e99c['northArrowSouthEast'],_0x39e99c['southArrowNorth'],_0x39e99c['northArrowSouth'],_0x39e99c['southArrowNorthWest'],_0x39e99c['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x44fc0a,'positions':_0x296c2d});}['_hideBalloon'](){const _0x99f191=this['balloonPanelView'],_0x321ea2=_0x99f191['content']['first'];_0x321ea2&&(this['_detachListeners'](_0x321ea2),_0x99f191['unpin'](),_0x99f191['content']['clear']());}['_attachListeners'](_0x35a6c8){this['listenTo'](_0x35a6c8,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x35a6c8,'Esc',(_0x242af0,_0x1d8a4a)=>{this['_manuallyClosedAnnotationViews']['add'](_0x35a6c8),this['_hideBalloon'](),_0x1d8a4a();});}['_detachListeners'](_0x58d41c){this['stopListening'](_0x58d41c);}},xi=class extends _0x580aef{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];['_refreshVisibilityDebounced'];static get['requires'](){return[di,_0x39675d,Ti];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x48486d){super(_0x48486d),_0x48486d['editing']['view']['addObserver'](lt),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x48486d['plugins']['get'](_0x39675d),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1,this['_refreshVisibilityDebounced']=_0x488046(()=>{this['editor']['plugins']['get']('Annotations')['refreshVisibility']();},0xfa,{'leading':!0x1});}['init'](){const _0x2493d4=this['editor']['plugins']['get'](Ti);_0x2493d4['context']===this['editor']&&(_0x2493d4['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x171adb,_0x54bbe2)=>{const _0x4c8e60=this['_balloon'];if(this['isAttached']&&_0x4c8e60['visibleView']){const _0x52a3ca=this['annotations']['getByView'](_0x4c8e60['visibleView']);_0x52a3ca&&this['_closeAnnotation'](_0x52a3ca),_0x54bbe2();}}));}['afterInit'](){const _0x1a0a1f=this['editor']['plugins']['get'](Ti);_0x1a0a1f['context']===this['editor']&&(_0x1a0a1f['hasActive']()||_0x1a0a1f['switchTo']('inline'));}['setActiveAnnotation'](_0x323d15){_0x323d15!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x323d15&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x323d15)&&this['_addAnnotationToBalloon'](_0x323d15,!0x0),_0x323d15['isActive']=!0x0),_0x323d15||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x323d15);}['attach'](_0x12f9c4){this['annotations']=_0x12f9c4;const _0x54dbce=this['editor']['plugins']['get'](Ti),_0x32fe68=this['_balloon'];if(this['isAttached'])throw new _0x3973a7('inlineannotations-attach-already-attached',this);if(_0x54dbce['context']!==this['editor'])throw new _0x3973a7('inlineannotations-not-allowed-with-context',this);const _0x3a5ed7=this['editor']['plugins']['get'](di);this['listenTo'](_0x3a5ed7,'refresh',()=>{const _0x45bea7=_0x3a5ed7['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x39c9d1,_0x425b3b;!this['_forceRefresh']&&(_0x39c9d1=_0x45bea7,_0x425b3b=this['_selectedAnnotations'],_0x39c9d1['length']===_0x425b3b['length']&&_0x39c9d1['every'](_0x54f654=>_0x425b3b['includes'](_0x54f654)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x45bea7),this['setActiveAnnotation'](_0x45bea7[0x0]||null));}),this['listenTo'](_0x3a5ed7,'blur',(_0x14279b,{isAnnotationTracked:_0x15e89f})=>{this['activeAnnotation']&&_0x15e89f(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x3a5ed7,'uiUpdate',()=>{this['_refreshVisibilityDebounced']();}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x43a837,_0x50656e,_0x875655)=>{_0x875655||this['setActiveAnnotation'](null);}),this['listenTo'](_0x12f9c4,'remove',(_0x582091,_0x1662e0)=>{this['_removeAnnotationFromBalloon'](_0x1662e0),_0x1662e0===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x32fe68,'change:visibleView',(_0x228a6b,_0x56fa57,_0x2a65ae,_0x278743)=>{_0x278743&&this['stopListening'](_0x278743);const _0x3a3193=_0x12f9c4['getByView'](_0x2a65ae);_0x2a65ae&&_0x3a3193&&(this['listenTo'](_0x2a65ae,'change:height',()=>{_0x32fe68['updatePosition']();}),this['listenTo'](_0x2a65ae,'Esc',()=>{this['_closeAnnotation'](_0x3a3193),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x3a3193&&this['setActiveAnnotation'](_0x3a3193));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x32fe68['visibleView']&&_0x12f9c4['getByView'](_0x32fe68['visibleView'])&&_0x32fe68['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 _0x3973a7('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x28f9c6 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x28f9c6);this['_refreshVisibilityDebounced']['cancel'](),this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['_refreshVisibilityDebounced']['cancel']();}['_setSelectedAnnotations'](_0x564bb9){for(const _0x294249 of this['_selectedAnnotations'])_0x564bb9['includes'](_0x294249)||this['_manuallyClosed']['delete'](_0x294249);for(const _0x10d0dc of this['annotations'])_0x564bb9['includes'](_0x10d0dc)||this['_removeAnnotationFromBalloon'](_0x10d0dc);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x4d2038 of _0x564bb9)this['_addAnnotationToBalloon'](_0x4d2038);}this['_selectedAnnotations']=_0x564bb9;}['_addAnnotationToBalloon'](_0x1a08f8,_0x5dd05c=!0x1){this['_manuallyClosed']['has'](_0x1a08f8)||(this['_addedAnnotations']['has'](_0x1a08f8)||this['_balloon']['hasView'](_0x1a08f8['view'])||(this['_addedAnnotations']['add'](_0x1a08f8),this['_balloon']['add']({'stackId':_0x1a08f8['view']['id'],'view':_0x1a08f8['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x1a08f8)}})),_0x5dd05c&&this['_balloon']['showStack'](_0x1a08f8['view']['id']));}['_getBalloonTargetForAnnotation'](_0x5cb2ef){const _0xdea8d3=_0x5cb2ef['target'],_0x6d3f26=this['editor']['editing']['view'],_0x2e3d68=_0x6d3f26['document']['selection']['getFirstRange'](),_0x3451cc=_0x6d3f26['domConverter']['viewRangeToDom'](_0x2e3d68);if(_0x3451cc['collapse'](!0x0),_0xdea8d3){if(_0xdea8d3 instanceof _0x3f7499)return _0xdea8d3;let _0x12d990=[];for(const _0x4d405d of _0xdea8d3)_0x12d990['push'](..._0x3f7499['getDomElementRects'](_0x4d405d));_0x12d990=function(_0x5b0ac9){const _0x275bb4=[];let _0x8d0f40=_0x5b0ac9[0x0];for(let _0xf03250=0x1;_0xf03250<_0x5b0ac9['length'];_0xf03250++)if(Pi(_0x8d0f40,_0x5b0ac9[_0xf03250])){const _0x8d4563=_0x5b0ac9[_0xf03250]['width'];_0x8d0f40['width']+=_0x8d4563,_0x8d0f40['right']+=_0x8d4563;}else _0x275bb4['push'](_0x8d0f40),_0x8d0f40=_0x5b0ac9[_0xf03250];return _0x275bb4['push'](_0x8d0f40),_0x275bb4;}(_0x12d990);const _0x1f8766=_0x3451cc['getBoundingClientRect']();return _0x12d990['find'](_0x3fe822=>_0x3fe822['top']<=_0x1f8766['top']&&_0x3fe822['bottom']>=_0x1f8766['bottom']&&_0x3fe822['left']<=_0x1f8766['left']&&_0x3fe822['right']>=_0x1f8766['right'])||_0x12d990[0x0];}return _0x5cb2ef['targetRect']||_0x3451cc;}['_removeAnnotationFromBalloon'](_0x374ce9){this['_addedAnnotations']['has'](_0x374ce9)&&this['_balloon']['hasView'](_0x374ce9['view'])&&(this['_addedAnnotations']['delete'](_0x374ce9),this['_balloon']['remove'](_0x374ce9['view']));}['_closeAnnotation'](_0x46188e){this['_manuallyClosed']['add'](_0x46188e),this['_removeAnnotationFromBalloon'](_0x46188e);}};function Pi(_0x585ac2,_0x2226b4){return _0x585ac2['top']===_0x2226b4['top']&&_0x585ac2['bottom']===_0x2226b4['bottom']&&_0x585ac2['right']===_0x2226b4['left'];}var Li=class extends ht{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x6d1936,_0xde6e8c){super(_0x6d1936),this['set']('isEmpty',!_0xde6e8c['length']),this['focusTracker']=new _0x17ba74(),this['_annotationViews']=_0xde6e8c,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new et({'focusables':_0xde6e8c,'focusTracker':this['focusTracker']}),this['listenTo'](_0xde6e8c,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0xde6e8c,'remove',(_0x325709,_0xa942e0)=>{_0xa942e0['isActive']&&this['focus'](),_0xde6e8c['length']||(this['isEmpty']=!0x0);});const _0x2ff769=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':Et(_0x6d1936,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0xde6e8c},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x2ff769['if']('isEmpty','ck-hidden',_0x4f3fcd=>!_0x4f3fcd)]},'children':[{'text':Et(_0x6d1936,'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 _0x4cb533 of this['_annotationViews'])this['focusTracker']['add'](_0x4cb533['element']);this['_annotationViews']['on']('change',(_0x27363c,{added:_0x56e62f,removed:_0x63d444})=>{for(const _0x38fbe4 of _0x56e62f)this['focusTracker']['add'](_0x38fbe4['element']);for(const _0x2eee25 of _0x63d444)this['focusTracker']['remove'](_0x2eee25['element']);});}},Di=class extends _0x584f12{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[oi,ti];}constructor(_0x1a6ef4){super(_0x1a6ef4),this['archivedThreads']=new _0x55d760();}['init'](){const _0x480403=this['context'],_0x321fd1=_0x480403['plugins']['get'](oi),_0x1c0865=_0x480403['plugins']['get'](ti);this['listenTo'](_0x321fd1,'addCommentThread',(_0x55f0b8,{threadId:_0x23afb5})=>{const _0x22129c=_0x321fd1['getCommentThread'](_0x23afb5);_0x22129c['archivedAt']&&this['archivedThreads']['add'](_0x22129c,this['_calculatePosition'](_0x22129c['archivedAt'])),this['listenTo'](_0x22129c,'change:archivedAt',(_0x1a6570,_0x5ad876,_0x5452a2)=>{_0x5452a2?this['archivedThreads']['has'](_0x22129c)||this['archivedThreads']['add'](_0x22129c,this['_calculatePosition'](_0x22129c['archivedAt'])):this['archivedThreads']['has'](_0x22129c)&&this['archivedThreads']['remove'](_0x22129c);});}),this['listenTo'](_0x321fd1,'removeCommentThread',(_0x3f48eb,{threadId:_0x214c58})=>{const _0x58b7ce=_0x321fd1['getCommentThread'](_0x214c58);this['stopListening'](_0x58b7ce),this['archivedThreads']['has'](_0x58b7ce)&&this['archivedThreads']['remove'](_0x58b7ce);},{'priority':'highest'}),this['listenTo'](_0x1c0865['collection'],'focus',(_0x403011,_0x27dffa)=>{_0x27dffa['isVisible']||(_0x27dffa['isActive']=!0x0,_0x1c0865['activate'](_0x27dffa));});}['_calculatePosition'](_0x4f7069){const _0x31c626=[...this['archivedThreads']]['findIndex'](_0x4a3381=>_0x4a3381['archivedAt']<_0x4f7069);return _0x31c626>-0x1?_0x31c626:this['archivedThreads']['length'];}},Vi=class extends _0x580aef{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[Di,_0x4abe2b];}constructor(_0x1bdcb2){super(_0x1bdcb2),this['annotationViews']=new at(),this['_pendingThreads']=[];}['init'](){const _0x2a20f5=this['editor'],_0x102570=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x2a20f5['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x352ef3,!0x0)),_0x2a20f5['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x4233da=this['_createCommentsArchiveButton'](rt);return _0x4233da['set']({'role':'menuitemcheckbox'}),_0x4233da;});const _0x376d53=_0x2a20f5['plugins']['get'](Di),_0x492134=_0x2a20f5['plugins']['get']('Annotations'),_0x905e4c=_0x2a20f5['plugins']['get']('CommentsRepository');_0x376d53['archivedThreads']['forEach'](_0x4a63fb=>{this['_handleNewThread'](_0x4a63fb);}),this['listenTo'](_0x376d53['archivedThreads'],'add',(_0x4edfd5,_0x604196)=>{this['_handleNewThread'](_0x604196);}),this['listenTo'](_0x492134['collection'],'add',(_0x2346f9,_0x421429)=>{const _0x48e630=this['_pendingThreads']['find'](_0x44bbd0=>{const _0x1983a3=_0x905e4c['_threadToController']['get'](_0x44bbd0);return _0x1983a3&&_0x421429['innerView']===_0x1983a3['view'];});if(_0x48e630){const _0xf0f888=this['_calculatePosition'](_0x48e630['archivedAt']);this['_addAnnotationToArchive'](_0x421429,_0xf0f888),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x48e630),0x1);}}),this['listenTo'](_0x376d53['archivedThreads'],'remove',(_0x3387eb,_0x2f6135)=>{const _0x587ff5=_0x2a20f5['config']['get']('collaboration.channelId');if(!_0x587ff5||_0x2f6135['channelId']===_0x587ff5){if(this['_pendingThreads']['includes'](_0x2f6135))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x2f6135),0x1);else{const _0x30c52f=_0x905e4c['_threadToController']['get'](_0x2f6135),_0x39a257=_0x492134['getByInnerView'](_0x30c52f['view']);this['annotationViews']['remove'](_0x39a257['view']),this['stopListening'](_0x39a257),this['stopListening'](_0x39a257['focusableElements']);}}}),this['listenTo'](_0x492134['collection'],'add',(_0xb658f1,_0x404455)=>{this['listenTo'](_0x404455,'escape',_0x102570);}),this['listenTo'](_0x492134['collection'],'remove',(_0x3fc3cf,_0x546d11)=>{this['stopListening'](_0x546d11,'escape',_0x102570);});}['_addAnnotationToArchive'](_0x568f1e,_0x40ac76){this['listenTo'](_0x568f1e,'set:isVisible',_0x54c2ee=>{_0x54c2ee['return']=!0x1,_0x54c2ee['stop']();}),this['annotationViews']['add'](_0x568f1e['view'],_0x40ac76);}['_handleNewThread'](_0x1c88f3){const _0x40c034=this['editor']['plugins']['get']('CommentsRepository'),_0x5a6af3=this['editor']['plugins']['get']('Annotations'),_0x41ce44=this['editor']['config']['get']('collaboration.channelId');if(!_0x41ce44||_0x1c88f3['channelId']===_0x41ce44){const _0xf0240c=_0x40c034['_threadToController']['get'](_0x1c88f3);if(!_0xf0240c)return void this['_pendingThreads']['push'](_0x1c88f3);const _0x4c8231=this['_calculatePosition'](_0x1c88f3['archivedAt']),_0x5ba9cb=_0x5a6af3['getByInnerView'](_0xf0240c['view']);_0x5ba9cb['isVisible']&&_0x5a6af3['_visibleAnnotations']['remove'](_0x5ba9cb),this['_addAnnotationToArchive'](_0x5ba9cb,_0x4c8231);}}['_calculatePosition'](_0x5040a4){const _0x4a1de1=this['editor']['config']['get']('collaboration.channelId'),_0x2703f5=[...this['editor']['plugins']['get'](Di)['archivedThreads']]['filter'](_0x37ef82=>_0x37ef82['channelId']===_0x4a1de1)['findIndex'](_0x4749c4=>_0x4749c4['archivedAt']<_0x5040a4);return _0x2703f5<0x0||_0x2703f5>this['annotationViews']['length']?this['annotationViews']['length']:_0x2703f5-0x1;}['_toggleDialog'](){const _0x2fb16e=this['editor'],_0x196182=_0x2fb16e['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Li(_0x2fb16e['locale'],this['annotationViews'])),'commentsArchive'===_0x196182['id']?_0x196182['hide']():_0x196182['show']({'id':'commentsArchive','title':Et(_0x2fb16e['locale'],'COMMENTS_ARCHIVE'),'icon':_0x104917,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0xdcd457['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x50c410,_0x464c0d=!0x1){const _0x5cf364=this['editor']['locale'],_0x184f21=this['editor']['plugins']['get']('Dialog'),_0x3badad=new _0x50c410(_0x5cf364);return _0x3badad['bind']('isEnabled')['to'](this,'isEnabled'),_0x3badad['bind']('isOn')['to'](_0x184f21,'id',_0x294008=>'commentsArchive'===_0x294008),_0x3badad['set']({'label':Et(_0x5cf364,'COMMENTS_ARCHIVE'),'icon':_0x104917,'isToggleable':!0x0}),_0x464c0d&&(_0x3badad['tooltip']=!0x0),this['listenTo'](_0x3badad,'execute',()=>this['_toggleDialog']()),_0x3badad;}['_hideDialogOnAnnotationEscape']=_0xf77f63=>{const _0xc53205=_0xf77f63['source'];if(!this['annotationViews']['has'](_0xc53205['view']))return;const _0x57c213=this['editor']['plugins']['get']('Dialog');_0x57c213['isOpen']&&'commentsArchive'===_0x57c213['id']&&(_0x57c213['hide'](),_0xf77f63['stop']());};},Bi=class extends _0x580aef{static get['requires'](){return[oi,wi,vi,Di,Vi,yi,Mi,Si,xi];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}};export{ci as AddCommentThreadCommand,$t as Annotation,Jt as AnnotationCollection,Ri as AnnotationCounterButtonView,qt as AnnotationView,ti as Annotations,Ei as AnnotationsSidebarItemView,Ii as AnnotationsSidebarView,Ti as AnnotationsUIs,Ht as BaseCommentThreadView,Kt as BaseCommentView,hi as Comment,ri as CommentThread,bt as CommentThreadController,xt as CommentThreadInputView,Ut as CommentThreadView,Yt as CommentView,Bi as Comments,Di as CommentsArchive,Vi as CommentsArchiveUI,wi as CommentsEditing,Lt as CommentsListView,yi as CommentsOnly,oi as CommentsRepository,vi as CommentsUI,di as EditorAnnotations,xi as InlineAnnotations,Si as NarrowSidebar,ki as Sidebar,Mi as WideSidebar,Qt as bindAnnotationCollections};
|
|
23
|
+
import{Command as _0x54d867,Context as _0x429018,ContextPlugin as _0x388472,Editor as _0x5df8d8,PendingActions as _0x35ca69,Plugin as _0x1228a1}from'@ckeditor/ckeditor5-core';import{CKEditorError as _0x3cac4c,Collection as _0x5c875e,DomEmitterMixin as _0xff39d,FocusTracker as _0x57589a,KeystrokeHandler as _0x6e4d4a,ObservableMixin as _0x181a7c,Rect as _0x50fe83,diff as _0x5c96b4,first as _0x48775c,getEnvKeystrokeText as _0x3d03a9,keyCodes as _0x161b1f,priorities as _0x5f4140,scrollViewportToShowTarget as _0x5199,toUnit as _0xe08cc4,uid as _0x238ccd}from'@ckeditor/ckeditor5-utils';import{AriaDescriptionView as _0x1a41e7,ConfirmMixin as _0x10bd48,FOCUS_ANNOTATION_KEYSTROKE as _0x4a902b,LateFocusButtonView as _0x470ff8,LateFocusDropdownButtonView as _0x4802c0,UserView as _0x19feda,Users as _0x52cabf,getAllMarkersDomElementsSorted as _0x30db39,getDateTimeFormatter as _0x5330d2,hashObject as _0x31a5a3,setupThreadKeyboardNavigation as _0x57b841,surroundingMarkersDetector as _0x56b924,trimHtml as _0x260955}from'@ckeditor/ckeditor5-collaboration-core';import{cloneDeep as _0x2cf7e4,debounce as _0x55ca5d,isEqual as _0x4074d8,set as _0x27c082,throttle as _0x5e5c2f,unset as _0xeea9c4}from'es-toolkit/compat';import{IconAddComment as _0x232043,IconCheck as _0x10acf0,IconCommentsArchive as _0x49f299,IconPencil as _0x16d61c,IconRemoveComment as _0x5dcef3,IconThreeVerticalDots as _0x4443a6,IconUndo as _0x431f9a}from'@ckeditor/ckeditor5-icons';import{BalloonPanelView as _0x230065,BodyCollection as _0x31232d,ButtonView as _0x3a0b06,ContextualBalloon as _0x4bf11d,Dialog as _0x13db02,DialogViewPosition as _0x2718da,EditorUI as tt,EditorUIView as it,FocusCycler as et,InlineEditableUIView as st,ListItemView as nt,ListView as ot,MenuBarMenuListItemButtonView as rt,View as ht,ViewCollection as at,createDropdown as ct,focusChildOnDropdownOpen as dt}from'@ckeditor/ckeditor5-ui';import{MouseObserver as lt,disableViewPlaceholder as mt,enableViewPlaceholder as ut}from'@ckeditor/ckeditor5-engine';import{Clipboard as ft,ClipboardMarkersUtils as pt,ClipboardPipeline as wt}from'@ckeditor/ckeditor5-clipboard';import{Enter as gt,ShiftEnter as _t}from'@ckeditor/ckeditor5-enter';import{SelectAll as At}from'@ckeditor/ckeditor5-select-all';import{Typing as vt}from'@ckeditor/ckeditor5-typing';import{Undo as yt}from'@ckeditor/ckeditor5-undo';import{Paragraph as Tt}from'@ckeditor/ckeditor5-paragraph';import{toWidget as Ct}from'@ckeditor/ckeditor5-widget';const It=/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x181a7c();var bt=class extends It{['model'];['view'];constructor(_0x3da8b9,_0x373d18){super(),this['model']=_0x3da8b9,this['model']['_isAttached']=!0x0,this['view']=_0x373d18,this['listenTo'](_0x373d18,'submitCommentThread',()=>this['submit']()),this['listenTo'](_0x373d18,'removeCommentThread',()=>this['remove']()),this['listenTo'](_0x373d18,'resolveCommentThread',()=>this['resolve']()),this['listenTo'](_0x373d18,'reopenCommentThread',()=>this['reopen']()),this['listenTo'](_0x373d18,'addComment',(_0x4b01ba,_0x93fe8c)=>this['addComment'](_0x93fe8c)),this['listenTo'](_0x373d18,'updateComment',(_0x562e6a,_0x24c5d8,_0xf0dc98)=>this['updateComment'](_0x24c5d8,_0xf0dc98)),this['listenTo'](_0x373d18,'removeComment',(_0x39cae2,_0xf38b59)=>this['removeComment'](_0xf38b59));}['submit'](){this['model']['submit']();}['remove'](){this['model']['remove']();}['resolve'](){this['model']['isResolved']||this['model']['resolve']();}['reopen'](){this['model']['isResolved']&&this['model']['reopen']();}['addComment'](_0x256cdd){this['model']['addComment']({'content':_0x256cdd,'authorId':this['view']['_localUser']['id']});}['updateComment'](_0xd90564,_0x3a8471){this['model']['getComment'](_0xd90564)['update']({'content':_0x3a8471});}['removeComment'](_0x339b29){this['model']['getComment'](_0x339b29)['remove']();}['destroy'](){this['stopListening'](),this['model']['_isAttached']=!0x1;}};function Et(_0x11c5a5,_0x18e1ff,_0x26c7f2){const t=_0x11c5a5['t'];switch(_0x18e1ff){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'},_0x26c7f2);case'COMMENT_THREAD_LABEL':return t({'string':'Comment\x20thread\x20by\x20%1.\x20%0\x20reply.','plural':'Comment\x20thread\x20by\x20%1.\x20%0\x20replies.','id':'COMMENT_THREAD_LABEL'},_0x26c7f2);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'},_0x26c7f2);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'},_0x26c7f2);case'NUMBER_OF_COMMENTS':return t({'string':'%0\x20Comment','plural':'%0\x20Comments','id':'NUMBER_OF_COMMENTS'},_0x26c7f2);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'},_0x26c7f2);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'},_0x26c7f2);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'},_0x26c7f2);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'';}}var kt=class extends it{['main'];['editable'];constructor(_0x425017,_0x3165c3){super(_0x425017);const _0x8529aa=_0x238ccd();this['main']=this['createCollection'](),this['editable']=new st(_0x425017,_0x3165c3,void 0x0,{'label':()=>Et(_0x425017,'Comment\x20editor')}),this['setTemplate']({'tag':'div','attributes':{'class':['ck-reset','ck-editor','ck-rounded-corners','ck-comment__input'],'dir':_0x425017['uiLanguageDirection'],'lang':_0x425017['uiLanguage'],'aria-labelledby':'cke-editor__aria-label_'+_0x8529aa},'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']();}},Nt=class extends tt{['view'];constructor(_0x43d25b){super(_0x43d25b),this['view']=new kt(_0x43d25b['locale'],_0x43d25b['editing']['view']);}get['element'](){return this['view']['element'];}['init'](){const _0x8ff8e2=this['editor']['editing']['view'],_0x4081ef=this['view']['editable'];_0x4081ef['name']=_0x8ff8e2['document']['getRoot']()['rootName'],this['view']['render']();const _0x37c33b=_0x4081ef['element'];this['setEditableElement'](_0x4081ef['name'],_0x37c33b),this['view']['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x8ff8e2['attachDomRoot'](_0x37c33b),this['fire']('ready');}['destroy'](){super['destroy'](),this['view']['destroy']();}};const Ot=[ft,gt,_t,At,vt,yt,Tt],Mt=/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x181a7c(_0x5df8d8);var Rt=class CommentEditor extends Mt{static ['defaultPlugins']=/* #__PURE__ -- @preserve */
|
|
26
|
+
((()=>Ot)());constructor(_0x3f0f93={}){(_0x3f0f93=Object['assign']({},_0x3f0f93))['plugins']||(_0x3f0f93['plugins']=CommentEditor['defaultPlugins']),super(_0x3f0f93),this['ui']=new Nt(this),this['set']('placeholder',''),this['model']['document']['on']('change',()=>this['_updatePlaceholder'](),{'priority':'low'}),this['on']('change:placeholder',()=>this['_updatePlaceholder']()),this['model']['document']['createRoot'](),this['editing']['view']['_overlayModeHint']='auto',this['_sendUsageRequest']=()=>window['Promise']['resolve']({'status':'ok'});}['create'](){const _0xeb6133=this['config']['get']('initialData')||'';return this['initPlugins']()['then'](()=>this['ui']['init']())['then'](()=>this['data']['init'](_0xeb6133))['then'](()=>this['fire']('ready'));}['destroy'](){return super['destroy']()['then'](()=>this['ui']['destroy']());}['focus'](){this['model']['change'](_0x2da7c9=>{const _0x11e8d2=this['model']['document']['getRoot'](),_0x2ecd46=_0x11e8d2&&_0x11e8d2['getChild'](_0x11e8d2['childCount']-0x1);_0x2da7c9['setSelection'](_0x2ecd46,'end'),this['editing']['view']['focus']();});}['_updatePlaceholder'](){const _0x28af66=this['editing']['view'],_0x4ab45c=_0x28af66['document']['getRoot'](),_0x44cd92=_0x4ab45c['getChild'](0x0);_0x4ab45c['childCount']>0x1||!_0x44cd92||'p'!=_0x44cd92['name']?this['placeholderElement']&&this['placeholderElement']['placeholder']&&(mt(_0x28af66,this['placeholderElement']),this['placeholderElement']=void 0x0):(this['placeholder']&&(_0x44cd92['placeholder']=this['placeholder']),ut({'view':_0x28af66,'element':_0x44cd92,'keepOnFocus':!0x0}),this['placeholderElement']=_0x44cd92);}},St=class extends ht{['keystrokes'];['focusTracker'];['focusables'];['focusCycler'];['submitButtonView'];['cancelButtonView'];['_editorConfig'];constructor(_0x31f79f,_0x4cd582={}){super(_0x31f79f),this['editor']=null,this['_editorConfig']=_0x4cd582,this['set']('value',_0x4cd582['initialData']||''),this['set']('disabledSubmit',!0x1),this['set']('showButtons',!0x0),this['set']('placeholder',Et(_0x31f79f,'Reply...')),this['set']('submitLabel',Et(_0x31f79f,'Reply')),this['submitButtonView']=this['_createSubmitButton'](),this['cancelButtonView']=this['_createCancelButton'](),this['focusables']=this['createCollection']([this['submitButtonView'],this['cancelButtonView']]),this['keystrokes']=new _0x6e4d4a(),this['focusTracker']=new _0x57589a(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x3aa677=>!_0x3aa677['defaultPrevented']},'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',(_0x24590d,_0x6c0dd2)=>{this['cancelButtonView']['fire']('execute'),_0x6c0dd2();}),this['keystrokes']['set']('Ctrl+Enter',(_0x4f9825,_0x4179bf)=>{this['submitButtonView']['isEnabled']&&(this['submitButtonView']['fire']('execute'),_0x4179bf());}),this['on']('submit',(_0x1523e6,_0xb09355)=>{_0xb09355['length']>0xfde8?(alert(Et(_0x31f79f,'TOO_LONG_COMMENT_ALERT',[_0xb09355['length'],0xfde8])),_0x1523e6['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 _0x2f1560=this['editor'];this['element']['insertBefore'](_0x2f1560['ui']['element'],this['element']['firstChild']),_0x2f1560['model']['document']['on']('change',()=>this['value']=_0x2f1560['getData']()),_0x2f1560['bind']('placeholder')['to'](this),this['focusables']['add'](_0x2f1560['ui']['view'],0x0),this['fire']('editorReady',this['editor']);})),this['_editorCreationPromise'];}['focus'](_0x3236f7){-0x1===_0x3236f7?(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:_0x1a012b}=this,_0x1a53a6=new _0x3a0b06(_0x1a012b);return _0x1a53a6['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--submit']}}),_0x1a53a6['withText']=!0x0,_0x1a53a6['bind']('label')['to'](this,'submitLabel'),_0x1a53a6['on']('execute',()=>{this['fire']('submit',this['value']);}),_0x1a53a6['bind']('isEnabled')['to'](this,'value',this,'disabledSubmit',(_0x537925,_0x3fe20a)=>!_0x3fe20a&&!!_0x537925['trim']()),_0x1a53a6;}['_createCancelButton'](){const {locale:_0x2b897c}=this,_0x168cfa=new _0x3a0b06(_0x2b897c);return _0x168cfa['extendTemplate']({'attributes':{'class':['ck-comment__input-actions--cancel']}}),_0x168cfa['label']=Et(_0x2b897c,'Cancel'),_0x168cfa['withText']=!0x0,_0x168cfa['on']('execute',()=>{this['editor']['setData'](''),this['fire']('cancel');}),_0x168cfa;}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']),this['focusables']['forEach'](_0x5a7eb1=>{this['focusTracker']['add'](_0x5a7eb1['element']);}),this['focusables']['on']('change',(_0x1b2bd6,_0x559826)=>{for(const _0x112986 of Array['from'](_0x559826['added'])['reverse']())this['focusTracker']['add'](_0x112986['element']);});}},xt=class extends ht{constructor(_0x53e202,_0x128a7b,_0x97ca73){super(_0x53e202),this['commentInputView']=new St(_0x53e202,_0x97ca73),this['focusCycler']=this['commentInputView']['focusCycler'],this['commentInputView']['bind']('showButtons')['to'](this['commentInputView']['focusTracker'],'isFocused',this['commentInputView'],'value',(_0x31bddb,_0x3c8f4a)=>_0x31bddb||!!_0x3c8f4a),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 _0x19feda(_0x53e202,_0x128a7b),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'](_0x47b998){this['commentInputView']['focus'](_0x47b998);}['_focusOnNonInteractiveMouseDown'](){this['listenTo'](this['element'],'mousedown',(_0x1f2adc,_0x479b28)=>{const {submitButtonView:_0x351110,cancelButtonView:_0x15e003,editor:_0x59c0ba}=this['commentInputView'];[_0x351110['element'],_0x15e003['element'],_0x59c0ba?_0x59c0ba['editing']['view']['getDomRoot']():null]['filter'](_0x5b4d82=>_0x5b4d82)['some'](_0x1ae42e=>_0x1ae42e['contains'](_0x479b28['target']))||(this['focus'](),_0x479b28['preventDefault']());});}},Pt=class extends ht{constructor(_0x5cff02){super(_0x5cff02);const _0x49d78f=this['bindTemplate'];this['set']('count',void 0x0),this['setTemplate']({'tag':'li','attributes':{'class':'ck-thread__comment-count'},'children':[{'text':_0x49d78f['to']('count',_0x2f8f88=>Et(_0x5cff02,'NUMBER_OF_COMMENTS',_0x2f8f88))}]});}},Lt=class extends ht{['commentViews'];['resolvedCommentView'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];['_collapsedCommentsView'];constructor(_0x27b303,_0x2e0aed,_0x556ce1){super(_0x27b303);const _0x594ac9=this['bindTemplate'];this['set']('hasDirtyComment',!0x1),this['set']('length',_0x2e0aed['comments']['length']),this['set']('isActive',!0x1),this['_model']=_0x2e0aed,this['_config']=_0x556ce1,this['commentViews']=this['createCollection'](),this['visibleViews']=this['createCollection'](),this['resolvedCommentView']=null,this['focusTracker']=new _0x57589a(),this['keystrokes']=new _0x6e4d4a(),this['focusCycler']=new et({'focusables':this['commentViews'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x2c7bb5=>this['commentViews']['map'](_0x9a07d7=>_0x9a07d7['element'])['includes'](_0x2c7bb5['target'])},'actions':{'focusPrevious':'arrowup','focusNext':'arrowdown'}}),this['_collapsedCommentsView']=new Pt(_0x27b303),this['_collapsedCommentsView']['bind']('count')['to'](this,'length',_0x1ead9e=>_0x1ead9e-this['_config']['maxCommentsWhenCollapsed']);for(const _0x17ca53 of _0x2e0aed['comments'])this['_handleNewCommentModel'](_0x17ca53);this['_handleInfoComment'](),this['listenTo'](_0x2e0aed['comments'],'add',(_0x313c8c,_0xda2a38)=>{const _0x3021cb=this['_calculatePosition'](_0xda2a38);this['length']++,this['_handleNewCommentModel'](_0xda2a38,_0x3021cb),this['refreshVisibleViews']();}),this['listenTo'](_0x2e0aed['comments'],'remove',(_0x4ba7af,_0xc9573f)=>{this['length']--,this['_handleRemoveCommentModel'](_0xc9573f),this['refreshVisibleViews']();}),this['listenTo'](_0x2e0aed,'commentUpdated',()=>this['refreshVisibleViews']()),this['listenTo'](_0x2e0aed,'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',_0x594ac9['if']('length','ck-hidden',_0x19c4b6=>!_0x19c4b6)],'aria-label':Et(_0x27b303,'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'](_0x55708f){-0x1===_0x55708f?this['focusCycler']['focusLast']():this['focusCycler']['focusFirst']();}['destroy'](){this['_collapsedCommentsView']['destroy']();for(const _0x1f88e4 of this['commentViews'])_0x1f88e4['destroy']();super['destroy']();}['refreshVisibleViews'](){this['_shouldCollapse']?this['_rearrangeCollapse']():this['_rearrangeExpand']();}['_handleNewCommentModel'](_0x4525b2,_0xabbd7e){const _0x574add=new this['_config']['CommentView'](this['locale'],_0x4525b2,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig']});_0x574add['viewUid']=_0x4525b2['id'],_0x574add['delegate']('removeComment')['to'](this),_0x574add['delegate']('updateComment')['to'](this),_0x574add['delegate']('resolveCommentThread')['to'](this),_0x574add['delegate']('editorReady')['to'](this),_0x574add['delegate']('editorDestroyed')['to'](this),this['listenTo'](_0x574add,'change:isEditMode',()=>this['_updateHasDirtyComment']()),this['commentViews']['add'](_0x574add,_0xabbd7e);}['_calculatePosition'](_0x280be4){const _0xa0c202=this['_model']['_findOptimalIndex'](_0x280be4);return this['resolvedCommentView']?this['resolvedCommentView']['authoredAt']>_0x280be4['authoredAt']?_0xa0c202-0x1:_0xa0c202:_0xa0c202-0x1;}['_handleInfoComment'](){if(this['_model']['resolvedBy']&&this['_model']['resolvedAt']){const _0x256c09={'id':'resolved','author':this['_model']['resolvedBy'],'authoredAt':this['_model']['resolvedAt'],'content':Et(this['locale'],'Marked\x20as\x20resolved'),'attributes':{}};this['resolvedCommentView']=new this['_config']['CommentView'](this['locale'],_0x256c09,{'maxCommentCharsWhenCollapsed':this['_config']['maxCommentCharsWhenCollapsed'],'formatDateTime':this['_config']['formatDateTime'],'editorConfig':this['_config']['editorConfig'],'isSystemComment':!0x0}),this['commentViews']['add'](this['resolvedCommentView'],this['_model']['_findOptimalIndex'](_0x256c09));}else this['resolvedCommentView']&&(this['commentViews']['remove'](this['resolvedCommentView']),this['resolvedCommentView']['destroy'](),this['resolvedCommentView']=null);this['refreshVisibleViews']();}['_handleRemoveCommentModel'](_0x37b6c6){const _0x4b4aa6=this['commentViews']['remove'](_0x37b6c6['id']);this['stopListening'](_0x4b4aa6),_0x4b4aa6['isEditMode']&&this['_updateHasDirtyComment'](),_0x4b4aa6['destroy']();}['_updateHasDirtyComment'](){this['hasDirtyComment']=Array['from'](this['commentViews'])['some'](_0x1f7601=>_0x1f7601['isEditMode']);}['_rearrangeCollapse'](){const _0x44fba0=function(_0x207f01){const _0x4df0c0=new _0x5c875e();for(const _0x1c66bf of _0x207f01)_0x4df0c0['add'](_0x1c66bf);return _0x4df0c0;}(this['commentViews']),_0x2d9d0f=this['_collapsedCommentsView']['count'];for(let _0x145e1c=0x1;_0x145e1c<=_0x2d9d0f;_0x145e1c++)_0x44fba0['remove'](0x1);for(const _0xef1062 of _0x44fba0)_0xef1062['collapse']();_0x2d9d0f>0x0&&_0x44fba0['add'](this['_collapsedCommentsView'],0x1),Dt(_0x5c96b4(Array['from'](this['visibleViews']),Array['from'](_0x44fba0)),this['visibleViews'],_0x44fba0);}['_rearrangeExpand'](){Dt(_0x5c96b4(Array['from'](this['visibleViews']),Array['from'](this['commentViews'])),this['visibleViews'],this['commentViews']);for(const _0xb37099 of this['visibleViews'])_0xb37099['expand']();}['_setupKeyboardNavigation'](){this['commentViews']['forEach'](_0x556938=>{this['focusTracker']['add'](_0x556938['element']),this['keystrokes']['listenTo'](_0x556938['element']);}),this['commentViews']['on']('change',(_0x136cea,_0x3e7629)=>{for(const _0x486424 of _0x3e7629['removed'])this['focusTracker']['remove'](_0x486424['element']),this['keystrokes']['stopListening'](_0x486424['element']);for(const _0x7b132b of Array['from'](_0x3e7629['added'])['reverse']())this['focusTracker']['add'](_0x7b132b['element']),this['keystrokes']['listenTo'](_0x7b132b['element']);});}};function Dt(_0x189184,_0x486d07,_0xcb11b2){let _0xfc20b6=0x0;for(const _0x519e58 of _0x189184)switch(_0x519e58){case'insert':_0x486d07['add'](_0xcb11b2['get'](_0xfc20b6),_0xfc20b6),_0xfc20b6++;break;case'delete':_0x486d07['remove'](_0xfc20b6);break;case'equal':_0xfc20b6++;}}var Vt=class extends ht{constructor(_0x279fc2){super(_0x279fc2);const _0x4bd9d3=this['bindTemplate'];this['set']('contextValue',''),this['setTemplate']({'tag':'span','attributes':{'class':['ck','ck-context__value'],'aria-label':_0x4bd9d3['to']('contextValue',_0x1be60a=>Et(_0x279fc2,'THREAD_CONTEXT_LABEL',_0x1be60a)),'tabindex':-0x1},'children':[{'text':_0x4bd9d3['to']('contextValue')}]});}['focus'](){this['element']['focus']();}},Bt=class extends ht{['_model'];['reopenButtonView'];['contextView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x4c7f3c,_0x3cfc08){super(_0x4c7f3c);const _0x3687b1=this['bindTemplate'];this['_model']=_0x3cfc08,this['reopenButtonView']=this['_createReopenButton'](),this['contextView']=this['_createContextView'](),this['focusables']=this['createCollection']([this['contextView'],this['reopenButtonView']]),this['focusTracker']=new _0x57589a(),this['keystrokes']=new _0x6e4d4a(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}}),this['bind']('hasContext')['to'](this['_model'],'context',_0x253348=>!!_0x253348),this['bind']('contextValue')['to'](this['_model'],'context',_0x598866=>_0x598866&&_0x598866['value']?this['_trimContextValue'](_0x598866['value']):Et(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',_0x3687b1['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 _0x571b4a=new _0x3a0b06(this['locale']);return _0x571b4a['label']=Et(this['locale'],'Reopen'),_0x571b4a['tooltip']=Et(this['locale'],'Reopen'),_0x571b4a['icon']=_0x431f9a,_0x571b4a['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x33e2eb=>!_0x33e2eb),_0x571b4a['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x566747,_0xdd1434)=>_0x566747&&_0xdd1434),_0x571b4a['on']('execute',()=>{this['fire']('reopenCommentThread',this['_model']['id']);}),_0x571b4a;}['_trimContextValue'](_0x596be7){if(_0x596be7['length']<0x96)return _0x596be7;const _0x52818e=_0x596be7['lastIndexOf']('\x20',0x93);return _0x596be7['substring'](0x0,_0x52818e>-0x1?_0x52818e:0x93)+'...';}['_attachContextActions'](){const _0x495c87=this['element']['querySelector']('.ck-context'),_0x46bbdf=_0x495c87['querySelector']('.ck-context__value');this['listenTo'](_0x495c87,'mouseenter',()=>{_0x46bbdf['offsetWidth']<_0x46bbdf['scrollWidth']&&_0x495c87['classList']['add']('overlay');}),this['listenTo'](_0x495c87,'mouseleave',()=>{_0x495c87['classList']['remove']('overlay');});}['_setupKeyboardNavigation'](){this['keystrokes']['listenTo'](this['element']);for(const _0x4c23a5 of this['focusables'])this['focusTracker']['add'](_0x4c23a5['element']),this['keystrokes']['listenTo'](_0x4c23a5['element']);}['_createContextView'](){const _0x38743f=new Vt(this['locale']);return _0x38743f['bind']('contextValue')['to'](this),_0x38743f;}},Ht=class extends ht{['_model'];['_config'];['commentThreadHeaderView'];['commentThreadInputView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];constructor(_0x588ae7,_0x52e80b,_0x399f73,_0xdd0150){super(_0x588ae7),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['_model']=_0x52e80b,this['_localUser']=_0x399f73,this['_config']=_0xdd0150,this['commentThreadHeaderView']=new Bt(_0x588ae7,_0x52e80b),this['commentThreadHeaderView']['delegate']('reopenCommentThread')['to'](this),this['ariaDescriptionView']=new _0x1a41e7(_0x588ae7,Et(_0x588ae7,'COMMENT_THREAD_DESCRIPTION')),this['listenTo'](this,'reopenCommentThread',()=>{this['focus']();}),this['commentsListView']=new Lt(_0x588ae7,_0x52e80b,Object['assign']({'CommentView':this['_config']['CommentView']},_0xdd0150)),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',(_0x49fa2d,_0x1eafe4)=>_0x49fa2d||!!_0x1eafe4),this['bind']('isUnlinked')['to'](_0x52e80b,'unlinkedAt',_0x5c109e=>!!_0x5c109e);let _0x3d7bd6=null;const _0x5d0da3=()=>{const _0x46a978=this['_model']['comments']['first']||null;_0x46a978!==_0x3d7bd6&&(_0x3d7bd6&&this['stopListening'](_0x3d7bd6,'change:content'),_0x3d7bd6=_0x46a978,_0x46a978&&this['listenTo'](_0x46a978,'change:content',_0x5d0da3));const _0x57ed4d=_0x46a978?_0x46a978['author']['name']:this['_localUser']['name'],_0x1fe5c5=_0x46a978?new DOMParser()['parseFromString'](_0x260955(_0x46a978['content'],{'limit':this['_config']['maxCommentCharsWhenCollapsed']}),'text/html')['body']['textContent']:'',_0xe423d4=Et(this['locale'],'COMMENT_THREAD_LABEL',[this['length'],_0x57ed4d]);this['set']('ariaLabel',_0x1fe5c5?_0xe423d4+'\x20'+_0x1fe5c5:_0xe423d4);};this['listenTo'](this['_model']['comments'],'change',_0x5d0da3),_0x5d0da3(),this['focusables']=this['createCollection']([this['commentsListView'],this['commentThreadInputView']]),this['focusTracker']=new _0x57589a(),this['keystrokes']=new _0x6e4d4a(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x352d1d=>_0x352d1d['target']!==this['element']},'actions':{'focusPrevious':'shift+tab','focusNext':'tab'}});}['focus'](){this['element']['focus']();}['render'](){super['render'](),_0x57b841(this,this['focusables']);}async['destroy'](){this['isDirty']=!0x1,this['commentsListView']['destroy'](),await this['commentThreadInputView']['destroy'](),super['destroy']();}['_createCommentThreadInputView'](){const _0xe5f283=new xt(this['locale'],this['_localUser'],this['_config']['editorConfig']),_0x48e63d=_0xe5f283['commentInputView'];return _0xe5f283['bind']('showInput')['to'](this,'isActive',this['_model'],'isReadOnly',this['_model'],'canComment',this['_model'],'archivedAt',_0x48e63d,'value',(_0x6e2f,_0x19946b,_0x294fcf,_0x3175ff,_0x258693)=>!!_0x258693||!!_0x3175ff&&_0x294fcf&&!_0x19946b||_0x6e2f&&_0x294fcf&&!_0x19946b),_0x48e63d['bind']('placeholder')['to'](this,'length',this['_model'],'isResolvable',this['_model'],'isResolved',(_0x4d35a8,_0x28271d,_0x573686)=>{let _0xd5c596;return _0xd5c596=_0x573686&&_0x28271d?'Reply\x20to\x20reopen\x20discussion...':_0x4d35a8?'Reply...':'Write\x20a\x20comment...',Et(this['locale'],_0xd5c596);}),_0x48e63d['bind']('submitLabel')['to'](this,'length',_0x2cc043=>Et(this['locale'],_0x2cc043?'Reply':'Comment')),_0x48e63d['on']('submit',(_0x313bc7,_0xfbec71)=>{this['fire']('addComment',_0xfbec71),this['_model']['isResolved']&&this['_model']['isResolvable']&&this['fire']('reopenCommentThread',this['_model']['id']),this['_model']['isSubmitted']||this['fire']('submitCommentThread');}),_0x48e63d['on']('cancel',()=>{this['focus']();}),_0x48e63d['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0x48e63d['on']('cancel',_0x3c3891=>{0x0==this['length']&&(this['fire']('removeCommentThread'),_0x3c3891['stop']());}),this['on']('change:isActive',(_0x4f80ea,_0x3e5bbe,_0xf02bb3)=>{_0xf02bb3||this['length']||_0x48e63d['value']||this['fire']('removeCommentThread');}),_0xe5f283;}};const Ft=/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x10bd48(Ht);var Ut=class extends Ft{['commentThreadChildren'];['containerElement'];['resolveButton'];['_boundFirstCommentView'];constructor(_0x31206e,_0x460ebe,_0x5b844f,_0x3a4ad4){super(_0x31206e,_0x460ebe,_0x5b844f,_0x3a4ad4),this['commentThreadChildren']=this['createCollection']([this['commentsListView'],this['commentThreadInputView'],this['ariaDescriptionView']]),this['set']('actionIndicator',null),this['containerElement']=null,this['_boundFirstCommentView']=null,this['locale']=_0x31206e,this['resolveButton']=this['_createResolveButton'](),this['setTemplate'](this['getTemplate']()),this['on']('change:isActive',(_0x155694,_0x4c4a75,_0x10eea3)=>{_0x10eea3||this['_cancelAllConfirms']();}),this['listenTo'](this['_model'],'change:isReadOnly',(_0x1b82ed,_0xe8efd8,_0x554f97)=>{_0x554f97&&this['_cancelAllConfirms']();}),this['length']>0x0&&this['_bindFirstCommentView'](),this['listenTo'](this['commentsListView']['commentViews'],'add',()=>{this['_bindFirstCommentView']();});}['getTemplate'](){const _0x59a35c=this['bindTemplate'];return{'tag':'div','attributes':{'class':['ck','ck-thread','ck-reset_all-excluded','ck-rounded-corners',_0x59a35c['if']('isActive','ck-thread--active'),_0x59a35c['if']('isUnlinked','ck-thread--unlinked'),_0x59a35c['to']('actionIndicator',_0xacfce4=>_0xacfce4?'ck-thread--'+_0xacfce4:'')],'data-thread-id':this['_model']['id'],'tabindex':0x0,'role':'listitem','aria-label':_0x59a35c['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 _0x2d5263 of this['commentsListView']['commentViews'])_0x2d5263['cancelConfirm']();}['_bindFirstCommentView'](){const {locale:_0x5017a9}=this,_0x2d322a=this['commentsListView']['commentViews']['get'](0x0);_0x2d322a===this['_boundFirstCommentView']||_0x2d322a['isSystemComment']||(this['_boundFirstCommentView']=_0x2d322a,this['unbind']('actionIndicator'),this['bind']('actionIndicator')['to'](_0x2d322a,'actionIndicator',_0x2837ba=>'remove'===_0x2837ba?'remove':null),_0x2d322a['placeholder']=Et(_0x5017a9,'Write\x20a\x20comment...'),_0x2d322a['removeButton']['on']('execute',_0x426363=>{_0x426363['stop'](),this['showConfirm'](Et(_0x5017a9,'Delete\x20comment\x20thread?'),this['containerElement'])['then'](()=>{this['fire']('removeCommentThread');});},{'priority':'high'}),this['on']('removeConfirm',()=>{_0x2d322a['focus']();}),_0x2d322a['actionBar']['add'](this['resolveButton'],0x0),_0x2d322a['focusables']['add'](this['resolveButton'],0x0));}['_createResolveButton'](){const _0x35fce5=new _0x470ff8(this['locale']);return _0x35fce5['label']=Et(this['locale'],'Resolve'),_0x35fce5['tooltip']=Et(this['locale'],'Resolve'),_0x35fce5['icon']=_0x10acf0,_0x35fce5['extendTemplate']({'attributes':{'class':'ck-comment--resolve'}}),_0x35fce5['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x1dda89=>!_0x1dda89),_0x35fce5['bind']('isVisible')['to'](this['_model'],'isResolvable',this['_model'],'isResolved',(_0x5af41b,_0x8db376)=>_0x5af41b&&!_0x8db376),_0x35fce5['on']('execute',()=>{this['fire']('resolveCommentThread',this['_model']['id']);}),_0x35fce5;}['_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']));}},Wt=class extends ht{constructor(_0x148a18){super(_0x148a18),this['set']('content',''),this['setTemplate']({'tag':'div','attributes':{'class':['ck-content','ck-comment__content','ck-annotation__content']}});}['render'](){super['render'](),this['on']('change:content',(_0x133f21,_0x380a7b,_0x3db7ee)=>{this['element']['innerHTML']=_0x3db7ee;}),this['element']['innerHTML']=this['content'];}},Kt=class extends ht{['visibleView'];['ariaDescriptionView'];['focusables'];['focusTracker'];['keystrokes'];['focusCycler'];['_model'];['_config'];constructor(_0x1c354b,_0x15d8d4,_0x5ea88a){super(_0x1c354b),this['_model']=_0x15d8d4,this['_config']=_0x5ea88a,this['isSystemComment']=!!this['_config']['isSystemComment'],this['set']('isEditMode',!0x1),this['set']('isCollapsed',!0x0),this['bind']('ariaLabel')['to'](_0x15d8d4,'content',_0x15d8d4,'authoredAt',(_0x9ecc74,_0x147fac)=>Et(_0x1c354b,'COMMENT_ARIA_LABEL',[_0x15d8d4['author']['name'],_0x5ea88a['formatDateTime'](_0x147fac),new DOMParser()['parseFromString'](_0x9ecc74,'text/html')['body']['textContent'],_0x15d8d4['isExternal']?this['getExternalCommentNote']():''])),this['ariaDescriptionView']=new _0x1a41e7(_0x1c354b,Et(_0x1c354b,'COMMENT_THREAD_DESCRIPTION')),this['visibleView']=this['createCollection'](),this['visibleView']['add'](this['_createCommentContentView']()),this['focusables']=new at(),this['focusTracker']=new _0x57589a(),this['keystrokes']=new _0x6e4d4a(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'keystrokeHandlerOptions':{'filter':_0x173e34=>_0x173e34['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']?Et(this['locale'],'EXTERNAL_IMPORT_WORD_COMMENT'):Et(this['locale'],'EXTERNAL_COMMENT');}['getUserViewNotificationText'](){return this['_model']['isExternal']?'importWord'===this['_model']['attributes']['@external']['source']?Et(this['locale'],'EXTERNAL_IMPORT_WORD_AVATAR',this['_model']['creator']['name']):Et(this['locale'],'EXTERNAL_AVATAR',this['_model']['creator']['name']):null;}['_createCommentContentView'](){const _0x49a395=new Wt(this['locale']);return _0x49a395['bind']('content')['to'](this['_model'],'content',this,'isCollapsed',(_0x570ea0,_0x251fa0)=>_0x251fa0?_0x260955(_0x570ea0,{'limit':this['_config']['maxCommentCharsWhenCollapsed']}):_0x570ea0),_0x49a395;}['_createCommentInputView'](){this['_config']['editorConfig']||(this['_config']['editorConfig']={}),this['_config']['editorConfig']['initialData']=this['_model']['content'];const _0xcbb9ac=new St(this['locale'],this['_config']['editorConfig']);return _0xcbb9ac['value']=this['_model']['content'],_0xcbb9ac['bind']('disabledSubmit')['to'](this['_model'],'isReadOnly'),_0xcbb9ac['submitLabel']=Et(this['locale'],'Save'),_0xcbb9ac['on']('submit',(_0x25fd26,_0xf928d3)=>{this['fire']('updateComment',this['_model']['id'],_0xf928d3),this['switchToDisplayMode'](),this['focus']();}),_0xcbb9ac['on']('cancel',()=>{this['switchToDisplayMode'](),this['focus']();}),_0xcbb9ac['once']('editorReady',()=>{_0xcbb9ac['focus']();}),_0xcbb9ac['createEditor'](),_0xcbb9ac['delegate']('editorReady')['to'](this),_0xcbb9ac['delegate']('editorDestroyed')['to'](this),_0xcbb9ac;}['_setupKeyboardNavigation'](){const _0x31055c=this['element'];this['keystrokes']['listenTo'](_0x31055c);for(const _0x37d0f0 of this['focusables'])this['focusTracker']['add'](_0x37d0f0['element']),this['keystrokes']['listenTo'](_0x37d0f0['element']);this['focusables']['on']('change',(_0x38a7f3,_0x351e7c)=>{for(const _0x24bcde of _0x351e7c['removed'])this['focusTracker']['remove'](_0x24bcde['element']),this['keystrokes']['stopListening'](_0x24bcde['element']);for(const _0x29f26f of _0x351e7c['added'])this['focusTracker']['add'](_0x29f26f['element']),this['keystrokes']['listenTo'](_0x29f26f['element']);}),this['keystrokes']['set']('enter',(_0x4fd467,_0x273e81)=>{_0x31055c===_0x4fd467['target']&&(this['focusCycler']['focusFirst'](),_0x273e81());}),this['keystrokes']['set']('esc',(_0x596e96,_0x1057ad)=>{_0x31055c!==_0x596e96['target']&&(this['focus'](),_0x1057ad());});}};const Gt=/* #__PURE__ -- @preserve */
|
|
28
|
+
_0x10bd48(Kt);var Yt=class extends Gt{['actionBar'];['userView'];constructor(_0x21badc,_0x3c0892,_0x1ce561){super(_0x21badc,_0x3c0892,_0x1ce561),this['set']('actionIndicator',null),this['set']('placeholder',Et(_0x21badc,'Reply...')),this['bind']('authoredAt')['to'](_0x3c0892),this['bind']('resolvedAt')['to'](_0x3c0892),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 _0x19feda(_0x21badc,_0x3c0892['author'],this['getUserViewNotificationText']()),this['userView']['extendTemplate']({'attributes':{'class':['ck-comment__user','ck-annotation__user'],'aria-hidden':!0x0}}),this['listenTo'](_0x3c0892,'change:isRemovable',()=>this['cancelConfirm']()),this['setTemplate'](this['getTemplate']());}['getTemplate'](){const _0x1e7df9=this['bindTemplate'],_0x4c0d3d=[{'tag':'div','attributes':{'class':['ck-comment__info','ck-annotation__info']},'children':[{'tag':'span','children':[{'text':this['userView']['name']}],'attributes':{'class':['ck-comment__info-name','ck-annotation__info-name'],'data-cke-tooltip-text':this['userView']['name']}},{'tag':'time','attributes':{'datetime':_0x1e7df9['to']('authoredAt'),'class':['ck-comment__info-time','ck-annotation__info-time']},'children':[{'text':_0x1e7df9['to']('authoredAt',_0x4b5270=>this['_config']['formatDateTime'](_0x4b5270))}]}]},{'tag':'div','attributes':{'class':['ck-comment__actions','ck-annotation__actions',_0x1e7df9['if']('isEditMode','ck-comment__actions--hidden'),_0x1e7df9['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']&&_0x4c0d3d['push']({'tag':'div','attributes':{'class':['ck-comment__external']},'children':[{'text':this['getExternalCommentNote']()}]}),{'tag':'li','attributes':{'class':['ck-comment__wrapper'],'tabindex':-0x1,'aria-label':_0x1e7df9['to']('ariaLabel'),'aria-describedby':this['ariaDescriptionView']['id'],'role':'listitem'},'children':[{'tag':'div','attributes':{'class':['ck-comment','ck-annotation',_0x1e7df9['if']('isEditMode','ck-comment--edit'),_0x1e7df9['if']('isSystemComment','ck-comment--info'),_0x1e7df9['to']('actionIndicator',_0x21a266=>_0x21a266?'ck-comment--'+_0x21a266:'')],'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':_0x4c0d3d}]}]};}['_createEditButton'](){const _0xcd46a4=new _0x3a0b06(this['locale']);return _0xcd46a4['label']=Et(this['locale'],'Edit'),_0xcd46a4['icon']=_0x16d61c,_0xcd46a4['withText']=!0x0,_0xcd46a4['extendTemplate']({'attributes':{'class':'ck-comment--edit'}}),_0xcd46a4['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x2a6c04=>!_0x2a6c04),_0xcd46a4['bind']('isVisible')['to'](this['_model'],'isEditable'),_0xcd46a4['on']('execute',()=>this['switchToEditMode']()),_0xcd46a4;}['_createRemoveButton'](){const _0x1e8d42=new _0x3a0b06(this['locale']);return _0x1e8d42['label']=Et(this['locale'],'Remove'),_0x1e8d42['icon']=_0x5dcef3,_0x1e8d42['withText']=!0x0,_0x1e8d42['extendTemplate']({'attributes':{'class':'ck-comment--remove'}}),_0x1e8d42['bind']('isEnabled')['to'](this['_model'],'isReadOnly',_0x30b9fa=>!_0x30b9fa),_0x1e8d42['bind']('isVisible')['to'](this['_model'],'isRemovable'),_0x1e8d42['on']('execute',()=>{this['showConfirm'](Et(this['locale'],'Delete\x20comment?'),this['element'])['then'](()=>{this['fire']('removeComment',this['_model']['id']);});}),_0x1e8d42;}['_createDropdown'](){const _0x3e9a41=ct(this['locale'],_0x4802c0),_0x3275c1=_0x3e9a41['panelView']['children'],_0x3af4c2=new ot(this['locale']),_0x50b4e6=_0x3e9a41['bindTemplate'];dt(_0x3e9a41,()=>this['items']['find'](_0xf4ef48=>_0xf4ef48['isVisible'])),_0x3e9a41['extendTemplate']({'attributes':{'class':[_0x50b4e6['if']('isVisible','ck-hidden',_0x40f03b=>!_0x40f03b)]}});const _0x54a155=(_0x52551a,_0x5585d6=-0x1)=>{const _0x5d012a=new nt(this['locale']);_0x5d012a['children']['add'](_0x52551a);const _0x408565=_0x5585d6>-0x1?_0x5585d6:_0x3af4c2['items']['length'];_0x3af4c2['items']['add'](_0x5d012a,_0x408565);const _0x32c709=Array['from'](this['items']);_0x3e9a41['unbind']('isEnabled','isVisible'),_0x3e9a41['bind']('isEnabled')['toMany'](_0x32c709,'isEnabled',(..._0x342b87)=>_0x342b87['some'](_0x207e5e=>_0x207e5e)),_0x3e9a41['bind']('isVisible')['toMany'](_0x32c709,'isVisible',(..._0x340f0a)=>_0x340f0a['some'](_0x65a9a3=>_0x65a9a3));};_0x3e9a41['panelPosition']='sw',_0x3e9a41['buttonView']['set']({'label':Et(this['locale'],'Show\x20more\x20items'),'icon':_0x4443a6});for(const _0x48fd8e of this['items'])_0x54a155(_0x48fd8e);return _0x3275c1['add'](_0x3af4c2),_0x3e9a41['listenTo'](this['items'],'add',(_0x3c0f2e,_0x47bab9,_0xfcd03e)=>{_0x54a155(_0x47bab9,_0xfcd03e);}),_0x3e9a41['listenTo'](this['items'],'remove',(_0x15240a,_0x33f709,_0x378a03)=>{_0x3af4c2['items']['remove'](_0x378a03);}),_0x3e9a41;}['_attachActions'](_0xd08b80,_0x252b9f){const _0x5e0456=_0xd08b80&&_0xd08b80['element'];_0x5e0456&&(this['listenTo'](_0x5e0456,'mouseenter',()=>this['actionIndicator']=_0x252b9f),this['listenTo'](_0x5e0456,'focus',()=>this['actionIndicator']=_0x252b9f),this['listenTo'](_0x5e0456,'mouseleave',()=>this['actionIndicator']=null),this['listenTo'](_0x5e0456,'blur',()=>this['actionIndicator']=null));}['_createCommentInputView'](){const _0x58895d=super['_createCommentInputView']();return _0x58895d['bind']('placeholder')['to'](this),_0x58895d;}['render'](){super['render'](),this['_attachActions'](this['editButton'],'edit'),this['_attachActions'](this['removeButton'],'remove');}};function Xt(_0x32c79a){const _0x4fb55e=_0x5e5c2f(_0x32c79a,0x1e),_0x46025a=new MutationObserver(_0x2020b0=>{for(const _0x35b63d of _0x2020b0)('attributes'==_0x35b63d['type']&&'class'==_0x35b63d['attributeName']||'childList'==_0x35b63d['type']||'characterData'==_0x35b63d['type'])&&_0x4fb55e();});return{'attach'(_0x7c517f){_0x46025a['observe'](_0x7c517f,{'attributes':!0x0,'childList':!0x0,'subtree':!0x0,'characterData':!0x0});},'detach'(){_0x46025a['disconnect'](),_0x4fb55e['cancel']();}};}var qt=class extends ht{['focusTracker'];['id'];['keystrokes'];['content'];['mainView'];['_mutationObserver'];constructor(_0x1e8758,_0x5db820){super(_0x1e8758),this['id']=_0x238ccd(),this['focusTracker']=new _0x57589a(),this['keystrokes']=new _0x6e4d4a(),this['keystrokes']['set']('Esc',(_0x20ae90,_0x14f7fc)=>this['fire']('Esc',_0x14f7fc)),this['set']('targetRect',{'top':0x0,'right':0x0,'bottom':0x0,'left':0x0}),this['set']('height',0x0),this['set']('isActive',!0x1),this['set']('isDirty',!0x1),this['set']('length',0x0),this['set']('type',''),this['_mutationObserver']=Xt(()=>this['_updateHeight']()),this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this),this['content']['add'](_0x5db820),this['mainView']=_0x5db820;const _0x3d39d2=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-annotation-wrapper','ck-rounded-corners',_0x3d39d2['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 _0x3f9470=this['element']['clientHeight'];_0x3f9470&&(this['height']=_0x3f9470);}};const jt=/* #__PURE__ -- @preserve */
|
|
29
|
+
_0x181a7c();var $t=class Annotation extends jt{['view'];['focusableElements'];['_type'];['_target'];constructor({view:_0x11f100,target:_0x8d26be,type:_0x4542a2,isVisible:_0x4aaa45=!0x0}){super(),this['view']=_0x11f100,this['view']['element']||this['view']['render'](),this['_type']=_0x4542a2,this['_target']=_0x8d26be,Annotation['_assertCorrectTarget'](this['_getNormalizedTarget']()),this['focusableElements']=new _0x5c875e([this['view']['element']],{'idProperty':'_id'}),this['focusableElements']['on']('add',(_0x5bcdf2,_0x429530)=>{this['view']['focusTracker']['add'](_0x429530);}),this['focusableElements']['on']('remove',(_0x5d3b17,_0x4b310b)=>{this['view']['focusTracker']['remove'](_0x4b310b);}),this['set']('isVisible',_0x4aaa45);}get['type'](){return'function'==typeof this['_type']?this['_type']():this['_type'];}get['innerView'](){return this['view']['mainView'];}get['target'](){const _0x50b967=this['_getNormalizedTarget']();return Annotation['_assertCorrectTarget'](_0x50b967),_0x50b967;}get['targetRect'](){const _0x1a945f=this['target'];if(null===_0x1a945f)return null;if(_0x1a945f instanceof _0x50fe83)return _0x1a945f;const _0x137b83=_0x1a945f['filter'](_0x3d2adb=>function(_0x236bd8){return!!_0x236bd8['offsetParent']||!!_0x236bd8['getClientRects']()['item'](0x0);}(_0x3d2adb));return 0x0===_0x137b83['length']?null:_0x50fe83['getDomElementRects'](_0x137b83[0x0])[0x0];}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x15a619){this['view']['isActive']=_0x15a619,this['view']['mainView']['isActive']=_0x15a619;}['updateTargetRect'](){this['view']['targetRect']=this['targetRect'];}['destroy'](){this['focusableElements']['stopListening'](),this['focusableElements']['clear'](),this['stopListening']();}['refreshVisibility'](){this['isVisible']=!!this['targetRect'];}static['_assertCorrectTarget'](_0x14b17a){if(!(null===_0x14b17a||_0x14b17a instanceof _0x50fe83||Array['isArray'](_0x14b17a)&&_0x14b17a['every'](_0x2c5d4d=>zt(_0x2c5d4d))))throw new _0x3cac4c('annotation-invalid-target',null,{'target':_0x14b17a});}['_getNormalizedTarget'](){const _0x560bb2='function'==typeof this['_target']?this['_target']():this['_target'];return zt(_0x560bb2)?[_0x560bb2]:_0x560bb2;}};function zt(_0x3cdec8){return null!==_0x3cdec8&&'object'==typeof _0x3cdec8&&'nodeType'in _0x3cdec8&&0x1===_0x3cdec8['nodeType'];}var Jt=class extends _0x5c875e{['_innerViewToAnnotation'];['_viewToAnnotation'];['_focusTracker'];constructor(_0x129a1b=[]){super(),this['_innerViewToAnnotation']=new Map(),this['_viewToAnnotation']=new Map(),this['_focusTracker']=new _0x57589a(),this['_focusTracker']['on']('change:isFocused',(_0x1c5266,_0x588d8f,_0x10c7c8)=>{_0x10c7c8||this['fire']('blur');});for(const _0x2862df of _0x129a1b)this['add'](_0x2862df);}get['isFocused'](){return this['_focusTracker']['isFocused'];}['add'](_0x299af5){if(this['has'](_0x299af5))throw new _0x3cac4c('annotationcollection-duplicated-item',null);this['_innerViewToAnnotation']['set'](_0x299af5['innerView'],_0x299af5),this['_viewToAnnotation']['set'](_0x299af5['view'],_0x299af5);for(const _0x1ad3f8 of _0x299af5['focusableElements'])this['_focusTracker']['add'](_0x1ad3f8);if(this['listenTo'](_0x299af5['focusableElements'],'add',(_0x376bf9,_0x345484)=>{this['_focusTracker']['add'](_0x345484);}),this['listenTo'](_0x299af5['focusableElements'],'remove',(_0x5da7f3,_0x341f0a)=>{this['_focusTracker']['remove'](_0x341f0a);}),this['listenTo'](_0x299af5['view']['focusTracker'],'change:isFocused',(_0x30d4c9,_0x145cb2,_0x4e062b)=>{_0x4e062b&&this['fire']('focus',_0x299af5);}),_0x299af5['updateTargetRect'](),this['_areCachedRectsStale']()){for(const _0x33aaf0 of this)_0x33aaf0['updateTargetRect']();}const _0x96fdd1=this['_getOrderInContent'](_0x299af5['view']['targetRect']);return super['add'](_0x299af5,_0x96fdd1);}['remove'](_0x368bad){if(!this['has'](_0x368bad))throw new _0x3cac4c('annotationcollection-not-existing-item',null);this['stopListening'](_0x368bad['view']['focusTracker']),this['stopListening'](_0x368bad['focusableElements']);for(const _0x17a9bd of _0x368bad['focusableElements'])this['_focusTracker']['remove'](_0x17a9bd);return this['_viewToAnnotation']['delete'](_0x368bad['view']),this['_innerViewToAnnotation']['delete'](_0x368bad['innerView']),super['remove'](_0x368bad);}['getByInnerView'](_0x4d3efe){return this['_innerViewToAnnotation']['get'](_0x4d3efe);}['getByView'](_0x3a3744){return this['_viewToAnnotation']['get'](_0x3a3744);}['destroy'](){super['clear'](),this['stopListening'](),this['_innerViewToAnnotation']['clear'](),this['_viewToAnnotation']['clear'](),this['_focusTracker']['destroy']();}['refreshPositioning'](){for(const _0x3bdb0e of this)_0x3bdb0e['updateTargetRect']();this['_sort']();}['_sort'](){const _0x4962db=Array['from'](this)['sort']((_0x490ce5,_0x10ad79)=>Zt(_0x490ce5['view']['targetRect'],_0x10ad79['view']['targetRect']));for(let _0x25fa6c=_0x4962db['length']-0x1;_0x25fa6c>0x0;_0x25fa6c--){const _0x28309f=_0x4962db[_0x25fa6c];_0x25fa6c!==this['getIndex'](_0x28309f)&&(this['remove'](_0x28309f),this['add'](_0x28309f));}}['_getOrderInContent'](_0x54c704){let _0x3666a2=0x0;if(!_0x54c704)return this['length'];for(const _0x44f763 of this){const _0x414c30=_0x44f763['view']['targetRect'];if(_0x414c30){if(Zt(_0x54c704,_0x414c30)<0x0)return _0x3666a2;_0x3666a2++;}}return _0x3666a2;}['_areCachedRectsStale'](){const _0x1c9d71=this['get'](0x0);if(!_0x1c9d71)return!0x1;const _0x54e0da=_0x1c9d71['view']['targetRect'],_0x39e6c0=_0x1c9d71['targetRect'];return!(!_0x54e0da||!_0x39e6c0)&&(_0x54e0da['top']!==_0x39e6c0['top']||_0x54e0da['left']!==_0x39e6c0['left']);}};function Qt({source:_0x168d0d,target:_0x2e5ec1,filter:_0x1dfce8}){for(const _0x5d900f of _0x168d0d)_0x1dfce8(_0x5d900f)&&_0x2e5ec1['add'](_0x5d900f);_0x2e5ec1['listenTo'](_0x168d0d,'add',(_0x4fe40e,_0x27619d)=>{_0x1dfce8(_0x27619d)&&_0x2e5ec1['add'](_0x27619d);}),_0x2e5ec1['listenTo'](_0x168d0d,'remove',(_0x2cc2bc,_0x296ea3)=>{_0x2e5ec1['has'](_0x296ea3)&&_0x2e5ec1['remove'](_0x296ea3);});}function Zt(_0x4bf63c,_0x29c056){if(null===_0x4bf63c&&null===_0x29c056)return 0x0;if(null===_0x4bf63c)return-0x1;if(null===_0x29c056)return 0x1;const _0x4252b3=_0x4bf63c['top']-_0x29c056['top'];return 0x0==_0x4252b3?_0x4bf63c['left']-_0x29c056['left']:_0x4252b3;}var ti=class extends _0x388472{['collection'];['_visibleAnnotations'];static get['pluginName'](){return'Annotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x50e0d3){if(super(_0x50e0d3),this['collection']=new Jt(),this['_visibleAnnotations']=new Jt(),this['set']('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations'](),_0x50e0d3 instanceof _0x5df8d8){const _0x3869d3=_0x50e0d3['locale'];_0x50e0d3['accessibility']['addKeystrokeInfoGroup']({'id':'annotations','label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_GROUP'),'keystrokes':[{'label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO'),'keystroke':'Ctrl+Shift+E'},{'label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_EXIT'),'keystroke':'Esc'},{'label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_ENTER'),'keystroke':'Enter'},{'label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS'),'keystroke':[['Tab'],['Shift+Tab']]},{'label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT'),'keystroke':['Ctrl+Enter']},{'label':Et(_0x3869d3,'ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS'),'keystroke':[['Arrowup'],['Arrowdown']]}]});}this['_setupEnterAnnotationKeystroke'](),this['_setupEscapeAnnotationHandling']();}['add'](_0x142bd5){this['collection']['add'](_0x142bd5);}['remove'](_0x432352){this['collection']['remove'](_0x432352),_0x432352['destroy']();}['refreshVisibility'](){for(const _0xe3797 of this['collection'])_0xe3797['refreshVisibility']();}['refreshPositioning'](){this['_visibleAnnotations']['refreshPositioning']();}['getByInnerView'](_0x331a62){return this['collection']['getByInnerView'](_0x331a62);}['deactivateAll'](){this['fire']('_deactivateAllAnnotations');}['destroy'](){for(const _0x2e9c5c of this['collection'])_0x2e9c5c['destroy']();this['_visibleAnnotations']['destroy'](),this['collection']['destroy'](),super['destroy']();}['activate'](_0x44d838){this['fire']('_activateAnnotation',_0x44d838);}['createAnnotation'](_0x55f694){return new $t(_0x55f694);}['createAnnotationView'](_0x30e2d3,_0x511c34){return new qt(_0x30e2d3,_0x511c34);}['_addActiveAnnotation'](_0x1b0a4f){const _0x3d0c12=new Set(this['activeAnnotations']);_0x3d0c12['add'](_0x1b0a4f),this['activeAnnotations']=_0x3d0c12;}['_removeActiveAnnotation'](_0x2ed181){const _0x3ef71a=new Set(this['activeAnnotations']);_0x3ef71a['delete'](_0x2ed181),this['activeAnnotations']=_0x3ef71a;}['_bindAnnotationsToVisibleAnnotations'](){const _0x456a41=this['collection'],_0x2ca952=this['_visibleAnnotations'];function _0x243b94(_0x855abe){const _0x348d00=_0x855abe['source'];_0x348d00['isVisible']&&!_0x2ca952['has'](_0x348d00)?_0x2ca952['add'](_0x348d00):!_0x348d00['isVisible']&&_0x2ca952['has'](_0x348d00)&&_0x2ca952['remove'](_0x348d00),_0x348d00['view']['focusTracker']['remove'](_0x348d00['view']['element']),_0x348d00['view']['focusTracker']['add'](_0x348d00['view']['element']);}this['listenTo'](_0x456a41,'add',(_0x16d5fe,_0x1c465a)=>{_0x1c465a['isVisible']&&_0x2ca952['add'](_0x1c465a),this['listenTo'](_0x1c465a,'change:isVisible',_0x243b94);}),this['listenTo'](_0x456a41,'remove',(_0x39cf52,_0xdbcce3)=>{_0x2ca952['has'](_0xdbcce3)&&_0x2ca952['remove'](_0xdbcce3),this['stopListening'](_0xdbcce3,'change:isVisible',_0x243b94);});}['_setupEnterAnnotationKeystroke'](){const _0x48ef02=_0x58a062=>{_0x58a062['on']('ready',()=>{_0x58a062['keystrokes']['set'](_0x4a902b,(_0x3cbf98,_0x4ce1a5)=>{const _0x47baed=_0x48775c(this['activeAnnotations']['values']());_0x47baed&&(_0x47baed['view']['focus'](),_0x4ce1a5());});});};this['context']instanceof _0x5df8d8?_0x48ef02(this['context']):this['context']['editors']&&this['context']['editors']['on']('add',(_0x2a954b,_0x50f7e6)=>{_0x48ef02(_0x50f7e6);});}['_setupEscapeAnnotationHandling'](){const _0x19da4d=_0x54b560=>{const _0x47d9b8=_0x54b560['source'],_0x3996fe=[];let _0x2a77aa;if(Array['isArray'](_0x47d9b8['target'])){_0x2a77aa=_0x47d9b8['target'][0x0],this['context']instanceof _0x5df8d8?_0x3996fe['push'](this['context']):this['context']['editors']&&_0x3996fe['push'](...this['context']['editors']);for(const _0x1d073d of _0x3996fe)for(const _0x1e9ece of _0x1d073d['editing']['view']['domRoots']['values']())if(_0x1e9ece['contains'](_0x2a77aa))return void _0x1d073d['editing']['view']['focus']();_0x2a77aa['focus']();}};this['listenTo'](this['collection'],'add',(_0x9473db,_0x25718d)=>{this['listenTo'](_0x25718d,'escape',_0x19da4d,{'priority':'low'});}),this['listenTo'](this['collection'],'remove',(_0x5d4377,_0x4fb5b8)=>{this['stopListening'](_0x4fb5b8,'escape',_0x19da4d);});}};const ii=Symbol('noChannel'),ei={'admin':!0x0,'modifyAll':!0x1,'write':!0x0,'resolve':!0x0},si=/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x181a7c(),ni=/* #__PURE__ -- @preserve */
|
|
31
|
+
_0x181a7c();var oi=class extends _0x388472{['_threads'];['_threadToController'];['_viewToController'];static get['requires'](){return[ti,_0x35ca69,_0x52cabf];}static get['pluginName'](){return'CommentsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x12c36e){super(_0x12c36e),this['_threads']=new Map(),this['_threadToController']=new Map(),this['_viewToController']=new Map(),this['set']('_readOnlyChannels',new Set()),this['set']('_permissions',new Map());const _0x55dc69=this['context']['config'];_0x55dc69['define']('comments.maxCommentsWhenCollapsed',0x2),_0x55dc69['define']('comments.maxThreadTotalWeight',0x1f4),_0x55dc69['define']('comments.maxCommentCharsWhenCollapsed',0x8c),_0x55dc69['define']('comments.CommentThreadView',Ut),_0x55dc69['define']('comments.CommentView',Yt),_0x55dc69['get']('comments.editorConfig')||console['warn']('Missing\x20comments\x20editor\x20configuration\x20(`comments.editorConfig`).\x20Default\x20configuration\x20will\x20be\x20used\x20instead.');}['init'](){const _0xa88459=this['context']['plugins']['get'](ti);this['set']('activeCommentThread',null),this['on']('addCommentThread',(_0x2be2ec,_0x37aefd)=>this['_addCommentThread'](_0x37aefd)),this['on']('submitCommentThread',(_0x57a0d7,_0x54c531)=>this['_submitCommentThread'](_0x54c531)),this['on']('resolveCommentThread',(_0xfa7dc1,_0x190fd7)=>this['_resolveCommentThread'](_0x190fd7)),this['on']('resolveCommentThread',(_0x4cbe46,_0x310cc9)=>this['_updateActiveAnnotation'](_0x310cc9),{'priority':'lowest'}),this['on']('reopenCommentThread',(_0x6dcd69,_0x570659)=>this['_reopenCommentThread'](_0x570659)),this['on']('reopenCommentThread',(_0x4cdcbf,_0xcb25e1)=>this['_updateActiveAnnotation'](_0xcb25e1),{'priority':'lowest'}),this['on']('removeCommentThread',(_0x5520b6,_0x1fd1c6)=>this['_removeCommentThread'](_0x1fd1c6)),this['on']('updateCommentThread',(_0x20758b,_0x32ae77)=>this['_updateCommentThread'](_0x32ae77)),this['on']('updateCommentThread',(_0x5a3341,_0xc6c7b5)=>this['_updateActiveAnnotation'](_0xc6c7b5),{'priority':'lowest'}),this['on']('addComment',(_0x5a9078,_0x2595a3)=>this['_addComment'](_0x2595a3)),this['on']('updateComment',(_0xe37c6a,_0x22d8cd)=>this['_updateComment'](_0x22d8cd)),this['on']('removeComment',(_0x7206a7,_0x3ae3d8)=>this['_removeComment'](_0x3ae3d8)),this['on']('addComment',(_0x45dce5,{threadId:_0x2d63bf,isFromAdapter:_0x4a9d63})=>{if(_0x4a9d63)return;const _0x46e535=this['getCommentThread'](_0x2d63bf),_0x5e9530=_0x46e535&&this['_threadToController']['get'](_0x46e535);_0x5e9530&&_0x5e9530['view']['commentsListView']['focus'](-0x1);},{'priority':'lowest'}),this['listenTo'](_0xa88459,'change:activeAnnotations',(_0x1d0eec,_0x163de1,_0x5ef0dc)=>{const _0x1818e9=Array['from'](_0x5ef0dc)['map'](_0x56cbcf=>this['_viewToController']['get'](_0x56cbcf['innerView']))['filter'](Boolean)[0x0];this['activeCommentThread']=_0x1818e9?_0x1818e9['model']:null;});}set['adapter'](_0x310c86){if(this['_adapter'])throw new _0x3cac4c('commentsrepository-adapter-already-set');this['_adapter']=_0x310c86;}get['adapter'](){return this['_adapter'];}['addCommentThread']({channelId:_0x66a0ac=ii,threadId:_0x32edf0=_0x238ccd(),comments:_0x27504e=[],unlinkedAt:_0x55bdd8=null,resolvedAt:_0x5395d1=null,resolvedBy:_0x32940e=null,target:_0x462dbd=null,context:_0x368ddf=null,attributes:_0x2cd8b6={},isResolvable:_0x1c8e08=!0x0,isSubmitted:_0x3ef4f6=!0x1,isFromAdapter:_0x329ace=!0x1}={}){return this['fire'](ai('addCommentThread',_0x66a0ac),{'channelId':_0x66a0ac,'threadId':_0x32edf0,'comments':_0x27504e,'unlinkedAt':_0x55bdd8,'resolvedAt':_0x5395d1,'resolvedBy':_0x32940e,'target':_0x462dbd,'context':_0x368ddf,'attributes':_0x2cd8b6,'isFromAdapter':_0x329ace,'isResolvable':_0x1c8e08,'isSubmitted':_0x3ef4f6}),this['getCommentThread'](_0x32edf0);}['openNewCommentThread']({channelId:_0x40a928=ii,threadId:_0x166f41=_0x238ccd(),target:_0x4198c2,context:_0x4609cf=null,isResolvable:_0x3acd46=!0x0}){if(this['_readOnlyChannels']['has'](_0x40a928)||this['_readOnlyChannels']['has'](void 0x0))return null;if(!_0x4198c2)throw new _0x3cac4c('commentsrepository-missing-target');const _0x2fb341=this['addCommentThread']({'channelId':_0x40a928,'threadId':_0x166f41,'target':_0x4198c2,'context':_0x4609cf,'isResolvable':_0x3acd46});if(!_0x2fb341)return null;const _0x3b5fe8=this['_threadToController']['get'](_0x2fb341),_0x144e42=_0x3b5fe8['view']['commentThreadInputView']['commentInputView'],_0x2fb9d8=this['context']['plugins']['get'](ti),_0x5be878=_0x2fb9d8['getByInnerView'](_0x3b5fe8['view']);return _0x2fb9d8['activate'](_0x5be878),_0x144e42['once']('editorReady',()=>_0x144e42['focus']()),_0x2fb341;}['hasCommentThread'](_0x24a000){if('string'!=typeof _0x24a000)throw new _0x3cac4c('commentsrepository-invalid-comment-thread-id');return this['_threads']['has'](_0x24a000);}['updateCommentThread']({channelId:_0x7885a0=ii,threadId:_0xaf3a38,context:_0x403c30,unlinkedAt:_0x235a9a,attributes:_0x1f3e6e,isFromAdapter:_0x2b3d75=!0x1}){return this['fire'](ai('updateCommentThread',_0x7885a0),{'channelId':_0x7885a0,'threadId':_0xaf3a38,'context':_0x403c30,'unlinkedAt':_0x235a9a,'attributes':_0x1f3e6e,'isFromAdapter':_0x2b3d75}),this['getCommentThread'](_0xaf3a38);}['getCommentThread'](_0x59c543){if('string'!=typeof _0x59c543)throw new _0x3cac4c('commentsrepository-invalid-comment-thread-id');return this['_threads']['get'](_0x59c543);}['fetchCommentThread']({channelId:_0x41f944,threadId:_0x2329cb}={}){const _0x4d1a21=this['getCommentThread'](_0x2329cb);if(_0x4d1a21)return Promise['resolve'](_0x4d1a21);if(!this['adapter'])return Promise['resolve'](void 0x0);if('function'!=typeof this['adapter']['getCommentThread'])throw new _0x3cac4c('commentsrepository-missing-thread-and-adapter-method',this['context']);return this['adapter']['getCommentThread']({'channelId':_0x41f944,'threadId':_0x2329cb})['then'](_0xc5006a=>this['hasCommentThread'](_0x2329cb)?this['getCommentThread'](_0x2329cb):_0xc5006a?this['addCommentThread'](Object['assign']({'isFromAdapter':!0x0,'channelId':_0x41f944},_0xc5006a)):void 0x0)['catch'](_0x58e2e2=>{throw console['error'](_0x58e2e2),new _0x3cac4c('commentsrepository-fetch-comment-thread',this['context']);});}['getCommentThreads']({channelId:_0x24b6aa,skipNotAttached:_0x4863c7=!0x1,skipEmpty:_0x1a7d6c=!0x1,toJSON:_0x56df03=!0x1}={}){const _0x4baba9=[];for(const _0x27d440 of this['_threads']['values']())_0x24b6aa&&_0x27d440['channelId']!==_0x24b6aa||_0x4863c7&&!_0x27d440['isAttached']||_0x1a7d6c&&0x0===_0x27d440['length']||_0x4baba9['push'](_0x27d440);return _0x56df03?_0x4baba9['map'](_0x31d571=>_0x31d571['toJSON']()):_0x4baba9;}['getAnnotationForCommentThread'](_0x186609){const _0x420877=this['_threadToController']['get'](_0x186609);return _0x420877&&this['context']['plugins']['get'](ti)['getByInnerView'](_0x420877['view'])||null;}['getCommentThreadForAnnotation'](_0x22fd54){const _0x8ce293=this['_viewToController']['get'](_0x22fd54['innerView']);return _0x8ce293?_0x8ce293['model']:null;}['setActiveCommentThread'](_0x4817eb){const _0x296c84=this['context']['plugins']['get'](ti);if(!_0x4817eb)return void(this['activeCommentThread']&&_0x296c84['deactivateAll']());const _0x33ef6f=this['getCommentThread'](_0x4817eb);if(!_0x33ef6f)throw new _0x3cac4c('commentsrepository-active-missing-comment-thread',null,{'threadId':_0x4817eb});if(!this['_threadToController']['has'](_0x33ef6f))throw new _0x3cac4c('commentsrepository-active-not-attached',null,{'threadId':_0x4817eb});const _0x31cbe1=_0x296c84['getByInnerView'](this['_threadToController']['get'](_0x33ef6f)['view']);_0x296c84['activate'](_0x31cbe1);}['switchReadOnly'](_0xcc9836,_0x26e4f2){_0xcc9836?this['_readOnlyChannels']['add'](_0x26e4f2):this['_readOnlyChannels']['delete'](_0x26e4f2),this['fire']('change:_readOnlyChannels','_readOnlyChannels',this['_readOnlyChannels'],this['_readOnlyChannels']);}['isReadOnly'](_0x5c6618){return this['_readOnlyChannels']['has'](_0x5c6618)||this['_readOnlyChannels']['has'](void 0x0);}['createCommentThreadController'](_0x8840b4,_0x49d7ae){return new bt(_0x8840b4,_0x49d7ae);}['setPermissions'](_0x1d6479,_0x50e5b1=ii){this['_permissions']['set'](_0x50e5b1,_0x1d6479),this['fire']('change:_permissions','_permissions',this['_permissions'],this['_permissions']);}['getPermissions'](_0x4d3bd5=ii){return this['_permissions']['has'](_0x4d3bd5)?this['_permissions']['get'](_0x4d3bd5):ei;}['_addCommentThread']({channelId:_0x155bcb,threadId:_0x52b503,comments:_0x5daba6,unlinkedAt:_0x227bc2,resolvedAt:_0x5bc910,resolvedBy:_0x1b842a,target:_0x615138,context:_0x24c73c,attributes:_0x1f2384,isFromAdapter:_0x3f2d88,isResolvable:_0x335396,isSubmitted:_0x471c0c}){if('string'!=typeof _0x52b503)throw new _0x3cac4c('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x52b503});if(this['hasCommentThread'](_0x52b503))throw new _0x3cac4c('commentsrepository-duplicated-comment-thread-id',null,{'threadId':_0x52b503});const _0x23a5a8=new ri(this,{'channelId':_0x155bcb,'id':_0x52b503,'context':_0x24c73c,'attributes':_0x1f2384,'unlinkedAt':_0x227bc2,'resolvedAt':_0x5bc910,'resolvedBy':_0x1b842a?this['context']['plugins']['get'](_0x52cabf)['getUser'](_0x1b842a):null,'isResolvable':_0x335396,'isSubmitted':_0x471c0c||_0x3f2d88});this['_threads']['set'](_0x52b503,_0x23a5a8);for(const _0xfcf10a of _0x5daba6)_0x23a5a8['_add'](this['_createNewComment']({'threadId':_0x52b503,..._0xfcf10a}));return _0x615138&&_0x23a5a8['attachTo'](_0x615138),_0x3f2d88||!_0x23a5a8['length']?Promise['resolve']():this['_submitCommentThread']({'channelId':_0x155bcb,'threadId':_0x52b503});}['_submitCommentThread']({channelId:_0x294ef5,threadId:_0x98b4de}){if(!this['hasCommentThread'](_0x98b4de))throw new _0x3cac4c('commentsrepository-missing-comment-thread',this);const _0x34532e=this['getCommentThread'](_0x98b4de);if(_0x34532e['_isSubmitted']=!0x0,!this['adapter']||'function'!=typeof this['adapter']['addCommentThread'])return Promise['resolve']();const {id:_0x4ccbcf,comments:_0x58afc7,resolvedAt:_0x1dac28,resolvedBy:_0x5827d0,context:_0x488b76,attributes:_0x2329e0}=_0x34532e,_0x503067=this['context']['plugins']['get']('PendingActions'),_0x5922b4=_0x503067['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['addCommentThread']({'channelId':_0x294ef5,'threadId':_0x4ccbcf,'comments':_0x58afc7['map'](_0x2a285f=>_0x2a285f['toJSON']()),'resolvedAt':_0x1dac28,'resolvedBy':_0x5827d0?_0x5827d0['id']:_0x5827d0,'context':_0x488b76,'attributes':_0x2329e0})['then'](({comments:_0x545de5})=>{_0x503067['remove'](_0x5922b4);for(const _0x4d8f0c of _0x545de5)this['_updateComment']({'channelId':_0x294ef5,'threadId':_0x98b4de,'commentId':_0x4d8f0c['commentId'],'createdAt':_0x4d8f0c['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x242ba3=>{throw console['error'](_0x242ba3),new _0x3cac4c('commentsrepository-add-comment-thread-internal-error',this);});}['_attachCommentThread']({threadId:_0x32251d,target:_0x295f77}){const _0x256152=this['getCommentThread'](_0x32251d);if(!_0x256152)throw new _0x3cac4c('commentsrepository-attach-missing-comment-thread',this);const _0x2d3c70=this['context']['plugins']['get']('PendingActions'),_0x2eb2f8=this['context']['plugins']['get'](ti),_0x224a2d=this['_createCommentThreadView'](_0x256152),_0x4d54cf=new bt(_0x256152,_0x224a2d);let _0x1a66b9=null;_0x224a2d['on']('change:isDirty',(_0xa0941b,_0x392351,_0x151431)=>{_0x151431?_0x1a66b9=_0x2d3c70['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD')):_0x1a66b9&&(_0x2d3c70['remove'](_0x1a66b9),_0x1a66b9=null);}),this['_threadToController']['set'](_0x256152,_0x4d54cf),this['_viewToController']['set'](_0x224a2d,_0x4d54cf);const _0x4fd2a0=new qt(this['context']['locale'],_0x224a2d);_0x4fd2a0['bind']('length')['to'](_0x224a2d),_0x4fd2a0['bind']('isDirty')['to'](_0x224a2d,'isDirty',_0x224a2d,'length',(_0x1efb8e,_0x282b36)=>_0x1efb8e||!_0x282b36),_0x4fd2a0['bind']('isActive')['to'](_0x224a2d),_0x4fd2a0['type']='comment';const _0x133d73=new $t({'view':_0x4fd2a0,'target':_0x295f77,'type':'comment','isVisible':!_0x256152['archivedAt']&&!!('function'==typeof _0x295f77?_0x295f77():_0x295f77)});return _0x224a2d['on']('escape',()=>{_0x133d73['fire']('escape');}),this['_bindAnnotationToEditors'](_0x224a2d,_0x133d73),_0x2eb2f8['add'](_0x133d73),_0x133d73;}['_bindAnnotationToEditors'](_0x466ec4,_0x486559){this['listenTo'](_0x466ec4,'editorReady',(_0x2c49b1,_0x37e922)=>{const _0x4e7797=_0x37e922['ui']['view']['body']['bodyCollectionContainer'];_0x486559['focusableElements']['add'](_0x4e7797),this['context']instanceof _0x5df8d8&&this['context']['ui']['focusTracker']['add'](_0x4e7797);},{'priority':'highest'}),this['listenTo'](_0x466ec4,'editorDestroyed',(_0x20abfb,_0x4de655)=>{const _0x18b7c4=_0x4de655['ui']['view']['body']['bodyCollectionContainer'];_0x486559['focusableElements']['has'](_0x18b7c4)&&_0x486559['focusableElements']['remove'](_0x18b7c4),this['context']instanceof _0x5df8d8&&this['context']['ui']['focusTracker']['remove'](_0x18b7c4);});}['_unbindEditors'](_0x56cd4a){this['stopListening'](_0x56cd4a,'editorReady'),this['stopListening'](_0x56cd4a,'editorDestroyed');}['_createCommentThreadView'](_0x17ca91){const _0x1a0267=this['context']['plugins']['get'](_0x52cabf),{config:_0x193ddf,locale:_0x3fa70a}=this['context'],_0x280cbe=_0x5330d2(_0x193ddf['get']('locale'),_0x3fa70a);return new(0x0,(_0x193ddf['get']('comments'))['CommentThreadView'])(_0x3fa70a,_0x17ca91,_0x1a0267['me'],{'editorConfig':{..._0x193ddf['get']('comments.editorConfig'),'licenseKey':this['context']['config']['get']('licenseKey')},'copyMarkers':_0x193ddf['get']('comments.copyMarkers'),'maxCommentsWhenCollapsed':_0x193ddf['get']('comments.maxCommentsWhenCollapsed'),'maxThreadTotalWeight':_0x193ddf['get']('comments.maxThreadTotalWeight'),'maxCommentCharsWhenCollapsed':_0x193ddf['get']('comments.maxCommentCharsWhenCollapsed'),'formatDateTime':_0x280cbe,'CommentView':_0x193ddf['get']('comments')['CommentView']});}['_resolveCommentThread']({threadId:_0x11d275,channelId:_0x13c6ca,resolvedAt:_0x249e05,resolvedBy:_0x4c645d,isFromAdapter:_0x9e8e34}){if(!this['hasCommentThread'](_0x11d275))throw new _0x3cac4c('commentsrepository-missing-comment-thread',null,{'threadId':_0x11d275});const _0x85bace=this['getCommentThread'](_0x11d275);if(_0x85bace['isResolved'])throw new _0x3cac4c('commentsrepository-resolved-comment-thread',null,{'threadId':_0x11d275});const _0x57d693=this['context']['plugins']['get'](_0x52cabf);if(_0x85bace['resolvedBy']=_0x57d693['getUser'](_0x4c645d),_0x85bace['resolvedAt']=_0x249e05,_0x9e8e34||!this['adapter']||'function'!=typeof this['adapter']['resolveCommentThread'])return Promise['resolve']();const _0x48ae0c=this['context']['plugins']['get']('PendingActions'),_0x15d96d=_0x48ae0c['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['resolveCommentThread']({'channelId':_0x13c6ca,'threadId':_0x11d275})['then'](({resolvedAt:_0x5951cc,resolvedBy:_0x37c61c})=>{_0x48ae0c['remove'](_0x15d96d),_0x85bace['resolvedBy']['id']!==_0x37c61c&&(_0x85bace['resolvedBy']=_0x57d693['getUser'](_0x37c61c)),_0x85bace['resolvedAt']=_0x5951cc;})['catch'](_0x43f8e3=>{throw console['error'](_0x43f8e3),new _0x3cac4c('commentsrepository-resolve-comment-thread-internal-error',this);});}['_reopenCommentThread']({threadId:_0x553af3,channelId:_0x1e2fcb,isFromAdapter:_0x340b05}){if(!this['hasCommentThread'](_0x553af3))throw new _0x3cac4c('commentsrepository-missing-comment-thread',null,{'threadId':_0x553af3});const _0x3085b1=this['getCommentThread'](_0x553af3);if(!_0x3085b1['isResolved'])throw new _0x3cac4c('commentsrepository-reopen-comment-thread',null,{'threadId':_0x553af3});if(_0x3085b1['resolvedBy']=null,_0x3085b1['resolvedAt']=null,_0x340b05||!this['adapter']||'function'!=typeof this['adapter']['reopenCommentThread'])return Promise['resolve']();const _0x5ab6e2=this['context']['plugins']['get']('PendingActions'),_0xa6b996=_0x5ab6e2['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['reopenCommentThread']({'channelId':_0x1e2fcb,'threadId':_0x553af3})['then'](()=>_0x5ab6e2['remove'](_0xa6b996))['catch'](_0x579a8f=>{throw console['error'](_0x579a8f),new _0x3cac4c('commentsrepository-reopen-comment-thread-internal-error',this);});}['_removeCommentThread']({threadId:_0x4d54dc,isFromAdapter:_0x27aff8}){const _0x2ad2de=this['getCommentThread'](_0x4d54dc);if(!_0x2ad2de)throw new _0x3cac4c('commentsrepository-remove-missing-comment-thread',this);if(this['_detachCommentThread'](_0x4d54dc),this['_threads']['delete'](_0x4d54dc),!_0x2ad2de['isSubmitted']||_0x27aff8||!this['adapter']||'function'!=typeof this['adapter']['removeCommentThread'])return Promise['resolve']();const _0x14f943=this['context']['plugins']['get']('PendingActions'),{channelId:_0x2482e9}=_0x2ad2de,_0x1c65a8=_0x14f943['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeCommentThread']({'channelId':_0x2482e9,'threadId':_0x4d54dc})['then'](()=>_0x14f943['remove'](_0x1c65a8))['catch'](_0x3fedb2=>{throw console['error'](_0x3fedb2),new _0x3cac4c('commentsrepository-remove-comment-thread-internal-error',this);});}['_updateCommentThread']({threadId:_0x3fae5f,unlinkedAt:_0x132b38,context:_0x2f5d7e,attributes:_0x5b205e,isFromAdapter:_0x120e0a}){if('string'!=typeof _0x3fae5f)throw new _0x3cac4c('commentsrepository-invalid-comment-thread-id',null,{'threadId':_0x3fae5f});if(!this['hasCommentThread'](_0x3fae5f))throw new _0x3cac4c('commentsrepository-missing-comment-thread',null,{'threadId':_0x3fae5f});const _0x397de3=this['getCommentThread'](_0x3fae5f);let _0x1fef01=!0x1;if(void 0x0!==_0x2f5d7e&&_0x397de3['context']!==_0x2f5d7e&&(_0x397de3['context']=_0x2f5d7e,_0x1fef01=!0x0),void 0x0!==_0x132b38&&_0x397de3['unlinkedAt']!==_0x132b38&&(_0x397de3['unlinkedAt']=_0x132b38,_0x1fef01=!0x0),_0x5b205e&&!_0x4074d8(_0x5b205e,_0x397de3['attributes'])&&(_0x397de3['attributes']=_0x5b205e,_0x1fef01=!0x0),!_0x1fef01)return Promise['resolve']();if(!_0x397de3['isSubmitted']||_0x120e0a||!this['adapter']||'function'!=typeof this['adapter']['updateCommentThread'])return Promise['resolve']();const _0x1c4295=this['context']['plugins']['get']('PendingActions'),{channelId:_0x2882a7}=_0x397de3,_0x40aa44=_0x1c4295['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateCommentThread']({'channelId':_0x2882a7,'threadId':_0x3fae5f,'context':_0x2f5d7e,'unlinkedAt':_0x132b38,'attributes':_0x5b205e})['then'](()=>_0x1c4295['remove'](_0x40aa44))['catch'](_0x13a20e=>{throw console['error'](_0x13a20e),new _0x3cac4c('commentsrepository-update-comment-thread-internal-error',this);});}['_detachCommentThread'](_0x3e949b){const _0x563d7f=this['context']['plugins']['get'](ti),_0xaaf207=this['getCommentThread'](_0x3e949b);if(_0xaaf207['_isAttached']=!0x1,this['_threadToController']['has'](_0xaaf207)){const _0x2c9a70=this['_threadToController']['get'](_0xaaf207),_0x568452=_0x2c9a70['view'],_0xcc4cee=_0x563d7f['getByInnerView'](_0x568452);this['_threadToController']['delete'](_0xaaf207),this['_viewToController']['delete'](_0x568452),_0xcc4cee&&_0x563d7f['remove'](_0xcc4cee),_0x2c9a70['destroy'](),_0x568452['destroy']()['then'](()=>{this['_unbindEditors'](_0x568452);});}}['_updateActiveAnnotation']({threadId:_0x1974b5,resolvedAt:_0x53abbe,unlinkedAt:_0x93ada4}){const _0x5c3da6=!!_0x53abbe,_0x3bff41=this['context']['plugins']['get'](ti),_0x24e58d=this['getCommentThread'](_0x1974b5);if(this['_threadToController']['has'](_0x24e58d)){const _0x5f3148=this['_threadToController']['get'](_0x24e58d)['view'],_0x4d3fda=_0x3bff41['getByInnerView'](_0x5f3148);_0x4d3fda&&(_0x5c3da6&&_0x3bff41['_removeActiveAnnotation'](_0x4d3fda),_0x93ada4?_0x4d3fda['isVisible']=!0x1:_0x4d3fda['refreshVisibility']());}}['_getExternalAuthor'](_0x4ca12e){const _0x503f03=this['context']['plugins']['get'](_0x52cabf),_0x1cc334=_0x31a5a3('external:'+_0x4ca12e),_0x2257b0=_0x503f03['getUser'](_0x1cc334);return _0x2257b0||_0x503f03['addUser']({'id':_0x1cc334,'name':_0x4ca12e});}['_createNewComment']({threadId:_0xea8341,commentId:_0x3db99b=_0x238ccd(),content:_0x49f3fe,authorId:_0x22d53f,createdAt:_0x5b63db,attributes:_0x38e73c}){if('string'!=typeof _0x3db99b)throw new _0x3cac4c('commentsrepository-invalid-commentid');if('string'!=typeof _0x22d53f)throw new _0x3cac4c('commentsrepository-invalid-comment-authorid');if('string'!=typeof _0x49f3fe||!_0x49f3fe['trim']())throw new _0x3cac4c('commentsrepository-invalid-comment-content');const _0x577063=this['context']['plugins']['get'](_0x52cabf)['getUser'](_0x22d53f);if(!_0x577063)throw new _0x3cac4c('commentsrepository-add-comment-user-not-exists',null,{'authorId':_0x22d53f});let _0x56c096=null,_0xdfef55=_0x5b63db;return _0x38e73c?.['@external']&&(_0x56c096=this['_getExternalAuthor'](_0x38e73c['@external']['authorName']),_0xdfef55=new Date(_0x38e73c['@external']['createdAt'])),new hi(this,{'threadId':_0xea8341,'id':_0x3db99b,'author':_0x56c096||_0x577063,'creator':_0x577063,'content':_0x49f3fe,'createdAt':_0x5b63db,'authoredAt':_0xdfef55,'attributes':_0x38e73c});}['_addComment'](_0x23c204){let {threadId:_0x9add53,content:_0x49472a,attributes:_0x139f57,isFromAdapter:_0x5a6fd9}=_0x23c204;const _0xcd64be=this['getCommentThread'](_0x23c204['threadId']);if(!_0xcd64be)throw new _0x3cac4c('commentsrepository-add-comment-to-missing-comment-thread',this);const _0x1bd04e=this['_createNewComment'](_0x23c204),{id:_0x3847f6}=_0x1bd04e;if(_0xcd64be['_add'](_0x1bd04e),_0x5a6fd9||!this['adapter']||'function'!=typeof this['adapter']['addComment']||!_0xcd64be['isSubmitted'])return Promise['resolve']();const _0x2da2a3=this['context']['plugins']['get']('PendingActions'),{channelId:_0x191404}=_0xcd64be,_0x2a6f3f=_0x2da2a3['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return _0x139f57||(_0x139f57={}),this['adapter']['addComment']({'channelId':_0x191404,'threadId':_0x9add53,'commentId':_0x3847f6,'content':_0x49472a,'attributes':_0x139f57})['then'](_0x16b1c0=>{_0x2da2a3['remove'](_0x2a6f3f),_0x16b1c0&&this['_updateComment']({'channelId':_0x191404,'threadId':_0x9add53,'commentId':_0x3847f6,'createdAt':_0x16b1c0['createdAt'],'isFromAdapter':!0x0});})['catch'](_0x555fa0=>{throw console['error'](_0x555fa0),new _0x3cac4c('commentsrepository-add-comment-internal-error',this);});}['_updateComment']({threadId:_0x1cce74,commentId:_0x25f1cd,content:_0x1d49c8,createdAt:_0x580965,attributes:_0x416d21,isFromAdapter:_0x63da4e}){if(void 0x0!==_0x1d49c8&&('string'!=typeof _0x1d49c8||!_0x1d49c8['trim']()['length']))throw new _0x3cac4c('commentsrepository-update-comment-invalid-content');const _0x4f746b=this['getCommentThread'](_0x1cce74),_0x24e73d=_0x4f746b['getComment'](_0x25f1cd);if(!_0x24e73d)throw new _0x3cac4c('commentsrepository-update-missing-comment',this);let _0x517493=!0x1;if(_0x1d49c8&&_0x1d49c8!==_0x24e73d['content']&&(_0x24e73d['isEditable']||_0x63da4e)&&(_0x24e73d['content']=_0x1d49c8,_0x517493=!0x0),_0x580965&&_0x580965!==_0x24e73d['createdAt']&&(_0x24e73d['createdAt']=_0x580965,_0x24e73d['isExternal']||(_0x24e73d['authoredAt']=_0x580965),_0x517493=!0x0),_0x416d21&&!_0x4074d8(_0x416d21,_0x24e73d['attributes'])&&(_0x24e73d['attributes']=_0x416d21,_0x517493=!0x0),!_0x517493)return Promise['resolve']();if(_0x4f746b['fire']('commentUpdated'),_0x63da4e||!this['adapter']||'function'!=typeof this['adapter']['updateComment'])return Promise['resolve']();const _0xf8e636=this['context']['plugins']['get']('PendingActions'),{channelId:_0x20c993}=this['getCommentThread'](_0x24e73d['threadId']),_0x4def98=_0xf8e636['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['updateComment']({'channelId':_0x20c993,'threadId':_0x1cce74,'commentId':_0x25f1cd,'content':_0x1d49c8,'attributes':_0x416d21})['then'](()=>_0xf8e636['remove'](_0x4def98))['catch'](_0x47f044=>{throw console['error'](_0x47f044),new _0x3cac4c('commentsrepository-update-comment-internal-error',this);});}['_removeComment']({threadId:_0xd53e10,commentId:_0x3d8041,isFromAdapter:_0x549663}){const _0x54c2a6=this['getCommentThread'](_0xd53e10),_0x435033=_0x54c2a6['getComment'](_0x3d8041);if(!_0x435033)throw new _0x3cac4c('commentsrepository-remove-missing-comment',this);if(_0x54c2a6['_remove'](_0x435033),_0x549663||!this['adapter']||'function'!=typeof this['adapter']['removeComment'])return Promise['resolve']();const _0x4b8032=this['context']['plugins']['get']('PendingActions'),{channelId:_0x443f51}=_0x54c2a6,_0x18ffbc=_0x4b8032['add'](Et(this['context']['locale'],'PENDING_ACTION_COMMENT_THREAD'));return this['adapter']['removeComment']({'channelId':_0x443f51,'threadId':_0xd53e10,'commentId':_0x3d8041})['then'](()=>_0x4b8032['remove'](_0x18ffbc))['catch'](_0x1f5d94=>{throw console['error'](_0x1f5d94),new _0x3cac4c('commentsrepository-remove-comment-internal-error',this);});}},ri=class extends si{['channelId'];['id'];['_isAttached'];['_isSubmitted'];['comments'];['_repository'];constructor(_0x267814,_0x2b9dd2){super();const _0x7c0712=_0x2b9dd2['isResolvable'];this['channelId']=_0x2b9dd2['channelId'],this['id']=_0x2b9dd2['id'],this['comments']=new _0x5c875e(),this['_repository']=_0x267814,this['_isAttached']=!0x1,this['_isSubmitted']=_0x2b9dd2['isSubmitted'],this['set']('_hasTargetInContent',!0x0),this['bind']('isReadOnly')['to'](_0x267814,'_permissions',_0x267814,'_readOnlyChannels',()=>_0x267814['isReadOnly'](this['channelId'])),this['bind']('isRemovable')['to'](_0x267814,'_permissions',()=>_0x267814['getPermissions'](this['channelId'])['admin']),this['bind']('canComment')['to'](_0x267814,'_permissions',()=>{const _0x1a9286=_0x267814['getPermissions'](this['channelId']);return _0x1a9286['write']||_0x1a9286['admin'];}),this['bind']('isResolvable')['to'](_0x267814,'_permissions',()=>_0x7c0712&&_0x267814['getPermissions'](this['channelId'])['resolve']),this['set']('context',_0x2b9dd2['context']),this['bind']('archivedAt')['to'](this,'resolvedAt',this,'unlinkedAt',(_0x2af22e,_0x1f8f1b)=>_0x2af22e?_0x1f8f1b?_0x2af22e<_0x1f8f1b?_0x2af22e:_0x1f8f1b:_0x2af22e:_0x1f8f1b),this['set']('unlinkedAt',_0x2b9dd2['unlinkedAt']||null),this['set']('resolvedAt',_0x2b9dd2['resolvedAt']||null),this['set']('resolvedBy',_0x2b9dd2['resolvedBy']||null),this['bind']('isResolved')['to'](this,'resolvedAt',_0x4581ae=>!!_0x4581ae),this['set']('attributes',_0x2b9dd2['attributes']||{});}get['weight'](){return Array['from'](this['comments'])['reduce']((_0x219607,_0x6b808a)=>_0x219607+_0x6b808a['weight'],0x0);}get['length'](){return this['comments']['length'];}get['isAttached'](){return this['_isAttached'];}get['isSubmitted'](){return this['_isSubmitted'];}['submit'](){const {channelId:_0x33c401,id:_0x81c7ca}=this;this['_repository']['fire'](ai('submitCommentThread',_0x33c401),{'channelId':_0x33c401,'threadId':_0x81c7ca});}['setUnlinkedAt'](_0x4b8209){this['_update']({'unlinkedAt':_0x4b8209});}['resolve']({resolvedAt:_0x3372f6=new Date(),resolvedBy:_0x27c2dd='',isFromAdapter:_0x52835f=!0x1}={}){const _0xaa8535=this['_repository']['context']['plugins']['get'](_0x52cabf)['me'],{channelId:_0x7370f8,id:_0x37ab8a}=this;this['_repository']['fire'](ai('resolveCommentThread',_0x7370f8),{'channelId':_0x7370f8,'threadId':_0x37ab8a,'resolvedAt':_0x3372f6,'resolvedBy':_0x27c2dd||_0xaa8535['id'],'isFromAdapter':_0x52835f});}['reopen']({isFromAdapter:_0x4f381a=!0x1}={}){const {channelId:_0x3d2134,id:_0x4f8939}=this;this['_repository']['fire'](ai('reopenCommentThread',_0x3d2134),{'channelId':_0x3d2134,'threadId':_0x4f8939,'isFromAdapter':_0x4f381a});}['setContext'](_0x2f3eb3){this['context']||this['_update']({'context':_0x2f3eb3});}['setAttribute'](_0x354897,_0xa92176){const _0x590adc=_0x2cf7e4(this['attributes']);_0x27c082(_0x590adc,_0x354897,_0xa92176),this['_update']({'attributes':_0x590adc});}['removeAttribute'](_0x2700b3){const _0xd07c39=_0x2cf7e4(this['attributes']);_0xeea9c4(_0xd07c39,_0x2700b3),this['_update']({'attributes':_0xd07c39});}['remove']({isFromAdapter:_0x4c193a=!0x1}={}){const {channelId:_0x350a60,id:_0x12451f}=this;this['_repository']['fire'](ai('removeCommentThread',_0x350a60),{'channelId':_0x350a60,'threadId':_0x12451f,'isFromAdapter':_0x4c193a});}['attachTo'](_0xf080de){return this['_repository']['_attachCommentThread']({'threadId':this['id'],'target':_0xf080de});}['addComment'](_0x42ee67){const {channelId:_0x24b7fa,id:_0x2bf35d}=this;this['_repository']['fire'](ai('addComment',_0x24b7fa,_0x2bf35d),Object['assign']({'channelId':_0x24b7fa,'threadId':_0x2bf35d},_0x42ee67));}['getComment'](_0x539ece){if('string'!=typeof _0x539ece)throw new _0x3cac4c('commentsrepository-get-comment-invalid-id',null,{'commentId':_0x539ece});return this['comments']['get'](_0x539ece);}['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'](_0x2ba58e=>_0x2ba58e['toJSON']()),'attributes':this['attributes']};}['_add'](_0x88a9fd){return this['listenTo'](_0x88a9fd,'change:authoredAt',()=>{const _0x73ff49=this['_findOptimalIndex'](_0x88a9fd),_0x71ddf9=this['comments'];_0x73ff49-0x1!=_0x71ddf9['getIndex'](_0x88a9fd)&&_0x73ff49+0x1!=_0x71ddf9['getIndex'](_0x88a9fd)&&(this['_remove'](_0x88a9fd),this['_add'](_0x88a9fd));}),this['comments']['add'](_0x88a9fd,this['_findOptimalIndex'](_0x88a9fd));}['_update'](_0x508232){const {channelId:_0x3d61b6,id:_0x46054d}=this;this['_repository']['fire'](ai('updateCommentThread',_0x3d61b6),{..._0x508232,'channelId':_0x3d61b6,'threadId':_0x46054d});}['_remove'](_0x208354){return this['stopListening'](_0x208354),_0x208354['destroy'](),this['comments']['remove'](_0x208354);}['_findOptimalIndex'](_0x332d83){const _0x56b98c=this['comments']['find'](_0x95aa7=>new Date(_0x95aa7['authoredAt'])['getTime']()>new Date(_0x332d83['authoredAt'])['getTime']());return _0x56b98c?this['comments']['getIndex'](_0x56b98c):this['length'];}},hi=class extends ni{['id'];['threadId'];['author'];['creator'];['createdAt'];['_repository'];constructor(_0x3a914e,_0x298306){super();const _0x41eed8=_0x3a914e['context']['plugins']['get'](_0x52cabf)['me'],_0x1bb2a0=_0x3a914e['getCommentThread'](_0x298306['threadId']),_0x49d414=0x0===_0x1bb2a0['comments']['length'],_0x1461c5=_0x41eed8===_0x298306['author'];this['id']=_0x298306['id'],this['threadId']=_0x298306['threadId'],this['author']=_0x298306['author'],this['creator']=_0x298306['creator'],this['set']('content',_0x298306['content']),this['createdAt']=_0x298306['createdAt']||new Date(),this['set']('authoredAt',_0x298306['authoredAt']||new Date()),this['bind']('resolvedAt')['to'](_0x1bb2a0,'resolvedAt'),this['set']('attributes',_0x298306['attributes']||{}),this['bind']('isEditable')['to'](_0x3a914e,'_permissions',()=>{const _0x4d3a7d=_0x3a914e['getPermissions'](_0x1bb2a0['channelId'])['write'],_0x18a0bc=_0x3a914e['getPermissions'](_0x1bb2a0['channelId'])['modifyAll'];return _0x1461c5&&_0x4d3a7d||!_0x1461c5&&_0x18a0bc;}),this['bind']('isRemovable')['to'](_0x1bb2a0,'isRemovable',_0x3a914e,'_permissions',_0x15d34c=>{const _0x274ae6=_0x3a914e['getPermissions'](_0x1bb2a0['channelId'])['write'],_0x1f1a1b=_0x3a914e['getPermissions'](_0x1bb2a0['channelId'])['modifyAll'];return _0x1461c5&&_0x274ae6||_0x15d34c&&_0x49d414||!_0x1461c5&&_0x1f1a1b&&!_0x49d414;}),this['bind']('isReadOnly')['to'](_0x1bb2a0,'isReadOnly'),this['_repository']=_0x3a914e;}get['isExternal'](){return Boolean(this['attributes']&&this['attributes']['@external']);}get['weight'](){return Math['max'](function(_0x41cee6){const _0x3bf180=document['createElement']('div');return _0x3bf180['innerHTML']=_0x41cee6,_0x3bf180['textContent']['length'];}(this['content']),0xc8);}['update'](_0x35721e){const {threadId:_0x41ffb8,id:_0x1fcca3}=this;if(!this['_repository']['hasCommentThread'](_0x41ffb8))throw new _0x3cac4c('commentsrepository-update-comment-missing-comment-thread',this);const {channelId:_0x32b69b}=this['_repository']['getCommentThread'](_0x41ffb8);this['_repository']['fire'](ai('updateComment',_0x32b69b,_0x41ffb8),{'channelId':_0x32b69b,'threadId':_0x41ffb8,'commentId':_0x1fcca3,..._0x35721e});}['setAttribute'](_0x52b116,_0x243ddb){const _0x3bfb9b=_0x2cf7e4(this['attributes']);_0x27c082(_0x3bfb9b,_0x52b116,_0x243ddb),this['update']({'attributes':_0x3bfb9b});}['removeAttribute'](_0x1c1f34){const _0x2075b8=_0x2cf7e4(this['attributes']);_0xeea9c4(_0x2075b8,_0x1c1f34),this['update']({'attributes':_0x2075b8});}['remove'](_0x168d67={}){if(!_0x168d67['isFromAdapter']&&!this['isRemovable'])return;const {threadId:_0x49fac8,id:_0x236afc}=this;if(!this['_repository']['hasCommentThread'](_0x49fac8))throw new _0x3cac4c('commentsrepository-remove-comment-missing-comment-thread',this);const {channelId:_0x4de300}=this['_repository']['getCommentThread'](_0x49fac8);this['_repository']['fire'](ai('removeComment',_0x4de300,_0x49fac8),{'channelId':_0x4de300,'threadId':_0x49fac8,'commentId':_0x236afc,..._0x168d67});}['toJSON'](){return{'commentId':this['id'],'content':this['content'],'createdAt':this['createdAt'],'authorId':this['creator']['id'],'attributes':this['attributes']};}['destroy'](){this['stopListening']();}};function ai(_0x474856,..._0x3e3004){for(const _0x2e671f of _0x3e3004)void 0x0!==_0x2e671f&&(_0x474856+=':'+String(_0x2e671f));return _0x474856;}var ci=class extends _0x54d867{constructor(_0x327cd1){super(_0x327cd1),this['set']('hasContent',!0x1);}['refresh'](){const _0x458cce=this['editor']['model']['document']['selection'];this['isEnabled']=!0x0,this['hasContent']=!0x1;for(const _0x569f1b of _0x458cce['getRanges']())if(this['_hasContent'](_0x569f1b))return void(this['hasContent']=!0x0);}['execute']({threadId:_0x357631=_0x238ccd(),ranges:_0x5c98d2,comment:_0x4062c2}={}){const _0x21de1e=this['editor']['model'],_0x59c2f6=_0x5c98d2??Array['from'](_0x21de1e['document']['selection']['getRanges']()),_0x55e6b8=[];for(const _0x528e4f of _0x59c2f6)this['_hasContent'](_0x528e4f)&&_0x55e6b8['push'](this['_trimToContent'](_0x528e4f));if(!_0x55e6b8['length'])throw new _0x3cac4c('addcommentthreadcommand-incorrect-ranges',null);_0x4062c2&&this['_createCommentThread'](_0x357631,_0x4062c2),this['_createMarkersFromRanges'](_0x357631,_0x55e6b8,!!_0x4062c2);}['_createMarkersFromRanges'](_0x20d658,_0x5e1a19,_0x4a5e32){this['editor']['model']['change'](_0x4095f8=>{for(const _0x3dd711 of _0x5e1a19){const _0x3fd115='comment:'+_0x20d658+':'+_0x238ccd()['substr'](0x1,0x5);_0x4095f8['addMarker'](_0x3fd115,{'range':_0x3dd711,'usingOperation':_0x4a5e32,'affectsData':_0x4a5e32});}});}['_createCommentThread'](_0x1e11cc,_0xba76f9){const _0x4168b8=this['editor']['plugins']['get']('CommentsRepository'),_0x54fd0b=this['editor']['config']['get']('collaboration.channelId'),_0x2a321a=this['editor']['plugins']['get']('Users')['me'];if(!_0x2a321a)throw new _0x3cac4c('addcommentthreadcommand-user-not-found',null);_0x4168b8['addCommentThread']({'threadId':_0x1e11cc,'channelId':_0x54fd0b,'comments':[{'authorId':_0x2a321a['id'],'content':_0xba76f9,'createdAt':new Date(),'attributes':{}}]});}['_hasContent'](_0x5b5f8b){for(const _0x5eb0d6 of _0x5b5f8b['getItems']())if(this['_itemIsContent'](_0x5eb0d6))return!0x0;return!0x1;}['_itemIsContent'](_0x186775){return _0x186775['is']('$textProxy')||this['editor']['model']['schema']['isObject'](_0x186775)&&!_0x186775['is']('element','tableCell');}['_trimToContent'](_0x5369f4){const _0x2ba389=_0xc3d75b=>!this['_itemIsContent'](_0xc3d75b['item']),_0xd3c9e8=_0x5369f4['start']['getLastMatchingPosition'](_0x2ba389),_0x18c985=_0x5369f4['end']['getLastMatchingPosition'](_0x2ba389,{'direction':'backward'});return this['editor']['model']['createRange'](_0xd3c9e8,_0x18c985);}},di=class extends _0x1228a1{['_dataCollectors'];['_editorAnnotations'];static get['requires'](){return[ti];}static get['pluginName'](){return'EditorAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x37a415){super(_0x37a415),this['_dataCollectors']=new Set(),this['_editorAnnotations']=new Set();}['init'](){const _0xdb10bd=this['editor'],_0x728c56=_0xdb10bd['model']['document']['selection'],_0xc9e6ce=_0x55ca5d(()=>this['refreshSelectedViews'](),0xa);_0x728c56['on']('change:range',(_0x3b47e6,_0x3a58f3)=>{_0x3a58f3['directChange']&&(_0xc9e6ce['cancel'](),this['refreshSelectedViews']());}),this['listenTo'](_0xdb10bd['editing']['view']['document'],'change:isFocused',(_0xa1ba5c,_0x38f16b,_0x15585a)=>{_0x15585a&&_0xc9e6ce();}),this['listenTo'](_0xdb10bd['ui']['focusTracker'],'change:isFocused',(_0x46103a,_0x485e9d,_0x21c5c6)=>{_0x21c5c6||this['fire']('blur',{'isAnnotationTracked':_0x2bd8ca=>this['_editorAnnotationsData']['has'](_0x2bd8ca['innerView'])});}),this['listenTo'](this['editor']['ui'],'update',()=>this['fire']('uiUpdate'));}['registerAnnotation'](_0x313cab){if(this['_editorAnnotations']['has'](_0x313cab['view']))return;this['_editorAnnotations']['add'](_0x313cab['view']),this['editor']['ui']['focusTracker']['add'](_0x313cab['view']['element']);const _0x126298=this['editor']['plugins']['get'](ti);this['listenTo'](_0x126298['collection'],'remove',(_0x3b3a61,_0x31ffc7)=>{this['editor']['ui']['focusTracker']['remove'](_0x31ffc7['view']['element']),this['_editorAnnotations']['delete'](_0x31ffc7['view']);});}['hasDomSelection'](){return this['editor']['editing']['view']['hasDomSelection'];}['addSourceCollector'](_0x15b513){if('function'!=typeof _0x15b513)throw new _0x3cac4c('editorannotations-invalid-source-callback');this['_dataCollectors']['add'](_0x15b513);}['refreshSelectedViews'](){this['fire']('refresh');}['getOrderedSelectedAnnotations']({activeAnnotation:_0x4c178f,annotations:_0x253d0c}){const _0x30bbd2=[],_0xefe185=this['editor']['model']['document']['selection'],_0x2eebd8=Array['from'](_0xefe185['getRanges']());for(const [_0x59f7a7,_0x75b967]of this['_editorAnnotationsData']){const _0xa12f7f=_0x1543db(_0x75b967),_0x31882f=_0x253d0c['getByInnerView'](_0x59f7a7);_0xa12f7f&&_0x31882f&&_0x30bbd2['push']({'annotation':_0x31882f,'range':_0xa12f7f});}function _0x1543db(_0x5741e3){for(const _0x40d715 of _0x5741e3)for(const _0x59e98f of _0x2eebd8)if(_0x40d715['containsRange'](_0x59e98f,!_0xefe185['isCollapsed']))return _0x40d715;return null;}return _0x30bbd2['sort']((_0x56e81d,_0x1fefcc)=>{const _0x1f188a=_0x56e81d['range'],_0x51fb38=_0x1fefcc['range'];if(!_0x1f188a['isEqual'](_0x51fb38)){if(_0x1f188a['containsRange'](_0x51fb38,!0x0))return 0x1;if(_0x51fb38['containsRange'](_0x1f188a,!0x0))return-0x1;}return _0x56e81d['annotation']==_0x4c178f?-0x1:_0x1fefcc['annotation']==_0x4c178f?0x1:0x0;})['map'](_0x3aba41=>_0x3aba41['annotation']);}get['_editorAnnotationsData'](){const _0x4a14ad=new Map();for(const _0x389bfe of Array['from'](this['_dataCollectors']))for(const [_0x3fc11d,_0x867175]of _0x389bfe())_0x4a14ad['set'](_0x3fc11d,_0x867175);return _0x4a14ad;}},li=class extends _0x1228a1{['afterInit'](){const _0x22cac3=this['editor'];_0x22cac3['plugins']['has']('RestrictedEditingModeEditing')&&_0x22cac3['plugins']['get']('RestrictedEditingModeEditing')['enableCommand']('addCommentThread');}},mi=class extends _0x1228a1{constructor(_0x21f2e3){super(_0x21f2e3),this['editor']['config']['define']('importWord.formatting.comments','basic');}['afterInit'](){const _0x45aa8f=this['editor'],_0x3ea765=_0x45aa8f['commands']['get']('importWord'),_0x1dccb0=_0x45aa8f['plugins']['get'](_0x52cabf);_0x3ea765&&(_0x3ea765['on']('execute',(_0xfac127,[,_0x3ce540])=>{_0x3ce540['collaboration_features']={'comments':!0x0,'user_id':_0x1dccb0['me']['id']};},{'priority':_0x5f4140['high']+0xa}),this['listenTo'](_0x3ea765,'dataInsert',this['_handleImportedData']));}['_handleImportedData'](_0x13a86c,_0x5aae2c){const {comment_threads:_0x405727}=_0x5aae2c;_0x405727&&_0x405727['forEach'](({thread_id:_0x36857f,comments:_0x398cd1,is_resolved:_0x42967b})=>{const _0x389d51=new Date(),_0x4d71ac=_0x398cd1['map'](({author:_0x406e85,content:_0x520b76,created_at:_0x35e3e1})=>({'content':_0x520b76,'authorId':this['editor']['plugins']['get'](_0x52cabf)['me']['id'],'createdAt':_0x389d51,'attributes':{'@external':{'authorName':_0x406e85,'createdAt':_0x35e3e1?new Date(_0x35e3e1):new Date(),'source':'importWord'}}})),_0x585e39=this['editor']['config']['get']('collaboration.channelId');this['editor']['plugins']['get'](oi)['addCommentThread']({'channelId':_0x585e39,'threadId':_0x36857f,'comments':_0x4d71ac,'resolvedAt':_0x42967b?_0x389d51:null});});}},ui=class extends _0x1228a1{constructor(_0x2bf838){super(_0x2bf838),this['editor']['config']['define']('comments.copyMarkers','default');}static get['requires'](){return[pt,wt];}['afterInit'](){const _0x535c4e=this['editor']['plugins']['get']('ClipboardPipeline');this['_registerMarkerInClipboardPipeline'](),this['listenTo'](_0x535c4e,'contentInsertion',(_0x59d704,_0x44ac78)=>this['_removeMarkersWithoutThreads'](_0x44ac78['content']['markers']),{'priority':'highest'});}['_removeMarkersWithoutThreads'](_0x4a1f57){if(!this['editor']['plugins']['has']('CommentsRepository'))return _0x4a1f57;const _0x3d426d=this['editor']['plugins']['get']('CommentsRepository');for(const _0x1413f6 of _0x4a1f57['keys']()){const [_0x39bcd6,_0x4bc816]=_0x1413f6['split'](':');'comment'!=_0x39bcd6||_0x3d426d['hasCommentThread'](_0x4bc816)||_0x4a1f57['delete'](_0x1413f6);}return _0x4a1f57;}['_registerMarkerInClipboardPipeline'](){const _0x4d6941=this['editor']['plugins']['get']('ClipboardMarkersUtils'),_0x4537e1=this['_mapCommentsCopyConfigToRegisterConfiguration'](this['editor']['config']['get']('comments.copyMarkers'));_0x4537e1&&_0x4d6941['_registerMarkerToCopy']('comment',_0x4537e1);}['_mapCommentsCopyConfigToRegisterConfiguration'](_0x370159){switch(_0x370159){case'always':return{'allowedActions':'all','copyPartiallySelected':!0x1,'duplicateOnPaste':!0x0};case'default':return{'allowedActions':['cut','dragstart'],'copyPartiallySelected':!0x1,'duplicateOnPaste':!0x1};default:return null;}}};function fi(_0x315ea8){const _0x4d1f06=_0x315ea8['split'](':');return{'group':_0x4d1f06[0x0],'id':_0x4d1f06[0x1],'part':_0x4d1f06[0x2]};}var pi=class extends _0x1228a1{['init'](){this['overrideMarkerConverters'](),this['overrideHorizontalRuleConverter'](),this['overrideImageInlineConverter'](),this['overrideMediaEmbedConverter']();}['overrideMarkerConverters'](){this['editor']['conversion']['for']('dataDowncast')['markerToHighlight']({'model':'comment','view':(_0x45514a,_0x53e316)=>{if(!_0x53e316['options']['showCommentHighlights'])return null;if(_0x53e316['options']['ignoreResolvedComments']){const {id:_0x37fde2}=fi(_0x45514a['markerName']);if(this['editor']['plugins']['get'](oi)['getCommentThread'](_0x37fde2)?.['isResolved']&&_0x45514a['item'])return _0x53e316['consumable']['consume'](_0x45514a['item'],'addMarker:'+_0x45514a['markerName']),_0x53e316['consumable']['consume'](_0x45514a['item'],'removeMarker:'+_0x45514a['markerName']),null;}return{'classes':['ck-comment-marker']};}}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5b2941=>{_0x5b2941['on']('addMarker:comment',(_0x350a2c,_0x4bca31,_0xf17947)=>{if(!_0xf17947['options']['showCommentHighlights'])return;const _0x49d1ec=_0x4bca31['item'];if(!_0x49d1ec)return;const _0x489c43=_0xf17947['mapper']['toViewElement'](_0x49d1ec);this['editor']['model']['schema']['isObject'](_0x49d1ec)&&_0x489c43&&!_0x489c43['getCustomProperty']('widget')&&_0x489c43['is']('containerElement')&&Ct(_0x489c43,_0xf17947['writer']);},{'priority':'high'});});}['overrideHorizontalRuleConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'horizontalLine','view':(_0x4a49de,{writer:_0x154af5,options:_0x490fad})=>{if(!_0x490fad['showCommentHighlights'])return null;const _0x381fde=_0x154af5['createContainerElement']('div'),_0x2e805f=_0x154af5['createEmptyElement']('hr');return _0x154af5['addClass']('ck-horizontal-line',_0x381fde),_0x154af5['insert'](_0x154af5['createPositionAt'](_0x381fde,0x0),_0x2e805f),_0x381fde;},'converterPriority':'high'});}['overrideImageInlineConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToStructure']({'model':'imageInline','view':(_0x5c8041,{writer:_0x5f4cdd,options:_0x3403da})=>{if(!_0x3403da['showCommentHighlights'])return null;const _0x14d0dc=_0x5f4cdd['createContainerElement']('span'),_0x2e04a4=_0x5f4cdd['createEmptyElement']('img');return _0x5f4cdd['addClass']('image-inline',_0x14d0dc),_0x5f4cdd['insert'](_0x5f4cdd['createPositionAt'](_0x14d0dc,0x0),_0x2e04a4),_0x14d0dc;},'converterPriority':'high'});}['overrideMediaEmbedConverter'](){this['editor']['conversion']['for']('dataDowncast')['elementToElement']({'model':'media','view':(_0x1d7057,{writer:_0x206af7,options:_0x34199b})=>{if(_0x34199b['showCommentHighlights'])return _0x206af7['createEmptyElement']('div');},'converterPriority':'high'}),this['editor']['data']['downcastDispatcher']['on']('attribute:url:media',(_0x5729f1,_0x21fa75,_0x32712c)=>{_0x32712c['options']['showCommentHighlights']&&_0x5729f1['stop']();},{'priority':'high'});}},wi=class extends _0x1228a1{static get['requires'](){return[oi,di,_0x52cabf,li,mi,ui,pi];}static get['pluginName'](){return'CommentsEditing';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x371699){super(_0x371699),this['set']('isThreadsLoadingPaused',!0x0),_0x371699['data']['once']('ready',()=>this['isThreadsLoadingPaused']=!0x1),this['set']('activeMarker',null),this['on']('change:activeMarker',(_0x167f9a,_0x5e6042,_0xeb71e8,_0x75479f)=>{const _0x47a131=_0x371699['plugins']['get'](oi),_0x298a67=_0xeb71e8?fi(_0xeb71e8)['id']:null;_0x371699['model']['change'](()=>{if(_0x298a67){const _0x18318b=this['getAllMarkersForId'](_0x298a67);for(const _0x459364 of _0x18318b)_0x371699['editing']['reconvertMarker'](_0x459364);}if(_0x75479f){const {id:_0x5007f1}=fi(_0x75479f),_0x430d4f=_0x47a131['getCommentThread'](_0x5007f1);if(_0x430d4f&&_0x430d4f['unlinkedAt'])return;if(_0x430d4f&&!_0x430d4f['isAttached'])return;const _0x426245=this['getAllMarkersForId'](_0x5007f1);for(const _0x2550d7 of _0x426245)_0x371699['editing']['reconvertMarker'](_0x2550d7);}}),_0x298a67&&this['scrollToThreadMarker'](_0x298a67);}),this['_initAriaMarkerChangeAnnouncements']();}['init'](){const _0x165492=this['editor'],_0x3f83db=_0x165492['plugins']['get'](oi),_0x4ae279=_0x165492['config']['get']('collaboration.channelId'),_0x2b1e18=_0x3f83db['getCommentThreads']()['filter'](_0x4e6b2b=>_0x4e6b2b['channelId']!==_0x4ae279);_0x165492['commands']['add']('addCommentThread',new ci(_0x165492)),this['listenTo'](_0x165492,'change:isReadOnly',(_0x44da99,_0x40c44d,_0xcd71cb)=>{_0x3f83db['switchReadOnly'](_0xcd71cb,_0x165492['config']['get']('collaboration.channelId'));}),this['listenTo'](_0x3f83db,gi('addCommentThread',_0x4ae279),(_0x4d927e,{threadId:_0x5d40cc})=>{this['editor']['plugins']['get'](oi)['getCommentThread'](_0x5d40cc)?.['unlinkedAt']&&this['_attachArchivedThread'](_0x5d40cc);}),this['listenTo'](_0x3f83db,gi('removeCommentThread',_0x4ae279),(_0x437499,{threadId:_0x50d5f3})=>{_0x165492['model']['enqueueChange']({'isUndoable':!0x1},_0x2378ea=>{const _0x4abe1b=this['getAllMarkersForId'](_0x50d5f3);for(const _0x18c3b2 of _0x4abe1b)_0x2378ea['removeMarker'](_0x18c3b2);});}),this['listenTo'](_0x3f83db,gi('resolveCommentThread',_0x4ae279),(_0x26fe4a,{threadId:_0x267a70})=>{this['_reconvertMarkers'](_0x267a70);const _0x5c7e19=this['editor']['plugins']['get'](ti);(this['editor']['editing']['view']['hasDomSelection']||_0x5c7e19['collection']['isFocused'])&&(this['editor']['plugins']['get'](oi)['getCommentThread'](_0x267a70)['unlinkedAt']||this['editor']['editing']['view']['focus']());},{'priority':'low'}),this['listenTo'](_0x3f83db,gi('reopenCommentThread',_0x4ae279),(_0x7fc1b0,{threadId:_0x5a34b3})=>{this['_reconvertMarkers'](_0x5a34b3);},{'priority':'low'}),this['listenTo'](_0x3f83db,gi('addComment',_0x4ae279),(_0x14b8b3,{threadId:_0x49819c,isFromAdapter:_0x13c3e9})=>{const _0x5c0633=this['getAllMarkersForId'](_0x49819c);!_0x13c3e9&&0x0!=_0x5c0633['length']&&_0x3f83db['hasCommentThread'](_0x49819c)&&0x1===_0x3f83db['getCommentThread'](_0x49819c)['length']&&_0x165492['model']['enqueueChange']({'isUndoable':!0x1},_0x2a904e=>{for(const _0x12e68a of _0x5c0633)_0x2a904e['updateMarker'](_0x12e68a,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this['_initializeMarkerConverters'](),this['_handleMarkerAddAndRemove'](),this['_handleInitialThreads'](_0x2b1e18);}['afterInit'](){!async function(_0x24f1a7){const _0x55a86d='KpOBJGNSEgqCyfVF1kZ8lbnRjM7eIzAsDQHw9aThu6rcYi05UmPL4d3X2Wotvx',_0x1efb72=0x78e70,_0x4c282d=window['Date']['now'](),_0x5e3fcc=_0x24f1a7['editor'],_0x325639=new window['Promise'](_0x3afe8a=>{_0x5e3fcc['once']('ready',_0x3afe8a);}),_0x32385b={'kty':'EC','use':'sig','crv':'P-256','x':'iCjOCvDFI6lQHHT18jVwRfkfHQ2a_MymT35LQVoFSAI','y':'kXIyJ4evtCEFRmxKSUpK9fDW459vXOvVrhf6uQAeOio','alg':'ES256'},_0x40876b=_0x5e3fcc['config']['get']('licenseKey');async function _0x1e73e3(){let _0x20d36a,_0x2b5271=null,_0x35107a=null;try{return'GPL'==_0x40876b?'NotAllowed':(_0x20d36a=_0x29f0b0(),_0x20d36a?(_0x20d36a['usageEndpoint']&&(_0x35107a=_0x4a4572(_0x20d36a['usageEndpoint'],_0x20d36a['jti'])),await _0x4457ad()?_0x1f382f()?_0x321672()?'Expired':_0x37ddb8()?('evaluation'==_0x20d36a['licenseType']&&(_0x2b5271=_0x4c9b94('EvaluationLimit')),await _0x41e65e()):'DomainLimit':'NotAllowed':'Invalid'):'Invalid');}catch{return'Invalid';}function _0x321672(){const _0x3409f6=['evaluation','trial']['includes'](_0x20d36a['licenseType'])?_0x4c282d/0x3e8:0xe10*_0x1efb72;return _0x20d36a['exp']<_0x3409f6;}function _0x1f382f(){const _0x2fa294=_0x20d36a['features'];if(!_0x2fa294)return!0x1;if(_0x2fa294['includes']('*'))return!0x0;if(_0x2fa294['includes']('CMT'))return!0x0;if(_0x2fa294['includes']('TRILIUM')&&_0x2d0985())return!0x0;if(_0x2fa294['includes']('RCMT')){if(_0x1b6ba7())return!0x0;if(_0xf40fc1()||_0x3fef77())return!0x0;}return!0x1;}function _0x37ddb8(){const _0x3ff0b5=_0x20d36a['licensedHosts'];if(!_0x3ff0b5||0x0==_0x3ff0b5['length'])return!0x0;const {hostname:_0x54a62e}=new URL(window['location']['href']);if(_0x3ff0b5['includes'](_0x54a62e))return!0x0;const _0x4d3758=_0x54a62e['split']('.');return _0x3ff0b5['filter'](_0x247081=>_0x247081['includes']('*'))['map'](_0xa47028=>_0xa47028['split']('.'))['filter'](_0x33f617=>_0x33f617['length']<=_0x4d3758['length'])['map'](_0x16f77f=>Array(_0x4d3758['length']-_0x16f77f['length'])['fill']('*'===_0x16f77f[0x0]?'*':'')['concat'](_0x16f77f))['some'](_0x45b9b4=>_0x4d3758['every']((_0x4cd335,_0x14d516)=>_0x45b9b4[_0x14d516]===_0x4cd335||'*'===_0x45b9b4[_0x14d516]));}function _0x41e65e(){return _0x2b5271&&_0x35107a?new window['Promise']((_0x370e6d,_0xa2d898)=>{_0x2b5271['then'](_0x370e6d,_0xa2d898),_0x35107a['then'](_0x1076fb=>{'Valid'!=_0x1076fb&&_0x370e6d(_0x1076fb);},_0xa2d898);}):_0x2b5271||_0x35107a||'Valid';}}function _0x4a4572(_0x596fe3,_0x44fa4a){return new window['Promise'](_0x43c832=>{if(_0x590f60())return _0x43c832('Valid');_0x350d57(),_0x5e3fcc['decorate']('_sendUsageRequest');let _0x3c174f=!0x1;const _0x47b47d=_0x238ccd();function _0x52d800(_0x496f8e){return!!_0x496f8e&&('object'==typeof _0x496f8e||'function'==typeof _0x496f8e)&&'function'==typeof _0x496f8e['then']&&'function'==typeof _0x496f8e['catch'];}function _0x1d474f(_0x5e8e93){_0x3e2ccf(_0x5e8e93)['then'](_0x5d6b67=>_0x5d6b67&&'ok'==_0x5d6b67['status']?_0xb427d1(_0x52248a(_0x47b47d+_0x44fa4a))!=_0x5d6b67['verification']?'UsageLimit':'Valid':'UsageLimit')['then'](_0x333c0e=>(_0x11350c(),_0x333c0e),()=>{const _0x19b00d=_0x972383();return null==_0x19b00d?(_0x11350c(),'Valid'):_0x4c282d-_0x19b00d>0x240c8400?'UsageLimit':'Valid';})['then'](_0x43c832)['catch'](()=>{_0x43c832('UsageLimit');});const _0x24e02a=0x36ee80;function _0x11350c(){const _0x446d11='llct-'+_0xb427d1(_0x52248a(_0x596fe3)),_0x118207=_0x32dd74(_0xb427d1(window['Math']['ceil'](_0x4c282d/_0x24e02a)));window['localStorage']['setItem'](_0x446d11,_0x118207);}function _0x972383(){const _0x9c3e61='llct-'+_0xb427d1(_0x52248a(_0x596fe3)),_0x1cfbe4=window['localStorage']['getItem'](_0x9c3e61);return _0x1cfbe4?window['parseInt'](_0x32dd74(_0x1cfbe4),0x10)*_0x24e02a:null;}function _0x3e2ccf(_0x186052){return new window['Promise']((_0x3c9dea,_0x2396eb)=>{_0x186052['then'](_0x3c9dea,_0x2396eb),window['setTimeout'](_0x2396eb,0x1d4c0);});}}_0x5e3fcc['on']('_sendUsageRequest',(_0x367c4c,_0xd29ebd)=>{if(_0xd29ebd[0x0]!=_0x596fe3)return _0x43c832('UsageLimit');_0xd29ebd[0x1]={..._0xd29ebd[0x1],'requestId':_0x47b47d};},{'priority':'high'}),_0x5e3fcc['on']('_sendUsageRequest',_0x297b90=>{_0x52d800(_0x297b90['return'])&&(_0x3c174f=!0x0,_0x1d474f(_0x297b90['return']));},{'priority':'low'}),_0x325639['then'](()=>{_0x3c174f||_0x43c832('UsageLimit');});});function _0x590f60(){return'auto'==_0x5e3fcc['editing']['view']['_overlayModeHint'];}function _0x350d57(){_0x5e3fcc['editing']['view']['_overlayModeHint']='auto';}}function _0x4c9b94(_0x34b4ee){const _0x27b3cd=[new window['Promise'](_0xe66fbe=>setTimeout(_0xe66fbe,0x93ecc)),_0x325639['then'](()=>new window['Promise'](_0x5dc772=>{let _0x425a9f=0x0;_0x5e3fcc['model']['on']('applyOperation',(_0x48aaf9,_0x1ebf41)=>{_0x1ebf41[0x0]['isDocumentOperation']&&_0x425a9f++,0x5e8==_0x425a9f&&(_0x5dc772(),_0x48aaf9['off']());});}))];return window['Promise']['race'](_0x27b3cd)['then'](()=>_0x34b4ee);}async function _0x5d0c7f(){await _0x325639,_0x5e3fcc['model']['change']=_0xadfb26,_0x5e3fcc['model']['enqueueChange']=_0xadfb26,_0x5e3fcc['enableReadOnlyMode']('model');}function _0x2d0985(){return window['glob']&&window['glob']['triliumVersion'];}function _0x1b6ba7(){return _0x39818f('WebSocketGateway')&&'connected'==_0x84d1bc('WebSocketGateway')['state'];}function _0xf40fc1(){return _0x39818f('RevisionViewerIntegration');}function _0x3fef77(){return _0x39818f('TrackChangesDataGetter');}function _0x501230(_0x39fa72){const _0x349f12=_0x4a9403();_0x5e3fcc[_0x349f12]='commentsLicenseKey'+_0x39fa72,'Valid'!=_0x39fa72&&_0x5d0c7f();}function _0x4a9403(){const _0x5ba4b6=window['String'](window['performance']['now']())['replace']('.','');let _0x518b5c='K';for(let _0x4bb710=0x0;_0x4bb710<_0x5ba4b6['length'];_0x4bb710+=0x2){let _0x14a55d=window['parseInt'](_0x5ba4b6['substring'](_0x4bb710,_0x4bb710+0x2));_0x14a55d>=0x3e&&(_0x14a55d-=0x3e),_0x518b5c+=_0x55a86d[_0x14a55d];}return _0x518b5c;}function _0x29f0b0(){const _0x2ed3c6=_0x40876b['split']('.');if(0x3!=_0x2ed3c6['length'])return null;return _0x1378f8(_0x2ed3c6[0x1]);function _0x1378f8(_0x44ca05){const _0xf5906f=_0x3768e1(_0x44ca05);return _0xf5906f&&_0x1cc813()?_0xf5906f:null;function _0x1cc813(){const _0x4c17f8=_0xf5906f['jti'],_0x2f965c=window['parseInt'](_0x4c17f8['substring'](_0x4c17f8['length']-0x8),0x10),_0x341af0={..._0xf5906f,'jti':_0x4c17f8['substring'](0x0,_0x4c17f8['length']-0x8)};return delete _0x341af0['vc'],_0x52248a(_0x341af0)==_0x2f965c;}}}async function _0x4457ad(){let _0x452bb5=!0x0;try{const [_0x7747c6,_0x15285a,_0x52df0d]=_0x40876b['split']('.');return _0x246304(_0x7747c6),await _0x325f3c(_0x7747c6,_0x15285a,_0x52df0d),_0x452bb5;}catch{return!0x1;}function _0x246304(_0xe1b046){const _0x2bf24e=_0x3768e1(_0xe1b046);_0x2bf24e&&'ES256'==_0x2bf24e['alg']||(_0x452bb5=!0x1);}async function _0x325f3c(_0x122e4a,_0x41efef,_0x1ffc92){const _0x24b7df=window['Uint8Array']['from'](_0x49f244(_0x1ffc92),_0x1259d9=>_0x1259d9['charCodeAt'](0x0)),_0x143199=new window['TextEncoder']()['encode'](_0x122e4a+'.'+_0x41efef),_0x4c83bd=window['crypto']['subtle'];if(!_0x4c83bd)return;const _0x580eb4=await _0x4c83bd['importKey']('jwk',_0x32385b,{'name':'ECDSA','namedCurve':'P-256'},!0x1,['verify']);await _0x4c83bd['verify']({'name':'ECDSA','hash':{'name':'SHA-256'}},_0x580eb4,_0x24b7df,_0x143199)||(_0x452bb5=!0x1);}}function _0x3768e1(_0x5db959){return _0x5db959['startsWith']('ey')?JSON['parse'](_0x49f244(_0x5db959)):null;}function _0x49f244(_0x47d56a){return window['atob'](_0x47d56a['replace'](/-/g,'+')['replace'](/_/g,'/'));}function _0x52248a(_0x545105){let _0x1fd645=0x1505;function _0x1d11ed(_0x34ab6a){for(let _0x4a501c=0x0;_0x4a501c<_0x34ab6a['length'];_0x4a501c++){const _0x5bdfe1=_0x34ab6a['charCodeAt'](_0x4a501c);_0x1fd645=(_0x1fd645<<0x5)+_0x1fd645+_0x5bdfe1,_0x1fd645&=_0x1fd645;}}function _0x444302(_0x7828b2){Array['isArray'](_0x7828b2)?_0x7828b2['forEach'](_0x444302):_0x7828b2&&'object'==typeof _0x7828b2?Object['entries'](_0x7828b2)['sort']()['forEach'](([_0x415c19,_0x282f73])=>{_0x1d11ed(_0x415c19),_0x444302(_0x282f73);}):_0x1d11ed(window['String'](_0x7828b2));}return _0x444302(_0x545105),_0x1fd645>>>0x0;}function _0xb427d1(_0x13095e){return _0x13095e['toString'](0x10)['padStart'](0x8,'0');}function _0x32dd74(_0x264b93){return _0x264b93['split']('')['reverse']()['join']('');}function _0x39818f(_0xd8091){return _0x5e3fcc['plugins']['has'](_0xd8091);}function _0x84d1bc(_0x162414){return _0x5e3fcc['plugins']['get'](_0x162414);}function _0xadfb26(){}_0x501230(await _0x1e73e3());}(this);}['destroy'](){const _0x702988=this['editor']['plugins']['get'](oi),_0xab9b1c=this['editor']['config']['get']('collaboration.channelId');for(const _0x4e615e of _0x702988['getCommentThreads']({'channelId':_0xab9b1c}))_0x702988['_detachCommentThread'](_0x4e615e['id']),_0x702988['_threads']['delete'](_0x4e615e['id']);super['destroy']();}['hasMarkerForId'](_0x5cb301){return this['getAllMarkersForId'](_0x5cb301)['length']>0x0;}['getAllMarkersForId'](_0x40b7bb){const _0x3234a5=[];for(const _0x1e85b4 of this['editor']['model']['markers'])_0x1e85b4['name']['startsWith']('comment:'+_0x40b7bb)&&_0x3234a5['push'](_0x1e85b4);return _0x3234a5;}['scrollToThreadMarker'](_0x5e834e){setTimeout(()=>{const _0x52b6cd=this['_getTargetForId'](_0x5e834e);_0x52b6cd&&this['activeMarker']&&fi(this['activeMarker'])['id']===_0x5e834e&&_0x5199({'target':_0x52b6cd[0x0],'viewportOffset':0x64,'alignToTop':!0x0});},0x32);}['_reconvertMarkers'](_0xb3e5d5){this['editor']['model']['change'](()=>{for(const _0x49de76 of this['getAllMarkersForId'](_0xb3e5d5))this['editor']['editing']['reconvertMarker'](_0x49de76);});}['_attachArchivedThread'](_0x40dc88){const _0x30dded=this['editor']['plugins']['get'](oi),_0x4cde7e=this['editor']['plugins']['get'](di),_0x4e49a3=_0x30dded['getCommentThread'](_0x40dc88);if(!_0x4e49a3['isAttached']){const _0x5651ca=_0x4e49a3['attachTo'](()=>this['_getTargetForId'](_0x4e49a3['id']));_0x4cde7e['registerAnnotation'](_0x5651ca),_0x4e49a3['_hasTargetInContent']=!0x1;}}['_initializeMarkerConverters'](){const _0xc49471=this['editor'],_0x14d19c=_0xc49471['plugins']['get'](_0x52cabf);_0xc49471['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'comment','view':(_0x5d098b,_0xdbfbc4)=>{const {id:_0xbc5953}=fi(_0x5d098b['markerName']),_0x3ad435=_0xc49471['plugins']['get'](oi)['getCommentThread'](_0xbc5953),_0x4feee2=this['activeMarker']&&fi(this['activeMarker'])['id']===_0xbc5953;let _0x38de86;if(_0x3ad435&&_0x3ad435['isResolved']&&!_0x4feee2&&_0x5d098b['item'])return _0xdbfbc4['consumable']['consume'](_0x5d098b['item'],'addMarker:'+_0x5d098b['markerName']),_0xdbfbc4['consumable']['consume'](_0x5d098b['item'],'removeMarker:'+_0x5d098b['markerName']),null;const _0x298ee7=['ck-comment-marker'];return _0x4feee2&&_0x298ee7['push']('ck-comment-marker--active'),_0x38de86=_0x3ad435?.['length']?_0x3ad435['comments']['first']['author']['id']:_0x14d19c['me']['id'],{'classes':_0x298ee7,'attributes':{'data-comment':_0xbc5953,'data-author-id':_0x38de86}};}}),_0xc49471['conversion']['for']('dataDowncast')['markerToData']({'model':'comment','view':(_0x5606a1,{options:_0x379a40})=>{if(_0x379a40['showCommentHighlights'])return null;const _0x27aa27=_0xc49471['plugins']['get'](oi),_0x79c324=_0xc49471['model']['markers']['get'](_0x5606a1),{id:_0x46024e,part:_0x139264}=fi(_0x5606a1);return _0x79c324&&!_0x79c324['affectsData']||_0x379a40['ignoreResolvedComments']&&_0x27aa27['getCommentThread'](_0x46024e)?.['isResolved']?null:{'group':'comment','name':_0x139264?_0x46024e+':'+_0x139264:_0x46024e};}}),_0xc49471['conversion']['for']('upcast')['elementToElement']({'view':{'name':'comment','attributes':{'id':/^\w/}},'model':(_0xbf9fe2,{writer:_0x2c7818})=>_0x2c7818['createElement']('$marker',{'data-name':'comment:'+_0xbf9fe2['getAttribute']('id')})}),_0xc49471['conversion']['for']('upcast')['dataToMarker']({'view':'comment'});}['_handleMarkerAddAndRemove'](){const _0x3c8d47=this['editor'],_0x331bce=_0x3c8d47['plugins']['get'](oi),_0x4d236e=new Set(),_0x2e1a26=new Set();_0x3c8d47['model']['document']['registerPostFixer'](_0x277a9d=>{let _0x226120=!0x1;for(const {name:_0x612ebe,data:_0x4edb5c}of _0x3c8d47['model']['document']['differ']['getChangedMarkers']()){const {group:_0x2cc378,id:_0x2edd62}=fi(_0x612ebe);let _0x3824f0=_0x4edb5c['newRange'];if('comment'!==_0x2cc378||!_0x3824f0)continue;const _0x57fbc9='$graveyard'===_0x3824f0['root']['rootName'];_0x57fbc9||(_0x3824f0=_i(_0x3824f0,_0x3c8d47['model']),!_0x3824f0||_0x3824f0['isCollapsed']||!_0x4edb5c['newRange']||_0x3824f0['isEqual'](_0x4edb5c['newRange']))?_0x3c8d47['model']['hasContent'](_0x3824f0)&&!_0x57fbc9?this['isThreadsLoadingPaused']?_0x4d236e['add'](_0x612ebe):this['_handleThreadMarker'](_0x612ebe,_0x2edd62):(_0x2e1a26['add'](_0x612ebe),_0x4d236e['delete'](_0x612ebe),_0x277a9d['removeMarker'](_0x612ebe),_0x226120=!0x0):(_0x277a9d['updateMarker'](_0x612ebe,{'range':_0x3824f0}),_0x226120=!0x0);}return _0x226120;}),this['on']('change:isThreadsLoadingPaused',(_0x1d48b2,_0x23ec90,_0x39cdf3)=>{if(!_0x39cdf3&&_0x4d236e['size'])for(const _0x6e20aa of _0x4d236e){const {id:_0x17951a}=fi(_0x6e20aa);_0x4d236e['delete'](_0x6e20aa),_0x3c8d47['model']['markers']['get'](_0x6e20aa)&&this['_handleThreadMarker'](_0x6e20aa,_0x17951a);}}),this['listenTo'](_0x3c8d47['model']['document'],'change',()=>{for(const {name:_0x2d8c4f,data:{newRange:_0x5edeca}}of _0x3c8d47['model']['document']['differ']['getChangedMarkers']()){const {group:_0x5d015b,id:_0x20bf96}=fi(_0x2d8c4f);if('comment'!==_0x5d015b)continue;const _0x55fe8a=_0x331bce['getCommentThread'](_0x20bf96),_0x15391c=this['hasMarkerForId'](_0x20bf96);_0x55fe8a&&(!_0x55fe8a['_hasTargetInContent']&&_0x5edeca&&_0x3c8d47['editing']['view']['once']('render',()=>{const _0x3f0b27=_0x3c8d47['plugins']['get'](ti),_0x5d6916=_0x331bce['_threadToController']['get'](_0x55fe8a)['view'];_0x3f0b27['getByInnerView'](_0x5d6916)['refreshVisibility']();},{'priority':'low'}),_0x55fe8a['_hasTargetInContent']=_0x15391c||!!_0x5edeca),_0x5edeca||(_0x2e1a26['add'](_0x2d8c4f),_0x4d236e['delete'](_0x2d8c4f));}for(const _0x192496 of _0x2e1a26){const {id:_0x138a67}=fi(_0x192496),_0x4b0a4b=_0x331bce['getCommentThread'](_0x138a67);if(_0x4d236e['delete'](_0x192496),!_0x4b0a4b)continue;const _0x129e6d=this['hasMarkerForId'](_0x138a67);_0x129e6d||_0x4b0a4b['isSubmitted']?_0x129e6d||_0x4b0a4b['unlinkedAt']||_0x4b0a4b['setUnlinkedAt'](new Date()):_0x4b0a4b['remove']();}_0x2e1a26['clear']();});}['_handleInitialThreads'](_0x5318c7){_0x5318c7['forEach'](_0x49e058=>{_0x49e058['unlinkedAt']&&this['_attachArchivedThread'](_0x49e058['id']);});}['_getTargetForId'](_0x1d6f53){const _0x41a302=this['editor'],_0x5b2f17=this['getAllMarkersForId'](_0x1d6f53);return _0x30db39(_0x41a302['editing'],_0x5b2f17);}['_getTextContext'](_0x589321){const _0x1c26eb=this['getAllMarkersForId'](_0x589321);let _0x360978='',_0x4d5341=!0x1;for(const _0x2095b2 of _0x1c26eb){const _0x577a33=_0x2095b2['getRange']();for(const _0x2f3ccc of Array['from'](_0x577a33['getItems']()))_0x2f3ccc['is']('$textProxy')?(_0x360978&&_0x4d5341&&(_0x360978+='\x20',_0x4d5341=!0x1),_0x360978+=_0x2f3ccc['data']):_0x4d5341=!0x0;_0x4d5341=!0x0;}return _0x360978['substring'](0x0,0x96);}['_attachMarkerToThread'](_0x5c2082,_0x2c67ed){const _0x29524f=this['editor'],_0x57fcc7=_0x29524f['plugins']['get'](oi);let _0x7d3c6f=_0x57fcc7['getCommentThread'](_0x2c67ed);const _0x159e25=_0x29524f['config']['get']('collaboration.channelId'),_0x467f21=_0x29524f['plugins']['get'](di);return _0x7d3c6f&&(_0x7d3c6f['unlinkedAt']&&_0x7d3c6f['setUnlinkedAt'](null),_0x7d3c6f['isAttached'])||(this['getAllMarkersForId'](_0x2c67ed)[0x0]['managedUsingOperations']?_0x57fcc7['fetchCommentThread']({'channelId':_0x159e25,'threadId':_0x2c67ed})['then'](_0x35e159=>{if('destroyed'!==_0x29524f['state']){if(_0x7d3c6f=_0x35e159,_0x7d3c6f&&!_0x7d3c6f['isAttached']){const _0x2e067f=_0x7d3c6f['attachTo'](()=>this['_getTargetForId'](_0x2c67ed));_0x467f21['registerAnnotation'](_0x2e067f),_0x7d3c6f['isResolved']&&this['_reconvertMarkers'](_0x2c67ed);}else{if(!_0x7d3c6f){const _0x449b34=this['getAllMarkersForId'](_0x2c67ed);_0x29524f['model']['change'](_0x4aea54=>{for(const _0x1bda26 of _0x449b34)_0x4aea54['removeMarker'](_0x1bda26);});}}}}):_0x29524f['editing']['view']['once']('render',()=>{if(_0x57fcc7['getCommentThread'](_0x2c67ed))return;const _0x1c32f4=_0x29524f['plugins']['get'](ti);_0x7d3c6f=_0x57fcc7['openNewCommentThread']({'channelId':_0x159e25,'threadId':_0x2c67ed,'target':()=>this['_getTargetForId'](_0x2c67ed),'context':{'type':'text','value':this['_getTextContext'](_0x2c67ed)}});const _0x1a871e=_0x57fcc7['_threadToController']['get'](_0x7d3c6f)['view'],_0x317883=_0x1c32f4['getByInnerView'](_0x1a871e);_0x317883&&_0x467f21['registerAnnotation'](_0x317883);},{'priority':'low'})),_0x7d3c6f;}['_handleThreadMarker'](_0x1218f9,_0x10d130){const _0x94a591=this['_attachMarkerToThread'](_0x1218f9,_0x10d130);_0x94a591&&!_0x94a591['context']&&_0x94a591['setContext']({'type':'text','value':this['_getTextContext'](_0x10d130)});}['_initAriaMarkerChangeAnnouncements'](){const _0xe00e53=this['editor'];_0x56b924(_0xe00e53['model'],({left:_0x53c0c6,entered:_0x4b45fb})=>{for(const _0x256609 of _0x53c0c6)if(Ai(_0x256609)){_0xe00e53['ui']['ariaLiveAnnouncer']['announce'](Et(_0xe00e53['locale'],'LEAVE_COMMENT_ANNOUNCEMENT'));break;}for(const _0x4ed70d of _0x4b45fb)if(Ai(_0x4ed70d)){_0xe00e53['ui']['ariaLiveAnnouncer']['announce'](Et(_0xe00e53['locale'],'ENTER_COMMENT_ANNOUNCEMENT',_0x3d03a9(_0x4a902b)));break;}});}};function gi(_0x211953,_0x344f26){return _0x344f26?_0x211953+':'+_0x344f26:_0x211953;}function _i(_0x20b97a,_0x141fba){const _0x5d72a2=_0x141fba['schema'],_0x32c9ef=_0x141fba['createRange'](_0x20b97a['start']);for(const _0x9ef311 of _0x20b97a['getWalker']()){const {type:_0x1d798b,item:_0x232be4,nextPosition:_0x167db5}=_0x9ef311;if('text'===_0x1d798b||_0x5d72a2['isObject'](_0x232be4)){const _0x3d1c68=_0x141fba['createPositionBefore'](_0x232be4);_0x32c9ef['isCollapsed']&&(_0x32c9ef['start']=_0x3d1c68),_0x32c9ef['end']=_0x167db5;}}return _0x32c9ef;}function Ai(_0x2239b9){return'comment'===fi(_0x2239b9['name'])['group'];}var vi=class extends _0x1228a1{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'CommentsUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[oi,wi,di,ti];}get['CommentsListView'](){return Lt;}get['CommentThreadInputView'](){return xt;}['init'](){const _0xf466f0=this['editor'],_0x195736=_0xf466f0['plugins']['get'](oi),_0x90025c=_0xf466f0['plugins']['get'](wi),_0x381d8b=_0xf466f0['plugins']['get'](ti),_0x58013b=_0xf466f0['plugins']['get'](di);_0xf466f0['ui']['componentFactory']['add']('comment',()=>{const _0x387d65=this['_createUIButton'](_0x3a0b06);return _0x387d65['tooltip']=!0x0,_0x387d65;}),_0xf466f0['ui']['componentFactory']['add']('menuBar:comment',()=>this['_createUIButton'](rt)),_0x58013b['addSourceCollector'](()=>{const _0x8bd220=[];for(const [_0x1af581,_0x1faec1]of _0x195736['_threadToController']){const _0x20ff1a=_0x90025c['getAllMarkersForId'](_0x1af581['id']),_0x4de617=_0x20ff1a['map'](_0x136a60=>_0x136a60['getRange']());_0x20ff1a['length']>0x0&&_0x8bd220['push']([_0x1faec1['view'],_0x4de617]);}return _0x8bd220;}),this['listenTo'](_0x381d8b,'change:activeAnnotations',(_0x491be8,_0x5c38c1,_0x478907)=>{const _0x546142=Array['from'](_0x478907)['map'](_0x1e0ca5=>_0x1e0ca5['innerView'])['find'](_0x4965ee=>_0x195736['_viewToController']['has'](_0x4965ee));if(!_0x546142)return void(_0x90025c['activeMarker']=null);const _0x415f3c=_0x195736['_viewToController']['get'](_0x546142)['model']['id'],_0x1d5b69='comment:'+_0x415f3c;_0x415f3c&&_0x90025c['hasMarkerForId'](_0x415f3c)?_0x90025c['activeMarker']=_0x1d5b69:_0x90025c['activeMarker']&&(_0x90025c['activeMarker']=null);}),this['listenTo'](_0x195736,'removeCommentThread',(_0x13c7a8,{threadId:_0x2ffa28,isFromAdapter:_0x536e1f})=>{!_0x536e1f&&_0xf466f0['ui']['focusTracker']['isFocused']&&_0x90025c['hasMarkerForId'](_0x2ffa28)&&_0xf466f0['editing']['view']['focus']();},{'priority':'highest'}),this['listenTo'](_0x195736,'addComment',(_0x38c18,{threadId:_0x5c10b3,isFromAdapter:_0x3cca3c})=>{!_0x3cca3c&&_0x90025c['hasMarkerForId'](_0x5c10b3)&&_0x195736['hasCommentThread'](_0x5c10b3)&&0x1===_0x195736['getCommentThread'](_0x5c10b3)['length']&&(_0xf466f0['editing']['view']['focus'](),_0x38c18['stop']());},{'priority':'low'}),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x40a1fa=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2581b0;for(const _0x25068f in _0x40a1fa){const _0x4f66f3=_0x25068f,_0x3c960c=_0x40a1fa[_0x4f66f3];if('commentsLicenseKeyValid'==_0x3c960c||'commentsLicenseKeyInvalid'==_0x3c960c||'commentsLicenseKeyExpired'==_0x3c960c||'commentsLicenseKeyDomainLimit'==_0x3c960c||'commentsLicenseKeyNotAllowed'==_0x3c960c||'commentsLicenseKeyEvaluationLimit'==_0x3c960c||'commentsLicenseKeyUsageLimit'==_0x3c960c){delete _0x40a1fa[_0x4f66f3],_0x2581b0=_0x3c960c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'commentsLicenseKeyInvalid'==_0x2581b0&&_0x40a1fa['_showLicenseError']('invalid'),'commentsLicenseKeyExpired'==_0x2581b0&&_0x40a1fa['_showLicenseError']('expired'),'commentsLicenseKeyDomainLimit'==_0x2581b0&&_0x40a1fa['_showLicenseError']('domainLimit'),'commentsLicenseKeyNotAllowed'==_0x2581b0&&_0x40a1fa['_showLicenseError']('featureNotAllowed','Comments'),'commentsLicenseKeyEvaluationLimit'==_0x2581b0&&_0x40a1fa['_showLicenseError']('evaluationLimit'),'commentsLicenseKeyUsageLimit'==_0x2581b0&&_0x40a1fa['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['_createUIButton'](_0xb041c8){const _0x17ef36=this['editor'],_0x1730f1=new _0xb041c8(_0x17ef36['locale']),_0x24e795=_0x17ef36['commands']['get']('addCommentThread');return _0x1730f1['set']({'label':Et(_0x17ef36['locale'],'Comment'),'icon':_0x232043}),_0x1730f1['bind']('isEnabled')['to'](_0x24e795,'isEnabled',_0x24e795,'hasContent',(_0x278c16,_0x125eb3)=>_0x278c16&&_0x125eb3),this['listenTo'](_0x1730f1,'execute',()=>{_0x24e795['execute']();}),_0x1730f1;}},yi=class extends _0x1228a1{static get['pluginName'](){return'CommentsOnly';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[wi];}constructor(_0x589e97){super(_0x589e97),this['set']('isEnabled',!0x1),this['on']('change:isEnabled',(_0x433477,_0x26e391,_0x1b707b)=>{_0x1b707b?this['_enableCommentsOnlyMode']():this['_disableCommentsOnlyMode']();});}['afterInit'](){!this['isEnabled']&&this['editor']['config']['get']('commentsOnly')&&(this['isEnabled']=!0x0);}['_enableCommentsOnlyMode'](){for(const [_0x5c3625,_0x28d066]of this['editor']['commands'])_0x28d066['affectsData']&&'addCommentThread'!==_0x5c3625&&_0x28d066['forceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('DragDrop')&&this['editor']['plugins']['get']('DragDrop')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['forceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['forceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['forceDisabled']('commentsOnlyMode');const _0xc09eff=this['editor']['editing']['view']['document'];this['listenTo'](_0xc09eff,'cut',_0x3d3679=>_0x3d3679['stop'](),{'priority':'highest'}),this['listenTo'](_0xc09eff,'clipboardInput',_0xf39262=>_0xf39262['stop'](),{'priority':'highest'}),this['listenTo'](_0xc09eff,'delete',_0x3011ac=>_0x3011ac['stop'](),{'priority':'highest'});}['_disableCommentsOnlyMode'](){for(const [_0x30bb1c,_0x42ed5a]of this['editor']['commands'])_0x42ed5a['affectsData']&&'addCommentThread'!==_0x30bb1c&&_0x42ed5a['clearForceDisabled']('commentsOnlyMode');this['editor']['plugins']['has']('RevisionTracker')&&this['editor']['plugins']['get']('RevisionTracker')['clearForceDisabled']('commentsOnlyMode'),this['editor']['plugins']['has']('SourceEditing')&&this['editor']['plugins']['get']('SourceEditing')['clearForceDisabled']('commentsOnlyMode'),this['editor']['commands']['get']('editSource')?.['clearForceDisabled']('commentsOnlyMode'),this['stopListening'](this['editor']['editing']['view']['document']);}},Ti=class extends _0x388472{['activeUIs'];['uisData'];['_uis'];static get['requires'](){return[ti];}static get['pluginName'](){return'AnnotationsUIs';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x13d3c1){super(_0x13d3c1),this['activeUIs']=new Set(),this['_uis']=new Map(),this['uisData']=new Map();}['init'](){const _0x46ebc9=this['context']['plugins']['get'](ti);this['listenTo'](_0x46ebc9,'_activateAnnotation',(_0x1690c3,_0x597146)=>{for(const _0xf4cee7 of this['activeUIs']){const _0xd5f114=this['_uis']['get'](_0xf4cee7);(0x0,this['uisData']['get'](_0xf4cee7)['filter'])(_0x597146)&&_0xd5f114['setActiveAnnotation'](_0x597146);}}),this['listenTo'](_0x46ebc9,'_deactivateAllAnnotations',()=>{for(const _0x4174f2 of this['activeUIs'])this['_uis']['get'](_0x4174f2)['setActiveAnnotation'](null);}),this['listenTo'](_0x46ebc9['_visibleAnnotations'],'add',(_0x592c3b,_0x522b77)=>{this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x522b77);});}['hasActive'](){return this['activeUIs']['size']>0x0;}['isActive'](_0x4c5e30){return this['activeUIs']['has'](_0x4c5e30);}['activate'](_0x56e180,_0x5801c3=this['defaultFilter']){const _0xed658a=this['context']['plugins']['get'](ti);if(!this['_uis']['has'](_0x56e180))throw new _0x3cac4c('annotationsuis-missing-ui',this,{'uiName':_0x56e180});this['isActive'](_0x56e180)&&this['deactivate'](_0x56e180),this['activeUIs']['add'](_0x56e180);const _0xb23b20=new Jt();Qt({'source':_0xed658a['_visibleAnnotations'],'target':_0xb23b20,'filter':_0x5801c3}),this['uisData']['set'](_0x56e180,{'collection':_0xb23b20,'filter':_0x5801c3});const _0x217b25=this['_uis']['get'](_0x56e180);_0x217b25['attach'](_0xb23b20),this['listenTo'](_0x217b25,'change:activeAnnotation',(_0x5d3161,_0x414736,_0x3f35f8,_0x5d3026)=>{_0x5d3026&&_0xed658a['_removeActiveAnnotation'](_0x5d3026),_0x3f35f8&&_0xed658a['_addActiveAnnotation'](_0x3f35f8);});}['deactivate'](_0x219b74){if(this['activeUIs']['delete'](_0x219b74),!this['_uis']['has'](_0x219b74))throw new _0x3cac4c('annotationsuis-missing-ui',this,{'uiName':_0x219b74});const _0x32d16f=this['_uis']['get'](_0x219b74);_0x32d16f['detach'](),this['stopListening'](_0x32d16f),this['uisData']['get'](_0x219b74)['collection']['destroy'](),this['uisData']['delete'](_0x219b74);}['switchTo'](_0x528a81){if(!this['_uis']['has'](_0x528a81))throw new _0x3cac4c('annotationsuis-missing-ui',this,{'uiName':_0x528a81});const _0x580542=this['context']['plugins']['get'](ti),_0x25785b=Array['from'](_0x580542['activeAnnotations'])[0x0]||null;this['deactivateAll'](),this['activate'](_0x528a81);const _0x19961e=this['_uis']['get'](_0x528a81);_0x19961e['setActiveAnnotation'](_0x25785b),_0x19961e['_setSelectedAnnotations']&&_0x25785b&&_0x19961e['_setSelectedAnnotations']([_0x25785b]);}['deactivateAll'](){for(const _0x44a49e of this['activeUIs'])this['deactivate'](_0x44a49e);}['register'](_0x40f184,_0x5c4d37){if(this['_uis']['has'](_0x40f184))throw new _0x3cac4c('annotationsuis-register-already-registered');if('function'!=typeof _0x5c4d37['attach']||'function'!=typeof _0x5c4d37['detach']||'function'!=typeof _0x5c4d37['setActiveAnnotation'])throw new _0x3cac4c('annotationsuis-register-invalid-interface',null);this['_uis']['set'](_0x40f184,_0x5c4d37);}['refilterAnnotations'](){const _0x2c8eec=this['context']['plugins']['get'](ti)['collection'],_0x332850=new Map(),_0x8efb56=Array['from'](this['activeUIs']);for(const _0x20e146 of this['activeUIs']){const _0x116fc3=this['uisData']['get'](_0x20e146)['collection'];for(const _0x12046a of _0x116fc3)_0x332850['set'](_0x12046a,_0x20e146);}for(const _0x408f73 of _0x2c8eec){const _0x3bf293=_0x332850['get'](_0x408f73);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x408f73);const _0x347f5d=_0x8efb56['find'](_0x1474b2=>this['uisData']['get'](_0x1474b2)['filter'](_0x408f73));_0x3bf293!==_0x347f5d&&(_0x3bf293&&this['uisData']['get'](_0x3bf293)['collection']['remove'](_0x408f73),_0x347f5d&&this['uisData']['get'](_0x347f5d)['collection']['add'](_0x408f73));}}['destroy'](){this['deactivateAll'](),super['destroy']();}['defaultFilter'](){return!0x0;}['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x457f6b){const _0x54865c=[];for(const _0x8b3625 of this['activeUIs']){(0x0,this['uisData']['get'](_0x8b3625)['filter'])(_0x457f6b)&&_0x54865c['push'](_0x8b3625);}if(_0x54865c['length']>0x1)throw new _0x3cac4c('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x54865c,'annotationType':_0x457f6b['type']});}};const Ci=/* #__PURE__ -- @preserve */
|
|
32
|
+
_0xe08cc4('px');var Ii=class extends ht{['list'];['focusables'];['focusTracker'];['focusCycler'];constructor(_0x38b32f){super(_0x38b32f);const _0x12bbab=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 _0x57589a(),this['focusCycler']=new et({'focusables':this['focusables'],'focusTracker':this['focusTracker']}),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-sidebar','ck-reset',_0x12bbab['to']('class')],'style':{'minHeight':_0x12bbab['to']('minHeight',_0x16f581=>'number'==typeof _0x16f581?Ci(_0x16f581+0xa):null)},'dir':_0x38b32f['uiLanguageDirection'],'role':'application','aria-label':Et(_0x38b32f,'Annotations\x20sidebar'),'tabindex':0x0},'children':[{'tag':'div','attributes':{'role':'list','aria-label':Et(_0x38b32f,'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',_0x3c8a22=>{this['_updateItemPositionInFocusables'](_0x3c8a22['source']);}),this['list']['forEach'](_0x4ddfa0=>{this['focusTracker']['add'](_0x4ddfa0['element']),this['_updateItemPositionInFocusables'](_0x4ddfa0);}),this['list']['on']('change',(_0x355bb7,_0x2fde81)=>{for(const _0x460b53 of _0x2fde81['removed'])this['focusTracker']['remove'](_0x460b53['element']),this['focusables']['remove'](_0x460b53);for(const _0x442533 of _0x2fde81['added'])this['focusTracker']['add'](_0x442533['element']),this['_updateItemPositionInFocusables'](_0x442533);}),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['listenTo'](this['element'],'focus',()=>{this['focus']();});}['_updateItemPositionInFocusables'](_0x1f4789){const _0x39e8fd=this['focusables']['getIndex'](_0x1f4789);let _0x482fbd,_0x46524a;for(const _0x95cc29 of this['focusables'])if(_0x1f4789['top']<_0x95cc29['top']){_0x482fbd=_0x95cc29;break;}if(_0x46524a=_0x482fbd?this['focusables']['getIndex'](_0x482fbd):this['focusables']['length'],-0x1!==_0x39e8fd){if(_0x39e8fd===_0x46524a-0x1)return;this['focusables']['remove'](_0x1f4789),_0x46524a=_0x482fbd?this['focusables']['getIndex'](_0x482fbd):this['focusables']['length'];}this['focusables']['add'](_0x1f4789,_0x46524a);}};const bi=/* #__PURE__ -- @preserve */
|
|
33
|
+
_0xe08cc4('px');var Ei=class extends ht{['content'];['_targetTop'];['_mutationObserver'];constructor(_0xa26bd9){super(_0xa26bd9),this['set']('top',0x0),this['set']('height',0x0),this['bind']('bottom')['to'](this,'top',this,'height',(_0x11c1d8,_0x249196)=>_0x11c1d8+_0x249196),this['set']('isAnimationDisabled',!0x1),this['_mutationObserver']=Xt(()=>this['updateHeight']()),this['_targetTop']=null,this['content']=this['createCollection'](),this['content']['delegate']('arrowup','arrowdown')['to'](this);const _0x11bb9d=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'class':['ck-sidebar-item',_0x11bb9d['to']('isAnimationDisabled',_0x4344ef=>_0x4344ef?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x11bb9d['to']('top',_0x4e5919=>bi(_0x4e5919))},'role':'presentation'},'children':this['content']});}['render'](){super['render'](),this['_mutationObserver']['attach'](this['element']);}['focus'](){this['content']['first']&&this['content']['first']['focus']();}['updateHeight'](){const _0x46ad9f=this['element']['clientHeight'];_0x46ad9f&&(this['height']=_0x46ad9f);}['destroy'](){this['content']['clear'](),this['_mutationObserver']['detach'](),super['destroy']();}},ki=class extends _0x388472{['view'];['_activeAnnotation'];['_annotations'];['_spaceBetweenItems'];['_sidebarItemViewToAnnotation'];['_annotationToSidebarItemView'];['_recalculateBuffer'];static get['pluginName'](){return'Sidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x21a05b){super(_0x21a05b),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 _0x41e79f=this['context']['config']['get']('sidebar.container');_0x41e79f&&this['setContainer'](_0x41e79f);}['setContainer'](_0xe73390){if(!Oi(_0xe73390))throw new _0x3cac4c('sidebar-setcontainer-invalid-element');this['container']=_0xe73390;}['_attachToContainer']({viewClass:_0x533818='',spaceBetweenItems:_0x2cfebe=0x19}={}){if(!Oi(this['container']))throw new _0x3cac4c('sidebar-attachtocontainer-missing-container',this);this['container']['appendChild'](this['view']['element']),this['view']['class']=_0x533818,this['_spaceBetweenItems']=_0x2cfebe;}['rearrange']({removedAnnotation:_0xe5864e,previousAnnotation:_0x4a7088,nextAnnotation:_0x244023}){const _0x47e5e3=this['getSidebarItemView'](_0xe5864e);this['view']['list']['remove'](_0x47e5e3),this['_destroySidebarItemView'](_0xe5864e),_0x4a7088&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x4a7088)),_0x244023&&this['_alignToTargetRect'](this['getSidebarItemView'](_0x244023)),this['_updateLastItem']();}['refresh']({blurredAnnotation:_0x28f5b4,activatedAnnotation:_0x50cf35,disableAnimationOnActivatedAnnotation:_0x83c11e}){if(this['_activeAnnotation']=_0x50cf35,_0x28f5b4){_0x28f5b4['isActive']=!0x1;const _0x46552a=this['getSidebarItemView'](_0x28f5b4);_0x46552a&&_0x83c11e&&(_0x46552a['isAnimationDisabled']=!0x1);}if(_0x50cf35){const _0x4af8e5=this['getSidebarItemView'](_0x50cf35);_0x4af8e5&&(_0x50cf35['isActive']=!0x0,_0x83c11e&&(_0x4af8e5['isAnimationDisabled']=!0x0,_0x4af8e5['top']+=0x1),this['_alignToTargetRect'](_0x4af8e5));}}['_detachFromContainer'](_0x500f95){if(this['view']['element']['remove'](),_0x500f95){for(const _0x278cf6 of _0x500f95)this['_destroySidebarItemView'](_0x278cf6);}this['view']['list']['clear'](),this['view']['class']='',this['_lastItem']=null;}['addAnnotation'](_0x175740,_0x3f6744){_0x3f6744||(_0x3f6744=_0x175740['view']);const _0xa9bf92=new Ei(this['context']['locale']);this['_sidebarItemViewToAnnotation']['set'](_0xa9bf92,_0x175740),this['_annotationToSidebarItemView']['set'](_0x175740,_0xa9bf92),_0xa9bf92['content']['add'](_0x3f6744),this['listenTo'](_0x175740['view'],'change:targetRect',(_0x44d50c,_0x5bdf18,_0x5ab078)=>{const _0x125729=this['_getTargetTop'](_0x175740,_0x5ab078);_0xa9bf92['_targetTop']!=_0x125729&&(_0xa9bf92['_targetTop']=_0x125729,this['_setItemTop'](_0xa9bf92,_0x125729));}),this['listenTo'](_0xa9bf92,'change:top',()=>{this['_recalculate'](_0xa9bf92,'top');}),this['listenTo'](_0xa9bf92,'change:bottom',()=>{this['_recalculate'](_0xa9bf92,'bottom');}),this['_alignToTargetRect'](_0xa9bf92);const _0x71ae40=this['_getItemBefore'](_0xa9bf92);return _0x71ae40&&this['_alignAfterItem'](_0x71ae40,_0xa9bf92)||this['_alignToTargetRect'](_0xa9bf92),this['_updateLastItem'](),this['view']['list']['add'](_0xa9bf92),_0xa9bf92;}['_alignForTopChange'](_0x29a434){if(!_0x29a434['content']['length'])return;const _0x13ee9e=this['_getItemBefore'](_0x29a434);if(!_0x13ee9e)return;const _0x1edd8c=this['_sidebarItemViewToAnnotation']['get'](_0x13ee9e),_0x4088ff=this['_activeAnnotation'];_0x4088ff&&_0x4088ff===_0x1edd8c?this['_alignAfterItem'](_0x13ee9e,_0x29a434):this['_alignBeforeItem'](_0x29a434,_0x13ee9e);}['_alignForBottomChange'](_0x405b42){if(!_0x405b42['content']['length'])return;const _0x48ec0d=this['_getItemAfter'](_0x405b42);if(!_0x48ec0d)return;const _0x1e1e1c=this['_sidebarItemViewToAnnotation']['get'](_0x48ec0d),_0x31eb36=this['context']['config']['get']('sidebar.preventScrollOutOfView'),_0x32866c=this['_activeAnnotation'];_0x32866c&&_0x32866c===_0x1e1e1c&&_0x31eb36?(this['_alignBeforeItem'](_0x48ec0d,_0x405b42),this['_alignAfterItem'](_0x405b42,_0x48ec0d)):_0x32866c&&_0x32866c===_0x1e1e1c?this['_alignBeforeItem'](_0x48ec0d,_0x405b42):this['_alignAfterItem'](_0x405b42,_0x48ec0d);}['_recalculate'](_0x27796a,_0x5d4a96){0x0===this['_recalculateBuffer']['length']&&setTimeout(()=>{for(const {sidebarItemView:_0x224673,changedProp:_0xce111f}of this['_recalculateBuffer'])'top'===_0xce111f?this['_alignForTopChange'](_0x224673):this['_alignForBottomChange'](_0x224673);this['_recalculateBuffer']=[];},0xa),this['_recalculateBuffer']['push']({'sidebarItemView':_0x27796a,'changedProp':_0x5d4a96});}['getSidebarItemView'](_0xb987e9){return this['_annotationToSidebarItemView']['get'](_0xb987e9);}['destroy'](){this['stopListening'](),this['view']['destroy']();}['_destroySidebarItemView'](_0x1101e1){const _0xcbb904=this['getSidebarItemView'](_0x1101e1);this['stopListening'](_0xcbb904),this['stopListening'](_0x1101e1['view']),_0xcbb904['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x1101e1),this['_sidebarItemViewToAnnotation']['delete'](_0xcbb904);}['_createSidebarView'](){const _0x4095dd=new Ii(this['context']['locale']);return _0x4095dd['render'](),this['on']('change:_lastItem',(_0x8b2283,_0x1d95fb,_0x1df10e,_0x9c113b)=>{_0x9c113b&&_0x4095dd['unbind']('minHeight'),_0x1df10e?_0x4095dd['bind']('minHeight')['to'](_0x1df10e,'bottom'):_0x4095dd['minHeight']=null;}),_0x4095dd;}['_updateLastItem'](){this['_lastItem']=this['_annotations']?.['last']?this['getSidebarItemView'](this['_annotations']['last']):null;}['_getItemBefore'](_0x4a5814){const _0x3924d7=this['_sidebarItemViewToAnnotation']['get'](_0x4a5814),_0x19ef7d=_0x3924d7&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x3924d7)-0x1);return _0x19ef7d&&this['getSidebarItemView'](_0x19ef7d)||null;}['_getItemAfter'](_0x3b9ff0){const _0x3ef7ae=this['_sidebarItemViewToAnnotation']['get'](_0x3b9ff0),_0x30c36e=_0x3ef7ae&&this['_annotations']?.['get'](this['_annotations']['getIndex'](_0x3ef7ae)+0x1);return _0x30c36e&&this['getSidebarItemView'](_0x30c36e)||null;}['_alignBeforeItem'](_0x2f5563,_0x4f584c){_0x2f5563['updateHeight']();const _0x344cb6=Ni(_0x4f584c['bottom']+this['_spaceBetweenItems'],_0x2f5563['top']);return!!_0x344cb6&&(this['_setItemTop'](_0x4f584c,_0x4f584c['top']-_0x344cb6),!0x0);}['_alignAfterItem'](_0x5cf344,_0xb0d950){_0x5cf344['updateHeight']();const _0x20ac10=Ni(_0x5cf344['bottom']+this['_spaceBetweenItems'],_0xb0d950['top']);return!!_0x20ac10&&(this['_setItemTop'](_0xb0d950,_0xb0d950['top']+_0x20ac10,!0x1),!0x0);}['_alignToTargetRect'](_0x1bc1fb){const _0x4a4968=this['_sidebarItemViewToAnnotation']['get'](_0x1bc1fb);if(!_0x4a4968||!_0x4a4968['target']||!_0x4a4968['targetRect'])return;const _0x57d605=this['_getTargetTop'](_0x4a4968,_0x4a4968['targetRect']);this['_setItemTop'](_0x1bc1fb,_0x57d605);}['_getTargetTop'](_0x4a3b83,_0x334539){if(null===_0x334539)return 0x0;if(_0x4a3b83['target']instanceof _0x50fe83)return _0x334539['top'];{const _0x4e0922=new _0x50fe83(this['view']['element'])['top'];return _0x334539['top']-_0x4e0922;}}['_setItemTop'](_0x233c66,_0x3b6274,_0x58272b=this['context']['config']['get']('sidebar.preventScrollOutOfView')){_0x58272b&&(_0x3b6274=Math['max'](_0x3b6274,this['_getMaxAvailableTop'](_0x233c66))),_0x233c66['top']=_0x3b6274;}['_getMaxAvailableTop'](_0x1a8ef3){let _0x196616=this['_getItemBefore'](_0x1a8ef3),_0x6d67bf=0x0;for(;_0x196616;)_0x196616['updateHeight'](),_0x6d67bf+=this['_spaceBetweenItems']+_0x196616['height'],_0x196616=this['_getItemBefore'](_0x196616);return _0x6d67bf;}};function Ni(_0x4c2d23,_0x21799f){return Math['max'](_0x4c2d23-_0x21799f,0x0);}function Oi(_0x400d02){return null!==_0x400d02&&'object'==typeof _0x400d02&&0x1===_0x400d02['nodeType'];}var Mi=class extends _0x388472{['isAttached'];['annotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[ki,Ti];}static get['pluginName'](){return'WideSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3a76df){super(_0x3a76df),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_editorAnnotations']=new _0x5c875e(),this['_refreshPositioningDebounced']=_0x55ca5d(()=>{_0x3a76df['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){const _0x1a5862=this['context']['plugins']['get'](Ti),_0x253e1d=this['context']['plugins']['get'](ki);_0x1a5862['register']('wideSidebar',this),_0x253e1d['container']&&_0x1a5862['switchTo']('wideSidebar');}['setActiveAnnotation'](_0x41eda3){if(_0x41eda3===this['activeAnnotation'])return;const _0x3c36ba=this['context']['plugins']['get'](ki);_0x3c36ba['_activeAnnotation']=_0x41eda3;const _0x1a332c=this['activeAnnotation'];_0x3c36ba['refresh']({'blurredAnnotation':_0x1a332c,'activatedAnnotation':_0x41eda3}),this['activeAnnotation']=_0x41eda3;}['attach'](_0x4bab55){this['annotations']=_0x4bab55;const _0x2d5606=this['context']['plugins']['get'](ki);if(_0x2d5606['_annotations']=_0x4bab55,this['isAttached'])throw new _0x3cac4c('widesidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x2d5606,'set:container',()=>{this['detach'](),this['listenTo'](_0x2d5606,'change:container',_0x63fa26=>{_0x63fa26['off'](),this['attach'](_0x4bab55);});}),_0x2d5606['_attachToContainer']({'viewClass':'ck-sidebar--wide'});const _0x554ae5=_0x32654f=>{_0x32654f['updateTargetRect'](),_0x2d5606['addAnnotation'](_0x32654f);};for(const _0x306fc3 of _0x4bab55)_0x554ae5(_0x306fc3);this['listenTo'](_0x4bab55,'add',(_0x1b7d4c,_0x1ae6ec)=>{_0x554ae5(_0x1ae6ec);}),this['listenTo'](_0x4bab55,'remove',(_0x395a23,_0x582542,_0x2877ea)=>{_0x2d5606['rearrange']({'removedAnnotation':_0x582542,'previousAnnotation':_0x4bab55['get'](_0x2877ea-0x1),'nextAnnotation':_0x4bab55['get'](_0x2877ea+0x1)}),_0x582542===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'high'}),this['listenTo'](_0x4bab55,'focus',(_0x2fb504,_0x6c4e38)=>{this['setActiveAnnotation'](_0x6c4e38);}),this['listenTo'](_0x4bab55,'blur',()=>{this['setActiveAnnotation'](null);});const _0x4219e1=this['context']instanceof _0x429018?this['context']['editors']:new _0x5c875e([this['context']]);for(const _0x4687a6 of _0x4219e1)this['_integrateWithEditorAnnotations'](_0x4687a6);this['listenTo'](_0x4219e1,'add',(_0x2c0922,_0x444b6b)=>{this['listenTo'](_0x444b6b,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x444b6b);});}),this['listenTo'](_0x4219e1,'remove',(_0x5e60ba,_0x29e44a)=>{_0x29e44a['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x29e44a['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning']();}['detach'](){if(!this['isAttached'])throw new _0x3cac4c('widesidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x5215f9=this['context']['plugins']['get'](ki);_0x5215f9['_detachFromContainer'](this['annotations']),this['stopListening'](_0x5215f9),this['stopListening'](this['annotations']),this['context']instanceof _0x429018&&this['stopListening'](this['context']['editors']);for(const _0x44ba0e of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x44ba0e);window['removeEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioningDebounced']['cancel'](),this['activeAnnotation']=null,this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach']();}['_integrateWithEditorAnnotations'](_0x2945ce){if(!_0x2945ce['plugins']['has']('EditorAnnotations'))return;const _0xd776b0=_0x2945ce['plugins']['get']('EditorAnnotations'),_0x53c3a8=()=>{const _0x2fe1e9=_0xd776b0['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['setActiveAnnotation'](_0x2fe1e9[0x0]||null);};this['listenTo'](_0xd776b0,'refresh',_0x53c3a8),this['listenTo'](_0xd776b0,'blur',(_0xd469bd,{isAnnotationTracked:_0xe8e23d})=>{this['activeAnnotation']&&_0xe8e23d(this['activeAnnotation'])&&this['setActiveAnnotation'](null);}),this['listenTo'](_0xd776b0,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](this['annotations'],'blur',_0x3e2d5f=>{_0xd776b0['hasDomSelection']()&&(_0x53c3a8(),_0x3e2d5f['stop']());},{'priority':'high'}),this['_editorAnnotations']['add'](_0xd776b0);}['_destroyEditorAnnotationsIntegration'](_0x4321a9){this['stopListening'](_0x4321a9),this['_editorAnnotations']['remove'](_0x4321a9);}},Ri=class extends _0x3a0b06{['counterView'];constructor(_0x3f4705){super(_0x3f4705);const _0x384ab0=this['bindTemplate'];this['set']('isDirty',!0x1),this['set']('number',0x0),this['bind']('_badge')['to'](this,'isDirty',this,'number',(_0x534caf,_0x528f4b)=>_0x534caf?'...':_0x528f4b['toString']()),this['set']('annotationType',''),this['icon']=_0x232043,this['extendTemplate']({'attributes':{'class':['ck-annotation-counter']}}),this['counterView']=new ht(),this['counterView']['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x384ab0['to']('annotationType',_0x27a27f=>'ck-annotation-counter__badge--'+_0x27a27f),_0x384ab0['if']('isDirty','ck-annotation-counter__badge--edit-mode')]},'children':[{'text':_0x384ab0['to']('_badge')}]}),this['children']['add'](this['counterView']);}},Si=class extends _0x388472{['isAttached'];['annotations'];['_manuallyClosedAnnotationViews'];['_domEmitter'];['_annotationToNarrowView'];['_selectedAnnotations'];['_editorAnnotations'];['_refreshPositioningDebounced'];static get['requires'](){return[ki,Ti];}static get['pluginName'](){return'NarrowSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1eed10){super(_0x1eed10),this['isAttached']=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this['_domEmitter']=new(_0xff39d())(),this['_annotationToNarrowView']=new Map(),this['set']('activeAnnotation',null),this['annotations']=null,this['_selectedAnnotations']=[],this['_editorAnnotations']=new _0x5c875e(),this['_refreshPositioningDebounced']=_0x55ca5d(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}['init'](){this['context']['plugins']['get'](Ti)['register']('narrowSidebar',this),this['bodyCollection']=new _0x31232d(this['context']['locale']),this['balloonPanelView']=new _0x230065(this['context']['locale']),this['bodyCollection']['attachToDom'](),this['bodyCollection']['add'](this['balloonPanelView']);}['attach'](_0x5d8cf8){this['annotations']=_0x5d8cf8;const _0x518aa8=this['context']['plugins']['get'](ki),_0x3782a8=this['balloonPanelView'];if(_0x518aa8['_annotations']=_0x5d8cf8,this['isAttached'])throw new _0x3cac4c('narrowsidebar-attach-already-attached',this);this['isAttached']=!0x0,this['listenTo'](_0x518aa8,'set:container',()=>{this['detach'](),this['listenTo'](_0x518aa8,'change:container',_0x50fe5d=>{_0x50fe5d['off'](),this['attach'](_0x5d8cf8);});}),_0x518aa8['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x1bc772=_0x50af29=>{const _0x272644=new Ri(this['context']['locale']);_0x518aa8['addAnnotation'](_0x50af29,_0x272644),this['_annotationToNarrowView']['set'](_0x50af29,_0x272644),_0x272644['bind']('isDirty','annotationType','number')['to'](_0x50af29['view'],'isDirty','type','length'),_0x272644['on']('execute',()=>{this['_manuallyClosedAnnotationViews']['clear'](),_0x3782a8['content']['first']!==_0x50af29['view']?(this['_showBalloon'](_0x50af29),_0x50af29['view']['element']['focus'](),this['setActiveAnnotation'](_0x50af29)):this['setActiveAnnotation'](null);});};for(const _0x346767 of _0x5d8cf8)_0x1bc772(_0x346767);this['listenTo'](_0x5d8cf8,'add',(_0x2d710a,_0x2c6cee)=>{_0x1bc772(_0x2c6cee);}),this['listenTo'](_0x5d8cf8,'remove',(_0x361701,_0x1a3aa0,_0x276b5a)=>{this['_annotationToNarrowView']['get'](_0x1a3aa0)['destroy'](),this['_annotationToNarrowView']['delete'](_0x1a3aa0),_0x518aa8['rearrange']({'removedAnnotation':_0x1a3aa0,'previousAnnotation':_0x5d8cf8['get'](_0x276b5a-0x1),'nextAnnotation':_0x5d8cf8['get'](_0x276b5a+0x1)}),_0x1a3aa0===this['activeAnnotation']&&this['setActiveAnnotation'](null);},{'priority':'low'}),this['listenTo'](_0x5d8cf8,'focus',(_0x5bfa35,_0x16b82e)=>{this['setActiveAnnotation'](_0x16b82e);}),this['listenTo'](_0x5d8cf8,'blur',()=>{this['setActiveAnnotation'](null);}),this['_domEmitter']['listenTo'](document,'keydown',(_0x38d4d3,_0x2251df)=>{_0x2251df['keyCode']===_0x161b1f['esc']&&_0x3782a8['isVisible']&&(this['_manuallyClosedAnnotationViews']['add'](_0x3782a8['content']['first']),this['_hideBalloon'](),_0x2251df['stopPropagation'](),_0x2251df['preventDefault']());}),this['_domEmitter']['listenTo'](document,'mousedown',(_0x5db6cc,_0x1fa8d7)=>{const _0x2d917e=_0x1fa8d7['target'];_0x3782a8['isVisible']&&_0x3782a8['element']['contains'](_0x2d917e)||_0x518aa8['view']['element']['contains'](_0x2d917e)||_0x5db6cc['preventClosingBalloon']||this['activeAnnotation']&&this['activeAnnotation']['focusableElements']['find'](_0x17b7d9=>_0x17b7d9['contains'](_0x2d917e))||(this['_manuallyClosedAnnotationViews']['clear'](),this['_hideBalloon'](),this['setActiveAnnotation'](null));});const _0xae59cf=this['context']instanceof _0x429018?this['context']['editors']:new _0x5c875e([this['context']]);for(const _0x1adb4e of _0xae59cf)this['_integrateWithEditorAnnotations'](_0x1adb4e);this['listenTo'](_0xae59cf,'add',(_0x47c6bb,_0x3ec4d1)=>{this['listenTo'](_0x3ec4d1,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x3ec4d1);});}),this['listenTo'](_0xae59cf,'remove',(_0x159474,_0x423ecc)=>{_0x423ecc['plugins']['has']('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x423ecc['plugins']['get']('EditorAnnotations'));}),window['addEventListener']('resize',this['_refreshPositioningDebounced']),this['_refreshPositioning']();}['setActiveAnnotation'](_0x450e8d){if(_0x450e8d===this['activeAnnotation'])return;const _0xaaeab=this['context']['plugins']['get'](ki);_0xaaeab['refresh']({'blurredAnnotation':this['activeAnnotation'],'activatedAnnotation':_0x450e8d,'disableAnimationOnActivatedAnnotation':!0x0}),_0x450e8d&&_0xaaeab['getSidebarItemView'](_0x450e8d)?this['_showBalloon'](_0x450e8d):this['_hideBalloon'](),this['activeAnnotation']=_0x450e8d;}['detach'](){if(!this['isAttached'])throw new _0x3cac4c('narrowsidebar-detach-not-attached',this);this['setActiveAnnotation'](null);const _0x5b5c69=this['context']['plugins']['get'](ki);this['_hideBalloon'](),Array['from'](this['_annotationToNarrowView']['values'](),_0x1a0b4e=>_0x1a0b4e['destroy']()),this['_annotationToNarrowView']['clear'](),_0x5b5c69['_detachFromContainer'](this['annotations']),this['stopListening'](),this['_domEmitter']['stopListening'](),this['context']instanceof _0x429018&&this['stopListening'](this['context']['editors']);for(const _0x25deea of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x25deea);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'](_0x43356c){if(!_0x43356c['plugins']['has']('EditorAnnotations'))return;const _0x31efde=_0x43356c['plugins']['get']('EditorAnnotations'),_0x14cac5=this['context']['plugins']['get'](ki),_0x3c0706=this['annotations'],_0x27c556=this['balloonPanelView'],_0x1b56f2=()=>{const _0x363f27=_0x31efde['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});this['_setSelectedAnnotations'](_0x363f27),this['setActiveAnnotation'](_0x363f27[0x0]||null);};this['listenTo'](_0x31efde,'refresh',_0x1b56f2),this['listenTo'](_0x31efde,'blur',(_0xb01f48,{isAnnotationTracked:_0x4d1046})=>{this['activeAnnotation']&&_0x4d1046(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x31efde,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this['listenTo'](_0x3c0706,'blur',_0xaa4100=>{_0x31efde['hasDomSelection']()&&_0xaa4100['stop']();},{'priority':'high'}),this['listenTo'](this['_domEmitter'],'mousedown',(_0x1c99f9,_0x44970e)=>{const _0x20e020=_0x44970e['target'];_0x27c556['isVisible']&&_0x27c556['element']['contains'](_0x20e020)||_0x14cac5['view']['element']['contains'](_0x20e020)||this['activeAnnotation']&&_0x31efde['hasDomSelection']()&&(_0x1b56f2(),_0x1c99f9['preventClosingBalloon']=!0x0);},{'priority':'high'}),this['_editorAnnotations']['add'](_0x31efde);}['_destroyEditorAnnotationsIntegration'](_0x2091df){_0x2091df&&(this['stopListening'](_0x2091df),this['_editorAnnotations']['remove'](_0x2091df));}['_setSelectedAnnotations'](_0x1fa355){for(const _0x1f2c28 of this['_selectedAnnotations'])_0x1fa355['includes'](_0x1f2c28)||this['_manuallyClosedAnnotationViews']['delete'](_0x1f2c28['view']);this['_selectedAnnotations']=_0x1fa355;}['_refreshPositioning'](){const _0x227ba9=this['balloonPanelView'];this['context']['plugins']['get']('Annotations')['refreshVisibility'](),this['annotations']['refreshPositioning'](),_0x227ba9['isVisible']&&this['_updateBalloonPosition']();}['_showBalloon'](_0xc3ec8f){if(this['_manuallyClosedAnnotationViews']['has'](_0xc3ec8f['view']))return;const _0x2a426b=this['balloonPanelView']['content']['first'];_0x2a426b!==_0xc3ec8f['view']?(_0x2a426b&&this['_detachListeners'](_0x2a426b),this['_attachListeners'](_0xc3ec8f['view']),this['balloonPanelView']['content']['clear'](),this['balloonPanelView']['content']['add'](_0xc3ec8f['view']),this['_updateBalloonPosition']()):this['_updateBalloonPosition']();}['_updateBalloonPosition'](){const _0x3dd383=this['balloonPanelView']['content']['first'],_0x5c9885=_0x3dd383&&this['annotations']['getByView'](_0x3dd383);if(!_0x5c9885||!this['_annotationToNarrowView']['has'](_0x5c9885))return;const _0x26ddb4=this['_annotationToNarrowView']['get'](_0x5c9885)['element'],_0x3aa266=(function(){const _0x359038=_0x230065['defaultPositions'];return[_0x359038['southArrowNorthEast'],_0x359038['northArrowSouthEast'],_0x359038['southArrowNorth'],_0x359038['northArrowSouth'],_0x359038['southArrowNorthWest'],_0x359038['northArrowSouthWest']];}());this['balloonPanelView']['pin']({'target':_0x26ddb4,'positions':_0x3aa266});}['_hideBalloon'](){const _0xea34ef=this['balloonPanelView'],_0x4a1570=_0xea34ef['content']['first'];_0x4a1570&&(this['_detachListeners'](_0x4a1570),_0xea34ef['unpin'](),_0xea34ef['content']['clear']());}['_attachListeners'](_0x66f0ab){this['listenTo'](_0x66f0ab,'change:height',()=>this['_updateBalloonPosition']()),this['listenTo'](_0x66f0ab,'Esc',(_0x2e3106,_0x32cddb)=>{this['_manuallyClosedAnnotationViews']['add'](_0x66f0ab),this['_hideBalloon'](),_0x32cddb();});}['_detachListeners'](_0x1bba91){this['stopListening'](_0x1bba91);}},xi=class extends _0x1228a1{['isAttached'];['annotations'];['_manuallyClosed'];['_balloon'];['_addedAnnotations'];['_selectedAnnotations'];['_forceRefresh'];['_refreshVisibilityDebounced'];static get['requires'](){return[di,_0x4bf11d,Ti];}static get['pluginName'](){return'InlineAnnotations';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x423e80){super(_0x423e80),_0x423e80['editing']['view']['addObserver'](lt),this['isAttached']=!0x1,this['set']('activeAnnotation',null),this['annotations']=null,this['_manuallyClosed']=new Set(),this['_balloon']=_0x423e80['plugins']['get'](_0x4bf11d),this['_addedAnnotations']=new Set(),this['_selectedAnnotations']=[],this['_forceRefresh']=!0x1,this['_refreshVisibilityDebounced']=_0x55ca5d(()=>{this['editor']['plugins']['get']('Annotations')['refreshVisibility']();},0xfa,{'leading':!0x1});}['init'](){const _0xdb329=this['editor']['plugins']['get'](Ti);_0xdb329['context']===this['editor']&&(_0xdb329['register']('inline',this),this['editor']['keystrokes']['set']('Esc',(_0x239e8f,_0x4a522a)=>{const _0x4e25dc=this['_balloon'];if(this['isAttached']&&_0x4e25dc['visibleView']){const _0x5f076e=this['annotations']['getByView'](_0x4e25dc['visibleView']);_0x5f076e&&this['_closeAnnotation'](_0x5f076e),_0x4a522a();}}));}['afterInit'](){const _0x451c79=this['editor']['plugins']['get'](Ti);_0x451c79['context']===this['editor']&&(_0x451c79['hasActive']()||_0x451c79['switchTo']('inline'));}['setActiveAnnotation'](_0x1075ee){_0x1075ee!==this['activeAnnotation']&&(this['activeAnnotation']&&(this['activeAnnotation']['isActive']=!0x1),_0x1075ee&&this['editor']['ui']['focusTracker']['isFocused']&&(this['annotations']['has'](_0x1075ee)&&this['_addAnnotationToBalloon'](_0x1075ee,!0x0),_0x1075ee['isActive']=!0x0),_0x1075ee||this['_setSelectedAnnotations']([]),this['activeAnnotation']=_0x1075ee);}['attach'](_0x18b1e8){this['annotations']=_0x18b1e8;const _0x1920f9=this['editor']['plugins']['get'](Ti),_0x54f3ed=this['_balloon'];if(this['isAttached'])throw new _0x3cac4c('inlineannotations-attach-already-attached',this);if(_0x1920f9['context']!==this['editor'])throw new _0x3cac4c('inlineannotations-not-allowed-with-context',this);const _0x430647=this['editor']['plugins']['get'](di);this['listenTo'](_0x430647,'refresh',()=>{const _0x4003aa=_0x430647['getOrderedSelectedAnnotations']({'annotations':this['annotations'],'activeAnnotation':this['activeAnnotation']});var _0x1c33de,_0x44a52c;!this['_forceRefresh']&&(_0x1c33de=_0x4003aa,_0x44a52c=this['_selectedAnnotations'],_0x1c33de['length']===_0x44a52c['length']&&_0x1c33de['every'](_0x18c6a3=>_0x44a52c['includes'](_0x18c6a3)))||(this['_forceRefresh']=!0x1,this['_setSelectedAnnotations'](_0x4003aa),this['setActiveAnnotation'](_0x4003aa[0x0]||null));}),this['listenTo'](_0x430647,'blur',(_0x5dc6f7,{isAnnotationTracked:_0x4b11e0})=>{this['activeAnnotation']&&_0x4b11e0(this['activeAnnotation'])&&(this['_setSelectedAnnotations']([]),this['setActiveAnnotation'](null));}),this['listenTo'](_0x430647,'uiUpdate',()=>{this['_refreshVisibilityDebounced']();}),this['listenTo'](this['editor']['ui']['focusTracker'],'change:isFocused',(_0x2127ad,_0x5e9f8f,_0x45f19a)=>{_0x45f19a||this['setActiveAnnotation'](null);}),this['listenTo'](_0x18b1e8,'remove',(_0x3b1e0c,_0xa0b43)=>{this['_removeAnnotationFromBalloon'](_0xa0b43),_0xa0b43===this['activeAnnotation']&&this['setActiveAnnotation'](null);}),this['listenTo'](_0x54f3ed,'change:visibleView',(_0x3414e0,_0x21df80,_0xdc0d43,_0x2745d1)=>{_0x2745d1&&this['stopListening'](_0x2745d1);const _0x553780=_0x18b1e8['getByView'](_0xdc0d43);_0xdc0d43&&_0x553780&&(this['listenTo'](_0xdc0d43,'change:height',()=>{_0x54f3ed['updatePosition']();}),this['listenTo'](_0xdc0d43,'Esc',()=>{this['_closeAnnotation'](_0x553780),this['editor']['editing']['view']['focus']();}),this['activeAnnotation']!==_0x553780&&this['setActiveAnnotation'](_0x553780));}),this['listenTo'](this['editor']['ui'],'update',()=>{_0x54f3ed['visibleView']&&_0x18b1e8['getByView'](_0x54f3ed['visibleView'])&&_0x54f3ed['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 _0x3cac4c('inlineannotations-detach-not-attached',this);this['setActiveAnnotation'](null);for(const _0x173325 of this['_addedAnnotations'])this['_removeAnnotationFromBalloon'](_0x173325);this['_refreshVisibilityDebounced']['cancel'](),this['stopListening'](),this['isAttached']=!0x1,this['annotations']=null;}['destroy'](){this['isAttached']&&this['detach'](),this['_refreshVisibilityDebounced']['cancel']();}['_setSelectedAnnotations'](_0x271417){for(const _0x8dd0f1 of this['_selectedAnnotations'])_0x271417['includes'](_0x8dd0f1)||this['_manuallyClosed']['delete'](_0x8dd0f1);for(const _0x699ee8 of this['annotations'])_0x271417['includes'](_0x699ee8)||this['_removeAnnotationFromBalloon'](_0x699ee8);if(this['editor']['ui']['focusTracker']['isFocused']){for(const _0x48c603 of _0x271417)this['_addAnnotationToBalloon'](_0x48c603);}this['_selectedAnnotations']=_0x271417;}['_addAnnotationToBalloon'](_0x24a083,_0x558975=!0x1){this['_manuallyClosed']['has'](_0x24a083)||(this['_addedAnnotations']['has'](_0x24a083)||this['_balloon']['hasView'](_0x24a083['view'])||(this['_addedAnnotations']['add'](_0x24a083),this['_balloon']['add']({'stackId':_0x24a083['view']['id'],'view':_0x24a083['view'],'position':{'target':()=>this['_getBalloonTargetForAnnotation'](_0x24a083)}})),_0x558975&&this['_balloon']['showStack'](_0x24a083['view']['id']));}['_getBalloonTargetForAnnotation'](_0x4c5ddc){const _0x4eb3fb=_0x4c5ddc['target'],_0x1352c2=this['editor']['editing']['view'],_0x3082a8=_0x1352c2['document']['selection']['getFirstRange'](),_0x14eb7c=_0x1352c2['domConverter']['viewRangeToDom'](_0x3082a8);if(_0x14eb7c['collapse'](!0x0),_0x4eb3fb){if(_0x4eb3fb instanceof _0x50fe83)return _0x4eb3fb;let _0x25293f=[];for(const _0x2c17c5 of _0x4eb3fb)_0x25293f['push'](..._0x50fe83['getDomElementRects'](_0x2c17c5));_0x25293f=function(_0x1a7065){const _0x5b4b30=[];let _0x2ef16e=_0x1a7065[0x0];for(let _0x5940fb=0x1;_0x5940fb<_0x1a7065['length'];_0x5940fb++)if(Pi(_0x2ef16e,_0x1a7065[_0x5940fb])){const _0x43fbb4=_0x1a7065[_0x5940fb]['width'];_0x2ef16e['width']+=_0x43fbb4,_0x2ef16e['right']+=_0x43fbb4;}else _0x5b4b30['push'](_0x2ef16e),_0x2ef16e=_0x1a7065[_0x5940fb];return _0x5b4b30['push'](_0x2ef16e),_0x5b4b30;}(_0x25293f);const _0x2cc3e0=_0x14eb7c['getBoundingClientRect']();return _0x25293f['find'](_0x2ee006=>_0x2ee006['top']<=_0x2cc3e0['top']&&_0x2ee006['bottom']>=_0x2cc3e0['bottom']&&_0x2ee006['left']<=_0x2cc3e0['left']&&_0x2ee006['right']>=_0x2cc3e0['right'])||_0x25293f[0x0];}return _0x4c5ddc['targetRect']||_0x14eb7c;}['_removeAnnotationFromBalloon'](_0x2d62d0){this['_addedAnnotations']['has'](_0x2d62d0)&&this['_balloon']['hasView'](_0x2d62d0['view'])&&(this['_addedAnnotations']['delete'](_0x2d62d0),this['_balloon']['remove'](_0x2d62d0['view']));}['_closeAnnotation'](_0x29937f){this['_manuallyClosed']['add'](_0x29937f),this['_removeAnnotationFromBalloon'](_0x29937f);}};function Pi(_0x54657e,_0x440c3d){return _0x54657e['top']===_0x440c3d['top']&&_0x54657e['bottom']===_0x440c3d['bottom']&&_0x54657e['right']===_0x440c3d['left'];}var Li=class extends ht{['focusTracker'];['focusCycler'];['_annotationViews'];constructor(_0x15b935,_0x170448){super(_0x15b935),this['set']('isEmpty',!_0x170448['length']),this['focusTracker']=new _0x57589a(),this['_annotationViews']=_0x170448,this['_annotationViews']['delegate']('arrowup','arrowdown')['to'](this),this['on']('arrowup',()=>{this['focusCycler']['focusPrevious']();}),this['on']('arrowdown',()=>{this['focusCycler']['focusNext']();}),this['focusCycler']=new et({'focusables':_0x170448,'focusTracker':this['focusTracker']}),this['listenTo'](_0x170448,'add',()=>{this['isEmpty']=!0x1;}),this['listenTo'](_0x170448,'remove',(_0x2fb8a5,_0x38fde8)=>{_0x38fde8['isActive']&&this['focus'](),_0x170448['length']||(this['isEmpty']=!0x0);});const _0x11fa3c=this['bindTemplate'];this['setTemplate']({'tag':'div','attributes':{'dir':'auto','class':['ck','ck-comments-archive'],'tabindex':-0x1,'role':'list','aria-label':Et(_0x15b935,'COMMENTS_ARCHIVE_LIST_LABEL')},'children':[{'tag':'div','attributes':{'class':['ck-comments-archive__content'],'role':'presentation'},'children':[{'tag':'div','attributes':{'role':'presentation'},'children':_0x170448},{'tag':'p','attributes':{'class':['ck-comments-archive__info',_0x11fa3c['if']('isEmpty','ck-hidden',_0x1ba73f=>!_0x1ba73f)]},'children':[{'text':Et(_0x15b935,'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 _0x10bcd8 of this['_annotationViews'])this['focusTracker']['add'](_0x10bcd8['element']);this['_annotationViews']['on']('change',(_0x2ec111,{added:_0x172f61,removed:_0x202718})=>{for(const _0x4f43cc of _0x172f61)this['focusTracker']['add'](_0x4f43cc['element']);for(const _0x29ac4d of _0x202718)this['focusTracker']['remove'](_0x29ac4d['element']);});}},Di=class extends _0x388472{static get['pluginName'](){return'CommentsArchive';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[oi,ti];}constructor(_0x59008a){super(_0x59008a),this['archivedThreads']=new _0x5c875e();}['init'](){const _0x319fd2=this['context'],_0x20fee7=_0x319fd2['plugins']['get'](oi),_0xdf139d=_0x319fd2['plugins']['get'](ti);this['listenTo'](_0x20fee7,'addCommentThread',(_0x2db58e,{threadId:_0x4c6cb4})=>{const _0x145163=_0x20fee7['getCommentThread'](_0x4c6cb4);_0x145163['archivedAt']&&this['archivedThreads']['add'](_0x145163,this['_calculatePosition'](_0x145163['archivedAt'])),this['listenTo'](_0x145163,'change:archivedAt',(_0x3e1063,_0x5eb1e9,_0x49a9a4)=>{_0x49a9a4?this['archivedThreads']['has'](_0x145163)||this['archivedThreads']['add'](_0x145163,this['_calculatePosition'](_0x145163['archivedAt'])):this['archivedThreads']['has'](_0x145163)&&this['archivedThreads']['remove'](_0x145163);});}),this['listenTo'](_0x20fee7,'removeCommentThread',(_0x5828cb,{threadId:_0x5a6e3f})=>{const _0x590482=_0x20fee7['getCommentThread'](_0x5a6e3f);this['stopListening'](_0x590482),this['archivedThreads']['has'](_0x590482)&&this['archivedThreads']['remove'](_0x590482);},{'priority':'highest'}),this['listenTo'](_0xdf139d['collection'],'focus',(_0x11aa57,_0x1811c0)=>{_0x1811c0['isVisible']||(_0x1811c0['isActive']=!0x0,_0xdf139d['activate'](_0x1811c0));});}['_calculatePosition'](_0xeab401){const _0x28b5c0=[...this['archivedThreads']]['findIndex'](_0x247d00=>_0x247d00['archivedAt']<_0xeab401);return _0x28b5c0>-0x1?_0x28b5c0:this['archivedThreads']['length'];}},Vi=class extends _0x1228a1{['commentsArchiveView'];['annotationViews'];['_pendingThreads'];static get['pluginName'](){return'CommentsArchiveUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[Di,_0x13db02];}constructor(_0x26e53b){super(_0x26e53b),this['annotationViews']=new at(),this['_pendingThreads']=[];}['init'](){const _0x99ef5=this['editor'],_0x377339=this['_hideDialogOnAnnotationEscape']['bind'](this);_0x99ef5['ui']['componentFactory']['add']('commentsArchive',()=>this['_createCommentsArchiveButton'](_0x3a0b06,!0x0)),_0x99ef5['ui']['componentFactory']['add']('menuBar:commentsArchive',()=>{const _0x1d2395=this['_createCommentsArchiveButton'](rt);return _0x1d2395['set']({'role':'menuitemcheckbox'}),_0x1d2395;});const _0x4de2f4=_0x99ef5['plugins']['get'](Di),_0x4db810=_0x99ef5['plugins']['get']('Annotations'),_0x34cb2f=_0x99ef5['plugins']['get']('CommentsRepository');_0x4de2f4['archivedThreads']['forEach'](_0x242d84=>{this['_handleNewThread'](_0x242d84);}),this['listenTo'](_0x4de2f4['archivedThreads'],'add',(_0x4778ad,_0x1f34f2)=>{this['_handleNewThread'](_0x1f34f2);}),this['listenTo'](_0x4db810['collection'],'add',(_0x79691e,_0x295352)=>{const _0x43e593=this['_pendingThreads']['find'](_0x1a7c34=>{const _0x4dee7e=_0x34cb2f['_threadToController']['get'](_0x1a7c34);return _0x4dee7e&&_0x295352['innerView']===_0x4dee7e['view'];});if(_0x43e593){const _0xe3616f=this['_calculatePosition'](_0x43e593['archivedAt']);this['_addAnnotationToArchive'](_0x295352,_0xe3616f),this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x43e593),0x1);}}),this['listenTo'](_0x4de2f4['archivedThreads'],'remove',(_0x45149c,_0x44358d)=>{const _0x584a09=_0x99ef5['config']['get']('collaboration.channelId');if(!_0x584a09||_0x44358d['channelId']===_0x584a09){if(this['_pendingThreads']['includes'](_0x44358d))this['_pendingThreads']['splice'](this['_pendingThreads']['indexOf'](_0x44358d),0x1);else{const _0x46d30c=_0x34cb2f['_threadToController']['get'](_0x44358d),_0x4037fe=_0x4db810['getByInnerView'](_0x46d30c['view']);this['annotationViews']['remove'](_0x4037fe['view']),this['stopListening'](_0x4037fe),this['stopListening'](_0x4037fe['focusableElements']);}}}),this['listenTo'](_0x4db810['collection'],'add',(_0x1d53d1,_0x296a74)=>{this['listenTo'](_0x296a74,'escape',_0x377339);}),this['listenTo'](_0x4db810['collection'],'remove',(_0x4d19e6,_0x2b93a)=>{this['stopListening'](_0x2b93a,'escape',_0x377339);});}['_addAnnotationToArchive'](_0x41b899,_0x42e973){this['listenTo'](_0x41b899,'set:isVisible',_0xdee290=>{_0xdee290['return']=!0x1,_0xdee290['stop']();}),this['annotationViews']['add'](_0x41b899['view'],_0x42e973);}['_handleNewThread'](_0x2e53a8){const _0xdcf5e3=this['editor']['plugins']['get']('CommentsRepository'),_0x5b2af1=this['editor']['plugins']['get']('Annotations'),_0x136e77=this['editor']['config']['get']('collaboration.channelId');if(!_0x136e77||_0x2e53a8['channelId']===_0x136e77){const _0x11c7ac=_0xdcf5e3['_threadToController']['get'](_0x2e53a8);if(!_0x11c7ac)return void this['_pendingThreads']['push'](_0x2e53a8);const _0x3e91d2=this['_calculatePosition'](_0x2e53a8['archivedAt']),_0x377754=_0x5b2af1['getByInnerView'](_0x11c7ac['view']);_0x377754['isVisible']&&_0x5b2af1['_visibleAnnotations']['remove'](_0x377754),this['_addAnnotationToArchive'](_0x377754,_0x3e91d2);}}['_calculatePosition'](_0x6966f3){const _0x29263a=this['editor']['config']['get']('collaboration.channelId'),_0x90a19c=[...this['editor']['plugins']['get'](Di)['archivedThreads']]['filter'](_0x3d40fd=>_0x3d40fd['channelId']===_0x29263a)['findIndex'](_0x5e1bee=>_0x5e1bee['archivedAt']<_0x6966f3);return _0x90a19c<0x0||_0x90a19c>this['annotationViews']['length']?this['annotationViews']['length']:_0x90a19c-0x1;}['_toggleDialog'](){const _0x224797=this['editor'],_0x56d388=_0x224797['plugins']['get']('Dialog');this['commentsArchiveView']||(this['commentsArchiveView']=new Li(_0x224797['locale'],this['annotationViews'])),'commentsArchive'===_0x56d388['id']?_0x56d388['hide']():_0x56d388['show']({'id':'commentsArchive','title':Et(_0x224797['locale'],'COMMENTS_ARCHIVE'),'icon':_0x49f299,'hasCloseButton':!0x0,'content':this['commentsArchiveView'],'position':_0x2718da['EDITOR_TOP_SIDE']});}['_createCommentsArchiveButton'](_0x34bd45,_0x2484a4=!0x1){const _0x2614a1=this['editor']['locale'],_0x584651=this['editor']['plugins']['get']('Dialog'),_0x2afe70=new _0x34bd45(_0x2614a1);return _0x2afe70['bind']('isEnabled')['to'](this,'isEnabled'),_0x2afe70['bind']('isOn')['to'](_0x584651,'id',_0x3f069b=>'commentsArchive'===_0x3f069b),_0x2afe70['set']({'label':Et(_0x2614a1,'COMMENTS_ARCHIVE'),'icon':_0x49f299,'isToggleable':!0x0}),_0x2484a4&&(_0x2afe70['tooltip']=!0x0),this['listenTo'](_0x2afe70,'execute',()=>this['_toggleDialog']()),_0x2afe70;}['_hideDialogOnAnnotationEscape']=_0x34674d=>{const _0x2a1371=_0x34674d['source'];if(!this['annotationViews']['has'](_0x2a1371['view']))return;const _0x35d8cb=this['editor']['plugins']['get']('Dialog');_0x35d8cb['isOpen']&&'commentsArchive'===_0x35d8cb['id']&&(_0x35d8cb['hide'](),_0x34674d['stop']());};},Bi=class extends _0x1228a1{static get['requires'](){return[oi,wi,vi,Di,Vi,yi,Mi,Si,xi];}static get['pluginName'](){return'Comments';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}};export{ci as AddCommentThreadCommand,$t as Annotation,Jt as AnnotationCollection,Ri as AnnotationCounterButtonView,qt as AnnotationView,ti as Annotations,Ei as AnnotationsSidebarItemView,Ii as AnnotationsSidebarView,Ti as AnnotationsUIs,Ht as BaseCommentThreadView,Kt as BaseCommentView,hi as Comment,ri as CommentThread,bt as CommentThreadController,xt as CommentThreadInputView,Ut as CommentThreadView,Yt as CommentView,Bi as Comments,Di as CommentsArchive,Vi as CommentsArchiveUI,wi as CommentsEditing,Lt as CommentsListView,yi as CommentsOnly,oi as CommentsRepository,vi as CommentsUI,di as EditorAnnotations,xi as InlineAnnotations,Si as NarrowSidebar,ki as Sidebar,Mi as WideSidebar,Qt as bindAnnotationCollections};
|