fomantic-ui 2.9.3-beta.43 → 2.9.3-beta.45
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/dist/components/accordion.css +1 -1
- package/dist/components/accordion.js +1 -1
- package/dist/components/accordion.min.css +1 -1
- package/dist/components/accordion.min.js +1 -1
- package/dist/components/ad.css +1 -1
- package/dist/components/ad.min.css +1 -1
- package/dist/components/api.js +1 -1
- package/dist/components/api.min.js +1 -1
- package/dist/components/breadcrumb.css +1 -1
- package/dist/components/breadcrumb.min.css +1 -1
- package/dist/components/button.css +1 -1
- package/dist/components/button.min.css +1 -1
- package/dist/components/calendar.css +1 -1
- package/dist/components/calendar.js +1 -1
- package/dist/components/calendar.min.css +1 -1
- package/dist/components/calendar.min.js +1 -1
- package/dist/components/card.css +1 -1
- package/dist/components/card.min.css +1 -1
- package/dist/components/checkbox.css +1 -1
- package/dist/components/checkbox.js +1 -1
- package/dist/components/checkbox.min.css +1 -1
- package/dist/components/checkbox.min.js +1 -1
- package/dist/components/comment.css +1 -1
- package/dist/components/comment.min.css +1 -1
- package/dist/components/container.css +1 -1
- package/dist/components/container.min.css +1 -1
- package/dist/components/dimmer.css +1 -1
- package/dist/components/dimmer.js +1 -1
- package/dist/components/dimmer.min.css +1 -1
- package/dist/components/dimmer.min.js +1 -1
- package/dist/components/divider.css +1 -1
- package/dist/components/divider.min.css +1 -1
- package/dist/components/dropdown.css +1 -1
- package/dist/components/dropdown.js +1 -1
- package/dist/components/dropdown.min.css +1 -1
- package/dist/components/dropdown.min.js +1 -1
- package/dist/components/embed.css +1 -1
- package/dist/components/embed.js +1 -1
- package/dist/components/embed.min.css +1 -1
- package/dist/components/embed.min.js +1 -1
- package/dist/components/emoji.css +1 -1
- package/dist/components/emoji.min.css +1 -1
- package/dist/components/feed.css +1 -1
- package/dist/components/feed.min.css +1 -1
- package/dist/components/flag.css +1 -1
- package/dist/components/flag.min.css +1 -1
- package/dist/components/flyout.css +1 -1
- package/dist/components/flyout.js +1 -1
- package/dist/components/flyout.min.css +1 -1
- package/dist/components/flyout.min.js +1 -1
- package/dist/components/form.css +1 -1
- package/dist/components/form.js +1 -1
- package/dist/components/form.min.css +1 -1
- package/dist/components/form.min.js +1 -1
- package/dist/components/grid.css +1 -1
- package/dist/components/grid.min.css +1 -1
- package/dist/components/header.css +1 -1
- package/dist/components/header.min.css +1 -1
- package/dist/components/icon.css +1 -1
- package/dist/components/icon.min.css +1 -1
- package/dist/components/image.css +1 -1
- package/dist/components/image.min.css +1 -1
- package/dist/components/input.css +1 -1
- package/dist/components/input.min.css +1 -1
- package/dist/components/item.css +1 -1
- package/dist/components/item.min.css +1 -1
- package/dist/components/label.css +1 -1
- package/dist/components/label.min.css +1 -1
- package/dist/components/list.css +1 -1
- package/dist/components/list.min.css +1 -1
- package/dist/components/loader.css +1 -1
- package/dist/components/loader.min.css +1 -1
- package/dist/components/menu.css +1 -1
- package/dist/components/menu.min.css +1 -1
- package/dist/components/message.css +1 -1
- package/dist/components/message.min.css +1 -1
- package/dist/components/modal.css +1 -1
- package/dist/components/modal.js +1 -1
- package/dist/components/modal.min.css +1 -1
- package/dist/components/modal.min.js +1 -1
- package/dist/components/nag.css +1 -1
- package/dist/components/nag.js +1 -1
- package/dist/components/nag.min.css +1 -1
- package/dist/components/nag.min.js +1 -1
- package/dist/components/placeholder.css +1 -1
- package/dist/components/placeholder.min.css +1 -1
- package/dist/components/popup.css +1 -1
- package/dist/components/popup.js +1 -1
- package/dist/components/popup.min.css +1 -1
- package/dist/components/popup.min.js +1 -1
- package/dist/components/progress.css +1 -1
- package/dist/components/progress.js +1 -1
- package/dist/components/progress.min.css +1 -1
- package/dist/components/progress.min.js +1 -1
- package/dist/components/rail.css +1 -1
- package/dist/components/rail.min.css +1 -1
- package/dist/components/rating.css +1 -1
- package/dist/components/rating.js +1 -1
- package/dist/components/rating.min.css +1 -1
- package/dist/components/rating.min.js +1 -1
- package/dist/components/reset.css +1 -1
- package/dist/components/reset.min.css +1 -1
- package/dist/components/reveal.css +1 -1
- package/dist/components/reveal.min.css +1 -1
- package/dist/components/search.css +1 -1
- package/dist/components/search.js +1 -1
- package/dist/components/search.min.css +1 -1
- package/dist/components/search.min.js +1 -1
- package/dist/components/segment.css +1 -1
- package/dist/components/segment.min.css +1 -1
- package/dist/components/shape.css +1 -1
- package/dist/components/shape.js +1 -1
- package/dist/components/shape.min.css +1 -1
- package/dist/components/shape.min.js +1 -1
- package/dist/components/sidebar.css +1 -1
- package/dist/components/sidebar.js +1 -1
- package/dist/components/sidebar.min.css +1 -1
- package/dist/components/sidebar.min.js +1 -1
- package/dist/components/site.css +1 -1
- package/dist/components/site.js +1 -1
- package/dist/components/site.min.css +1 -1
- package/dist/components/site.min.js +1 -1
- package/dist/components/slider.css +1 -1
- package/dist/components/slider.js +1 -1
- package/dist/components/slider.min.css +1 -1
- package/dist/components/slider.min.js +1 -1
- package/dist/components/state.js +1 -1
- package/dist/components/state.min.js +1 -1
- package/dist/components/statistic.css +1 -1
- package/dist/components/statistic.min.css +1 -1
- package/dist/components/step.css +1 -1
- package/dist/components/step.min.css +1 -1
- package/dist/components/sticky.css +1 -1
- package/dist/components/sticky.js +1 -1
- package/dist/components/sticky.min.css +1 -1
- package/dist/components/sticky.min.js +1 -1
- package/dist/components/tab.css +1 -1
- package/dist/components/tab.js +1 -1
- package/dist/components/tab.min.css +1 -1
- package/dist/components/tab.min.js +1 -1
- package/dist/components/table.css +1 -1
- package/dist/components/table.min.css +1 -1
- package/dist/components/text.css +1 -1
- package/dist/components/text.min.css +1 -1
- package/dist/components/toast.css +1 -1
- package/dist/components/toast.js +1 -1
- package/dist/components/toast.min.css +1 -1
- package/dist/components/toast.min.js +1 -1
- package/dist/components/transition.css +1 -1
- package/dist/components/transition.js +1 -1
- package/dist/components/transition.min.css +1 -1
- package/dist/components/transition.min.js +1 -1
- package/dist/components/visibility.js +1 -1
- package/dist/components/visibility.min.js +1 -1
- package/dist/semantic.css +53 -53
- package/dist/semantic.js +26 -26
- package/dist/semantic.min.css +1 -1
- package/dist/semantic.min.js +1 -1
- package/package.json +3 -2
- package/types/fomantic-ui-accordion.d.ts +250 -0
- package/types/fomantic-ui-api.d.ts +607 -0
- package/types/fomantic-ui-calendar.d.ts +820 -0
- package/types/fomantic-ui-checkbox.d.ts +378 -0
- package/types/fomantic-ui-dimmer.d.ts +485 -0
- package/types/fomantic-ui-dropdown.d.ts +1402 -0
- package/types/fomantic-ui-embed.d.ts +372 -0
- package/types/fomantic-ui-flyout.d.ts +558 -0
- package/types/fomantic-ui-form.d.ts +780 -0
- package/types/fomantic-ui-modal.d.ts +553 -0
- package/types/fomantic-ui-nag.d.ts +319 -0
- package/types/fomantic-ui-popup.d.ts +619 -0
- package/types/fomantic-ui-progress.d.ts +533 -0
- package/types/fomantic-ui-rating.d.ts +218 -0
- package/types/fomantic-ui-search.d.ts +590 -0
- package/types/fomantic-ui-shape.d.ts +316 -0
- package/types/fomantic-ui-sidebar.d.ts +478 -0
- package/types/fomantic-ui-slider.d.ts +379 -0
- package/types/fomantic-ui-sticky.d.ts +261 -0
- package/types/fomantic-ui-tab.d.ts +427 -0
- package/types/fomantic-ui-tests.ts +23 -0
- package/types/fomantic-ui-toast.d.ts +620 -0
- package/types/fomantic-ui-transition.d.ts +405 -0
- package/types/fomantic-ui-visibility.d.ts +422 -0
- package/types/index.d.ts +64 -0
- package/types/tsconfig.json +23 -0
- package/types/tslint.json +1 -0
@@ -0,0 +1,620 @@
|
|
1
|
+
declare namespace FomanticUI {
|
2
|
+
interface Toast {
|
3
|
+
settings: ToastSettings;
|
4
|
+
|
5
|
+
/**
|
6
|
+
* Pauses the display time decrease (and possible progress bar animation)
|
7
|
+
*/
|
8
|
+
(behavior: 'animate pause'): JQuery;
|
9
|
+
|
10
|
+
/**
|
11
|
+
* Continues decreasing display time (and possible progress bar animation)
|
12
|
+
*/
|
13
|
+
(behavior: 'animate continue'): JQuery;
|
14
|
+
|
15
|
+
/**
|
16
|
+
* Closes the toast
|
17
|
+
*/
|
18
|
+
(behavior: 'close'): JQuery;
|
19
|
+
|
20
|
+
/**
|
21
|
+
* Returns all toasts as an array of objects which are visible within the current toast-container
|
22
|
+
*/
|
23
|
+
(behavior: 'get toasts'): object[];
|
24
|
+
|
25
|
+
/**
|
26
|
+
* Returns the remaining time in milliseconds
|
27
|
+
*/
|
28
|
+
(behavior: 'get remainingTime'): number;
|
29
|
+
|
30
|
+
(behavior: 'refresh' | 'destroy'): JQuery;
|
31
|
+
<K extends keyof ToastSettings>(behavior: 'setting', name: K, value?: undefined): ToastSettings._Impl[K];
|
32
|
+
<K extends keyof ToastSettings>(behavior: 'setting', name: K, value: ToastSettings._Impl[K]): JQuery;
|
33
|
+
(behavior: 'setting', value: ToastSettings): JQuery;
|
34
|
+
(settings?: ToastSettings): JQuery;
|
35
|
+
}
|
36
|
+
|
37
|
+
/**
|
38
|
+
* @see {@link https://fomantic-ui.com/modules/toast.html#/settings}
|
39
|
+
*/
|
40
|
+
type ToastSettings = ToastSettings.Param;
|
41
|
+
|
42
|
+
namespace ToastSettings {
|
43
|
+
type Param = (
|
44
|
+
| Pick<_Impl, 'position'>
|
45
|
+
| Pick<_Impl, 'horizontal'>
|
46
|
+
| Pick<_Impl, 'class'>
|
47
|
+
| Pick<_Impl, 'classProgress'>
|
48
|
+
| Pick<_Impl, 'classActions'>
|
49
|
+
| Pick<_Impl, 'classImage'>
|
50
|
+
| Pick<_Impl, 'context'>
|
51
|
+
| Pick<_Impl, 'displayTime'>
|
52
|
+
| Pick<_Impl, 'minDisplayTime'>
|
53
|
+
| Pick<_Impl, 'wordsPerMinute'>
|
54
|
+
| Pick<_Impl, 'showImage'>
|
55
|
+
| Pick<_Impl, 'showIcon'>
|
56
|
+
| Pick<_Impl, 'closeIcon'>
|
57
|
+
| Pick<_Impl, 'closeOnClick'>
|
58
|
+
| Pick<_Impl, 'cloneModule'>
|
59
|
+
| Pick<_Impl, 'showProgress'>
|
60
|
+
| Pick<_Impl, 'progressUp'>
|
61
|
+
| Pick<_Impl, 'pauseOnHover'>
|
62
|
+
| Pick<_Impl, 'compact'>
|
63
|
+
| Pick<_Impl, 'opacity'>
|
64
|
+
| Pick<_Impl, 'newestOnTop'>
|
65
|
+
| Pick<_Impl, 'preserveHTML'>
|
66
|
+
| Pick<_Impl, 'transition'>
|
67
|
+
| Pick<_Impl, 'onShow'>
|
68
|
+
| Pick<_Impl, 'onVisible'>
|
69
|
+
| Pick<_Impl, 'onClick'>
|
70
|
+
| Pick<_Impl, 'onHide'>
|
71
|
+
| Pick<_Impl, 'onHidden'>
|
72
|
+
| Pick<_Impl, 'onRemove'>
|
73
|
+
| Pick<_Impl, 'onApprove'>
|
74
|
+
| Pick<_Impl, 'onDeny'>
|
75
|
+
| Pick<_Impl, 'title'>
|
76
|
+
| Pick<_Impl, 'message'>
|
77
|
+
| Pick<_Impl, 'actions'>
|
78
|
+
| Pick<_Impl, 'namespace'>
|
79
|
+
| Pick<_Impl, 'selector'>
|
80
|
+
| Pick<_Impl, 'className'>
|
81
|
+
| Pick<_Impl, 'icons'>
|
82
|
+
| Pick<_Impl, 'name'>
|
83
|
+
| Pick<_Impl, 'silent'>
|
84
|
+
| Pick<_Impl, 'debug'>
|
85
|
+
| Pick<_Impl, 'performance'>
|
86
|
+
| Pick<_Impl, 'verbose'>
|
87
|
+
| Pick<_Impl, 'error'>
|
88
|
+
) &
|
89
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
90
|
+
|
91
|
+
interface _Impl {
|
92
|
+
// region Toast Settings
|
93
|
+
|
94
|
+
/**
|
95
|
+
* Sets where the toast can be displayed. Can be 'top right', 'top center', 'top left', 'bottom right', 'bottom center' and 'bottom left'.
|
96
|
+
*
|
97
|
+
* @default 'top right'
|
98
|
+
*/
|
99
|
+
position: string;
|
100
|
+
|
101
|
+
/**
|
102
|
+
* If the toasts should stack horizontal instead of vertical.
|
103
|
+
*
|
104
|
+
* @default false
|
105
|
+
*/
|
106
|
+
horizontal: boolean;
|
107
|
+
|
108
|
+
/**
|
109
|
+
* Define the class of notification. Can be any existing color definition or 'info', 'success', 'warning' and 'error'.
|
110
|
+
* If ui message is used in className.toast option (see below), this option can hold any supported class of the message component.
|
111
|
+
*
|
112
|
+
* @default 'neutral'
|
113
|
+
*/
|
114
|
+
class: string;
|
115
|
+
|
116
|
+
/**
|
117
|
+
* Can hold a string to be added to the progress bar class, for example a separate color
|
118
|
+
*
|
119
|
+
* @default false
|
120
|
+
*/
|
121
|
+
classProgress: false | string;
|
122
|
+
|
123
|
+
/**
|
124
|
+
* Can hold a string to be added to the actions class to control its appearance.
|
125
|
+
* Usually a combination of 'basic', 'left', 'top', 'bottom', 'vertical' and 'attached'.
|
126
|
+
*
|
127
|
+
* @default false
|
128
|
+
*/
|
129
|
+
classActions: false | string;
|
130
|
+
|
131
|
+
/**
|
132
|
+
* Can hold a string to be added to the image class. 'mini', 'tiny', 'small' and 'avatar' are supported out of the box.
|
133
|
+
*
|
134
|
+
* @default 'mini'
|
135
|
+
*/
|
136
|
+
classImage: string;
|
137
|
+
|
138
|
+
/**
|
139
|
+
* Selector or jquery object specifying the area to attach the toast container to.
|
140
|
+
*
|
141
|
+
* @default 'body'
|
142
|
+
*/
|
143
|
+
context: string | JQuery;
|
144
|
+
|
145
|
+
/**
|
146
|
+
* Set the time (in ms) of the toast appearance. Set '0' to disable the automatic dismissal.
|
147
|
+
* Set 'auto' to calculate the time by the given amount of words within the toast.
|
148
|
+
*
|
149
|
+
* @default 3000
|
150
|
+
*/
|
151
|
+
displayTime: number | 'auto';
|
152
|
+
|
153
|
+
/**
|
154
|
+
* Minimum display time in case displayTime is set to 'auto'.
|
155
|
+
*
|
156
|
+
* @default 1000
|
157
|
+
*/
|
158
|
+
minDisplayTime: number;
|
159
|
+
|
160
|
+
/**
|
161
|
+
* Base to calculate display time in case displayTime is set to 'auto'.
|
162
|
+
*
|
163
|
+
* @default 120
|
164
|
+
*/
|
165
|
+
wordsPerMinute: number;
|
166
|
+
|
167
|
+
/**
|
168
|
+
* If an URL to an image is given, that image will be shown to the left of the toast.
|
169
|
+
*
|
170
|
+
* @default false
|
171
|
+
*/
|
172
|
+
showImage: false | string;
|
173
|
+
|
174
|
+
/**
|
175
|
+
* Define if the toast should display an icon which matches to a given class.
|
176
|
+
* If a string is given, this will be used as icon classname.
|
177
|
+
*
|
178
|
+
* @default true
|
179
|
+
*/
|
180
|
+
showIcon: boolean | string;
|
181
|
+
|
182
|
+
/**
|
183
|
+
* This will make the toast closable by the top right corner icon instead of clicking anywhere on the toast when set to 'true'.
|
184
|
+
* When set to 'left' the closeIcon is shown to the left instead of right.
|
185
|
+
*
|
186
|
+
* @default false
|
187
|
+
*/
|
188
|
+
closeIcon: boolean | 'left';
|
189
|
+
|
190
|
+
/**
|
191
|
+
* Set to 'false' to avoid closing the toast when it is clicked.
|
192
|
+
*
|
193
|
+
* @default true
|
194
|
+
*/
|
195
|
+
closeOnClick: boolean;
|
196
|
+
|
197
|
+
/**
|
198
|
+
* If a given DOM-Node should stay reusable by using a clone of it as toast.
|
199
|
+
* If set to false the original DOM-Node will be detached and removed from the DOM then the toast is closed.
|
200
|
+
*
|
201
|
+
* @default true
|
202
|
+
*/
|
203
|
+
cloneModule: boolean;
|
204
|
+
|
205
|
+
/**
|
206
|
+
* Displays a progress bar on 'top' or 'bottom' increasing until 'displayTime' is reached.
|
207
|
+
* 'false' won't display any progress bar. If 'displayTime' option is '0', this option is ignored.
|
208
|
+
*
|
209
|
+
* @default false
|
210
|
+
*/
|
211
|
+
showProgress: boolean | 'top' | 'bottom';
|
212
|
+
|
213
|
+
/**
|
214
|
+
* 'true' Increases the progress bar from 0% to 100%.
|
215
|
+
* 'false' Decreases the progress bar from 100% to 0%.
|
216
|
+
*
|
217
|
+
* @default false
|
218
|
+
*/
|
219
|
+
progressUp: boolean;
|
220
|
+
|
221
|
+
/**
|
222
|
+
* Set to 'false' if the display timer should not pause when the toast is hovered.
|
223
|
+
*
|
224
|
+
* @default true
|
225
|
+
*/
|
226
|
+
pauseOnHover: boolean;
|
227
|
+
|
228
|
+
/**
|
229
|
+
* 'true' will display the toast in a fixed width, 'false' displays the toast responsively with dynamic width.
|
230
|
+
*
|
231
|
+
* @default true
|
232
|
+
*/
|
233
|
+
compact: boolean;
|
234
|
+
|
235
|
+
/**
|
236
|
+
* Opacity value of the toast after the show-transition.
|
237
|
+
*
|
238
|
+
* @default 1
|
239
|
+
*/
|
240
|
+
opacity: number;
|
241
|
+
|
242
|
+
/**
|
243
|
+
* Define if new toasts should be displayed above the others.
|
244
|
+
*
|
245
|
+
* @default false
|
246
|
+
*/
|
247
|
+
newestOnTop: boolean;
|
248
|
+
|
249
|
+
/**
|
250
|
+
* Whether HTML included in given title, message or actions should be preserved.
|
251
|
+
* Set to 'false' in case you work with untrusted 3rd party content.
|
252
|
+
*
|
253
|
+
* @default true
|
254
|
+
*/
|
255
|
+
preserveHTML: boolean;
|
256
|
+
|
257
|
+
/**
|
258
|
+
* Settings to set the transitions and durations during the show or the hide of a toast.
|
259
|
+
*/
|
260
|
+
transition: Toast.TransitionSettings;
|
261
|
+
|
262
|
+
// endregion
|
263
|
+
|
264
|
+
// region Callbacks
|
265
|
+
|
266
|
+
/**
|
267
|
+
* Callback before toast is shown. Returning 'false' from this callback will cancel the toast from showing.
|
268
|
+
*/
|
269
|
+
onShow(this: JQuery): void;
|
270
|
+
|
271
|
+
/**
|
272
|
+
* Callback before toast is shown. Returning false from this callback will cancel the toast from showing..
|
273
|
+
*/
|
274
|
+
onVisible(this: JQuery): void;
|
275
|
+
|
276
|
+
/**
|
277
|
+
* Callback after popup is clicked in
|
278
|
+
*/
|
279
|
+
onClick(this: JQuery): void;
|
280
|
+
|
281
|
+
/**
|
282
|
+
* Callback before toast is hidden. Returning 'false' from this callback will cancel the toast from hiding.
|
283
|
+
*/
|
284
|
+
onHide(this: JQuery): void;
|
285
|
+
|
286
|
+
/**
|
287
|
+
* Callback after toast is hidden.
|
288
|
+
*/
|
289
|
+
onHidden(this: JQuery): void;
|
290
|
+
|
291
|
+
/**
|
292
|
+
* Callback before toast is destroyed.
|
293
|
+
*/
|
294
|
+
onRemove(this: JQuery): void;
|
295
|
+
|
296
|
+
/**
|
297
|
+
* Callback when an existing button with class 'positive' or 'ok' or 'approve' is clicked. Return 'false' to avoid closing the toast.
|
298
|
+
*/
|
299
|
+
onApprove(this: JQuery): void;
|
300
|
+
|
301
|
+
/**
|
302
|
+
* Callback when an existing button with class 'negative' or 'cancel' or 'deny' is clicked. Return 'false' to avoid closing the toast.
|
303
|
+
*/
|
304
|
+
onDeny(this: JQuery): void;
|
305
|
+
|
306
|
+
// endregion
|
307
|
+
|
308
|
+
// region Content Settings
|
309
|
+
|
310
|
+
/**
|
311
|
+
* A title for the toast. Leave empty to not display it.
|
312
|
+
*
|
313
|
+
* @default ''
|
314
|
+
*/
|
315
|
+
title: string;
|
316
|
+
|
317
|
+
/**
|
318
|
+
* Message to display.
|
319
|
+
*
|
320
|
+
* @default ''
|
321
|
+
*/
|
322
|
+
message: string;
|
323
|
+
|
324
|
+
/**
|
325
|
+
* An array of objects. Each object defines an action with 'properties' 'text', 'class', 'icon' and 'click'.
|
326
|
+
*/
|
327
|
+
actions: Toast.ActionsSettings;
|
328
|
+
|
329
|
+
// endregion
|
330
|
+
|
331
|
+
// region DOM Settings
|
332
|
+
|
333
|
+
/**
|
334
|
+
* Event namespace. Makes sure module teardown does not effect other events attached to an element.
|
335
|
+
*/
|
336
|
+
namespace: string;
|
337
|
+
|
338
|
+
/**
|
339
|
+
* DOM Selectors used internally.
|
340
|
+
*/
|
341
|
+
selector: Toast.SelectorSettings;
|
342
|
+
|
343
|
+
/**
|
344
|
+
* Class names used to attach style to state.
|
345
|
+
*/
|
346
|
+
className: Toast.ClassNameSettings;
|
347
|
+
|
348
|
+
/**
|
349
|
+
* Icon names used internally.
|
350
|
+
*/
|
351
|
+
icons: Toast.IconSettings;
|
352
|
+
|
353
|
+
// endregion
|
354
|
+
|
355
|
+
// region Debug Settings
|
356
|
+
|
357
|
+
/**
|
358
|
+
* Name used in log statements
|
359
|
+
*/
|
360
|
+
name: string;
|
361
|
+
|
362
|
+
/**
|
363
|
+
* Silences all console output including error messages, regardless of other debug settings.
|
364
|
+
*/
|
365
|
+
silent: boolean;
|
366
|
+
|
367
|
+
/**
|
368
|
+
* Debug output to console
|
369
|
+
*/
|
370
|
+
debug: boolean;
|
371
|
+
|
372
|
+
/**
|
373
|
+
* Show console.table output with performance metrics
|
374
|
+
*/
|
375
|
+
performance: boolean;
|
376
|
+
|
377
|
+
/**
|
378
|
+
* Debug output includes all internal behaviors
|
379
|
+
*/
|
380
|
+
verbose: boolean;
|
381
|
+
|
382
|
+
error: Toast.ErrorSettings;
|
383
|
+
|
384
|
+
// endregion
|
385
|
+
}
|
386
|
+
}
|
387
|
+
|
388
|
+
namespace Toast {
|
389
|
+
type TransitionSettings = TransitionSettings.Param;
|
390
|
+
|
391
|
+
namespace TransitionSettings {
|
392
|
+
type Param = (
|
393
|
+
| Pick<_Impl, 'showMethod'>
|
394
|
+
| Pick<_Impl, 'showDuration'>
|
395
|
+
| Pick<_Impl, 'hideMethod'>
|
396
|
+
| Pick<_Impl, 'hideDuration'>
|
397
|
+
| Pick<_Impl, 'closeEasing'>
|
398
|
+
) &
|
399
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
400
|
+
|
401
|
+
interface _Impl {
|
402
|
+
/**
|
403
|
+
* @default 'scale'
|
404
|
+
*/
|
405
|
+
showMethod: string;
|
406
|
+
|
407
|
+
/**
|
408
|
+
* @default 500
|
409
|
+
*/
|
410
|
+
showDuration: number;
|
411
|
+
|
412
|
+
/**
|
413
|
+
* @default 'scale'
|
414
|
+
*/
|
415
|
+
hideMethod: string;
|
416
|
+
|
417
|
+
/**
|
418
|
+
* @default 500
|
419
|
+
*/
|
420
|
+
hideDuration: number;
|
421
|
+
|
422
|
+
/**
|
423
|
+
* @default 'closeEasing'
|
424
|
+
*/
|
425
|
+
closeEasing: string;
|
426
|
+
}
|
427
|
+
}
|
428
|
+
|
429
|
+
type ActionsSettings = ActionsSettings.Param;
|
430
|
+
|
431
|
+
namespace ActionsSettings {
|
432
|
+
type Param = (Pick<_Impl, 'text'> | Pick<_Impl, 'class'> | Pick<_Impl, 'icon'> | Pick<_Impl, 'click'>) &
|
433
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
434
|
+
|
435
|
+
interface _Impl {
|
436
|
+
/**
|
437
|
+
* @default 'Wait'
|
438
|
+
*/
|
439
|
+
text: string;
|
440
|
+
|
441
|
+
/**
|
442
|
+
* @default 'red'
|
443
|
+
*/
|
444
|
+
class: string;
|
445
|
+
|
446
|
+
/**
|
447
|
+
* @default 'exclamation'
|
448
|
+
*/
|
449
|
+
icon: string;
|
450
|
+
|
451
|
+
/**
|
452
|
+
* @default function() {}
|
453
|
+
*/
|
454
|
+
click: () => void;
|
455
|
+
}
|
456
|
+
}
|
457
|
+
|
458
|
+
type SelectorSettings = SelectorSettings.Param;
|
459
|
+
|
460
|
+
namespace SelectorSettings {
|
461
|
+
type Param = (
|
462
|
+
| Pick<_Impl, 'container'>
|
463
|
+
| Pick<_Impl, 'box'>
|
464
|
+
| Pick<_Impl, 'toast'>
|
465
|
+
| Pick<_Impl, 'input'>
|
466
|
+
| Pick<_Impl, 'approve'>
|
467
|
+
| Pick<_Impl, 'deny'>
|
468
|
+
) &
|
469
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
470
|
+
|
471
|
+
interface _Impl {
|
472
|
+
/**
|
473
|
+
* @default '.ui.toast-container'
|
474
|
+
*/
|
475
|
+
container: string;
|
476
|
+
|
477
|
+
/**
|
478
|
+
* @default '.toast-box'
|
479
|
+
*/
|
480
|
+
box: string;
|
481
|
+
|
482
|
+
/**
|
483
|
+
* @default '.ui.toast'
|
484
|
+
*/
|
485
|
+
toast: string;
|
486
|
+
|
487
|
+
/**
|
488
|
+
* @default 'input:not([type="hidden"]), textarea, select, button, .ui.button, ui.dropdown'
|
489
|
+
*/
|
490
|
+
input: string;
|
491
|
+
|
492
|
+
/**
|
493
|
+
* @default '.actions .positive, .actions .approve, .actions .ok'
|
494
|
+
*/
|
495
|
+
approve: string;
|
496
|
+
|
497
|
+
/**
|
498
|
+
* @default '.actions .negative, .actions .deny, .actions .cancel'
|
499
|
+
*/
|
500
|
+
deny: string;
|
501
|
+
}
|
502
|
+
}
|
503
|
+
|
504
|
+
type ClassNameSettings = ClassNameSettings.Param;
|
505
|
+
|
506
|
+
namespace ClassNameSettings {
|
507
|
+
type Param = (
|
508
|
+
| Pick<_Impl, 'container'>
|
509
|
+
| Pick<_Impl, 'box'>
|
510
|
+
| Pick<_Impl, 'progress'>
|
511
|
+
| Pick<_Impl, 'toast'>
|
512
|
+
| Pick<_Impl, 'icon'>
|
513
|
+
| Pick<_Impl, 'visible'>
|
514
|
+
| Pick<_Impl, 'content'>
|
515
|
+
| Pick<_Impl, 'title'>
|
516
|
+
) &
|
517
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
518
|
+
|
519
|
+
interface _Impl {
|
520
|
+
/**
|
521
|
+
* @default 'toast-container'
|
522
|
+
*/
|
523
|
+
container: string;
|
524
|
+
|
525
|
+
/**
|
526
|
+
* @default 'toast-box'
|
527
|
+
*/
|
528
|
+
box: string;
|
529
|
+
|
530
|
+
/**
|
531
|
+
* @default 'ui attached active progress'
|
532
|
+
*/
|
533
|
+
progress: string;
|
534
|
+
|
535
|
+
/**
|
536
|
+
* @default 'ui toast'
|
537
|
+
*/
|
538
|
+
toast: string;
|
539
|
+
|
540
|
+
/**
|
541
|
+
* @default 'icon'
|
542
|
+
*/
|
543
|
+
icon: string;
|
544
|
+
|
545
|
+
/**
|
546
|
+
* @default 'visible'
|
547
|
+
*/
|
548
|
+
visible: string;
|
549
|
+
|
550
|
+
/**
|
551
|
+
* @default 'content'
|
552
|
+
*/
|
553
|
+
content: string;
|
554
|
+
|
555
|
+
/**
|
556
|
+
* @default 'header'
|
557
|
+
*/
|
558
|
+
title: string;
|
559
|
+
}
|
560
|
+
}
|
561
|
+
|
562
|
+
type IconSettings = IconSettings.Param;
|
563
|
+
|
564
|
+
namespace IconSettings {
|
565
|
+
type Param = (
|
566
|
+
| Pick<_Impl, 'info'>
|
567
|
+
| Pick<_Impl, 'success'>
|
568
|
+
| Pick<_Impl, 'warning'>
|
569
|
+
| Pick<_Impl, 'error'>
|
570
|
+
) &
|
571
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
572
|
+
|
573
|
+
interface _Impl {
|
574
|
+
/**
|
575
|
+
* @default 'info'
|
576
|
+
*/
|
577
|
+
info: string;
|
578
|
+
|
579
|
+
/**
|
580
|
+
* @default 'checkmark'
|
581
|
+
*/
|
582
|
+
success: string;
|
583
|
+
|
584
|
+
/**
|
585
|
+
* @default 'warning'
|
586
|
+
*/
|
587
|
+
warning: string;
|
588
|
+
|
589
|
+
/**
|
590
|
+
* @default 'times'
|
591
|
+
*/
|
592
|
+
error: string;
|
593
|
+
}
|
594
|
+
}
|
595
|
+
|
596
|
+
type ErrorSettings = ErrorSettings.Param;
|
597
|
+
|
598
|
+
namespace ErrorSettings {
|
599
|
+
type Param = (Pick<_Impl, 'method'> | Pick<_Impl, 'noElement'> | Pick<_Impl, 'verticalCard'>) &
|
600
|
+
Partial<Pick<_Impl, keyof _Impl>>;
|
601
|
+
|
602
|
+
interface _Impl {
|
603
|
+
/**
|
604
|
+
* @default 'The method you called is not defined.'
|
605
|
+
*/
|
606
|
+
method: string;
|
607
|
+
|
608
|
+
/**
|
609
|
+
* @default 'This module requires ui transitions.'
|
610
|
+
*/
|
611
|
+
noElement: string;
|
612
|
+
|
613
|
+
/**
|
614
|
+
* @default 'Vertical but not attached actions are not supported for card layout.'
|
615
|
+
*/
|
616
|
+
verticalCard: string;
|
617
|
+
}
|
618
|
+
}
|
619
|
+
}
|
620
|
+
}
|