@progress/kendo-angular-spreadsheet 21.4.1 → 22.0.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/fesm2022/progress-kendo-angular-spreadsheet.mjs +183 -183
- package/package.json +22 -30
- package/schematics/ngAdd/index.js +2 -2
- package/tools/shared/spreadsheet-command-base.d.ts +1 -1
- package/tools/shared/spreadsheet-dropdown-tools-base.d.ts +1 -1
- package/tools/shared/spreadsheet-dropdownlist.base.d.ts +1 -1
- package/esm2022/action-bar/formula-input.directive.mjs +0 -183
- package/esm2022/action-bar/list.component.mjs +0 -91
- package/esm2022/action-bar/namebox.component.mjs +0 -134
- package/esm2022/common/calendar-editor.component.mjs +0 -48
- package/esm2022/common/error-handling.service.mjs +0 -99
- package/esm2022/common/list-editor.component.mjs +0 -146
- package/esm2022/common/main-menu.directive.mjs +0 -30
- package/esm2022/common/sheet-changes.mjs +0 -5
- package/esm2022/common/spreadsheet.service.mjs +0 -49
- package/esm2022/directives.mjs +0 -94
- package/esm2022/filter-menu/filter-menu-item-content-template.directive.mjs +0 -26
- package/esm2022/filter-menu/filter-menu-item.component.mjs +0 -271
- package/esm2022/index.mjs +0 -14
- package/esm2022/localization/custom-messages.component.mjs +0 -52
- package/esm2022/localization/localized-messages.directive.mjs +0 -35
- package/esm2022/localization/messages.mjs +0 -884
- package/esm2022/localization/spreadsheet-localization.service.mjs +0 -31
- package/esm2022/models/cell-editor-action-args.mjs +0 -5
- package/esm2022/models/cell-editor-options.mjs +0 -5
- package/esm2022/models/events.mjs +0 -5
- package/esm2022/models/filter-menu-item.mjs +0 -5
- package/esm2022/models/index.mjs +0 -11
- package/esm2022/models/main-menu-item.mjs +0 -5
- package/esm2022/models/range-filter-value.mjs +0 -5
- package/esm2022/models/sheet-info.mjs +0 -5
- package/esm2022/package-metadata.mjs +0 -16
- package/esm2022/progress-kendo-angular-spreadsheet.mjs +0 -8
- package/esm2022/sheets-bar/action-dialog.component.mjs +0 -78
- package/esm2022/sheets-bar/sheets-bar.component.mjs +0 -433
- package/esm2022/sheets-bar/utils.mjs +0 -49
- package/esm2022/spreadsheet.component.mjs +0 -2408
- package/esm2022/spreadsheet.module.mjs +0 -72
- package/esm2022/tools/align/align-tool.directive.mjs +0 -62
- package/esm2022/tools/align/horizontal-align-tool.directive.mjs +0 -62
- package/esm2022/tools/align/vertical-align-tool.directive.mjs +0 -62
- package/esm2022/tools/colorpicker/spreadsheet-backcolor.component.mjs +0 -142
- package/esm2022/tools/colorpicker/spreadsheet-forecolor.component.mjs +0 -142
- package/esm2022/tools/data-validation-dialog.component.mjs +0 -481
- package/esm2022/tools/data-validation-tool.directive.mjs +0 -156
- package/esm2022/tools/decrease-decimal-tool.directive.mjs +0 -41
- package/esm2022/tools/filter-sort/filter-tool.directive.mjs +0 -89
- package/esm2022/tools/filter-sort/sort-tool.directive.mjs +0 -62
- package/esm2022/tools/font-family/font-family-dropdownlist.component.mjs +0 -59
- package/esm2022/tools/font-family/spreadsheet-fontfamily-tool.component.mjs +0 -114
- package/esm2022/tools/font-size/decrease-font-tool.directive.mjs +0 -52
- package/esm2022/tools/font-size/font-size-dropdownlist.component.mjs +0 -46
- package/esm2022/tools/font-size/increase-font-tool.directive.mjs +0 -52
- package/esm2022/tools/font-size/spreadsheet-fontsize-tool.component.mjs +0 -114
- package/esm2022/tools/format-tool.directive.mjs +0 -65
- package/esm2022/tools/gridlines-tool.directive.mjs +0 -47
- package/esm2022/tools/history/redo-tool.mjs +0 -37
- package/esm2022/tools/history/undo-tool.mjs +0 -37
- package/esm2022/tools/increase-decimal-tool.directive.mjs +0 -41
- package/esm2022/tools/index.mjs +0 -30
- package/esm2022/tools/insert/insert-link-dialog.component.mjs +0 -53
- package/esm2022/tools/insert/insert-link-tool.directive.mjs +0 -97
- package/esm2022/tools/load-file.component.mjs +0 -226
- package/esm2022/tools/save-file-tool.directive.mjs +0 -58
- package/esm2022/tools/shared/command-icons.mjs +0 -121
- package/esm2022/tools/shared/commands.mjs +0 -5
- package/esm2022/tools/shared/constants.mjs +0 -77
- package/esm2022/tools/shared/dialog-content.component.mjs +0 -130
- package/esm2022/tools/shared/spreadsheet-command-base.mjs +0 -73
- package/esm2022/tools/shared/spreadsheet-command-button.mjs +0 -31
- package/esm2022/tools/shared/spreadsheet-dropdown-tools-base.mjs +0 -194
- package/esm2022/tools/shared/spreadsheet-dropdownlist.base.mjs +0 -54
- package/esm2022/tools/tables/add-column-left-button.directive.mjs +0 -37
- package/esm2022/tools/tables/add-column-right-button.directive.mjs +0 -37
- package/esm2022/tools/tables/add-row-above-button.directive.mjs +0 -37
- package/esm2022/tools/tables/add-row-below-button.directive.mjs +0 -37
- package/esm2022/tools/tables/delete-column-button.directive.mjs +0 -35
- package/esm2022/tools/tables/delete-row-button.directive.mjs +0 -35
- package/esm2022/tools/tables/index.mjs +0 -11
- package/esm2022/tools/tables/merge-tool.directive.mjs +0 -72
- package/esm2022/tools/text-wrap-tool.directive.mjs +0 -48
- package/esm2022/tools/tools.service.mjs +0 -61
- package/esm2022/tools/typographical-emphasis/bold-tool.directive.mjs +0 -37
- package/esm2022/tools/typographical-emphasis/italic-tool.directive.mjs +0 -37
- package/esm2022/tools/typographical-emphasis/underline-tool.directive.mjs +0 -37
- package/esm2022/tools/utils.mjs +0 -35
- package/esm2022/utils.mjs +0 -32
|
@@ -1,194 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Component, ElementRef, EventEmitter, Inject, Output, ViewChild } from "@angular/core";
|
|
6
|
-
import { ToolBarComponent, ToolBarToolComponent } from "@progress/kendo-angular-toolbar";
|
|
7
|
-
import { SpreadsheetService } from "../../common/spreadsheet.service";
|
|
8
|
-
import { SpreadsheetLocalizationService } from "../../localization/spreadsheet-localization.service";
|
|
9
|
-
import { SpreadsheetToolsService } from "../tools.service";
|
|
10
|
-
import { hasObservers, isPresent } from '@progress/kendo-angular-common';
|
|
11
|
-
import { DEFAULT_FONT_VALUES, FONT_DATA, MY_TOKEN } from "./constants";
|
|
12
|
-
import { commandIcons, commandSVGIcons } from './command-icons';
|
|
13
|
-
import { outerWidth } from '../utils';
|
|
14
|
-
import { DialogService } from "@progress/kendo-angular-dialog";
|
|
15
|
-
import { DialogContentComponent } from "./dialog-content.component";
|
|
16
|
-
import { take } from "rxjs/operators";
|
|
17
|
-
import * as i0 from "@angular/core";
|
|
18
|
-
import * as i1 from "@progress/kendo-angular-dialog";
|
|
19
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
20
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
21
|
-
import * as i4 from "../tools.service";
|
|
22
|
-
import * as i5 from "@progress/kendo-angular-toolbar";
|
|
23
|
-
/**
|
|
24
|
-
* @hidden
|
|
25
|
-
*/
|
|
26
|
-
export class SpreadsheetDropDownToolBase extends ToolBarToolComponent {
|
|
27
|
-
command;
|
|
28
|
-
dialogService;
|
|
29
|
-
localization;
|
|
30
|
-
spreadsheetService;
|
|
31
|
-
toolsService;
|
|
32
|
-
toolbar;
|
|
33
|
-
element;
|
|
34
|
-
dropDownListRef;
|
|
35
|
-
popupButton;
|
|
36
|
-
data;
|
|
37
|
-
constructor(command, dialogService, localization, spreadsheetService, toolsService, toolbar) {
|
|
38
|
-
super();
|
|
39
|
-
this.command = command;
|
|
40
|
-
this.dialogService = dialogService;
|
|
41
|
-
this.localization = localization;
|
|
42
|
-
this.spreadsheetService = spreadsheetService;
|
|
43
|
-
this.toolsService = toolsService;
|
|
44
|
-
this.toolbar = toolbar;
|
|
45
|
-
this.value = DEFAULT_FONT_VALUES[this.command];
|
|
46
|
-
this.data = FONT_DATA[this.command];
|
|
47
|
-
this.isBuiltInTool = true;
|
|
48
|
-
}
|
|
49
|
-
/**
|
|
50
|
-
* Fires when the user updates the value of the drop-down list.
|
|
51
|
-
*/
|
|
52
|
-
valueChange = new EventEmitter();
|
|
53
|
-
value;
|
|
54
|
-
tabindex = -1;
|
|
55
|
-
itemDisabled;
|
|
56
|
-
svgIcon;
|
|
57
|
-
icon;
|
|
58
|
-
subs;
|
|
59
|
-
ngOnInit() {
|
|
60
|
-
this.value = this.toolsService.toolsState[this.command];
|
|
61
|
-
this.subs = this.toolsService.stateChange.subscribe(state => {
|
|
62
|
-
this.value = state[this.command];
|
|
63
|
-
});
|
|
64
|
-
this.svgIcon = commandSVGIcons[this.command];
|
|
65
|
-
this.icon = commandIcons[this.command];
|
|
66
|
-
}
|
|
67
|
-
ngOnDestroy() {
|
|
68
|
-
if (this.subs) {
|
|
69
|
-
this.subs.unsubscribe();
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
/**
|
|
73
|
-
* @hidden
|
|
74
|
-
*/
|
|
75
|
-
messageFor(key) {
|
|
76
|
-
return this.localization.get(key);
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* @hidden
|
|
80
|
-
*/
|
|
81
|
-
onValueChange(ev) {
|
|
82
|
-
if (isPresent(ev)) {
|
|
83
|
-
if (hasObservers(this.valueChange)) {
|
|
84
|
-
this.valueChange.emit(ev);
|
|
85
|
-
}
|
|
86
|
-
const options = {
|
|
87
|
-
command: 'PropertyChangeCommand',
|
|
88
|
-
options: { property: this.command, value: ev || null }
|
|
89
|
-
};
|
|
90
|
-
this.spreadsheetService.spreadsheet.executeCommand(options);
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
/**
|
|
94
|
-
* @hidden
|
|
95
|
-
*/
|
|
96
|
-
get outerWidth() {
|
|
97
|
-
if (this.element) {
|
|
98
|
-
return outerWidth(this.element.nativeElement);
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
/**
|
|
102
|
-
* @hidden
|
|
103
|
-
*/
|
|
104
|
-
openDialog() {
|
|
105
|
-
const dialogSettings = {
|
|
106
|
-
appendTo: this.spreadsheetService.dialogContainer,
|
|
107
|
-
title: this.messageFor(this.command),
|
|
108
|
-
content: DialogContentComponent,
|
|
109
|
-
actions: [{
|
|
110
|
-
text: this.messageFor('dialogApply'),
|
|
111
|
-
themeColor: 'primary'
|
|
112
|
-
}, {
|
|
113
|
-
text: this.messageFor('dialogCancel')
|
|
114
|
-
}],
|
|
115
|
-
actionsLayout: 'start',
|
|
116
|
-
width: 400,
|
|
117
|
-
autoFocusedElement: '.k-picker'
|
|
118
|
-
};
|
|
119
|
-
this.toolbar.toggle(false);
|
|
120
|
-
const dialog = this.dialogService.open(dialogSettings);
|
|
121
|
-
const dialogInstance = dialog.dialog.instance;
|
|
122
|
-
const dialogContent = dialog.content.instance;
|
|
123
|
-
dialogInstance.action.pipe(take(1)).subscribe((event) => {
|
|
124
|
-
if (event.text === this.messageFor('dialogApply')) {
|
|
125
|
-
const options = {
|
|
126
|
-
command: 'PropertyChangeCommand',
|
|
127
|
-
options: { property: this.command, value: dialogContent.value || null }
|
|
128
|
-
};
|
|
129
|
-
this.spreadsheetService.spreadsheet.executeCommand(options);
|
|
130
|
-
}
|
|
131
|
-
this.toolbar.toggle();
|
|
132
|
-
});
|
|
133
|
-
dialogInstance.close.pipe(take(1)).subscribe(() => {
|
|
134
|
-
this.toolbar.toggle();
|
|
135
|
-
});
|
|
136
|
-
dialogContent.setData({
|
|
137
|
-
data: this.data,
|
|
138
|
-
value: this.value,
|
|
139
|
-
tabindex: this.tabindex,
|
|
140
|
-
componentType: this.command,
|
|
141
|
-
title: this.localization.get(this.command)
|
|
142
|
-
});
|
|
143
|
-
}
|
|
144
|
-
/**
|
|
145
|
-
* @hidden
|
|
146
|
-
*/
|
|
147
|
-
focus(e) {
|
|
148
|
-
this.tabindex = 0;
|
|
149
|
-
if (e instanceof PointerEvent) {
|
|
150
|
-
return;
|
|
151
|
-
}
|
|
152
|
-
if (this.overflows) {
|
|
153
|
-
this.popupButton.nativeElement.focus();
|
|
154
|
-
}
|
|
155
|
-
else {
|
|
156
|
-
this.dropDownListRef.focus();
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
/**
|
|
160
|
-
* @hidden
|
|
161
|
-
*/
|
|
162
|
-
canFocus() {
|
|
163
|
-
return true;
|
|
164
|
-
}
|
|
165
|
-
/**
|
|
166
|
-
* @hidden
|
|
167
|
-
*/
|
|
168
|
-
handleKey() {
|
|
169
|
-
this.tabindex = -1;
|
|
170
|
-
return false;
|
|
171
|
-
}
|
|
172
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetDropDownToolBase, deps: [{ token: MY_TOKEN }, { token: i1.DialogService }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }, { token: i5.ToolBarComponent }], target: i0.ɵɵFactoryTarget.Component });
|
|
173
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetDropDownToolBase, selector: "ng-component", outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "element", first: true, predicate: ["element"], descendants: true, read: ElementRef }, { propertyName: "dropDownListRef", first: true, predicate: ["element"], descendants: true }, { propertyName: "popupButton", first: true, predicate: ["popupButton"], descendants: true, read: ElementRef }], usesInheritance: true, ngImport: i0, template: ``, isInline: true });
|
|
174
|
-
}
|
|
175
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetDropDownToolBase, decorators: [{
|
|
176
|
-
type: Component,
|
|
177
|
-
args: [{
|
|
178
|
-
template: ``
|
|
179
|
-
}]
|
|
180
|
-
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
181
|
-
type: Inject,
|
|
182
|
-
args: [MY_TOKEN]
|
|
183
|
-
}] }, { type: i1.DialogService }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }, { type: i5.ToolBarComponent }], propDecorators: { element: [{
|
|
184
|
-
type: ViewChild,
|
|
185
|
-
args: ['element', { read: ElementRef }]
|
|
186
|
-
}], dropDownListRef: [{
|
|
187
|
-
type: ViewChild,
|
|
188
|
-
args: ['element']
|
|
189
|
-
}], popupButton: [{
|
|
190
|
-
type: ViewChild,
|
|
191
|
-
args: ['popupButton', { read: ElementRef }]
|
|
192
|
-
}], valueChange: [{
|
|
193
|
-
type: Output
|
|
194
|
-
}] } });
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive, ElementRef, EventEmitter, HostBinding, Input, Output, ViewChild } from "@angular/core";
|
|
6
|
-
import { DropDownListComponent } from "@progress/kendo-angular-dropdowns";
|
|
7
|
-
import * as i0 from "@angular/core";
|
|
8
|
-
/**
|
|
9
|
-
* @hidden
|
|
10
|
-
*/
|
|
11
|
-
export class DropDownListBase {
|
|
12
|
-
display = 'inline-flex';
|
|
13
|
-
data;
|
|
14
|
-
value;
|
|
15
|
-
title;
|
|
16
|
-
tabindex;
|
|
17
|
-
fillMode = 'flat';
|
|
18
|
-
valueChange = new EventEmitter();
|
|
19
|
-
element;
|
|
20
|
-
dropDownList;
|
|
21
|
-
onValueChange(value) {
|
|
22
|
-
this.valueChange.emit(value);
|
|
23
|
-
}
|
|
24
|
-
focus() {
|
|
25
|
-
this.dropDownList.focus();
|
|
26
|
-
}
|
|
27
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: DropDownListBase, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
28
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: DropDownListBase, selector: "kendo-spreadsheet-dropdownlist-base", inputs: { data: "data", value: "value", title: "title", tabindex: "tabindex" }, outputs: { valueChange: "valueChange" }, host: { properties: { "style.display": "this.display" } }, viewQueries: [{ propertyName: "element", first: true, predicate: ["element"], descendants: true, static: true }, { propertyName: "dropDownList", first: true, predicate: ["element"], descendants: true, read: DropDownListComponent, static: true }], ngImport: i0 });
|
|
29
|
-
}
|
|
30
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: DropDownListBase, decorators: [{
|
|
31
|
-
type: Directive,
|
|
32
|
-
args: [{
|
|
33
|
-
selector: 'kendo-spreadsheet-dropdownlist-base'
|
|
34
|
-
}]
|
|
35
|
-
}], propDecorators: { display: [{
|
|
36
|
-
type: HostBinding,
|
|
37
|
-
args: ['style.display']
|
|
38
|
-
}], data: [{
|
|
39
|
-
type: Input
|
|
40
|
-
}], value: [{
|
|
41
|
-
type: Input
|
|
42
|
-
}], title: [{
|
|
43
|
-
type: Input
|
|
44
|
-
}], tabindex: [{
|
|
45
|
-
type: Input
|
|
46
|
-
}], valueChange: [{
|
|
47
|
-
type: Output
|
|
48
|
-
}], element: [{
|
|
49
|
-
type: ViewChild,
|
|
50
|
-
args: ['element', { static: true }]
|
|
51
|
-
}], dropDownList: [{
|
|
52
|
-
type: ViewChild,
|
|
53
|
-
args: ['element', { read: DropDownListComponent, static: true }]
|
|
54
|
-
}] } });
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from '.././tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from '.././shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from ".././tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetAddColumnLeftButtonDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('addColumnLeft', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'AddColumnCommand',
|
|
23
|
-
options: { property: 'addColumnLeft',
|
|
24
|
-
value: 'left'
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddColumnLeftButtonDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
29
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetAddColumnLeftButtonDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetAddColumnLeftButton]", usesInheritance: true, ngImport: i0 });
|
|
30
|
-
}
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddColumnLeftButtonDirective, decorators: [{
|
|
32
|
-
type: Directive,
|
|
33
|
-
args: [{
|
|
34
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetAddColumnLeftButton]',
|
|
35
|
-
standalone: true
|
|
36
|
-
}]
|
|
37
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from '.././tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from '.././shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from ".././tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetAddColumnRightButtonDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('addColumnRight', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'AddColumnCommand',
|
|
23
|
-
options: { property: 'addColumnRight',
|
|
24
|
-
value: 'right'
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddColumnRightButtonDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
29
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetAddColumnRightButtonDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetAddColumnRightButton]", usesInheritance: true, ngImport: i0 });
|
|
30
|
-
}
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddColumnRightButtonDirective, decorators: [{
|
|
32
|
-
type: Directive,
|
|
33
|
-
args: [{
|
|
34
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetAddColumnRightButton]',
|
|
35
|
-
standalone: true
|
|
36
|
-
}]
|
|
37
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from '.././tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from '.././shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from ".././tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetAddRowAboveButtonDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('addRowAbove', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'AddRowCommand',
|
|
23
|
-
options: { property: 'addRowAbove',
|
|
24
|
-
value: 'above'
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddRowAboveButtonDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
29
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetAddRowAboveButtonDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetAddRowAboveButton]", usesInheritance: true, ngImport: i0 });
|
|
30
|
-
}
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddRowAboveButtonDirective, decorators: [{
|
|
32
|
-
type: Directive,
|
|
33
|
-
args: [{
|
|
34
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetAddRowAboveButton]',
|
|
35
|
-
standalone: true
|
|
36
|
-
}]
|
|
37
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from '.././tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from '.././shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from ".././tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetAddRowBelowButtonDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('addRowBelow', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'AddRowCommand',
|
|
23
|
-
options: { property: 'addRowBelow',
|
|
24
|
-
value: 'below'
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddRowBelowButtonDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
29
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetAddRowBelowButtonDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetAddRowBelowButton]", usesInheritance: true, ngImport: i0 });
|
|
30
|
-
}
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetAddRowBelowButtonDirective, decorators: [{
|
|
32
|
-
type: Directive,
|
|
33
|
-
args: [{
|
|
34
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetAddRowBelowButton]',
|
|
35
|
-
standalone: true
|
|
36
|
-
}]
|
|
37
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from '.././tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from '.././shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from ".././tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetDeleteColumnButtonDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('deleteColumn', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'DeleteColumnCommand',
|
|
23
|
-
options: { property: 'deleteColumn' }
|
|
24
|
-
});
|
|
25
|
-
}
|
|
26
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetDeleteColumnButtonDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
27
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetDeleteColumnButtonDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetDeleteColumnButton]", usesInheritance: true, ngImport: i0 });
|
|
28
|
-
}
|
|
29
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetDeleteColumnButtonDirective, decorators: [{
|
|
30
|
-
type: Directive,
|
|
31
|
-
args: [{
|
|
32
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetDeleteColumnButton]',
|
|
33
|
-
standalone: true
|
|
34
|
-
}]
|
|
35
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from '.././tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from '.././shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from ".././tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetDeleteRowButtonDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('deleteRow', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'DeleteRowCommand',
|
|
23
|
-
options: { property: 'deleteRow' }
|
|
24
|
-
});
|
|
25
|
-
}
|
|
26
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetDeleteRowButtonDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
27
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetDeleteRowButtonDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetDeleteRowButton]", usesInheritance: true, ngImport: i0 });
|
|
28
|
-
}
|
|
29
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetDeleteRowButtonDirective, decorators: [{
|
|
30
|
-
type: Directive,
|
|
31
|
-
args: [{
|
|
32
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetDeleteRowButton]',
|
|
33
|
-
standalone: true
|
|
34
|
-
}]
|
|
35
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
export { SpreadsheetAddColumnLeftButtonDirective } from './add-column-left-button.directive';
|
|
6
|
-
export { SpreadsheetAddColumnRightButtonDirective } from './add-column-right-button.directive';
|
|
7
|
-
export { SpreadsheetAddRowAboveButtonDirective } from './add-row-above-button.directive';
|
|
8
|
-
export { SpreadsheetAddRowBelowButtonDirective } from './add-row-below-button.directive';
|
|
9
|
-
export { SpreadsheetDeleteColumnButtonDirective } from './delete-column-button.directive';
|
|
10
|
-
export { SpreadsheetDeleteRowButtonDirective } from './delete-row-button.directive';
|
|
11
|
-
export { SpreadsheetMergeDirective } from './merge-tool.directive';
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { Subscription } from 'rxjs';
|
|
7
|
-
import { ToolBarDropDownButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
8
|
-
import { SpreadsheetLocalizationService } from '../../localization/spreadsheet-localization.service';
|
|
9
|
-
import { SpreadsheetService } from '../../common/spreadsheet.service';
|
|
10
|
-
import { commandIcons, commandSVGIcons } from '../shared/command-icons';
|
|
11
|
-
import { MERGE } from '../shared/constants';
|
|
12
|
-
import * as i0 from "@angular/core";
|
|
13
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
14
|
-
import * as i2 from "../../localization/spreadsheet-localization.service";
|
|
15
|
-
import * as i3 from "../../common/spreadsheet.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetMergeDirective {
|
|
20
|
-
host;
|
|
21
|
-
spreadsheetService;
|
|
22
|
-
commandName = 'merge';
|
|
23
|
-
subs = new Subscription();
|
|
24
|
-
selectedRange;
|
|
25
|
-
constructor(host, localization, spreadsheetService) {
|
|
26
|
-
this.host = host;
|
|
27
|
-
this.spreadsheetService = spreadsheetService;
|
|
28
|
-
host.svgIcon = commandSVGIcons[this.commandName];
|
|
29
|
-
host.icon = commandIcons[this.commandName];
|
|
30
|
-
host.arrowIcon = true;
|
|
31
|
-
host.fillMode = 'flat';
|
|
32
|
-
host.data = MERGE.map(item => ({ ...item, textKey: localization.get(item.commandId) }));
|
|
33
|
-
this.subs.add(host.itemClick.subscribe((e) => this.onItemClick(e)));
|
|
34
|
-
host.title = localization.get(this.commandName);
|
|
35
|
-
host.textField = 'textKey';
|
|
36
|
-
}
|
|
37
|
-
ngOnInit() {
|
|
38
|
-
this.subs.add(this.host.open.subscribe(() => {
|
|
39
|
-
const sheet = this.spreadsheetService.spreadsheet.activeSheet();
|
|
40
|
-
const isMergedCellWithinRange = this.hasMergedCells(sheet);
|
|
41
|
-
const unmergeItem = this.host.data.find(i => i.commandName === 'unmerge');
|
|
42
|
-
unmergeItem.disabled = !isMergedCellWithinRange;
|
|
43
|
-
}));
|
|
44
|
-
this.subs.add(this.spreadsheetService.selectionChanged.subscribe(range => this.selectedRange = range));
|
|
45
|
-
}
|
|
46
|
-
ngOnDestroy() {
|
|
47
|
-
this.subs.unsubscribe();
|
|
48
|
-
}
|
|
49
|
-
onItemClick(item) {
|
|
50
|
-
if (item.disabled) {
|
|
51
|
-
return;
|
|
52
|
-
}
|
|
53
|
-
const value = item.value || null;
|
|
54
|
-
const options = {
|
|
55
|
-
command: 'MergeCellCommand', options: { property: item.commandName, value }
|
|
56
|
-
};
|
|
57
|
-
this.spreadsheetService.spreadsheet.executeCommand(options);
|
|
58
|
-
}
|
|
59
|
-
hasMergedCells(sheet) {
|
|
60
|
-
const range = sheet._ref(this.selectedRange);
|
|
61
|
-
return sheet._getMergedCells(range).hasMerged;
|
|
62
|
-
}
|
|
63
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetMergeDirective, deps: [{ token: i1.ToolBarDropDownButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
64
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetMergeDirective, isStandalone: true, selector: "[kendoSpreadsheetMerge]", ngImport: i0 });
|
|
65
|
-
}
|
|
66
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetMergeDirective, decorators: [{
|
|
67
|
-
type: Directive,
|
|
68
|
-
args: [{
|
|
69
|
-
selector: '[kendoSpreadsheetMerge]',
|
|
70
|
-
standalone: true
|
|
71
|
-
}]
|
|
72
|
-
}], ctorParameters: () => [{ type: i1.ToolBarDropDownButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }] });
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Directive } from '@angular/core';
|
|
6
|
-
import { ToolBarButtonComponent } from '@progress/kendo-angular-toolbar';
|
|
7
|
-
import { SpreadsheetLocalizationService } from '../localization/spreadsheet-localization.service';
|
|
8
|
-
import { SpreadsheetService } from '../common/spreadsheet.service';
|
|
9
|
-
import { SpreadsheetToolsService } from './tools.service';
|
|
10
|
-
import { SpreadsheetCommandButton } from './shared/spreadsheet-command-button';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "@progress/kendo-angular-toolbar";
|
|
13
|
-
import * as i2 from "../localization/spreadsheet-localization.service";
|
|
14
|
-
import * as i3 from "../common/spreadsheet.service";
|
|
15
|
-
import * as i4 from "./tools.service";
|
|
16
|
-
/**
|
|
17
|
-
* @hidden
|
|
18
|
-
*/
|
|
19
|
-
export class SpreadsheetTextWrapDirective extends SpreadsheetCommandButton {
|
|
20
|
-
constructor(button, localization, spreadsheetService, toolsService) {
|
|
21
|
-
super('wrap', button, localization, spreadsheetService, toolsService, {
|
|
22
|
-
command: 'TextWrapCommand',
|
|
23
|
-
options: { property: 'wrap',
|
|
24
|
-
value: !button.selected
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
clickHandler() {
|
|
29
|
-
const sheet = this.spreadsheetService.spreadsheet.activeSheet();
|
|
30
|
-
if (sheet) {
|
|
31
|
-
const range = sheet.range(sheet.activeCell());
|
|
32
|
-
const value = !range.wrap();
|
|
33
|
-
const options = {
|
|
34
|
-
command: 'TextWrapCommand', options: { property: 'wrap', value }
|
|
35
|
-
};
|
|
36
|
-
this.spreadsheetService.spreadsheet.executeCommand(options);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetTextWrapDirective, deps: [{ token: i1.ToolBarButtonComponent }, { token: i2.SpreadsheetLocalizationService }, { token: i3.SpreadsheetService }, { token: i4.SpreadsheetToolsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
40
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.14", type: SpreadsheetTextWrapDirective, isStandalone: true, selector: "kendo-toolbar-button[kendoSpreadsheetTextWrap]", usesInheritance: true, ngImport: i0 });
|
|
41
|
-
}
|
|
42
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SpreadsheetTextWrapDirective, decorators: [{
|
|
43
|
-
type: Directive,
|
|
44
|
-
args: [{
|
|
45
|
-
selector: 'kendo-toolbar-button[kendoSpreadsheetTextWrap]',
|
|
46
|
-
standalone: true
|
|
47
|
-
}]
|
|
48
|
-
}], ctorParameters: () => [{ type: i1.ToolBarButtonComponent }, { type: i2.SpreadsheetLocalizationService }, { type: i3.SpreadsheetService }, { type: i4.SpreadsheetToolsService }] });
|