@ckeditor/ckeditor5-comments 35.3.2 → 36.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/comments.js +3 -2
- package/build/translations/af.js +1 -0
- package/build/translations/ar.js +1 -0
- package/build/translations/bg.js +1 -0
- package/build/translations/bn.js +1 -0
- package/build/translations/bs.js +1 -0
- package/build/translations/ca.js +1 -0
- package/build/translations/cs.js +1 -0
- package/build/translations/da.js +1 -0
- package/build/translations/de-ch.js +1 -0
- package/build/translations/de.js +1 -0
- package/build/translations/el.js +1 -0
- package/build/translations/en-au.js +1 -0
- package/build/translations/es-co.js +1 -0
- package/build/translations/es.js +1 -0
- package/build/translations/et.js +1 -0
- package/build/translations/fa.js +1 -0
- package/build/translations/fi.js +1 -0
- package/build/translations/fr.js +1 -0
- package/build/translations/gl.js +1 -0
- package/build/translations/he.js +1 -0
- package/build/translations/hi.js +1 -0
- package/build/translations/hr.js +1 -0
- package/build/translations/hu.js +1 -0
- package/build/translations/id.js +1 -0
- package/build/translations/it.js +1 -0
- package/build/translations/ja.js +1 -0
- package/build/translations/jv.js +1 -0
- package/build/translations/ko.js +1 -0
- package/build/translations/lt.js +1 -0
- package/build/translations/lv.js +1 -0
- package/build/translations/ms.js +1 -0
- package/build/translations/nl.js +1 -0
- package/build/translations/no.js +1 -0
- package/build/translations/pl.js +1 -0
- package/build/translations/pt-br.js +1 -0
- package/build/translations/pt.js +1 -0
- package/build/translations/ro.js +1 -0
- package/build/translations/ru.js +1 -0
- package/build/translations/sk.js +1 -0
- package/build/translations/sr-latn.js +1 -0
- package/build/translations/sr.js +1 -0
- package/build/translations/sv.js +1 -0
- package/build/translations/th.js +1 -0
- package/build/translations/tk.js +1 -0
- package/build/translations/tr.js +1 -0
- package/build/translations/tt.js +1 -0
- package/build/translations/ug.js +1 -0
- package/build/translations/uk.js +1 -0
- package/build/translations/ur.js +1 -0
- package/build/translations/vi.js +1 -0
- package/build/translations/zh-cn.js +1 -0
- package/build/translations/zh.js +1 -0
- package/lang/translations/af.po +1 -1
- package/lang/translations/ar.po +4 -4
- package/lang/translations/bg.po +4 -4
- package/lang/translations/bn.po +4 -4
- package/lang/translations/bs.po +1 -1
- package/lang/translations/ca.po +4 -4
- package/lang/translations/cs.po +4 -4
- package/lang/translations/da.po +4 -4
- package/lang/translations/de-ch.po +1 -1
- package/lang/translations/de.po +4 -4
- package/lang/translations/el.po +4 -4
- package/lang/translations/en-au.po +1 -1
- package/lang/translations/en.po +1 -1
- package/lang/translations/es-co.po +1 -1
- package/lang/translations/es.po +4 -4
- package/lang/translations/et.po +4 -4
- package/lang/translations/fa.po +1 -1
- package/lang/translations/fi.po +4 -4
- package/lang/translations/fr.po +4 -4
- package/lang/translations/gl.po +1 -1
- package/lang/translations/he.po +4 -4
- package/lang/translations/hi.po +4 -4
- package/lang/translations/hr.po +1 -1
- package/lang/translations/hu.po +4 -4
- package/lang/translations/id.po +4 -4
- package/lang/translations/it.po +4 -4
- package/lang/translations/ja.po +4 -4
- package/lang/translations/jv.po +1 -1
- package/lang/translations/ko.po +4 -4
- package/lang/translations/lt.po +4 -4
- package/lang/translations/lv.po +4 -4
- package/lang/translations/ms.po +4 -4
- package/lang/translations/nl.po +4 -4
- package/lang/translations/no.po +4 -4
- package/lang/translations/pl.po +4 -4
- package/lang/translations/pt-br.po +4 -4
- package/lang/translations/pt.po +4 -4
- package/lang/translations/ro.po +4 -4
- package/lang/translations/ru.po +4 -4
- package/lang/translations/sk.po +4 -4
- package/lang/translations/sr-latn.po +5 -5
- package/lang/translations/sr.po +5 -5
- package/lang/translations/sv.po +4 -4
- package/lang/translations/th.po +4 -4
- package/lang/translations/tk.po +1 -1
- package/lang/translations/tr.po +4 -4
- package/lang/translations/tt.po +1 -1
- package/lang/translations/ug.po +7 -7
- package/lang/translations/uk.po +4 -4
- package/lang/translations/ur.po +1 -1
- package/lang/translations/vi.po +4 -4
- package/lang/translations/zh-cn.po +4 -4
- package/lang/translations/zh.po +4 -4
- package/package.json +3 -3
- package/src/annotations/annotation.js +2 -2
- package/src/annotations/annotationcollection.js +2 -2
- package/src/annotations/annotations.js +2 -2
- package/src/annotations/annotationsuis.js +2 -2
- package/src/annotations/editorannotations.js +2 -2
- package/src/annotations/inlineannotations.js +2 -2
- package/src/annotations/narrowsidebar.js +2 -2
- package/src/annotations/sidebar.js +2 -2
- package/src/annotations/view/annotationcounterbuttonview.js +2 -2
- package/src/annotations/view/annotationview.js +2 -2
- package/src/annotations/view/sidebaritemview.js +2 -2
- package/src/annotations/view/sidebarview.js +2 -2
- package/src/annotations/widesidebar.js +2 -2
- package/src/comments/addcommentthreadcommand.js +2 -2
- package/src/comments/commentsediting.js +2 -2
- package/src/comments/commentsrepository.js +2 -2
- package/src/comments/commentsui.js +2 -2
- package/src/comments/integrations/commentsrestrictededitingmode.js +2 -2
- package/src/comments/integrations/importword.js +2 -2
- package/src/comments/ui/commenteditor/commenteditor.js +2 -2
- package/src/comments/ui/commenteditor/commenteditorui.js +2 -2
- package/src/comments/ui/commenteditor/commenteditoruiview.js +2 -2
- package/src/comments/ui/commentthreadcontroller.js +2 -2
- package/src/comments/ui/view/basecommentthreadview.js +2 -2
- package/src/comments/ui/view/basecommentview.js +2 -2
- package/src/comments/ui/view/collapsedcommentsview.js +2 -2
- package/src/comments/ui/view/commentcontentview.js +2 -2
- package/src/comments/ui/view/commentinputview.js +2 -2
- package/src/comments/ui/view/commentslistview.js +2 -2
- package/src/comments/ui/view/commentthreadinputview.js +2 -2
- package/src/comments/ui/view/commentthreadview.js +2 -2
- package/src/comments/ui/view/commentview.js +2 -2
- package/src/comments.js +2 -2
- package/src/commentsonly.js +2 -2
- package/src/index.js +1 -1
- package/src/utils/common-translations.js +2 -2
- package/src/utils/createmutationobserver.js +2 -2
- package/theme/annotation.css +23 -6
- package/theme/commentthread.css +7 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x533b=['Sidebar','_selectedAnnotations','contains','low','detach','requires','_showBalloon','resize','activeAnnotation','blur','addAnnotation','create','delete','_editorAnnotations','Esc','init','attach','change:container','isDirty','_destroyEditorAnnotationsIntegration','first','uiUpdate','_domEmitter','mousedown','editors','isVisible','focus','destroy','refreshPositioning','listenTo','stopListening','_annotations','element','_refreshPositioning','esc','bodyCollection','annotations','type','narrowsidebar-detach-not-attached','narrowsidebar-attach-already-attached','ready','_integrateWithEditorAnnotations','set:container','_detachFromContainer','attachToDom','annotationType','rearrange','add','from','detachFromDom','change:height','plugins','addEventListener','southArrowNorthEast','narrowSidebar','_hideBalloon','_manuallyClosedAnnotationViews','content','southArrowNorth','setActiveAnnotation','getSidebarItemView','getOrderedSelectedAnnotations','view','get','EditorAnnotations','refresh','clear','preventDefault','context','northArrowSouthEast','has','_updateBalloonPosition','set','pin','remove','high','_attachListeners','_detachListeners','number','_refreshPositioningDebounced','balloonPanelView','northArrowSouth','getByView','target','isAttached','hasDomSelection','locale','register','_annotationToNarrowView','includes','execute','defaultPositions','northArrowSouthWest','preventClosingBalloon','_setSelectedAnnotations','keydown'];(function(_0x228511,_0x533b3b){const _0x2de320=function(_0x2cd0d0){while(--_0x2cd0d0){_0x228511['push'](_0x228511['shift']());}};_0x2de320(++_0x533b3b);}(_0x533b,0xf5));const _0x2de3=function(_0x228511,_0x533b3b){_0x228511=_0x228511-0x0;let _0x2de320=_0x533b[_0x228511];return _0x2de320;};import{ContextPlugin as _0x4aa965}from'ckeditor5/src/core';import _0x274d20 from'./annotationsuis';import _0x1cbf17 from'./sidebar';import _0x56795e from'./view/annotationcounterbuttonview';import{BalloonPanelView as _0x2b4ed3,BodyCollection as _0x1c154a}from'ckeditor5/src/ui';import{CKEditorError as _0x5cbe7a,DomEmitterMixin as _0x3e0a7b,keyCodes as _0x34f758,Collection as _0x5b1bbc}from'ckeditor5/src/utils';import'../../theme/sidebar-narrow.css';import{debounce as _0x224c6e}from'lodash-es';export default class s extends _0x4aa965{static get[_0x2de3('0x30')](){return[_0x1cbf17,_0x274d20];}static get['pluginName'](){return'NarrowSidebar';}constructor(_0x378dac){super(_0x378dac),this[_0x2de3('0x1f')]=!0x1,this[_0x2de3('0x3')]=new Set(),this[_0x2de3('0x41')]=Object[_0x2de3('0x36')](_0x3e0a7b),this[_0x2de3('0x23')]=new Map(),this[_0x2de3('0x13')](_0x2de3('0x33'),null),this[_0x2de3('0x4f')]=null,this[_0x2de3('0x2c')]=[],this[_0x2de3('0x38')]=new _0x5b1bbc(),this[_0x2de3('0x1a')]=_0x224c6e(()=>{this['_refreshPositioning']();},0xfa,{'leading':!0x1});}[_0x2de3('0x3a')](){this[_0x2de3('0xf')][_0x2de3('0x5e')][_0x2de3('0xa')](_0x274d20)[_0x2de3('0x22')](_0x2de3('0x1'),this),this['bodyCollection']=new _0x1c154a(this[_0x2de3('0xf')][_0x2de3('0x21')]),this[_0x2de3('0x1b')]=new _0x2b4ed3(this[_0x2de3('0xf')][_0x2de3('0x21')]),this[_0x2de3('0x4e')][_0x2de3('0x57')](),this[_0x2de3('0x4e')]['add'](this[_0x2de3('0x1b')]);}[_0x2de3('0x3b')](_0x33124d){this[_0x2de3('0x4f')]=_0x33124d;const _0x4f83b3=this['context'][_0x2de3('0x5e')]['get'](_0x1cbf17),_0x4c7901=this['balloonPanelView'];if(_0x4f83b3[_0x2de3('0x4a')]=_0x33124d,this[_0x2de3('0x1f')])throw new _0x5cbe7a(_0x2de3('0x52'),this);this[_0x2de3('0x1f')]=!0x0,this[_0x2de3('0x48')](_0x4f83b3,_0x2de3('0x55'),()=>{this[_0x2de3('0x2f')](),this['listenTo'](_0x4f83b3,_0x2de3('0x3c'),_0x4fca61=>{_0x4fca61['off'](),this[_0x2de3('0x3b')](_0x33124d);});}),_0x4f83b3['_attachToContainer']({'viewClass':'ck-sidebar--narrow','spaceBetweenItems':0x5});const _0x1a0b69=_0x3ba75a=>{const _0x41e5e8=new _0x56795e(this[_0x2de3('0xf')][_0x2de3('0x21')]);_0x4f83b3[_0x2de3('0x35')](_0x3ba75a,_0x41e5e8),this[_0x2de3('0x23')][_0x2de3('0x13')](_0x3ba75a,_0x41e5e8),_0x41e5e8['bind'](_0x2de3('0x3d'),_0x2de3('0x58'),_0x2de3('0x19'))['to'](_0x3ba75a[_0x2de3('0x9')],_0x2de3('0x3d'),_0x2de3('0x50'),'length'),_0x41e5e8['on'](_0x2de3('0x25'),()=>{this['_manuallyClosedAnnotationViews'][_0x2de3('0xd')](),_0x4c7901[_0x2de3('0x4')][_0x2de3('0x3f')]!==_0x3ba75a['view']?(this[_0x2de3('0x31')](_0x3ba75a),_0x3ba75a['view']['element']['focus'](),this[_0x2de3('0x6')](_0x3ba75a)):this[_0x2de3('0x6')](null);});};for(const _0x1bb7d5 of _0x33124d)_0x1a0b69(_0x1bb7d5);this[_0x2de3('0x48')](_0x33124d,'add',(_0x5d0935,_0x2f4cbe)=>{_0x1a0b69(_0x2f4cbe);}),this['listenTo'](_0x33124d,_0x2de3('0x15'),(_0x307a69,_0x314e49,_0xe312d3)=>{this[_0x2de3('0x23')][_0x2de3('0xa')](_0x314e49)['destroy'](),this[_0x2de3('0x23')][_0x2de3('0x37')](_0x314e49),_0x4f83b3[_0x2de3('0x59')]({'removedAnnotation':_0x314e49,'previousAnnotation':_0x33124d[_0x2de3('0xa')](_0xe312d3-0x1),'nextAnnotation':_0x33124d[_0x2de3('0xa')](_0xe312d3+0x1)}),_0x314e49===this[_0x2de3('0x33')]&&this['setActiveAnnotation'](null);},{'priority':_0x2de3('0x2e')}),this[_0x2de3('0x48')](_0x33124d,_0x2de3('0x45'),(_0x417e85,_0x4b1755)=>{this[_0x2de3('0x6')](_0x4b1755);}),this[_0x2de3('0x48')](_0x33124d,_0x2de3('0x34'),()=>{this['setActiveAnnotation'](null);}),this[_0x2de3('0x41')][_0x2de3('0x48')](document,_0x2de3('0x2a'),(_0x19e203,_0x6a387e)=>{_0x6a387e['keyCode']===_0x34f758[_0x2de3('0x4d')]&&_0x4c7901['isVisible']&&(this[_0x2de3('0x3')][_0x2de3('0x5a')](_0x4c7901[_0x2de3('0x4')][_0x2de3('0x3f')]),this[_0x2de3('0x2')](),_0x6a387e['stopPropagation'](),_0x6a387e[_0x2de3('0xe')]());}),this['_domEmitter'][_0x2de3('0x48')](document,_0x2de3('0x42'),(_0x5923cd,_0x5b2bfe)=>{const _0x4a1df4=_0x5b2bfe[_0x2de3('0x1e')];_0x4c7901[_0x2de3('0x44')]&&_0x4c7901['element'][_0x2de3('0x2d')](_0x4a1df4)||_0x4f83b3['view']['element'][_0x2de3('0x2d')](_0x4a1df4)||_0x5923cd[_0x2de3('0x28')]||(this[_0x2de3('0x3')][_0x2de3('0xd')](),this[_0x2de3('0x2')](),this[_0x2de3('0x6')](null));});const _0x33a54c=this[_0x2de3('0xf')][_0x2de3('0x43')]?this[_0x2de3('0xf')][_0x2de3('0x43')]:new _0x5b1bbc([this[_0x2de3('0xf')]]);for(const _0x139195 of _0x33a54c)this[_0x2de3('0x54')](_0x139195);this[_0x2de3('0x48')](_0x33a54c,'add',(_0x150c0b,_0x723d5b)=>{this[_0x2de3('0x48')](_0x723d5b,_0x2de3('0x53'),()=>{this[_0x2de3('0x54')](_0x723d5b);});}),this['listenTo'](_0x33a54c,_0x2de3('0x15'),(_0x367819,_0x4cf5c5)=>{_0x4cf5c5['plugins'][_0x2de3('0x11')](_0x2de3('0xb'))&&this[_0x2de3('0x3e')](_0x4cf5c5[_0x2de3('0x5e')]['get'](_0x2de3('0xb')));}),window[_0x2de3('0x5f')](_0x2de3('0x32'),this[_0x2de3('0x1a')]),this[_0x2de3('0x4c')]();}[_0x2de3('0x6')](_0xf7cf50){if(_0xf7cf50===this['activeAnnotation'])return;const _0x7a15=this[_0x2de3('0xf')]['plugins'][_0x2de3('0xa')](_0x2de3('0x2b'));if(_0x7a15[_0x2de3('0xc')]({'blurredAnnotation':this[_0x2de3('0x33')],'activatedAnnotation':_0xf7cf50,'disableAnimationOnActivatedAnnotation':!0x0}),_0xf7cf50)_0x7a15[_0x2de3('0x7')](_0xf7cf50)?this[_0x2de3('0x31')](_0xf7cf50):this[_0x2de3('0x2')]();else this[_0x2de3('0x2')]();this[_0x2de3('0x33')]=_0xf7cf50;}[_0x2de3('0x2f')](){if(!this[_0x2de3('0x1f')])throw new _0x5cbe7a(_0x2de3('0x51'),this);this[_0x2de3('0x6')](null);const _0x20baf1=this[_0x2de3('0xf')]['plugins'][_0x2de3('0xa')](_0x2de3('0x2b'));this[_0x2de3('0x2')](),Array['from'](this[_0x2de3('0x23')]['values'](),_0x316e99=>_0x316e99[_0x2de3('0x46')]()),this[_0x2de3('0x23')]['clear'](),_0x20baf1[_0x2de3('0x56')](this[_0x2de3('0x4f')]),this[_0x2de3('0x49')](),this[_0x2de3('0x41')][_0x2de3('0x49')](),this['stopListening'](this[_0x2de3('0xf')]['editors']);for(const _0x2c1247 of Array[_0x2de3('0x5b')](this[_0x2de3('0x38')]))this['_destroyEditorAnnotationsIntegration'](_0x2c1247);window['removeEventListener'](_0x2de3('0x32'),this['_refreshPositioningDebounced']),this[_0x2de3('0x1a')]['cancel'](),this[_0x2de3('0x2c')]=[],this[_0x2de3('0x1f')]=!0x1,this[_0x2de3('0x4f')]=null;}[_0x2de3('0x46')](){this[_0x2de3('0x1f')]&&this[_0x2de3('0x2f')](),this[_0x2de3('0x4e')][_0x2de3('0x5c')]();}[_0x2de3('0x54')](_0x5320b5){const _0x37f3e1=_0x5320b5[_0x2de3('0x5e')][_0x2de3('0xa')](_0x2de3('0xb')),_0x35afd9=this[_0x2de3('0xf')][_0x2de3('0x5e')]['get'](_0x1cbf17),_0x21a1f6=this[_0x2de3('0x4f')],_0x520cb1=this[_0x2de3('0x1b')],_0x287e47=()=>{const _0x5544ee=_0x37f3e1[_0x2de3('0x8')]({'activeAnnotation':this[_0x2de3('0x33')],'annotations':this['annotations']});this[_0x2de3('0x29')](_0x5544ee),this[_0x2de3('0x6')](_0x5544ee[0x0]||null);};this[_0x2de3('0x48')](_0x37f3e1,'refresh',_0x287e47),this['listenTo'](_0x37f3e1,_0x2de3('0x34'),(_0x3d10de,{isAnnotationTracked:_0x1fa9ff})=>{this[_0x2de3('0x33')]&&_0x1fa9ff(this[_0x2de3('0x33')])&&(this[_0x2de3('0x29')]([]),this[_0x2de3('0x6')](null));}),this[_0x2de3('0x48')](_0x37f3e1,_0x2de3('0x40'),()=>{this[_0x2de3('0x1a')]();}),this['listenTo'](_0x21a1f6,_0x2de3('0x34'),_0x3d98a5=>{_0x37f3e1[_0x2de3('0x20')]()&&_0x3d98a5['stop']();},{'priority':_0x2de3('0x16')}),this[_0x2de3('0x41')]['listenTo'](document,_0x2de3('0x42'),(_0x3e1d3f,_0x4ffc29)=>{const _0x313b76=_0x4ffc29[_0x2de3('0x1e')];_0x520cb1['isVisible']&&_0x520cb1[_0x2de3('0x4b')]['contains'](_0x313b76)||_0x35afd9[_0x2de3('0x9')][_0x2de3('0x4b')][_0x2de3('0x2d')](_0x313b76)||this[_0x2de3('0x33')]&&_0x37f3e1[_0x2de3('0x20')]()&&(_0x287e47(),_0x3e1d3f['preventClosingBalloon']=!0x0);},{'priority':_0x2de3('0x16')}),this['_editorAnnotations']['add'](_0x37f3e1);}[_0x2de3('0x3e')](_0x400f21){_0x400f21&&(this['stopListening'](_0x400f21),this[_0x2de3('0x38')][_0x2de3('0x15')](_0x400f21));}['_setSelectedAnnotations'](_0x2c6553){for(const _0x1f64a9 of this[_0x2de3('0x2c')])_0x2c6553[_0x2de3('0x24')](_0x1f64a9)||this[_0x2de3('0x3')][_0x2de3('0x37')](_0x1f64a9[_0x2de3('0x9')]);this[_0x2de3('0x2c')]=_0x2c6553;}[_0x2de3('0x4c')](){const _0x4e947f=this[_0x2de3('0x1b')];this[_0x2de3('0x4f')][_0x2de3('0x47')](),_0x4e947f[_0x2de3('0x44')]&&this[_0x2de3('0x12')]();}[_0x2de3('0x31')](_0x13cbca){if(this[_0x2de3('0x3')][_0x2de3('0x11')](_0x13cbca['view']))return;const _0x3915df=this['balloonPanelView'][_0x2de3('0x4')][_0x2de3('0x3f')];_0x3915df!==_0x13cbca['view']?(_0x3915df&&this['_detachListeners'](_0x3915df),this[_0x2de3('0x17')](_0x13cbca['view']),this[_0x2de3('0x1b')][_0x2de3('0x4')]['clear'](),this['balloonPanelView'][_0x2de3('0x4')]['add'](_0x13cbca['view']),this[_0x2de3('0x12')]()):this[_0x2de3('0x12')]();}[_0x2de3('0x12')](){const _0x4d1a5b=this[_0x2de3('0x1b')]['content'][_0x2de3('0x3f')],_0x3d9188=this[_0x2de3('0x4f')][_0x2de3('0x1d')](_0x4d1a5b);if(!this['_annotationToNarrowView'][_0x2de3('0x11')](_0x3d9188))return;const _0xedc383=this[_0x2de3('0x23')][_0x2de3('0xa')](_0x3d9188)[_0x2de3('0x4b')],_0x4e9a55=function(){const _0x51fa00=_0x2b4ed3[_0x2de3('0x26')];return[_0x51fa00[_0x2de3('0x0')],_0x51fa00[_0x2de3('0x10')],_0x51fa00[_0x2de3('0x5')],_0x51fa00[_0x2de3('0x1c')],_0x51fa00['southArrowNorthWest'],_0x51fa00[_0x2de3('0x27')]];}();this[_0x2de3('0x1b')][_0x2de3('0x14')]({'target':_0xedc383,'positions':_0x4e9a55});}[_0x2de3('0x2')](){const _0x55d366=this['balloonPanelView'],_0x5c564d=_0x55d366[_0x2de3('0x4')]['first'];_0x5c564d&&(this[_0x2de3('0x18')](_0x5c564d),_0x55d366['unpin'](),_0x55d366[_0x2de3('0x4')][_0x2de3('0xd')]());}[_0x2de3('0x17')](_0x2c504c){this[_0x2de3('0x48')](_0x2c504c,_0x2de3('0x5d'),()=>this['_updateBalloonPosition']()),this[_0x2de3('0x48')](_0x2c504c,_0x2de3('0x39'),(_0x986ee7,_0x5e15ba)=>{this['_manuallyClosedAnnotationViews'][_0x2de3('0x5a')](_0x2c504c),this[_0x2de3('0x2')](),_0x5e15ba();});}[_0x2de3('0x18')](_0x1a1190){this[_0x2de3('0x49')](_0x1a1190);}}
|
|
23
|
+
const _0x2ee8=['context','change:height','activeAnnotation','contains','EditorAnnotations','first','keydown','uiUpdate','_editorAnnotations','content','_refreshPositioningDebounced','unpin','delete','keyCode','_detachListeners','narrowSidebar','editors','listenTo','annotations','off','element','ck-sidebar--narrow','type','narrowsidebar-attach-already-attached','set','init','annotationType','_hideBalloon','_refreshPositioning','rearrange','detachFromDom','getSidebarItemView','isAttached','get','preventClosingBalloon','getOrderedSelectedAnnotations','stopPropagation','southArrowNorthEast','_attachListeners','_destroyEditorAnnotationsIntegration','defaultPositions','NarrowSidebar','resize','_integrateWithEditorAnnotations','bind','addAnnotation','_annotationToNarrowView','balloonPanelView','has','length','stop','_setSelectedAnnotations','view','narrowsidebar-detach-not-attached','high','getByView','_detachFromContainer','plugins','attach','Esc','_showBalloon','bodyCollection','add','removeEventListener','focus','isDirty','execute','low','preventDefault','_selectedAnnotations','ready','change:container','stopListening','target','detach','pin','_manuallyClosedAnnotationViews','requires','cancel','number','includes','remove','Sidebar','_updateBalloonPosition','hasDomSelection','locale','destroy','clear','blur','create','isVisible','setActiveAnnotation','_domEmitter','refresh'];(function(_0x21b1d9,_0x2ee85d){const _0x9ea00=function(_0x365859){while(--_0x365859){_0x21b1d9['push'](_0x21b1d9['shift']());}};_0x9ea00(++_0x2ee85d);}(_0x2ee8,0xf1));const _0x9ea0=function(_0x21b1d9,_0x2ee85d){_0x21b1d9=_0x21b1d9-0x0;let _0x9ea00=_0x2ee8[_0x21b1d9];return _0x9ea00;};import{ContextPlugin as _0x3a5597}from'ckeditor5/src/core';import _0x465548 from'./annotationsuis';import _0x250618 from'./sidebar';import _0x43d1ed from'./view/annotationcounterbuttonview';import{BalloonPanelView as _0x2b59da,BodyCollection as _0x41bf5e}from'ckeditor5/src/ui';import{CKEditorError as _0x2dffc6,DomEmitterMixin as _0x1b0d2d,keyCodes as _0x38f2e4,Collection as _0x24df3d}from'ckeditor5/src/utils';import'../../theme/sidebar-narrow.css';import{debounce as _0x3cbe4e}from'lodash-es';export default class s extends _0x3a5597{static get[_0x9ea0('0x18')](){return[_0x250618,_0x465548];}static get['pluginName'](){return _0x9ea0('0x52');}constructor(_0x3794b1){super(_0x3794b1),this[_0x9ea0('0x49')]=!0x1,this[_0x9ea0('0x17')]=new Set(),this['_domEmitter']=Object[_0x9ea0('0x24')](_0x1b0d2d),this[_0x9ea0('0x57')]=new Map(),this[_0x9ea0('0x41')](_0x9ea0('0x2b'),null),this[_0x9ea0('0x3b')]=null,this['_selectedAnnotations']=[],this[_0x9ea0('0x31')]=new _0x24df3d(),this[_0x9ea0('0x33')]=_0x3cbe4e(()=>{this[_0x9ea0('0x45')]();},0xfa,{'leading':!0x1});}[_0x9ea0('0x42')](){this['context'][_0x9ea0('0x4')][_0x9ea0('0x4a')](_0x465548)['register'](_0x9ea0('0x38'),this),this[_0x9ea0('0x8')]=new _0x41bf5e(this[_0x9ea0('0x29')][_0x9ea0('0x20')]),this['balloonPanelView']=new _0x2b59da(this['context'][_0x9ea0('0x20')]),this[_0x9ea0('0x8')]['attachToDom'](),this[_0x9ea0('0x8')][_0x9ea0('0x9')](this[_0x9ea0('0x58')]);}[_0x9ea0('0x5')](_0x243078){this[_0x9ea0('0x3b')]=_0x243078;const _0x2b0d8b=this[_0x9ea0('0x29')][_0x9ea0('0x4')][_0x9ea0('0x4a')](_0x250618),_0x31c1f0=this[_0x9ea0('0x58')];if(_0x2b0d8b['_annotations']=_0x243078,this[_0x9ea0('0x49')])throw new _0x2dffc6(_0x9ea0('0x40'),this);this[_0x9ea0('0x49')]=!0x0,this[_0x9ea0('0x3a')](_0x2b0d8b,'set:container',()=>{this[_0x9ea0('0x15')](),this[_0x9ea0('0x3a')](_0x2b0d8b,_0x9ea0('0x12'),_0x36b1b0=>{_0x36b1b0[_0x9ea0('0x3c')](),this[_0x9ea0('0x5')](_0x243078);});}),_0x2b0d8b['_attachToContainer']({'viewClass':_0x9ea0('0x3e'),'spaceBetweenItems':0x5});const _0x506f73=_0x640431=>{const _0x52027f=new _0x43d1ed(this[_0x9ea0('0x29')][_0x9ea0('0x20')]);_0x2b0d8b[_0x9ea0('0x56')](_0x640431,_0x52027f),this[_0x9ea0('0x57')]['set'](_0x640431,_0x52027f),_0x52027f[_0x9ea0('0x55')]('isDirty',_0x9ea0('0x43'),_0x9ea0('0x1a'))['to'](_0x640431[_0x9ea0('0x5d')],_0x9ea0('0xc'),_0x9ea0('0x3f'),_0x9ea0('0x5a')),_0x52027f['on'](_0x9ea0('0xd'),()=>{this[_0x9ea0('0x17')]['clear'](),_0x31c1f0[_0x9ea0('0x32')][_0x9ea0('0x2e')]!==_0x640431[_0x9ea0('0x5d')]?(this['_showBalloon'](_0x640431),_0x640431[_0x9ea0('0x5d')][_0x9ea0('0x3d')][_0x9ea0('0xb')](),this[_0x9ea0('0x26')](_0x640431)):this[_0x9ea0('0x26')](null);});};for(const _0x1249c7 of _0x243078)_0x506f73(_0x1249c7);this[_0x9ea0('0x3a')](_0x243078,_0x9ea0('0x9'),(_0x4910ad,_0x1f0387)=>{_0x506f73(_0x1f0387);}),this[_0x9ea0('0x3a')](_0x243078,_0x9ea0('0x1c'),(_0x247168,_0x2fbf00,_0x411162)=>{this[_0x9ea0('0x57')][_0x9ea0('0x4a')](_0x2fbf00)[_0x9ea0('0x21')](),this[_0x9ea0('0x57')][_0x9ea0('0x35')](_0x2fbf00),_0x2b0d8b[_0x9ea0('0x46')]({'removedAnnotation':_0x2fbf00,'previousAnnotation':_0x243078[_0x9ea0('0x4a')](_0x411162-0x1),'nextAnnotation':_0x243078[_0x9ea0('0x4a')](_0x411162+0x1)}),_0x2fbf00===this[_0x9ea0('0x2b')]&&this[_0x9ea0('0x26')](null);},{'priority':_0x9ea0('0xe')}),this[_0x9ea0('0x3a')](_0x243078,_0x9ea0('0xb'),(_0x34f13b,_0x1233f9)=>{this[_0x9ea0('0x26')](_0x1233f9);}),this[_0x9ea0('0x3a')](_0x243078,_0x9ea0('0x23'),()=>{this[_0x9ea0('0x26')](null);}),this[_0x9ea0('0x27')][_0x9ea0('0x3a')](document,_0x9ea0('0x2f'),(_0x2d01f4,_0x6c7e87)=>{_0x6c7e87[_0x9ea0('0x36')]===_0x38f2e4['esc']&&_0x31c1f0[_0x9ea0('0x25')]&&(this[_0x9ea0('0x17')]['add'](_0x31c1f0['content'][_0x9ea0('0x2e')]),this['_hideBalloon'](),_0x6c7e87[_0x9ea0('0x4d')](),_0x6c7e87[_0x9ea0('0xf')]());}),this[_0x9ea0('0x27')]['listenTo'](document,'mousedown',(_0x5d717c,_0x5f0fcd)=>{const _0x2d9379=_0x5f0fcd[_0x9ea0('0x14')];_0x31c1f0[_0x9ea0('0x25')]&&_0x31c1f0[_0x9ea0('0x3d')][_0x9ea0('0x2c')](_0x2d9379)||_0x2b0d8b[_0x9ea0('0x5d')][_0x9ea0('0x3d')][_0x9ea0('0x2c')](_0x2d9379)||_0x5d717c[_0x9ea0('0x4b')]||(this[_0x9ea0('0x17')][_0x9ea0('0x22')](),this[_0x9ea0('0x44')](),this[_0x9ea0('0x26')](null));});const _0x423a99=this[_0x9ea0('0x29')][_0x9ea0('0x39')]?this[_0x9ea0('0x29')][_0x9ea0('0x39')]:new _0x24df3d([this['context']]);for(const _0x6e373b of _0x423a99)this[_0x9ea0('0x54')](_0x6e373b);this[_0x9ea0('0x3a')](_0x423a99,_0x9ea0('0x9'),(_0x4a390a,_0x56f32b)=>{this[_0x9ea0('0x3a')](_0x56f32b,_0x9ea0('0x11'),()=>{this['_integrateWithEditorAnnotations'](_0x56f32b);});}),this[_0x9ea0('0x3a')](_0x423a99,_0x9ea0('0x1c'),(_0x41c080,_0x32f7cb)=>{_0x32f7cb['plugins'][_0x9ea0('0x59')](_0x9ea0('0x2d'))&&this[_0x9ea0('0x50')](_0x32f7cb[_0x9ea0('0x4')][_0x9ea0('0x4a')]('EditorAnnotations'));}),window['addEventListener'](_0x9ea0('0x53'),this[_0x9ea0('0x33')]),this['_refreshPositioning']();}[_0x9ea0('0x26')](_0x43015b){if(_0x43015b===this[_0x9ea0('0x2b')])return;const _0x2b7d4f=this[_0x9ea0('0x29')][_0x9ea0('0x4')][_0x9ea0('0x4a')](_0x9ea0('0x1d'));if(_0x2b7d4f[_0x9ea0('0x28')]({'blurredAnnotation':this[_0x9ea0('0x2b')],'activatedAnnotation':_0x43015b,'disableAnimationOnActivatedAnnotation':!0x0}),_0x43015b)_0x2b7d4f[_0x9ea0('0x48')](_0x43015b)?this[_0x9ea0('0x7')](_0x43015b):this['_hideBalloon']();else this['_hideBalloon']();this[_0x9ea0('0x2b')]=_0x43015b;}[_0x9ea0('0x15')](){if(!this[_0x9ea0('0x49')])throw new _0x2dffc6(_0x9ea0('0x0'),this);this['setActiveAnnotation'](null);const _0x5d2f80=this[_0x9ea0('0x29')][_0x9ea0('0x4')][_0x9ea0('0x4a')](_0x9ea0('0x1d'));this[_0x9ea0('0x44')](),Array['from'](this[_0x9ea0('0x57')]['values'](),_0x6829c3=>_0x6829c3[_0x9ea0('0x21')]()),this[_0x9ea0('0x57')][_0x9ea0('0x22')](),_0x5d2f80[_0x9ea0('0x3')](this[_0x9ea0('0x3b')]),this[_0x9ea0('0x13')](),this[_0x9ea0('0x27')][_0x9ea0('0x13')](),this['stopListening'](this[_0x9ea0('0x29')][_0x9ea0('0x39')]);for(const _0x5ee777 of Array['from'](this[_0x9ea0('0x31')]))this[_0x9ea0('0x50')](_0x5ee777);window[_0x9ea0('0xa')]('resize',this['_refreshPositioningDebounced']),this[_0x9ea0('0x33')][_0x9ea0('0x19')](),this['_selectedAnnotations']=[],this[_0x9ea0('0x49')]=!0x1,this[_0x9ea0('0x3b')]=null;}[_0x9ea0('0x21')](){this['isAttached']&&this[_0x9ea0('0x15')](),this[_0x9ea0('0x8')][_0x9ea0('0x47')]();}[_0x9ea0('0x54')](_0xf2af5c){const _0x581ec2=_0xf2af5c[_0x9ea0('0x4')][_0x9ea0('0x4a')]('EditorAnnotations'),_0x527c3d=this[_0x9ea0('0x29')][_0x9ea0('0x4')][_0x9ea0('0x4a')](_0x250618),_0x5382fc=this[_0x9ea0('0x3b')],_0x33da23=this[_0x9ea0('0x58')],_0x2bc451=()=>{const _0x26c964=_0x581ec2[_0x9ea0('0x4c')]({'activeAnnotation':this[_0x9ea0('0x2b')],'annotations':this['annotations']});this['_setSelectedAnnotations'](_0x26c964),this[_0x9ea0('0x26')](_0x26c964[0x0]||null);};this[_0x9ea0('0x3a')](_0x581ec2,_0x9ea0('0x28'),_0x2bc451),this['listenTo'](_0x581ec2,'blur',(_0x1d5391,{isAnnotationTracked:_0x5b5015})=>{this[_0x9ea0('0x2b')]&&_0x5b5015(this[_0x9ea0('0x2b')])&&(this['_setSelectedAnnotations']([]),this[_0x9ea0('0x26')](null));}),this[_0x9ea0('0x3a')](_0x581ec2,_0x9ea0('0x30'),()=>{this['_refreshPositioningDebounced']();}),this[_0x9ea0('0x3a')](_0x5382fc,'blur',_0x266833=>{_0x581ec2[_0x9ea0('0x1f')]()&&_0x266833[_0x9ea0('0x5b')]();},{'priority':_0x9ea0('0x1')}),this['_domEmitter'][_0x9ea0('0x3a')](document,'mousedown',(_0x760d7c,_0x28fbb8)=>{const _0x1c82a1=_0x28fbb8[_0x9ea0('0x14')];_0x33da23[_0x9ea0('0x25')]&&_0x33da23['element'][_0x9ea0('0x2c')](_0x1c82a1)||_0x527c3d[_0x9ea0('0x5d')]['element'][_0x9ea0('0x2c')](_0x1c82a1)||this[_0x9ea0('0x2b')]&&_0x581ec2['hasDomSelection']()&&(_0x2bc451(),_0x760d7c[_0x9ea0('0x4b')]=!0x0);},{'priority':_0x9ea0('0x1')}),this['_editorAnnotations'][_0x9ea0('0x9')](_0x581ec2);}[_0x9ea0('0x50')](_0x2168f5){_0x2168f5&&(this['stopListening'](_0x2168f5),this[_0x9ea0('0x31')]['remove'](_0x2168f5));}[_0x9ea0('0x5c')](_0x4f662e){for(const _0x4d08ed of this[_0x9ea0('0x10')])_0x4f662e[_0x9ea0('0x1b')](_0x4d08ed)||this[_0x9ea0('0x17')]['delete'](_0x4d08ed[_0x9ea0('0x5d')]);this['_selectedAnnotations']=_0x4f662e;}[_0x9ea0('0x45')](){const _0x1f8a94=this[_0x9ea0('0x58')];this[_0x9ea0('0x3b')]['refreshPositioning'](),_0x1f8a94[_0x9ea0('0x25')]&&this['_updateBalloonPosition']();}[_0x9ea0('0x7')](_0x1736d4){if(this[_0x9ea0('0x17')]['has'](_0x1736d4[_0x9ea0('0x5d')]))return;const _0x255dba=this['balloonPanelView'][_0x9ea0('0x32')][_0x9ea0('0x2e')];_0x255dba!==_0x1736d4[_0x9ea0('0x5d')]?(_0x255dba&&this['_detachListeners'](_0x255dba),this[_0x9ea0('0x4f')](_0x1736d4['view']),this[_0x9ea0('0x58')]['content'][_0x9ea0('0x22')](),this['balloonPanelView'][_0x9ea0('0x32')]['add'](_0x1736d4['view']),this['_updateBalloonPosition']()):this[_0x9ea0('0x1e')]();}[_0x9ea0('0x1e')](){const _0x27d429=this[_0x9ea0('0x58')][_0x9ea0('0x32')]['first'],_0x425a54=this[_0x9ea0('0x3b')][_0x9ea0('0x2')](_0x27d429);if(!this[_0x9ea0('0x57')][_0x9ea0('0x59')](_0x425a54))return;const _0x5d9b1f=this['_annotationToNarrowView']['get'](_0x425a54)[_0x9ea0('0x3d')],_0x1ae11a=function(){const _0x119a13=_0x2b59da[_0x9ea0('0x51')];return[_0x119a13[_0x9ea0('0x4e')],_0x119a13['northArrowSouthEast'],_0x119a13['southArrowNorth'],_0x119a13['northArrowSouth'],_0x119a13['southArrowNorthWest'],_0x119a13['northArrowSouthWest']];}();this[_0x9ea0('0x58')][_0x9ea0('0x16')]({'target':_0x5d9b1f,'positions':_0x1ae11a});}[_0x9ea0('0x44')](){const _0x4b9328=this[_0x9ea0('0x58')],_0x543802=_0x4b9328[_0x9ea0('0x32')]['first'];_0x543802&&(this[_0x9ea0('0x37')](_0x543802),_0x4b9328[_0x9ea0('0x34')](),_0x4b9328[_0x9ea0('0x32')][_0x9ea0('0x22')]());}[_0x9ea0('0x4f')](_0x115fa1){this[_0x9ea0('0x3a')](_0x115fa1,_0x9ea0('0x2a'),()=>this[_0x9ea0('0x1e')]()),this[_0x9ea0('0x3a')](_0x115fa1,_0x9ea0('0x6'),(_0x4bdd01,_0x74a259)=>{this['_manuallyClosedAnnotationViews'][_0x9ea0('0x9')](_0x115fa1),this[_0x9ea0('0x44')](),_0x74a259();});}[_0x9ea0('0x37')](_0x3f2650){this[_0x9ea0('0x13')](_0x3f2650);}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x8ada=['_activeAnnotation','view','_updateLastItem','listenTo','bind','last','_recalculate','target','container','_getTargetTop','_targetTop','remove','locale','nodeType','_alignToTargetRect','set','destroy','rearrange','_destroySidebarItemView','_setItemTop','delete','sidebar-setcontainer-invalid-element','_alignAfterItem','init','minHeight','class','stopListening','sidebar.preventScrollOutOfView','_attachToContainer','max','render','getIndex','height','getSidebarItemView','element','isAnimationDisabled','_getItemBefore','_lastItem','updateHeight','change:targetRect','length','config','sidebar-attachtocontainer-missing-container','context','add','_getMaxAvailableTop','_alignForTopChange','_createSidebarView','list','top','change:_lastItem','get','_alignBeforeItem','isActive','_sidebarItemViewToAnnotation','push','bottom','_spaceBetweenItems','appendChild','_annotations','_alignForBottomChange','_recalculateBuffer','refresh','sidebar.container','object','targetRect','change:bottom','content','_annotationToSidebarItemView'];(function(_0x3e1bd4,_0x8adaf4){const _0x146dea=function(_0x562de5){while(--_0x562de5){_0x3e1bd4['push'](_0x3e1bd4['shift']());}};_0x146dea(++_0x8adaf4);}(_0x8ada,0x169));const _0x146d=function(_0x3e1bd4,_0x8adaf4){_0x3e1bd4=_0x3e1bd4-0x0;let _0x146dea=_0x8ada[_0x3e1bd4];return _0x146dea;};import{ContextPlugin as _0x1de050}from'ckeditor5/src/core';import _0x25539f from'./view/sidebarview';import _0x238755 from'./view/sidebaritemview';import{Rect as _0x4ed153,CKEditorError as _0x5b7eb3}from'ckeditor5/src/utils';export default class b extends _0x1de050{static get['pluginName'](){return'Sidebar';}constructor(_0x25ba7d){super(_0x25ba7d),this[_0x146d('0x44')](_0x146d('0x15')),this[_0x146d('0x36')]=this[_0x146d('0x1f')](),this[_0x146d('0x44')]('container',null),this[_0x146d('0x29')]=0x19,this['_sidebarItemViewToAnnotation']=new Map(),this['_annotationToSidebarItemView']=new Map(),this[_0x146d('0x1b')][_0x146d('0x19')]['define'](_0x146d('0xb'),!0x1),this[_0x146d('0x2b')]=null,this['_activeAnnotation']=null,this['_recalculateBuffer']=[];}[_0x146d('0x7')](){const _0x5e8079=this[_0x146d('0x1b')]['config'][_0x146d('0x23')](_0x146d('0x2f'));_0x5e8079&&this['setContainer'](_0x5e8079);}['setContainer'](_0x46de98){if(!p(_0x46de98))throw new _0x5b7eb3(_0x146d('0x5'));this[_0x146d('0x3d')]=_0x46de98;}[_0x146d('0xc')]({viewClass:_0x2fee63='',spaceBetweenItems:_0x2acdb0=0x19}={}){if(!p(this[_0x146d('0x3d')]))throw new _0x5b7eb3(_0x146d('0x1a'),this);this[_0x146d('0x3d')][_0x146d('0x2a')](this[_0x146d('0x36')][_0x146d('0x12')]),this[_0x146d('0x36')][_0x146d('0x9')]=_0x2fee63,this['_spaceBetweenItems']=_0x2acdb0;}[_0x146d('0x1')]({removedAnnotation:_0x1ea6f8,previousAnnotation:_0x410208,nextAnnotation:_0x1440f7}){const _0xcec52b=this[_0x146d('0x11')](_0x1ea6f8);this[_0x146d('0x36')][_0x146d('0x20')][_0x146d('0x40')](_0xcec52b),this[_0x146d('0x2')](_0x1ea6f8),_0x410208&&this[_0x146d('0x43')](this['getSidebarItemView'](_0x410208)),_0x1440f7&&this[_0x146d('0x43')](this[_0x146d('0x11')](_0x1440f7)),this[_0x146d('0x37')]();}[_0x146d('0x2e')]({blurredAnnotation:_0x3cca87,activatedAnnotation:_0x68ae86,disableAnimationOnActivatedAnnotation:_0xfd01ea}){if(this[_0x146d('0x35')]=_0x68ae86,_0x3cca87){_0x3cca87[_0x146d('0x25')]=!0x1;const _0x5ca0e5=this['getSidebarItemView'](_0x3cca87);_0x5ca0e5&&_0xfd01ea&&(_0x5ca0e5[_0x146d('0x13')]=!0x1);}if(_0x68ae86){const _0x4835cd=this[_0x146d('0x11')](_0x68ae86);_0x4835cd&&(_0x68ae86[_0x146d('0x25')]=!0x0,_0xfd01ea&&(_0x4835cd[_0x146d('0x13')]=!0x0,_0x4835cd[_0x146d('0x21')]+=0x1),this[_0x146d('0x43')](_0x4835cd));}}['_detachFromContainer'](_0x2f0b52){this[_0x146d('0xa')](),this[_0x146d('0x36')][_0x146d('0x12')][_0x146d('0x40')]();for(const _0x3f2ced of _0x2f0b52)this[_0x146d('0x2')](_0x3f2ced);this[_0x146d('0x36')][_0x146d('0x20')]['clear'](),this[_0x146d('0x36')][_0x146d('0x9')]='',this[_0x146d('0x15')]=null;}['addAnnotation'](_0x32ee34,_0xe00f6e){_0xe00f6e||(_0xe00f6e=_0x32ee34[_0x146d('0x36')]);const _0x19564b=new _0x238755(this[_0x146d('0x1b')][_0x146d('0x41')]);this[_0x146d('0x26')]['set'](_0x19564b,_0x32ee34),this[_0x146d('0x34')][_0x146d('0x44')](_0x32ee34,_0x19564b),_0x19564b[_0x146d('0x33')][_0x146d('0x1c')](_0xe00f6e),this[_0x146d('0x38')](_0x32ee34['view'],_0x146d('0x17'),(_0x1ab4b8,_0x1b2b5e,_0x4fc90c)=>{const _0x5d3c35=this[_0x146d('0x3e')](_0x32ee34,_0x4fc90c);_0x19564b[_0x146d('0x3f')]!=_0x5d3c35&&(_0x19564b[_0x146d('0x3f')]=_0x5d3c35,this[_0x146d('0x3')](_0x19564b,_0x5d3c35));}),this[_0x146d('0x38')](_0x19564b,'change:top',()=>{this[_0x146d('0x3b')](_0x19564b,'top');}),this['listenTo'](_0x19564b,_0x146d('0x32'),()=>{this[_0x146d('0x3b')](_0x19564b,'bottom');}),this['_alignToTargetRect'](_0x19564b);const _0x1e7ee3=this[_0x146d('0x14')](_0x19564b);if(_0x1e7ee3)this[_0x146d('0x6')](_0x1e7ee3,_0x19564b)||this['_alignToTargetRect'](_0x19564b);else this[_0x146d('0x43')](_0x19564b);return this[_0x146d('0x37')](),this[_0x146d('0x36')][_0x146d('0x20')]['add'](_0x19564b),_0x19564b;}[_0x146d('0x1e')](_0x42a3c5){if(!_0x42a3c5[_0x146d('0x33')][_0x146d('0x18')])return;const _0x3150d9=this[_0x146d('0x14')](_0x42a3c5);if(!_0x3150d9)return;const _0x2eaf8b=this['_sidebarItemViewToAnnotation'][_0x146d('0x23')](_0x3150d9),_0x3a9c94=this[_0x146d('0x35')];_0x3a9c94&&_0x3a9c94===_0x2eaf8b?this['_alignAfterItem'](_0x3150d9,_0x42a3c5):this[_0x146d('0x24')](_0x42a3c5,_0x3150d9);}[_0x146d('0x2c')](_0x3fa1f6){if(!_0x3fa1f6[_0x146d('0x33')]['length'])return;const _0x30db27=this['_getItemAfter'](_0x3fa1f6);if(!_0x30db27)return;const _0x14db2f=this[_0x146d('0x26')]['get'](_0x30db27),_0x45a067=this['context'][_0x146d('0x19')][_0x146d('0x23')]('sidebar.preventScrollOutOfView'),_0x54dfa1=this['_activeAnnotation'];_0x54dfa1&&_0x54dfa1===_0x14db2f&&_0x45a067?(this[_0x146d('0x24')](_0x30db27,_0x3fa1f6),this[_0x146d('0x6')](_0x3fa1f6,_0x30db27)):_0x54dfa1&&_0x54dfa1===_0x14db2f?this[_0x146d('0x24')](_0x30db27,_0x3fa1f6):this[_0x146d('0x6')](_0x3fa1f6,_0x30db27);}['_recalculate'](_0x5e2ef6,_0x182e54){0x0===this[_0x146d('0x2d')][_0x146d('0x18')]&&setTimeout(()=>{for(const {sidebarItemView:_0x24e96f,changedProp:_0x29c2ef}of this[_0x146d('0x2d')])_0x146d('0x21')===_0x29c2ef?this['_alignForTopChange'](_0x24e96f):this['_alignForBottomChange'](_0x24e96f);this[_0x146d('0x2d')]=[];},0xa),this[_0x146d('0x2d')][_0x146d('0x27')]({'sidebarItemView':_0x5e2ef6,'changedProp':_0x182e54});}['getSidebarItemView'](_0x2ce442){return this['_annotationToSidebarItemView'][_0x146d('0x23')](_0x2ce442);}['destroy'](){this['view'][_0x146d('0x0')]();}[_0x146d('0x2')](_0x36edb1){const _0x2857c5=this[_0x146d('0x11')](_0x36edb1);this['stopListening'](_0x2857c5),this['stopListening'](_0x36edb1[_0x146d('0x36')]),_0x2857c5[_0x146d('0x0')](),this['_annotationToSidebarItemView'][_0x146d('0x4')](_0x36edb1),this['_sidebarItemViewToAnnotation'][_0x146d('0x4')](_0x2857c5);}[_0x146d('0x1f')](){const _0x1b9f3c=new _0x25539f(this[_0x146d('0x1b')][_0x146d('0x41')]);return _0x1b9f3c[_0x146d('0xe')](),this['on'](_0x146d('0x22'),(_0x30dc67,_0x2410fc,_0x58af5a,_0x436b2d)=>{_0x436b2d&&_0x1b9f3c['unbind'](_0x146d('0x8')),_0x58af5a?_0x1b9f3c[_0x146d('0x39')](_0x146d('0x8'))['to'](_0x58af5a,_0x146d('0x28')):_0x1b9f3c['minHeight']=null;}),_0x1b9f3c;}[_0x146d('0x37')](){this[_0x146d('0x15')]=this[_0x146d('0x11')](this[_0x146d('0x2b')][_0x146d('0x3a')]);}['_getItemBefore'](_0x135a1d){const _0x59553f=this[_0x146d('0x26')][_0x146d('0x23')](_0x135a1d),_0x12cf73=this[_0x146d('0x2b')][_0x146d('0x23')](this[_0x146d('0x2b')][_0x146d('0xf')](_0x59553f)-0x1);return _0x12cf73&&this['getSidebarItemView'](_0x12cf73);}['_getItemAfter'](_0xf0041e){const _0x5391d0=this[_0x146d('0x26')][_0x146d('0x23')](_0xf0041e),_0x1ebad6=this[_0x146d('0x2b')][_0x146d('0x23')](this[_0x146d('0x2b')][_0x146d('0xf')](_0x5391d0)+0x1);return _0x1ebad6&&this[_0x146d('0x11')](_0x1ebad6);}[_0x146d('0x24')](_0x3f42ef,_0x829fc6){_0x3f42ef[_0x146d('0x16')]();const _0x5ef425=F(_0x829fc6[_0x146d('0x28')]+this['_spaceBetweenItems'],_0x3f42ef[_0x146d('0x21')]);return!!_0x5ef425&&(this[_0x146d('0x3')](_0x829fc6,_0x829fc6[_0x146d('0x21')]-_0x5ef425),!0x0);}['_alignAfterItem'](_0x479734,_0x104e51){_0x479734['updateHeight']();const _0x2f3720=F(_0x479734[_0x146d('0x28')]+this[_0x146d('0x29')],_0x104e51['top']);return!!_0x2f3720&&(this[_0x146d('0x3')](_0x104e51,_0x104e51[_0x146d('0x21')]+_0x2f3720,!0x1),!0x0);}[_0x146d('0x43')](_0x300360){const _0x51bd7c=this['_sidebarItemViewToAnnotation'][_0x146d('0x23')](_0x300360);if(!_0x51bd7c||!_0x51bd7c[_0x146d('0x3c')])return;const _0x51000a=this[_0x146d('0x3e')](_0x51bd7c,_0x51bd7c[_0x146d('0x31')]);this[_0x146d('0x3')](_0x300360,_0x51000a);}['_getTargetTop'](_0x677795,_0x25784a){if(null===_0x25784a)return 0x0;if(_0x677795[_0x146d('0x3c')]instanceof _0x4ed153)return _0x25784a['top'];{const _0xb984f3=new _0x4ed153(this[_0x146d('0x36')][_0x146d('0x12')])['top'];return _0x25784a[_0x146d('0x21')]-_0xb984f3;}}[_0x146d('0x3')](_0x1cd37b,_0x2a40c3,_0x514bbc=this['context'][_0x146d('0x19')][_0x146d('0x23')](_0x146d('0xb'))){_0x514bbc&&(_0x2a40c3=Math['max'](_0x2a40c3,this[_0x146d('0x1d')](_0x1cd37b))),_0x1cd37b[_0x146d('0x21')]=_0x2a40c3;}['_getMaxAvailableTop'](_0x4d3588){let _0x4e0b81=this['_getItemBefore'](_0x4d3588),_0x6ef36e=0x0;for(;_0x4e0b81;)_0x4e0b81[_0x146d('0x16')](),_0x6ef36e+=this[_0x146d('0x29')]+_0x4e0b81[_0x146d('0x10')],_0x4e0b81=this[_0x146d('0x14')](_0x4e0b81);return _0x6ef36e;}}function F(_0x32e4eb,_0x12a842){return Math[_0x146d('0xd')](_0x32e4eb-_0x12a842,0x0);}function p(_0x2ccf4f){return null!==_0x2ccf4f&&_0x146d('0x30')==typeof _0x2ccf4f&&0x1===_0x2ccf4f[_0x146d('0x42')];}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x351e=['ck-annotation-counter__badge--edit-mode','...','add','counterView','children','ck-annotation-counter__badge--','_badge','annotationType','icon','number','isDirty','extendTemplate','ck-annotation-counter','bind','set'];(function(_0x37a05f,_0x351ed2){const _0x5d35b3=function(_0x2a9091){while(--_0x2a9091){_0x37a05f['push'](_0x37a05f['shift']());}};_0x5d35b3(++_0x351ed2);}(_0x351e,0x14d));const _0x5d35=function(_0x37a05f,_0x351ed2){_0x37a05f=_0x37a05f-0x0;let _0x5d35b3=_0x351e[_0x37a05f];return _0x5d35b3;};import{ButtonView as _0x4f288f,View as _0x1a58b2}from'ckeditor5/src/ui';import _0x2cb0a1 from'../../../theme/icons/add-comment.svg';export default class z extends _0x4f288f{constructor(_0x3b3cfe){super(_0x3b3cfe);const _0x4f8efa=this['bindTemplate'];this[_0x5d35('0xb')](_0x5d35('0x7'),!0x1),this['set'](_0x5d35('0x6'),0x0),this[_0x5d35('0xa')](_0x5d35('0x3'))['to'](this,_0x5d35('0x7'),this,_0x5d35('0x6'),(_0x46cf07,_0x1b5039)=>_0x46cf07?_0x5d35('0xd'):_0x1b5039),this[_0x5d35('0xb')](_0x5d35('0x4'),''),this[_0x5d35('0x5')]=_0x2cb0a1,this[_0x5d35('0x8')]({'attributes':{'class':[_0x5d35('0x9')]}}),this[_0x5d35('0x0')]=new _0x1a58b2(),this[_0x5d35('0x0')]['setTemplate']({'tag':'span','attributes':{'class':['ck-annotation-counter__badge',_0x4f8efa['to'](_0x5d35('0x4'),_0x56d804=>_0x5d35('0x2')+_0x56d804),_0x4f8efa['if'](_0x5d35('0x7'),_0x5d35('0xc'))]},'children':[{'text':_0x4f8efa['to']('_badge')}]}),this[_0x5d35('0x1')][_0x5d35('0xe')](this[_0x5d35('0x0')]);}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x12f3=['ck-annotation-wrapper','focusTracker','type','mainView','render','setTemplate','Esc','bindTemplate','keystrokes','div','_mutationObserver','isActive','detach','height','element','set','attach','content','length','add','focus','ck-rounded-corners','targetRect','ck-annotation-wrapper--active','destroy','_updateHeight','clientHeight','listenTo'];(function(_0x23e9d0,_0x12f3cb){const _0x19dc07=function(_0x23b752){while(--_0x23b752){_0x23e9d0['push'](_0x23e9d0['shift']());}};_0x19dc07(++_0x12f3cb);}(_0x12f3,0xfa));const _0x19dc=function(_0x23e9d0,_0x12f3cb){_0x23e9d0=_0x23e9d0-0x0;let _0x19dc07=_0x12f3[_0x23e9d0];return _0x19dc07;};import{View as _0x5a6d9f}from'ckeditor5/src/ui';import{FocusTracker as _0x4485c1,KeystrokeHandler as _0x35e035,uid as _0x19d982}from'ckeditor5/src/utils';import _0x5ad404 from'../../utils/createmutationobserver';import'../../../theme/annotation.css';export default class v extends _0x5a6d9f{constructor(_0x43819c,_0x88d993){super(_0x43819c),this['id']=_0x19d982(),this[_0x19dc('0x3')]=new _0x4485c1(),this[_0x19dc('0xa')]=new _0x35e035(),this[_0x19dc('0xa')][_0x19dc('0x11')](_0x19dc('0x8'),(_0x2257e0,_0x27aa7e)=>this['fire']('Esc',_0x27aa7e)),this[_0x19dc('0x11')](_0x19dc('0x18'),{'top':0x0,'right':0x0,'bottom':0x0,'left':0x0}),this[_0x19dc('0x11')](_0x19dc('0xf'),0x0),this[_0x19dc('0x11')]('isActive',!0x1),this[_0x19dc('0x11')]('isDirty',!0x1),this['set'](_0x19dc('0x14'),0x0),this[_0x19dc('0x11')](_0x19dc('0x4'),''),this[_0x19dc('0xc')]=_0x5ad404(()=>this[_0x19dc('0x1b')]()),this[_0x19dc('0x13')]=this['createCollection'](),this[_0x19dc('0x13')][_0x19dc('0x15')](_0x88d993),this[_0x19dc('0x5')]=_0x88d993;const _0x16f275=this[_0x19dc('0x9')];this[_0x19dc('0x7')]({'tag':_0x19dc('0xb'),'attributes':{'class':['ck',_0x19dc('0x2'),_0x19dc('0x17'),_0x16f275['if'](_0x19dc('0xd'),_0x19dc('0x19'))],'tabindex':-0x1},'children':this[_0x19dc('0x13')]});}['render'](){super[_0x19dc('0x6')](),this['focusTracker'][_0x19dc('0x15')](this['element']),this[_0x19dc('0xa')][_0x19dc('0x1')](this['element']),this[_0x19dc('0xc')][_0x19dc('0x12')](this[_0x19dc('0x10')]);}['destroy'](){this[_0x19dc('0x13')]['clear'](),this['keystrokes']['destroy'](),this[_0x19dc('0x3')][_0x19dc('0x1a')](),this['_mutationObserver'][_0x19dc('0xe')](),super[_0x19dc('0x1a')]();}['focus'](){this[_0x19dc('0x10')][_0x19dc('0x16')]();}[_0x19dc('0x1b')](){const _0x226c5b=this[_0x19dc('0x10')][_0x19dc('0x0')];_0x226c5b&&(this[_0x19dc('0xf')]=_0x226c5b);}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x4656=['_targetTop','destroy','height','render','isAnimationDisabled','bottom','_mutationObserver','bind','element','setTemplate','clientHeight','attach','set','top','content','detach','updateHeight','div'];(function(_0x5afca8,_0x46569a){const _0x5d5b73=function(_0x428e7c){while(--_0x428e7c){_0x5afca8['push'](_0x5afca8['shift']());}};_0x5d5b73(++_0x46569a);}(_0x4656,0x1e2));const _0x5d5b=function(_0x5afca8,_0x46569a){_0x5afca8=_0x5afca8-0x0;let _0x5d5b73=_0x4656[_0x5afca8];return _0x5d5b73;};import{View as _0x137472}from'ckeditor5/src/ui';import{toUnit as _0x4737c1}from'ckeditor5/src/utils';import _0x397622 from'../../utils/createmutationobserver';const kt=_0x4737c1('px');export default class C extends _0x137472{constructor(_0x51f46a){super(_0x51f46a),this[_0x5d5b('0x10')](_0x5d5b('0x11')),this[_0x5d5b('0x10')](_0x5d5b('0x6'),0x0),this[_0x5d5b('0xb')](_0x5d5b('0x9'))['to'](this,_0x5d5b('0x11'),this,_0x5d5b('0x6'),(_0x31f5e8,_0x2cf667)=>(_0x31f5e8||0x0)+_0x2cf667),this[_0x5d5b('0x10')]('isAnimationDisabled',!0x1),this[_0x5d5b('0xa')]=_0x397622(()=>this[_0x5d5b('0x2')]()),this[_0x5d5b('0x4')]=null,this['content']=this['createCollection']();const _0x3a9f78=this['bindTemplate'];this[_0x5d5b('0xd')]({'tag':_0x5d5b('0x3'),'attributes':{'class':['ck-sidebar-item',_0x3a9f78['to'](_0x5d5b('0x8'),_0x476fd0=>_0x476fd0?'ck-sidebar-item--no-animation':'')],'style':{'top':_0x3a9f78['to'](_0x5d5b('0x11'),kt)}},'children':this[_0x5d5b('0x0')]});}[_0x5d5b('0x7')](){super['render'](),this[_0x5d5b('0xa')][_0x5d5b('0xf')](this[_0x5d5b('0xc')]);}[_0x5d5b('0x2')](){const _0x4d4f8f=this[_0x5d5b('0xc')][_0x5d5b('0xe')];_0x4d4f8f&&(this[_0x5d5b('0x6')]=_0x4d4f8f);}[_0x5d5b('0x5')](){this[_0x5d5b('0x0')]['clear'](),this[_0x5d5b('0xa')][_0x5d5b('0x1')](),super['destroy']();}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x406d=['class','div','minHeight','set','setTemplate','list','bindTemplate','createCollection','ck-sidebar'];(function(_0x5ad2b4,_0x406d79){const _0x56684e=function(_0x22eb5a){while(--_0x22eb5a){_0x5ad2b4['push'](_0x5ad2b4['shift']());}};_0x56684e(++_0x406d79);}(_0x406d,0x1e1));const _0x5668=function(_0x5ad2b4,_0x406d79){_0x5ad2b4=_0x5ad2b4-0x0;let _0x56684e=_0x406d[_0x5ad2b4];return _0x56684e;};import{View as _0x486540}from'ckeditor5/src/ui';import{toUnit as _0x4f8c38}from'ckeditor5/src/utils';import'../../../theme/sidebar.css';const kt=_0x4f8c38('px');export default class T extends _0x486540{constructor(_0x1cafff){super(_0x1cafff);const _0x4ec8ed=this[_0x5668('0x2')];this[_0x5668('0x8')](_0x5668('0x7'),0x0),this[_0x5668('0x8')](_0x5668('0x5'),''),this[_0x5668('0x1')]=this[_0x5668('0x3')](),this[_0x5668('0x0')]({'tag':_0x5668('0x6'),'attributes':{'class':['ck',_0x5668('0x4'),'ck-reset',_0x4ec8ed['to'](_0x5668('0x5'))],'style':{'minHeight':_0x4ec8ed['to'](_0x5668('0x7'),_0x31de81=>_0x31de81?kt(_0x31de81+0xa):null)}},'children':this[_0x5668('0x1')]});}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0xce80=['EditorAnnotations','WideSidebar','blur','listenTo','removeEventListener','widesidebar-detach-not-attached','_refreshPositioningDebounced','pluginName','change:container','off','_destroyEditorAnnotationsIntegration','init','_integrateWithEditorAnnotations','register','add','switchTo','_detachFromContainer','annotations','stop','from','cancel','refreshPositioning','addEventListener','editors','_activeAnnotation','resize','setActiveAnnotation','get','addAnnotation','plugins','stopListening','refresh','activeAnnotation','isAttached','remove','_editorAnnotations','set','ready','container','Sidebar','detach','getOrderedSelectedAnnotations','high','attach','_attachToContainer','ck-sidebar--wide','context'];(function(_0x1fe293,_0xce80a3){const _0x21b478=function(_0x5d8c2a){while(--_0x5d8c2a){_0x1fe293['push'](_0x1fe293['shift']());}};_0x21b478(++_0xce80a3);}(_0xce80,0xea));const _0x21b4=function(_0x1fe293,_0xce80a3){_0x1fe293=_0x1fe293-0x0;let _0x21b478=_0xce80[_0x1fe293];return _0x21b478;};import{ContextPlugin as _0xbba118}from'ckeditor5/src/core';import _0x536d98 from'./annotationsuis';import _0x49cd70 from'./sidebar';import{CKEditorError as _0x104809,Collection as _0x87f93}from'ckeditor5/src/utils';import{debounce as _0x1befe7}from'lodash-es';export default class i extends _0xbba118{static get['requires'](){return[_0x49cd70,_0x536d98];}static get[_0x21b4('0x8')](){return _0x21b4('0x2');}constructor(_0x24e161){super(_0x24e161),this[_0x21b4('0x22')]=!0x1,this[_0x21b4('0x25')]('activeAnnotation',null),this[_0x21b4('0x12')]=null,this[_0x21b4('0x24')]=new _0x87f93(),this[_0x21b4('0x7')]=_0x1befe7(()=>{this[_0x21b4('0x12')][_0x21b4('0x16')]();},0xfa,{'leading':!0x1});}[_0x21b4('0xc')](){const _0x41b6f4=this[_0x21b4('0x0')][_0x21b4('0x1e')]['get'](_0x536d98),_0x4f14f8=this[_0x21b4('0x0')][_0x21b4('0x1e')][_0x21b4('0x1c')](_0x49cd70);_0x41b6f4[_0x21b4('0xe')]('wideSidebar',this),_0x4f14f8[_0x21b4('0x27')]&&_0x41b6f4[_0x21b4('0x10')]('wideSidebar');}[_0x21b4('0x1b')](_0x590058){if(_0x590058===this[_0x21b4('0x21')])return;const _0x210ad2=this[_0x21b4('0x0')][_0x21b4('0x1e')][_0x21b4('0x1c')](_0x49cd70);_0x210ad2[_0x21b4('0x19')]=_0x590058;const _0x38544e=this[_0x21b4('0x21')];this[_0x21b4('0x21')]=_0x590058,_0x210ad2[_0x21b4('0x20')]({'blurredAnnotation':_0x38544e,'activatedAnnotation':this[_0x21b4('0x21')]});}['attach'](_0x10adec){this[_0x21b4('0x12')]=_0x10adec;const _0x4ba0e0=this['context'][_0x21b4('0x1e')]['get'](_0x21b4('0x28'));if(_0x4ba0e0['_annotations']=_0x10adec,this[_0x21b4('0x22')])throw new _0x104809('widesidebar-attach-already-attached',this);this[_0x21b4('0x22')]=!0x0,this[_0x21b4('0x4')](_0x4ba0e0,'set:container',()=>{this[_0x21b4('0x29')](),this[_0x21b4('0x4')](_0x4ba0e0,_0x21b4('0x9'),_0x518734=>{_0x518734[_0x21b4('0xa')](),this[_0x21b4('0x2c')](_0x10adec);});}),_0x4ba0e0[_0x21b4('0x2d')]({'viewClass':_0x21b4('0x2e')});const _0x247e75=_0x265992=>{_0x265992['updateTargetRect'](),_0x4ba0e0[_0x21b4('0x1d')](_0x265992);};for(const _0x4549c7 of _0x10adec)_0x247e75(_0x4549c7);this[_0x21b4('0x4')](_0x10adec,_0x21b4('0xf'),(_0x5a2a1b,_0x36bd25)=>{_0x247e75(_0x36bd25);}),this[_0x21b4('0x4')](_0x10adec,'remove',(_0x1f33ff,_0x5ec0a6,_0x3aaa5b)=>{_0x4ba0e0['rearrange']({'removedAnnotation':_0x5ec0a6,'previousAnnotation':_0x10adec[_0x21b4('0x1c')](_0x3aaa5b-0x1),'nextAnnotation':_0x10adec[_0x21b4('0x1c')](_0x3aaa5b+0x1)}),_0x5ec0a6===this[_0x21b4('0x21')]&&this[_0x21b4('0x1b')](null);},{'priority':_0x21b4('0x2b')}),this[_0x21b4('0x4')](_0x10adec,'focus',(_0x276af5,_0x5b619c)=>{this[_0x21b4('0x1b')](_0x5b619c);}),this[_0x21b4('0x4')](_0x10adec,_0x21b4('0x3'),()=>{this['setActiveAnnotation'](null);});const _0x260f6f=this['context']['editors']?this[_0x21b4('0x0')]['editors']:new _0x87f93([this[_0x21b4('0x0')]]);for(const _0x25a1a3 of _0x260f6f)this[_0x21b4('0xd')](_0x25a1a3);this['listenTo'](_0x260f6f,_0x21b4('0xf'),(_0x1e5fe3,_0x29cf36)=>{this[_0x21b4('0x4')](_0x29cf36,_0x21b4('0x26'),()=>{this[_0x21b4('0xd')](_0x29cf36);});}),this[_0x21b4('0x4')](_0x260f6f,_0x21b4('0x23'),(_0x2ff590,_0x9d3ec2)=>{_0x9d3ec2[_0x21b4('0x1e')]['has'](_0x21b4('0x1'))&&this[_0x21b4('0xb')](_0x9d3ec2['plugins']['get'](_0x21b4('0x1')));}),window[_0x21b4('0x17')](_0x21b4('0x1a'),this['_refreshPositioningDebounced']),this['annotations']['refreshPositioning']();}[_0x21b4('0x29')](){if(!this[_0x21b4('0x22')])throw new _0x104809(_0x21b4('0x6'),this);this[_0x21b4('0x1b')](null);const _0x36e90f=this[_0x21b4('0x0')][_0x21b4('0x1e')]['get'](_0x49cd70);_0x36e90f[_0x21b4('0x11')](this['annotations']),this[_0x21b4('0x1f')](_0x36e90f),this[_0x21b4('0x1f')](this[_0x21b4('0x12')]),this[_0x21b4('0x1f')](this[_0x21b4('0x0')][_0x21b4('0x18')]);for(const _0x318b7a of Array[_0x21b4('0x14')](this['_editorAnnotations']))this[_0x21b4('0xb')](_0x318b7a);window[_0x21b4('0x5')](_0x21b4('0x1a'),this[_0x21b4('0x7')]),this['_refreshPositioningDebounced'][_0x21b4('0x15')](),this[_0x21b4('0x21')]=null,this[_0x21b4('0x22')]=!0x1,this[_0x21b4('0x12')]=null;}['destroy'](){this[_0x21b4('0x22')]&&this['detach']();}[_0x21b4('0xd')](_0x4d65ed){const _0x47f0a3=_0x4d65ed[_0x21b4('0x1e')][_0x21b4('0x1c')]('EditorAnnotations');if(!_0x47f0a3)return;const _0x4dc2d5=()=>{const _0x4911b1=_0x47f0a3[_0x21b4('0x2a')]({'annotations':this[_0x21b4('0x12')],'activeAnnotation':this[_0x21b4('0x21')]});this[_0x21b4('0x1b')](_0x4911b1[0x0]||null);};this[_0x21b4('0x4')](_0x47f0a3,_0x21b4('0x20'),_0x4dc2d5),this[_0x21b4('0x4')](_0x47f0a3,_0x21b4('0x3'),(_0x220d29,{isAnnotationTracked:_0x5bdac2})=>{this[_0x21b4('0x21')]&&_0x5bdac2(this['activeAnnotation'])&&this[_0x21b4('0x1b')](null);}),this[_0x21b4('0x4')](_0x47f0a3,'uiUpdate',()=>{this['_refreshPositioningDebounced']();}),this[_0x21b4('0x4')](this[_0x21b4('0x12')],_0x21b4('0x3'),_0x4ab315=>{_0x47f0a3['hasDomSelection']()&&(_0x4dc2d5(),_0x4ab315[_0x21b4('0x13')]());},{'priority':'high'}),this['_editorAnnotations']['add'](_0x47f0a3);}[_0x21b4('0xb')](_0x3b3841){_0x3b3841&&(this[_0x21b4('0x1f')](_0x3b3841),this['_editorAnnotations']['remove'](_0x3b3841));}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const _0x3cb7=['getItems','push','backward','selection','tableCell','_hasContent','isEnabled','getLastMatchingPosition','document','createRange','getRanges','addMarker','isObject','_trimToContent','model','change','execute','element','substr','editor','item','_itemIsContent','comment:'];(function(_0xb53314,_0x3cb733){const _0x37fdcd=function(_0x1fa983){while(--_0x1fa983){_0xb53314['push'](_0xb53314['shift']());}};_0x37fdcd(++_0x3cb733);}(_0x3cb7,0x93));const _0x37fd=function(_0xb53314,_0x3cb733){_0xb53314=_0xb53314-0x0;let _0x37fdcd=_0x3cb7[_0xb53314];return _0x37fdcd;};import{Command as _0x15b164}from'ckeditor5/src/core';import{uid as _0x9c194}from'ckeditor5/src/utils';export default class j extends _0x15b164{['refresh'](){const _0x5b2dd4=this[_0x37fd('0xa')][_0x37fd('0x5')][_0x37fd('0x16')][_0x37fd('0x11')];for(const _0x3c3fd9 of _0x5b2dd4['getRanges']())if(this[_0x37fd('0x13')](_0x3c3fd9))return void(this[_0x37fd('0x14')]=!0x0);this[_0x37fd('0x14')]=!0x1;}[_0x37fd('0x7')]({threadId:_0x25cba9=_0x9c194()}={}){const _0x302a0a=this[_0x37fd('0xa')][_0x37fd('0x5')],_0x22ab2e=[];for(const _0x30b768 of _0x302a0a[_0x37fd('0x16')][_0x37fd('0x11')][_0x37fd('0x1')]())this['_hasContent'](_0x30b768)&&_0x22ab2e[_0x37fd('0xf')](this[_0x37fd('0x4')](_0x30b768));_0x302a0a[_0x37fd('0x6')](_0x5ddc20=>{for(const _0x11362e of _0x22ab2e){const _0x34677d=_0x9c194()[_0x37fd('0x9')](0x1,0x5),_0x3b882e=_0x37fd('0xd')+_0x25cba9+':'+_0x34677d;_0x5ddc20[_0x37fd('0x2')](_0x3b882e,{'range':_0x11362e,'usingOperation':!0x1,'affectData':!0x1});}});}['_hasContent'](_0x2ab203){for(const _0x33ea7f of _0x2ab203[_0x37fd('0xe')]())if(this['_itemIsContent'](_0x33ea7f))return!0x0;return!0x1;}[_0x37fd('0xc')](_0x784629){return _0x784629['is']('textProxy')||this['editor'][_0x37fd('0x5')]['schema'][_0x37fd('0x3')](_0x784629)&&!_0x784629['is'](_0x37fd('0x8'),_0x37fd('0x12'));}[_0x37fd('0x4')](_0x4b4475){const _0x11198b=_0x502454=>!this['_itemIsContent'](_0x502454[_0x37fd('0xb')]),_0x4dc898=_0x4b4475['start'][_0x37fd('0x15')](_0x11198b),_0xe7cf70=_0x4b4475['end'][_0x37fd('0x15')](_0x11198b,{'direction':_0x37fd('0x10')});return this[_0x37fd('0xa')]['model'][_0x37fd('0x0')](_0x4dc898,_0xe7cf70);}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x3576=['getByInnerView','isObject','model','config','state','change','change:isReadOnly','createRange','editor','Annotations','createElement','getCommentThread','once','hasContent','push','text','collaboration.channelId','editing','_initializeMarkerConverters','dataToMarker','comment','for','_handleMarkerAddAndRemove','upcast','end','stop','get','listenTo','$marker','delete','differ','rootName','getAttribute','top','size','removeCommentThread','data','createPositionBefore','map','switchReadOnly','low','view','editingDowncast','plugins','change:isThreadsLoadingPaused','sort','destroyed','getChangedMarkers','ck-comment-marker','includes','$graveyard','root','hasMarkerForId','has','left','pluginName','reconvertMarker','_attachMarkerToThread','attachTo','hasCommentThread','init','markerToData','isThreadsLoadingPaused','getAllMarkersForId','schema','set','conversion','updateMarker','_detachCommentThread','length','split','markers','CommentsRepository','document','ready','update:comment','start','addComment','addCommentThread','_attachedThreads','name','isCollapsed','ck-comment-marker--active','registerAnnotation','registerPostFixer','affectsData','getWalker','CommentsEditing','add','destroy','openNewCommentThread','activeMarker','getCommentThreads','change:activeMarker','newRange','commands'];(function(_0x1969a1,_0x3576b0){const _0x27f78f=function(_0x1f5fdb){while(--_0x1f5fdb){_0x1969a1['push'](_0x1969a1['shift']());}};_0x27f78f(++_0x3576b0);}(_0x3576,0xce));const _0x27f7=function(_0x1969a1,_0x3576b0){_0x1969a1=_0x1969a1-0x0;let _0x27f78f=_0x3576[_0x1969a1];return _0x27f78f;};import{Plugin as _0x3bbf7f}from'ckeditor5/src/core';import{Rect as _0x5a49bb}from'ckeditor5/src/utils';import _0x2e0be1 from'./commentsrepository';import _0x1c27e3 from'./addcommentthreadcommand';import{getMarkerDomElement as _0x696325}from'ckeditor5-collaboration/src/collaboration-core';import _0x3ed7c4 from'../annotations/editorannotations';import _0x21e1ef from'./integrations/commentsrestrictededitingmode';import'../../theme/commentmarker.css';import _0x4578f2 from'./integrations/importword';export default class r extends _0x3bbf7f{static get['requires'](){return[_0x2e0be1,_0x3ed7c4,_0x21e1ef,_0x4578f2];}static get[_0x27f7('0x29')](){return _0x27f7('0x49');}constructor(_0x2e35ff){super(_0x2e35ff),this[_0x27f7('0x33')]('isThreadsLoadingPaused',!0x0),_0x2e35ff[_0x27f7('0x16')][_0x27f7('0x5e')](_0x27f7('0x3c'),()=>this['isThreadsLoadingPaused']=!0x1),this[_0x27f7('0x33')](_0x27f7('0x4d'),null),this['on'](_0x27f7('0x4f'),(_0x4c50fe,_0x5e94d1,_0x49481b,_0x275eca)=>{_0x2e35ff[_0x27f7('0x54')][_0x27f7('0x57')](()=>{if(_0x49481b){const {id:_0x16c8be}=H(_0x49481b),_0x10bffb=this[_0x27f7('0x31')](_0x16c8be);for(const _0x417081 of _0x10bffb)_0x2e35ff[_0x27f7('0x3')][_0x27f7('0x2a')](_0x417081);}if(_0x275eca){const {id:_0x20a991}=H(_0x275eca),_0x7df943=this[_0x27f7('0x31')](_0x20a991);for(const _0x3112f7 of _0x7df943)_0x2e35ff[_0x27f7('0x3')]['reconvertMarker'](_0x3112f7);}});}),this['_attachedThreads']=new Map();}[_0x27f7('0x2e')](){const _0xd44e2e=this[_0x27f7('0x5a')],_0x4e36e0=_0xd44e2e[_0x27f7('0x1d')][_0x27f7('0xc')]('CommentsRepository'),_0x121156=_0xd44e2e[_0x27f7('0x55')][_0x27f7('0xc')](_0x27f7('0x2'));_0xd44e2e[_0x27f7('0x51')][_0x27f7('0x4a')](_0x27f7('0x40'),new _0x1c27e3(_0xd44e2e)),this[_0x27f7('0xd')](_0xd44e2e,_0x27f7('0x58'),(_0x45b77b,_0x3c98c6,_0x7db65d)=>{_0x4e36e0[_0x27f7('0x19')](_0x7db65d,_0xd44e2e[_0x27f7('0x55')][_0x27f7('0xc')](_0x27f7('0x2')));}),this[_0x27f7('0xd')](_0x4e36e0,G(_0x27f7('0x15'),_0x121156),(_0x6b8440,{threadId:_0x3db3da})=>{_0xd44e2e[_0x27f7('0x54')][_0x27f7('0x57')](_0x3d4026=>{for(const _0x56a302 of this[_0x27f7('0x31')](_0x3db3da))_0x3d4026['removeMarker'](_0x56a302);});const _0x365840=_0x4e36e0['getCommentThread'](_0x3db3da);_0x4e36e0[_0x27f7('0x2d')](_0x3db3da)&&!_0x365840[_0x27f7('0x37')]||_0x6b8440[_0x27f7('0xb')]();},{'priority':'high'}),this[_0x27f7('0xd')](_0x4e36e0,G(_0x27f7('0x3f'),_0x121156),(_0x181ccd,{threadId:_0x281d31,isFromAdapter:_0x4b4c16})=>{const _0xae2957=this['getAllMarkersForId'](_0x281d31);if(_0x4b4c16||0x0==_0xae2957['length']||!_0x4e36e0[_0x27f7('0x2d')](_0x281d31))return;0x1===_0x4e36e0['getCommentThread'](_0x281d31)[_0x27f7('0x37')]&&_0xd44e2e[_0x27f7('0x54')][_0x27f7('0x57')](_0x54555a=>{for(const _0x268dc0 of _0xae2957)_0x54555a[_0x27f7('0x35')](_0x268dc0,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this[_0x27f7('0x4')](),this[_0x27f7('0x8')]();}['destroy'](){const _0x477a82=this[_0x27f7('0x5a')][_0x27f7('0x1d')][_0x27f7('0xc')](_0x27f7('0x3a')),_0x233fd0=this[_0x27f7('0x5a')]['config'][_0x27f7('0xc')](_0x27f7('0x2'));for(const _0x405753 of _0x477a82[_0x27f7('0x4e')]({'channelId':_0x233fd0}))_0x477a82[_0x27f7('0x36')](_0x405753['id']),_0x477a82['_threads']['delete'](_0x405753['id']);super[_0x27f7('0x4b')]();}['hasMarkerForId'](_0xb8e9dc){return this[_0x27f7('0x31')](_0xb8e9dc)[_0x27f7('0x37')]>0x0;}[_0x27f7('0x31')](_0xac69a5){return(this[_0x27f7('0x41')][_0x27f7('0xc')](_0xac69a5)||[])[_0x27f7('0x18')](_0x58172e=>this['editor'][_0x27f7('0x54')][_0x27f7('0x39')][_0x27f7('0xc')](_0x58172e))['filter'](_0xe5fad4=>_0xe5fad4);}[_0x27f7('0x4')](){const _0x19872f=this[_0x27f7('0x5a')];_0x19872f['conversion'][_0x27f7('0x7')](_0x27f7('0x1c'))['markerToHighlight']({'model':_0x27f7('0x6'),'view':_0x36350a=>{const {id:_0x3ab2f2}=H(_0x36350a['markerName']),_0x35b348=[_0x27f7('0x22')];return this[_0x27f7('0x4d')]&&H(this[_0x27f7('0x4d')])['id']===_0x3ab2f2&&_0x35b348[_0x27f7('0x0')](_0x27f7('0x44')),{'classes':_0x35b348,'attributes':{'data-comment':_0x3ab2f2}};}}),_0x19872f['conversion'][_0x27f7('0x7')]('dataDowncast')[_0x27f7('0x2f')]({'model':'comment','view':_0x1f9b16=>{const _0x5e3c56=_0x19872f[_0x27f7('0x54')][_0x27f7('0x39')]['get'](_0x1f9b16),{id:_0x70f668,part:_0x574fc9}=H(_0x1f9b16);return _0x5e3c56&&!_0x5e3c56[_0x27f7('0x47')]?null:{'group':_0x27f7('0x6'),'name':_0x574fc9?_0x70f668+':'+_0x574fc9:_0x70f668};}}),_0x19872f[_0x27f7('0x34')][_0x27f7('0x7')](_0x27f7('0x9'))['elementToElement']({'view':{'name':_0x27f7('0x6'),'attribute':{'id':/^\w/}},'model':(_0x3110fe,{writer:_0x428137})=>_0x428137[_0x27f7('0x5c')](_0x27f7('0xe'),{'data-name':'comment:'+_0x3110fe[_0x27f7('0x12')]('id')})}),_0x19872f[_0x27f7('0x34')][_0x27f7('0x7')](_0x27f7('0x9'))[_0x27f7('0x5')]({'view':'comment'});}[_0x27f7('0x8')](){const _0x4d4f8e=this[_0x27f7('0x5a')],_0x6e8a3d=_0x4d4f8e['plugins'][_0x27f7('0xc')](_0x27f7('0x3a')),_0x1576d2=new Set();_0x4d4f8e[_0x27f7('0x54')][_0x27f7('0x3b')][_0x27f7('0x46')](_0x2f2635=>{let _0x6c3bf2=!0x1;for(const {name:_0x50f9fe,data:_0x5076c4}of _0x4d4f8e[_0x27f7('0x54')]['document'][_0x27f7('0x10')][_0x27f7('0x21')]()){const {group:_0x5a964e,id:_0x36b23e}=H(_0x50f9fe);let _0x5b1872=_0x5076c4[_0x27f7('0x50')];if(_0x27f7('0x6')!==_0x5a964e||!_0x5b1872)continue;const _0x582dc6=_0x27f7('0x24')===_0x5b1872[_0x27f7('0x25')][_0x27f7('0x11')];_0x582dc6||(_0x5b1872=J(_0x5b1872,_0x4d4f8e[_0x27f7('0x54')]),!_0x5b1872||_0x5b1872['isEqual'](_0x5076c4['newRange']))?!_0x5b1872||!_0x4d4f8e['model'][_0x27f7('0x5f')](_0x5b1872)||this[_0x27f7('0x41')]['has'](_0x36b23e)&&_0x582dc6?(_0x2f2635['removeMarker'](_0x50f9fe),_0x6c3bf2=!0x0):_0x582dc6||(this[_0x27f7('0x30')]?_0x1576d2[_0x27f7('0x4a')](_0x50f9fe):this[_0x27f7('0x2b')](_0x50f9fe,_0x36b23e)):(_0x2f2635[_0x27f7('0x35')](_0x50f9fe,{'range':_0x5b1872}),_0x6c3bf2=!0x0);}return _0x6c3bf2;}),this['on'](_0x27f7('0x1e'),(_0x1f028c,_0x21d7c4,_0x30c397)=>{if(!_0x30c397&&_0x1576d2[_0x27f7('0x14')])for(const _0x3aa01a of _0x1576d2){const {id:_0x54853b}=H(_0x3aa01a);_0x1576d2[_0x27f7('0xf')](_0x54853b),_0x4d4f8e['model']['markers'][_0x27f7('0xc')](_0x3aa01a)&&this['_attachMarkerToThread'](_0x3aa01a,_0x54853b);}}),this['listenTo'](_0x4d4f8e[_0x27f7('0x54')][_0x27f7('0x39')],_0x27f7('0x3d'),(_0x464a1d,_0x47f4e7,_0x1b37a7,_0x47939c)=>{if(_0x47939c)return;const {id:_0x5822c3}=H(_0x47f4e7[_0x27f7('0x42')]),_0x556c49=_0x4d4f8e[_0x27f7('0x1d')][_0x27f7('0xc')](_0x27f7('0x3a'))[_0x27f7('0x5d')](_0x5822c3);_0x1576d2[_0x27f7('0xf')](_0x5822c3),_0x556c49&&!this[_0x27f7('0x26')](_0x5822c3)&&(this[_0x27f7('0x41')][_0x27f7('0xf')](_0x5822c3),_0x6e8a3d[_0x27f7('0x36')](_0x5822c3));});}['_attachMarkerToThread'](_0x1ab807,_0x368eff){if(this['_attachedThreads'][_0x27f7('0x27')](_0x368eff)){const _0x22dcc8=this['_attachedThreads'][_0x27f7('0xc')](_0x368eff);return void(_0x22dcc8[_0x27f7('0x23')](_0x1ab807)||_0x22dcc8['push'](_0x1ab807));}this[_0x27f7('0x41')]['set'](_0x368eff,[_0x1ab807]);const _0x423838=this[_0x27f7('0x5a')],_0x131e44=_0x423838[_0x27f7('0x1d')][_0x27f7('0xc')](_0x27f7('0x3a')),_0x1e3ecc=_0x423838[_0x27f7('0x55')][_0x27f7('0xc')](_0x27f7('0x2')),_0x44924b=_0x423838['plugins'][_0x27f7('0xc')]('EditorAnnotations'),_0x38d793=()=>{const _0x124524=this['getAllMarkersForId'](_0x368eff);if(0x0===_0x124524[_0x27f7('0x37')])return null;if(0x1===_0x124524[_0x27f7('0x37')])return _0x696325(_0x423838[_0x27f7('0x3')],_0x124524[0x0]);const _0xb265f1=_0x124524['map'](_0x39a414=>_0x696325(_0x423838[_0x27f7('0x3')],_0x39a414));return _0xb265f1[_0x27f7('0x1f')]((_0x5b912f,_0x1f2058)=>{const _0x4972a6=new _0x5a49bb(_0x5b912f),_0x19d12d=new _0x5a49bb(_0x1f2058),_0x4a4314=_0x4972a6[_0x27f7('0x13')]-_0x19d12d[_0x27f7('0x13')];return 0x0==_0x4a4314?_0x4972a6['left']-_0x19d12d[_0x27f7('0x28')]:_0x4a4314;}),_0xb265f1[0x0];};!this[_0x27f7('0x31')](_0x368eff)[0x0]['managedUsingOperations']?_0x423838['editing'][_0x27f7('0x1b')][_0x27f7('0x5e')]('render',()=>{const _0x5c91ef=_0x423838['plugins'][_0x27f7('0xc')](_0x27f7('0x5b')),_0x5555c3=_0x131e44[_0x27f7('0x4c')]({'channelId':_0x1e3ecc,'threadId':_0x368eff,'target':_0x38d793}),_0x2a6c92=_0x131e44['_threadToController'][_0x27f7('0xc')](_0x5555c3)['view'],_0x1a9309=_0x5c91ef[_0x27f7('0x52')](_0x2a6c92);_0x44924b[_0x27f7('0x45')](_0x1a9309);},{'priority':_0x27f7('0x1a')}):_0x131e44['fetchCommentThread']({'channelId':_0x1e3ecc,'threadId':_0x368eff})['then'](_0x4e93b6=>{if(_0x27f7('0x20')!==_0x423838[_0x27f7('0x56')]){if(_0x4e93b6){const _0x2b5173=_0x4e93b6[_0x27f7('0x2c')](_0x38d793);_0x44924b[_0x27f7('0x45')](_0x2b5173);}else{const _0x4873a6=this['getAllMarkersForId'](_0x368eff);_0x423838[_0x27f7('0x54')][_0x27f7('0x57')](_0x269cff=>{for(const _0x31b34c of _0x4873a6)_0x269cff['removeMarker'](_0x31b34c);});}}});}}function G(_0x4924c9,_0x216165){return _0x216165?_0x4924c9+':'+_0x216165:_0x4924c9;}function H(_0x26ec77){const _0x450d0a=_0x26ec77[_0x27f7('0x38')](':');return{'group':_0x450d0a[0x0],'id':_0x450d0a[0x1],'part':_0x450d0a[0x2]};}function J(_0x37ccea,_0x286404){const _0x575a4b=_0x286404[_0x27f7('0x32')],_0x3a7356=_0x286404[_0x27f7('0x59')](_0x37ccea[_0x27f7('0x3e')]);for(const _0xdb4d70 of _0x37ccea[_0x27f7('0x48')]()){const {type:_0x4c58b9,item:_0x2c6552,nextPosition:_0x24a00c}=_0xdb4d70;if(_0x27f7('0x1')===_0x4c58b9||_0x575a4b[_0x27f7('0x53')](_0x2c6552)){const _0x4e7e8d=_0x286404[_0x27f7('0x17')](_0x2c6552);_0x3a7356[_0x27f7('0x43')]&&(_0x3a7356[_0x27f7('0x3e')]=_0x4e7e8d),_0x3a7356[_0x27f7('0xa')]=_0x24a00c;}}return _0x3a7356[_0x27f7('0x43')]?null:_0x3a7356;}
|
|
23
|
+
const _0x2915=['change','once','markerToData','switchReadOnly','_attachedThreads','then','editor','activeMarker','get','CommentsEditing','reconvertMarker','dataDowncast','CommentsRepository','fetchCommentThread','registerAnnotation','has','addComment','_handleMarkerAddAndRemove','view','updateMarker','comment','split','config','_detachCommentThread','stop','affectsData','differ','editing','addCommentThread','getAllMarkersForId','isCollapsed','elementToElement','getCommentThread','change:activeMarker','editingDowncast','$marker','data','openNewCommentThread','change:isThreadsLoadingPaused','conversion','plugins','length','$graveyard','destroy','comment:','hasCommentThread','push','set','pluginName','start','upcast','document','destroyed','_attachMarkerToThread','_initializeMarkerConverters','update:comment','hasContent','getWalker','size','rootName','name','requires','delete','text','getByInnerView','listenTo','markerName','schema','for','init','hasMarkerForId','createRange','isEqual','state','_threadToController','model','collaboration.channelId','getCommentThreads','isThreadsLoadingPaused','add','commands','render','includes','managedUsingOperations','removeMarker','filter','getAttribute','Annotations','change:isReadOnly','markers','ready','createPositionBefore','high','newRange'];(function(_0x169fcb,_0x2915ef){const _0x25d5ce=function(_0x238743){while(--_0x238743){_0x169fcb['push'](_0x169fcb['shift']());}};_0x25d5ce(++_0x2915ef);}(_0x2915,0xc3));const _0x25d5=function(_0x169fcb,_0x2915ef){_0x169fcb=_0x169fcb-0x0;let _0x25d5ce=_0x2915[_0x169fcb];return _0x25d5ce;};import{Plugin as _0x2436e6}from'ckeditor5/src/core';import _0x9e9341 from'./commentsrepository';import _0x45ea66 from'./addcommentthreadcommand';import{getAllMarkersDomElementsSorted as _0x288d9c}from'ckeditor5-collaboration/src/collaboration-core';import _0x2b3ff8 from'../annotations/editorannotations';import _0x29df1b from'./integrations/commentsrestrictededitingmode';import'../../theme/commentmarker.css';import _0x2a4605 from'./integrations/importword';export default class r extends _0x2436e6{static get[_0x25d5('0x36')](){return[_0x9e9341,_0x2b3ff8,_0x29df1b,_0x2a4605];}static get[_0x25d5('0x29')](){return _0x25d5('0x2');}constructor(_0x3cd56a){super(_0x3cd56a),this['set']('isThreadsLoadingPaused',!0x0),_0x3cd56a[_0x25d5('0x1d')][_0x25d5('0x58')](_0x25d5('0x53'),()=>this[_0x25d5('0x47')]=!0x1),this[_0x25d5('0x28')](_0x25d5('0x0'),null),this['on'](_0x25d5('0x1a'),(_0x2ed05f,_0x1e8f4e,_0x1a9f44,_0x13fa27)=>{_0x3cd56a[_0x25d5('0x44')][_0x25d5('0x57')](()=>{if(_0x1a9f44){const {id:_0x3d1808}=J(_0x1a9f44),_0x641faf=this[_0x25d5('0x16')](_0x3d1808);for(const _0x2fcbbd of _0x641faf)_0x3cd56a['editing']['reconvertMarker'](_0x2fcbbd);}if(_0x13fa27){const {id:_0x478def}=J(_0x13fa27),_0x17d12d=this['getAllMarkersForId'](_0x478def);for(const _0x292ec7 of _0x17d12d)_0x3cd56a[_0x25d5('0x14')][_0x25d5('0x3')](_0x292ec7);}});}),this[_0x25d5('0x5b')]=new Map();}[_0x25d5('0x3e')](){const _0x242145=this[_0x25d5('0x5d')],_0x1e323b=_0x242145[_0x25d5('0x21')][_0x25d5('0x1')](_0x25d5('0x5')),_0x2fdd47=_0x242145['config']['get'](_0x25d5('0x45'));_0x242145[_0x25d5('0x49')][_0x25d5('0x48')](_0x25d5('0x15'),new _0x45ea66(_0x242145)),this[_0x25d5('0x3a')](_0x242145,_0x25d5('0x51'),(_0x45084b,_0x418f24,_0x1dcfd6)=>{_0x1e323b[_0x25d5('0x5a')](_0x1dcfd6,_0x242145[_0x25d5('0xf')][_0x25d5('0x1')]('collaboration.channelId'));}),this['listenTo'](_0x1e323b,H('removeCommentThread',_0x2fdd47),(_0x58847d,{threadId:_0x3ce473})=>{_0x242145[_0x25d5('0x44')]['change'](_0x2cac71=>{for(const _0x50ba21 of this[_0x25d5('0x16')](_0x3ce473))_0x2cac71[_0x25d5('0x4d')](_0x50ba21);});const _0x14ef87=_0x1e323b[_0x25d5('0x19')](_0x3ce473);_0x1e323b[_0x25d5('0x26')](_0x3ce473)&&!_0x14ef87['length']||_0x58847d[_0x25d5('0x11')]();},{'priority':_0x25d5('0x55')}),this['listenTo'](_0x1e323b,H(_0x25d5('0x9'),_0x2fdd47),(_0x4962ce,{threadId:_0x906d94,isFromAdapter:_0x38cea4})=>{const _0x115a34=this[_0x25d5('0x16')](_0x906d94);if(_0x38cea4||0x0==_0x115a34['length']||!_0x1e323b[_0x25d5('0x26')](_0x906d94))return;0x1===_0x1e323b[_0x25d5('0x19')](_0x906d94)[_0x25d5('0x22')]&&_0x242145[_0x25d5('0x44')][_0x25d5('0x57')](_0x439fc4=>{for(const _0x2fea8a of _0x115a34)_0x439fc4[_0x25d5('0xc')](_0x2fea8a,{'usingOperation':!0x0,'affectsData':!0x0});});},{'priority':'low'}),this[_0x25d5('0x2f')](),this[_0x25d5('0xa')]();}[_0x25d5('0x24')](){const _0x1de04c=this['editor'][_0x25d5('0x21')][_0x25d5('0x1')](_0x25d5('0x5')),_0x4ff8fe=this['editor'][_0x25d5('0xf')][_0x25d5('0x1')]('collaboration.channelId');for(const _0x514cf5 of _0x1de04c[_0x25d5('0x46')]({'channelId':_0x4ff8fe}))_0x1de04c['_detachCommentThread'](_0x514cf5['id']),_0x1de04c['_threads'][_0x25d5('0x37')](_0x514cf5['id']);super[_0x25d5('0x24')]();}[_0x25d5('0x3f')](_0x5e3a40){return this[_0x25d5('0x16')](_0x5e3a40)[_0x25d5('0x22')]>0x0;}[_0x25d5('0x16')](_0x2af637){return(this[_0x25d5('0x5b')]['get'](_0x2af637)||[])['map'](_0x38b16e=>this[_0x25d5('0x5d')][_0x25d5('0x44')][_0x25d5('0x52')][_0x25d5('0x1')](_0x38b16e))[_0x25d5('0x4e')](_0x5a4631=>_0x5a4631);}[_0x25d5('0x2f')](){const _0x24ba1a=this[_0x25d5('0x5d')];_0x24ba1a[_0x25d5('0x20')][_0x25d5('0x3d')](_0x25d5('0x1b'))['markerToHighlight']({'model':_0x25d5('0xd'),'view':_0x4bf4c4=>{const {id:_0x534975}=J(_0x4bf4c4[_0x25d5('0x3b')]),_0x172eea=['ck-comment-marker'];return this[_0x25d5('0x0')]&&J(this[_0x25d5('0x0')])['id']===_0x534975&&_0x172eea[_0x25d5('0x27')]('ck-comment-marker--active'),{'classes':_0x172eea,'attributes':{'data-comment':_0x534975}};}}),_0x24ba1a[_0x25d5('0x20')]['for'](_0x25d5('0x4'))[_0x25d5('0x59')]({'model':_0x25d5('0xd'),'view':_0x4eeca6=>{const _0x118da0=_0x24ba1a[_0x25d5('0x44')]['markers'][_0x25d5('0x1')](_0x4eeca6),{id:_0x2e9290,part:_0x23ddd6}=J(_0x4eeca6);return _0x118da0&&!_0x118da0[_0x25d5('0x12')]?null:{'group':_0x25d5('0xd'),'name':_0x23ddd6?_0x2e9290+':'+_0x23ddd6:_0x2e9290};}}),_0x24ba1a[_0x25d5('0x20')][_0x25d5('0x3d')](_0x25d5('0x2b'))[_0x25d5('0x18')]({'view':{'name':_0x25d5('0xd'),'attribute':{'id':/^\w/}},'model':(_0x55589e,{writer:_0x37d870})=>_0x37d870['createElement'](_0x25d5('0x1c'),{'data-name':_0x25d5('0x25')+_0x55589e[_0x25d5('0x4f')]('id')})}),_0x24ba1a[_0x25d5('0x20')][_0x25d5('0x3d')](_0x25d5('0x2b'))['dataToMarker']({'view':_0x25d5('0xd')});}[_0x25d5('0xa')](){const _0x22882f=this['editor'],_0x53d07b=_0x22882f[_0x25d5('0x21')][_0x25d5('0x1')]('CommentsRepository'),_0x274c9e=new Set();_0x22882f[_0x25d5('0x44')]['document']['registerPostFixer'](_0xc721be=>{let _0x656a7a=!0x1;for(const {name:_0x5815c1,data:_0x487f73}of _0x22882f['model'][_0x25d5('0x2c')][_0x25d5('0x13')]['getChangedMarkers']()){const {group:_0x1bd755,id:_0x128a79}=J(_0x5815c1);let _0x18feb1=_0x487f73[_0x25d5('0x56')];if(_0x25d5('0xd')!==_0x1bd755||!_0x18feb1)continue;const _0x5af7cd=_0x25d5('0x23')===_0x18feb1['root'][_0x25d5('0x34')];_0x5af7cd||(_0x18feb1=K(_0x18feb1,_0x22882f[_0x25d5('0x44')]),!_0x18feb1||_0x18feb1[_0x25d5('0x41')](_0x487f73['newRange']))?!_0x18feb1||!_0x22882f[_0x25d5('0x44')][_0x25d5('0x31')](_0x18feb1)||this[_0x25d5('0x5b')][_0x25d5('0x8')](_0x128a79)&&_0x5af7cd?(_0xc721be['removeMarker'](_0x5815c1),_0x656a7a=!0x0):_0x5af7cd||(this[_0x25d5('0x47')]?_0x274c9e[_0x25d5('0x48')](_0x5815c1):this['_attachMarkerToThread'](_0x5815c1,_0x128a79)):(_0xc721be[_0x25d5('0xc')](_0x5815c1,{'range':_0x18feb1}),_0x656a7a=!0x0);}return _0x656a7a;}),this['on'](_0x25d5('0x1f'),(_0x15d009,_0x5b85fa,_0x10ba6a)=>{if(!_0x10ba6a&&_0x274c9e[_0x25d5('0x33')])for(const _0x5d1f89 of _0x274c9e){const {id:_0x388578}=J(_0x5d1f89);_0x274c9e[_0x25d5('0x37')](_0x388578),_0x22882f['model'][_0x25d5('0x52')][_0x25d5('0x1')](_0x5d1f89)&&this['_attachMarkerToThread'](_0x5d1f89,_0x388578);}}),this[_0x25d5('0x3a')](_0x22882f[_0x25d5('0x44')][_0x25d5('0x52')],_0x25d5('0x30'),(_0x5c879e,_0x7f2730,_0x2588b4,_0x3a4a49)=>{if(_0x3a4a49)return;const {id:_0x56518a}=J(_0x7f2730[_0x25d5('0x35')]),_0x242ae5=_0x22882f['plugins'][_0x25d5('0x1')](_0x25d5('0x5'))['getCommentThread'](_0x56518a);_0x274c9e['delete'](_0x56518a),_0x242ae5&&!this[_0x25d5('0x3f')](_0x56518a)&&(this[_0x25d5('0x5b')]['delete'](_0x56518a),_0x53d07b[_0x25d5('0x10')](_0x56518a));});}[_0x25d5('0x2e')](_0x3db709,_0x1c14f4){if(this[_0x25d5('0x5b')]['has'](_0x1c14f4)){const _0x4c7517=this[_0x25d5('0x5b')][_0x25d5('0x1')](_0x1c14f4);return void(_0x4c7517[_0x25d5('0x4b')](_0x3db709)||_0x4c7517[_0x25d5('0x27')](_0x3db709));}this[_0x25d5('0x5b')][_0x25d5('0x28')](_0x1c14f4,[_0x3db709]);const _0x53ec76=this[_0x25d5('0x5d')],_0x72a81f=_0x53ec76[_0x25d5('0x21')]['get'](_0x25d5('0x5')),_0x59bb6d=_0x53ec76[_0x25d5('0xf')][_0x25d5('0x1')](_0x25d5('0x45')),_0x2685ef=_0x53ec76[_0x25d5('0x21')][_0x25d5('0x1')]('EditorAnnotations'),_0x32f0e0=()=>{const _0x276256=this[_0x25d5('0x16')](_0x1c14f4);return _0x288d9c(_0x53ec76[_0x25d5('0x14')],_0x276256);};!this[_0x25d5('0x16')](_0x1c14f4)[0x0][_0x25d5('0x4c')]?_0x53ec76[_0x25d5('0x14')][_0x25d5('0xb')][_0x25d5('0x58')](_0x25d5('0x4a'),()=>{const _0x479ae4=_0x53ec76[_0x25d5('0x21')][_0x25d5('0x1')](_0x25d5('0x50')),_0x3a1a30=_0x72a81f[_0x25d5('0x1e')]({'channelId':_0x59bb6d,'threadId':_0x1c14f4,'target':_0x32f0e0}),_0x1e3b0b=_0x72a81f[_0x25d5('0x43')]['get'](_0x3a1a30)[_0x25d5('0xb')],_0x3747cd=_0x479ae4[_0x25d5('0x39')](_0x1e3b0b);_0x2685ef['registerAnnotation'](_0x3747cd);},{'priority':'low'}):_0x72a81f[_0x25d5('0x6')]({'channelId':_0x59bb6d,'threadId':_0x1c14f4})[_0x25d5('0x5c')](_0x18c88c=>{if(_0x25d5('0x2d')!==_0x53ec76[_0x25d5('0x42')]){if(_0x18c88c){const _0x36df52=_0x18c88c['attachTo'](_0x32f0e0);_0x2685ef[_0x25d5('0x7')](_0x36df52);}else{const _0x323062=this[_0x25d5('0x16')](_0x1c14f4);_0x53ec76[_0x25d5('0x44')][_0x25d5('0x57')](_0x43c07a=>{for(const _0x216be5 of _0x323062)_0x43c07a[_0x25d5('0x4d')](_0x216be5);});}}});}}function H(_0x348c46,_0x29b737){return _0x29b737?_0x348c46+':'+_0x29b737:_0x348c46;}function J(_0xba2a69){const _0x3ea576=_0xba2a69[_0x25d5('0xe')](':');return{'group':_0x3ea576[0x0],'id':_0x3ea576[0x1],'part':_0x3ea576[0x2]};}function K(_0x16ed99,_0xaa372a){const _0xdb320=_0xaa372a[_0x25d5('0x3c')],_0x652d77=_0xaa372a[_0x25d5('0x40')](_0x16ed99[_0x25d5('0x2a')]);for(const _0x13457d of _0x16ed99[_0x25d5('0x32')]()){const {type:_0x55dce7,item:_0x477f5b,nextPosition:_0x52b98f}=_0x13457d;if(_0x25d5('0x38')===_0x55dce7||_0xdb320['isObject'](_0x477f5b)){const _0x4cc552=_0xaa372a[_0x25d5('0x54')](_0x477f5b);_0x652d77[_0x25d5('0x17')]&&(_0x652d77[_0x25d5('0x2a')]=_0x4cc552),_0x652d77['end']=_0x52b98f;}}return _0x652d77[_0x25d5('0x17')]?null:_0x652d77;}
|