@progress/kendo-angular-toolbar 17.0.0-develop.9 → 17.0.1-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/README.md +28 -20
- package/common/fillmode.d.ts +8 -0
- package/common/size.d.ts +1 -1
- package/direction.d.ts +1 -1
- package/display-mode.d.ts +1 -1
- package/{esm2020 → esm2022}/common/preventable-event.mjs +1 -3
- package/{esm2020 → esm2022}/localization/custom-messages.component.mjs +9 -8
- package/{esm2020 → esm2022}/localization/localized-toolbar-messages.directive.mjs +9 -8
- package/{esm2020 → esm2022}/localization/messages.mjs +7 -3
- package/{esm2020 → esm2022}/navigation.service.mjs +9 -7
- package/{esm2020 → esm2022}/package-metadata.mjs +2 -2
- package/{esm2020 → esm2022}/refresh.service.mjs +4 -6
- package/{esm2020 → esm2022}/renderer.component.mjs +22 -10
- package/{esm2020 → esm2022}/renderer.service.mjs +5 -3
- package/esm2022/tool-options.mjs +5 -0
- package/{esm2020 → esm2022}/toolbar.component.mjs +104 -64
- package/{esm2020 → esm2022}/toolbar.module.mjs +4 -4
- package/{esm2020 → esm2022}/tools/toolbar-button.component.mjs +110 -98
- package/{esm2020 → esm2022}/tools/toolbar-buttongroup.component.mjs +49 -25
- package/{esm2020 → esm2022}/tools/toolbar-dropdownbutton.component.mjs +112 -95
- package/{esm2020 → esm2022}/tools/toolbar-separator.component.mjs +7 -12
- package/{esm2020 → esm2022}/tools/toolbar-spacer.component.mjs +10 -16
- package/{esm2020 → esm2022}/tools/toolbar-splitbutton.component.mjs +117 -102
- package/{esm2020 → esm2022}/tools/toolbar-tool.component.mjs +23 -13
- package/{esm2020 → esm2022}/tools/tools.service.mjs +8 -10
- package/{esm2020 → esm2022}/util.mjs +5 -0
- package/{fesm2020 → fesm2022}/progress-kendo-angular-toolbar.mjs +612 -484
- package/group-selection-settings.d.ts +1 -1
- package/index.d.ts +1 -0
- package/localization/messages.d.ts +1 -1
- package/package.json +15 -21
- package/render-location.d.ts +1 -1
- package/renderer.component.d.ts +1 -1
- package/schematics/ngAdd/index.js +1 -1
- package/toolbar.component.d.ts +11 -1
- package/tools/toolbar-button.component.d.ts +2 -8
- package/tools/toolbar-buttongroup.component.d.ts +8 -4
- package/tools/toolbar-dropdownbutton.component.d.ts +2 -4
- package/tools/toolbar-separator.component.d.ts +1 -3
- package/tools/toolbar-spacer.component.d.ts +1 -3
- package/tools/toolbar-splitbutton.component.d.ts +2 -4
- package/tools/toolbar-tool.component.d.ts +3 -3
- package/fesm2015/progress-kendo-angular-toolbar.mjs +0 -3374
- /package/{esm2020/common/renderer-click.mjs → esm2022/common/fillmode.mjs} +0 -0
- /package/{esm2020/common/size.mjs → esm2022/common/renderer-click.mjs} +0 -0
- /package/{esm2020/direction.mjs → esm2022/common/size.mjs} +0 -0
- /package/{esm2020/display-mode.mjs → esm2022/direction.mjs} +0 -0
- /package/{esm2020 → esm2022}/directives.mjs +0 -0
- /package/{esm2020/group-selection-settings.mjs → esm2022/display-mode.mjs} +0 -0
- /package/{esm2020/popup-settings.mjs → esm2022/group-selection-settings.mjs} +0 -0
- /package/{esm2020 → esm2022}/index.mjs +0 -0
- /package/{esm2020/render-location.mjs → esm2022/popup-settings.mjs} +0 -0
- /package/{esm2020 → esm2022}/progress-kendo-angular-toolbar.mjs +0 -0
- /package/{esm2020/tool-options.mjs → esm2022/render-location.mjs} +0 -0
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Component,
|
|
5
|
+
import { Component, forwardRef, ViewChild, Input, ElementRef, Output, EventEmitter, ViewChildren, QueryList, isDevMode } from '@angular/core';
|
|
6
6
|
import { SplitButtonComponent } from '@progress/kendo-angular-buttons';
|
|
7
7
|
import { ToolBarToolComponent } from './toolbar-tool.component';
|
|
8
8
|
import { getValueForLocation, makePeeker, getIndexOfFocused, getPrevKey, getNextKey, seekFocusedIndex, areEqual } from '../util';
|
|
@@ -14,96 +14,6 @@ import * as i0 from "@angular/core";
|
|
|
14
14
|
* Represents the [Kendo UI ToolBar SplitButton for Angular]({% slug controltypes_toolbar %}#toc-splitbuttons).
|
|
15
15
|
*/
|
|
16
16
|
export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
17
|
-
constructor() {
|
|
18
|
-
super();
|
|
19
|
-
/**
|
|
20
|
-
* Specifies where button icon should be displayed
|
|
21
|
-
*/
|
|
22
|
-
this.showIcon = 'both';
|
|
23
|
-
/**
|
|
24
|
-
* The fillMode property specifies the background and border styles of the Button.
|
|
25
|
-
*
|
|
26
|
-
* The available values are:
|
|
27
|
-
* * `solid` (default)
|
|
28
|
-
* * `flat`
|
|
29
|
-
* * `outline`
|
|
30
|
-
* * `link`
|
|
31
|
-
* * `null`
|
|
32
|
-
*/
|
|
33
|
-
this.fillMode = 'solid';
|
|
34
|
-
/**
|
|
35
|
-
* The Button allows you to specify predefined theme colors.
|
|
36
|
-
* The theme color will be applied as a background and border color while also amending the text color accordingly.
|
|
37
|
-
*
|
|
38
|
-
* The possible values are:
|
|
39
|
-
* * `base` —Applies coloring based on the `base` theme color. (default)
|
|
40
|
-
* * `primary` —Applies coloring based on the `primary` theme color.
|
|
41
|
-
* * `secondary`—Applies coloring based on the `secondary` theme color.
|
|
42
|
-
* * `tertiary`— Applies coloring based on the `tertiary` theme color.
|
|
43
|
-
* * `info`—Applies coloring based on the `info` theme color.
|
|
44
|
-
* * `success`— Applies coloring based on the `success` theme color.
|
|
45
|
-
* * `warning`— Applies coloring based on the `warning` theme color.
|
|
46
|
-
* * `error`— Applies coloring based on the `error` theme color.
|
|
47
|
-
* * `dark`— Applies coloring based on the `dark` theme color.
|
|
48
|
-
* * `light`— Applies coloring based on the `light` theme color.
|
|
49
|
-
* * `inverse`— Applies coloring based on the `inverse` theme color.
|
|
50
|
-
* * `null` —Removes the default CSS class (no class would be rendered).
|
|
51
|
-
*/
|
|
52
|
-
this.themeColor = 'base';
|
|
53
|
-
/**
|
|
54
|
-
* Specifies the name of the [font icon]({% slug icons %}#toc-list-of-font-icons) that will
|
|
55
|
-
* be rendered for the button which opens the popup.
|
|
56
|
-
*/
|
|
57
|
-
this.arrowButtonIcon = 'caret-alt-down';
|
|
58
|
-
/**
|
|
59
|
-
* Specifies the [`SVGIcon`](slug:api_icons_svgicon) that will
|
|
60
|
-
* be rendered for the button which opens the popup.
|
|
61
|
-
*/
|
|
62
|
-
this.arrowButtonSvgIcon = caretAltDownIcon;
|
|
63
|
-
/**
|
|
64
|
-
* Configures the text field of the button-list popup.
|
|
65
|
-
*/
|
|
66
|
-
this.textField = 'text';
|
|
67
|
-
/**
|
|
68
|
-
* Fires each time the user clicks the main button.
|
|
69
|
-
*/
|
|
70
|
-
this.buttonClick = new EventEmitter();
|
|
71
|
-
/**
|
|
72
|
-
* Fires each time the user clicks the drop-down list.
|
|
73
|
-
* The event data contains the data item that is bound to the clicked list item.
|
|
74
|
-
*/
|
|
75
|
-
this.itemClick = new EventEmitter();
|
|
76
|
-
/**
|
|
77
|
-
* Fires each time the popup is about to open.
|
|
78
|
-
* This event is preventable. If you cancel the event, the popup will remain closed.
|
|
79
|
-
*/
|
|
80
|
-
this.open = new EventEmitter();
|
|
81
|
-
/**
|
|
82
|
-
* Fires each time the popup is about to close.
|
|
83
|
-
* This event is preventable. If you cancel the event, the popup will remain open.
|
|
84
|
-
*/
|
|
85
|
-
this.close = new EventEmitter();
|
|
86
|
-
this.toolbarOptions = {
|
|
87
|
-
text: '',
|
|
88
|
-
icon: '',
|
|
89
|
-
iconClass: '',
|
|
90
|
-
svgIcon: null,
|
|
91
|
-
imageUrl: ''
|
|
92
|
-
};
|
|
93
|
-
this.overflowOptions = {
|
|
94
|
-
text: '',
|
|
95
|
-
icon: '',
|
|
96
|
-
iconClass: '',
|
|
97
|
-
svgIcon: null,
|
|
98
|
-
imageUrl: ''
|
|
99
|
-
};
|
|
100
|
-
this._popupSettings = { animate: true, popupClass: '' };
|
|
101
|
-
this.focusedIndex = -1;
|
|
102
|
-
this._showText = 'both';
|
|
103
|
-
this.getNextKey = getNextKey();
|
|
104
|
-
this.getPrevKey = getPrevKey();
|
|
105
|
-
this.isBuiltInTool = true;
|
|
106
|
-
}
|
|
107
17
|
// showText and showIcon showIcon should be declared first
|
|
108
18
|
/**
|
|
109
19
|
* Specifies where button text should be displayed
|
|
@@ -115,6 +25,10 @@ export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
|
115
25
|
get showText() {
|
|
116
26
|
return this._showText;
|
|
117
27
|
}
|
|
28
|
+
/**
|
|
29
|
+
* Specifies where button icon should be displayed
|
|
30
|
+
*/
|
|
31
|
+
showIcon = 'both';
|
|
118
32
|
/**
|
|
119
33
|
* Sets the text of the SplitButton ([see example](slug:controltypes_toolbar#toc-split-buttons).
|
|
120
34
|
*/
|
|
@@ -163,6 +77,10 @@ export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
|
163
77
|
this.toolbarOptions.imageUrl = getValueForLocation(imageUrl, this.showIcon, false);
|
|
164
78
|
this.overflowOptions.imageUrl = getValueForLocation(imageUrl, this.showIcon, true);
|
|
165
79
|
}
|
|
80
|
+
/**
|
|
81
|
+
* When set to `true`, disables a SplitButton item.
|
|
82
|
+
*/
|
|
83
|
+
disabled;
|
|
166
84
|
/**
|
|
167
85
|
* Configures the popup of the SplitButton.
|
|
168
86
|
*
|
|
@@ -179,6 +97,36 @@ export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
|
179
97
|
}
|
|
180
98
|
return this._popupSettings;
|
|
181
99
|
}
|
|
100
|
+
/**
|
|
101
|
+
* The fillMode property specifies the background and border styles of the Button.
|
|
102
|
+
*
|
|
103
|
+
* The available values are:
|
|
104
|
+
* * `solid` (default)
|
|
105
|
+
* * `flat`
|
|
106
|
+
* * `outline`
|
|
107
|
+
* * `link`
|
|
108
|
+
* * `null`
|
|
109
|
+
*/
|
|
110
|
+
fillMode = 'solid';
|
|
111
|
+
/**
|
|
112
|
+
* The Button allows you to specify predefined theme colors.
|
|
113
|
+
* The theme color will be applied as a background and border color while also amending the text color accordingly.
|
|
114
|
+
*
|
|
115
|
+
* The possible values are:
|
|
116
|
+
* * `base` —Applies coloring based on the `base` theme color. (default)
|
|
117
|
+
* * `primary` —Applies coloring based on the `primary` theme color.
|
|
118
|
+
* * `secondary`—Applies coloring based on the `secondary` theme color.
|
|
119
|
+
* * `tertiary`— Applies coloring based on the `tertiary` theme color.
|
|
120
|
+
* * `info`—Applies coloring based on the `info` theme color.
|
|
121
|
+
* * `success`— Applies coloring based on the `success` theme color.
|
|
122
|
+
* * `warning`— Applies coloring based on the `warning` theme color.
|
|
123
|
+
* * `error`— Applies coloring based on the `error` theme color.
|
|
124
|
+
* * `dark`— Applies coloring based on the `dark` theme color.
|
|
125
|
+
* * `light`— Applies coloring based on the `light` theme color.
|
|
126
|
+
* * `inverse`— Applies coloring based on the `inverse` theme color.
|
|
127
|
+
* * `null` —Removes the default CSS class (no class would be rendered).
|
|
128
|
+
*/
|
|
129
|
+
themeColor = 'base';
|
|
182
130
|
/**
|
|
183
131
|
* @hidden
|
|
184
132
|
*/
|
|
@@ -187,6 +135,30 @@ export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
|
187
135
|
this.fillMode = look === 'default' ? 'solid' : look;
|
|
188
136
|
}
|
|
189
137
|
}
|
|
138
|
+
/**
|
|
139
|
+
* The CSS classes that will be rendered on the main button.
|
|
140
|
+
* Supports the type of values that are supported by [`ngClass`](link:site.data.urls.angular['ngclassapi']).
|
|
141
|
+
*/
|
|
142
|
+
buttonClass;
|
|
143
|
+
/**
|
|
144
|
+
* The CSS classes that will be rendered on the button which opens the popup.
|
|
145
|
+
* Supports the type of values that are supported by [`ngClass`](link:site.data.urls.angular['ngclassapi']).
|
|
146
|
+
*/
|
|
147
|
+
arrowButtonClass;
|
|
148
|
+
/**
|
|
149
|
+
* Specifies the name of the [font icon]({% slug icons %}#toc-list-of-font-icons) that will
|
|
150
|
+
* be rendered for the button which opens the popup.
|
|
151
|
+
*/
|
|
152
|
+
arrowButtonIcon = 'caret-alt-down';
|
|
153
|
+
/**
|
|
154
|
+
* Specifies the [`SVGIcon`](slug:api_icons_svgicon) that will
|
|
155
|
+
* be rendered for the button which opens the popup.
|
|
156
|
+
*/
|
|
157
|
+
arrowButtonSvgIcon = caretAltDownIcon;
|
|
158
|
+
/**
|
|
159
|
+
* Configures the text field of the button-list popup.
|
|
160
|
+
*/
|
|
161
|
+
textField = 'text';
|
|
190
162
|
/**
|
|
191
163
|
* Sets the data of the SplitButton ([see example]({% slug controltypes_toolbar %}#toc-splitbuttons)).
|
|
192
164
|
*
|
|
@@ -201,12 +173,61 @@ export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
|
201
173
|
}
|
|
202
174
|
return this._data;
|
|
203
175
|
}
|
|
176
|
+
/**
|
|
177
|
+
* Fires each time the user clicks the main button.
|
|
178
|
+
*/
|
|
179
|
+
buttonClick = new EventEmitter();
|
|
180
|
+
/**
|
|
181
|
+
* Fires each time the user clicks the drop-down list.
|
|
182
|
+
* The event data contains the data item that is bound to the clicked list item.
|
|
183
|
+
*/
|
|
184
|
+
itemClick = new EventEmitter();
|
|
185
|
+
/**
|
|
186
|
+
* Fires each time the popup is about to open.
|
|
187
|
+
* This event is preventable. If you cancel the event, the popup will remain closed.
|
|
188
|
+
*/
|
|
189
|
+
open = new EventEmitter();
|
|
190
|
+
/**
|
|
191
|
+
* Fires each time the popup is about to close.
|
|
192
|
+
* This event is preventable. If you cancel the event, the popup will remain open.
|
|
193
|
+
*/
|
|
194
|
+
close = new EventEmitter();
|
|
195
|
+
toolbarOptions = {
|
|
196
|
+
text: '',
|
|
197
|
+
icon: '',
|
|
198
|
+
iconClass: '',
|
|
199
|
+
svgIcon: null,
|
|
200
|
+
imageUrl: ''
|
|
201
|
+
};
|
|
202
|
+
overflowOptions = {
|
|
203
|
+
text: '',
|
|
204
|
+
icon: '',
|
|
205
|
+
iconClass: '',
|
|
206
|
+
svgIcon: null,
|
|
207
|
+
imageUrl: ''
|
|
208
|
+
};
|
|
204
209
|
ngOnInit() {
|
|
205
210
|
this.setTextDisplayMode();
|
|
206
211
|
}
|
|
207
212
|
get overflowButtons() {
|
|
208
213
|
return [this.overflowMainButton, ...this.overflowListItems.toArray().filter(el => !el.nativeElement.classList.contains('k-disabled'))];
|
|
209
214
|
}
|
|
215
|
+
_data;
|
|
216
|
+
_popupSettings = { animate: true, popupClass: '' };
|
|
217
|
+
focusedIndex = -1;
|
|
218
|
+
_showText = 'both';
|
|
219
|
+
_text;
|
|
220
|
+
getNextKey;
|
|
221
|
+
getPrevKey;
|
|
222
|
+
toolbarSplitButton;
|
|
223
|
+
overflowMainButton;
|
|
224
|
+
overflowListItems;
|
|
225
|
+
constructor() {
|
|
226
|
+
super();
|
|
227
|
+
this.getNextKey = getNextKey();
|
|
228
|
+
this.getPrevKey = getPrevKey();
|
|
229
|
+
this.isBuiltInTool = true;
|
|
230
|
+
}
|
|
210
231
|
/**
|
|
211
232
|
* @hidden
|
|
212
233
|
*/
|
|
@@ -284,9 +305,8 @@ export class ToolBarSplitButtonComponent extends ToolBarToolComponent {
|
|
|
284
305
|
this.toolbarOptions.text = this.showText === 'overflow' ? undefined : this.text;
|
|
285
306
|
this.overflowOptions.text = this.showText === 'toolbar' ? undefined : this.text;
|
|
286
307
|
}
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
ToolBarSplitButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ToolBarSplitButtonComponent, isStandalone: true, selector: "kendo-toolbar-splitbutton", inputs: { showText: "showText", showIcon: "showIcon", text: "text", icon: "icon", svgIcon: "svgIcon", iconClass: "iconClass", imageUrl: "imageUrl", disabled: "disabled", popupSettings: "popupSettings", fillMode: "fillMode", themeColor: "themeColor", look: "look", buttonClass: "buttonClass", arrowButtonClass: "arrowButtonClass", arrowButtonIcon: "arrowButtonIcon", arrowButtonSvgIcon: "arrowButtonSvgIcon", textField: "textField", data: "data" }, outputs: { buttonClick: "buttonClick", itemClick: "itemClick", open: "open", close: "close" }, providers: [{ provide: ToolBarToolComponent, useExisting: forwardRef(() => ToolBarSplitButtonComponent) }], viewQueries: [{ propertyName: "toolbarTemplate", first: true, predicate: ["toolbarTemplate"], descendants: true, static: true }, { propertyName: "popupTemplate", first: true, predicate: ["popupTemplate"], descendants: true, static: true }, { propertyName: "toolbarSplitButton", first: true, predicate: ["toolbarSplitButton"], descendants: true }, { propertyName: "overflowMainButton", first: true, predicate: ["overflowMainButton"], descendants: true, read: ElementRef }, { propertyName: "overflowListItems", predicate: ["listItem"], descendants: true }], exportAs: ["kendoToolBarSplitButton"], usesInheritance: true, ngImport: i0, template: `
|
|
308
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolBarSplitButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
309
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ToolBarSplitButtonComponent, isStandalone: true, selector: "kendo-toolbar-splitbutton", inputs: { showText: "showText", showIcon: "showIcon", text: "text", icon: "icon", svgIcon: "svgIcon", iconClass: "iconClass", imageUrl: "imageUrl", disabled: "disabled", popupSettings: "popupSettings", fillMode: "fillMode", themeColor: "themeColor", look: "look", buttonClass: "buttonClass", arrowButtonClass: "arrowButtonClass", arrowButtonIcon: "arrowButtonIcon", arrowButtonSvgIcon: "arrowButtonSvgIcon", textField: "textField", data: "data" }, outputs: { buttonClick: "buttonClick", itemClick: "itemClick", open: "open", close: "close" }, providers: [{ provide: ToolBarToolComponent, useExisting: forwardRef(() => ToolBarSplitButtonComponent) }], viewQueries: [{ propertyName: "toolbarSplitButton", first: true, predicate: ["toolbarSplitButton"], descendants: true }, { propertyName: "overflowMainButton", first: true, predicate: ["overflowMainButton"], descendants: true, read: ElementRef }, { propertyName: "overflowListItems", predicate: ["listItem"], descendants: true }], exportAs: ["kendoToolBarSplitButton"], usesInheritance: true, ngImport: i0, template: `
|
|
290
310
|
<ng-template #toolbarTemplate>
|
|
291
311
|
<kendo-splitbutton
|
|
292
312
|
#toolbarSplitButton
|
|
@@ -356,8 +376,9 @@ ToolBarSplitButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.
|
|
|
356
376
|
</div>
|
|
357
377
|
</ng-container>
|
|
358
378
|
</ng-template>
|
|
359
|
-
`, isInline: true, dependencies: [{ kind: "component", type: SplitButtonComponent, selector: "kendo-splitbutton", inputs: ["text", "icon", "svgIcon", "iconClass", "type", "imageUrl", "size", "rounded", "fillMode", "themeColor", "disabled", "popupSettings", "tabIndex", "textField", "data", "
|
|
360
|
-
|
|
379
|
+
`, isInline: true, dependencies: [{ kind: "component", type: SplitButtonComponent, selector: "kendo-splitbutton", inputs: ["text", "icon", "svgIcon", "iconClass", "type", "imageUrl", "size", "rounded", "fillMode", "themeColor", "disabled", "popupSettings", "tabIndex", "textField", "data", "arrowButtonClass", "arrowButtonIcon", "arrowButtonSvgIcon", "buttonAttributes"], outputs: ["buttonClick", "itemClick", "focus", "blur", "open", "close"], exportAs: ["kendoSplitButton"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass", "size"], exportAs: ["kendoIconWrapper"] }, { kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
380
|
+
}
|
|
381
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolBarSplitButtonComponent, decorators: [{
|
|
361
382
|
type: Component,
|
|
362
383
|
args: [{
|
|
363
384
|
exportAs: 'kendoToolBarSplitButton',
|
|
@@ -481,12 +502,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
481
502
|
type: Output
|
|
482
503
|
}], close: [{
|
|
483
504
|
type: Output
|
|
484
|
-
}], toolbarTemplate: [{
|
|
485
|
-
type: ViewChild,
|
|
486
|
-
args: ['toolbarTemplate', { static: true }]
|
|
487
|
-
}], popupTemplate: [{
|
|
488
|
-
type: ViewChild,
|
|
489
|
-
args: ['popupTemplate', { static: true }]
|
|
490
505
|
}], toolbarSplitButton: [{
|
|
491
506
|
type: ViewChild,
|
|
492
507
|
args: ['toolbarSplitButton', { static: false }]
|
|
@@ -2,24 +2,28 @@
|
|
|
2
2
|
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Input, Directive, ElementRef, inject } from '@angular/core';
|
|
5
|
+
import { TemplateRef, Input, Directive, ElementRef, inject, ViewChild } from '@angular/core';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
/**
|
|
8
8
|
* Represents the Base ToolBar Tool component for Angular.
|
|
9
9
|
* Extend this class to create custom tools.
|
|
10
10
|
*/
|
|
11
11
|
export class ToolBarToolComponent {
|
|
12
|
+
toolbarTemplate;
|
|
13
|
+
popupTemplate;
|
|
14
|
+
tabIndex = -1; //Focus movement inside the toolbar is managed using roving tabindex.
|
|
15
|
+
overflows = true;
|
|
16
|
+
visibility;
|
|
17
|
+
element;
|
|
18
|
+
isBuiltInTool = false;
|
|
12
19
|
constructor() {
|
|
13
|
-
this.tabIndex = -1; //Focus movement inside the toolbar is managed using roving tabindex.
|
|
14
|
-
this.overflows = true;
|
|
15
|
-
this.isBuiltInTool = false;
|
|
16
|
-
// this should be replaced with showTool: DisplayMode = 'both';
|
|
17
|
-
/**
|
|
18
|
-
* @hidden
|
|
19
|
-
*/
|
|
20
|
-
this.responsive = true;
|
|
21
20
|
this.element = inject(ElementRef);
|
|
22
21
|
}
|
|
22
|
+
// this should be replaced with showTool: DisplayMode = 'both';
|
|
23
|
+
/**
|
|
24
|
+
* @hidden
|
|
25
|
+
*/
|
|
26
|
+
responsive = true;
|
|
23
27
|
get toolbarDisplay() {
|
|
24
28
|
return this.overflows ? 'none' : 'inline-flex';
|
|
25
29
|
}
|
|
@@ -52,14 +56,20 @@ export class ToolBarToolComponent {
|
|
|
52
56
|
handleKey(ev) {
|
|
53
57
|
return false;
|
|
54
58
|
}
|
|
59
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolBarToolComponent, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
60
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: ToolBarToolComponent, isStandalone: true, inputs: { responsive: "responsive" }, viewQueries: [{ propertyName: "toolbarTemplate", first: true, predicate: ["toolbarTemplate"], descendants: true, static: true }, { propertyName: "popupTemplate", first: true, predicate: ["popupTemplate"], descendants: true, static: true }], ngImport: i0 });
|
|
55
61
|
}
|
|
56
|
-
|
|
57
|
-
ToolBarToolComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: ToolBarToolComponent, isStandalone: true, inputs: { responsive: "responsive" }, ngImport: i0 });
|
|
58
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolBarToolComponent, decorators: [{
|
|
62
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolBarToolComponent, decorators: [{
|
|
59
63
|
type: Directive,
|
|
60
64
|
args: [{
|
|
61
65
|
standalone: true
|
|
62
66
|
}]
|
|
63
|
-
}], ctorParameters: function () { return []; }, propDecorators: {
|
|
67
|
+
}], ctorParameters: function () { return []; }, propDecorators: { toolbarTemplate: [{
|
|
68
|
+
type: ViewChild,
|
|
69
|
+
args: ['toolbarTemplate', { static: true }]
|
|
70
|
+
}], popupTemplate: [{
|
|
71
|
+
type: ViewChild,
|
|
72
|
+
args: ['popupTemplate', { static: true }]
|
|
73
|
+
}], responsive: [{
|
|
64
74
|
type: Input
|
|
65
75
|
}] } });
|
|
@@ -9,16 +9,14 @@ import * as i0 from "@angular/core";
|
|
|
9
9
|
* @hidden
|
|
10
10
|
*/
|
|
11
11
|
export class ToolbarToolsService {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
12
|
+
renderedToolsChange = new Subject();
|
|
13
|
+
overflowToolsChange = new Subject();
|
|
14
|
+
renderedTools = [];
|
|
15
|
+
overflowTools = [];
|
|
16
|
+
allTools = [];
|
|
17
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolbarToolsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
18
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolbarToolsService });
|
|
19
19
|
}
|
|
20
|
-
|
|
21
|
-
ToolbarToolsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarToolsService });
|
|
22
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarToolsService, decorators: [{
|
|
20
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ToolbarToolsService, decorators: [{
|
|
23
21
|
type: Injectable
|
|
24
22
|
}] });
|
|
@@ -205,6 +205,11 @@ export const getStylingClasses = (componentType, stylingOption, previousValue, n
|
|
|
205
205
|
toRemove: `k-${componentType}-${SIZES[previousValue]}`,
|
|
206
206
|
toAdd: newValue !== 'none' ? `k-${componentType}-${SIZES[newValue]}` : ''
|
|
207
207
|
};
|
|
208
|
+
case 'fillMode':
|
|
209
|
+
return {
|
|
210
|
+
toRemove: `k-${componentType}-${previousValue}`,
|
|
211
|
+
toAdd: newValue !== 'none' ? `k-${componentType}-${newValue}` : ''
|
|
212
|
+
};
|
|
208
213
|
default:
|
|
209
214
|
break;
|
|
210
215
|
}
|