@syncfusion/ej2-splitbuttons 29.2.4 → 30.1.37

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.
Files changed (100) hide show
  1. package/dist/ej2-splitbuttons.min.js +2 -2
  2. package/dist/ej2-splitbuttons.umd.min.js +1 -1
  3. package/dist/global/ej2-splitbuttons.min.js +1 -1
  4. package/dist/global/index.d.ts +1 -1
  5. package/dist/ts/button-group/button-group.d.ts +38 -0
  6. package/dist/ts/button-group/button-group.ts +84 -0
  7. package/dist/ts/button-group/index.d.ts +4 -0
  8. package/dist/ts/button-group/index.ts +4 -0
  9. package/dist/ts/common/common-model.d.ts +51 -0
  10. package/dist/ts/common/common.d.ts +95 -0
  11. package/dist/ts/common/common.ts +218 -0
  12. package/dist/ts/common/index.d.ts +5 -0
  13. package/dist/ts/common/index.ts +5 -0
  14. package/dist/ts/drop-down-button/drop-down-button-model.d.ts +195 -0
  15. package/dist/ts/drop-down-button/drop-down-button.d.ts +308 -0
  16. package/dist/ts/drop-down-button/drop-down-button.ts +1110 -0
  17. package/dist/ts/drop-down-button/index.d.ts +5 -0
  18. package/dist/ts/drop-down-button/index.ts +5 -0
  19. package/dist/ts/index.d.ts +8 -0
  20. package/dist/ts/index.ts +8 -0
  21. package/dist/ts/progress-button/index.d.ts +5 -0
  22. package/dist/ts/progress-button/index.ts +5 -0
  23. package/dist/ts/progress-button/progress-button-model.d.ts +206 -0
  24. package/dist/ts/progress-button/progress-button.d.ts +323 -0
  25. package/dist/ts/progress-button/progress-button.ts +689 -0
  26. package/dist/ts/split-button/index.d.ts +5 -0
  27. package/dist/ts/split-button/index.ts +5 -0
  28. package/dist/ts/split-button/split-button-model.d.ts +133 -0
  29. package/dist/ts/split-button/split-button.d.ts +236 -0
  30. package/dist/ts/split-button/split-button.ts +535 -0
  31. package/package.json +9 -9
  32. package/styles/bds-lite.css +1 -7
  33. package/styles/bds.css +2 -7
  34. package/styles/bootstrap-dark-lite.css +0 -1
  35. package/styles/bootstrap-dark.css +0 -1
  36. package/styles/bootstrap-lite.css +0 -1
  37. package/styles/bootstrap.css +0 -1
  38. package/styles/bootstrap4-lite.css +0 -1
  39. package/styles/bootstrap4.css +3 -1
  40. package/styles/bootstrap5-dark-lite.css +2 -4
  41. package/styles/bootstrap5-dark.css +2 -4
  42. package/styles/bootstrap5-lite.css +2 -4
  43. package/styles/bootstrap5.3-lite.css +0 -2
  44. package/styles/bootstrap5.3.css +0 -2
  45. package/styles/bootstrap5.css +2 -4
  46. package/styles/drop-down-button/_layout.scss +0 -1
  47. package/styles/drop-down-button/material3-dark.css +0 -1
  48. package/styles/drop-down-button/material3.css +0 -1
  49. package/styles/fabric-dark-lite.css +0 -1
  50. package/styles/fabric-dark.css +0 -1
  51. package/styles/fabric-lite.css +0 -1
  52. package/styles/fabric.css +0 -1
  53. package/styles/fluent-dark-lite.css +0 -1
  54. package/styles/fluent-dark.css +1 -1
  55. package/styles/fluent-lite.css +0 -1
  56. package/styles/fluent.css +1 -1
  57. package/styles/fluent2-lite.css +1 -3
  58. package/styles/fluent2.css +1 -3
  59. package/styles/highcontrast-light-lite.css +0 -1
  60. package/styles/highcontrast-light.css +0 -1
  61. package/styles/highcontrast-lite.css +0 -1
  62. package/styles/highcontrast.css +0 -1
  63. package/styles/material-dark-lite.css +0 -1
  64. package/styles/material-dark.css +0 -1
  65. package/styles/material-lite.css +0 -1
  66. package/styles/material.css +0 -1
  67. package/styles/material3-dark-lite.css +3 -6
  68. package/styles/material3-dark.css +5 -8
  69. package/styles/material3-lite.css +3 -6
  70. package/styles/material3.css +5 -8
  71. package/styles/split-button/_bigger.scss +7 -1
  72. package/styles/split-button/_layout.scss +7 -13
  73. package/styles/split-button/_theme.scss +2 -8
  74. package/styles/split-button/bds.css +2 -7
  75. package/styles/split-button/bootstrap-dark.css +0 -1
  76. package/styles/split-button/bootstrap.css +0 -1
  77. package/styles/split-button/bootstrap4.css +3 -1
  78. package/styles/split-button/bootstrap5-dark.css +2 -4
  79. package/styles/split-button/bootstrap5.3.css +0 -2
  80. package/styles/split-button/bootstrap5.css +2 -4
  81. package/styles/split-button/fabric-dark.css +0 -1
  82. package/styles/split-button/fabric.css +0 -1
  83. package/styles/split-button/fluent-dark.css +1 -1
  84. package/styles/split-button/fluent.css +1 -1
  85. package/styles/split-button/fluent2.css +1 -3
  86. package/styles/split-button/highcontrast-light.css +0 -1
  87. package/styles/split-button/highcontrast.css +0 -1
  88. package/styles/split-button/material-dark.css +0 -1
  89. package/styles/split-button/material.css +0 -1
  90. package/styles/split-button/material3-dark.css +5 -7
  91. package/styles/split-button/material3.css +5 -7
  92. package/styles/split-button/tailwind-dark.css +2 -7
  93. package/styles/split-button/tailwind.css +2 -7
  94. package/styles/split-button/tailwind3.css +1 -3
  95. package/styles/tailwind-dark-lite.css +1 -7
  96. package/styles/tailwind-dark.css +2 -7
  97. package/styles/tailwind-lite.css +1 -7
  98. package/styles/tailwind.css +2 -7
  99. package/styles/tailwind3-lite.css +1 -3
  100. package/styles/tailwind3.css +1 -3
@@ -0,0 +1,308 @@
1
+ import { EmitType } from '@syncfusion/ej2-base';
2
+ import { INotifyPropertyChanged, ChildProperty } from '@syncfusion/ej2-base';
3
+ import { Component, KeyboardEventArgs } from '@syncfusion/ej2-base';
4
+ import { Button } from '@syncfusion/ej2-buttons';
5
+ import { Popup } from '@syncfusion/ej2-popups';
6
+ import { MenuEventArgs, BeforeOpenCloseMenuEventArgs, OpenCloseMenuEventArgs, DropDownAnimationEffect } from './../common/common';
7
+ import { SplitButtonIconPosition } from './../common/common';
8
+ import { ItemModel } from './../common/common-model';
9
+ import { DropDownButtonModel, DropDownMenuAnimationSettingsModel } from './drop-down-button-model';
10
+ /**
11
+ * Animation configuration settings.
12
+ */
13
+ export declare class DropDownMenuAnimationSettings extends ChildProperty<DropDownMenuAnimationSettings> {
14
+ /**
15
+ * Specifies the animation effect applied when the DropDownMenu is shown.
16
+ * The possible effects are:
17
+ * * None: Specifies that the DropDownMenu appears without any animation effect.
18
+ * * SlideDown: Specifies that the DropDownMenu appears with a slide down effect.
19
+ * * ZoomIn: Specifies that the DropDownMenu appears with a zoom in effect.
20
+ * * FadeIn: Specifies that the DropDownMenu appears with a fade in effect.
21
+ *
22
+ * @default 'SlideDown'
23
+ * @isEnumeration true
24
+ */
25
+ effect: DropDownAnimationEffect;
26
+ /**
27
+ * Specifies the time duration (in milliseconds) of the animation effect when the DropDownMenu is displayed.
28
+ *
29
+ * @default 400
30
+ */
31
+ duration: number;
32
+ /**
33
+ * Specifies the easing function applied during the animation effect of the DropDownMenu.
34
+ *
35
+ * @default 'ease'
36
+ */
37
+ easing: string;
38
+ }
39
+ /**
40
+ * DropDownButton component is used to toggle contextual overlays for displaying list of action items.
41
+ * It can contain both text and images.
42
+ * ```html
43
+ * <button id="element">DropDownButton</button>
44
+ * ```
45
+ * ```typescript
46
+ * <script>
47
+ * var dropDownButtonObj = new DropDownButton({items: [{ text: 'Action1' }, { text: 'Action2' },{ text: 'Action3' }]);
48
+ * dropDownButtonObj.appendTo("#element");
49
+ * </script>
50
+ * ```
51
+ */
52
+ export declare class DropDownButton extends Component<HTMLButtonElement> implements INotifyPropertyChanged {
53
+ /** @hidden */
54
+ dropDown: Popup;
55
+ protected button: Button;
56
+ /** @hidden */
57
+ activeElem: HTMLElement[];
58
+ private rippleFn;
59
+ private delegateMousedownHandler;
60
+ private isPopupCreated;
61
+ private popupContent;
62
+ /**
63
+ * Defines the content of the DropDownButton element that can either be a text or HTML elements.
64
+ *
65
+ * @default ""
66
+ */
67
+ content: string;
68
+ /**
69
+ * Defines class/multiple classes separated by a space in the DropDownButton element. The
70
+ * DropDownButton size and styles can be customized by using this.
71
+ *
72
+ * @default ""
73
+ */
74
+ cssClass: string;
75
+ /**
76
+ * Specifies a value that indicates whether the DropDownButton is `disabled` or not.
77
+ *
78
+ * @default false.
79
+ */
80
+ disabled: boolean;
81
+ /**
82
+ * Defines class/multiple classes separated by a space for the DropDownButton that is used to
83
+ * include an icon. DropDownButton can also include font icon and sprite image.
84
+ *
85
+ * @default ""
86
+ */
87
+ iconCss: string;
88
+ /**
89
+ * Positions the icon before/top of the text content in the DropDownButton. The possible values are:
90
+ * * Left: The icon will be positioned to the left of the text content.
91
+ * * Top: The icon will be positioned to the top of the text content.
92
+ *
93
+ * @default "Left"
94
+ */
95
+ iconPosition: SplitButtonIconPosition;
96
+ /**
97
+ * Specifies whether to enable the rendering of untrusted HTML values in the DropDownButton component.
98
+ * If 'enableHtmlSanitizer' set to true, the component will sanitize any suspected untrusted strings and scripts before rendering them.
99
+ *
100
+ * @default true
101
+ */
102
+ enableHtmlSanitizer: boolean;
103
+ /**
104
+ * Specifies action items with its properties which will be rendered as DropDownButton popup.
105
+ *
106
+ * @default []
107
+ */
108
+ items: ItemModel[];
109
+ /**
110
+ * Specifies the popup element creation on open.
111
+ *
112
+ * @default false
113
+ */
114
+ createPopupOnClick: boolean;
115
+ /**
116
+ * Allows to specify the DropDownButton popup item element.
117
+ *
118
+ * @default ""
119
+ */
120
+ target: string | Element;
121
+ /**
122
+ * Specifies the event to close the DropDownButton popup.
123
+ *
124
+ * @default ""
125
+ */
126
+ closeActionEvents: string;
127
+ /**
128
+ * Specifies the template content to be displayed.
129
+ *
130
+ * @default null
131
+ * @aspType string
132
+ */
133
+ itemTemplate: string | Function;
134
+ /**
135
+ * This property defines the width of the dropdown popup for the DropDownButton component.
136
+ *
137
+ * @property {string | number} popupWidth - A string or number representing the width of the dropdown.
138
+ * It can be a valid CSS unit such as `px`, `%`, or `rem`, or a number interpreted as pixels.
139
+ * @default "auto"
140
+ * @remarks
141
+ * The `popupWidth` property allows developers to control the width of the dropdown popup, ensuring it fits their design requirements.
142
+ * The default value of `auto` allows the popup to adjust based on the content length, but a specific width can be provided for more precise control.
143
+ */
144
+ popupWidth: string | number;
145
+ /**
146
+ * Specifies the animation settings for opening the sub menu in the DropDownMenu.
147
+ * The settings control the duration, easing, and effect of the animation applied when the sub menu opens.
148
+ *
149
+ * @default { effect: 'None' }
150
+ */
151
+ animationSettings: DropDownMenuAnimationSettingsModel;
152
+ /**
153
+ * Triggers while rendering each Popup item of DropDownButton.
154
+ *
155
+ * @event beforeItemRender
156
+ */
157
+ beforeItemRender: EmitType<MenuEventArgs>;
158
+ /**
159
+ * Triggers before opening the DropDownButton popup.
160
+ *
161
+ * @event beforeOpen
162
+ */
163
+ beforeOpen: EmitType<BeforeOpenCloseMenuEventArgs>;
164
+ /**
165
+ * Triggers before closing the DropDownButton popup.
166
+ *
167
+ * @event beforeClose
168
+ */
169
+ beforeClose: EmitType<BeforeOpenCloseMenuEventArgs>;
170
+ /**
171
+ * Triggers while closing the DropDownButton popup.
172
+ *
173
+ * @event close
174
+ */
175
+ close: EmitType<OpenCloseMenuEventArgs>;
176
+ /**
177
+ * Triggers while opening the DropDownButton popup.
178
+ *
179
+ * @event open
180
+ */
181
+ open: EmitType<OpenCloseMenuEventArgs>;
182
+ /**
183
+ * Triggers while selecting action item in DropDownButton popup.
184
+ *
185
+ * @event select
186
+ */
187
+ select: EmitType<MenuEventArgs>;
188
+ /**
189
+ * Triggers once the component rendering is completed.
190
+ *
191
+ * @event created
192
+ */
193
+ created: EmitType<Event>;
194
+ /**
195
+ * Constructor for creating the widget
196
+ *
197
+ * @param {DropDownButtonModel} options - Specifies dropdown button model
198
+ * @param {string|HTMLButtonElement} element - Specifies element
199
+ * @hidden
200
+ */
201
+ constructor(options?: DropDownButtonModel, element?: string | HTMLButtonElement);
202
+ protected preRender(): void;
203
+ /**
204
+ * Get the properties to be maintained in the persisted state.
205
+ *
206
+ * @returns {string} - Persist data
207
+ */
208
+ getPersistData(): string;
209
+ /**
210
+ * To open/close DropDownButton popup based on current state of the DropDownButton.
211
+ *
212
+ * @returns {void}
213
+ */
214
+ toggle(): void;
215
+ /**
216
+ * Initialize the Component rendering
217
+ *
218
+ * @returns {void}
219
+ * @private
220
+ */
221
+ render(): void;
222
+ /**
223
+ * Adds a new item to the menu. By default, new item appends to the list as the last item,
224
+ * but you can insert based on the text parameter.
225
+ *
226
+ * @param { ItemModel[] } items - Specifies an array of JSON data.
227
+ * @param { string } text - Specifies the text to insert the newly added item in the menu.
228
+ * @returns {void}.
229
+ */
230
+ addItems(items: ItemModel[], text?: string): void;
231
+ /**
232
+ * Removes the items from the menu.
233
+ *
234
+ * @param { string[] } items - Specifies an array of string to remove the items.
235
+ * @param { string } isUniqueId - Set `true` if specified items is a collection of unique id.
236
+ * @returns {void}.
237
+ */
238
+ removeItems(items: string[], isUniqueId?: boolean): void;
239
+ private createPopup;
240
+ private getTargetElement;
241
+ private createItems;
242
+ private compiletemplate;
243
+ private hasIcon;
244
+ private createAnchor;
245
+ private initialize;
246
+ private isColorPicker;
247
+ private appendArrowSpan;
248
+ protected setActiveElem(elem: HTMLElement[]): void;
249
+ /**
250
+ * Get component name.
251
+ *
252
+ * @returns {string} - Module Name
253
+ * @private
254
+ */
255
+ getModuleName(): string;
256
+ private canOpen;
257
+ /**
258
+ * Destroys the widget.
259
+ *
260
+ * @returns {void}
261
+ */
262
+ destroy(): void;
263
+ protected destroyPopup(): void;
264
+ protected getPopUpElement(): HTMLElement;
265
+ protected getULElement(): HTMLElement;
266
+ protected wireEvents(): void;
267
+ protected windowResize(): void;
268
+ protected popupWireEvents(): void;
269
+ protected popupUnWireEvents(): void;
270
+ /**
271
+ * Handles the keyboard interactions.
272
+ *
273
+ * @param {KeyboardEventArgs} e - Specifies keyboard event args.
274
+ * @returns {void}
275
+ * @hidden
276
+ */
277
+ keyBoardHandler(e: KeyboardEventArgs): void;
278
+ private isSafari;
279
+ protected upDownKeyHandler(e: KeyboardEventArgs): void;
280
+ private keyEventHandler;
281
+ private getLI;
282
+ private mousedownHandler;
283
+ private focusoutHandler;
284
+ protected clickHandler(e: MouseEvent | KeyboardEventArgs): void;
285
+ private triggerSelect;
286
+ private openPopUp;
287
+ private animatePopup;
288
+ private setWidth;
289
+ private closePopup;
290
+ protected unWireEvents(): void;
291
+ /**
292
+ * Called internally if any of the property value changed.
293
+ *
294
+ * @param {DropDownButtonModel} newProp - Specifies new properties
295
+ * @param {DropDownButtonModel} oldProp - Specifies old properties
296
+ * @returns {void}
297
+ * @private
298
+ */
299
+ onPropertyChanged(newProp: DropDownButtonModel, oldProp: DropDownButtonModel): void;
300
+ /**
301
+ * Sets the focus to DropDownButton
302
+ * its native method
303
+ *
304
+ * @public
305
+ * @returns {void}
306
+ */
307
+ focusIn(): void;
308
+ }