@progress/kendo-vue-buttons 8.0.3-develop.2 → 8.0.3-develop.4
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/Button.d.ts +273 -0
- package/ButtonGroup.d.ts +58 -0
- package/ButtonGroupInterface.d.ts +37 -0
- package/ButtonInterface.d.ts +57 -0
- package/ButtonWrap.d.ts +12 -0
- package/Chip/Chip.d.ts +351 -0
- package/Chip/ChipList.d.ts +278 -0
- package/Chip/ChipList.mjs +4 -4
- package/Chip/data-reducer.d.ts +28 -0
- package/Chip/data-reducer.js +1 -1
- package/Chip/data-reducer.mjs +2 -2
- package/Chip/focus-reducer.d.ts +31 -0
- package/Chip/focus-reducer.js +1 -1
- package/Chip/focus-reducer.mjs +2 -2
- package/Chip/selection-reducer.d.ts +36 -0
- package/Chip/selection-reducer.js +1 -1
- package/Chip/selection-reducer.mjs +3 -3
- package/FloatingActionButton/FloatingActionButton.d.ts +151 -0
- package/FloatingActionButton/FloatingActionButtonItem.d.ts +134 -0
- package/FloatingActionButton/interfaces/FloatingActionButtonHandle.d.ts +20 -0
- package/FloatingActionButton/interfaces/FloatingActionButtonPopupSettings.d.ts +31 -0
- package/FloatingActionButton/interfaces/FloatingActionButtonProps.d.ts +240 -0
- package/FloatingActionButton/models/align-offset.d.ts +27 -0
- package/FloatingActionButton/models/align.d.ts +34 -0
- package/FloatingActionButton/models/events.d.ts +29 -0
- package/FloatingActionButton/models/position-mode.d.ts +16 -0
- package/FloatingActionButton/models/size.d.ts +17 -0
- package/FloatingActionButton/models/theme-color.d.ts +24 -0
- package/FloatingActionButton/utils.d.ts +34 -0
- package/ListButton/ButtonItem.d.ts +57 -0
- package/ListButton/DropDownButton.d.ts +168 -0
- package/ListButton/SplitButton.d.ts +174 -0
- package/ListButton/models/ButtonItemInterface.d.ts +36 -0
- package/ListButton/models/ListButtonProps.d.ts +311 -0
- package/ListButton/models/PopupSettings.d.ts +31 -0
- package/ListButton/models/events.d.ts +118 -0
- package/ListButton/utils/navigation.d.ts +12 -0
- package/ListButton/utils/popup.d.ts +16 -0
- package/SpeechToText/SpeechToTextButton.d.ts +242 -0
- package/SpeechToText/SpeechToTextButton.js +1 -1
- package/SpeechToText/SpeechToTextButton.mjs +2 -2
- package/dist/cdn/js/kendo-vue-buttons.js +1 -1
- package/index.d.mts +31 -2942
- package/index.d.ts +31 -2942
- package/models/ButtonBlurEvent.d.ts +16 -0
- package/models/ButtonFocusEvent.d.ts +16 -0
- package/models/events.d.ts +96 -0
- package/package-metadata.d.ts +12 -0
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +13 -7
- package/toolbar/Toolbar.d.ts +170 -0
- package/toolbar/interfaces/ToolbarOverflowProps.d.ts +48 -0
- package/toolbar/interfaces/ToolbarProps.d.ts +93 -0
- package/toolbar/messages/index.d.ts +27 -0
- package/toolbar/tools/ToolbarItem.d.ts +14 -0
- package/toolbar/tools/ToolbarOverflowSection.d.ts +50 -0
- package/toolbar/tools/ToolbarScrollButton.d.ts +47 -0
- package/toolbar/tools/ToolbarScrollable.d.ts +58 -0
- package/toolbar/tools/ToolbarSeparator.d.ts +34 -0
- package/toolbar/tools/ToolbarSpacer.d.ts +48 -0
- package/util.d.ts +37 -0
package/Chip/Chip.d.ts
ADDED
|
@@ -0,0 +1,351 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
import { SVGIcon } from '@progress/kendo-vue-common';
|
|
9
|
+
import { ChipRemoveEvent, ChipMouseEvent, ChipFocusEvent, ChipKeyboardEvent } from '../models/events';
|
|
10
|
+
import { PropType } from 'vue';
|
|
11
|
+
/**
|
|
12
|
+
* Represents the properties of the Avatar in the Chip.
|
|
13
|
+
*/
|
|
14
|
+
export interface ChipAvatarProps {
|
|
15
|
+
/**
|
|
16
|
+
* Sets the image of the avatar.
|
|
17
|
+
*/
|
|
18
|
+
imageUrl: string;
|
|
19
|
+
/**
|
|
20
|
+
* Defines the alternative text of the avatar image.
|
|
21
|
+
*/
|
|
22
|
+
imageAlt: string;
|
|
23
|
+
/**
|
|
24
|
+
* Configures the `roundness` of the avatar. Default is set to 'medium'.
|
|
25
|
+
*/
|
|
26
|
+
rounded?: null | 'small' | 'medium' | 'large' | 'full';
|
|
27
|
+
/**
|
|
28
|
+
* Sets additional CSS styles to the avatar
|
|
29
|
+
*/
|
|
30
|
+
style?: object;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Represents the properties of [Chip]({% slug overview_chip %}) component.
|
|
34
|
+
*/
|
|
35
|
+
export interface ChipProps {
|
|
36
|
+
/**
|
|
37
|
+
* Sets the `id` property of the top div element of the Chip.
|
|
38
|
+
*/
|
|
39
|
+
id?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Sets the `tabIndex` attribute.
|
|
42
|
+
*/
|
|
43
|
+
tabIndex?: number;
|
|
44
|
+
/**
|
|
45
|
+
* Sets the label text of the Chip.
|
|
46
|
+
*/
|
|
47
|
+
text?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Sets the `id` value of the Chip.
|
|
50
|
+
*/
|
|
51
|
+
value?: any;
|
|
52
|
+
/**
|
|
53
|
+
* The Chip direction 'ltr' as default or 'rtl'.
|
|
54
|
+
*/
|
|
55
|
+
dir?: string;
|
|
56
|
+
/**
|
|
57
|
+
* Determines if the Chip could be removed.
|
|
58
|
+
*/
|
|
59
|
+
removable?: boolean;
|
|
60
|
+
/**
|
|
61
|
+
* Determines if the Chip has custom `removeIcon`.
|
|
62
|
+
*/
|
|
63
|
+
removeIcon?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Defines an remove SVGIcon to be rendered within the chip.
|
|
66
|
+
*/
|
|
67
|
+
removeSvgIcon?: SVGIcon;
|
|
68
|
+
/**
|
|
69
|
+
* Determines if the Chip is disabled.
|
|
70
|
+
*/
|
|
71
|
+
disabled?: boolean;
|
|
72
|
+
/**
|
|
73
|
+
* Determines if the Chip has an `icon`.
|
|
74
|
+
*/
|
|
75
|
+
icon?: string;
|
|
76
|
+
/**
|
|
77
|
+
* Defines an SVGIcon to be rendered within the chip.
|
|
78
|
+
*/
|
|
79
|
+
svgIcon?: SVGIcon;
|
|
80
|
+
/**
|
|
81
|
+
* Determines if the Chip has custom selection `icon`.
|
|
82
|
+
*/
|
|
83
|
+
selectedIcon?: string;
|
|
84
|
+
/**
|
|
85
|
+
* Defines an selection SVGIcon to be rendered within the chip.
|
|
86
|
+
*/
|
|
87
|
+
selectedSvgIcon?: SVGIcon;
|
|
88
|
+
/**
|
|
89
|
+
* If set to object of type ChipAvatarProps with image and imageAlt it renders a default Avatar. If set to string or a `render` function it
|
|
90
|
+
* defines the avatar template that will be shown.
|
|
91
|
+
*/
|
|
92
|
+
avatar?: string | Function | Object;
|
|
93
|
+
/**
|
|
94
|
+
* Configures the `size` of the Chip.
|
|
95
|
+
*
|
|
96
|
+
* The available options are:
|
|
97
|
+
* - small
|
|
98
|
+
* - medium
|
|
99
|
+
* - large
|
|
100
|
+
*
|
|
101
|
+
* @default `undefined`
|
|
102
|
+
*/
|
|
103
|
+
size?: 'small' | 'medium' | 'large';
|
|
104
|
+
/**
|
|
105
|
+
* Configures the `roundness` of the Chip.
|
|
106
|
+
*
|
|
107
|
+
* The available options are:
|
|
108
|
+
* - none
|
|
109
|
+
* - small
|
|
110
|
+
* - medium
|
|
111
|
+
* - large
|
|
112
|
+
* - full
|
|
113
|
+
*
|
|
114
|
+
* @default `undefined`
|
|
115
|
+
*/
|
|
116
|
+
rounded?: 'none' | 'small' | 'medium' | 'large' | 'full';
|
|
117
|
+
/**
|
|
118
|
+
* Configures the `fillMode` of the Chip.
|
|
119
|
+
*
|
|
120
|
+
* The available options are:
|
|
121
|
+
* - solid
|
|
122
|
+
* - outline
|
|
123
|
+
* - flat
|
|
124
|
+
*
|
|
125
|
+
* @default `undefined`
|
|
126
|
+
*/
|
|
127
|
+
fillMode?: 'solid' | 'outline' | 'flat';
|
|
128
|
+
/**
|
|
129
|
+
* Configures the `themeColor` of the Chip.
|
|
130
|
+
*
|
|
131
|
+
* The available options are:
|
|
132
|
+
* - base
|
|
133
|
+
* - info
|
|
134
|
+
* - success
|
|
135
|
+
* - warning
|
|
136
|
+
* - error
|
|
137
|
+
*
|
|
138
|
+
* @default `undefined`
|
|
139
|
+
*/
|
|
140
|
+
themeColor?: 'base' | 'info' | 'success' | 'warning' | 'error';
|
|
141
|
+
/**
|
|
142
|
+
* Triggered on Chip removing.
|
|
143
|
+
*/
|
|
144
|
+
onRemove?: (event: ChipRemoveEvent) => void;
|
|
145
|
+
/**
|
|
146
|
+
* Triggered on onClick event.
|
|
147
|
+
*/
|
|
148
|
+
onClick?: (event: ChipMouseEvent) => void;
|
|
149
|
+
/**
|
|
150
|
+
* Triggered on onKeyDown event.
|
|
151
|
+
*/
|
|
152
|
+
onKeydown?: (event: ChipKeyboardEvent) => void;
|
|
153
|
+
/**
|
|
154
|
+
* Triggered on onFocus event.
|
|
155
|
+
*/
|
|
156
|
+
onFocus?: (event: ChipFocusEvent) => void;
|
|
157
|
+
/**
|
|
158
|
+
* Triggered on onBlur event.
|
|
159
|
+
*/
|
|
160
|
+
onBlur?: (event: ChipFocusEvent) => void;
|
|
161
|
+
/**
|
|
162
|
+
* Represents the item data, coming from the `ChipList` component.
|
|
163
|
+
*/
|
|
164
|
+
dataItem?: any;
|
|
165
|
+
/**
|
|
166
|
+
* Determines if the Chip is selected.
|
|
167
|
+
*/
|
|
168
|
+
selected?: boolean;
|
|
169
|
+
/**
|
|
170
|
+
* Identifies the element(s) which will describe the component, similar to HTML aria-describedby attribute.
|
|
171
|
+
* For example these elements could contain error or hint message.
|
|
172
|
+
*/
|
|
173
|
+
ariaDescribedBy?: string;
|
|
174
|
+
/**
|
|
175
|
+
* @hidden
|
|
176
|
+
*/
|
|
177
|
+
role?: string;
|
|
178
|
+
/**
|
|
179
|
+
* @hidden
|
|
180
|
+
*/
|
|
181
|
+
onMousedown?: (event: any) => void;
|
|
182
|
+
}
|
|
183
|
+
/**
|
|
184
|
+
* Represents the target(element and props) of the ChipRemoveEvent.
|
|
185
|
+
*/
|
|
186
|
+
export interface ChipHandle {
|
|
187
|
+
/**
|
|
188
|
+
* The current element or `null` if there is no one.
|
|
189
|
+
*/
|
|
190
|
+
element: HTMLDivElement | null;
|
|
191
|
+
/**
|
|
192
|
+
* The props values of the Chip.
|
|
193
|
+
*/
|
|
194
|
+
props: ChipProps;
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* @hidden
|
|
198
|
+
*/
|
|
199
|
+
declare const Chip: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
200
|
+
id: PropType<string>;
|
|
201
|
+
text: PropType<string>;
|
|
202
|
+
avatar: {
|
|
203
|
+
type: PropType<string | Object | Function>;
|
|
204
|
+
default: () => any;
|
|
205
|
+
};
|
|
206
|
+
value: PropType<any>;
|
|
207
|
+
dir: {
|
|
208
|
+
type: PropType<string>;
|
|
209
|
+
default: () => string;
|
|
210
|
+
};
|
|
211
|
+
removable: {
|
|
212
|
+
type: PropType<boolean>;
|
|
213
|
+
default: boolean;
|
|
214
|
+
};
|
|
215
|
+
removeIcon: {
|
|
216
|
+
type: PropType<string>;
|
|
217
|
+
default: () => string;
|
|
218
|
+
};
|
|
219
|
+
removeSvgIcon: {
|
|
220
|
+
type: PropType<SVGIcon>;
|
|
221
|
+
default: () => import('@progress/kendo-svg-icons').SVGIcon;
|
|
222
|
+
};
|
|
223
|
+
disabled: {
|
|
224
|
+
type: PropType<boolean>;
|
|
225
|
+
default: boolean;
|
|
226
|
+
};
|
|
227
|
+
icon: PropType<string>;
|
|
228
|
+
svgIcon: PropType<SVGIcon>;
|
|
229
|
+
selectedIcon: {
|
|
230
|
+
type: PropType<string>;
|
|
231
|
+
default: () => string;
|
|
232
|
+
};
|
|
233
|
+
selectedSvgIcon: {
|
|
234
|
+
type: PropType<SVGIcon>;
|
|
235
|
+
default: () => import('@progress/kendo-svg-icons').SVGIcon;
|
|
236
|
+
};
|
|
237
|
+
size: PropType<"small" | "medium" | "large">;
|
|
238
|
+
rounded: PropType<"small" | "medium" | "large" | "full" | "none">;
|
|
239
|
+
fillMode: {
|
|
240
|
+
type: PropType<"flat" | "solid" | "outline">;
|
|
241
|
+
validator: (value: string) => boolean;
|
|
242
|
+
};
|
|
243
|
+
themeColor: {
|
|
244
|
+
type: PropType<"base" | "info" | "success" | "warning" | "error">;
|
|
245
|
+
validator: (value: string) => boolean;
|
|
246
|
+
};
|
|
247
|
+
dataItem: PropType<any>;
|
|
248
|
+
selected: PropType<boolean>;
|
|
249
|
+
ariaDescribedBy: PropType<string>;
|
|
250
|
+
role: {
|
|
251
|
+
type: PropType<string>;
|
|
252
|
+
default: string;
|
|
253
|
+
};
|
|
254
|
+
tabIndex: PropType<number>;
|
|
255
|
+
onMousedown: PropType<(event: any) => void>;
|
|
256
|
+
}>, {
|
|
257
|
+
chipRef: import('vue').Ref<any, any>;
|
|
258
|
+
}, {}, {
|
|
259
|
+
currentSelected(): any;
|
|
260
|
+
chipLabelClass(): {
|
|
261
|
+
'k-chip-label': boolean;
|
|
262
|
+
};
|
|
263
|
+
}, {
|
|
264
|
+
computedFocused(): boolean;
|
|
265
|
+
handleMouseDown(event: any): void;
|
|
266
|
+
handleClick(event: any): void;
|
|
267
|
+
handleRemove(event: any): void;
|
|
268
|
+
handleKeyDown(event: any): void;
|
|
269
|
+
handleFocus(event: FocusEvent): void;
|
|
270
|
+
handleBlur(event: FocusEvent): void;
|
|
271
|
+
}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
272
|
+
click: (event: ChipMouseEvent) => true;
|
|
273
|
+
keydown: (event: ChipKeyboardEvent) => true;
|
|
274
|
+
blur: (event: ChipFocusEvent) => true;
|
|
275
|
+
focus: (event: ChipFocusEvent) => true;
|
|
276
|
+
remove: (event: ChipRemoveEvent) => true;
|
|
277
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
278
|
+
id: PropType<string>;
|
|
279
|
+
text: PropType<string>;
|
|
280
|
+
avatar: {
|
|
281
|
+
type: PropType<string | Object | Function>;
|
|
282
|
+
default: () => any;
|
|
283
|
+
};
|
|
284
|
+
value: PropType<any>;
|
|
285
|
+
dir: {
|
|
286
|
+
type: PropType<string>;
|
|
287
|
+
default: () => string;
|
|
288
|
+
};
|
|
289
|
+
removable: {
|
|
290
|
+
type: PropType<boolean>;
|
|
291
|
+
default: boolean;
|
|
292
|
+
};
|
|
293
|
+
removeIcon: {
|
|
294
|
+
type: PropType<string>;
|
|
295
|
+
default: () => string;
|
|
296
|
+
};
|
|
297
|
+
removeSvgIcon: {
|
|
298
|
+
type: PropType<SVGIcon>;
|
|
299
|
+
default: () => import('@progress/kendo-svg-icons').SVGIcon;
|
|
300
|
+
};
|
|
301
|
+
disabled: {
|
|
302
|
+
type: PropType<boolean>;
|
|
303
|
+
default: boolean;
|
|
304
|
+
};
|
|
305
|
+
icon: PropType<string>;
|
|
306
|
+
svgIcon: PropType<SVGIcon>;
|
|
307
|
+
selectedIcon: {
|
|
308
|
+
type: PropType<string>;
|
|
309
|
+
default: () => string;
|
|
310
|
+
};
|
|
311
|
+
selectedSvgIcon: {
|
|
312
|
+
type: PropType<SVGIcon>;
|
|
313
|
+
default: () => import('@progress/kendo-svg-icons').SVGIcon;
|
|
314
|
+
};
|
|
315
|
+
size: PropType<"small" | "medium" | "large">;
|
|
316
|
+
rounded: PropType<"small" | "medium" | "large" | "full" | "none">;
|
|
317
|
+
fillMode: {
|
|
318
|
+
type: PropType<"flat" | "solid" | "outline">;
|
|
319
|
+
validator: (value: string) => boolean;
|
|
320
|
+
};
|
|
321
|
+
themeColor: {
|
|
322
|
+
type: PropType<"base" | "info" | "success" | "warning" | "error">;
|
|
323
|
+
validator: (value: string) => boolean;
|
|
324
|
+
};
|
|
325
|
+
dataItem: PropType<any>;
|
|
326
|
+
selected: PropType<boolean>;
|
|
327
|
+
ariaDescribedBy: PropType<string>;
|
|
328
|
+
role: {
|
|
329
|
+
type: PropType<string>;
|
|
330
|
+
default: string;
|
|
331
|
+
};
|
|
332
|
+
tabIndex: PropType<number>;
|
|
333
|
+
onMousedown: PropType<(event: any) => void>;
|
|
334
|
+
}>> & Readonly<{
|
|
335
|
+
onClick?: (event: ChipMouseEvent) => any;
|
|
336
|
+
onBlur?: (event: ChipFocusEvent) => any;
|
|
337
|
+
onFocus?: (event: ChipFocusEvent) => any;
|
|
338
|
+
onKeydown?: (event: ChipKeyboardEvent) => any;
|
|
339
|
+
onRemove?: (event: ChipRemoveEvent) => any;
|
|
340
|
+
}>, {
|
|
341
|
+
role: string;
|
|
342
|
+
disabled: boolean;
|
|
343
|
+
dir: string;
|
|
344
|
+
avatar: string | Object | Function;
|
|
345
|
+
removable: boolean;
|
|
346
|
+
removeIcon: string;
|
|
347
|
+
removeSvgIcon: SVGIcon;
|
|
348
|
+
selectedIcon: string;
|
|
349
|
+
selectedSvgIcon: SVGIcon;
|
|
350
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
351
|
+
export { Chip };
|
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
import { FormComponentProps } from '@progress/kendo-vue-common';
|
|
9
|
+
import { ChipProps } from './Chip';
|
|
10
|
+
import { ChipListChangeEvent, ChipListDataChangeEvent } from '../models/events';
|
|
11
|
+
/**
|
|
12
|
+
* Represents the properties of [ChipList]({% slug overview_chiplist %}) component.
|
|
13
|
+
*/
|
|
14
|
+
export interface ChipListProps extends FormComponentProps, ChipProps {
|
|
15
|
+
/**
|
|
16
|
+
* Sets the `id` property of the top div element of the ChipList.
|
|
17
|
+
*/
|
|
18
|
+
id?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Sets additional classes to the ChipList.
|
|
21
|
+
*/
|
|
22
|
+
className?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Sets the `tabIndex` attribute.
|
|
25
|
+
*/
|
|
26
|
+
tabIndex?: number;
|
|
27
|
+
/**
|
|
28
|
+
* Represents Chip component.
|
|
29
|
+
*/
|
|
30
|
+
chip?: any;
|
|
31
|
+
/**
|
|
32
|
+
* Represents the data about the child Chips.
|
|
33
|
+
*/
|
|
34
|
+
dataItems?: any;
|
|
35
|
+
/**
|
|
36
|
+
* Represents the default data about the child Chips.
|
|
37
|
+
*/
|
|
38
|
+
defaultDataItems?: any[];
|
|
39
|
+
/**
|
|
40
|
+
* Triggered after Chip data change.
|
|
41
|
+
*/
|
|
42
|
+
onDatachange?: (event: ChipListDataChangeEvent) => void;
|
|
43
|
+
/**
|
|
44
|
+
* Represents the selection state of Chip component.
|
|
45
|
+
*/
|
|
46
|
+
value?: any | any[];
|
|
47
|
+
/**
|
|
48
|
+
* Represents the default value of the selection state of Chip component.
|
|
49
|
+
*/
|
|
50
|
+
defaultValue?: any | any[];
|
|
51
|
+
/**
|
|
52
|
+
* Triggered after value change.
|
|
53
|
+
*/
|
|
54
|
+
onChange?: (event: ChipListChangeEvent) => void;
|
|
55
|
+
/**
|
|
56
|
+
* Configures the `size` of the Chip.
|
|
57
|
+
*
|
|
58
|
+
* The available options are:
|
|
59
|
+
* - small
|
|
60
|
+
* - medium
|
|
61
|
+
* - large
|
|
62
|
+
*
|
|
63
|
+
* @default `undefined`
|
|
64
|
+
*/
|
|
65
|
+
size?: 'small' | 'medium' | 'large';
|
|
66
|
+
/**
|
|
67
|
+
* Configures the `roundness` of the Chip.
|
|
68
|
+
*
|
|
69
|
+
* The available options are:
|
|
70
|
+
* - none
|
|
71
|
+
* - small
|
|
72
|
+
* - medium
|
|
73
|
+
* - large
|
|
74
|
+
* - full
|
|
75
|
+
*
|
|
76
|
+
* @default `undefined`
|
|
77
|
+
*/
|
|
78
|
+
rounded?: 'none' | 'small' | 'medium' | 'large' | 'full';
|
|
79
|
+
/**
|
|
80
|
+
* Configures the `fillMode` of the Chip.
|
|
81
|
+
*
|
|
82
|
+
* The available options are:
|
|
83
|
+
* - solid
|
|
84
|
+
* - outline
|
|
85
|
+
* - flat
|
|
86
|
+
*
|
|
87
|
+
* @default `undefined`
|
|
88
|
+
*/
|
|
89
|
+
fillMode?: 'solid' | 'outline' | 'flat';
|
|
90
|
+
/**
|
|
91
|
+
* Represents the selection state of Chip component.
|
|
92
|
+
*/
|
|
93
|
+
selection?: string;
|
|
94
|
+
/**
|
|
95
|
+
* Represents the `text` field of Chip, defaults to 'text'.
|
|
96
|
+
*/
|
|
97
|
+
textField?: string;
|
|
98
|
+
/**
|
|
99
|
+
* Represents the `value` field of the Chip, defaults to 'value'.
|
|
100
|
+
*/
|
|
101
|
+
valueField?: string;
|
|
102
|
+
/**
|
|
103
|
+
* Represents the 'avatar' field in the Chip, defaults to 'avatar'.
|
|
104
|
+
*/
|
|
105
|
+
avatarField?: object;
|
|
106
|
+
/**
|
|
107
|
+
* Determines of ChipList is disabled.
|
|
108
|
+
*/
|
|
109
|
+
disabled?: boolean;
|
|
110
|
+
/**
|
|
111
|
+
* The ChipList direction 'ltr' as default or 'rtl'.
|
|
112
|
+
*/
|
|
113
|
+
dir?: string;
|
|
114
|
+
/**
|
|
115
|
+
* Identifies the element(s) which will describe the component, similar to HTML aria-describedby attribute.
|
|
116
|
+
* For example these elements could contain error or hint message.
|
|
117
|
+
*/
|
|
118
|
+
ariaDescribedBy?: string;
|
|
119
|
+
/**
|
|
120
|
+
* Identifies the element(s) which will label the component.
|
|
121
|
+
*/
|
|
122
|
+
ariaLabelledBy?: string;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Represents the target(element and props) of the ChipListChangeEvent.
|
|
126
|
+
*/
|
|
127
|
+
export interface ChipListHandle {
|
|
128
|
+
/**
|
|
129
|
+
* The current element or `null` if there is no one.
|
|
130
|
+
*/
|
|
131
|
+
element: HTMLDivElement | null;
|
|
132
|
+
/**
|
|
133
|
+
* The props values of the ChipList.
|
|
134
|
+
*/
|
|
135
|
+
props: ChipListProps;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* @hidden
|
|
139
|
+
*/
|
|
140
|
+
declare const ChipList: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
141
|
+
id: StringConstructor;
|
|
142
|
+
tabIndex: NumberConstructor;
|
|
143
|
+
dataItems: ArrayConstructor;
|
|
144
|
+
defaultDataItems: {
|
|
145
|
+
type: ArrayConstructor;
|
|
146
|
+
default: () => any[];
|
|
147
|
+
};
|
|
148
|
+
value: (ArrayConstructor | ObjectConstructor | StringConstructor | NumberConstructor)[];
|
|
149
|
+
defaultValue: {
|
|
150
|
+
type: (ArrayConstructor | ObjectConstructor | StringConstructor | NumberConstructor)[];
|
|
151
|
+
default: () => any;
|
|
152
|
+
};
|
|
153
|
+
size: StringConstructor;
|
|
154
|
+
rounded: StringConstructor;
|
|
155
|
+
fillMode: {
|
|
156
|
+
type: StringConstructor;
|
|
157
|
+
validator: (value: string) => boolean;
|
|
158
|
+
};
|
|
159
|
+
selection: {
|
|
160
|
+
type: StringConstructor;
|
|
161
|
+
default: () => "none";
|
|
162
|
+
};
|
|
163
|
+
textField: {
|
|
164
|
+
type: StringConstructor;
|
|
165
|
+
default: () => "text";
|
|
166
|
+
};
|
|
167
|
+
valueField: {
|
|
168
|
+
type: StringConstructor;
|
|
169
|
+
default: () => "value";
|
|
170
|
+
};
|
|
171
|
+
avatarField: {
|
|
172
|
+
type: StringConstructor;
|
|
173
|
+
default: () => "avatar";
|
|
174
|
+
};
|
|
175
|
+
disabled: {
|
|
176
|
+
type: BooleanConstructor;
|
|
177
|
+
default: boolean;
|
|
178
|
+
};
|
|
179
|
+
dir: {
|
|
180
|
+
type: StringConstructor;
|
|
181
|
+
default: () => "ltr";
|
|
182
|
+
};
|
|
183
|
+
chip: (ObjectConstructor | StringConstructor | FunctionConstructor)[];
|
|
184
|
+
ariaLabelledBy: StringConstructor;
|
|
185
|
+
ariaDescribedBy: StringConstructor;
|
|
186
|
+
}>, {
|
|
187
|
+
chipListRef: import('vue').Ref<any, any>;
|
|
188
|
+
}, {
|
|
189
|
+
currentDataItems: any[];
|
|
190
|
+
currentDir: string;
|
|
191
|
+
isRtl: boolean;
|
|
192
|
+
currentFocused: {
|
|
193
|
+
value: boolean;
|
|
194
|
+
};
|
|
195
|
+
currentValue: {
|
|
196
|
+
value: any;
|
|
197
|
+
};
|
|
198
|
+
}, {
|
|
199
|
+
computedDataItems(): any;
|
|
200
|
+
computedValue(): any;
|
|
201
|
+
items(): any;
|
|
202
|
+
}, {
|
|
203
|
+
handleDispatchSelection(action: any): void;
|
|
204
|
+
handleDispatchFocus(action: any): void;
|
|
205
|
+
handleDispatchDataItems(action: any): void;
|
|
206
|
+
handleChange(newValue: any, event: any): void;
|
|
207
|
+
handleDataChange(newData: any, event: any): void;
|
|
208
|
+
itemsReducer(acc: any, current: any): any;
|
|
209
|
+
}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
210
|
+
change: (event: ChipListChangeEvent) => true;
|
|
211
|
+
datachange: (event: ChipListDataChangeEvent) => true;
|
|
212
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
213
|
+
id: StringConstructor;
|
|
214
|
+
tabIndex: NumberConstructor;
|
|
215
|
+
dataItems: ArrayConstructor;
|
|
216
|
+
defaultDataItems: {
|
|
217
|
+
type: ArrayConstructor;
|
|
218
|
+
default: () => any[];
|
|
219
|
+
};
|
|
220
|
+
value: (ArrayConstructor | ObjectConstructor | StringConstructor | NumberConstructor)[];
|
|
221
|
+
defaultValue: {
|
|
222
|
+
type: (ArrayConstructor | ObjectConstructor | StringConstructor | NumberConstructor)[];
|
|
223
|
+
default: () => any;
|
|
224
|
+
};
|
|
225
|
+
size: StringConstructor;
|
|
226
|
+
rounded: StringConstructor;
|
|
227
|
+
fillMode: {
|
|
228
|
+
type: StringConstructor;
|
|
229
|
+
validator: (value: string) => boolean;
|
|
230
|
+
};
|
|
231
|
+
selection: {
|
|
232
|
+
type: StringConstructor;
|
|
233
|
+
default: () => "none";
|
|
234
|
+
};
|
|
235
|
+
textField: {
|
|
236
|
+
type: StringConstructor;
|
|
237
|
+
default: () => "text";
|
|
238
|
+
};
|
|
239
|
+
valueField: {
|
|
240
|
+
type: StringConstructor;
|
|
241
|
+
default: () => "value";
|
|
242
|
+
};
|
|
243
|
+
avatarField: {
|
|
244
|
+
type: StringConstructor;
|
|
245
|
+
default: () => "avatar";
|
|
246
|
+
};
|
|
247
|
+
disabled: {
|
|
248
|
+
type: BooleanConstructor;
|
|
249
|
+
default: boolean;
|
|
250
|
+
};
|
|
251
|
+
dir: {
|
|
252
|
+
type: StringConstructor;
|
|
253
|
+
default: () => "ltr";
|
|
254
|
+
};
|
|
255
|
+
chip: (ObjectConstructor | StringConstructor | FunctionConstructor)[];
|
|
256
|
+
ariaLabelledBy: StringConstructor;
|
|
257
|
+
ariaDescribedBy: StringConstructor;
|
|
258
|
+
}>> & Readonly<{
|
|
259
|
+
onChange?: (event: ChipListChangeEvent) => any;
|
|
260
|
+
onDatachange?: (event: ChipListDataChangeEvent) => any;
|
|
261
|
+
}>, {
|
|
262
|
+
disabled: boolean;
|
|
263
|
+
dir: string;
|
|
264
|
+
defaultDataItems: unknown[];
|
|
265
|
+
defaultValue: string | number | Record<string, any> | unknown[];
|
|
266
|
+
selection: string;
|
|
267
|
+
textField: string;
|
|
268
|
+
valueField: string;
|
|
269
|
+
avatarField: string;
|
|
270
|
+
}, {}, {}, {}, string, () => {
|
|
271
|
+
kendoSelection: any;
|
|
272
|
+
kendoFocused: any;
|
|
273
|
+
kendoDataItems: any;
|
|
274
|
+
handleDispatchDataItems: any;
|
|
275
|
+
handleDispatchSelection: any;
|
|
276
|
+
handleDispatchFocus: any;
|
|
277
|
+
}, true, {}, any>;
|
|
278
|
+
export { ChipList };
|
package/Chip/ChipList.mjs
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
import { defineComponent as r, createVNode as i, h as l, ref as n } from "vue";
|
|
9
|
-
import { classNames as u,
|
|
9
|
+
import { classNames as u, kendoThemeMaps as p, getTabIndex as d, setRef as o, templateRendering as h, getListeners as c, getTemplate as m, validatePackage as f } from "@progress/kendo-vue-common";
|
|
10
10
|
import { selectionReducer as $ } from "./selection-reducer.mjs";
|
|
11
11
|
import { focusReducer as v } from "./focus-reducer.mjs";
|
|
12
12
|
import { dataReducer as g } from "./data-reducer.mjs";
|
|
@@ -174,14 +174,14 @@ const V = /* @__PURE__ */ r({
|
|
|
174
174
|
size: e
|
|
175
175
|
} = this.$props;
|
|
176
176
|
return i("div", {
|
|
177
|
-
ref:
|
|
177
|
+
ref: o(this, "chipList"),
|
|
178
178
|
role: "listbox",
|
|
179
179
|
id: this.$props.id,
|
|
180
180
|
dir: this.currentDir,
|
|
181
181
|
style: this.$attrs.style,
|
|
182
|
-
tabindex:
|
|
182
|
+
tabindex: d(this.$props.tabIndex, this.$props.disabled, void 0),
|
|
183
183
|
class: u("k-chip-list", {
|
|
184
|
-
[`k-chip-list-${
|
|
184
|
+
[`k-chip-list-${p.sizeMap[e] || e}`]: e,
|
|
185
185
|
"k-rtl": this.currentDir === "rtl",
|
|
186
186
|
"k-selection-single": this.$props.selection === "single",
|
|
187
187
|
"k-selection-multiple": this.$props.selection === "multiple",
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* @hidden
|
|
10
|
+
*/
|
|
11
|
+
export declare enum DATA_ACTION {
|
|
12
|
+
remove = "remove",
|
|
13
|
+
add = "add",
|
|
14
|
+
reorder = "reorder"
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* @hidden
|
|
18
|
+
*/
|
|
19
|
+
export type DataAction = {
|
|
20
|
+
type: DATA_ACTION;
|
|
21
|
+
payload?: any;
|
|
22
|
+
valueField: string;
|
|
23
|
+
event?: any;
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* @hidden
|
|
27
|
+
*/
|
|
28
|
+
export declare const dataReducer: (state: any, action: DataAction) => any;
|
package/Chip/data-reducer.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});let r=function(e){return e.remove="remove",e.add="add",e.reorder="reorder",e}({});const t=(e,d)=>{switch(d.type){case r.add:break;case r.remove:return e.filter(a=>a[d.valueField]!==d.payload);case r.reorder:break;default:return e}};exports.DATA_ACTION=r;exports.dataReducer=t;
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});let r=(function(e){return e.remove="remove",e.add="add",e.reorder="reorder",e})({});const t=(e,d)=>{switch(d.type){case r.add:break;case r.remove:return e.filter(a=>a[d.valueField]!==d.payload);case r.reorder:break;default:return e}};exports.DATA_ACTION=r;exports.dataReducer=t;
|
package/Chip/data-reducer.mjs
CHANGED
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
let d = /* @__PURE__ */ function(e) {
|
|
8
|
+
let d = /* @__PURE__ */ (function(e) {
|
|
9
9
|
return e.remove = "remove", e.add = "add", e.reorder = "reorder", e;
|
|
10
|
-
}({});
|
|
10
|
+
})({});
|
|
11
11
|
const o = (e, r) => {
|
|
12
12
|
switch (r.type) {
|
|
13
13
|
case d.add:
|