UNPKG

@ckeditor/ckeditor5-comments

Version:

Collaborative comments feature for CKEditor 5.

23 lines 9.6 kB
/* * Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved. * * * * * +---------------------------------------------------------------------------------+ * | | * | Hello stranger! | * | | * | | * | What you're currently looking at is the source code of a legally protected, | * | proprietary software. Any attempts to deobfuscate / disassemble this code | * | are forbidden and will result in legal consequences. | * | | * | | * +---------------------------------------------------------------------------------+ * * * * */ const _0x3a52cf=_0x466f;(function(_0x391eb5,_0x208cb4){const _0x28d19a=_0x466f,_0x32f0db=_0x391eb5();while(!![]){try{const _0x794506=parseInt(_0x28d19a(0x16e))/0x1*(-parseInt(_0x28d19a(0x169))/0x2)+parseInt(_0x28d19a(0x19f))/0x3+parseInt(_0x28d19a(0x172))/0x4*(parseInt(_0x28d19a(0x183))/0x5)+-parseInt(_0x28d19a(0x1a4))/0x6+parseInt(_0x28d19a(0x173))/0x7*(parseInt(_0x28d19a(0x1a6))/0x8)+parseInt(_0x28d19a(0x18b))/0x9*(-parseInt(_0x28d19a(0x186))/0xa)+parseInt(_0x28d19a(0x198))/0xb;if(_0x794506===_0x208cb4)break;else _0x32f0db['push'](_0x32f0db['shift']());}catch(_0x1edd7a){_0x32f0db['push'](_0x32f0db['shift']());}}}(_0x17b2,0x4e56e));import{ContextPlugin as _0x256338,Editor as _0x37cde6}from'ckeditor5/src/core.js';function _0x17b2(){const _0x580de4=['values','editing','9305252jUHiCp','source','escape','listenTo','_visibleAnnotations','_bindAnnotationsToVisibleAnnotations','ACCESSIBILITY_HELP_ANNOTATIONS_NAVIGATE_THREADS','993873RarJlt','remove','low','ACCESSIBILITY_HELP_ANNOTATIONS_BROWSE_GROUPS','stopListening','1377672asqrml','editors','8yGPuZy','ACCESSIBILITY_HELP_ANNOTATIONS_SUBMIT_COMMENT','ACCESSIBILITY_HELP_ANNOTATIONS_MOVE_TO','activeAnnotations','accessibility','refreshPositioning','_setupEscapeAnnotationHandling','domRoots','locale','keystrokes','Shift+Tab','ACCESSIBILITY_HELP_ANNOTATIONS_EXIT','view','change:isVisible','Enter','activate','focus','Ctrl+Enter','collection','29406tCapmi','add','createAnnotation','_addActiveAnnotation','createAnnotationView','23sgMrax','Arrowup','target','isVisible','951092JwUfLP','395269CpKjmB','destroy','delete','contains','ACCESSIBILITY_HELP_ANNOTATIONS_GROUP','Tab','Arrowdown','_setupEnterAnnotationKeystroke','ACCESSIBILITY_HELP_ANNOTATIONS_ENTER','isPremiumPlugin','ready','isArray','_deactivateAllAnnotations','refreshVisibility','isOfficialPlugin','focusTracker','5cxCoYc','element','addKeystrokeInfoGroup','971340PumgRN','_activateAnnotation','has','deactivateAll','set','54BRPBnO','_removeActiveAnnotation','pluginName','annotations','Esc','fire','Ctrl+Shift+E','Annotations','push','context','getByInnerView'];_0x17b2=function(){return _0x580de4;};return _0x17b2();}import{first as _0x59fb46}from'ckeditor5/src/utils.js';import{Annotation as _0x18e66d}from'./annotation.js';import{AnnotationCollection as _0x3f3e50}from'./annotationcollection.js';function _0x466f(_0x4fe22c,_0x5132f9){const _0x17b2a0=_0x17b2();return _0x466f=function(_0x466f3c,_0x3f881e){_0x466f3c=_0x466f3c-0x158;let _0x532a25=_0x17b2a0[_0x466f3c];return _0x532a25;},_0x466f(_0x4fe22c,_0x5132f9);}import{AnnotationView as _0xf7351e}from'./view/annotationview.js';import{getTranslation as _0xdfb0ef}from'../utils/common-translations.js';import{FOCUS_ANNOTATION_KEYSTROKE as _0x553de1}from'@ckeditor/ckeditor5-collaboration-core';export class Annotations extends _0x256338{[_0x3a52cf(0x168)];[_0x3a52cf(0x19c)];static get[_0x3a52cf(0x18d)](){const _0xdcb8e5=_0x3a52cf;return _0xdcb8e5(0x192);}static get[_0x3a52cf(0x181)](){return!0x0;}static get[_0x3a52cf(0x17c)](){return!0x0;}constructor(_0x20e864){const _0x367ee5=_0x3a52cf;if(super(_0x20e864),this[_0x367ee5(0x168)]=new _0x3f3e50(),this[_0x367ee5(0x19c)]=new _0x3f3e50(),this[_0x367ee5(0x18a)](_0x367ee5(0x159),new Set()),this[_0x367ee5(0x19d)](),_0x20e864 instanceof _0x37cde6){const _0x306c83=_0x20e864[_0x367ee5(0x15e)];_0x20e864[_0x367ee5(0x15a)][_0x367ee5(0x185)]({'id':_0x367ee5(0x18e),'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x177)),'keystrokes':[{'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x158)),'keystroke':_0x367ee5(0x191)},{'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x161)),'keystroke':_0x367ee5(0x18f)},{'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x17b)),'keystroke':_0x367ee5(0x164)},{'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x1a2)),'keystroke':[[_0x367ee5(0x178)],[_0x367ee5(0x160)]]},{'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x1a7)),'keystroke':[_0x367ee5(0x167)]},{'label':_0xdfb0ef(_0x306c83,_0x367ee5(0x19e)),'keystroke':[[_0x367ee5(0x16f)],[_0x367ee5(0x179)]]}]});}this[_0x367ee5(0x17a)](),this[_0x367ee5(0x15c)]();}[_0x3a52cf(0x16a)](_0x291597){const _0x2c16bf=_0x3a52cf;this[_0x2c16bf(0x168)][_0x2c16bf(0x16a)](_0x291597);}[_0x3a52cf(0x1a0)](_0x1a1a96){const _0x10a23f=_0x3a52cf;this[_0x10a23f(0x168)][_0x10a23f(0x1a0)](_0x1a1a96),_0x1a1a96[_0x10a23f(0x174)]();}[_0x3a52cf(0x180)](){const _0x4448b6=_0x3a52cf;for(const _0x4d42bf of this[_0x4448b6(0x168)])_0x4d42bf[_0x4448b6(0x180)]();}[_0x3a52cf(0x15b)](){const _0x5deac7=_0x3a52cf;this[_0x5deac7(0x19c)][_0x5deac7(0x15b)]();}[_0x3a52cf(0x195)](_0x5753e4){const _0x6c4cd=_0x3a52cf;return this[_0x6c4cd(0x168)][_0x6c4cd(0x195)](_0x5753e4);}[_0x3a52cf(0x189)](){const _0x4e0a68=_0x3a52cf;this[_0x4e0a68(0x190)](_0x4e0a68(0x17f));}[_0x3a52cf(0x174)](){const _0x56f881=_0x3a52cf;for(const _0x29850a of this[_0x56f881(0x168)])_0x29850a[_0x56f881(0x174)]();this[_0x56f881(0x19c)][_0x56f881(0x174)](),this[_0x56f881(0x168)][_0x56f881(0x174)](),super[_0x56f881(0x174)]();}[_0x3a52cf(0x165)](_0xa13b49){const _0xd98197=_0x3a52cf;this[_0xd98197(0x190)](_0xd98197(0x187),_0xa13b49);}[_0x3a52cf(0x16b)](_0x3c2e6e){return new _0x18e66d(_0x3c2e6e);}[_0x3a52cf(0x16d)](_0x1bf48f,_0x565026){return new _0xf7351e(_0x1bf48f,_0x565026);}[_0x3a52cf(0x16c)](_0x3a122f){const _0x49ae88=_0x3a52cf,_0x2b3290=new Set(this[_0x49ae88(0x159)]);_0x2b3290[_0x49ae88(0x16a)](_0x3a122f),this[_0x49ae88(0x159)]=_0x2b3290;}[_0x3a52cf(0x18c)](_0x362577){const _0xf9f1c4=_0x3a52cf,_0x226e3b=new Set(this[_0xf9f1c4(0x159)]);_0x226e3b[_0xf9f1c4(0x175)](_0x362577),this[_0xf9f1c4(0x159)]=_0x226e3b;}[_0x3a52cf(0x19d)](){const _0x261677=_0x3a52cf,_0x13997f=this[_0x261677(0x168)],_0x249ada=this[_0x261677(0x19c)];function _0x891379(_0x549ed2){const _0x56e860=_0x261677,_0x10766c=_0x549ed2[_0x56e860(0x199)];_0x10766c[_0x56e860(0x171)]&&!_0x249ada[_0x56e860(0x188)](_0x10766c)?_0x249ada[_0x56e860(0x16a)](_0x10766c):!_0x10766c[_0x56e860(0x171)]&&_0x249ada[_0x56e860(0x188)](_0x10766c)&&_0x249ada[_0x56e860(0x1a0)](_0x10766c),_0x10766c[_0x56e860(0x162)][_0x56e860(0x182)][_0x56e860(0x1a0)](_0x10766c[_0x56e860(0x162)][_0x56e860(0x184)]),_0x10766c[_0x56e860(0x162)][_0x56e860(0x182)][_0x56e860(0x16a)](_0x10766c[_0x56e860(0x162)][_0x56e860(0x184)]);}this[_0x261677(0x19b)](_0x13997f,_0x261677(0x16a),(_0x5524a5,_0x333511)=>{const _0x20df80=_0x261677;_0x333511[_0x20df80(0x171)]&&_0x249ada[_0x20df80(0x16a)](_0x333511),this[_0x20df80(0x19b)](_0x333511,_0x20df80(0x163),_0x891379);}),this[_0x261677(0x19b)](_0x13997f,_0x261677(0x1a0),(_0x4ef926,_0x30560b)=>{const _0x5c642d=_0x261677;_0x249ada[_0x5c642d(0x188)](_0x30560b)&&_0x249ada[_0x5c642d(0x1a0)](_0x30560b),this[_0x5c642d(0x1a3)](_0x30560b,_0x5c642d(0x163),_0x891379);});}[_0x3a52cf(0x17a)](){const _0x1e5c74=_0x3a52cf,_0x338dfb=_0xf60d04=>{const _0x4f2667=_0x466f;_0xf60d04['on'](_0x4f2667(0x17d),()=>{const _0xf4a287=_0x4f2667;_0xf60d04[_0xf4a287(0x15f)][_0xf4a287(0x18a)](_0x553de1,(_0x978d92,_0x3ef6bf)=>{const _0x4bcd9a=_0xf4a287,_0x354ff4=_0x59fb46(this[_0x4bcd9a(0x159)][_0x4bcd9a(0x196)]());_0x354ff4&&(_0x354ff4[_0x4bcd9a(0x162)][_0x4bcd9a(0x166)](),_0x3ef6bf());});});};this[_0x1e5c74(0x194)]instanceof _0x37cde6?_0x338dfb(this[_0x1e5c74(0x194)]):this[_0x1e5c74(0x194)][_0x1e5c74(0x1a5)]&&this[_0x1e5c74(0x194)][_0x1e5c74(0x1a5)]['on'](_0x1e5c74(0x16a),(_0x5a8a50,_0x36e5b6)=>{_0x338dfb(_0x36e5b6);});}[_0x3a52cf(0x15c)](){const _0x7bac7f=_0x3a52cf,_0x50ff32=_0x596d2d=>{const _0x15b96b=_0x466f,_0x48caa0=_0x596d2d[_0x15b96b(0x199)],_0x5879e6=[];let _0x4be165;if(Array[_0x15b96b(0x17e)](_0x48caa0[_0x15b96b(0x170)])){_0x4be165=_0x48caa0[_0x15b96b(0x170)][0x0],this[_0x15b96b(0x194)]instanceof _0x37cde6?_0x5879e6[_0x15b96b(0x193)](this[_0x15b96b(0x194)]):this[_0x15b96b(0x194)][_0x15b96b(0x1a5)]&&_0x5879e6[_0x15b96b(0x193)](...this[_0x15b96b(0x194)][_0x15b96b(0x1a5)]);for(const _0x495894 of _0x5879e6)for(const _0x463154 of _0x495894[_0x15b96b(0x197)][_0x15b96b(0x162)][_0x15b96b(0x15d)][_0x15b96b(0x196)]())if(_0x463154[_0x15b96b(0x176)](_0x4be165))return void _0x495894[_0x15b96b(0x197)][_0x15b96b(0x162)][_0x15b96b(0x166)]();_0x4be165[_0x15b96b(0x166)]();}};this[_0x7bac7f(0x19b)](this[_0x7bac7f(0x168)],_0x7bac7f(0x16a),(_0x2a2af6,_0x554b47)=>{const _0x5e07e0=_0x7bac7f;this[_0x5e07e0(0x19b)](_0x554b47,_0x5e07e0(0x19a),_0x50ff32,{'priority':_0x5e07e0(0x1a1)});}),this[_0x7bac7f(0x19b)](this[_0x7bac7f(0x168)],_0x7bac7f(0x1a0),(_0x166a63,_0xa34b0b)=>{const _0x598f9c=_0x7bac7f;this[_0x598f9c(0x1a3)](_0xa34b0b,_0x598f9c(0x19a),_0x50ff32);});}}