@vaadin/tabsheet 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 CHANGED
@@ -61,7 +61,7 @@ import '@vaadin/tabsheet/src/vaadin-tabsheet.js';
61
61
 
62
62
  ## Contributing
63
63
 
64
- Read the [contributing guide](https://vaadin.com/docs/latest/contributing/overview) to learn about our development process, how to propose bugfixes and improvements, and how to test your changes to Vaadin components.
64
+ 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.
65
65
 
66
66
  ## License
67
67
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/tabsheet",
3
- "version": "24.5.0-alpha1",
3
+ "version": "24.5.0-alpha11",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -37,21 +37,21 @@
37
37
  "dependencies": {
38
38
  "@open-wc/dedupe-mixin": "^1.3.0",
39
39
  "@polymer/polymer": "^3.0.0",
40
- "@vaadin/component-base": "24.5.0-alpha1",
41
- "@vaadin/scroller": "24.5.0-alpha1",
42
- "@vaadin/tabs": "24.5.0-alpha1",
43
- "@vaadin/vaadin-lumo-styles": "24.5.0-alpha1",
44
- "@vaadin/vaadin-material-styles": "24.5.0-alpha1",
45
- "@vaadin/vaadin-themable-mixin": "24.5.0-alpha1"
40
+ "@vaadin/component-base": "24.5.0-alpha11",
41
+ "@vaadin/scroller": "24.5.0-alpha11",
42
+ "@vaadin/tabs": "24.5.0-alpha11",
43
+ "@vaadin/vaadin-lumo-styles": "24.5.0-alpha11",
44
+ "@vaadin/vaadin-material-styles": "24.5.0-alpha11",
45
+ "@vaadin/vaadin-themable-mixin": "24.5.0-alpha11"
46
46
  },
47
47
  "devDependencies": {
48
- "@esm-bundle/chai": "^4.3.4",
49
- "@vaadin/testing-helpers": "^0.6.0",
50
- "sinon": "^13.0.2"
48
+ "@vaadin/chai-plugins": "24.5.0-alpha11",
49
+ "@vaadin/testing-helpers": "^1.0.0",
50
+ "sinon": "^18.0.0"
51
51
  },
52
52
  "web-types": [
53
53
  "web-types.json",
54
54
  "web-types.lit.json"
55
55
  ],
56
- "gitHead": "57806caac5468532a3b4e3dbdda730cd0fca193a"
56
+ "gitHead": "8426cea2803a10db518fc85752eeea4c5c755687"
57
57
  }
@@ -141,7 +141,28 @@ export const TabSheetMixin = (superClass) =>
141
141
 
142
142
  // Observe the panels slot for nodes. Set the assigned element nodes as the __panels array.
143
143
  const panelSlot = this.shadowRoot.querySelector('#panel-slot');
144
- this.__panelsObserver = new SlotObserver(panelSlot, () => {
144
+ this.__panelsObserver = new SlotObserver(panelSlot, ({ addedNodes, removedNodes }) => {
145
+ if (addedNodes.length) {
146
+ addedNodes.forEach((node) => {
147
+ // Preserve custom hidden attribute to not override it.
148
+ if (node.nodeType === Node.ELEMENT_NODE && node.hidden) {
149
+ node.__customHidden = true;
150
+ }
151
+ });
152
+ }
153
+ if (removedNodes.length) {
154
+ removedNodes.forEach((node) => {
155
+ // Clear hidden attribute when removing node from the default slot,
156
+ // e.g. when changing its slot to `prefix` or `suffix` dynamically.
157
+ if (node.nodeType === Node.ELEMENT_NODE && node.hidden) {
158
+ if (node.__customHidden) {
159
+ delete node.__customHidden;
160
+ } else {
161
+ node.hidden = false;
162
+ }
163
+ }
164
+ });
165
+ }
145
166
  this.__panels = Array.from(
146
167
  panelSlot.assignedNodes({
147
168
  flatten: true,
@@ -38,6 +38,10 @@ const tabsheet = css`
38
38
  align-items: center;
39
39
  justify-content: center;
40
40
  }
41
+
42
+ :host([theme~='no-padding']) [part='content'] {
43
+ padding: 0;
44
+ }
41
45
  `;
42
46
 
43
47
  registerStyles('vaadin-tabsheet', [tabsheet, loader], { moduleId: 'lumo-tabsheet' });
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/tabsheet",
4
- "version": "24.5.0-alpha1",
4
+ "version": "24.5.0-alpha11",
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/tabsheet",
4
- "version": "24.5.0-alpha1",
4
+ "version": "24.5.0-alpha11",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {