@vaadin/checkbox-group 24.2.0-alpha4 → 24.2.0-alpha6

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/checkbox-group",
3
- "version": "24.2.0-alpha4",
3
+ "version": "24.2.0-alpha6",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -36,22 +36,22 @@
36
36
  ],
37
37
  "dependencies": {
38
38
  "@polymer/polymer": "^3.0.0",
39
- "@vaadin/a11y-base": "24.2.0-alpha4",
40
- "@vaadin/checkbox": "24.2.0-alpha4",
41
- "@vaadin/component-base": "24.2.0-alpha4",
42
- "@vaadin/field-base": "24.2.0-alpha4",
43
- "@vaadin/vaadin-lumo-styles": "24.2.0-alpha4",
44
- "@vaadin/vaadin-material-styles": "24.2.0-alpha4",
45
- "@vaadin/vaadin-themable-mixin": "24.2.0-alpha4"
39
+ "@vaadin/a11y-base": "24.2.0-alpha6",
40
+ "@vaadin/checkbox": "24.2.0-alpha6",
41
+ "@vaadin/component-base": "24.2.0-alpha6",
42
+ "@vaadin/field-base": "24.2.0-alpha6",
43
+ "@vaadin/vaadin-lumo-styles": "24.2.0-alpha6",
44
+ "@vaadin/vaadin-material-styles": "24.2.0-alpha6",
45
+ "@vaadin/vaadin-themable-mixin": "24.2.0-alpha6"
46
46
  },
47
47
  "devDependencies": {
48
48
  "@esm-bundle/chai": "^4.3.4",
49
- "@vaadin/testing-helpers": "^0.4.2",
49
+ "@vaadin/testing-helpers": "^0.4.3",
50
50
  "sinon": "^13.0.2"
51
51
  },
52
52
  "web-types": [
53
53
  "web-types.json",
54
54
  "web-types.lit.json"
55
55
  ],
56
- "gitHead": "aaf7c5ebfea62628210eead4229be1718ac6b129"
56
+ "gitHead": "3ef6e6cd66919b3ef7637e42916e4c54656beb51"
57
57
  }
@@ -3,12 +3,12 @@
3
3
  * Copyright (c) 2018 - 2023 Vaadin Ltd.
4
4
  * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
5
  */
6
- import { FlattenedNodesObserver } from '@polymer/polymer/lib/utils/flattened-nodes-observer.js';
7
6
  import { html, PolymerElement } from '@polymer/polymer/polymer-element.js';
8
7
  import { DisabledMixin } from '@vaadin/a11y-base/src/disabled-mixin.js';
9
8
  import { FocusMixin } from '@vaadin/a11y-base/src/focus-mixin.js';
10
9
  import { Checkbox } from '@vaadin/checkbox/src/vaadin-checkbox.js';
11
10
  import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
11
+ import { SlotObserver } from '@vaadin/component-base/src/slot-observer.js';
12
12
  import { TooltipController } from '@vaadin/component-base/src/tooltip-controller.js';
13
13
  import { FieldMixin } from '@vaadin/field-base/src/field-mixin.js';
14
14
  import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
@@ -90,6 +90,11 @@ class CheckboxGroup extends FieldMixin(FocusMixin(DisabledMixin(ElementMixin(The
90
90
  width: 100%;
91
91
  }
92
92
 
93
+ [part='group-field'] {
94
+ display: flex;
95
+ flex-wrap: wrap;
96
+ }
97
+
93
98
  :host(:not([has-label])) [part='label'] {
94
99
  display: none;
95
100
  }
@@ -164,7 +169,8 @@ class CheckboxGroup extends FieldMixin(FocusMixin(DisabledMixin(ElementMixin(The
164
169
  // See https://github.com/vaadin/vaadin-web-components/issues/94
165
170
  this.setAttribute('role', 'group');
166
171
 
167
- this._observer = new FlattenedNodesObserver(this, ({ addedNodes, removedNodes }) => {
172
+ const slot = this.shadowRoot.querySelector('slot:not([name])');
173
+ this._observer = new SlotObserver(slot, ({ addedNodes, removedNodes }) => {
168
174
  const addedCheckboxes = this.__filterCheckboxes(addedNodes);
169
175
  const removedCheckboxes = this.__filterCheckboxes(removedNodes);
170
176
 
@@ -27,7 +27,6 @@ const checkboxGroup = css`
27
27
  }
28
28
 
29
29
  :host([theme~='vertical']) [part='group-field'] {
30
- display: flex;
31
30
  flex-direction: column;
32
31
  }
33
32
 
@@ -27,7 +27,6 @@ const checkboxGroup = css`
27
27
  }
28
28
 
29
29
  :host([theme~='vertical']) [part='group-field'] {
30
- display: flex;
31
30
  flex-direction: column;
32
31
  }
33
32
 
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/checkbox-group",
4
- "version": "24.2.0-alpha4",
4
+ "version": "24.2.0-alpha6",
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/checkbox-group",
4
- "version": "24.2.0-alpha4",
4
+ "version": "24.2.0-alpha6",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {