@vaadin/board 24.1.0-alpha9 → 24.1.0-beta1

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/board",
3
- "version": "24.1.0-alpha9",
3
+ "version": "24.1.0-beta1",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -39,7 +39,8 @@
39
39
  ],
40
40
  "dependencies": {
41
41
  "@polymer/polymer": "^3.0.0",
42
- "@vaadin/component-base": "24.1.0-alpha9"
42
+ "@vaadin/a11y-base": "24.1.0-beta1",
43
+ "@vaadin/component-base": "24.1.0-beta1"
43
44
  },
44
45
  "devDependencies": {
45
46
  "@esm-bundle/chai": "^4.3.4",
@@ -51,5 +52,5 @@
51
52
  "web-types.json",
52
53
  "web-types.lit.json"
53
54
  ],
54
- "gitHead": "db4fe44603a6702b85b0da2a6d033ddf8ffea5c4"
55
+ "gitHead": "f0ddb6576073a6af05ab29867bc5ec82e334f9d7"
55
56
  }
@@ -9,6 +9,7 @@
9
9
  * license.
10
10
  */
11
11
  import { html, PolymerElement } from '@polymer/polymer/polymer-element.js';
12
+ import { isElementHidden } from '@vaadin/a11y-base/src/focus-utils.js';
12
13
  import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
13
14
  import { ResizeMixin } from '@vaadin/component-base/src/resize-mixin.js';
14
15
 
@@ -232,12 +233,7 @@ class BoardRow extends ResizeMixin(ElementMixin(PolymerElement)) {
232
233
  _recalculateFlexBasis(forceResize) {
233
234
  const width = this.getBoundingClientRect().width;
234
235
  const breakpoints = this._measureBreakpointsInPx();
235
- if (
236
- forceResize ||
237
- width !== this._oldWidth ||
238
- breakpoints.smallSize !== this._oldBreakpoints.smallSize ||
239
- breakpoints.mediumSize !== this._oldBreakpoints.mediumSize
240
- ) {
236
+ if (forceResize || this._shouldRecalculate(width, breakpoints)) {
241
237
  const nodes = this.$.insertionPoint.assignedNodes({ flatten: true });
242
238
  const filteredNodes = nodes.filter((node) => node.nodeType === Node.ELEMENT_NODE);
243
239
  this._addStyleNames(width, breakpoints);
@@ -255,6 +251,19 @@ class BoardRow extends ResizeMixin(ElementMixin(PolymerElement)) {
255
251
  }
256
252
  }
257
253
 
254
+ /** @private */
255
+ _shouldRecalculate(width, breakpoints) {
256
+ // Should not recalculate if row is invisible
257
+ if (isElementHidden(this)) {
258
+ return false;
259
+ }
260
+ return (
261
+ width !== this._oldWidth ||
262
+ breakpoints.smallSize !== this._oldBreakpoints.smallSize ||
263
+ breakpoints.mediumSize !== this._oldBreakpoints.mediumSize
264
+ );
265
+ }
266
+
258
267
  /**
259
268
  * Measure the breakpoints in pixels.
260
269
  *
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/board",
4
- "version": "24.1.0-alpha9",
4
+ "version": "24.1.0-beta1",
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/board",
4
- "version": "24.1.0-alpha9",
4
+ "version": "24.1.0-beta1",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {