@ckeditor/ckeditor5-comments 31.0.0 → 33.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/LICENSE.md +2 -2
- package/README.md +2 -2
- package/build/comments.js +5 -0
- package/build/translations/bs.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.js +1 -0
- package/build/translations/et.js +1 -0
- package/build/translations/fr.js +1 -0
- package/build/translations/gl.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/ko.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/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/tk.js +1 -0
- package/build/translations/tr.js +1 -0
- package/build/translations/ug.js +1 -0
- package/build/translations/uk.js +1 -0
- package/build/translations/zh-cn.js +1 -0
- package/build/translations/zh.js +1 -0
- package/lang/translations/bs.po +80 -0
- package/lang/translations/cs.po +1 -1
- package/lang/translations/da.po +79 -0
- package/lang/translations/de-ch.po +1 -1
- package/lang/translations/de.po +1 -1
- package/lang/translations/el.po +79 -0
- package/lang/translations/en-au.po +1 -1
- package/lang/translations/en.po +1 -1
- package/lang/translations/es.po +1 -1
- package/lang/translations/et.po +1 -1
- package/lang/translations/fr.po +1 -1
- package/lang/translations/gl.po +1 -1
- package/lang/translations/hi.po +1 -1
- package/lang/translations/hr.po +1 -1
- package/lang/translations/hu.po +1 -1
- package/lang/translations/id.po +78 -0
- package/lang/translations/it.po +1 -1
- package/lang/translations/ja.po +1 -1
- package/lang/translations/ko.po +1 -1
- package/lang/translations/nl.po +1 -1
- package/lang/translations/no.po +1 -1
- package/lang/translations/pl.po +1 -1
- package/lang/translations/pt-br.po +1 -1
- package/lang/translations/ro.po +1 -1
- package/lang/translations/ru.po +1 -1
- package/lang/translations/sk.po +1 -1
- package/lang/translations/sr-latn.po +1 -1
- package/lang/translations/sr.po +1 -1
- package/lang/translations/tk.po +1 -1
- package/lang/translations/tr.po +1 -1
- package/lang/translations/ug.po +1 -1
- package/lang/translations/uk.po +1 -1
- package/lang/translations/zh-cn.po +1 -1
- package/lang/translations/zh.po +1 -1
- package/package.json +4 -9
- 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/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/ui/view/confirmmixin.js +2 -2
- package/src/comments/ui/view/confirmview.js +2 -2
- package/src/comments.js +2 -2
- package/src/commentsonly.js +2 -2
- package/src/{utils/getmarkerdomelement.js → index.js} +2 -2
- package/src/utils/common-translations.js +2 -2
- package/src/utils/createmutationobserver.js +2 -2
- package/theme/annotation-inline.css +1 -1
- package/theme/annotation.css +1 -1
- package/theme/comment.css +1 -1
- package/theme/commentinput.css +1 -1
- package/theme/commentmarker.css +1 -1
- package/theme/commentthread.css +1 -1
- package/theme/icons/add-comment.svg +1 -1
- package/theme/icons/edit-comment.svg +1 -1
- package/theme/icons/remove-comment.svg +1 -1
- package/theme/sidebar-narrow.css +1 -1
- package/theme/sidebar.css +1 -1
- package/src/utils/getdatetimeformatter.js +0 -23
- package/src/utils/trim-html.js +0 -23
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-comments",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "33.0.0",
|
|
4
4
|
"description": "Collaborative comments feature for CKEditor 5.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"author": "CKSource (http://cksource.com/)",
|
|
@@ -29,15 +29,10 @@
|
|
|
29
29
|
"discussion",
|
|
30
30
|
"discussions"
|
|
31
31
|
],
|
|
32
|
+
"main": "src/index.js",
|
|
32
33
|
"dependencies": {
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"@ckeditor/ckeditor5-collaboration-core": "^31.0.0",
|
|
36
|
-
"@ckeditor/ckeditor5-essentials": "^31.0.0",
|
|
37
|
-
"@ckeditor/ckeditor5-list": "^31.0.0",
|
|
38
|
-
"@ckeditor/ckeditor5-utils": "^31.0.0",
|
|
39
|
-
"ckeditor5": "^31.0.0",
|
|
40
|
-
"date-fns": "^2.17.0",
|
|
34
|
+
"ckeditor5": "^33.0.0",
|
|
35
|
+
"ckeditor5-collaboration": "^33.0.0",
|
|
41
36
|
"lodash-es": "^4.17.11"
|
|
42
37
|
}
|
|
43
38
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x15f1=['clear','isVisible','focusTracker','render','view','type','add','element','_type','_target','focusableElements','_isTargetElementVisible','targetRect','offsetParent','innerView','_assertCorrectTarget','refreshVisibility','getClientRects','target','_id','mainView','isActive','stopListening','set','annotation-invalid-target'];(function(_0xda45d7,_0x15f1f9){const _0x533eeb=function(_0x4893b8){while(--_0x4893b8){_0xda45d7['push'](_0xda45d7['shift']());}};_0x533eeb(++_0x15f1f9);}(_0x15f1,0x9d));const _0x533e=function(_0xda45d7,_0x15f1f9){_0xda45d7=_0xda45d7-0x0;let _0x533eeb=_0x15f1[_0xda45d7];return _0x533eeb;};import{CKEditorError as _0x5ca36a,Rect as _0x55baec,Collection as _0x14b303,mix as _0x2ca081,ObservableMixin as _0x40716d}from'ckeditor5/src/utils';import{isElement as _0x1dd9a2}from'lodash-es';export default class p{constructor({view:_0x347a41,target:_0x34a865,type:_0x431b37,isVisible:_0x4ec95a=!0x0}){this[_0x533e('0x16')]=_0x347a41,this[_0x533e('0x16')][_0x533e('0x0')]||this[_0x533e('0x16')][_0x533e('0x15')](),this[_0x533e('0x1')]=_0x431b37,this['_target']=_0x34a865,this[_0x533e('0x8')](),this[_0x533e('0x3')]=new _0x14b303([this['view'][_0x533e('0x0')]],{'idProperty':_0x533e('0xc')}),this[_0x533e('0x3')]['on'](_0x533e('0x18'),(_0xd88faa,_0x12206f)=>{this[_0x533e('0x16')][_0x533e('0x14')]['add'](_0x12206f);}),this[_0x533e('0x3')]['on']('remove',(_0x4b2901,_0x472c44)=>{this[_0x533e('0x16')][_0x533e('0x14')]['remove'](_0x472c44);}),this[_0x533e('0x10')](_0x533e('0x13'),_0x4ec95a);}get[_0x533e('0x17')](){return'function'==typeof this[_0x533e('0x1')]?this[_0x533e('0x1')]():this['_type'];}get[_0x533e('0x7')](){return this[_0x533e('0x16')]['mainView'];}get['target'](){return'function'==typeof this[_0x533e('0x2')]?this[_0x533e('0x2')]():this['_target'];}get[_0x533e('0x5')](){const _0x29e1dc=this['target'];return this[_0x533e('0x8')](),null!==_0x29e1dc&&this['_isTargetElementVisible']()?new _0x55baec(_0x29e1dc):null;}get['isActive'](){return this['view']['isActive'];}set['isActive'](_0x4632f0){this[_0x533e('0x16')]['isActive']=_0x4632f0,this[_0x533e('0x16')][_0x533e('0xd')][_0x533e('0xe')]=_0x4632f0;}['updateTargetRect'](){this[_0x533e('0x16')][_0x533e('0x5')]=this[_0x533e('0x5')];}['destroy'](){this['focusableElements'][_0x533e('0xf')](),this[_0x533e('0x3')][_0x533e('0x12')](),this[_0x533e('0xf')]();}[_0x533e('0x9')](){this[_0x533e('0x13')]=this[_0x533e('0x4')]();}[_0x533e('0x4')](){const _0x494b5b=this[_0x533e('0xb')];if(_0x1dd9a2(_0x494b5b)){const _0x65f13f=_0x494b5b[_0x533e('0xa')]()['item'](0x0),_0x10eaa8=_0x494b5b[_0x533e('0x6')];if(!_0x65f13f||!_0x10eaa8)return!0x1;}return!0x0;}[_0x533e('0x8')](){const _0x3a765b=this['target'];if(!(null===_0x3a765b||_0x3a765b instanceof _0x55baec||_0x1dd9a2(_0x3a765b)))throw new _0x5ca36a(_0x533e('0x11'),null,{'target':_0x3a765b});}}_0x2ca081(p,_0x40716d);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x1d50=['change:isFocused','fire','_sort','blur','add','_innerViewToAnnotation','remove','getIndex','clear','updateTargetRect','_viewToAnnotation','refreshPositioning','focusTracker','_items','_focusTracker','view','destroy','left','stopListening','has','_getOrderInContent','set','targetRect','listenTo','focusableElements','from','delete','length','get','innerView','top'];(function(_0x326b07,_0x1d50f3){const _0x32020d=function(_0x1e567a){while(--_0x1e567a){_0x326b07['push'](_0x326b07['shift']());}};_0x32020d(++_0x1d50f3);}(_0x1d50,0x137));const _0x3202=function(_0x326b07,_0x1d50f3){_0x326b07=_0x326b07-0x0;let _0x32020d=_0x1d50[_0x326b07];return _0x32020d;};import{CKEditorError as _0x4d9e63,Collection as _0x55dab7,FocusTracker as _0x287de0}from'ckeditor5/src/utils';export default class x extends _0x55dab7{constructor(_0x4f14ae=[]){super(),this[_0x3202('0x4')]=new Map(),this[_0x3202('0x9')]=new Map(),this[_0x3202('0xd')]=new _0x287de0(),this[_0x3202('0xd')]['on'](_0x3202('0x1e'),(_0x3005ee,_0x4fb247,_0x18062f)=>{_0x18062f||this[_0x3202('0x0')](_0x3202('0x2'));});for(const _0xe20619 of _0x4f14ae)this[_0x3202('0x3')](_0xe20619);}get['isFocused'](){return this[_0x3202('0xd')]['isFocused'];}[_0x3202('0x3')](_0x371154){if(this['has'](_0x371154))throw new _0x4d9e63('annotationcollection-duplicated-item',null);this[_0x3202('0x4')][_0x3202('0x14')](_0x371154[_0x3202('0x1c')],_0x371154),this['_viewToAnnotation'][_0x3202('0x14')](_0x371154[_0x3202('0xe')],_0x371154);for(const _0x142025 of _0x371154[_0x3202('0x17')])this['_focusTracker']['add'](_0x142025);this[_0x3202('0x16')](_0x371154[_0x3202('0x17')],_0x3202('0x3'),(_0x1fd6c9,_0x3fc271)=>{this['_focusTracker']['add'](_0x3fc271);}),this[_0x3202('0x16')](_0x371154['focusableElements'],'remove',(_0x2bf33b,_0x178f05)=>{this['_focusTracker'][_0x3202('0x5')](_0x178f05);}),this[_0x3202('0x16')](_0x371154['view'][_0x3202('0xb')],'change:isFocused',(_0x539d2f,_0x4a8485,_0xd71ef)=>{_0xd71ef&&this[_0x3202('0x0')]('focus',_0x371154);});const _0x47a8e5=this['_getOrderInContent'](_0x371154);super[_0x3202('0x3')](_0x371154,_0x47a8e5),_0x371154[_0x3202('0x8')]();}[_0x3202('0x5')](_0x33d6bc){if(!this['has'](_0x33d6bc))throw new _0x4d9e63('annotationcollection-not-existing-item',null);this[_0x3202('0x11')](_0x33d6bc[_0x3202('0xe')][_0x3202('0xb')]),this[_0x3202('0x11')](_0x33d6bc[_0x3202('0x17')]);for(const _0xb821aa of _0x33d6bc[_0x3202('0x17')])this[_0x3202('0xd')][_0x3202('0x5')](_0xb821aa);this['_viewToAnnotation'][_0x3202('0x19')](_0x33d6bc['view']),this['_innerViewToAnnotation'][_0x3202('0x19')](_0x33d6bc[_0x3202('0x1c')]),super['remove'](_0x33d6bc);}['getByInnerView'](_0x199ae4){return this[_0x3202('0x4')][_0x3202('0x1b')](_0x199ae4);}['getByView'](_0xb4adf5){return this[_0x3202('0x9')][_0x3202('0x1b')](_0xb4adf5);}['destroy'](){super['clear'](),this[_0x3202('0x11')](),this[_0x3202('0x4')][_0x3202('0x7')](),this[_0x3202('0x9')][_0x3202('0x7')](),this['_focusTracker'][_0x3202('0xf')]();}[_0x3202('0xa')](){for(const _0x326cc6 of this)_0x326cc6[_0x3202('0x8')]();this[_0x3202('0x1')]();}[_0x3202('0x1')](){const _0x4f0460=Array[_0x3202('0x18')](this)['sort']((_0x4e4d51,_0x4cd5ec)=>y(_0x4e4d51[_0x3202('0x15')],_0x4cd5ec[_0x3202('0x15')]));for(let _0x19dbdb=_0x4f0460['length']-0x1;_0x19dbdb>0x0;_0x19dbdb--){const _0x1c589c=_0x4f0460[_0x19dbdb];_0x19dbdb!==this[_0x3202('0x6')](_0x1c589c)&&(this[_0x3202('0x5')](_0x1c589c),this[_0x3202('0x3')](_0x1c589c,_0x19dbdb));}}[_0x3202('0x13')](_0x597b36){let _0x348899=0x0;const _0x5e4e07=_0x597b36[_0x3202('0x15')];if(!_0x5e4e07)return this[_0x3202('0xc')][_0x3202('0x1a')];for(const _0x10160b of this){const _0x164654=_0x10160b[_0x3202('0x15')];if(_0x164654){if(y(_0x5e4e07,_0x164654)<0x0)return _0x348899;_0x348899++;}}return _0x348899;}}export function bindAnnotationCollections({source:_0x5b8813,target:_0x2df6af,filter:_0x461046}){for(const _0x1061f9 of _0x5b8813)_0x461046(_0x1061f9)&&_0x2df6af['add'](_0x1061f9);_0x2df6af[_0x3202('0x16')](_0x5b8813,_0x3202('0x3'),(_0xf2d9ae,_0x35ba20)=>{_0x461046(_0x35ba20)&&_0x2df6af[_0x3202('0x3')](_0x35ba20);}),_0x2df6af[_0x3202('0x16')](_0x5b8813,_0x3202('0x5'),(_0x420bc6,_0x12a405)=>{_0x2df6af[_0x3202('0x12')](_0x12a405)&&_0x2df6af[_0x3202('0x5')](_0x12a405);});}function y(_0x23f9d9,_0x59c344){if(null===_0x23f9d9&&null===_0x59c344)return 0x0;if(null===_0x23f9d9)return-0x1;if(null===_0x59c344)return 0x1;const _0x404860=_0x23f9d9[_0x3202('0x1d')]-_0x59c344[_0x3202('0x1d')];return 0x0==_0x404860?_0x23f9d9[_0x3202('0x10')]-_0x59c344['left']:_0x404860;}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x54ab=['pluginName','delete','createAnnotation','refreshVisibility','stopListening','deactivateAll','destroy','has','activate','_visibleAnnotations','_bindAnnotationsToVisibleAnnotations','remove','add','getByInnerView','collection','fire','_addActiveAnnotation','change:isVisible','activeAnnotations','set','isVisible','refreshPositioning','source','listenTo'];(function(_0x41c1ba,_0x54ab0a){const _0x27d136=function(_0x485c30){while(--_0x485c30){_0x41c1ba['push'](_0x41c1ba['shift']());}};_0x27d136(++_0x54ab0a);}(_0x54ab,0x75));const _0x27d1=function(_0x41c1ba,_0x54ab0a){_0x41c1ba=_0x41c1ba-0x0;let _0x27d136=_0x54ab[_0x41c1ba];return _0x27d136;};import{ContextPlugin as _0x40a6a0}from'ckeditor5/src/core';import _0x433ba9 from'./annotation';import _0x9ae26e from'./annotationcollection';import _0x5c12ae from'./view/annotationview';export default class V extends _0x40a6a0{static get[_0x27d1('0x3')](){return'Annotations';}constructor(_0x10288d){super(_0x10288d),this['collection']=new _0x9ae26e(),this[_0x27d1('0xc')]=new _0x9ae26e(),this[_0x27d1('0x16')]('activeAnnotations',new Set()),this['_bindAnnotationsToVisibleAnnotations']();}['add'](_0x2d23f6){this[_0x27d1('0x11')][_0x27d1('0xf')](_0x2d23f6);}[_0x27d1('0xe')](_0x5e805e){this[_0x27d1('0x11')][_0x27d1('0xe')](_0x5e805e),_0x5e805e['destroy']();}[_0x27d1('0x6')](){for(const _0x92c0cf of this['collection'])_0x92c0cf[_0x27d1('0x6')]();}['refreshPositioning'](){this[_0x27d1('0xc')][_0x27d1('0x0')]();}[_0x27d1('0x10')](_0xab7b4b){return this['collection'][_0x27d1('0x10')](_0xab7b4b);}[_0x27d1('0x8')](){this[_0x27d1('0x12')]('_deactivateAllAnnotations');}[_0x27d1('0x9')](){for(const _0x24b233 of this[_0x27d1('0x11')])_0x24b233[_0x27d1('0x9')]();this['_visibleAnnotations'][_0x27d1('0x9')](),this[_0x27d1('0x11')][_0x27d1('0x9')](),super[_0x27d1('0x9')]();}[_0x27d1('0xb')](_0x12b309){this['fire']('_activateAnnotation',_0x12b309);}[_0x27d1('0x5')](_0x232d36){return new _0x433ba9(_0x232d36);}['createAnnotationView'](_0x2c0aa4,_0x1980fc){return new _0x5c12ae(_0x2c0aa4,_0x1980fc);}[_0x27d1('0x13')](_0x225377){const _0x5e6bde=new Set(this['activeAnnotations']);_0x5e6bde[_0x27d1('0xf')](_0x225377),this[_0x27d1('0x15')]=_0x5e6bde;}['_removeActiveAnnotation'](_0x2a0e2b){const _0x18e5d3=new Set(this[_0x27d1('0x15')]);_0x18e5d3[_0x27d1('0x4')](_0x2a0e2b),this[_0x27d1('0x15')]=_0x18e5d3;}[_0x27d1('0xd')](){const _0x38852d=this[_0x27d1('0x11')],_0x1ffcd2=this[_0x27d1('0xc')];function _0x345b87(_0x14b352){const _0x5ab1eb=_0x14b352[_0x27d1('0x1')];_0x5ab1eb[_0x27d1('0x17')]&&!_0x1ffcd2[_0x27d1('0xa')](_0x5ab1eb)?_0x1ffcd2[_0x27d1('0xf')](_0x5ab1eb):!_0x5ab1eb[_0x27d1('0x17')]&&_0x1ffcd2[_0x27d1('0xa')](_0x5ab1eb)&&_0x1ffcd2[_0x27d1('0xe')](_0x5ab1eb);}this[_0x27d1('0x2')](_0x38852d,_0x27d1('0xf'),(_0x57ade6,_0x23fdcf)=>{_0x23fdcf[_0x27d1('0x17')]&&_0x1ffcd2[_0x27d1('0xf')](_0x23fdcf),this['listenTo'](_0x23fdcf,'change:isVisible',_0x345b87);}),this[_0x27d1('0x2')](_0x38852d,_0x27d1('0xe'),(_0x18f2fa,_0x1a7e8e)=>{_0x1ffcd2[_0x27d1('0xa')](_0x1a7e8e)&&_0x1ffcd2['remove'](_0x1a7e8e),this[_0x27d1('0x7')](_0x1a7e8e,_0x27d1('0x14'),_0x345b87);});}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x5443=['switchTo','isActive','refilterAnnotations','attach','length','setActiveAnnotation','_uisData','get','hasActive','_uis','annotationsuis-register-invalid-interface','_activateAnnotation','annotationsuis-register-already-registered','from','size','context','register','_deactivateAllAnnotations','listenTo','activeUIs','plugins','_removeActiveAnnotation','_visibleAnnotations','requires','set','filter','function','_setSelectedAnnotations','detach','pluginName','has','destroy','annotationsuis-activate-missing-ui','add','collection','delete','AnnotationsUIs','deactivateAll','init','activeAnnotations','_assertAnnotationDoesNotBelongToMultipleUIs','deactivate','type','activate'];(function(_0xe81566,_0x5443ba){const _0x1c4949=function(_0x4444c0){while(--_0x4444c0){_0xe81566['push'](_0xe81566['shift']());}};_0x1c4949(++_0x5443ba);}(_0x5443,0xa0));const _0x1c49=function(_0xe81566,_0x5443ba){_0xe81566=_0xe81566-0x0;let _0x1c4949=_0x5443[_0xe81566];return _0x1c4949;};import{ContextPlugin as _0x34fb0d}from'ckeditor5/src/core';import{CKEditorError as _0x4b8f6e}from'ckeditor5/src/utils';import _0x2abb73,{bindAnnotationCollections as _0x1557f6}from'./annotationcollection';import _0x1c1b10 from'./annotations';export default class I extends _0x34fb0d{static get[_0x1c49('0x27')](){return[_0x1c1b10];}static get[_0x1c49('0x1')](){return _0x1c49('0x8');}constructor(_0x27f275){super(_0x27f275),this[_0x1c49('0x23')]=new Set(),this[_0x1c49('0x19')]=new Map(),this[_0x1c49('0x16')]=new Map();}[_0x1c49('0xa')](){const _0xbf43a7=this[_0x1c49('0x1f')][_0x1c49('0x24')][_0x1c49('0x17')](_0x1c1b10);this[_0x1c49('0x22')](_0xbf43a7,_0x1c49('0x1b'),(_0x531bc0,_0xe7f247)=>{for(const _0x1a8a34 of this[_0x1c49('0x23')]){const _0x260fea=this[_0x1c49('0x19')][_0x1c49('0x17')](_0x1a8a34);(0x0,this[_0x1c49('0x16')]['get'](_0x1a8a34)['filter'])(_0xe7f247)&&_0x260fea['setActiveAnnotation'](_0xe7f247);}}),this[_0x1c49('0x22')](_0xbf43a7,_0x1c49('0x21'),()=>{for(const _0xc3e629 of this[_0x1c49('0x23')]){this[_0x1c49('0x19')][_0x1c49('0x17')](_0xc3e629)[_0x1c49('0x15')](null);}}),this[_0x1c49('0x22')](_0xbf43a7[_0x1c49('0x26')],_0x1c49('0x5'),(_0x5143f2,_0x38fbe5)=>{this[_0x1c49('0xc')](_0x38fbe5);});}[_0x1c49('0x18')](){return this[_0x1c49('0x23')][_0x1c49('0x1e')]>0x0;}[_0x1c49('0x11')](_0x1e5b8c){return this[_0x1c49('0x23')][_0x1c49('0x2')](_0x1e5b8c);}['activate'](_0x252e0c,_0x1f5d1f=()=>!0x0){const _0x15d8e8=this[_0x1c49('0x1f')][_0x1c49('0x24')][_0x1c49('0x17')](_0x1c1b10);if(!this[_0x1c49('0x19')][_0x1c49('0x2')](_0x252e0c))throw new _0x4b8f6e(_0x1c49('0x4'),this,{'uiName':_0x252e0c});this[_0x1c49('0x11')](_0x252e0c)&&this[_0x1c49('0xd')](_0x252e0c),this[_0x1c49('0x23')][_0x1c49('0x5')](_0x252e0c);const _0x355efe=new _0x2abb73(),_0x21f98e=_0x15d8e8[_0x1c49('0x26')];_0x1557f6({'source':_0x21f98e,'target':_0x355efe,'filter':_0x1f5d1f}),this[_0x1c49('0x16')][_0x1c49('0x28')](_0x252e0c,{'collection':_0x355efe,'filter':_0x1f5d1f});const _0x442925=this[_0x1c49('0x19')][_0x1c49('0x17')](_0x252e0c);_0x442925[_0x1c49('0x13')](_0x355efe),this[_0x1c49('0x22')](_0x442925,'change:activeAnnotation',(_0x5d2c46,_0x362b04,_0x179aef,_0x5949b4)=>{_0x5949b4&&_0x15d8e8[_0x1c49('0x25')](_0x5949b4),_0x179aef&&_0x15d8e8['_addActiveAnnotation'](_0x179aef);});}[_0x1c49('0xd')](_0x1cabd8){this[_0x1c49('0x23')][_0x1c49('0x7')](_0x1cabd8);const _0x2ccbe2=this[_0x1c49('0x19')]['get'](_0x1cabd8);_0x2ccbe2[_0x1c49('0x0')](),this['stopListening'](_0x2ccbe2),this[_0x1c49('0x16')][_0x1c49('0x17')](_0x1cabd8)[_0x1c49('0x6')][_0x1c49('0x3')](),this[_0x1c49('0x16')][_0x1c49('0x7')](_0x1cabd8);}[_0x1c49('0x10')](_0x294a06){const _0x15526e=this['context'][_0x1c49('0x24')][_0x1c49('0x17')](_0x1c1b10),_0x59de97=Array[_0x1c49('0x1d')](_0x15526e[_0x1c49('0xb')])[0x0]||null;this[_0x1c49('0x9')](),this[_0x1c49('0xf')](_0x294a06);const _0x3054c1=this[_0x1c49('0x19')][_0x1c49('0x17')](_0x294a06);_0x3054c1['setActiveAnnotation'](_0x59de97),_0x3054c1['_setSelectedAnnotations']&&_0x59de97&&_0x3054c1[_0x1c49('0x2b')]([_0x59de97]);}[_0x1c49('0x9')](){for(const _0x5cfbda of this[_0x1c49('0x23')])this[_0x1c49('0xd')](_0x5cfbda);}[_0x1c49('0x20')](_0x441ebc,_0x2954b8){if(this[_0x1c49('0x19')]['has'](_0x441ebc))throw new _0x4b8f6e(_0x1c49('0x1c'));if('function'!=typeof _0x2954b8[_0x1c49('0x13')]||'function'!=typeof _0x2954b8[_0x1c49('0x0')]||_0x1c49('0x2a')!=typeof _0x2954b8[_0x1c49('0x15')])throw new _0x4b8f6e(_0x1c49('0x1a'),null);this[_0x1c49('0x19')][_0x1c49('0x28')](_0x441ebc,_0x2954b8);}[_0x1c49('0x12')](){const _0x54fba0=this['context'][_0x1c49('0x24')][_0x1c49('0x17')](_0x1c1b10)['collection'],_0x4e996e=new Map(),_0x24f6be=Array['from'](this[_0x1c49('0x23')]);for(const _0x960a04 of this[_0x1c49('0x23')]){const _0x4ea3e5=this[_0x1c49('0x16')][_0x1c49('0x17')](_0x960a04)[_0x1c49('0x6')];for(const _0x1871c9 of _0x4ea3e5)_0x4e996e[_0x1c49('0x28')](_0x1871c9,_0x960a04);}for(const _0x20aee8 of _0x54fba0){const _0x1e98f7=_0x4e996e[_0x1c49('0x17')](_0x20aee8);this['_assertAnnotationDoesNotBelongToMultipleUIs'](_0x20aee8);const _0x3919e1=_0x24f6be['find'](_0x53688e=>this[_0x1c49('0x16')][_0x1c49('0x17')](_0x53688e)[_0x1c49('0x29')](_0x20aee8));_0x1e98f7!==_0x3919e1&&(_0x1e98f7&&this[_0x1c49('0x16')][_0x1c49('0x17')](_0x1e98f7)[_0x1c49('0x6')]['remove'](_0x20aee8),_0x3919e1&&this['_uisData'][_0x1c49('0x17')](_0x3919e1)['collection']['add'](_0x20aee8));}}['destroy'](){this[_0x1c49('0x9')](),super[_0x1c49('0x3')]();}[_0x1c49('0xc')](_0x565a3d){const _0x59d432=[];for(const _0x330775 of this[_0x1c49('0x23')]){(0x0,this[_0x1c49('0x16')][_0x1c49('0x17')](_0x330775)[_0x1c49('0x29')])(_0x565a3d)&&_0x59d432['push'](_0x330775);}if(_0x59d432[_0x1c49('0x14')]>0x1)throw new _0x4b8f6e('annotationsuis-annotation-mismatch',null,{'matchedUIs':_0x59d432,'annotationType':_0x565a3d[_0x1c49('0xe')]});}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x1855=['annotation','remove','collection','editing','model','element','push','document','view','plugins','has','change:isFocused','getOrderedSelectedAnnotations','editorannotations-invalid-source-callback','refresh','sort','innerView','range','change:range','directChange','add','from','_dataCollectors','hasDomSelection','map','containsRange','refreshSelectedViews','isCollapsed','addSourceCollector','pluginName','getByInnerView','keys','init','get','editor','isReadOnly','listenTo','selection','delete','_editorAnnotationsData','fire','cancel','set','requires','focusTracker'];(function(_0x362386,_0x1855cd){const _0x3bb80c=function(_0x3f8122){while(--_0x3f8122){_0x362386['push'](_0x362386['shift']());}};_0x3bb80c(++_0x1855cd);}(_0x1855,0x147));const _0x3bb8=function(_0x362386,_0x1855cd){_0x362386=_0x362386-0x0;let _0x3bb80c=_0x1855[_0x362386];return _0x3bb80c;};import{Plugin as _0x558b1d}from'ckeditor5/src/core';import{CKEditorError as _0x227259}from'ckeditor5/src/utils';import{debounce as _0x223d77}from'lodash-es';import _0x564171 from'./annotations';export default class k extends _0x558b1d{static get[_0x3bb8('0x1f')](){return[_0x564171];}static get[_0x3bb8('0x11')](){return'EditorAnnotations';}constructor(_0x42fe20){super(_0x42fe20),this['_dataCollectors']=new Set();}[_0x3bb8('0x14')](){const _0x49110a=this[_0x3bb8('0x16')],_0x1764f6=_0x49110a[_0x3bb8('0x2a')][_0x3bb8('0x15')](_0x564171),_0xa4c2d8=_0x49110a[_0x3bb8('0x25')][_0x3bb8('0x28')]['selection'],_0x1a93c4=_0x223d77(()=>this[_0x3bb8('0xe')](),0xa);_0xa4c2d8['on'](_0x3bb8('0x6'),(_0x3610cb,_0xde067a)=>{_0xde067a[_0x3bb8('0x7')]&&(_0x1a93c4[_0x3bb8('0x1d')](),this[_0x3bb8('0xe')]());}),this[_0x3bb8('0x18')](_0x49110a[_0x3bb8('0x24')][_0x3bb8('0x29')][_0x3bb8('0x28')],'change:isFocused',(_0x2750c7,_0x36f6aa,_0x3b722a)=>{_0x3b722a&&_0x1a93c4();}),this[_0x3bb8('0x18')](_0x49110a['ui']['focusTracker'],_0x3bb8('0x2c'),(_0x1e7787,_0x774f94,_0x2336d9)=>{_0x2336d9||_0x49110a[_0x3bb8('0x17')]||this[_0x3bb8('0x1c')]('blur',{'isAnnotationTracked':_0x178db3=>this[_0x3bb8('0x1b')][_0x3bb8('0x2b')](_0x178db3[_0x3bb8('0x4')])});}),this[_0x3bb8('0x18')](this[_0x3bb8('0x16')]['ui'],'update',()=>this[_0x3bb8('0x1c')]('uiUpdate'));const _0x4d5e3b=new Set();this[_0x3bb8('0x18')](_0x1764f6[_0x3bb8('0x23')],_0x3bb8('0x8'),(_0x443b98,_0x36e805)=>{for(const _0x1a7fcd of this[_0x3bb8('0x1b')][_0x3bb8('0x13')]())if(_0x1a7fcd===_0x36e805['innerView']){_0x49110a['ui'][_0x3bb8('0x20')][_0x3bb8('0x8')](_0x36e805[_0x3bb8('0x29')][_0x3bb8('0x26')]),_0x4d5e3b['add'](_0x36e805['view']);break;}}),this[_0x3bb8('0x18')](_0x1764f6[_0x3bb8('0x23')],_0x3bb8('0x22'),(_0x2bb5c0,_0xe6d3b0)=>{_0x4d5e3b[_0x3bb8('0x2b')](_0xe6d3b0['view'])&&(_0x49110a['ui'][_0x3bb8('0x20')]['remove'](_0xe6d3b0[_0x3bb8('0x29')]['element']),_0x4d5e3b[_0x3bb8('0x1a')](_0xe6d3b0['view']));});}[_0x3bb8('0xb')](){return this[_0x3bb8('0x16')][_0x3bb8('0x24')][_0x3bb8('0x29')]['hasDomSelection'];}[_0x3bb8('0x10')](_0x3d2530){if('function'!=typeof _0x3d2530)throw new _0x227259(_0x3bb8('0x1'));this['_dataCollectors']['add'](_0x3d2530);}[_0x3bb8('0xe')](){this[_0x3bb8('0x1c')](_0x3bb8('0x2'));}[_0x3bb8('0x0')]({activeAnnotation:_0x33fc1e,annotations:_0x4f3856}){const _0x509b7c=[],_0x2c15ac=this[_0x3bb8('0x16')][_0x3bb8('0x25')]['document'][_0x3bb8('0x19')],_0xe565ca=Array[_0x3bb8('0x9')](_0x2c15ac['getRanges']());for(const [_0x713807,_0x196f11]of this[_0x3bb8('0x1b')]){const _0x480e26=_0x241ee1(_0x196f11),_0x1c31fe=_0x4f3856[_0x3bb8('0x12')](_0x713807);_0x480e26&&_0x1c31fe&&_0x509b7c[_0x3bb8('0x27')]({'annotation':_0x1c31fe,'range':_0x480e26});}function _0x241ee1(_0x2c8564){for(const _0x17fd46 of _0x2c8564)for(const _0x42518d of _0xe565ca)if(_0x17fd46[_0x3bb8('0xd')](_0x42518d,!_0x2c15ac[_0x3bb8('0xf')]))return _0x17fd46;return null;}return _0x509b7c[_0x3bb8('0x3')]((_0x3cf163,_0x108144)=>{const _0x12cb56=_0x3cf163['range'],_0x537e79=_0x108144[_0x3bb8('0x5')];if(!_0x12cb56['isEqual'](_0x537e79)){if(_0x12cb56['containsRange'](_0x537e79,!0x0))return 0x1;if(_0x537e79[_0x3bb8('0xd')](_0x12cb56,!0x0))return-0x1;}return _0x3cf163[_0x3bb8('0x21')]==_0x33fc1e?-0x1:_0x108144[_0x3bb8('0x21')]==_0x33fc1e?0x1:0x0;})[_0x3bb8('0xc')](_0x408d4e=>_0x408d4e[_0x3bb8('0x21')]);}get[_0x3bb8('0x1b')](){const _0x685736=new Map();for(const _0x5141e2 of Array[_0x3bb8('0x9')](this[_0x3bb8('0xa')]))for(const [_0x2d8210,_0x25aebf]of _0x5141e2())_0x685736[_0x3bb8('0x1e')](_0x2d8210,_0x25aebf);return _0x685736;}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x4f89=['requires','pluginName','_selectedAnnotations','EditorAnnotations','attach','set','has','editor','inlineannotations-not-allowed-with-context','context','getSelection','focus','blur','keystrokes','destroy','change:height','setActiveAnnotation','update','inline','clear','editableElement','add','editing','Esc','inlineannotations-attach-already-attached','addObserver','get','_annotations','visibleView','remove','_manuallyClosed','_addedAnnotations','view','register','isAttached','plugins','change:visibleView','hasView','activeAnnotation','document','updatePosition','_setSelectedAnnotations','stopListening','targetRect','getByView','bind','_balloon','_removeAnnotationFromBalloon','focusTracker','selection','refresh','afterInit','InlineAnnotations','_addAnnotationToBalloon','mousedown','isFocused','change:isFocused','inlineannotations-detach-not-attached','switchTo','listenTo','detach','delete','isActive'];(function(_0x54c6cf,_0x4f89b1){const _0x586297=function(_0x533c10){while(--_0x533c10){_0x54c6cf['push'](_0x54c6cf['shift']());}};_0x586297(++_0x4f89b1);}(_0x4f89,0x1c8));const _0x5862=function(_0x54c6cf,_0x4f89b1){_0x54c6cf=_0x54c6cf-0x0;let _0x586297=_0x4f89[_0x54c6cf];return _0x586297;};import{Plugin as _0x128311}from'ckeditor5/src/core';import _0x235bac from'./annotationsuis';import _0x7e1d97 from'./editorannotations';import{ContextualBalloon as _0xe5f3c5}from'ckeditor5/src/ui';import{MouseObserver as _0x5c3f10}from'ckeditor5/src/engine';import{CKEditorError as _0x15c006}from'ckeditor5/src/utils';import'./../../theme/annotation-inline.css';export default class a extends _0x128311{static get[_0x5862('0x30')](){return[_0x7e1d97,_0xe5f3c5,_0x235bac];}static get[_0x5862('0x31')](){return _0x5862('0x25');}constructor(_0x577613){super(_0x577613),_0x577613[_0x5862('0x7')][_0x5862('0x11')][_0x5862('0xa')](_0x5c3f10),this['isAttached']=!0x1,this[_0x5862('0x35')](_0x5862('0x17'),null),this[_0x5862('0xc')]=null,this[_0x5862('0xf')]=new Set(),this[_0x5862('0x1f')]=_0x577613[_0x5862('0x14')][_0x5862('0xb')](_0xe5f3c5),this['_addedAnnotations']=new Set(),this[_0x5862('0x32')]=[];}['init'](){const _0x5e73fb=this[_0x5862('0x37')]['plugins'][_0x5862('0xb')](_0x235bac);_0x5e73fb[_0x5862('0x39')]===this[_0x5862('0x37')]&&(_0x5e73fb[_0x5862('0x12')](_0x5862('0x3'),this),this[_0x5862('0x37')][_0x5862('0x3d')][_0x5862('0x35')](_0x5862('0x8'),(_0x2ca8d1,_0x35494f)=>{const _0x4c99a7=this[_0x5862('0x1f')];if(this[_0x5862('0x13')]&&_0x4c99a7['visibleView']){const _0x322092=this[_0x5862('0xc')][_0x5862('0x1d')](_0x4c99a7['visibleView']);this[_0x5862('0xf')]['add'](_0x322092),this[_0x5862('0x20')](_0x322092),_0x35494f();}}));}[_0x5862('0x24')](){const _0x59aa7a=this[_0x5862('0x37')][_0x5862('0x14')]['get'](_0x235bac);_0x59aa7a['context']===this[_0x5862('0x37')]&&(_0x59aa7a['hasActive']()||_0x59aa7a[_0x5862('0x2b')]('inline'));}[_0x5862('0x1')](_0x3ef6ec){_0x3ef6ec!==this[_0x5862('0x17')]&&(this['activeAnnotation']&&(this['activeAnnotation'][_0x5862('0x2f')]=!0x1),_0x3ef6ec&&this[_0x5862('0x37')]['ui'][_0x5862('0x21')][_0x5862('0x28')]&&(this[_0x5862('0x26')](_0x3ef6ec,!0x0),_0x3ef6ec[_0x5862('0x2f')]=!0x0),_0x3ef6ec||this[_0x5862('0x1a')]([]),this[_0x5862('0x17')]=_0x3ef6ec);}[_0x5862('0x34')](_0x59d18b){this[_0x5862('0xc')]=_0x59d18b;const _0x5cb023=this[_0x5862('0x37')][_0x5862('0x14')]['get'](_0x235bac),_0x2ac759=this['_balloon'];if(this['isAttached'])throw new _0x15c006(_0x5862('0x9'),this);if(_0x5cb023[_0x5862('0x39')]!==this['editor'])throw new _0x15c006(_0x5862('0x38'),this);const _0x2b8789=this[_0x5862('0x37')][_0x5862('0x14')]['get'](_0x5862('0x33'));this[_0x5862('0x2c')](_0x2b8789,_0x5862('0x23'),function(){const _0x4a679c=_0x2b8789['getOrderedSelectedAnnotations']({'activeAnnotation':this['activeAnnotation'],'annotations':this[_0x5862('0xc')]});this[_0x5862('0x1a')](_0x4a679c),this['setActiveAnnotation'](_0x4a679c[0x0]||null);}[_0x5862('0x1e')](this)),this[_0x5862('0x2c')](_0x2b8789,_0x5862('0x3c'),(_0x11fc11,{isAnnotationTracked:_0x2a7784})=>{this['activeAnnotation']&&_0x2a7784(this[_0x5862('0x17')])&&(this['_setSelectedAnnotations']([]),this[_0x5862('0x1')](null));}),this[_0x5862('0x2c')](this['editor']['ui'][_0x5862('0x21')],_0x5862('0x29'),(_0x594c2d,_0x22f5dc,_0x350c47)=>{_0x350c47||this[_0x5862('0x1')](null);}),this[_0x5862('0x2c')](_0x59d18b,_0x5862('0xe'),(_0x22a99a,_0x12f404)=>{this['_removeAnnotationFromBalloon'](_0x12f404),_0x12f404===this[_0x5862('0x17')]&&this[_0x5862('0x1')](null);}),this[_0x5862('0x2c')](_0x2ac759,_0x5862('0x15'),(_0x3bf079,_0x4068f2,_0x53ee2d,_0x9fe385)=>{if(_0x9fe385&&this[_0x5862('0x1b')](_0x9fe385),!_0x53ee2d||!_0x59d18b['getByView'](_0x53ee2d))return;const _0x3e7f61=_0x59d18b[_0x5862('0x1d')](_0x53ee2d);this[_0x5862('0x2c')](_0x53ee2d,_0x5862('0x0'),()=>{_0x2ac759[_0x5862('0x19')]();}),this['listenTo'](_0x53ee2d,_0x5862('0x8'),()=>{this[_0x5862('0xf')][_0x5862('0x6')](_0x3e7f61),this[_0x5862('0x20')](_0x3e7f61),this[_0x5862('0x37')][_0x5862('0x7')]['view']['focus']();}),this[_0x5862('0x17')]!==_0x3e7f61&&this[_0x5862('0x1')](_0x3e7f61);}),this[_0x5862('0x2c')](this[_0x5862('0x37')]['ui'],_0x5862('0x2'),()=>{_0x2ac759[_0x5862('0xd')]&&(_0x59d18b['getByView'](_0x2ac759['visibleView'])&&_0x2ac759[_0x5862('0x19')]());}),this['listenTo'](this[_0x5862('0x37')][_0x5862('0x7')][_0x5862('0x11')][_0x5862('0x18')],_0x5862('0x27'),()=>{this['_manuallyClosed'][_0x5862('0x4')]();}),this[_0x5862('0x37')][_0x5862('0x7')]['view'][_0x5862('0x18')][_0x5862('0x22')][_0x5862('0x5')]&&this['editor'][_0x5862('0x7')]['view'][_0x5862('0x3b')](),this[_0x5862('0x13')]=!0x0;}[_0x5862('0x2d')](){if(!this[_0x5862('0x13')])throw new _0x15c006(_0x5862('0x2a'),this);this['setActiveAnnotation'](null);for(const _0x46fe1b of this[_0x5862('0x10')])this[_0x5862('0x20')](_0x46fe1b);this[_0x5862('0x1b')](),this['isAttached']=!0x1;}[_0x5862('0x3e')](){this[_0x5862('0x13')]&&this[_0x5862('0x2d')]();}[_0x5862('0x1a')](_0x6d3ada){const _0x1c9ace=this[_0x5862('0x32')];for(const _0x2500f2 of _0x1c9ace)_0x6d3ada['includes'](_0x2500f2)||this[_0x5862('0xf')][_0x5862('0x2e')](_0x2500f2);for(const _0x264c4e of this[_0x5862('0xc')])_0x6d3ada['includes'](_0x264c4e)||this[_0x5862('0x20')](_0x264c4e);if(this[_0x5862('0x37')]['ui'][_0x5862('0x21')][_0x5862('0x28')])for(const _0x25ae38 of _0x6d3ada)this['_addAnnotationToBalloon'](_0x25ae38);this['_selectedAnnotations']=_0x6d3ada;}[_0x5862('0x26')](_0x4684f9,_0x4acdd7){this['_manuallyClosed']['has'](_0x4684f9)||(this[_0x5862('0x10')][_0x5862('0x36')](_0x4684f9)||this['_balloon'][_0x5862('0x16')](_0x4684f9[_0x5862('0x11')])||(this['_addedAnnotations'][_0x5862('0x6')](_0x4684f9),this['_balloon'][_0x5862('0x6')]({'stackId':_0x4684f9['view']['id'],'view':_0x4684f9[_0x5862('0x11')],'position':{'target':()=>_0x4684f9['target']||_0x4684f9[_0x5862('0x1c')]||document[_0x5862('0x3a')]()['getRangeAt'](0x0)}})),_0x4acdd7&&this[_0x5862('0x1f')]['showStack'](_0x4684f9[_0x5862('0x11')]['id']));}[_0x5862('0x20')](_0x268989){this[_0x5862('0x10')][_0x5862('0x36')](_0x268989)&&this[_0x5862('0x1f')][_0x5862('0x16')](_0x268989[_0x5862('0x11')])&&(this['_addedAnnotations'][_0x5862('0x2e')](_0x268989),this[_0x5862('0x1f')]['remove'](_0x268989['view']));}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x5b15=['_manuallyClosedAnnotationViews','get','change:container','esc','set','_updateBalloonPosition','stopListening','_editorAnnotations','locale','uiUpdate','rearrange','southArrowNorthWest','NarrowSidebar','_integrateWithEditorAnnotations','attachToDom','off','register','_showBalloon','delete','northArrowSouthEast','_destroyEditorAnnotationsIntegration','_annotations','has','keyCode','EditorAnnotations','refreshPositioning','southArrowNorthEast','getSidebarItemView','_attachToContainer','_refreshPositioning','_domEmitter','isDirty','from','target','editors','annotationType','clear','bind','bodyCollection','detach','balloonPanelView','unpin','create','southArrowNorth','remove','contains','preventDefault','stop','first','detachFromDom','focus','plugins','add','narrowSidebar','number','init','addAnnotation','_attachListeners','Esc','isAttached','execute','keydown','isVisible','set:container','Sidebar','defaultPositions','hasDomSelection','mousedown','listenTo','values','_throttledRefreshPositioning','getByView','content','getOrderedSelectedAnnotations','northArrowSouthWest','activeAnnotation','destroy','requires','blur','removeEventListener','cancel','ck-sidebar--narrow','view','_annotationToNarrowView','_setSelectedAnnotations','ready','narrowsidebar-detach-not-attached','pin','setActiveAnnotation','resize','_detachListeners','preventClosingBalloon','_hideBalloon','high','refresh','element','context','_selectedAnnotations','northArrowSouth'];(function(_0x42dd08,_0x5b1544){const _0x2f49ed=function(_0x360a24){while(--_0x360a24){_0x42dd08['push'](_0x42dd08['shift']());}};_0x2f49ed(++_0x5b1544);}(_0x5b15,0x17d));const _0x2f49=function(_0x42dd08,_0x5b1544){_0x42dd08=_0x42dd08-0x0;let _0x2f49ed=_0x5b15[_0x42dd08];return _0x2f49ed;};import{ContextPlugin as _0x203678}from'ckeditor5/src/core';import _0x3f762a from'./annotationsuis';import _0x4fa331 from'./sidebar';import _0x478ceb from'./view/annotationcounterbuttonview';import{BalloonPanelView as _0x2a16c0,BodyCollection as _0xe17308}from'ckeditor5/src/ui';import{CKEditorError as _0x2f6cd1,DomEmitterMixin as _0x269581,keyCodes as _0x261e15,Collection as _0x39d40d}from'ckeditor5/src/utils';import'../../theme/sidebar-narrow.css';import{throttle as _0x8ff5d5}from'lodash-es';export default class s extends _0x203678{static get[_0x2f49('0x5c')](){return[_0x4fa331,_0x3f762a];}static get['pluginName'](){return _0x2f49('0x1b');}constructor(_0x158c60){super(_0x158c60),this[_0x2f49('0x4a')]=!0x1,this['_manuallyClosedAnnotationViews']=new Set(),this[_0x2f49('0x2d')]=Object[_0x2f49('0x39')](_0x269581),this['_annotationToNarrowView']=new Map(),this[_0x2f49('0x13')](_0x2f49('0x5a'),null),this['_annotations']=null,this[_0x2f49('0xd')]=[],this[_0x2f49('0x16')]=new _0x39d40d(),this[_0x2f49('0x55')]=_0x8ff5d5(()=>{this['_refreshPositioning']();},0x190,{'leading':!0x1});}[_0x2f49('0x46')](){this[_0x2f49('0xc')][_0x2f49('0x42')][_0x2f49('0x10')](_0x3f762a)[_0x2f49('0x1f')](_0x2f49('0x44'),this),this[_0x2f49('0x35')]=new _0xe17308(this[_0x2f49('0xc')][_0x2f49('0x17')]),this[_0x2f49('0x37')]=new _0x2a16c0(this[_0x2f49('0xc')][_0x2f49('0x17')]),this[_0x2f49('0x35')][_0x2f49('0x1d')](),this[_0x2f49('0x35')][_0x2f49('0x43')](this[_0x2f49('0x37')]);}['attach'](_0x4dc3f5){this[_0x2f49('0x24')]=_0x4dc3f5;const _0x3cff2b=this[_0x2f49('0xc')][_0x2f49('0x42')][_0x2f49('0x10')](_0x4fa331),_0xe360ea=this['balloonPanelView'];if(_0x3cff2b['_annotations']=_0x4dc3f5,this[_0x2f49('0x4a')])throw new _0x2f6cd1('narrowsidebar-attach-already-attached',this);this[_0x2f49('0x4a')]=!0x0,this[_0x2f49('0x53')](_0x3cff2b,_0x2f49('0x4e'),()=>{this[_0x2f49('0x36')](),this[_0x2f49('0x53')](_0x3cff2b,_0x2f49('0x11'),_0x2341ff=>{_0x2341ff[_0x2f49('0x1e')](),this['attach'](_0x4dc3f5);});}),_0x3cff2b[_0x2f49('0x2b')]({'viewClass':_0x2f49('0x60'),'spaceBetweenItems':0x5});const _0x3dd13b=_0x3d5946=>{const _0x532152=new _0x478ceb(this['context']['locale']);_0x3cff2b[_0x2f49('0x47')](_0x3d5946,_0x532152),this['_annotationToNarrowView'][_0x2f49('0x13')](_0x3d5946,_0x532152),_0x532152[_0x2f49('0x34')](_0x2f49('0x2e'),_0x2f49('0x32'),_0x2f49('0x45'))['to'](_0x3d5946[_0x2f49('0x61')],'isDirty','type','length'),_0x532152['on'](_0x2f49('0x4b'),()=>{this[_0x2f49('0xf')][_0x2f49('0x33')](),_0xe360ea[_0x2f49('0x57')][_0x2f49('0x3f')]!==_0x3d5946[_0x2f49('0x61')]?(this[_0x2f49('0x20')](_0x3d5946),_0x3d5946[_0x2f49('0x61')][_0x2f49('0xb')][_0x2f49('0x41')](),this['setActiveAnnotation'](_0x3d5946)):this['setActiveAnnotation'](null);});};for(const _0x11c9c8 of _0x4dc3f5)_0x3dd13b(_0x11c9c8);this[_0x2f49('0x53')](_0x4dc3f5,_0x2f49('0x43'),(_0x3004a4,_0x22dc26)=>{_0x3dd13b(_0x22dc26);}),this[_0x2f49('0x53')](_0x4dc3f5,_0x2f49('0x3b'),(_0x4c8bbd,_0x289cf1,_0x29629e)=>{this[_0x2f49('0x62')]['get'](_0x289cf1)['destroy'](),this[_0x2f49('0x62')][_0x2f49('0x21')](_0x289cf1),_0x3cff2b[_0x2f49('0x19')]({'removedAnnotation':_0x289cf1,'previousAnnotation':_0x4dc3f5[_0x2f49('0x10')](_0x29629e-0x1),'nextAnnotation':_0x4dc3f5['get'](_0x29629e+0x1)}),_0x289cf1===this[_0x2f49('0x5a')]&&this[_0x2f49('0x4')](null);},{'priority':'low'}),this[_0x2f49('0x53')](_0x4dc3f5,_0x2f49('0x41'),(_0x489c5e,_0x5988e9)=>{this[_0x2f49('0x4')](_0x5988e9);}),this[_0x2f49('0x53')](_0x4dc3f5,_0x2f49('0x5d'),()=>{this[_0x2f49('0x4')](null);}),this[_0x2f49('0x2d')][_0x2f49('0x53')](document,_0x2f49('0x4c'),(_0x20255e,_0x3419be)=>{_0x3419be[_0x2f49('0x26')]===_0x261e15[_0x2f49('0x12')]&&_0xe360ea[_0x2f49('0x4d')]&&(this[_0x2f49('0xf')][_0x2f49('0x43')](_0xe360ea[_0x2f49('0x57')][_0x2f49('0x3f')]),this['_hideBalloon'](),_0x3419be['stopPropagation'](),_0x3419be[_0x2f49('0x3d')]());}),this['_domEmitter'][_0x2f49('0x53')](document,_0x2f49('0x52'),(_0x2e3783,_0x2115ec)=>{const _0x1a02c9=_0x2115ec[_0x2f49('0x30')];_0xe360ea[_0x2f49('0x4d')]&&_0xe360ea[_0x2f49('0xb')]['contains'](_0x1a02c9)||_0x3cff2b[_0x2f49('0x61')][_0x2f49('0xb')][_0x2f49('0x3c')](_0x1a02c9)||_0x2e3783[_0x2f49('0x7')]||(this[_0x2f49('0xf')][_0x2f49('0x33')](),this[_0x2f49('0x8')](),this[_0x2f49('0x4')](null));});const _0x3bffb2=this[_0x2f49('0xc')]['editors']?this['context'][_0x2f49('0x31')]:new _0x39d40d([this[_0x2f49('0xc')]]);for(const _0x45ed50 of _0x3bffb2)this[_0x2f49('0x1c')](_0x45ed50);this[_0x2f49('0x53')](_0x3bffb2,_0x2f49('0x43'),(_0x49ca04,_0x44d6a9)=>{this['listenTo'](_0x44d6a9,_0x2f49('0x1'),()=>{this[_0x2f49('0x1c')](_0x44d6a9);});}),this[_0x2f49('0x53')](_0x3bffb2,_0x2f49('0x3b'),(_0x3bf1cd,_0x2b1883)=>{_0x2b1883[_0x2f49('0x42')][_0x2f49('0x25')]('EditorAnnotations')&&this['_destroyEditorAnnotationsIntegration'](_0x2b1883[_0x2f49('0x42')]['get'](_0x2f49('0x27')));}),window['addEventListener'](_0x2f49('0x5'),this[_0x2f49('0x55')]),this[_0x2f49('0x2c')]();}[_0x2f49('0x4')](_0x1c03a3){if(_0x1c03a3===this['activeAnnotation'])return;const _0x565e53=this[_0x2f49('0xc')][_0x2f49('0x42')][_0x2f49('0x10')](_0x2f49('0x4f'));if(_0x565e53['refresh']({'blurredAnnotation':this[_0x2f49('0x5a')],'activatedAnnotation':_0x1c03a3,'disableAnimationOnActivatedAnnotation':!0x0}),_0x1c03a3)_0x565e53[_0x2f49('0x2a')](_0x1c03a3)?this[_0x2f49('0x20')](_0x1c03a3):this[_0x2f49('0x8')]();else this[_0x2f49('0x8')]();this[_0x2f49('0x5a')]=_0x1c03a3;}[_0x2f49('0x36')](){if(!this[_0x2f49('0x4a')])throw new _0x2f6cd1(_0x2f49('0x2'),this);this[_0x2f49('0x4')](null);const _0x3088ef=this['context'][_0x2f49('0x42')][_0x2f49('0x10')](_0x2f49('0x4f'));this['_hideBalloon'](),Array[_0x2f49('0x2f')](this[_0x2f49('0x62')][_0x2f49('0x54')](),_0x17e9a0=>_0x17e9a0[_0x2f49('0x5b')]()),this[_0x2f49('0x62')]['clear'](),_0x3088ef['_detachFromContainer'](this[_0x2f49('0x24')]),this[_0x2f49('0x15')](),this[_0x2f49('0x2d')][_0x2f49('0x15')](),this[_0x2f49('0x15')](this[_0x2f49('0xc')]['editors']);for(const _0x41eb89 of Array[_0x2f49('0x2f')](this['_editorAnnotations']))this[_0x2f49('0x23')](_0x41eb89);window[_0x2f49('0x5e')](_0x2f49('0x5'),this[_0x2f49('0x55')]),this[_0x2f49('0x55')][_0x2f49('0x5f')](),this['_selectedAnnotations']=[],this[_0x2f49('0x4a')]=!0x1,this[_0x2f49('0x24')]=null;}[_0x2f49('0x5b')](){this[_0x2f49('0x4a')]&&this[_0x2f49('0x36')](),this[_0x2f49('0x35')][_0x2f49('0x40')]();}['_integrateWithEditorAnnotations'](_0x4901a0){const _0x1b575b=_0x4901a0[_0x2f49('0x42')][_0x2f49('0x10')](_0x2f49('0x27')),_0x586c8a=this[_0x2f49('0xc')][_0x2f49('0x42')][_0x2f49('0x10')](_0x4fa331),_0x24b1bf=this['_annotations'],_0x167493=this[_0x2f49('0x37')],_0x4f43fb=()=>{const _0x38d727=_0x1b575b[_0x2f49('0x58')]({'activeAnnotation':this['activeAnnotation'],'annotations':this[_0x2f49('0x24')]});this[_0x2f49('0x0')](_0x38d727),this['setActiveAnnotation'](_0x38d727[0x0]||null);};this['listenTo'](_0x1b575b,_0x2f49('0xa'),_0x4f43fb),this[_0x2f49('0x53')](_0x1b575b,'blur',(_0x4fd268,{isAnnotationTracked:_0x9e65f8})=>{this['activeAnnotation']&&_0x9e65f8(this[_0x2f49('0x5a')])&&(this[_0x2f49('0x0')]([]),this[_0x2f49('0x4')](null));}),this[_0x2f49('0x53')](_0x1b575b,_0x2f49('0x18'),()=>{this[_0x2f49('0x55')]();}),this['listenTo'](_0x24b1bf,_0x2f49('0x5d'),_0x4fe70a=>{_0x1b575b['hasDomSelection']()&&_0x4fe70a[_0x2f49('0x3e')]();},{'priority':_0x2f49('0x9')}),this[_0x2f49('0x2d')][_0x2f49('0x53')](document,_0x2f49('0x52'),(_0x101d09,_0x1e09c9)=>{const _0x482030=_0x1e09c9[_0x2f49('0x30')];_0x167493['isVisible']&&_0x167493[_0x2f49('0xb')][_0x2f49('0x3c')](_0x482030)||_0x586c8a[_0x2f49('0x61')]['element']['contains'](_0x482030)||this[_0x2f49('0x5a')]&&_0x1b575b[_0x2f49('0x51')]()&&(_0x4f43fb(),_0x101d09[_0x2f49('0x7')]=!0x0);},{'priority':'high'}),this[_0x2f49('0x16')]['add'](_0x1b575b);}[_0x2f49('0x23')](_0x50a10c){_0x50a10c&&(this[_0x2f49('0x15')](_0x50a10c),this[_0x2f49('0x16')][_0x2f49('0x3b')](_0x50a10c));}[_0x2f49('0x0')](_0x488e06){for(const _0x2fa43b of this[_0x2f49('0xd')])_0x488e06['includes'](_0x2fa43b)||this[_0x2f49('0xf')][_0x2f49('0x21')](_0x2fa43b['view']);this['_selectedAnnotations']=_0x488e06;}[_0x2f49('0x2c')](){const _0x1a3e55=this['balloonPanelView'];this['_annotations'][_0x2f49('0x28')](),_0x1a3e55[_0x2f49('0x4d')]&&this[_0x2f49('0x14')]();}[_0x2f49('0x20')](_0x48ddc3){if(this['_manuallyClosedAnnotationViews'][_0x2f49('0x25')](_0x48ddc3['view']))return;const _0x46919c=this[_0x2f49('0x37')]['content']['first'];_0x46919c!==_0x48ddc3[_0x2f49('0x61')]?(_0x46919c&&this['_detachListeners'](_0x46919c),this[_0x2f49('0x48')](_0x48ddc3[_0x2f49('0x61')]),this[_0x2f49('0x37')][_0x2f49('0x57')][_0x2f49('0x33')](),this['balloonPanelView']['content'][_0x2f49('0x43')](_0x48ddc3[_0x2f49('0x61')]),this[_0x2f49('0x14')]()):this[_0x2f49('0x14')]();}['_updateBalloonPosition'](){const _0x361653=this['balloonPanelView'][_0x2f49('0x57')]['first'],_0x5e55b6=this[_0x2f49('0x24')][_0x2f49('0x56')](_0x361653);if(!this[_0x2f49('0x62')][_0x2f49('0x25')](_0x5e55b6))return;const _0x43c9f1=this['_annotationToNarrowView'][_0x2f49('0x10')](_0x5e55b6)['element'],_0x595249=function(){const _0xbcd568=_0x2a16c0[_0x2f49('0x50')];return[_0xbcd568[_0x2f49('0x29')],_0xbcd568[_0x2f49('0x22')],_0xbcd568[_0x2f49('0x3a')],_0xbcd568[_0x2f49('0xe')],_0xbcd568[_0x2f49('0x1a')],_0xbcd568[_0x2f49('0x59')]];}();this['balloonPanelView'][_0x2f49('0x3')]({'target':_0x43c9f1,'positions':_0x595249});}[_0x2f49('0x8')](){const _0x18b90e=this[_0x2f49('0x37')],_0x1ddc99=_0x18b90e[_0x2f49('0x57')][_0x2f49('0x3f')];_0x1ddc99&&(this[_0x2f49('0x6')](_0x1ddc99),_0x18b90e[_0x2f49('0x38')](),_0x18b90e[_0x2f49('0x57')][_0x2f49('0x33')]());}[_0x2f49('0x48')](_0x226e24){this[_0x2f49('0x53')](_0x226e24,'change:height',()=>this[_0x2f49('0x14')]()),this['listenTo'](_0x226e24,_0x2f49('0x49'),(_0x538f0c,_0x46ae66)=>{this[_0x2f49('0xf')][_0x2f49('0x43')](_0x226e24),this['_hideBalloon'](),_0x46ae66();});}[_0x2f49('0x6')](_0x3a10c8){this[_0x2f49('0x15')](_0x3a10c8);}}
|
|
23
|
+
const _0x1843=['refreshPositioning','attachToDom','_detachListeners','has','remove','detach','register','keydown','clear','NarrowSidebar','southArrowNorthWest','stopListening','isVisible','contains','unpin','_throttledRefreshPositioning','off','isDirty','preventDefault','_detachFromContainer','focus','_hideBalloon','target','get','element','_selectedAnnotations','listenTo','view','esc','destroy','context','ck-sidebar--narrow','resize','balloonPanelView','activeAnnotation','refresh','_annotations','values','length','high','preventClosingBalloon','setActiveAnnotation','bodyCollection','_attachToContainer','stop','locale','_manuallyClosedAnnotationViews','content','mousedown','northArrowSouthEast','plugins','narrowsidebar-detach-not-attached','cancel','_updateBalloonPosition','_attachListeners','Sidebar','requires','rearrange','blur','hasDomSelection','_refreshPositioning','set','change:container','narrowSidebar','detachFromDom','editors','addEventListener','getByView','pluginName','delete','_domEmitter','_annotationToNarrowView','_destroyEditorAnnotationsIntegration','addAnnotation','init','removeEventListener','first','narrowsidebar-attach-already-attached','attach','change:height','EditorAnnotations','isAttached','create','_showBalloon','_editorAnnotations','_setSelectedAnnotations','keyCode','_integrateWithEditorAnnotations','add','type'];(function(_0x5d929c,_0x184329){const _0xb9784f=function(_0x14f7a3){while(--_0x14f7a3){_0x5d929c['push'](_0x5d929c['shift']());}};_0xb9784f(++_0x184329);}(_0x1843,0x1ed));const _0xb978=function(_0x5d929c,_0x184329){_0x5d929c=_0x5d929c-0x0;let _0xb9784f=_0x1843[_0x5d929c];return _0xb9784f;};import{ContextPlugin as _0x53a403}from'ckeditor5/src/core';import _0x5d07ea from'./annotationsuis';import _0x536bdb from'./sidebar';import _0x220f8b from'./view/annotationcounterbuttonview';import{BalloonPanelView as _0x4143a6,BodyCollection as _0x529ac2}from'ckeditor5/src/ui';import{CKEditorError as _0x556d90,DomEmitterMixin as _0x559ff9,keyCodes as _0x2d3321,Collection as _0x8692ab}from'ckeditor5/src/utils';import'../../theme/sidebar-narrow.css';import{throttle as _0x33c2a0}from'lodash-es';export default class s extends _0x53a403{static get[_0xb978('0xd')](){return[_0x536bdb,_0x5d07ea];}static get[_0xb978('0x19')](){return _0xb978('0x38');}constructor(_0x29ebfa){super(_0x29ebfa),this['isAttached']=!0x1,this[_0xb978('0x3')]=new Set(),this[_0xb978('0x1b')]=Object[_0xb978('0x27')](_0x559ff9),this[_0xb978('0x1c')]=new Map(),this[_0xb978('0x12')](_0xb978('0x51'),null),this[_0xb978('0x53')]=null,this[_0xb978('0x48')]=[],this[_0xb978('0x29')]=new _0x8692ab(),this['_throttledRefreshPositioning']=_0x33c2a0(()=>{this[_0xb978('0x11')]();},0x190,{'leading':!0x1});}[_0xb978('0x1f')](){this[_0xb978('0x4d')][_0xb978('0x7')][_0xb978('0x46')](_0x5d07ea)[_0xb978('0x35')](_0xb978('0x14'),this),this[_0xb978('0x59')]=new _0x529ac2(this[_0xb978('0x4d')][_0xb978('0x2')]),this[_0xb978('0x50')]=new _0x4143a6(this[_0xb978('0x4d')][_0xb978('0x2')]),this[_0xb978('0x59')][_0xb978('0x30')](),this['bodyCollection'][_0xb978('0x2d')](this[_0xb978('0x50')]);}[_0xb978('0x23')](_0x33f11c){this['_annotations']=_0x33f11c;const _0xcb87c0=this['context']['plugins'][_0xb978('0x46')](_0x536bdb),_0x577ac6=this[_0xb978('0x50')];if(_0xcb87c0[_0xb978('0x53')]=_0x33f11c,this['isAttached'])throw new _0x556d90(_0xb978('0x22'),this);this[_0xb978('0x26')]=!0x0,this[_0xb978('0x49')](_0xcb87c0,'set:container',()=>{this[_0xb978('0x34')](),this[_0xb978('0x49')](_0xcb87c0,_0xb978('0x13'),_0x5f5ac3=>{_0x5f5ac3[_0xb978('0x3f')](),this[_0xb978('0x23')](_0x33f11c);});}),_0xcb87c0[_0xb978('0x0')]({'viewClass':_0xb978('0x4e'),'spaceBetweenItems':0x5});const _0x2c61db=_0xa88d72=>{const _0x49d563=new _0x220f8b(this[_0xb978('0x4d')][_0xb978('0x2')]);_0xcb87c0[_0xb978('0x1e')](_0xa88d72,_0x49d563),this['_annotationToNarrowView'][_0xb978('0x12')](_0xa88d72,_0x49d563),_0x49d563['bind']('isDirty','annotationType','number')['to'](_0xa88d72[_0xb978('0x4a')],_0xb978('0x40'),_0xb978('0x2e'),_0xb978('0x55')),_0x49d563['on']('execute',()=>{this[_0xb978('0x3')]['clear'](),_0x577ac6[_0xb978('0x4')][_0xb978('0x21')]!==_0xa88d72['view']?(this['_showBalloon'](_0xa88d72),_0xa88d72[_0xb978('0x4a')]['element']['focus'](),this['setActiveAnnotation'](_0xa88d72)):this[_0xb978('0x58')](null);});};for(const _0x3d7012 of _0x33f11c)_0x2c61db(_0x3d7012);this[_0xb978('0x49')](_0x33f11c,'add',(_0x3ce507,_0x17447c)=>{_0x2c61db(_0x17447c);}),this[_0xb978('0x49')](_0x33f11c,_0xb978('0x33'),(_0x1a0860,_0x24fb0e,_0x51f3d9)=>{this['_annotationToNarrowView'][_0xb978('0x46')](_0x24fb0e)['destroy'](),this[_0xb978('0x1c')][_0xb978('0x1a')](_0x24fb0e),_0xcb87c0[_0xb978('0xe')]({'removedAnnotation':_0x24fb0e,'previousAnnotation':_0x33f11c[_0xb978('0x46')](_0x51f3d9-0x1),'nextAnnotation':_0x33f11c[_0xb978('0x46')](_0x51f3d9+0x1)}),_0x24fb0e===this[_0xb978('0x51')]&&this[_0xb978('0x58')](null);},{'priority':'low'}),this[_0xb978('0x49')](_0x33f11c,_0xb978('0x43'),(_0x6062d8,_0x3ca5b8)=>{this[_0xb978('0x58')](_0x3ca5b8);}),this['listenTo'](_0x33f11c,_0xb978('0xf'),()=>{this[_0xb978('0x58')](null);}),this['_domEmitter'][_0xb978('0x49')](document,_0xb978('0x36'),(_0x23cae6,_0x845db4)=>{_0x845db4[_0xb978('0x2b')]===_0x2d3321[_0xb978('0x4b')]&&_0x577ac6[_0xb978('0x3b')]&&(this[_0xb978('0x3')][_0xb978('0x2d')](_0x577ac6[_0xb978('0x4')][_0xb978('0x21')]),this['_hideBalloon'](),_0x845db4['stopPropagation'](),_0x845db4[_0xb978('0x41')]());}),this[_0xb978('0x1b')][_0xb978('0x49')](document,_0xb978('0x5'),(_0x2a8e10,_0x5df01f)=>{const _0x49e25c=_0x5df01f['target'];_0x577ac6[_0xb978('0x3b')]&&_0x577ac6['element'][_0xb978('0x3c')](_0x49e25c)||_0xcb87c0[_0xb978('0x4a')][_0xb978('0x47')][_0xb978('0x3c')](_0x49e25c)||_0x2a8e10[_0xb978('0x57')]||(this[_0xb978('0x3')][_0xb978('0x37')](),this[_0xb978('0x44')](),this[_0xb978('0x58')](null));});const _0x4eb275=this[_0xb978('0x4d')]['editors']?this[_0xb978('0x4d')][_0xb978('0x16')]:new _0x8692ab([this['context']]);for(const _0x181c5b of _0x4eb275)this[_0xb978('0x2c')](_0x181c5b);this[_0xb978('0x49')](_0x4eb275,'add',(_0x5df7ee,_0x2923b4)=>{this['listenTo'](_0x2923b4,'ready',()=>{this['_integrateWithEditorAnnotations'](_0x2923b4);});}),this[_0xb978('0x49')](_0x4eb275,_0xb978('0x33'),(_0x62e9c4,_0x4905d2)=>{_0x4905d2[_0xb978('0x7')]['has'](_0xb978('0x25'))&&this[_0xb978('0x1d')](_0x4905d2['plugins'][_0xb978('0x46')](_0xb978('0x25')));}),window[_0xb978('0x17')](_0xb978('0x4f'),this[_0xb978('0x3e')]),this[_0xb978('0x11')]();}[_0xb978('0x58')](_0x1965ea){if(_0x1965ea===this[_0xb978('0x51')])return;const _0x50c019=this[_0xb978('0x4d')][_0xb978('0x7')][_0xb978('0x46')](_0xb978('0xc'));if(_0x50c019['refresh']({'blurredAnnotation':this[_0xb978('0x51')],'activatedAnnotation':_0x1965ea,'disableAnimationOnActivatedAnnotation':!0x0}),_0x1965ea)_0x50c019['getSidebarItemView'](_0x1965ea)?this['_showBalloon'](_0x1965ea):this[_0xb978('0x44')]();else this[_0xb978('0x44')]();this[_0xb978('0x51')]=_0x1965ea;}[_0xb978('0x34')](){if(!this['isAttached'])throw new _0x556d90(_0xb978('0x8'),this);this['setActiveAnnotation'](null);const _0xa4a826=this[_0xb978('0x4d')][_0xb978('0x7')][_0xb978('0x46')](_0xb978('0xc'));this[_0xb978('0x44')](),Array['from'](this[_0xb978('0x1c')][_0xb978('0x54')](),_0x4070d7=>_0x4070d7[_0xb978('0x4c')]()),this[_0xb978('0x1c')]['clear'](),_0xa4a826[_0xb978('0x42')](this[_0xb978('0x53')]),this[_0xb978('0x3a')](),this[_0xb978('0x1b')]['stopListening'](),this['stopListening'](this[_0xb978('0x4d')][_0xb978('0x16')]);for(const _0x3569f0 of Array['from'](this['_editorAnnotations']))this['_destroyEditorAnnotationsIntegration'](_0x3569f0);window[_0xb978('0x20')](_0xb978('0x4f'),this[_0xb978('0x3e')]),this[_0xb978('0x3e')][_0xb978('0x9')](),this[_0xb978('0x48')]=[],this[_0xb978('0x26')]=!0x1,this['_annotations']=null;}[_0xb978('0x4c')](){this[_0xb978('0x26')]&&this['detach'](),this[_0xb978('0x59')][_0xb978('0x15')]();}[_0xb978('0x2c')](_0x338d35){const _0x411798=_0x338d35[_0xb978('0x7')][_0xb978('0x46')](_0xb978('0x25')),_0x4220d1=this[_0xb978('0x4d')][_0xb978('0x7')][_0xb978('0x46')](_0x536bdb),_0x11c8c1=this['_annotations'],_0x2c6c2e=this[_0xb978('0x50')],_0x166a27=()=>{const _0x56ae60=_0x411798['getOrderedSelectedAnnotations']({'activeAnnotation':this[_0xb978('0x51')],'annotations':this[_0xb978('0x53')]});this['_setSelectedAnnotations'](_0x56ae60),this[_0xb978('0x58')](_0x56ae60[0x0]||null);};this[_0xb978('0x49')](_0x411798,_0xb978('0x52'),_0x166a27),this['listenTo'](_0x411798,_0xb978('0xf'),(_0x34e604,{isAnnotationTracked:_0x1add6e})=>{this[_0xb978('0x51')]&&_0x1add6e(this[_0xb978('0x51')])&&(this['_setSelectedAnnotations']([]),this[_0xb978('0x58')](null));}),this[_0xb978('0x49')](_0x411798,'uiUpdate',()=>{this[_0xb978('0x3e')]();}),this[_0xb978('0x49')](_0x11c8c1,'blur',_0x389a21=>{_0x411798[_0xb978('0x10')]()&&_0x389a21[_0xb978('0x1')]();},{'priority':_0xb978('0x56')}),this[_0xb978('0x1b')][_0xb978('0x49')](document,_0xb978('0x5'),(_0xebc7a0,_0x31dd18)=>{const _0x5501fc=_0x31dd18[_0xb978('0x45')];_0x2c6c2e[_0xb978('0x3b')]&&_0x2c6c2e[_0xb978('0x47')][_0xb978('0x3c')](_0x5501fc)||_0x4220d1[_0xb978('0x4a')][_0xb978('0x47')]['contains'](_0x5501fc)||this[_0xb978('0x51')]&&_0x411798['hasDomSelection']()&&(_0x166a27(),_0xebc7a0[_0xb978('0x57')]=!0x0);},{'priority':'high'}),this[_0xb978('0x29')][_0xb978('0x2d')](_0x411798);}['_destroyEditorAnnotationsIntegration'](_0x470ffe){_0x470ffe&&(this[_0xb978('0x3a')](_0x470ffe),this[_0xb978('0x29')]['remove'](_0x470ffe));}[_0xb978('0x2a')](_0x4fd009){for(const _0x4c8721 of this[_0xb978('0x48')])_0x4fd009['includes'](_0x4c8721)||this[_0xb978('0x3')][_0xb978('0x1a')](_0x4c8721[_0xb978('0x4a')]);this[_0xb978('0x48')]=_0x4fd009;}['_refreshPositioning'](){const _0x1583a0=this[_0xb978('0x50')];this[_0xb978('0x53')][_0xb978('0x2f')](),_0x1583a0[_0xb978('0x3b')]&&this['_updateBalloonPosition']();}[_0xb978('0x28')](_0x184ac3){if(this[_0xb978('0x3')][_0xb978('0x32')](_0x184ac3[_0xb978('0x4a')]))return;const _0x355e97=this[_0xb978('0x50')]['content'][_0xb978('0x21')];_0x355e97!==_0x184ac3[_0xb978('0x4a')]?(_0x355e97&&this['_detachListeners'](_0x355e97),this['_attachListeners'](_0x184ac3[_0xb978('0x4a')]),this[_0xb978('0x50')]['content'][_0xb978('0x37')](),this[_0xb978('0x50')][_0xb978('0x4')][_0xb978('0x2d')](_0x184ac3[_0xb978('0x4a')]),this[_0xb978('0xa')]()):this[_0xb978('0xa')]();}[_0xb978('0xa')](){const _0x8a01fc=this[_0xb978('0x50')][_0xb978('0x4')]['first'],_0x4b565b=this['_annotations'][_0xb978('0x18')](_0x8a01fc);if(!this[_0xb978('0x1c')]['has'](_0x4b565b))return;const _0x3b7c77=this[_0xb978('0x1c')]['get'](_0x4b565b)[_0xb978('0x47')],_0x5476b3=function(){const _0x317038=_0x4143a6['defaultPositions'];return[_0x317038['southArrowNorthEast'],_0x317038[_0xb978('0x6')],_0x317038['southArrowNorth'],_0x317038['northArrowSouth'],_0x317038[_0xb978('0x39')],_0x317038['northArrowSouthWest']];}();this[_0xb978('0x50')]['pin']({'target':_0x3b7c77,'positions':_0x5476b3});}['_hideBalloon'](){const _0x26618d=this[_0xb978('0x50')],_0x432bf6=_0x26618d[_0xb978('0x4')][_0xb978('0x21')];_0x432bf6&&(this[_0xb978('0x31')](_0x432bf6),_0x26618d[_0xb978('0x3d')](),_0x26618d['content']['clear']());}[_0xb978('0xb')](_0x1a9f0c){this[_0xb978('0x49')](_0x1a9f0c,_0xb978('0x24'),()=>this[_0xb978('0xa')]()),this['listenTo'](_0x1a9f0c,'Esc',(_0xc64974,_0x4852e0)=>{this[_0xb978('0x3')][_0xb978('0x2d')](_0x1a9f0c),this[_0xb978('0x44')](),_0x4852e0();});}[_0xb978('0x31')](_0x3740d2){this[_0xb978('0x3a')](_0x3740d2);}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x5636=['isActive','getSidebarItemView','addAnnotation','_updateLastItem','config','element','bottom','max','minHeight','_sidebarItemViewToAnnotation','locale','_destroySidebarItemView','_annotationToSidebarItemView','getIndex','_targetTop','_getItemAfter','targetRect','_getItemBefore','refresh','change:top','_annotations','sidebar.container','_setItemTop','change:targetRect','unbind','list','height','sidebar-attachtocontainer-missing-container','appendChild','container','pluginName','define','_alignAfterItem','class','remove','destroy','_getTargetTop','target','init','Sidebar','updateHeight','delete','top','add','_alignBeforeItem','_activeAnnotation','sidebar.preventScrollOutOfView','set','stopListening','view','isAnimationDisabled','_spaceBetweenItems','listenTo','clear','get','content','length','_alignToTargetRect','setContainer','context','sidebar-setcontainer-invalid-element'];(function(_0x13c60d,_0x563682){const _0x5e96fe=function(_0x345068){while(--_0x345068){_0x13c60d['push'](_0x13c60d['shift']());}};_0x5e96fe(++_0x563682);}(_0x5636,0x69));const _0x5e96=function(_0x13c60d,_0x563682){_0x13c60d=_0x13c60d-0x0;let _0x5e96fe=_0x5636[_0x13c60d];return _0x5e96fe;};import{ContextPlugin as _0x599806}from'ckeditor5/src/core';import _0x5af177 from'./view/sidebarview';import _0x2f9e08 from'./view/sidebaritemview';import{Rect as _0x300841,CKEditorError as _0x575631}from'ckeditor5/src/utils';import{isElement as _0x4568e7,throttle as _0x5cf3c5}from'lodash-es';export default class b extends _0x599806{static get[_0x5e96('0x2f')](){return _0x5e96('0x38');}constructor(_0x52226b){super(_0x52226b),this[_0x5e96('0x3')]('_lastItem'),this[_0x5e96('0x5')]=this['_createSidebarView'](),this[_0x5e96('0x3')]('container',null),this['_spaceBetweenItems']=0x19,this[_0x5e96('0x1a')]=new Map(),this[_0x5e96('0x1d')]=new Map(),this['context'][_0x5e96('0x15')][_0x5e96('0x30')](_0x5e96('0x2'),!0x1),this['_annotations']=null,this['_activeAnnotation']=null;}[_0x5e96('0x37')](){const _0x1b3d79=this[_0x5e96('0xf')]['config']['get'](_0x5e96('0x26'));_0x1b3d79&&this[_0x5e96('0xe')](_0x1b3d79);}['setContainer'](_0x52b848){if(!_0x4568e7(_0x52b848))throw new _0x575631(_0x5e96('0x10'));this[_0x5e96('0x2e')]=_0x52b848;}['_attachToContainer']({viewClass:_0x3c59b3='',spaceBetweenItems:_0x5f37e3=0x19}={}){if(!_0x4568e7(this[_0x5e96('0x2e')]))throw new _0x575631(_0x5e96('0x2c'),this);this[_0x5e96('0x2e')][_0x5e96('0x2d')](this[_0x5e96('0x5')]['element']),this[_0x5e96('0x5')][_0x5e96('0x32')]=_0x3c59b3,this[_0x5e96('0x7')]=_0x5f37e3;}['rearrange']({removedAnnotation:_0x3cb0f9,previousAnnotation:_0x3b2037,nextAnnotation:_0x496768}){const _0x35f329=this[_0x5e96('0x12')](_0x3cb0f9);this[_0x5e96('0x5')]['list']['remove'](_0x35f329),this[_0x5e96('0x1c')](_0x3cb0f9),_0x3b2037&&this[_0x5e96('0xd')](this[_0x5e96('0x12')](_0x3b2037)),_0x496768&&this[_0x5e96('0xd')](this[_0x5e96('0x12')](_0x496768)),this[_0x5e96('0x14')]();}[_0x5e96('0x23')]({blurredAnnotation:_0x47c201,activatedAnnotation:_0x44fb00,disableAnimationOnActivatedAnnotation:_0x43231b}){if(this[_0x5e96('0x1')]=_0x44fb00,_0x47c201){_0x47c201[_0x5e96('0x11')]=!0x1;const _0x2bd0d0=this[_0x5e96('0x12')](_0x47c201);_0x2bd0d0&&_0x43231b&&(_0x2bd0d0[_0x5e96('0x6')]=!0x1);}if(_0x44fb00){const _0x1d21d3=this[_0x5e96('0x12')](_0x44fb00);_0x1d21d3&&(_0x44fb00['isActive']=!0x0,_0x43231b&&(_0x1d21d3[_0x5e96('0x6')]=!0x0,_0x1d21d3[_0x5e96('0x3b')]+=0x1),this[_0x5e96('0xd')](_0x1d21d3));}}['_detachFromContainer'](_0x4e40af){this[_0x5e96('0x4')](),this[_0x5e96('0x5')][_0x5e96('0x16')][_0x5e96('0x33')]();for(const _0x482e98 of _0x4e40af)this[_0x5e96('0x1c')](_0x482e98);this['view']['list'][_0x5e96('0x9')](),this[_0x5e96('0x5')][_0x5e96('0x32')]='',this['_lastItem']=null;}[_0x5e96('0x13')](_0x4f5944,_0x598cb9){_0x598cb9||(_0x598cb9=_0x4f5944[_0x5e96('0x5')]);const _0x5cddcf=new _0x2f9e08(this['context']['locale']);this[_0x5e96('0x1a')][_0x5e96('0x3')](_0x5cddcf,_0x4f5944),this[_0x5e96('0x1d')]['set'](_0x4f5944,_0x5cddcf),_0x5cddcf[_0x5e96('0xb')][_0x5e96('0x3c')](_0x598cb9),this[_0x5e96('0xd')](_0x5cddcf),this[_0x5e96('0x8')](_0x4f5944[_0x5e96('0x5')],_0x5e96('0x28'),()=>{const _0x2edc12=this[_0x5e96('0x35')](_0x5cddcf);_0x5cddcf[_0x5e96('0x1f')]!=_0x2edc12&&(_0x5cddcf[_0x5e96('0x1f')]=_0x2edc12,this['_setItemTop'](_0x5cddcf,_0x2edc12));}),this[_0x5e96('0x8')](_0x5cddcf,_0x5e96('0x24'),_0x5cf3c5(()=>{if(!_0x5cddcf[_0x5e96('0xb')][_0x5e96('0xc')])return;const _0x2b90b4=this['_getItemBefore'](_0x5cddcf);if(!_0x2b90b4)return;const _0x2e0142=this[_0x5e96('0x1a')][_0x5e96('0xa')](_0x2b90b4),_0xab0bc7=this['_activeAnnotation'];_0xab0bc7&&_0xab0bc7===_0x2e0142?this[_0x5e96('0x31')](_0x2b90b4,_0x5cddcf):this['_alignBeforeItem'](_0x5cddcf,_0x2b90b4);},0xa,{'leading':!0x1})),this[_0x5e96('0x8')](_0x5cddcf,'change:bottom',_0x5cf3c5(()=>{if(!_0x5cddcf[_0x5e96('0xb')][_0x5e96('0xc')])return;const _0x4280cc=this[_0x5e96('0x20')](_0x5cddcf);if(!_0x4280cc)return;const _0x500ebe=this[_0x5e96('0x1a')][_0x5e96('0xa')](_0x4280cc),_0x3909f1=this[_0x5e96('0xf')][_0x5e96('0x15')][_0x5e96('0xa')]('sidebar.preventScrollOutOfView'),_0x320dae=this[_0x5e96('0x1')];_0x320dae&&_0x320dae===_0x500ebe&&_0x3909f1?(this['_alignBeforeItem'](_0x4280cc,_0x5cddcf),this[_0x5e96('0x31')](_0x5cddcf,_0x4280cc)):_0x320dae&&_0x320dae===_0x500ebe?this[_0x5e96('0x0')](_0x4280cc,_0x5cddcf):this[_0x5e96('0x31')](_0x5cddcf,_0x4280cc);},0xa,{'leading':!0x1}));const _0x21690a=this[_0x5e96('0x22')](_0x5cddcf);if(_0x21690a)this[_0x5e96('0x31')](_0x21690a,_0x5cddcf)||this['_alignToTargetRect'](_0x5cddcf);else this['_alignToTargetRect'](_0x5cddcf);return this['_updateLastItem'](),this[_0x5e96('0x5')][_0x5e96('0x2a')]['add'](_0x5cddcf),_0x5cddcf;}[_0x5e96('0x12')](_0x5fe8c7){return this[_0x5e96('0x1d')][_0x5e96('0xa')](_0x5fe8c7);}[_0x5e96('0x34')](){this['view']['destroy']();}[_0x5e96('0x1c')](_0x54c132){const _0x31451f=this[_0x5e96('0x12')](_0x54c132);this[_0x5e96('0x4')](_0x31451f),this[_0x5e96('0x4')](_0x54c132[_0x5e96('0x5')]),_0x31451f['destroy'](),this['_annotationToSidebarItemView']['delete'](_0x54c132),this[_0x5e96('0x1a')][_0x5e96('0x3a')](_0x31451f);}['_createSidebarView'](){const _0x2f74df=new _0x5af177(this[_0x5e96('0xf')][_0x5e96('0x1b')]);return _0x2f74df['render'](),this['on']('change:_lastItem',(_0x282aec,_0x588038,_0x2534fa,_0x5a0d30)=>{_0x5a0d30&&_0x2f74df[_0x5e96('0x29')](_0x5e96('0x19')),_0x2534fa?_0x2f74df['bind']('minHeight')['to'](_0x2534fa,_0x5e96('0x17')):_0x2f74df[_0x5e96('0x19')]=null;}),_0x2f74df;}[_0x5e96('0x14')](){this['_lastItem']=this[_0x5e96('0x12')](this[_0x5e96('0x25')]['last']);}[_0x5e96('0x22')](_0x49ae64){const _0x19c9cb=this[_0x5e96('0x1a')][_0x5e96('0xa')](_0x49ae64),_0x3cfca2=this['_annotations'][_0x5e96('0xa')](this[_0x5e96('0x25')][_0x5e96('0x1e')](_0x19c9cb)-0x1);return _0x3cfca2&&this['getSidebarItemView'](_0x3cfca2);}[_0x5e96('0x20')](_0x447ded){const _0x1d16c1=this[_0x5e96('0x1a')][_0x5e96('0xa')](_0x447ded),_0x43a435=this[_0x5e96('0x25')]['get'](this[_0x5e96('0x25')]['getIndex'](_0x1d16c1)+0x1);return _0x43a435&&this[_0x5e96('0x12')](_0x43a435);}[_0x5e96('0x0')](_0x4bd367,_0x3235b8){_0x4bd367[_0x5e96('0x39')]();const _0x1d35be=H(_0x3235b8['bottom']+this['_spaceBetweenItems'],_0x4bd367[_0x5e96('0x3b')]);return!!_0x1d35be&&(this[_0x5e96('0x27')](_0x3235b8,_0x3235b8[_0x5e96('0x3b')]-_0x1d35be),!0x0);}[_0x5e96('0x31')](_0x280a58,_0x18aa2b){_0x280a58[_0x5e96('0x39')]();const _0x16fcea=H(_0x280a58['bottom']+this[_0x5e96('0x7')],_0x18aa2b['top']);return!!_0x16fcea&&(this['_setItemTop'](_0x18aa2b,_0x18aa2b[_0x5e96('0x3b')]+_0x16fcea,!0x1),!0x0);}[_0x5e96('0xd')](_0x573451){const _0x527113=this[_0x5e96('0x1a')][_0x5e96('0xa')](_0x573451);if(!_0x527113||!_0x527113[_0x5e96('0x36')])return;const _0x5f463f=this[_0x5e96('0x35')](_0x573451);this[_0x5e96('0x27')](_0x573451,_0x5f463f);}[_0x5e96('0x35')](_0x4ddc80){const _0x29dd81=this[_0x5e96('0x1a')][_0x5e96('0xa')](_0x4ddc80);if(null===_0x29dd81['targetRect'])return 0x0;if(_0x29dd81[_0x5e96('0x36')]instanceof _0x300841)return _0x29dd81['targetRect'][_0x5e96('0x3b')];{const _0x1ddb33=new _0x300841(this['view'][_0x5e96('0x16')])[_0x5e96('0x3b')];return _0x29dd81[_0x5e96('0x21')][_0x5e96('0x3b')]-_0x1ddb33;}}[_0x5e96('0x27')](_0x1c9a73,_0x3d4184,_0x5e4c78=this[_0x5e96('0xf')]['config'][_0x5e96('0xa')](_0x5e96('0x2'))){_0x5e4c78&&(_0x3d4184=Math[_0x5e96('0x18')](_0x3d4184,this['_getMaxAvailableTop'](_0x1c9a73))),_0x1c9a73[_0x5e96('0x3b')]=_0x3d4184;}['_getMaxAvailableTop'](_0x14fef2){let _0x239d31=this[_0x5e96('0x22')](_0x14fef2),_0x42054c=0x0;for(;_0x239d31;)_0x239d31[_0x5e96('0x39')](),_0x42054c+=this['_spaceBetweenItems']+_0x239d31[_0x5e96('0x2b')],_0x239d31=this[_0x5e96('0x22')](_0x239d31);return _0x42054c;}}function H(_0x12999a,_0x4dad12){return Math[_0x5e96('0x18')](_0x12999a-_0x4dad12,0x0);}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2016 -
|
|
2
|
+
* Copyright (c) 2016 - 2022, 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 _0x139d=['annotationType','add','setTemplate','ck-annotation-counter','isDirty','_badge','icon','...','ck-annotation-counter__badge','set','ck-annotation-counter__badge--edit-mode','bind','counterView','number','span'];(function(_0x540025,_0x139df4){const _0x4c0511=function(_0x2ae88b){while(--_0x2ae88b){_0x540025['push'](_0x540025['shift']());}};_0x4c0511(++_0x139df4);}(_0x139d,0x1c5));const _0x4c05=function(_0x540025,_0x139df4){_0x540025=_0x540025-0x0;let _0x4c0511=_0x139d[_0x540025];return _0x4c0511;};import{ButtonView as _0x1a1cb7,View as _0x11a9dc}from'ckeditor5/src/ui';import _0x4ecc5d from'../../../theme/icons/add-comment.svg';export default class B extends _0x1a1cb7{constructor(_0x5bbc85){super(_0x5bbc85);const _0x5950b4=this['bindTemplate'];this['set'](_0x4c05('0x1'),!0x1),this[_0x4c05('0x6')](_0x4c05('0xa'),0x0),this[_0x4c05('0x8')](_0x4c05('0x2'))['to'](this,_0x4c05('0x1'),this,'number',(_0x58c1b3,_0x2ef73c)=>_0x58c1b3?_0x4c05('0x4'):_0x2ef73c),this[_0x4c05('0x6')](_0x4c05('0xc'),''),this[_0x4c05('0x3')]=_0x4ecc5d,this['extendTemplate']({'attributes':{'class':[_0x4c05('0x0')]}}),this[_0x4c05('0x9')]=new _0x11a9dc(),this[_0x4c05('0x9')][_0x4c05('0xe')]({'tag':_0x4c05('0xb'),'attributes':{'class':[_0x4c05('0x5'),_0x5950b4['to']('annotationType',_0x3d343d=>'ck-annotation-counter__badge--'+_0x3d343d),_0x5950b4['if']('isDirty',_0x4c05('0x7'))]},'children':[{'text':_0x5950b4['to'](_0x4c05('0x2'))}]}),this['children'][_0x4c05('0xd')](this[_0x4c05('0x9')]);}}
|