@vaadin/popover 25.0.0-alpha16 → 25.0.0-alpha18

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/popover",
3
- "version": "25.0.0-alpha16",
3
+ "version": "25.0.0-alpha18",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -36,23 +36,23 @@
36
36
  ],
37
37
  "dependencies": {
38
38
  "@open-wc/dedupe-mixin": "^1.3.0",
39
- "@vaadin/a11y-base": "25.0.0-alpha16",
40
- "@vaadin/component-base": "25.0.0-alpha16",
41
- "@vaadin/lit-renderer": "25.0.0-alpha16",
42
- "@vaadin/overlay": "25.0.0-alpha16",
43
- "@vaadin/vaadin-themable-mixin": "25.0.0-alpha16",
39
+ "@vaadin/a11y-base": "25.0.0-alpha18",
40
+ "@vaadin/component-base": "25.0.0-alpha18",
41
+ "@vaadin/lit-renderer": "25.0.0-alpha18",
42
+ "@vaadin/overlay": "25.0.0-alpha18",
43
+ "@vaadin/vaadin-themable-mixin": "25.0.0-alpha18",
44
44
  "lit": "^3.0.0"
45
45
  },
46
46
  "devDependencies": {
47
- "@vaadin/chai-plugins": "25.0.0-alpha16",
48
- "@vaadin/test-runner-commands": "25.0.0-alpha16",
47
+ "@vaadin/chai-plugins": "25.0.0-alpha18",
48
+ "@vaadin/test-runner-commands": "25.0.0-alpha18",
49
49
  "@vaadin/testing-helpers": "^2.0.0",
50
- "@vaadin/vaadin-lumo-styles": "25.0.0-alpha16",
51
- "sinon": "^18.0.0"
50
+ "@vaadin/vaadin-lumo-styles": "25.0.0-alpha18",
51
+ "sinon": "^21.0.0"
52
52
  },
53
53
  "web-types": [
54
54
  "web-types.json",
55
55
  "web-types.lit.json"
56
56
  ],
57
- "gitHead": "4b316158a4a4f702f032bc9940fc82f0faa840f4"
57
+ "gitHead": "cb5cafb5687a117ebead1b81e2116991cec13abe"
58
58
  }
@@ -85,7 +85,7 @@ const popoverOverlay = css`
85
85
  }
86
86
 
87
87
  :host([theme~='arrow']) {
88
- --_default-offset: calc(4px + var(--_arrow-size) / 2);
88
+ --_default-offset: var(--_arrow-size);
89
89
  }
90
90
 
91
91
  :host([theme~='arrow']) [part='arrow'] {
@@ -34,6 +34,12 @@ class PopoverOverlay extends PopoverOverlayMixin(
34
34
  return popoverOverlayStyles;
35
35
  }
36
36
 
37
+ static get lumoInjector() {
38
+ return {
39
+ includeBaseStyles: true,
40
+ };
41
+ }
42
+
37
43
  /** @protected */
38
44
  render() {
39
45
  return html`
@@ -228,7 +228,7 @@ class Popover extends PopoverPositionMixin(
228
228
  display: none !important;
229
229
  }
230
230
 
231
- :host(:focus) ::part(overlay) {
231
+ :host(:focus-visible) ::part(overlay) {
232
232
  outline: var(--vaadin-focus-ring-width) solid var(--vaadin-focus-ring-color);
233
233
  }
234
234
  `;
@@ -435,7 +435,7 @@ class Popover extends PopoverPositionMixin(
435
435
  }
436
436
 
437
437
  static get observers() {
438
- return ['__sizeChanged(width, height, _overlayElement)', '__updateAriaAttributes(opened, role, target)'];
438
+ return ['__updateAriaAttributes(opened, role, target)'];
439
439
  }
440
440
 
441
441
  /**
@@ -572,6 +572,11 @@ class Popover extends PopoverPositionMixin(
572
572
  updated(props) {
573
573
  super.updated(props);
574
574
 
575
+ if (props.has('width') || props.has('height')) {
576
+ const { width, height } = this;
577
+ requestAnimationFrame(() => this.$.overlay.setBounds({ width, height }, false));
578
+ }
579
+
575
580
  if (props.has('accessibleName')) {
576
581
  if (this.accessibleName) {
577
582
  this.setAttribute('aria-label', this.accessibleName);
@@ -1019,13 +1024,6 @@ class Popover extends PopoverPositionMixin(
1019
1024
  return Array.isArray(this.trigger) && this.trigger.includes(trigger);
1020
1025
  }
1021
1026
 
1022
- /** @private */
1023
- __sizeChanged(width, height, overlay) {
1024
- if (overlay) {
1025
- requestAnimationFrame(() => overlay.setBounds({ width, height }, false));
1026
- }
1027
- }
1028
-
1029
1027
  /**
1030
1028
  * Fired when the popover is closed.
1031
1029
  *
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/popover",
4
- "version": "25.0.0-alpha16",
4
+ "version": "25.0.0-alpha18",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/popover",
4
- "version": "25.0.0-alpha16",
4
+ "version": "25.0.0-alpha18",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {