@progress/kendo-angular-spreadsheet 14.2.0 → 14.3.0-develop.1
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/action-bar/formula-input.directive.d.ts +5 -1
- package/action-bar/namebox.component.d.ts +6 -3
- package/esm2020/action-bar/formula-input.directive.mjs +17 -4
- package/esm2020/action-bar/namebox.component.mjs +13 -5
- package/esm2020/localization/messages.mjs +17 -1
- package/esm2020/package-metadata.mjs +2 -2
- package/esm2020/spreadsheet.component.mjs +335 -51
- package/esm2020/spreadsheet.module.mjs +4 -4
- package/esm2020/tools/colorpicker/spreadsheet-backcolor.component.mjs +2 -2
- package/esm2020/tools/colorpicker/spreadsheet-forecolor.component.mjs +2 -2
- package/esm2020/tools/insert/insert-link-tool.directive.mjs +4 -1
- package/esm2020/tools/shared/command-icons.mjs +17 -3
- package/fesm2015/progress-kendo-angular-spreadsheet.mjs +412 -81
- package/fesm2020/progress-kendo-angular-spreadsheet.mjs +411 -81
- package/localization/messages.d.ts +33 -1
- package/package.json +15 -15
- package/schematics/ngAdd/index.js +1 -1
- package/spreadsheet.component.d.ts +19 -4
- package/spreadsheet.module.d.ts +1 -1
- package/tools/insert/insert-link-tool.directive.d.ts +1 -0
- package/tools/shared/commands.d.ts +1 -1
|
@@ -19,55 +19,61 @@ import { FormulaInputDirective } from './action-bar/formula-input.directive';
|
|
|
19
19
|
import { take } from 'rxjs/operators';
|
|
20
20
|
import { getSheetActions } from './sheets-bar/utils';
|
|
21
21
|
import { ErrorHandlingService } from './common/error-handling.service';
|
|
22
|
+
import { ContextMenuComponent } from '@progress/kendo-angular-menu';
|
|
23
|
+
import { commandIcons, commandSVGIcons } from './tools/shared/command-icons';
|
|
24
|
+
import { Subscription } from 'rxjs';
|
|
25
|
+
import { DialogService } from '@progress/kendo-angular-dialog';
|
|
26
|
+
import { InsertLinkDialogComponent } from './tools/insert/insert-link-dialog.component';
|
|
22
27
|
import * as i0 from "@angular/core";
|
|
23
28
|
import * as i1 from "@progress/kendo-angular-intl";
|
|
24
29
|
import * as i2 from "@progress/kendo-angular-l10n";
|
|
25
30
|
import * as i3 from "./common/spreadsheet.service";
|
|
26
31
|
import * as i4 from "./tools/tools.service";
|
|
27
32
|
import * as i5 from "./common/error-handling.service";
|
|
28
|
-
import * as i6 from "@progress/kendo-angular-
|
|
29
|
-
import * as i7 from "@progress/kendo-angular-
|
|
30
|
-
import * as i8 from "
|
|
31
|
-
import * as i9 from "./tools/
|
|
32
|
-
import * as i10 from "./tools/font-
|
|
33
|
-
import * as i11 from "./tools/
|
|
34
|
-
import * as i12 from "./tools/colorpicker/spreadsheet-
|
|
35
|
-
import * as i13 from "./
|
|
36
|
-
import * as i14 from "
|
|
37
|
-
import * as i15 from "
|
|
38
|
-
import * as i16 from "
|
|
39
|
-
import * as i17 from "
|
|
40
|
-
import * as i18 from "./
|
|
41
|
-
import * as i19 from "
|
|
42
|
-
import * as i20 from "
|
|
43
|
-
import * as i21 from "./tools/
|
|
44
|
-
import * as i22 from "./tools/history/
|
|
45
|
-
import * as i23 from "./tools/
|
|
46
|
-
import * as i24 from "./tools/font-size/
|
|
47
|
-
import * as i25 from "./tools/
|
|
48
|
-
import * as i26 from "./tools/typographical-emphasis/
|
|
49
|
-
import * as i27 from "./tools/typographical-emphasis/
|
|
50
|
-
import * as i28 from "./tools/
|
|
51
|
-
import * as i29 from "./tools/align/
|
|
52
|
-
import * as i30 from "./tools/
|
|
53
|
-
import * as i31 from "./tools/
|
|
54
|
-
import * as i32 from "./tools/
|
|
55
|
-
import * as i33 from "./tools/
|
|
56
|
-
import * as i34 from "./tools/tables/add-column-
|
|
57
|
-
import * as i35 from "./tools/tables/add-
|
|
58
|
-
import * as i36 from "./tools/tables/add-row-
|
|
59
|
-
import * as i37 from "./tools/tables/
|
|
60
|
-
import * as i38 from "./tools/tables/delete-
|
|
61
|
-
import * as i39 from "./tools/
|
|
62
|
-
import * as i40 from "./tools/
|
|
63
|
-
import * as i41 from "./tools/
|
|
64
|
-
import * as i42 from "./tools/
|
|
65
|
-
import * as i43 from "./
|
|
33
|
+
import * as i6 from "@progress/kendo-angular-dialog";
|
|
34
|
+
import * as i7 from "@progress/kendo-angular-menu";
|
|
35
|
+
import * as i8 from "@progress/kendo-angular-toolbar";
|
|
36
|
+
import * as i9 from "./tools/load-file.component";
|
|
37
|
+
import * as i10 from "./tools/font-family/spreadsheet-fontfamily-tool.component";
|
|
38
|
+
import * as i11 from "./tools/font-size/spreadsheet-fontsize-tool.component";
|
|
39
|
+
import * as i12 from "./tools/colorpicker/spreadsheet-forecolor.component";
|
|
40
|
+
import * as i13 from "./tools/colorpicker/spreadsheet-backcolor.component";
|
|
41
|
+
import * as i14 from "./action-bar/namebox.component";
|
|
42
|
+
import * as i15 from "@progress/kendo-angular-icons";
|
|
43
|
+
import * as i16 from "./sheets-bar/sheets-bar.component";
|
|
44
|
+
import * as i17 from "@progress/kendo-angular-common";
|
|
45
|
+
import * as i18 from "./localization/localized-messages.directive";
|
|
46
|
+
import * as i19 from "./common/main-menu.directive";
|
|
47
|
+
import * as i20 from "@angular/common";
|
|
48
|
+
import * as i21 from "./tools/save-file-tool.directive";
|
|
49
|
+
import * as i22 from "./tools/history/undo-tool";
|
|
50
|
+
import * as i23 from "./tools/history/redo-tool";
|
|
51
|
+
import * as i24 from "./tools/font-size/increase-font-tool.directive";
|
|
52
|
+
import * as i25 from "./tools/font-size/decrease-font-tool.directive";
|
|
53
|
+
import * as i26 from "./tools/typographical-emphasis/bold-tool.directive";
|
|
54
|
+
import * as i27 from "./tools/typographical-emphasis/italic-tool.directive";
|
|
55
|
+
import * as i28 from "./tools/typographical-emphasis/underline-tool.directive";
|
|
56
|
+
import * as i29 from "./tools/align/horizontal-align-tool.directive";
|
|
57
|
+
import * as i30 from "./tools/align/vertical-align-tool.directive";
|
|
58
|
+
import * as i31 from "./tools/text-wrap-tool.directive";
|
|
59
|
+
import * as i32 from "./tools/format-tool.directive";
|
|
60
|
+
import * as i33 from "./tools/insert/insert-link-tool.directive";
|
|
61
|
+
import * as i34 from "./tools/tables/add-column-left-button.directive";
|
|
62
|
+
import * as i35 from "./tools/tables/add-column-right-button.directive";
|
|
63
|
+
import * as i36 from "./tools/tables/add-row-below-button.directive";
|
|
64
|
+
import * as i37 from "./tools/tables/add-row-above-button.directive";
|
|
65
|
+
import * as i38 from "./tools/tables/delete-column-button.directive";
|
|
66
|
+
import * as i39 from "./tools/tables/delete-row-button.directive";
|
|
67
|
+
import * as i40 from "./tools/decrease-decimal-tool.directive";
|
|
68
|
+
import * as i41 from "./tools/increase-decimal-tool.directive";
|
|
69
|
+
import * as i42 from "./tools/tables/merge-tool.directive";
|
|
70
|
+
import * as i43 from "./tools/gridlines-tool.directive";
|
|
71
|
+
import * as i44 from "./action-bar/formula-input.directive";
|
|
66
72
|
/**
|
|
67
73
|
* Represents the [Kendo UI Spreadsheet component for Angular]({% slug overview_spreadsheet %}).
|
|
68
74
|
*/
|
|
69
75
|
export class SpreadsheetComponent {
|
|
70
|
-
constructor(ngZone, intl, host, localization, spreadsheetService, toolsService, errorService) {
|
|
76
|
+
constructor(ngZone, intl, host, localization, spreadsheetService, toolsService, errorService, dialogService) {
|
|
71
77
|
this.ngZone = ngZone;
|
|
72
78
|
this.intl = intl;
|
|
73
79
|
this.host = host;
|
|
@@ -75,6 +81,7 @@ export class SpreadsheetComponent {
|
|
|
75
81
|
this.spreadsheetService = spreadsheetService;
|
|
76
82
|
this.toolsService = toolsService;
|
|
77
83
|
this.errorService = errorService;
|
|
84
|
+
this.dialogService = dialogService;
|
|
78
85
|
this.hostClass = true;
|
|
79
86
|
this.role = 'application';
|
|
80
87
|
/**
|
|
@@ -150,10 +157,9 @@ export class SpreadsheetComponent {
|
|
|
150
157
|
this.formulaFxIcon = formulaFxIcon;
|
|
151
158
|
this.folderOpenIcon = folderOpenIcon;
|
|
152
159
|
this.downloadIcon = downloadIcon;
|
|
153
|
-
/**
|
|
154
|
-
* @hidden
|
|
155
|
-
*/
|
|
156
160
|
this.showLicenseWatermark = false;
|
|
161
|
+
this.contextMenuItems = [];
|
|
162
|
+
this.subs = new Subscription();
|
|
157
163
|
this.onChange = (e) => {
|
|
158
164
|
hasObservers(this.change) && this.change.emit(e);
|
|
159
165
|
this.spreadsheetService.selectionChanged.next(e.range);
|
|
@@ -219,7 +225,7 @@ export class SpreadsheetComponent {
|
|
|
219
225
|
this.ngZone.onStable.pipe(take(1)).subscribe(() => {
|
|
220
226
|
const normalizedItems = items.map(item => ({
|
|
221
227
|
active: item.active,
|
|
222
|
-
text: this.messageFor(item.id),
|
|
228
|
+
text: item.id === 'format' ? this.messageFor('formatTab') : this.messageFor(item.id),
|
|
223
229
|
cssClass: item.active ? 'k-active' : null,
|
|
224
230
|
id: item.id
|
|
225
231
|
}));
|
|
@@ -277,6 +283,7 @@ export class SpreadsheetComponent {
|
|
|
277
283
|
spreadsheet.bind('excelExport', this.onExcelExport);
|
|
278
284
|
spreadsheet.view.bind('update', this.updateState);
|
|
279
285
|
spreadsheet.view.bind('message', this.onMessage);
|
|
286
|
+
spreadsheet.bind('contextmenu', this.onContextMenu.bind(this));
|
|
280
287
|
const sheet = spreadsheet.activeSheet();
|
|
281
288
|
if (sheet) {
|
|
282
289
|
this.updateState({ range: sheet.range(sheet.activeCell()) });
|
|
@@ -289,8 +296,9 @@ export class SpreadsheetComponent {
|
|
|
289
296
|
});
|
|
290
297
|
}
|
|
291
298
|
});
|
|
292
|
-
this.spreadsheetService.sheetsChanged.subscribe(this.onSheetsChanged.bind(this));
|
|
293
|
-
this.spreadsheetService.activeSheetChanged.subscribe(this.onActiveSheetChanged.bind(this));
|
|
299
|
+
this.subs.add(this.spreadsheetService.sheetsChanged.subscribe(this.onSheetsChanged.bind(this)));
|
|
300
|
+
this.subs.add(this.spreadsheetService.activeSheetChanged.subscribe(this.onActiveSheetChanged.bind(this)));
|
|
301
|
+
this.subs.add(this.spreadsheetService.selectionChanged.subscribe(range => this.currentRange = range));
|
|
294
302
|
this.spreadsheetService.dialogContainer = this.dialogContainer;
|
|
295
303
|
});
|
|
296
304
|
}
|
|
@@ -314,6 +322,85 @@ export class SpreadsheetComponent {
|
|
|
314
322
|
this.spreadsheetWidget.fromJSON(newOptions);
|
|
315
323
|
}
|
|
316
324
|
}
|
|
325
|
+
ngOnDestroy() {
|
|
326
|
+
this.subs.unsubscribe();
|
|
327
|
+
}
|
|
328
|
+
/**
|
|
329
|
+
* @hidden
|
|
330
|
+
*/
|
|
331
|
+
onContextMenu(e) {
|
|
332
|
+
if (e.targetType === 'topcorner') {
|
|
333
|
+
return;
|
|
334
|
+
}
|
|
335
|
+
const selection = this.spreadsheetWidget.activeSheet().select();
|
|
336
|
+
const { topLeft, bottomRight } = selection;
|
|
337
|
+
const isRange = e.targetType === 'cell' && (topLeft.row !== bottomRight.row || topLeft.col !== bottomRight.col);
|
|
338
|
+
const targetType = isRange ? 'range' : e.targetType;
|
|
339
|
+
this.contextMenuItems = this.contextMenuItemsForTarget(targetType, e.showUnhide, e.showUnmerge);
|
|
340
|
+
this.contextMenu.show({ top: e.originalEvent.pageY, left: e.originalEvent.pageX });
|
|
341
|
+
}
|
|
342
|
+
/**
|
|
343
|
+
* @hidden
|
|
344
|
+
*/
|
|
345
|
+
onContextMenuSelect(e) {
|
|
346
|
+
let command;
|
|
347
|
+
switch (e.item.id) {
|
|
348
|
+
case 'cut':
|
|
349
|
+
command = { command: 'ToolbarCutCommand', options: { workbook: this.spreadsheetWidget.workbook } };
|
|
350
|
+
break;
|
|
351
|
+
case 'copy':
|
|
352
|
+
command = { command: 'ToolbarCopyCommand', options: { workbook: this.spreadsheetWidget.workbook } };
|
|
353
|
+
break;
|
|
354
|
+
case 'unmerge':
|
|
355
|
+
command = { command: 'MergeCellCommand', options: { value: 'unmerge' } };
|
|
356
|
+
break;
|
|
357
|
+
case 'mergeAll':
|
|
358
|
+
command = { command: 'MergeCellCommand', options: { value: 'cells' } };
|
|
359
|
+
break;
|
|
360
|
+
case 'mergeHorizontally':
|
|
361
|
+
command = { command: 'MergeCellCommand', options: { value: 'horizontally' } };
|
|
362
|
+
break;
|
|
363
|
+
case 'mergeVertically':
|
|
364
|
+
command = { command: 'MergeCellCommand', options: { value: 'vertically' } };
|
|
365
|
+
break;
|
|
366
|
+
case 'hideRow':
|
|
367
|
+
command = { command: 'HideLineCommand', options: { axis: 'row' } };
|
|
368
|
+
break;
|
|
369
|
+
case 'hideColumn':
|
|
370
|
+
command = { command: 'HideLineCommand', options: { axis: 'column' } };
|
|
371
|
+
break;
|
|
372
|
+
case 'unhideRow':
|
|
373
|
+
command = { command: 'UnHideLineCommand', options: { axis: 'row' } };
|
|
374
|
+
break;
|
|
375
|
+
case 'unhideColumn':
|
|
376
|
+
command = { command: 'UnHideLineCommand', options: { axis: 'column' } };
|
|
377
|
+
break;
|
|
378
|
+
case 'deleteRow':
|
|
379
|
+
command = { command: 'DeleteRowCommand' };
|
|
380
|
+
break;
|
|
381
|
+
case 'deleteColumn':
|
|
382
|
+
command = { command: 'DeleteColumnCommand' };
|
|
383
|
+
break;
|
|
384
|
+
case 'insertLink':
|
|
385
|
+
this.openLinkDialog();
|
|
386
|
+
break;
|
|
387
|
+
case 'addRowAbove':
|
|
388
|
+
command = { command: 'AddRowCommand', options: { value: 'above' } };
|
|
389
|
+
break;
|
|
390
|
+
case 'addRowBelow':
|
|
391
|
+
command = { command: 'AddRowCommand', options: { value: 'below' } };
|
|
392
|
+
break;
|
|
393
|
+
case 'addColumnLeft':
|
|
394
|
+
command = { command: 'AddColumnCommand', options: { value: 'left' } };
|
|
395
|
+
break;
|
|
396
|
+
case 'addColumnRight':
|
|
397
|
+
command = { command: 'AddColumnCommand', options: { value: 'right' } };
|
|
398
|
+
break;
|
|
399
|
+
}
|
|
400
|
+
if (command) {
|
|
401
|
+
this.spreadsheetWidget.executeCommand(command);
|
|
402
|
+
}
|
|
403
|
+
}
|
|
317
404
|
/**
|
|
318
405
|
* @hidden
|
|
319
406
|
*/
|
|
@@ -369,8 +456,162 @@ export class SpreadsheetComponent {
|
|
|
369
456
|
nameBoxRef: { current: this.nameBoxRef.current }
|
|
370
457
|
};
|
|
371
458
|
}
|
|
459
|
+
contextMenuItemsForTarget(target, unhide, unmerge) {
|
|
460
|
+
const commonItems = [{
|
|
461
|
+
text: this.messageFor('copy'),
|
|
462
|
+
icon: commandIcons.copy,
|
|
463
|
+
svgIcon: commandSVGIcons.copy,
|
|
464
|
+
id: 'copy'
|
|
465
|
+
}, {
|
|
466
|
+
text: this.messageFor('cut'),
|
|
467
|
+
icon: commandIcons.cut,
|
|
468
|
+
svgIcon: commandSVGIcons.cut,
|
|
469
|
+
id: 'cut'
|
|
470
|
+
}, {
|
|
471
|
+
text: this.messageFor('paste'),
|
|
472
|
+
icon: commandIcons.paste,
|
|
473
|
+
svgIcon: commandSVGIcons.paste,
|
|
474
|
+
id: 'paste',
|
|
475
|
+
disabled: true
|
|
476
|
+
}, {
|
|
477
|
+
separator: true
|
|
478
|
+
}, {
|
|
479
|
+
text: this.messageFor('mergeAll'),
|
|
480
|
+
icon: commandIcons.mergeAll,
|
|
481
|
+
svgIcon: commandSVGIcons.mergeAll,
|
|
482
|
+
id: 'mergeAll',
|
|
483
|
+
}, {
|
|
484
|
+
text: this.messageFor('mergeHorizontally'),
|
|
485
|
+
icon: commandIcons.mergeHorizontally,
|
|
486
|
+
svgIcon: commandSVGIcons.mergeHorizontally,
|
|
487
|
+
id: 'mergeHorizontally',
|
|
488
|
+
}, {
|
|
489
|
+
text: this.messageFor('mergeVertically'),
|
|
490
|
+
icon: commandIcons.mergeVertically,
|
|
491
|
+
svgIcon: commandSVGIcons.mergeVertically,
|
|
492
|
+
id: 'mergeVertically',
|
|
493
|
+
}, {
|
|
494
|
+
text: this.messageFor('unmerge'),
|
|
495
|
+
icon: commandIcons.unmerge,
|
|
496
|
+
svgIcon: commandSVGIcons.unmerge,
|
|
497
|
+
id: 'unmerge',
|
|
498
|
+
disabled: !unmerge
|
|
499
|
+
}, {
|
|
500
|
+
separator: true
|
|
501
|
+
}, {
|
|
502
|
+
text: this.messageFor('insertLink'),
|
|
503
|
+
icon: commandIcons.insertLink,
|
|
504
|
+
svgIcon: commandSVGIcons.insertLink,
|
|
505
|
+
id: 'insertLink'
|
|
506
|
+
}];
|
|
507
|
+
if (target === 'rowheader') {
|
|
508
|
+
commonItems.push({
|
|
509
|
+
separator: true
|
|
510
|
+
}, {
|
|
511
|
+
text: this.messageFor('addRowAbove'),
|
|
512
|
+
icon: commandIcons.addRowAbove,
|
|
513
|
+
svgIcon: commandSVGIcons.addRowAbove,
|
|
514
|
+
id: 'addRowAbove',
|
|
515
|
+
}, {
|
|
516
|
+
text: this.messageFor('addRowBelow'),
|
|
517
|
+
icon: commandIcons.addRowBelow,
|
|
518
|
+
svgIcon: commandSVGIcons.addRowBelow,
|
|
519
|
+
id: 'addRowBelow',
|
|
520
|
+
}, {
|
|
521
|
+
text: this.messageFor('deleteRow'),
|
|
522
|
+
icon: commandIcons.deleteRow,
|
|
523
|
+
svgIcon: commandSVGIcons.deleteRow,
|
|
524
|
+
id: 'deleteRow',
|
|
525
|
+
}, {
|
|
526
|
+
text: this.messageFor('hideRow'),
|
|
527
|
+
icon: commandIcons.hideRow,
|
|
528
|
+
svgIcon: commandSVGIcons.hideRow,
|
|
529
|
+
id: 'hideRow',
|
|
530
|
+
}, {
|
|
531
|
+
text: this.messageFor('unhideRow'),
|
|
532
|
+
icon: commandIcons.unhideRow,
|
|
533
|
+
svgIcon: commandSVGIcons.unhideRow,
|
|
534
|
+
id: 'unhideRow',
|
|
535
|
+
disabled: !unhide
|
|
536
|
+
});
|
|
537
|
+
}
|
|
538
|
+
if (target === 'columnheader') {
|
|
539
|
+
commonItems.push({
|
|
540
|
+
separator: true
|
|
541
|
+
}, {
|
|
542
|
+
text: this.messageFor('addColumnLeft'),
|
|
543
|
+
icon: commandIcons.addColumnLeft,
|
|
544
|
+
svgIcon: commandSVGIcons.addColumnLeft,
|
|
545
|
+
id: 'addColumnLeft',
|
|
546
|
+
}, {
|
|
547
|
+
text: this.messageFor('addColumnRight'),
|
|
548
|
+
icon: commandIcons.addColumnRight,
|
|
549
|
+
svgIcon: commandSVGIcons.addColumnRight,
|
|
550
|
+
id: 'addColumnRight',
|
|
551
|
+
}, {
|
|
552
|
+
text: this.messageFor('deleteColumn'),
|
|
553
|
+
icon: commandIcons.deleteColumn,
|
|
554
|
+
svgIcon: commandSVGIcons.deleteColumn,
|
|
555
|
+
id: 'deleteColumn',
|
|
556
|
+
}, {
|
|
557
|
+
text: this.messageFor('hideColumn'),
|
|
558
|
+
icon: commandIcons.hideColumn,
|
|
559
|
+
svgIcon: commandSVGIcons.hideColumn,
|
|
560
|
+
id: 'hideColumn',
|
|
561
|
+
}, {
|
|
562
|
+
text: this.messageFor('unhideColumn'),
|
|
563
|
+
icon: commandIcons.unhideColumn,
|
|
564
|
+
svgIcon: commandSVGIcons.unhideColumn,
|
|
565
|
+
id: 'unhideColumn',
|
|
566
|
+
disabled: !unhide
|
|
567
|
+
});
|
|
568
|
+
}
|
|
569
|
+
return commonItems;
|
|
570
|
+
}
|
|
571
|
+
openLinkDialog() {
|
|
572
|
+
const hasLink = isPresent(this.currentRange?.link());
|
|
573
|
+
const dialogSettings = {
|
|
574
|
+
appendTo: this.spreadsheetService.dialogContainer,
|
|
575
|
+
title: this.localization.get('insertLink'),
|
|
576
|
+
content: InsertLinkDialogComponent,
|
|
577
|
+
actions: [{
|
|
578
|
+
text: this.localization.get('dialogInsert'),
|
|
579
|
+
themeColor: 'primary'
|
|
580
|
+
}, {
|
|
581
|
+
text: this.localization.get('dialogCancel')
|
|
582
|
+
},
|
|
583
|
+
'spacer', {
|
|
584
|
+
text: this.localization.get('dialogRemoveLink'),
|
|
585
|
+
themeColor: 'primary',
|
|
586
|
+
fillMode: 'clear',
|
|
587
|
+
cssClass: hasLink ? '' : 'k-disabled'
|
|
588
|
+
}],
|
|
589
|
+
actionsLayout: 'start',
|
|
590
|
+
width: 400,
|
|
591
|
+
autoFocusedElement: '.k-textbox > .k-input-inner'
|
|
592
|
+
};
|
|
593
|
+
const dialog = this.dialogService.open(dialogSettings);
|
|
594
|
+
const dialogInstance = dialog.dialog.instance;
|
|
595
|
+
const dialogContent = dialog.content.instance;
|
|
596
|
+
if (hasLink) {
|
|
597
|
+
dialogContent.setData({ link: this.currentRange?.link() });
|
|
598
|
+
}
|
|
599
|
+
dialogInstance.action.pipe(take(1)).subscribe((event) => {
|
|
600
|
+
if (event.text === this.localization.get('dialogCancel')) {
|
|
601
|
+
return;
|
|
602
|
+
}
|
|
603
|
+
let link = null;
|
|
604
|
+
if (event.text === this.localization.get('dialogInsert')) {
|
|
605
|
+
link = dialogContent.urlLink || null;
|
|
606
|
+
}
|
|
607
|
+
this.spreadsheetService.spreadsheet.executeCommand({
|
|
608
|
+
command: 'HyperlinkCommand',
|
|
609
|
+
options: { link }
|
|
610
|
+
});
|
|
611
|
+
});
|
|
612
|
+
}
|
|
372
613
|
}
|
|
373
|
-
SpreadsheetComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: SpreadsheetComponent, deps: [{ token: i0.NgZone }, { token: i1.IntlService }, { token: i0.ElementRef }, { token: i2.LocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }, { token: i5.ErrorHandlingService }], target: i0.ɵɵFactoryTarget.Component });
|
|
614
|
+
SpreadsheetComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: SpreadsheetComponent, deps: [{ token: i0.NgZone }, { token: i1.IntlService }, { token: i0.ElementRef }, { token: i2.LocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }, { token: i5.ErrorHandlingService }, { token: i6.DialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
374
615
|
SpreadsheetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: SpreadsheetComponent, selector: "kendo-spreadsheet", inputs: { menuItems: "menuItems", overflow: "overflow", activeSheet: "activeSheet", sheets: "sheets", columns: "columns", columnWidth: "columnWidth", defaultCellStyle: "defaultCellStyle", headerHeight: "headerHeight", headerWidth: "headerWidth", rowHeight: "rowHeight", rows: "rows", images: "images", excel: "excel" }, outputs: { change: "change", formatChange: "formatChange", selectionChange: "selectionChange", excelExport: "excelExport", excelImport: "excelImport", activeSheetChange: "activeSheetChange" }, host: { properties: { "class.k-spreadsheet": "this.hostClass", "attr.role": "this.role" } }, providers: [
|
|
375
616
|
SpreadsheetLocalizationService,
|
|
376
617
|
{
|
|
@@ -384,7 +625,7 @@ SpreadsheetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
384
625
|
SpreadsheetToolsService,
|
|
385
626
|
PopupService,
|
|
386
627
|
ErrorHandlingService
|
|
387
|
-
], viewQueries: [{ propertyName: "formulaBarInputRef", first: true, predicate: ["formulaBar"], descendants: true, read: FormulaInputDirective }, { propertyName: "formulaCellInputRef", first: true, predicate: ["formulaCell"], descendants: true, read: FormulaInputDirective }, { propertyName: "nameBoxRef", first: true, predicate: ["nameBox"], descendants: true }, { propertyName: "dialogContainer", first: true, predicate: ["dialogContainer"], descendants: true, read: ViewContainerRef }], exportAs: ["kendo-spreadsheet"], usesOnChanges: true, ngImport: i0, template: `
|
|
628
|
+
], viewQueries: [{ propertyName: "formulaBarInputRef", first: true, predicate: ["formulaBar"], descendants: true, read: FormulaInputDirective }, { propertyName: "formulaCellInputRef", first: true, predicate: ["formulaCell"], descendants: true, read: FormulaInputDirective }, { propertyName: "nameBoxRef", first: true, predicate: ["nameBox"], descendants: true }, { propertyName: "dialogContainer", first: true, predicate: ["dialogContainer"], descendants: true, read: ViewContainerRef }, { propertyName: "contextMenu", first: true, predicate: ["contextMenu"], descendants: true }], exportAs: ["kendo-spreadsheet"], usesOnChanges: true, ngImport: i0, template: `
|
|
388
629
|
<ng-container
|
|
389
630
|
kendoSpreadsheetLocalizedMessages
|
|
390
631
|
i18n-background="kendo.spreadsheet.background|The title of the tool that changes the text background color."
|
|
@@ -495,6 +736,8 @@ SpreadsheetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
495
736
|
delete="Delete Sheet"
|
|
496
737
|
i18n-nameBox="kendo.spreadsheet.nameBox|The title of the Name Box input."
|
|
497
738
|
nameBox="Name Box"
|
|
739
|
+
i18n-formulaInput="kendo.spreadsheet.formulaInput|The title of the Formula input."
|
|
740
|
+
formulaInput="Formula Input"
|
|
498
741
|
i18n-addSheet="kendo.spreadsheet.addSheet|The title of the Add new sheet button."
|
|
499
742
|
addSheet="Add New Sheet"
|
|
500
743
|
i18n-sheetsMenu="kendo.spreadsheet.sheetsMenu|The title of the Sheets menu button."
|
|
@@ -511,7 +754,20 @@ SpreadsheetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
511
754
|
dialogError="Error"
|
|
512
755
|
i18n-duplicateSheetName="kendo.spreadsheet.duplicateSheetName|The content of the dialog that warns about duplicated sheet name."
|
|
513
756
|
duplicateSheetName="There is an existing sheet with this name. Please enter another name."
|
|
514
|
-
|
|
757
|
+
i18n-copy="kendo.spreadsheet.copy|The Copy command text."
|
|
758
|
+
copy="Copy"
|
|
759
|
+
i18n-cut="kendo.spreadsheet.cut|The Cut command text."
|
|
760
|
+
cut="Cut"
|
|
761
|
+
i18n-paste="kendo.spreadsheet.paste|The Paste command text."
|
|
762
|
+
paste="Paste (use Ctrl/⌘ + V)"
|
|
763
|
+
i18n-hideRow="kendo.spreadsheet.hideRow|The Hide row command text."
|
|
764
|
+
hideRow="Hide"
|
|
765
|
+
i18n-unhideRow="kendo.spreadsheet.unhideRow|The Unhide row command text."
|
|
766
|
+
unhideRow="Unhide"
|
|
767
|
+
i18n-hideColumn="kendo.spreadsheet.hideColumn|The Hide column command text."
|
|
768
|
+
hideColumn="Hide"
|
|
769
|
+
i18n-unhideColumn="kendo.spreadsheet.unhideColumn|The Unhide column command text."
|
|
770
|
+
unhideColumn="Unhide">
|
|
515
771
|
</ng-container>
|
|
516
772
|
<div class="k-spreadsheet-header">
|
|
517
773
|
<kendo-menu kendoSpreadsheetMenu (select)="onMenuItemSelect($event)">
|
|
@@ -610,8 +866,13 @@ SpreadsheetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
610
866
|
</div>
|
|
611
867
|
<ng-container #dialogContainer></ng-container>
|
|
612
868
|
|
|
869
|
+
<kendo-contextmenu
|
|
870
|
+
#contextMenu
|
|
871
|
+
[items]="contextMenuItems"
|
|
872
|
+
(select)="onContextMenuSelect($event)"></kendo-contextmenu>
|
|
873
|
+
|
|
613
874
|
<div kendoWatermarkOverlay *ngIf="showLicenseWatermark"></div>
|
|
614
|
-
`, isInline: true, components: [{ type:
|
|
875
|
+
`, isInline: true, components: [{ type: i7.MenuComponent, selector: "kendo-menu", inputs: ["menuItemTemplate", "ariaRole", "menuItemLinkTemplate"], outputs: ["select", "open", "close"], exportAs: ["kendoMenu"] }, { type: i7.MenuItemComponent, selector: "kendo-menu-item", inputs: ["text", "url", "disabled", "cssClass", "cssStyle", "icon", "svgIcon", "data", "separator"] }, { type: i8.ToolBarComponent, selector: "kendo-toolbar", inputs: ["overflow", "resizable", "popupSettings", "tabindex", "size", "tabIndex"], outputs: ["open", "close"], exportAs: ["kendoToolBar"] }, { type: i9.SpreadsheetLoadFileComponent, selector: "kendo-spreadsheet-load-file-tool" }, { type: i8.ToolBarButtonComponent, selector: "kendo-toolbar-button", inputs: ["showText", "showIcon", "text", "style", "className", "title", "disabled", "toggleable", "look", "togglable", "selected", "fillMode", "themeColor", "icon", "iconClass", "svgIcon", "imageUrl"], outputs: ["click", "pointerdown", "selectedChange"], exportAs: ["kendoToolBarButton"] }, { type: i8.ToolBarButtonGroupComponent, selector: "kendo-toolbar-buttongroup", inputs: ["disabled", "selection", "width", "look"], exportAs: ["kendoToolBarButtonGroup"] }, { type: i8.ToolBarSeparatorComponent, selector: "kendo-toolbar-separator", exportAs: ["kendoToolBarSeparator"] }, { type: i10.SpreadsheetFontFamilyComponent, selector: "kendo-toolbar-dropdownlist[kendoSpreadsheetFontFamily]" }, { type: i11.SpreadsheetFontSizeComponent, selector: "kendo-toolbar-dropdownlist[kendoSpreadsheetFontSize]" }, { type: i12.SpreadsheetForeColorComponent, selector: "kendo-spreadsheet-forecolor-tool" }, { type: i13.SpreadsheetBackColorComponent, selector: "kendo-spreadsheet-backcolor-tool" }, { type: i8.ToolBarDropDownButtonComponent, selector: "kendo-toolbar-dropdownbutton", inputs: ["arrowIcon", "title", "showText", "showIcon", "text", "icon", "svgIcon", "iconClass", "imageUrl", "popupSettings", "look", "primary", "fillMode", "themeColor", "buttonClass", "textField", "disabled", "data"], outputs: ["itemClick", "open", "close"], exportAs: ["kendoToolBarDropDownButton"] }, { type: i14.NameBoxComponent, selector: "[kendoSpreadsheetNameBox]", inputs: ["data", "spreadsheetWidget"] }, { type: i15.IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass", "size"], exportAs: ["kendoIconWrapper"] }, { type: i16.SheetsBarComponent, selector: "[kendoSpreadsheetSheetsBar]", inputs: ["sheets", "sheetDescriptors"] }, { type: i7.ContextMenuComponent, selector: "kendo-contextmenu", inputs: ["showOn", "target", "filter", "alignToAnchor", "vertical", "popupAnimate", "popupAlign", "anchorAlign", "collision", "appendTo", "ariaLabel"], outputs: ["popupOpen", "popupClose", "select", "open", "close"], exportAs: ["kendoContextMenu"] }, { type: i17.WatermarkOverlayComponent, selector: "div[kendoWatermarkOverlay]" }], directives: [{ type: i18.LocalizedMessagesDirective, selector: "[kendoSpreadsheetLocalizedMessages]" }, { type: i19.MainMenuDirective, selector: "[kendoSpreadsheetMenu]" }, { type: i20.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i20.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i21.SpreadsheetSaveFileDirective, selector: "[kendoSpreadsheetSaveFile]" }, { type: i22.SpreadsheetUndoDirective, selector: "kendo-toolbar-button[kendoSpreadsheetUndo]" }, { type: i23.SpreadsheetRedoDirective, selector: "kendo-toolbar-button[kendoSpreadsheetRedo]" }, { type: i24.SpreadsheetIncreaseFontSizeDirective, selector: "kendo-toolbar-button[kendoSpreadsheetIncreaseFontSize]" }, { type: i25.SpreadsheetDecreaseFontSizeDirective, selector: "kendo-toolbar-button[kendoSpreadsheetDecreaseFontSize]" }, { type: i26.SpreadsheetBoldDirective, selector: "kendo-toolbar-button[kendoSpreadsheetBold]" }, { type: i27.SpreadsheetItalicDirective, selector: "kendo-toolbar-button[kendoSpreadsheetItalic]" }, { type: i28.SpreadsheetUnderlineDirective, selector: "kendo-toolbar-button[kendoSpreadsheetUnderline]" }, { type: i29.SpreadsheetHorizontalTextAlignDirective, selector: "[kendoSpreadsheetHorizontalTextAlign]" }, { type: i30.SpreadsheetVerticalTextAlignDirective, selector: "[kendoSpreadsheetVerticalTextAlign]" }, { type: i31.SpreadsheetTextWrapDirective, selector: "kendo-toolbar-button[kendoSpreadsheetTextWrap]" }, { type: i32.SpreadsheetFormatDirective, selector: "[kendoSpreadsheetFormat]" }, { type: i33.SpreadsheetInsertLinkDirective, selector: "kendo-toolbar-button[kendoSpreadsheetInsertLink]" }, { type: i34.SpreadsheetAddColumnLeftButtonDirective, selector: "kendo-toolbar-button[kendoSpreadsheetAddColumnLeftButton]" }, { type: i35.SpreadsheetAddColumnRightButtonDirective, selector: "kendo-toolbar-button[kendoSpreadsheetAddColumnRightButton]" }, { type: i36.SpreadsheetAddRowBelowButtonDirective, selector: "kendo-toolbar-button[kendoSpreadsheetAddRowBelowButton]" }, { type: i37.SpreadsheetAddRowAboveButtonDirective, selector: "kendo-toolbar-button[kendoSpreadsheetAddRowAboveButton]" }, { type: i38.SpreadsheetDeleteColumnButtonDirective, selector: "kendo-toolbar-button[kendoSpreadsheetDeleteColumnButton]" }, { type: i39.SpreadsheetDeleteRowButtonDirective, selector: "kendo-toolbar-button[kendoSpreadsheetDeleteRowButton]" }, { type: i40.SpreadsheetDecreaseDecimalDirective, selector: "kendo-toolbar-button[kendoSpreadsheetDecreaseDecimal]" }, { type: i41.SpreadsheetIncreaseDecimalDirective, selector: "kendo-toolbar-button[kendoSpreadsheetIncreaseDecimal]" }, { type: i42.SpreadsheetMergeDirective, selector: "[kendoSpreadsheetMerge]" }, { type: i43.SpreadsheetGridLinesDirective, selector: "kendo-toolbar-button[kendoSpreadsheetGridLines]" }, { type: i44.FormulaInputDirective, selector: "[kendoSpreadsheetFormulaInput]" }] });
|
|
615
876
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: SpreadsheetComponent, decorators: [{
|
|
616
877
|
type: Component,
|
|
617
878
|
args: [{
|
|
@@ -742,6 +1003,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
742
1003
|
delete="Delete Sheet"
|
|
743
1004
|
i18n-nameBox="kendo.spreadsheet.nameBox|The title of the Name Box input."
|
|
744
1005
|
nameBox="Name Box"
|
|
1006
|
+
i18n-formulaInput="kendo.spreadsheet.formulaInput|The title of the Formula input."
|
|
1007
|
+
formulaInput="Formula Input"
|
|
745
1008
|
i18n-addSheet="kendo.spreadsheet.addSheet|The title of the Add new sheet button."
|
|
746
1009
|
addSheet="Add New Sheet"
|
|
747
1010
|
i18n-sheetsMenu="kendo.spreadsheet.sheetsMenu|The title of the Sheets menu button."
|
|
@@ -758,7 +1021,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
758
1021
|
dialogError="Error"
|
|
759
1022
|
i18n-duplicateSheetName="kendo.spreadsheet.duplicateSheetName|The content of the dialog that warns about duplicated sheet name."
|
|
760
1023
|
duplicateSheetName="There is an existing sheet with this name. Please enter another name."
|
|
761
|
-
|
|
1024
|
+
i18n-copy="kendo.spreadsheet.copy|The Copy command text."
|
|
1025
|
+
copy="Copy"
|
|
1026
|
+
i18n-cut="kendo.spreadsheet.cut|The Cut command text."
|
|
1027
|
+
cut="Cut"
|
|
1028
|
+
i18n-paste="kendo.spreadsheet.paste|The Paste command text."
|
|
1029
|
+
paste="Paste (use Ctrl/⌘ + V)"
|
|
1030
|
+
i18n-hideRow="kendo.spreadsheet.hideRow|The Hide row command text."
|
|
1031
|
+
hideRow="Hide"
|
|
1032
|
+
i18n-unhideRow="kendo.spreadsheet.unhideRow|The Unhide row command text."
|
|
1033
|
+
unhideRow="Unhide"
|
|
1034
|
+
i18n-hideColumn="kendo.spreadsheet.hideColumn|The Hide column command text."
|
|
1035
|
+
hideColumn="Hide"
|
|
1036
|
+
i18n-unhideColumn="kendo.spreadsheet.unhideColumn|The Unhide column command text."
|
|
1037
|
+
unhideColumn="Unhide">
|
|
762
1038
|
</ng-container>
|
|
763
1039
|
<div class="k-spreadsheet-header">
|
|
764
1040
|
<kendo-menu kendoSpreadsheetMenu (select)="onMenuItemSelect($event)">
|
|
@@ -857,10 +1133,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
857
1133
|
</div>
|
|
858
1134
|
<ng-container #dialogContainer></ng-container>
|
|
859
1135
|
|
|
1136
|
+
<kendo-contextmenu
|
|
1137
|
+
#contextMenu
|
|
1138
|
+
[items]="contextMenuItems"
|
|
1139
|
+
(select)="onContextMenuSelect($event)"></kendo-contextmenu>
|
|
1140
|
+
|
|
860
1141
|
<div kendoWatermarkOverlay *ngIf="showLicenseWatermark"></div>
|
|
861
1142
|
`,
|
|
862
1143
|
}]
|
|
863
|
-
}], ctorParameters: function () { return [{ type: i0.NgZone }, { type: i1.IntlService }, { type: i0.ElementRef }, { type: i2.LocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }, { type: i5.ErrorHandlingService }]; }, propDecorators: { formulaBarInputRef: [{
|
|
1144
|
+
}], ctorParameters: function () { return [{ type: i0.NgZone }, { type: i1.IntlService }, { type: i0.ElementRef }, { type: i2.LocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }, { type: i5.ErrorHandlingService }, { type: i6.DialogService }]; }, propDecorators: { formulaBarInputRef: [{
|
|
864
1145
|
type: ViewChild,
|
|
865
1146
|
args: ['formulaBar', { read: FormulaInputDirective }]
|
|
866
1147
|
}], formulaCellInputRef: [{
|
|
@@ -872,6 +1153,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
872
1153
|
}], dialogContainer: [{
|
|
873
1154
|
type: ViewChild,
|
|
874
1155
|
args: ['dialogContainer', { read: ViewContainerRef }]
|
|
1156
|
+
}], contextMenu: [{
|
|
1157
|
+
type: ViewChild,
|
|
1158
|
+
args: ['contextMenu']
|
|
875
1159
|
}], hostClass: [{
|
|
876
1160
|
type: HostBinding,
|
|
877
1161
|
args: ['class.k-spreadsheet']
|
|
@@ -47,7 +47,7 @@ import { DialogModule } from '@progress/kendo-angular-dialog';
|
|
|
47
47
|
import { FontFamilyDropDownListComponent } from './tools/font-family/font-family-dropdownlist.component';
|
|
48
48
|
import { FontSizeDropDownListComponent } from './tools/font-size/font-size-dropdownlist.component';
|
|
49
49
|
import { DialogContentComponent } from './tools/shared/dialog-content.component';
|
|
50
|
-
import {
|
|
50
|
+
import { MenusModule } from '@progress/kendo-angular-menu';
|
|
51
51
|
import { MainMenuDirective } from './common/main-menu.directive';
|
|
52
52
|
import { ActionDialogComponent } from './sheets-bar/action-dialog.component';
|
|
53
53
|
import { SpreadsheetMergeDirective } from './tools/tables/merge-tool.directive';
|
|
@@ -195,7 +195,7 @@ SpreadsheetModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", versi
|
|
|
195
195
|
EventsModule,
|
|
196
196
|
IconsModule,
|
|
197
197
|
IntlModule,
|
|
198
|
-
|
|
198
|
+
MenusModule,
|
|
199
199
|
PopupModule,
|
|
200
200
|
TabStripModule,
|
|
201
201
|
ToolBarModule,
|
|
@@ -241,7 +241,7 @@ SpreadsheetModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", versi
|
|
|
241
241
|
EventsModule,
|
|
242
242
|
IconsModule,
|
|
243
243
|
IntlModule,
|
|
244
|
-
|
|
244
|
+
MenusModule,
|
|
245
245
|
PopupModule,
|
|
246
246
|
TabStripModule,
|
|
247
247
|
ToolBarModule,
|
|
@@ -263,7 +263,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
263
263
|
EventsModule,
|
|
264
264
|
IconsModule,
|
|
265
265
|
IntlModule,
|
|
266
|
-
|
|
266
|
+
MenusModule,
|
|
267
267
|
PopupModule,
|
|
268
268
|
TabStripModule,
|
|
269
269
|
ToolBarModule,
|
|
@@ -48,7 +48,7 @@ SpreadsheetBackColorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "1
|
|
|
48
48
|
[tabindex]="tabindex"
|
|
49
49
|
role="menuitem"
|
|
50
50
|
class="k-item k-menu-item"
|
|
51
|
-
(click)="openDialog()
|
|
51
|
+
(click)="openDialog()">
|
|
52
52
|
<span
|
|
53
53
|
class="k-link k-menu-link">
|
|
54
54
|
<kendo-icon-wrapper [name]="icon" [svgIcon]="svgIcon"></kendo-icon-wrapper>
|
|
@@ -82,7 +82,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
82
82
|
[tabindex]="tabindex"
|
|
83
83
|
role="menuitem"
|
|
84
84
|
class="k-item k-menu-item"
|
|
85
|
-
(click)="openDialog()
|
|
85
|
+
(click)="openDialog()">
|
|
86
86
|
<span
|
|
87
87
|
class="k-link k-menu-link">
|
|
88
88
|
<kendo-icon-wrapper [name]="icon" [svgIcon]="svgIcon"></kendo-icon-wrapper>
|
|
@@ -48,7 +48,7 @@ SpreadsheetForeColorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "1
|
|
|
48
48
|
[tabindex]="tabindex"
|
|
49
49
|
role="menuitem"
|
|
50
50
|
class="k-item k-menu-item"
|
|
51
|
-
(click)="openDialog()
|
|
51
|
+
(click)="openDialog()">
|
|
52
52
|
<span
|
|
53
53
|
class="k-link k-menu-link">
|
|
54
54
|
<kendo-icon-wrapper [name]="icon" [svgIcon]="svgIcon"></kendo-icon-wrapper>
|
|
@@ -82,7 +82,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
82
82
|
[tabindex]="tabindex"
|
|
83
83
|
role="menuitem"
|
|
84
84
|
class="k-item k-menu-item"
|
|
85
|
-
(click)="openDialog()
|
|
85
|
+
(click)="openDialog()">
|
|
86
86
|
<span
|
|
87
87
|
class="k-link k-menu-link">
|
|
88
88
|
<kendo-icon-wrapper [name]="icon" [svgIcon]="svgIcon"></kendo-icon-wrapper>
|
|
@@ -27,7 +27,10 @@ export class SpreadsheetInsertLinkDirective extends SpreadsheetCommandButton {
|
|
|
27
27
|
command: 'HyperlinkCommand'
|
|
28
28
|
});
|
|
29
29
|
this.dialogService = dialogService;
|
|
30
|
-
spreadsheetService.selectionChanged.subscribe(range => this.currentRange = range);
|
|
30
|
+
this.subs.add(spreadsheetService.selectionChanged.subscribe(range => this.currentRange = range));
|
|
31
|
+
}
|
|
32
|
+
ngOnDestroy() {
|
|
33
|
+
this.subs.unsubscribe();
|
|
31
34
|
}
|
|
32
35
|
clickHandler() {
|
|
33
36
|
const sheet = this.spreadsheetService.spreadsheet.activeSheet();
|