@vaadin/notification 25.1.0-alpha6 → 25.1.0-alpha8
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/custom-elements.json +533 -0
- package/package.json +12 -10
- package/src/vaadin-notification.js +3 -3
- package/web-types.json +1 -1
- package/web-types.lit.json +1 -1
|
@@ -0,0 +1,533 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": "1.0.0",
|
|
3
|
+
"readme": "",
|
|
4
|
+
"modules": [
|
|
5
|
+
{
|
|
6
|
+
"kind": "javascript-module",
|
|
7
|
+
"path": "vaadin-notification.js",
|
|
8
|
+
"declarations": [],
|
|
9
|
+
"exports": [
|
|
10
|
+
{
|
|
11
|
+
"kind": "js",
|
|
12
|
+
"name": "*",
|
|
13
|
+
"declaration": {
|
|
14
|
+
"name": "*",
|
|
15
|
+
"module": "src/vaadin-notification.js"
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"kind": "javascript-module",
|
|
22
|
+
"path": "src/vaadin-notification-mixin.js",
|
|
23
|
+
"declarations": [
|
|
24
|
+
{
|
|
25
|
+
"kind": "mixin",
|
|
26
|
+
"description": "A mixin providing common notification container functionality.",
|
|
27
|
+
"name": "NotificationContainerMixin",
|
|
28
|
+
"members": [
|
|
29
|
+
{
|
|
30
|
+
"kind": "method",
|
|
31
|
+
"name": "bringToFront",
|
|
32
|
+
"description": "Move the notification container to the top of the stack."
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"kind": "field",
|
|
36
|
+
"name": "opened",
|
|
37
|
+
"privacy": "public",
|
|
38
|
+
"type": {
|
|
39
|
+
"text": "boolean"
|
|
40
|
+
},
|
|
41
|
+
"description": "True when the container is opened",
|
|
42
|
+
"attribute": "opened"
|
|
43
|
+
}
|
|
44
|
+
],
|
|
45
|
+
"attributes": [
|
|
46
|
+
{
|
|
47
|
+
"name": "opened",
|
|
48
|
+
"type": {
|
|
49
|
+
"text": "boolean"
|
|
50
|
+
},
|
|
51
|
+
"description": "True when the container is opened",
|
|
52
|
+
"fieldName": "opened"
|
|
53
|
+
}
|
|
54
|
+
],
|
|
55
|
+
"parameters": [
|
|
56
|
+
{
|
|
57
|
+
"name": "superClass"
|
|
58
|
+
}
|
|
59
|
+
]
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"kind": "mixin",
|
|
63
|
+
"description": "A mixin providing common notification functionality.",
|
|
64
|
+
"name": "NotificationMixin",
|
|
65
|
+
"members": [
|
|
66
|
+
{
|
|
67
|
+
"kind": "field",
|
|
68
|
+
"name": "assertive",
|
|
69
|
+
"privacy": "public",
|
|
70
|
+
"type": {
|
|
71
|
+
"text": "boolean"
|
|
72
|
+
},
|
|
73
|
+
"description": "When true, the notification card has `aria-live` attribute set to\n`assertive` instead of `polite`. This makes screen readers announce\nthe notification content immediately when it appears.",
|
|
74
|
+
"attribute": "assertive"
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"kind": "method",
|
|
78
|
+
"name": "close",
|
|
79
|
+
"description": "Closes the notification."
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"kind": "field",
|
|
83
|
+
"name": "duration",
|
|
84
|
+
"privacy": "public",
|
|
85
|
+
"type": {
|
|
86
|
+
"text": "number"
|
|
87
|
+
},
|
|
88
|
+
"description": "The duration in milliseconds to show the notification.\nSet to `0` or a negative number to disable the notification auto-closing.",
|
|
89
|
+
"attribute": "duration"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"kind": "method",
|
|
93
|
+
"name": "open",
|
|
94
|
+
"description": "Opens the notification."
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
"kind": "field",
|
|
98
|
+
"name": "opened",
|
|
99
|
+
"privacy": "public",
|
|
100
|
+
"type": {
|
|
101
|
+
"text": "boolean"
|
|
102
|
+
},
|
|
103
|
+
"description": "True if the notification is currently displayed.",
|
|
104
|
+
"attribute": "opened"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"kind": "field",
|
|
108
|
+
"name": "overlayClass",
|
|
109
|
+
"privacy": "public",
|
|
110
|
+
"type": {
|
|
111
|
+
"text": "string"
|
|
112
|
+
},
|
|
113
|
+
"description": "A space-delimited list of CSS class names to set on the overlay element.\nThis property does not affect other CSS class names set manually via JS.\n\nNote, if the CSS class name was set with this property, clearing it will\nremove it from the overlay, even if the same class name was also added\nmanually, e.g. by using `classList.add()` in the `renderer` function.",
|
|
114
|
+
"attribute": "overlay-class",
|
|
115
|
+
"inheritedFrom": {
|
|
116
|
+
"name": "OverlayClassMixin",
|
|
117
|
+
"package": "@vaadin/component-base/src/overlay-class-mixin.js"
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
"kind": "field",
|
|
122
|
+
"name": "position",
|
|
123
|
+
"privacy": "public",
|
|
124
|
+
"type": {
|
|
125
|
+
"text": "!NotificationPosition"
|
|
126
|
+
},
|
|
127
|
+
"description": "Alignment of the notification in the viewport\nValid values are `top-stretch|top-start|top-center|top-end|middle|bottom-start|bottom-center|bottom-end|bottom-stretch`",
|
|
128
|
+
"attribute": "position"
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
"kind": "field",
|
|
132
|
+
"name": "renderer",
|
|
133
|
+
"privacy": "public",
|
|
134
|
+
"type": {
|
|
135
|
+
"text": "!NotificationRenderer | undefined"
|
|
136
|
+
},
|
|
137
|
+
"description": "Custom function for rendering the content of the notification.\nReceives two arguments:\n\n- `root` The `<vaadin-notification-card>` DOM element. Append\n your content to it.\n- `notification` The reference to the `<vaadin-notification>` element.",
|
|
138
|
+
"attribute": "renderer"
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
"kind": "method",
|
|
142
|
+
"name": "requestContentUpdate",
|
|
143
|
+
"description": "Requests an update for the content of the notification.\nWhile performing the update, it invokes the renderer passed in the `renderer` property.\n\nIt is not guaranteed that the update happens immediately (synchronously) after it is requested."
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
"kind": "method",
|
|
147
|
+
"name": "show",
|
|
148
|
+
"static": true,
|
|
149
|
+
"parameters": [
|
|
150
|
+
{
|
|
151
|
+
"name": "contents",
|
|
152
|
+
"description": "the contents to show, either as a string or a Lit template."
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
"name": "options",
|
|
156
|
+
"description": "optional options for customizing the notification."
|
|
157
|
+
}
|
|
158
|
+
],
|
|
159
|
+
"description": "Shows a notification with the given content.\nBy default, positions the notification at `bottom-start` and uses a 5 second duration.\nAn options object can be passed to configure the notification.\nThe options object has the following structure:\n\n```ts\n{\n assertive?: boolean\n position?: string\n duration?: number\n theme?: string\n}\n```\n\nSee the individual documentation for:\n- [`assertive`](#/elements/vaadin-notification#property-assertive)\n- [`position`](#/elements/vaadin-notification#property-position)\n- [`duration`](#/elements/vaadin-notification#property-duration)"
|
|
160
|
+
}
|
|
161
|
+
],
|
|
162
|
+
"events": [
|
|
163
|
+
{
|
|
164
|
+
"name": "closed",
|
|
165
|
+
"type": {
|
|
166
|
+
"text": "CustomEvent"
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
],
|
|
170
|
+
"attributes": [
|
|
171
|
+
{
|
|
172
|
+
"name": "assertive",
|
|
173
|
+
"type": {
|
|
174
|
+
"text": "boolean"
|
|
175
|
+
},
|
|
176
|
+
"description": "When true, the notification card has `aria-live` attribute set to\n`assertive` instead of `polite`. This makes screen readers announce\nthe notification content immediately when it appears.",
|
|
177
|
+
"fieldName": "assertive"
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
"name": "duration",
|
|
181
|
+
"type": {
|
|
182
|
+
"text": "number"
|
|
183
|
+
},
|
|
184
|
+
"description": "The duration in milliseconds to show the notification.\nSet to `0` or a negative number to disable the notification auto-closing.",
|
|
185
|
+
"fieldName": "duration"
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
"name": "opened",
|
|
189
|
+
"type": {
|
|
190
|
+
"text": "boolean"
|
|
191
|
+
},
|
|
192
|
+
"description": "True if the notification is currently displayed.",
|
|
193
|
+
"fieldName": "opened"
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"name": "overlay-class",
|
|
197
|
+
"type": {
|
|
198
|
+
"text": "string"
|
|
199
|
+
},
|
|
200
|
+
"description": "A space-delimited list of CSS class names to set on the overlay element.\nThis property does not affect other CSS class names set manually via JS.\n\nNote, if the CSS class name was set with this property, clearing it will\nremove it from the overlay, even if the same class name was also added\nmanually, e.g. by using `classList.add()` in the `renderer` function.",
|
|
201
|
+
"fieldName": "overlayClass",
|
|
202
|
+
"inheritedFrom": {
|
|
203
|
+
"name": "OverlayClassMixin",
|
|
204
|
+
"package": "@vaadin/component-base/src/overlay-class-mixin.js"
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
"name": "position",
|
|
209
|
+
"type": {
|
|
210
|
+
"text": "!NotificationPosition"
|
|
211
|
+
},
|
|
212
|
+
"description": "Alignment of the notification in the viewport\nValid values are `top-stretch|top-start|top-center|top-end|middle|bottom-start|bottom-center|bottom-end|bottom-stretch`",
|
|
213
|
+
"fieldName": "position"
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
"name": "renderer",
|
|
217
|
+
"type": {
|
|
218
|
+
"text": "!NotificationRenderer | undefined"
|
|
219
|
+
},
|
|
220
|
+
"description": "Custom function for rendering the content of the notification.\nReceives two arguments:\n\n- `root` The `<vaadin-notification-card>` DOM element. Append\n your content to it.\n- `notification` The reference to the `<vaadin-notification>` element.",
|
|
221
|
+
"fieldName": "renderer"
|
|
222
|
+
}
|
|
223
|
+
],
|
|
224
|
+
"mixins": [
|
|
225
|
+
{
|
|
226
|
+
"name": "ThemePropertyMixin",
|
|
227
|
+
"package": "@vaadin/vaadin-themable-mixin/vaadin-theme-property-mixin.js"
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
"name": "OverlayClassMixin",
|
|
231
|
+
"package": "@vaadin/component-base/src/overlay-class-mixin.js"
|
|
232
|
+
}
|
|
233
|
+
],
|
|
234
|
+
"parameters": [
|
|
235
|
+
{
|
|
236
|
+
"name": "superClass"
|
|
237
|
+
}
|
|
238
|
+
]
|
|
239
|
+
}
|
|
240
|
+
],
|
|
241
|
+
"exports": [
|
|
242
|
+
{
|
|
243
|
+
"kind": "js",
|
|
244
|
+
"name": "NotificationContainerMixin",
|
|
245
|
+
"declaration": {
|
|
246
|
+
"name": "NotificationContainerMixin",
|
|
247
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
248
|
+
}
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
"kind": "js",
|
|
252
|
+
"name": "NotificationMixin",
|
|
253
|
+
"declaration": {
|
|
254
|
+
"name": "NotificationMixin",
|
|
255
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
]
|
|
259
|
+
},
|
|
260
|
+
{
|
|
261
|
+
"kind": "javascript-module",
|
|
262
|
+
"path": "src/vaadin-notification.js",
|
|
263
|
+
"declarations": [
|
|
264
|
+
{
|
|
265
|
+
"kind": "class",
|
|
266
|
+
"description": "`<vaadin-notification>` is a Web Component providing accessible and customizable notifications (toasts).\n\n### Rendering\n\nThe content of the notification can be populated by using the renderer callback function.\n\nThe renderer function provides `root`, `notification` arguments.\nGenerate DOM content, append it to the `root` element and control the state\nof the host element by accessing `notification`. Before generating new content,\nusers are able to check if there is already content in `root` for reusing it.\n\n```html\n<vaadin-notification id=\"notification\"></vaadin-notification>\n```\n```js\nconst notification = document.querySelector('#notification');\nnotification.renderer = function(root, notification) {\n root.textContent = \"Your work has been saved\";\n};\n```\n\nRenderer is called on the opening of the notification.\nDOM generated during the renderer call can be reused\nin the next renderer call and will be provided with the `root` argument.\nOn first call it will be empty.\n\n### Styling\n\n`<vaadin-notification>` uses `<vaadin-notification-card>` internal\nthemable component as the actual visible notification cards.\n\nThe following shadow DOM parts of the `<vaadin-notification-card>` are available for styling:\n\nPart name | Description\n----------------|----------------\n`overlay` | The notification container\n`content` | The content of the notification\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.\n\nNote: the `theme` attribute value set on `<vaadin-notification>` is\npropagated to the internal `<vaadin-notification-card>`.",
|
|
267
|
+
"name": "Notification",
|
|
268
|
+
"members": [
|
|
269
|
+
{
|
|
270
|
+
"kind": "field",
|
|
271
|
+
"name": "assertive",
|
|
272
|
+
"privacy": "public",
|
|
273
|
+
"type": {
|
|
274
|
+
"text": "boolean"
|
|
275
|
+
},
|
|
276
|
+
"description": "When true, the notification card has `aria-live` attribute set to\n`assertive` instead of `polite`. This makes screen readers announce\nthe notification content immediately when it appears.",
|
|
277
|
+
"attribute": "assertive",
|
|
278
|
+
"inheritedFrom": {
|
|
279
|
+
"name": "NotificationMixin",
|
|
280
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
"kind": "method",
|
|
285
|
+
"name": "close",
|
|
286
|
+
"description": "Closes the notification.",
|
|
287
|
+
"inheritedFrom": {
|
|
288
|
+
"name": "NotificationMixin",
|
|
289
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
290
|
+
}
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
"kind": "field",
|
|
294
|
+
"name": "duration",
|
|
295
|
+
"privacy": "public",
|
|
296
|
+
"type": {
|
|
297
|
+
"text": "number"
|
|
298
|
+
},
|
|
299
|
+
"description": "The duration in milliseconds to show the notification.\nSet to `0` or a negative number to disable the notification auto-closing.",
|
|
300
|
+
"attribute": "duration",
|
|
301
|
+
"inheritedFrom": {
|
|
302
|
+
"name": "NotificationMixin",
|
|
303
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
304
|
+
}
|
|
305
|
+
},
|
|
306
|
+
{
|
|
307
|
+
"kind": "method",
|
|
308
|
+
"name": "open",
|
|
309
|
+
"description": "Opens the notification.",
|
|
310
|
+
"inheritedFrom": {
|
|
311
|
+
"name": "NotificationMixin",
|
|
312
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
"kind": "field",
|
|
317
|
+
"name": "opened",
|
|
318
|
+
"privacy": "public",
|
|
319
|
+
"type": {
|
|
320
|
+
"text": "boolean"
|
|
321
|
+
},
|
|
322
|
+
"description": "True if the notification is currently displayed.",
|
|
323
|
+
"attribute": "opened",
|
|
324
|
+
"inheritedFrom": {
|
|
325
|
+
"name": "NotificationMixin",
|
|
326
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
327
|
+
}
|
|
328
|
+
},
|
|
329
|
+
{
|
|
330
|
+
"kind": "field",
|
|
331
|
+
"name": "overlayClass",
|
|
332
|
+
"privacy": "public",
|
|
333
|
+
"type": {
|
|
334
|
+
"text": "string"
|
|
335
|
+
},
|
|
336
|
+
"description": "A space-delimited list of CSS class names to set on the overlay element.\nThis property does not affect other CSS class names set manually via JS.\n\nNote, if the CSS class name was set with this property, clearing it will\nremove it from the overlay, even if the same class name was also added\nmanually, e.g. by using `classList.add()` in the `renderer` function.",
|
|
337
|
+
"attribute": "overlay-class",
|
|
338
|
+
"inheritedFrom": {
|
|
339
|
+
"name": "OverlayClassMixin",
|
|
340
|
+
"package": "@vaadin/component-base/src/overlay-class-mixin.js"
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
"kind": "field",
|
|
345
|
+
"name": "position",
|
|
346
|
+
"privacy": "public",
|
|
347
|
+
"type": {
|
|
348
|
+
"text": "!NotificationPosition"
|
|
349
|
+
},
|
|
350
|
+
"description": "Alignment of the notification in the viewport\nValid values are `top-stretch|top-start|top-center|top-end|middle|bottom-start|bottom-center|bottom-end|bottom-stretch`",
|
|
351
|
+
"attribute": "position",
|
|
352
|
+
"inheritedFrom": {
|
|
353
|
+
"name": "NotificationMixin",
|
|
354
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
355
|
+
}
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
"kind": "field",
|
|
359
|
+
"name": "renderer",
|
|
360
|
+
"privacy": "public",
|
|
361
|
+
"type": {
|
|
362
|
+
"text": "!NotificationRenderer | undefined"
|
|
363
|
+
},
|
|
364
|
+
"description": "Custom function for rendering the content of the notification.\nReceives two arguments:\n\n- `root` The `<vaadin-notification-card>` DOM element. Append\n your content to it.\n- `notification` The reference to the `<vaadin-notification>` element.",
|
|
365
|
+
"attribute": "renderer",
|
|
366
|
+
"inheritedFrom": {
|
|
367
|
+
"name": "NotificationMixin",
|
|
368
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
369
|
+
}
|
|
370
|
+
},
|
|
371
|
+
{
|
|
372
|
+
"kind": "method",
|
|
373
|
+
"name": "requestContentUpdate",
|
|
374
|
+
"description": "Requests an update for the content of the notification.\nWhile performing the update, it invokes the renderer passed in the `renderer` property.\n\nIt is not guaranteed that the update happens immediately (synchronously) after it is requested.",
|
|
375
|
+
"inheritedFrom": {
|
|
376
|
+
"name": "NotificationMixin",
|
|
377
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
{
|
|
381
|
+
"kind": "method",
|
|
382
|
+
"name": "show",
|
|
383
|
+
"static": true,
|
|
384
|
+
"parameters": [
|
|
385
|
+
{
|
|
386
|
+
"name": "contents",
|
|
387
|
+
"description": "the contents to show, either as a string or a Lit template."
|
|
388
|
+
},
|
|
389
|
+
{
|
|
390
|
+
"name": "options",
|
|
391
|
+
"description": "optional options for customizing the notification."
|
|
392
|
+
}
|
|
393
|
+
],
|
|
394
|
+
"description": "Shows a notification with the given content.\nBy default, positions the notification at `bottom-start` and uses a 5 second duration.\nAn options object can be passed to configure the notification.\nThe options object has the following structure:\n\n```ts\n{\n assertive?: boolean\n position?: string\n duration?: number\n theme?: string\n}\n```\n\nSee the individual documentation for:\n- [`assertive`](#/elements/vaadin-notification#property-assertive)\n- [`position`](#/elements/vaadin-notification#property-position)\n- [`duration`](#/elements/vaadin-notification#property-duration)",
|
|
395
|
+
"inheritedFrom": {
|
|
396
|
+
"name": "NotificationMixin",
|
|
397
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
],
|
|
401
|
+
"events": [
|
|
402
|
+
{
|
|
403
|
+
"name": "closed",
|
|
404
|
+
"type": {
|
|
405
|
+
"text": "CustomEvent"
|
|
406
|
+
},
|
|
407
|
+
"description": "Fired when the notification is closed.",
|
|
408
|
+
"inheritedFrom": {
|
|
409
|
+
"name": "NotificationMixin",
|
|
410
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
411
|
+
}
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
"type": {
|
|
415
|
+
"text": "CustomEvent"
|
|
416
|
+
},
|
|
417
|
+
"description": "Fired when the `opened` property changes.",
|
|
418
|
+
"name": "opened-changed"
|
|
419
|
+
}
|
|
420
|
+
],
|
|
421
|
+
"mixins": [
|
|
422
|
+
{
|
|
423
|
+
"name": "NotificationMixin",
|
|
424
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
425
|
+
},
|
|
426
|
+
{
|
|
427
|
+
"name": "ElementMixin",
|
|
428
|
+
"package": "@vaadin/component-base/src/element-mixin.js"
|
|
429
|
+
},
|
|
430
|
+
{
|
|
431
|
+
"name": "ThemableMixin",
|
|
432
|
+
"package": "@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js"
|
|
433
|
+
},
|
|
434
|
+
{
|
|
435
|
+
"name": "PolylitMixin",
|
|
436
|
+
"package": "@vaadin/component-base/src/polylit-mixin.js"
|
|
437
|
+
}
|
|
438
|
+
],
|
|
439
|
+
"superclass": {
|
|
440
|
+
"name": "LitElement",
|
|
441
|
+
"package": "lit"
|
|
442
|
+
},
|
|
443
|
+
"tagName": "vaadin-notification",
|
|
444
|
+
"customElement": true,
|
|
445
|
+
"attributes": [
|
|
446
|
+
{
|
|
447
|
+
"name": "assertive",
|
|
448
|
+
"type": {
|
|
449
|
+
"text": "boolean"
|
|
450
|
+
},
|
|
451
|
+
"description": "When true, the notification card has `aria-live` attribute set to\n`assertive` instead of `polite`. This makes screen readers announce\nthe notification content immediately when it appears.",
|
|
452
|
+
"fieldName": "assertive",
|
|
453
|
+
"inheritedFrom": {
|
|
454
|
+
"name": "NotificationMixin",
|
|
455
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
456
|
+
}
|
|
457
|
+
},
|
|
458
|
+
{
|
|
459
|
+
"name": "duration",
|
|
460
|
+
"type": {
|
|
461
|
+
"text": "number"
|
|
462
|
+
},
|
|
463
|
+
"description": "The duration in milliseconds to show the notification.\nSet to `0` or a negative number to disable the notification auto-closing.",
|
|
464
|
+
"fieldName": "duration",
|
|
465
|
+
"inheritedFrom": {
|
|
466
|
+
"name": "NotificationMixin",
|
|
467
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
468
|
+
}
|
|
469
|
+
},
|
|
470
|
+
{
|
|
471
|
+
"name": "opened",
|
|
472
|
+
"type": {
|
|
473
|
+
"text": "boolean"
|
|
474
|
+
},
|
|
475
|
+
"description": "True if the notification is currently displayed.",
|
|
476
|
+
"fieldName": "opened",
|
|
477
|
+
"inheritedFrom": {
|
|
478
|
+
"name": "NotificationMixin",
|
|
479
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
480
|
+
}
|
|
481
|
+
},
|
|
482
|
+
{
|
|
483
|
+
"name": "overlay-class",
|
|
484
|
+
"type": {
|
|
485
|
+
"text": "string"
|
|
486
|
+
},
|
|
487
|
+
"description": "A space-delimited list of CSS class names to set on the overlay element.\nThis property does not affect other CSS class names set manually via JS.\n\nNote, if the CSS class name was set with this property, clearing it will\nremove it from the overlay, even if the same class name was also added\nmanually, e.g. by using `classList.add()` in the `renderer` function.",
|
|
488
|
+
"fieldName": "overlayClass",
|
|
489
|
+
"inheritedFrom": {
|
|
490
|
+
"name": "OverlayClassMixin",
|
|
491
|
+
"package": "@vaadin/component-base/src/overlay-class-mixin.js"
|
|
492
|
+
}
|
|
493
|
+
},
|
|
494
|
+
{
|
|
495
|
+
"name": "position",
|
|
496
|
+
"type": {
|
|
497
|
+
"text": "!NotificationPosition"
|
|
498
|
+
},
|
|
499
|
+
"description": "Alignment of the notification in the viewport\nValid values are `top-stretch|top-start|top-center|top-end|middle|bottom-start|bottom-center|bottom-end|bottom-stretch`",
|
|
500
|
+
"fieldName": "position",
|
|
501
|
+
"inheritedFrom": {
|
|
502
|
+
"name": "NotificationMixin",
|
|
503
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
504
|
+
}
|
|
505
|
+
},
|
|
506
|
+
{
|
|
507
|
+
"name": "renderer",
|
|
508
|
+
"type": {
|
|
509
|
+
"text": "!NotificationRenderer | undefined"
|
|
510
|
+
},
|
|
511
|
+
"description": "Custom function for rendering the content of the notification.\nReceives two arguments:\n\n- `root` The `<vaadin-notification-card>` DOM element. Append\n your content to it.\n- `notification` The reference to the `<vaadin-notification>` element.",
|
|
512
|
+
"fieldName": "renderer",
|
|
513
|
+
"inheritedFrom": {
|
|
514
|
+
"name": "NotificationMixin",
|
|
515
|
+
"module": "src/vaadin-notification-mixin.js"
|
|
516
|
+
}
|
|
517
|
+
}
|
|
518
|
+
]
|
|
519
|
+
}
|
|
520
|
+
],
|
|
521
|
+
"exports": [
|
|
522
|
+
{
|
|
523
|
+
"kind": "js",
|
|
524
|
+
"name": "Notification",
|
|
525
|
+
"declaration": {
|
|
526
|
+
"name": "Notification",
|
|
527
|
+
"module": "src/vaadin-notification.js"
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
]
|
|
531
|
+
}
|
|
532
|
+
]
|
|
533
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/notification",
|
|
3
|
-
"version": "25.1.0-
|
|
3
|
+
"version": "25.1.0-alpha8",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -25,6 +25,7 @@
|
|
|
25
25
|
"src",
|
|
26
26
|
"vaadin-*.d.ts",
|
|
27
27
|
"vaadin-*.js",
|
|
28
|
+
"custom-elements.json",
|
|
28
29
|
"web-types.json",
|
|
29
30
|
"web-types.lit.json"
|
|
30
31
|
],
|
|
@@ -36,23 +37,24 @@
|
|
|
36
37
|
],
|
|
37
38
|
"dependencies": {
|
|
38
39
|
"@open-wc/dedupe-mixin": "^1.3.0",
|
|
39
|
-
"@vaadin/component-base": "25.1.0-
|
|
40
|
-
"@vaadin/lit-renderer": "25.1.0-
|
|
41
|
-
"@vaadin/vaadin-themable-mixin": "25.1.0-
|
|
40
|
+
"@vaadin/component-base": "25.1.0-alpha8",
|
|
41
|
+
"@vaadin/lit-renderer": "25.1.0-alpha8",
|
|
42
|
+
"@vaadin/vaadin-themable-mixin": "25.1.0-alpha8",
|
|
42
43
|
"lit": "^3.0.0"
|
|
43
44
|
},
|
|
44
45
|
"devDependencies": {
|
|
45
|
-
"@vaadin/aura": "25.1.0-
|
|
46
|
-
"@vaadin/button": "25.1.0-
|
|
47
|
-
"@vaadin/chai-plugins": "25.1.0-
|
|
48
|
-
"@vaadin/test-runner-commands": "25.1.0-
|
|
46
|
+
"@vaadin/aura": "25.1.0-alpha8",
|
|
47
|
+
"@vaadin/button": "25.1.0-alpha8",
|
|
48
|
+
"@vaadin/chai-plugins": "25.1.0-alpha8",
|
|
49
|
+
"@vaadin/test-runner-commands": "25.1.0-alpha8",
|
|
49
50
|
"@vaadin/testing-helpers": "^2.0.0",
|
|
50
|
-
"@vaadin/vaadin-lumo-styles": "25.1.0-
|
|
51
|
+
"@vaadin/vaadin-lumo-styles": "25.1.0-alpha8",
|
|
51
52
|
"sinon": "^21.0.0"
|
|
52
53
|
},
|
|
54
|
+
"customElements": "custom-elements.json",
|
|
53
55
|
"web-types": [
|
|
54
56
|
"web-types.json",
|
|
55
57
|
"web-types.lit.json"
|
|
56
58
|
],
|
|
57
|
-
"gitHead": "
|
|
59
|
+
"gitHead": "810590c9c7682a9326c9352df795b5ea4891a71f"
|
|
58
60
|
}
|
|
@@ -17,7 +17,7 @@ import { NotificationContainerMixin, NotificationMixin } from './vaadin-notifica
|
|
|
17
17
|
/**
|
|
18
18
|
* An element used internally by `<vaadin-notification>`. Not intended to be used separately.
|
|
19
19
|
*
|
|
20
|
-
* @customElement
|
|
20
|
+
* @customElement vaadin-notification-container
|
|
21
21
|
* @extends HTMLElement
|
|
22
22
|
* @mixes NotificationContainerMixin
|
|
23
23
|
* @mixes ElementMixin
|
|
@@ -58,7 +58,7 @@ class NotificationContainer extends NotificationContainerMixin(
|
|
|
58
58
|
/**
|
|
59
59
|
* An element used internally by `<vaadin-notification>`. Not intended to be used separately.
|
|
60
60
|
*
|
|
61
|
-
* @customElement
|
|
61
|
+
* @customElement vaadin-notification-card
|
|
62
62
|
* @extends HTMLElement
|
|
63
63
|
* @mixes ThemableMixin
|
|
64
64
|
* @private
|
|
@@ -137,7 +137,7 @@ class NotificationCard extends ThemableMixin(PolylitMixin(LumoInjectionMixin(Lit
|
|
|
137
137
|
* @fires {CustomEvent} opened-changed - Fired when the `opened` property changes.
|
|
138
138
|
* @fires {CustomEvent} closed - Fired when the notification is closed.
|
|
139
139
|
*
|
|
140
|
-
* @customElement
|
|
140
|
+
* @customElement vaadin-notification
|
|
141
141
|
* @extends HTMLElement
|
|
142
142
|
* @mixes NotificationMixin
|
|
143
143
|
* @mixes ElementMixin
|
package/web-types.json
CHANGED
package/web-types.lit.json
CHANGED