@vaadin/confirm-dialog 24.5.0-alpha1 → 24.5.0-alpha11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +13 -13
- package/src/vaadin-confirm-dialog-mixin.d.ts +7 -0
- package/src/vaadin-confirm-dialog-mixin.js +7 -0
- package/src/vaadin-confirm-dialog.d.ts +1 -0
- package/src/vaadin-confirm-dialog.js +1 -0
- package/web-types.json +6 -2
- package/web-types.lit.json +9 -2
package/README.md
CHANGED
|
@@ -53,7 +53,7 @@ import '@vaadin/confirm-dialog/src/vaadin-confirm-dialog.js';
|
|
|
53
53
|
|
|
54
54
|
## Contributing
|
|
55
55
|
|
|
56
|
-
Read the [contributing guide](https://vaadin.com/docs/latest/contributing
|
|
56
|
+
Read the [contributing guide](https://vaadin.com/docs/latest/contributing) to learn about our development process, how to propose bugfixes and improvements, and how to test your changes to Vaadin components.
|
|
57
57
|
|
|
58
58
|
## License
|
|
59
59
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/confirm-dialog",
|
|
3
|
-
"version": "24.5.0-
|
|
3
|
+
"version": "24.5.0-alpha11",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -37,24 +37,24 @@
|
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@open-wc/dedupe-mixin": "^1.3.0",
|
|
39
39
|
"@polymer/polymer": "^3.0.0",
|
|
40
|
-
"@vaadin/button": "24.5.0-
|
|
41
|
-
"@vaadin/component-base": "24.5.0-
|
|
42
|
-
"@vaadin/dialog": "24.5.0-
|
|
43
|
-
"@vaadin/overlay": "24.5.0-
|
|
44
|
-
"@vaadin/vaadin-lumo-styles": "24.5.0-
|
|
45
|
-
"@vaadin/vaadin-material-styles": "24.5.0-
|
|
46
|
-
"@vaadin/vaadin-themable-mixin": "24.5.0-
|
|
40
|
+
"@vaadin/button": "24.5.0-alpha11",
|
|
41
|
+
"@vaadin/component-base": "24.5.0-alpha11",
|
|
42
|
+
"@vaadin/dialog": "24.5.0-alpha11",
|
|
43
|
+
"@vaadin/overlay": "24.5.0-alpha11",
|
|
44
|
+
"@vaadin/vaadin-lumo-styles": "24.5.0-alpha11",
|
|
45
|
+
"@vaadin/vaadin-material-styles": "24.5.0-alpha11",
|
|
46
|
+
"@vaadin/vaadin-themable-mixin": "24.5.0-alpha11",
|
|
47
47
|
"lit": "^3.0.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
|
-
"@
|
|
51
|
-
"@vaadin/
|
|
52
|
-
"@vaadin/testing-helpers": "^0.
|
|
53
|
-
"sinon": "^
|
|
50
|
+
"@vaadin/a11y-base": "24.5.0-alpha11",
|
|
51
|
+
"@vaadin/chai-plugins": "24.5.0-alpha11",
|
|
52
|
+
"@vaadin/testing-helpers": "^1.0.0",
|
|
53
|
+
"sinon": "^18.0.0"
|
|
54
54
|
},
|
|
55
55
|
"web-types": [
|
|
56
56
|
"web-types.json",
|
|
57
57
|
"web-types.lit.json"
|
|
58
58
|
],
|
|
59
|
-
"gitHead": "
|
|
59
|
+
"gitHead": "8426cea2803a10db518fc85752eeea4c5c755687"
|
|
60
60
|
}
|
|
@@ -10,9 +10,16 @@ import type { Constructor } from '@open-wc/dedupe-mixin';
|
|
|
10
10
|
*/
|
|
11
11
|
export type ConfirmDialogOpenedChangedEvent = CustomEvent<{ value: boolean }>;
|
|
12
12
|
|
|
13
|
+
/**
|
|
14
|
+
* Fired when the confirm dialog is closed.
|
|
15
|
+
*/
|
|
16
|
+
export type ConfirmDialogClosedEvent = CustomEvent;
|
|
17
|
+
|
|
13
18
|
export interface ConfirmDialogCustomEventMap {
|
|
14
19
|
'opened-changed': ConfirmDialogOpenedChangedEvent;
|
|
15
20
|
|
|
21
|
+
closed: ConfirmDialogClosedEvent;
|
|
22
|
+
|
|
16
23
|
confirm: Event;
|
|
17
24
|
|
|
18
25
|
cancel: Event;
|
|
@@ -333,6 +333,7 @@ export const ConfirmDialogMixin = (superClass) =>
|
|
|
333
333
|
this.__slottedNodes.forEach((node) => {
|
|
334
334
|
this.appendChild(node);
|
|
335
335
|
});
|
|
336
|
+
this.dispatchEvent(new CustomEvent('closed'));
|
|
336
337
|
}
|
|
337
338
|
|
|
338
339
|
/** @private */
|
|
@@ -448,4 +449,10 @@ export const ConfirmDialogMixin = (superClass) =>
|
|
|
448
449
|
_getAriaLabel(header) {
|
|
449
450
|
return header || 'confirmation';
|
|
450
451
|
}
|
|
452
|
+
|
|
453
|
+
/**
|
|
454
|
+
* Fired when the confirm dialog is closed.
|
|
455
|
+
*
|
|
456
|
+
* @event closed
|
|
457
|
+
*/
|
|
451
458
|
};
|
|
@@ -57,6 +57,7 @@ export * from './vaadin-confirm-dialog-mixin.js';
|
|
|
57
57
|
* @fires {Event} cancel - Fired when Cancel button or Escape key was pressed.
|
|
58
58
|
* @fires {Event} reject - Fired when Reject button was pressed.
|
|
59
59
|
* @fires {CustomEvent} opened-changed - Fired when the `opened` property changes.
|
|
60
|
+
* @fires {CustomEvent} closed - Fired when the confirm dialog is closed.
|
|
60
61
|
*/
|
|
61
62
|
declare class ConfirmDialog extends ConfirmDialogMixin(ElementMixin(ThemePropertyMixin(ControllerMixin(HTMLElement)))) {
|
|
62
63
|
addEventListener<K extends keyof ConfirmDialogEventMap>(
|
|
@@ -59,6 +59,7 @@ import { ConfirmDialogMixin } from './vaadin-confirm-dialog-mixin.js';
|
|
|
59
59
|
* @fires {Event} cancel - Fired when Cancel button or Escape key was pressed.
|
|
60
60
|
* @fires {Event} reject - Fired when Reject button was pressed.
|
|
61
61
|
* @fires {CustomEvent} opened-changed - Fired when the `opened` property changes.
|
|
62
|
+
* @fires {CustomEvent} closed - Fired when the confirm dialog is closed.
|
|
62
63
|
*
|
|
63
64
|
* @customElement
|
|
64
65
|
* @extends HTMLElement
|
package/web-types.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/confirm-dialog",
|
|
4
|
-
"version": "24.5.0-
|
|
4
|
+
"version": "24.5.0-alpha11",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"contributions": {
|
|
7
7
|
"html": {
|
|
8
8
|
"elements": [
|
|
9
9
|
{
|
|
10
10
|
"name": "vaadin-confirm-dialog",
|
|
11
|
-
"description": "`<vaadin-confirm-dialog>` is a Web Component for showing alerts and asking for user confirmation.\n\n```\n<vaadin-confirm-dialog cancel-button-visible>\n There are unsaved changes. Do you really want to leave?\n</vaadin-confirm-dialog>\n```\n\n### Styling\n\nThe `<vaadin-confirm-dialog>` is not themable. Apply styles to `<vaadin-confirm-dialog-overlay>`\ncomponent and use its shadow parts for styling.\nSee [`<vaadin-overlay>`](https://cdn.vaadin.com/vaadin-web-components/24.5.0-
|
|
11
|
+
"description": "`<vaadin-confirm-dialog>` is a Web Component for showing alerts and asking for user confirmation.\n\n```\n<vaadin-confirm-dialog cancel-button-visible>\n There are unsaved changes. Do you really want to leave?\n</vaadin-confirm-dialog>\n```\n\n### Styling\n\nThe `<vaadin-confirm-dialog>` is not themable. Apply styles to `<vaadin-confirm-dialog-overlay>`\ncomponent and use its shadow parts for styling.\nSee [`<vaadin-overlay>`](https://cdn.vaadin.com/vaadin-web-components/24.5.0-alpha11/#/elements/vaadin-overlay) for the overlay styling documentation.\n\nIn addition to `<vaadin-overlay>` parts, the following parts are available for theming:\n\nPart name | Description\n-----------------|-------------------------------------------\n`header` | The header element wrapper\n`message` | The message element wrapper\n`footer` | The footer element that wraps the buttons\n`cancel-button` | The \"Cancel\" button wrapper\n`confirm-button` | The \"Confirm\" button wrapper\n`reject-button` | The \"Reject\" button wrapper\n\nUse `confirmTheme`, `cancelTheme` and `rejectTheme` properties to customize buttons theme.\nAlso, the `theme` attribute value set on `<vaadin-confirm-dialog>` is propagated to the\n`<vaadin-confirm-dialog-overlay>` component.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.\n\n### Custom content\n\nThe following slots are available for providing custom content:\n\nSlot name | Description\n------------------|---------------------------\n`header` | Slot for header element\n`cancel-button` | Slot for \"Cancel\" button\n`confirm-button` | Slot for \"Confirm\" button\n`reject-button` | Slot for \"Reject\" button",
|
|
12
12
|
"attributes": [
|
|
13
13
|
{
|
|
14
14
|
"name": "accessible-description-ref",
|
|
@@ -290,6 +290,10 @@
|
|
|
290
290
|
}
|
|
291
291
|
],
|
|
292
292
|
"events": [
|
|
293
|
+
{
|
|
294
|
+
"name": "closed",
|
|
295
|
+
"description": "Fired when the confirm dialog is closed."
|
|
296
|
+
},
|
|
293
297
|
{
|
|
294
298
|
"name": "cancel",
|
|
295
299
|
"description": "cancel\nfired when Cancel button or Escape key was pressed."
|
package/web-types.lit.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/confirm-dialog",
|
|
4
|
-
"version": "24.5.0-
|
|
4
|
+
"version": "24.5.0-alpha11",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"framework": "lit",
|
|
7
7
|
"framework-config": {
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"elements": [
|
|
17
17
|
{
|
|
18
18
|
"name": "vaadin-confirm-dialog",
|
|
19
|
-
"description": "`<vaadin-confirm-dialog>` is a Web Component for showing alerts and asking for user confirmation.\n\n```\n<vaadin-confirm-dialog cancel-button-visible>\n There are unsaved changes. Do you really want to leave?\n</vaadin-confirm-dialog>\n```\n\n### Styling\n\nThe `<vaadin-confirm-dialog>` is not themable. Apply styles to `<vaadin-confirm-dialog-overlay>`\ncomponent and use its shadow parts for styling.\nSee [`<vaadin-overlay>`](https://cdn.vaadin.com/vaadin-web-components/24.5.0-
|
|
19
|
+
"description": "`<vaadin-confirm-dialog>` is a Web Component for showing alerts and asking for user confirmation.\n\n```\n<vaadin-confirm-dialog cancel-button-visible>\n There are unsaved changes. Do you really want to leave?\n</vaadin-confirm-dialog>\n```\n\n### Styling\n\nThe `<vaadin-confirm-dialog>` is not themable. Apply styles to `<vaadin-confirm-dialog-overlay>`\ncomponent and use its shadow parts for styling.\nSee [`<vaadin-overlay>`](https://cdn.vaadin.com/vaadin-web-components/24.5.0-alpha11/#/elements/vaadin-overlay) for the overlay styling documentation.\n\nIn addition to `<vaadin-overlay>` parts, the following parts are available for theming:\n\nPart name | Description\n-----------------|-------------------------------------------\n`header` | The header element wrapper\n`message` | The message element wrapper\n`footer` | The footer element that wraps the buttons\n`cancel-button` | The \"Cancel\" button wrapper\n`confirm-button` | The \"Confirm\" button wrapper\n`reject-button` | The \"Reject\" button wrapper\n\nUse `confirmTheme`, `cancelTheme` and `rejectTheme` properties to customize buttons theme.\nAlso, the `theme` attribute value set on `<vaadin-confirm-dialog>` is propagated to the\n`<vaadin-confirm-dialog-overlay>` component.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.\n\n### Custom content\n\nThe following slots are available for providing custom content:\n\nSlot name | Description\n------------------|---------------------------\n`header` | Slot for header element\n`cancel-button` | Slot for \"Cancel\" button\n`confirm-button` | Slot for \"Confirm\" button\n`reject-button` | Slot for \"Reject\" button",
|
|
20
20
|
"extension": true,
|
|
21
21
|
"attributes": [
|
|
22
22
|
{
|
|
@@ -117,6 +117,13 @@
|
|
|
117
117
|
"kind": "expression"
|
|
118
118
|
}
|
|
119
119
|
},
|
|
120
|
+
{
|
|
121
|
+
"name": "@closed",
|
|
122
|
+
"description": "Fired when the confirm dialog is closed.",
|
|
123
|
+
"value": {
|
|
124
|
+
"kind": "expression"
|
|
125
|
+
}
|
|
126
|
+
},
|
|
120
127
|
{
|
|
121
128
|
"name": "@cancel",
|
|
122
129
|
"description": "cancel\nfired when Cancel button or Escape key was pressed.",
|