@vaadin/dialog 25.0.0-alpha9 → 25.0.0-beta2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/dialog",
3
- "version": "25.0.0-alpha9",
3
+ "version": "25.0.0-beta2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -23,9 +23,6 @@
23
23
  "lit.d.ts",
24
24
  "lit.js",
25
25
  "src",
26
- "!src/styles/*-base-styles.d.ts",
27
- "!src/styles/*-base-styles.js",
28
- "theme",
29
26
  "vaadin-*.d.ts",
30
27
  "vaadin-*.js",
31
28
  "web-types.json",
@@ -39,23 +36,23 @@
39
36
  ],
40
37
  "dependencies": {
41
38
  "@open-wc/dedupe-mixin": "^1.3.0",
42
- "@vaadin/component-base": "25.0.0-alpha9",
43
- "@vaadin/lit-renderer": "25.0.0-alpha9",
44
- "@vaadin/overlay": "25.0.0-alpha9",
45
- "@vaadin/vaadin-lumo-styles": "25.0.0-alpha9",
46
- "@vaadin/vaadin-themable-mixin": "25.0.0-alpha9",
39
+ "@vaadin/component-base": "25.0.0-beta2",
40
+ "@vaadin/lit-renderer": "25.0.0-beta2",
41
+ "@vaadin/overlay": "25.0.0-beta2",
42
+ "@vaadin/vaadin-themable-mixin": "25.0.0-beta2",
47
43
  "lit": "^3.0.0"
48
44
  },
49
45
  "devDependencies": {
50
- "@vaadin/a11y-base": "25.0.0-alpha9",
51
- "@vaadin/chai-plugins": "25.0.0-alpha9",
52
- "@vaadin/test-runner-commands": "25.0.0-alpha9",
46
+ "@vaadin/a11y-base": "25.0.0-beta2",
47
+ "@vaadin/chai-plugins": "25.0.0-beta2",
48
+ "@vaadin/test-runner-commands": "25.0.0-beta2",
53
49
  "@vaadin/testing-helpers": "^2.0.0",
54
- "sinon": "^18.0.0"
50
+ "@vaadin/vaadin-lumo-styles": "25.0.0-beta2",
51
+ "sinon": "^21.0.0"
55
52
  },
56
53
  "web-types": [
57
54
  "web-types.json",
58
55
  "web-types.lit.json"
59
56
  ],
60
- "gitHead": "bbe4720721e0955ffc87a79b412bee38b1f0eb1e"
57
+ "gitHead": "e078f8371ae266f05c7ca1ec25686cc489c83f24"
61
58
  }
@@ -3,7 +3,7 @@
3
3
  * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
4
  * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
5
  */
6
- import '@vaadin/component-base/src/style-props.js';
6
+ import '@vaadin/component-base/src/styles/style-props.js';
7
7
  import { css } from 'lit';
8
8
  import { overlayStyles } from '@vaadin/overlay/src/styles/vaadin-overlay-base-styles.js';
9
9
 
@@ -29,16 +29,15 @@ export const dialogOverlayBase = css`
29
29
  }
30
30
 
31
31
  [part='overlay'] {
32
- background: var(--vaadin-dialog-background, var(--vaadin-background-color));
32
+ background: var(--vaadin-dialog-background, var(--vaadin-overlay-background, var(--vaadin-background-color)));
33
33
  background-origin: border-box;
34
- border: 0;
35
- box-shadow:
36
- 0 0 0 var(--vaadin-dialog-border-width, 1px) var(--vaadin-dialog-border-color, rgba(0, 0, 0, 0.1)),
37
- var(--vaadin-dialog-box-shadow, 0 8px 24px -4px rgba(0, 0, 0, 0.3));
34
+ border: var(--vaadin-dialog-border-width, var(--vaadin-overlay-border-width, 1px)) solid
35
+ var(--vaadin-dialog-border-color, var(--vaadin-overlay-border-color, var(--vaadin-border-color-secondary)));
36
+ box-shadow: var(--vaadin-dialog-shadow, var(--vaadin-overlay-shadow, 0 8px 24px -4px rgba(0, 0, 0, 0.3)));
38
37
  border-radius: var(--vaadin-dialog-border-radius, var(--vaadin-radius-l));
39
38
  width: max-content;
40
39
  min-width: min(var(--vaadin-dialog-min-width, 4em), 100%);
41
- max-width: var(--vaadin-dialog-max-width, 100%);
40
+ max-width: min(var(--vaadin-dialog-max-width, 100%), 100%);
42
41
  max-height: 100%;
43
42
  }
44
43
 
@@ -51,7 +50,7 @@ export const dialogOverlayBase = css`
51
50
  flex: none;
52
51
  pointer-events: none;
53
52
  z-index: 1;
54
- gap: var(--vaadin-dialog-toolbar-gap, var(--vaadin-gap-container-inline));
53
+ gap: var(--vaadin-dialog-toolbar-gap, var(--vaadin-gap-s));
55
54
  }
56
55
 
57
56
  ::slotted(*) {
@@ -61,7 +60,7 @@ export const dialogOverlayBase = css`
61
60
  [part='header'],
62
61
  [part='content'],
63
62
  [part='footer'] {
64
- padding: var(--vaadin-dialog-padding, var(--vaadin-padding));
63
+ padding: var(--vaadin-dialog-padding, var(--vaadin-padding-l));
65
64
  }
66
65
 
67
66
  :host([theme~='no-padding']) [part='content'] {
@@ -93,7 +92,7 @@ export const dialogOverlayBase = css`
93
92
  }
94
93
 
95
94
  [part='title'] {
96
- color: var(--vaadin-dialog-title-color, var(--vaadin-color));
95
+ color: var(--vaadin-dialog-title-color, var(--vaadin-text-color));
97
96
  font-weight: var(--vaadin-dialog-title-font-weight, 600);
98
97
  font-size: var(--vaadin-dialog-title-font-size, 1em);
99
98
  line-height: var(--vaadin-dialog-title-line-height, inherit);
@@ -11,7 +11,7 @@ export declare function DialogBaseMixin<T extends Constructor<HTMLElement>>(
11
11
 
12
12
  export declare class DialogBaseMixinClass {
13
13
  /**
14
- * True if the overlay is currently displayed.
14
+ * True if the dialog is visible and available for interaction.
15
15
  */
16
16
  opened: boolean;
17
17
 
@@ -36,26 +36,25 @@ export declare class DialogBaseMixinClass {
36
36
  * The `role` attribute value to be set on the dialog. Defaults to "dialog".
37
37
  *
38
38
  * @attr {string} overlay-role
39
+ * @deprecated Use standard `role` attribute on the dialog instead
39
40
  */
40
41
  overlayRole: string;
41
42
 
42
43
  /**
43
- * Set the distance of the overlay from the top of its container.
44
+ * Set the distance of the dialog from the top of the viewport.
44
45
  * If a unitless number is provided, pixels are assumed.
45
46
  *
46
- * Note that the overlay top edge may not be the same as the viewport
47
- * top edge (e.g. the Lumo theme defines some spacing to prevent the
48
- * overlay from stretching all the way to the top of the viewport).
47
+ * Note that the dialog uses an internal container that has some
48
+ * additional spacing, which can be overridden by the theme.
49
49
  */
50
50
  top: string;
51
51
 
52
52
  /**
53
- * Set the distance of the overlay from the left of its container.
53
+ * Set the distance of the dialog from the left of the viewport.
54
54
  * If a unitless number is provided, pixels are assumed.
55
55
  *
56
- * Note that the overlay left edge may not be the same as the viewport
57
- * left edge (e.g. the Lumo theme defines some spacing to prevent the
58
- * overlay from stretching all the way to the left of the viewport).
56
+ * Note that the dialog uses an internal container that has some
57
+ * additional spacing, which can be overridden by the theme.
59
58
  */
60
59
  left: string;
61
60
  }
@@ -12,7 +12,7 @@ export const DialogBaseMixin = (superClass) =>
12
12
  static get properties() {
13
13
  return {
14
14
  /**
15
- * True if the overlay is currently displayed.
15
+ * True if the dialog is visible and available for interaction.
16
16
  * @type {boolean}
17
17
  */
18
18
  opened: {
@@ -53,24 +53,22 @@ export const DialogBaseMixin = (superClass) =>
53
53
  },
54
54
 
55
55
  /**
56
- * Set the distance of the overlay from the top of its container.
56
+ * Set the distance of the dialog from the top of the viewport.
57
57
  * If a unitless number is provided, pixels are assumed.
58
58
  *
59
- * Note that the overlay top edge may not be the same as the viewport
60
- * top edge (e.g. the Lumo theme defines some spacing to prevent the
61
- * overlay from stretching all the way to the top of the viewport).
59
+ * Note that the dialog uses an internal container that has some
60
+ * additional spacing, which can be overridden by the theme.
62
61
  */
63
62
  top: {
64
63
  type: String,
65
64
  },
66
65
 
67
66
  /**
68
- * Set the distance of the overlay from the left of its container.
67
+ * Set the distance of the dialog from the left of the viewport.
69
68
  * If a unitless number is provided, pixels are assumed.
70
69
  *
71
- * Note that the overlay left edge may not be the same as the viewport
72
- * left edge (e.g. the Lumo theme defines some spacing to prevent the
73
- * overlay from stretching all the way to the left of the viewport).
70
+ * Note that the dialog uses an internal container that has some
71
+ * additional spacing, which can be overridden by the theme.
74
72
  */
75
73
  left: {
76
74
  type: String,
@@ -80,6 +78,7 @@ export const DialogBaseMixin = (superClass) =>
80
78
  * The `role` attribute value to be set on the dialog. Defaults to "dialog".
81
79
  *
82
80
  * @attr {string} overlay-role
81
+ * @deprecated Use standard `role` attribute on the dialog instead
83
82
  */
84
83
  overlayRole: {
85
84
  type: String,
@@ -106,6 +105,8 @@ export const DialogBaseMixin = (superClass) =>
106
105
  if (!this.hasAttribute('role')) {
107
106
  this.role = 'dialog';
108
107
  }
108
+
109
+ this.setAttribute('tabindex', '0');
109
110
  }
110
111
 
111
112
  /** @protected */
@@ -115,6 +116,14 @@ export const DialogBaseMixin = (superClass) =>
115
116
  if (props.has('overlayRole')) {
116
117
  this.role = this.overlayRole || 'dialog';
117
118
  }
119
+
120
+ if (props.has('modeless')) {
121
+ if (!this.modeless) {
122
+ this.setAttribute('aria-modal', 'true');
123
+ } else {
124
+ this.removeAttribute('aria-modal');
125
+ }
126
+ }
118
127
  }
119
128
 
120
129
  /** @private */
@@ -95,7 +95,8 @@ export const DialogDraggableMixin = (superClass) =>
95
95
  window.addEventListener('touchmove', this._drag);
96
96
  if (this.$.overlay.$.overlay.style.position !== 'absolute') {
97
97
  const { top, left } = this._originalBounds;
98
- this.$.overlay.setBounds({ top, left });
98
+ this.top = top;
99
+ this.left = left;
99
100
  }
100
101
  }
101
102
  }
@@ -54,12 +54,19 @@ export const DialogOverlayMixin = (superClass) =>
54
54
  }
55
55
 
56
56
  /**
57
- * Override method from OverlayFocusMixin to use owner as modal root
57
+ * Override method from OverlayMixin to use slotted div as a renderer root.
58
58
  * @protected
59
59
  * @override
60
60
  */
61
- get _modalRoot() {
62
- return this.owner;
61
+ get _rendererRoot() {
62
+ if (!this.__savedRoot) {
63
+ const root = document.createElement('vaadin-dialog-content');
64
+ root.style.display = 'contents';
65
+ this.owner.appendChild(root);
66
+ this.__savedRoot = root;
67
+ }
68
+
69
+ return this.__savedRoot;
63
70
  }
64
71
 
65
72
  /** @protected */
@@ -68,7 +75,9 @@ export const DialogOverlayMixin = (superClass) =>
68
75
 
69
76
  // Update overflow attribute on resize
70
77
  this.__resizeObserver = new ResizeObserver(() => {
71
- this.__updateOverflow();
78
+ requestAnimationFrame(() => {
79
+ this.__updateOverflow();
80
+ });
72
81
  });
73
82
  this.__resizeObserver.observe(this.$.resizerContainer);
74
83
 
@@ -76,11 +85,16 @@ export const DialogOverlayMixin = (superClass) =>
76
85
  this.$.content.addEventListener('scroll', () => {
77
86
  this.__updateOverflow();
78
87
  });
88
+
89
+ // Update overflow attribute on content change
90
+ this.shadowRoot.addEventListener('slotchange', () => {
91
+ this.__updateOverflow();
92
+ });
79
93
  }
80
94
 
81
95
  /** @private */
82
96
  __createContainer(slot) {
83
- const container = document.createElement('div');
97
+ const container = document.createElement('vaadin-dialog-content');
84
98
  container.setAttribute('slot', slot);
85
99
  return container;
86
100
  }
@@ -100,8 +114,9 @@ export const DialogOverlayMixin = (superClass) =>
100
114
  // Reset existing container in case if a new renderer is set.
101
115
  this.__clearContainer(container);
102
116
  } else {
103
- // Create the container, but wait to append it until requestContentUpdate is called.
117
+ // Create the container and append it to the dialog element.
104
118
  container = this.__createContainer(slot);
119
+ this.owner.appendChild(container);
105
120
  }
106
121
  return container;
107
122
  }
@@ -183,28 +198,12 @@ export const DialogOverlayMixin = (superClass) =>
183
198
  requestContentUpdate() {
184
199
  super.requestContentUpdate();
185
200
 
186
- if (this.headerContainer) {
187
- // If a new renderer has been set, make sure to reattach the container
188
- if (!this.headerContainer.parentElement) {
189
- this.owner.appendChild(this.headerContainer);
190
- }
191
-
192
- if (this.headerRenderer) {
193
- // Only call header renderer after the container has been initialized
194
- this.headerRenderer.call(this.owner, this.headerContainer, this.owner);
195
- }
201
+ if (this.headerContainer && this.headerRenderer) {
202
+ this.headerRenderer.call(this.owner, this.headerContainer, this.owner);
196
203
  }
197
204
 
198
- if (this.footerContainer) {
199
- // If a new renderer has been set, make sure to reattach the container
200
- if (!this.footerContainer.parentElement) {
201
- this.owner.appendChild(this.footerContainer);
202
- }
203
-
204
- if (this.footerRenderer) {
205
- // Only call header renderer after the container has been initialized
206
- this.footerRenderer.call(this.owner, this.footerContainer, this.owner);
207
- }
205
+ if (this.footerContainer && this.footerRenderer) {
206
+ this.footerRenderer.call(this.owner, this.footerContainer, this.owner);
208
207
  }
209
208
 
210
209
  this._headerTitleRenderer();
@@ -230,18 +229,14 @@ export const DialogOverlayMixin = (superClass) =>
230
229
  __updateOverflow() {
231
230
  let overflow = '';
232
231
 
233
- // Only set "overflow" attribute if the dialog has a header, title or footer.
234
- // Check for state attributes as extending components might not use renderers.
235
- if (this.hasAttribute('has-header') || this.hasAttribute('has-footer') || this.headerTitle) {
236
- const content = this.$.content;
232
+ const content = this.$.content;
237
233
 
238
- if (content.scrollTop > 0) {
239
- overflow += ' top';
240
- }
234
+ if (content.scrollTop > 0) {
235
+ overflow += ' top';
236
+ }
241
237
 
242
- if (content.scrollTop < content.scrollHeight - content.clientHeight) {
243
- overflow += ' bottom';
244
- }
238
+ if (content.scrollTop < content.scrollHeight - content.clientHeight) {
239
+ overflow += ' bottom';
245
240
  }
246
241
 
247
242
  const value = overflow.trim();
@@ -9,7 +9,7 @@ import { DirMixin } from '@vaadin/component-base/src/dir-mixin.js';
9
9
  import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
10
10
  import { LumoInjectionMixin } from '@vaadin/vaadin-themable-mixin/lumo-injection-mixin.js';
11
11
  import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
12
- import { dialogOverlayStyles } from './styles/vaadin-dialog-overlay-core-styles.js';
12
+ import { dialogOverlayStyles } from './styles/vaadin-dialog-overlay-base-styles.js';
13
13
  import { DialogOverlayMixin } from './vaadin-dialog-overlay-mixin.js';
14
14
 
15
15
  /**
@@ -33,11 +33,20 @@ export class DialogOverlay extends DialogOverlayMixin(
33
33
  return dialogOverlayStyles;
34
34
  }
35
35
 
36
+ /**
37
+ * Override method from OverlayFocusMixin to use owner as focus trap root
38
+ * @protected
39
+ * @override
40
+ */
41
+ get _focusTrapRoot() {
42
+ return this.owner;
43
+ }
44
+
36
45
  /** @protected */
37
46
  render() {
38
47
  return html`
39
48
  <div id="backdrop" part="backdrop" ?hidden="${!this.withBackdrop}"></div>
40
- <div part="overlay" id="overlay" tabindex="0">
49
+ <div part="overlay" id="overlay">
41
50
  <section id="resizerContainer" class="resizer-container">
42
51
  <header part="header">
43
52
  <div part="title"><slot name="title"></slot></div>
@@ -27,7 +27,7 @@ export declare class DialogRendererMixinClass {
27
27
  * and the elements created by the renderer will be placed next to
28
28
  * each other, with the title coming first.
29
29
  *
30
- * When `headerTitle` is set, the attribute `has-title` is added to the overlay element.
30
+ * When `headerTitle` is set, the attribute `has-title` is set on the dialog.
31
31
  * @attr {string} header-title
32
32
  */
33
33
  headerTitle: string | null | undefined;
@@ -43,7 +43,7 @@ export declare class DialogRendererMixinClass {
43
43
  * and the elements created by the renderer will be placed next to
44
44
  * each other, with the title coming first.
45
45
  *
46
- * When `headerRenderer` is set, the attribute `has-header` is added to the overlay element.
46
+ * When `headerRenderer` is set, the attribute `has-header` is set on the dialog.
47
47
  */
48
48
  headerRenderer: DialogRenderer | null | undefined;
49
49
 
@@ -54,7 +54,7 @@ export declare class DialogRendererMixinClass {
54
54
  * - `root` The root container DOM element. Append your content to it.
55
55
  * - `dialog` The reference to the `<vaadin-dialog>` element.
56
56
  *
57
- * When `footerRenderer` is set, the attribute `has-footer` is added to the overlay element.
57
+ * When `footerRenderer` is set, the attribute `has-footer` is set on the dialog.
58
58
  */
59
59
  footerRenderer: DialogRenderer | null | undefined;
60
60
 
@@ -30,7 +30,7 @@ export const DialogRendererMixin = (superClass) =>
30
30
  * and the elements created by the renderer will be placed next to
31
31
  * each other, with the title coming first.
32
32
  *
33
- * When `headerTitle` is set, the attribute `has-title` is added to the overlay element.
33
+ * When `headerTitle` is set, the attribute `has-title` is set on the dialog.
34
34
  * @attr {string} header-title
35
35
  */
36
36
  headerTitle: String,
@@ -46,7 +46,7 @@ export const DialogRendererMixin = (superClass) =>
46
46
  * and the elements created by the renderer will be placed next to
47
47
  * each other, with the title coming first.
48
48
  *
49
- * When `headerRenderer` is set, the attribute `has-header` is added to the overlay element.
49
+ * When `headerRenderer` is set, the attribute `has-header` is set on the dialog.
50
50
  * @type {DialogRenderer | undefined}
51
51
  */
52
52
  headerRenderer: {
@@ -60,7 +60,7 @@ export const DialogRendererMixin = (superClass) =>
60
60
  * - `root` The root container DOM element. Append your content to it.
61
61
  * - `dialog` The reference to the `<vaadin-dialog>` element.
62
62
  *
63
- * When `footerRenderer` is set, the attribute `has-footer` is added to the overlay element.
63
+ * When `footerRenderer` is set, the attribute `has-footer` is set on the dialog.
64
64
  * @type {DialogRenderer | undefined}
65
65
  */
66
66
  footerRenderer: {
@@ -11,13 +11,13 @@ export declare function DialogSizeMixin<T extends Constructor<HTMLElement>>(
11
11
 
12
12
  export declare class DialogSizeMixinClass {
13
13
  /**
14
- * Set the width of the overlay.
14
+ * Set the width of the dialog.
15
15
  * If a unitless number is provided, pixels are assumed.
16
16
  */
17
17
  width: string | null;
18
18
 
19
19
  /**
20
- * Set the height of the overlay.
20
+ * Set the height of the dialog.
21
21
  * If a unitless number is provided, pixels are assumed.
22
22
  */
23
23
  height: string | null;
@@ -12,7 +12,7 @@ export const DialogSizeMixin = (superClass) =>
12
12
  static get properties() {
13
13
  return {
14
14
  /**
15
- * Set the width of the overlay.
15
+ * Set the width of the dialog.
16
16
  * If a unitless number is provided, pixels are assumed.
17
17
  */
18
18
  width: {
@@ -20,7 +20,7 @@ export const DialogSizeMixin = (superClass) =>
20
20
  },
21
21
 
22
22
  /**
23
- * Set the height of the overlay.
23
+ * Set the height of the dialog.
24
24
  * If a unitless number is provided, pixels are assumed.
25
25
  */
26
26
  height: {
@@ -4,7 +4,6 @@
4
4
  * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
5
  */
6
6
  import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
7
- import { OverlayClassMixin } from '@vaadin/component-base/src/overlay-class-mixin.js';
8
7
  import { ThemePropertyMixin } from '@vaadin/vaadin-themable-mixin/vaadin-theme-property-mixin.js';
9
8
  import { DialogBaseMixin } from './vaadin-dialog-base-mixin.js';
10
9
  import { DialogDraggableMixin } from './vaadin-dialog-draggable-mixin.js';
@@ -121,9 +120,7 @@ export type DialogEventMap = DialogCustomEventMap & HTMLElementEventMap;
121
120
  */
122
121
  declare class Dialog extends DialogSizeMixin(
123
122
  DialogDraggableMixin(
124
- DialogResizableMixin(
125
- DialogRendererMixin(DialogBaseMixin(OverlayClassMixin(ThemePropertyMixin(ElementMixin(HTMLElement))))),
126
- ),
123
+ DialogResizableMixin(DialogRendererMixin(DialogBaseMixin(ThemePropertyMixin(ElementMixin(HTMLElement))))),
127
124
  ),
128
125
  ) {
129
126
  addEventListener<K extends keyof DialogEventMap>(
@@ -8,7 +8,6 @@ import { css, html, LitElement } from 'lit';
8
8
  import { ifDefined } from 'lit/directives/if-defined.js';
9
9
  import { defineCustomElement } from '@vaadin/component-base/src/define.js';
10
10
  import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
11
- import { OverlayClassMixin } from '@vaadin/component-base/src/overlay-class-mixin.js';
12
11
  import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
13
12
  import { ThemePropertyMixin } from '@vaadin/vaadin-themable-mixin/vaadin-theme-property-mixin.js';
14
13
  import { DialogBaseMixin } from './vaadin-dialog-base-mixin.js';
@@ -85,14 +84,11 @@ export { DialogOverlay } from './vaadin-dialog-overlay.js';
85
84
  * @mixes DialogRendererMixin
86
85
  * @mixes DialogResizableMixin
87
86
  * @mixes DialogSizeMixin
88
- * @mixes OverlayClassMixin
89
87
  */
90
88
  class Dialog extends DialogSizeMixin(
91
89
  DialogDraggableMixin(
92
90
  DialogResizableMixin(
93
- DialogRendererMixin(
94
- DialogBaseMixin(OverlayClassMixin(ThemePropertyMixin(ElementMixin(PolylitMixin(LitElement))))),
95
- ),
91
+ DialogRendererMixin(DialogBaseMixin(ThemePropertyMixin(ElementMixin(PolylitMixin(LitElement))))),
96
92
  ),
97
93
  ),
98
94
  ) {
@@ -105,13 +101,19 @@ class Dialog extends DialogSizeMixin(
105
101
  :host([opened]),
106
102
  :host([opening]),
107
103
  :host([closing]) {
108
- display: contents !important;
104
+ display: block !important;
105
+ position: absolute;
106
+ outline: none;
109
107
  }
110
108
 
111
109
  :host,
112
110
  :host([hidden]) {
113
111
  display: none !important;
114
112
  }
113
+
114
+ :host(:focus-visible) ::part(overlay) {
115
+ outline: var(--vaadin-focus-ring-width) solid var(--vaadin-focus-ring-color);
116
+ }
115
117
  `;
116
118
  }
117
119
 
package/vaadin-dialog.js CHANGED
@@ -1,2 +1,2 @@
1
- import './theme/lumo/vaadin-dialog.js';
1
+ import './src/vaadin-dialog.js';
2
2
  export * from './src/vaadin-dialog.js';
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/dialog",
4
- "version": "25.0.0-alpha9",
4
+ "version": "25.0.0-beta2",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -12,7 +12,7 @@
12
12
  "attributes": [
13
13
  {
14
14
  "name": "opened",
15
- "description": "True if the overlay is currently displayed.",
15
+ "description": "True if the dialog is visible and available for interaction.",
16
16
  "value": {
17
17
  "type": [
18
18
  "boolean"
@@ -48,7 +48,7 @@
48
48
  },
49
49
  {
50
50
  "name": "top",
51
- "description": "Set the distance of the overlay from the top of its container.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the overlay top edge may not be the same as the viewport\ntop edge (e.g. the Lumo theme defines some spacing to prevent the\noverlay from stretching all the way to the top of the viewport).",
51
+ "description": "Set the distance of the dialog from the top of the viewport.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the dialog uses an internal container that has some\nadditional spacing, which can be overridden by the theme.",
52
52
  "value": {
53
53
  "type": [
54
54
  "string",
@@ -59,7 +59,7 @@
59
59
  },
60
60
  {
61
61
  "name": "left",
62
- "description": "Set the distance of the overlay from the left of its container.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the overlay left edge may not be the same as the viewport\nleft edge (e.g. the Lumo theme defines some spacing to prevent the\noverlay from stretching all the way to the left of the viewport).",
62
+ "description": "Set the distance of the dialog from the left of the viewport.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the dialog uses an internal container that has some\nadditional spacing, which can be overridden by the theme.",
63
63
  "value": {
64
64
  "type": [
65
65
  "string",
@@ -90,7 +90,7 @@
90
90
  },
91
91
  {
92
92
  "name": "header-title",
93
- "description": "String used for rendering a dialog title.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerTitle` is set, the attribute `has-title` is added to the overlay element.",
93
+ "description": "String used for rendering a dialog title.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerTitle` is set, the attribute `has-title` is set on the dialog.",
94
94
  "value": {
95
95
  "type": [
96
96
  "string",
@@ -110,7 +110,7 @@
110
110
  },
111
111
  {
112
112
  "name": "width",
113
- "description": "Set the width of the overlay.\nIf a unitless number is provided, pixels are assumed.",
113
+ "description": "Set the width of the dialog.\nIf a unitless number is provided, pixels are assumed.",
114
114
  "value": {
115
115
  "type": [
116
116
  "string",
@@ -121,18 +121,7 @@
121
121
  },
122
122
  {
123
123
  "name": "height",
124
- "description": "Set the height of the overlay.\nIf a unitless number is provided, pixels are assumed.",
125
- "value": {
126
- "type": [
127
- "string",
128
- "null",
129
- "undefined"
130
- ]
131
- }
132
- },
133
- {
134
- "name": "overlay-class",
135
- "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.",
124
+ "description": "Set the height of the dialog.\nIf a unitless number is provided, pixels are assumed.",
136
125
  "value": {
137
126
  "type": [
138
127
  "string",
@@ -157,7 +146,7 @@
157
146
  "properties": [
158
147
  {
159
148
  "name": "opened",
160
- "description": "True if the overlay is currently displayed.",
149
+ "description": "True if the dialog is visible and available for interaction.",
161
150
  "value": {
162
151
  "type": [
163
152
  "boolean"
@@ -193,7 +182,7 @@
193
182
  },
194
183
  {
195
184
  "name": "top",
196
- "description": "Set the distance of the overlay from the top of its container.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the overlay top edge may not be the same as the viewport\ntop edge (e.g. the Lumo theme defines some spacing to prevent the\noverlay from stretching all the way to the top of the viewport).",
185
+ "description": "Set the distance of the dialog from the top of the viewport.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the dialog uses an internal container that has some\nadditional spacing, which can be overridden by the theme.",
197
186
  "value": {
198
187
  "type": [
199
188
  "string",
@@ -204,7 +193,7 @@
204
193
  },
205
194
  {
206
195
  "name": "left",
207
- "description": "Set the distance of the overlay from the left of its container.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the overlay left edge may not be the same as the viewport\nleft edge (e.g. the Lumo theme defines some spacing to prevent the\noverlay from stretching all the way to the left of the viewport).",
196
+ "description": "Set the distance of the dialog from the left of the viewport.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the dialog uses an internal container that has some\nadditional spacing, which can be overridden by the theme.",
208
197
  "value": {
209
198
  "type": [
210
199
  "string",
@@ -245,7 +234,7 @@
245
234
  },
246
235
  {
247
236
  "name": "headerTitle",
248
- "description": "String used for rendering a dialog title.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerTitle` is set, the attribute `has-title` is added to the overlay element.",
237
+ "description": "String used for rendering a dialog title.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerTitle` is set, the attribute `has-title` is set on the dialog.",
249
238
  "value": {
250
239
  "type": [
251
240
  "string",
@@ -256,7 +245,7 @@
256
245
  },
257
246
  {
258
247
  "name": "headerRenderer",
259
- "description": "Custom function for rendering the dialog header.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerRenderer` is set, the attribute `has-header` is added to the overlay element.",
248
+ "description": "Custom function for rendering the dialog header.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerRenderer` is set, the attribute `has-header` is set on the dialog.",
260
249
  "value": {
261
250
  "type": [
262
251
  "DialogRenderer",
@@ -266,7 +255,7 @@
266
255
  },
267
256
  {
268
257
  "name": "footerRenderer",
269
- "description": "Custom function for rendering the dialog footer.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nWhen `footerRenderer` is set, the attribute `has-footer` is added to the overlay element.",
258
+ "description": "Custom function for rendering the dialog footer.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nWhen `footerRenderer` is set, the attribute `has-footer` is set on the dialog.",
270
259
  "value": {
271
260
  "type": [
272
261
  "DialogRenderer",
@@ -285,7 +274,7 @@
285
274
  },
286
275
  {
287
276
  "name": "width",
288
- "description": "Set the width of the overlay.\nIf a unitless number is provided, pixels are assumed.",
277
+ "description": "Set the width of the dialog.\nIf a unitless number is provided, pixels are assumed.",
289
278
  "value": {
290
279
  "type": [
291
280
  "string",
@@ -296,18 +285,7 @@
296
285
  },
297
286
  {
298
287
  "name": "height",
299
- "description": "Set the height of the overlay.\nIf a unitless number is provided, pixels are assumed.",
300
- "value": {
301
- "type": [
302
- "string",
303
- "null",
304
- "undefined"
305
- ]
306
- }
307
- },
308
- {
309
- "name": "overlayClass",
310
- "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.",
288
+ "description": "Set the height of the dialog.\nIf a unitless number is provided, pixels are assumed.",
311
289
  "value": {
312
290
  "type": [
313
291
  "string",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/dialog",
4
- "version": "25.0.0-alpha9",
4
+ "version": "25.0.0-beta2",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {
@@ -21,7 +21,7 @@
21
21
  "attributes": [
22
22
  {
23
23
  "name": "?opened",
24
- "description": "True if the overlay is currently displayed.",
24
+ "description": "True if the dialog is visible and available for interaction.",
25
25
  "value": {
26
26
  "kind": "expression"
27
27
  }
@@ -63,14 +63,14 @@
63
63
  },
64
64
  {
65
65
  "name": ".top",
66
- "description": "Set the distance of the overlay from the top of its container.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the overlay top edge may not be the same as the viewport\ntop edge (e.g. the Lumo theme defines some spacing to prevent the\noverlay from stretching all the way to the top of the viewport).",
66
+ "description": "Set the distance of the dialog from the top of the viewport.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the dialog uses an internal container that has some\nadditional spacing, which can be overridden by the theme.",
67
67
  "value": {
68
68
  "kind": "expression"
69
69
  }
70
70
  },
71
71
  {
72
72
  "name": ".left",
73
- "description": "Set the distance of the overlay from the left of its container.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the overlay left edge may not be the same as the viewport\nleft edge (e.g. the Lumo theme defines some spacing to prevent the\noverlay from stretching all the way to the left of the viewport).",
73
+ "description": "Set the distance of the dialog from the left of the viewport.\nIf a unitless number is provided, pixels are assumed.\n\nNote that the dialog uses an internal container that has some\nadditional spacing, which can be overridden by the theme.",
74
74
  "value": {
75
75
  "kind": "expression"
76
76
  }
@@ -91,42 +91,35 @@
91
91
  },
92
92
  {
93
93
  "name": ".headerTitle",
94
- "description": "String used for rendering a dialog title.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerTitle` is set, the attribute `has-title` is added to the overlay element.",
94
+ "description": "String used for rendering a dialog title.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerTitle` is set, the attribute `has-title` is set on the dialog.",
95
95
  "value": {
96
96
  "kind": "expression"
97
97
  }
98
98
  },
99
99
  {
100
100
  "name": ".headerRenderer",
101
- "description": "Custom function for rendering the dialog header.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerRenderer` is set, the attribute `has-header` is added to the overlay element.",
101
+ "description": "Custom function for rendering the dialog header.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nIf both `headerTitle` and `headerRenderer` are defined, the title\nand the elements created by the renderer will be placed next to\neach other, with the title coming first.\n\nWhen `headerRenderer` is set, the attribute `has-header` is set on the dialog.",
102
102
  "value": {
103
103
  "kind": "expression"
104
104
  }
105
105
  },
106
106
  {
107
107
  "name": ".footerRenderer",
108
- "description": "Custom function for rendering the dialog footer.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nWhen `footerRenderer` is set, the attribute `has-footer` is added to the overlay element.",
108
+ "description": "Custom function for rendering the dialog footer.\nReceives two arguments:\n\n- `root` The root container DOM element. Append your content to it.\n- `dialog` The reference to the `<vaadin-dialog>` element.\n\nWhen `footerRenderer` is set, the attribute `has-footer` is set on the dialog.",
109
109
  "value": {
110
110
  "kind": "expression"
111
111
  }
112
112
  },
113
113
  {
114
114
  "name": ".width",
115
- "description": "Set the width of the overlay.\nIf a unitless number is provided, pixels are assumed.",
115
+ "description": "Set the width of the dialog.\nIf a unitless number is provided, pixels are assumed.",
116
116
  "value": {
117
117
  "kind": "expression"
118
118
  }
119
119
  },
120
120
  {
121
121
  "name": ".height",
122
- "description": "Set the height of the overlay.\nIf a unitless number is provided, pixels are assumed.",
123
- "value": {
124
- "kind": "expression"
125
- }
126
- },
127
- {
128
- "name": ".overlayClass",
129
- "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.",
122
+ "description": "Set the height of the dialog.\nIf a unitless number is provided, pixels are assumed.",
130
123
  "value": {
131
124
  "kind": "expression"
132
125
  }
@@ -1,10 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2021 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import type { CSSResult } from 'lit';
7
-
8
- export const dialogOverlayBase: CSSResult;
9
-
10
- export const dialogOverlayStyles: CSSResult;
@@ -1,184 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
- * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
- */
6
- import { css } from 'lit';
7
- import { overlayStyles } from '@vaadin/overlay/src/styles/vaadin-overlay-core-styles.js';
8
-
9
- export const dialogOverlayBase = css`
10
- [part='header'],
11
- [part='header-content'],
12
- [part='footer'] {
13
- display: flex;
14
- align-items: center;
15
- flex-wrap: wrap;
16
- flex: none;
17
- pointer-events: none;
18
- z-index: 1;
19
- }
20
-
21
- [part='header'] {
22
- flex-wrap: nowrap;
23
- }
24
-
25
- ::slotted([slot='header-content']),
26
- ::slotted([slot='title']),
27
- ::slotted([slot='footer']) {
28
- display: contents;
29
- pointer-events: auto;
30
- }
31
-
32
- ::slotted([slot='title']) {
33
- font: inherit !important;
34
- overflow-wrap: anywhere;
35
- }
36
-
37
- [part='header-content'] {
38
- flex: 1;
39
- }
40
-
41
- :host([has-title]) [part='header-content'],
42
- [part='footer'] {
43
- justify-content: flex-end;
44
- }
45
-
46
- :host(:not([has-title]):not([has-header])) [part='header'],
47
- :host(:not([has-header])) [part='header-content'],
48
- :host(:not([has-title])) [part='title'],
49
- :host(:not([has-footer])) [part='footer'] {
50
- display: none !important;
51
- }
52
-
53
- :host(:is([has-title], [has-header], [has-footer])) [part='content'] {
54
- height: auto;
55
- }
56
-
57
- @media (min-height: 320px) {
58
- :host(:is([has-title], [has-header], [has-footer])) .resizer-container {
59
- overflow: hidden;
60
- display: flex;
61
- flex-direction: column;
62
- }
63
-
64
- :host(:is([has-title], [has-header], [has-footer])) [part='content'] {
65
- flex: 1;
66
- overflow: auto;
67
- }
68
- }
69
-
70
- /*
71
- NOTE(platosha): Make some min-width to prevent collapsing of the content
72
- taking the parent width, e. g., <vaadin-grid> and such.
73
- */
74
- [part='content'] {
75
- min-width: 12em; /* matches the default <vaadin-text-field> width */
76
- }
77
-
78
- :host([has-bounds-set]) [part='overlay'] {
79
- max-width: none;
80
- }
81
-
82
- @media (forced-colors: active) {
83
- [part='overlay'] {
84
- outline: 3px solid !important;
85
- }
86
- }
87
- `;
88
-
89
- const dialogResizableOverlay = css`
90
- [part='overlay'] {
91
- position: relative;
92
- overflow: visible;
93
- max-height: 100%;
94
- display: flex;
95
- }
96
-
97
- [part='content'] {
98
- box-sizing: border-box;
99
- height: 100%;
100
- }
101
-
102
- .resizer-container {
103
- overflow: auto;
104
- flex-grow: 1;
105
- border-radius: inherit; /* prevent child elements being drawn outside part=overlay */
106
- }
107
-
108
- [part='overlay'][style] .resizer-container {
109
- min-height: 100%;
110
- width: 100%;
111
- }
112
-
113
- :host(:not([resizable])) .resizer {
114
- display: none;
115
- }
116
-
117
- :host([resizable]) [part='title'] {
118
- cursor: move;
119
- -webkit-user-select: none;
120
- user-select: none;
121
- }
122
-
123
- .resizer {
124
- position: absolute;
125
- height: 16px;
126
- width: 16px;
127
- }
128
-
129
- .resizer.edge {
130
- height: 8px;
131
- width: 8px;
132
- inset: -4px;
133
- }
134
-
135
- .resizer.edge.n {
136
- width: auto;
137
- bottom: auto;
138
- cursor: ns-resize;
139
- }
140
-
141
- .resizer.ne {
142
- top: -4px;
143
- right: -4px;
144
- cursor: nesw-resize;
145
- }
146
-
147
- .resizer.edge.e {
148
- height: auto;
149
- left: auto;
150
- cursor: ew-resize;
151
- }
152
-
153
- .resizer.se {
154
- bottom: -4px;
155
- right: -4px;
156
- cursor: nwse-resize;
157
- }
158
-
159
- .resizer.edge.s {
160
- width: auto;
161
- top: auto;
162
- cursor: ns-resize;
163
- }
164
-
165
- .resizer.sw {
166
- bottom: -4px;
167
- left: -4px;
168
- cursor: nesw-resize;
169
- }
170
-
171
- .resizer.edge.w {
172
- height: auto;
173
- right: auto;
174
- cursor: ew-resize;
175
- }
176
-
177
- .resizer.nw {
178
- top: -4px;
179
- left: -4px;
180
- cursor: nwse-resize;
181
- }
182
- `;
183
-
184
- export const dialogOverlayStyles = [overlayStyles, dialogOverlayBase, dialogResizableOverlay];
@@ -1,3 +0,0 @@
1
- import '@vaadin/vaadin-lumo-styles/spacing.js';
2
- declare const dialogOverlay: import("lit").CSSResult;
3
- export { dialogOverlay };
@@ -1,109 +0,0 @@
1
- import '@vaadin/vaadin-lumo-styles/spacing.js';
2
- import { overlay } from '@vaadin/vaadin-lumo-styles/mixins/overlay.js';
3
- import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
4
-
5
- const dialogOverlay = css`
6
- /* Optical centering */
7
- :host::before,
8
- :host::after {
9
- content: '';
10
- flex-basis: 0;
11
- flex-grow: 1;
12
- }
13
-
14
- :host::after {
15
- flex-grow: 1.1;
16
- }
17
-
18
- [part='overlay'] {
19
- border-radius: var(--lumo-border-radius-l);
20
- box-shadow:
21
- 0 0 0 1px var(--lumo-shade-5pct),
22
- var(--lumo-box-shadow-xl);
23
- background-image: none;
24
- outline: none;
25
- -webkit-tap-highlight-color: transparent;
26
- }
27
-
28
- [part='content'] {
29
- padding: var(--lumo-space-l);
30
- }
31
-
32
- :host(:is([has-header], [has-title])) [part='header'] + [part='content'] {
33
- padding-top: 0;
34
- }
35
-
36
- [part='header'],
37
- [part='header-content'],
38
- [part='footer'] {
39
- gap: var(--lumo-space-xs) var(--lumo-space-s);
40
- line-height: var(--lumo-line-height-s);
41
- }
42
-
43
- [part='header'] {
44
- padding: var(--lumo-space-m);
45
- background-color: var(--lumo-base-color);
46
- border-radius: var(--lumo-border-radius-l) var(--lumo-border-radius-l) 0 0; /* Needed for Safari */
47
- }
48
-
49
- [part='footer'] {
50
- padding: var(--lumo-space-s) var(--lumo-space-m);
51
- background-color: var(--lumo-contrast-5pct);
52
- border-radius: 0 0 var(--lumo-border-radius-l) var(--lumo-border-radius-l); /* Needed for Safari */
53
- }
54
-
55
- [part='title'] {
56
- font-size: var(--lumo-font-size-xl);
57
- font-weight: 600;
58
- color: var(--lumo-header-text-color);
59
- margin-inline-start: calc(var(--lumo-space-l) - var(--lumo-space-m));
60
- }
61
-
62
- /* No padding */
63
- :host([theme~='no-padding']) [part='content'] {
64
- padding: 0 !important;
65
- }
66
-
67
- @media (min-height: 320px) {
68
- :host([overflow~='top']) [part='header'] {
69
- box-shadow: 0 1px 0 0 var(--lumo-contrast-10pct);
70
- }
71
- }
72
-
73
- /* Animations */
74
-
75
- :host([opening]),
76
- :host([closing]) {
77
- animation: 0.25s lumo-overlay-dummy-animation;
78
- }
79
-
80
- :host([opening]) [part='overlay'] {
81
- animation: 0.12s 0.05s vaadin-dialog-enter cubic-bezier(0.215, 0.61, 0.355, 1) both;
82
- }
83
-
84
- @keyframes vaadin-dialog-enter {
85
- 0% {
86
- opacity: 0;
87
- transform: scale(0.95);
88
- }
89
- }
90
-
91
- :host([closing]) [part='overlay'] {
92
- animation: 0.1s 0.03s vaadin-dialog-exit cubic-bezier(0.55, 0.055, 0.675, 0.19) both;
93
- }
94
-
95
- :host([closing]) [part='backdrop'] {
96
- animation-delay: 0.05s;
97
- }
98
-
99
- @keyframes vaadin-dialog-exit {
100
- 100% {
101
- opacity: 0;
102
- transform: scale(1.02);
103
- }
104
- }
105
- `;
106
-
107
- registerStyles('vaadin-dialog-overlay', [overlay, dialogOverlay], { moduleId: 'lumo-dialog' });
108
-
109
- export { dialogOverlay };
@@ -1,2 +0,0 @@
1
- import './vaadin-dialog-styles.js';
2
- import '../../src/vaadin-dialog.js';
@@ -1,2 +0,0 @@
1
- import './vaadin-dialog-styles.js';
2
- import '../../src/vaadin-dialog.js';