@swisspost/design-system-components 7.2.0 → 7.2.1
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/dist/cjs/{index-0fc0bf5f.js → index-49177437.js} +232 -214
- package/dist/cjs/index.cjs.js +16 -16
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{package-b133ab48.js → package-198f981b.js} +1 -1
- package/dist/cjs/{post-accordion-a079c21b.js → post-accordion-f81a31b2.js} +2 -2
- package/dist/cjs/{post-accordion-item-30c6ec06.js → post-accordion-item-994583fc.js} +2 -2
- package/dist/cjs/post-accordion-item.cjs.entry.js +3 -3
- package/dist/cjs/post-accordion.cjs.entry.js +3 -3
- package/dist/cjs/{post-alert-b5cfc4c6.js → post-alert-b160762a.js} +3 -3
- package/dist/cjs/post-alert.cjs.entry.js +3 -3
- package/dist/cjs/{post-card-control-80ff0fbb.js → post-card-control-5f309278.js} +2 -2
- package/dist/cjs/post-card-control.cjs.entry.js +3 -3
- package/dist/cjs/{post-collapsible-9bcaf6f1.js → post-collapsible-bf63b152.js} +2 -2
- package/dist/cjs/post-collapsible.cjs.entry.js +3 -3
- package/dist/cjs/post-components.cjs.js +2 -2
- package/dist/cjs/{post-icon-87e7972e.js → post-icon-e5af0dff.js} +2 -2
- package/dist/cjs/post-icon.cjs.entry.js +3 -3
- package/dist/cjs/{post-popover-0a73553e.js → post-popover-bb1cf2dc.js} +2 -2
- package/dist/cjs/post-popover.cjs.entry.js +3 -3
- package/dist/cjs/{post-popovercontainer-a1df1705.js → post-popovercontainer-814f2053.js} +31 -22
- package/dist/cjs/post-popovercontainer.cjs.entry.js +3 -3
- package/dist/cjs/{post-rating-2337c023.js → post-rating-7e29df2c.js} +2 -2
- package/dist/cjs/post-rating.cjs.entry.js +3 -3
- package/dist/cjs/{post-tab-header-ac4137cb.js → post-tab-header-1d896a9b.js} +2 -2
- package/dist/cjs/post-tab-header.cjs.entry.js +3 -3
- package/dist/cjs/{post-tab-panel-307eacef.js → post-tab-panel-47481b1e.js} +2 -2
- package/dist/cjs/post-tab-panel.cjs.entry.js +3 -3
- package/dist/cjs/{post-tabs-92435b40.js → post-tabs-35d27649.js} +3 -3
- package/dist/cjs/post-tabs.cjs.entry.js +3 -3
- package/dist/cjs/{post-tag-0237216a.js → post-tag-27049429.js} +2 -2
- package/dist/cjs/post-tag.cjs.entry.js +3 -3
- package/dist/cjs/{post-tooltip-7fcd3f15.js → post-tooltip-95c1e078.js} +2 -2
- package/dist/cjs/post-tooltip.cjs.entry.js +3 -3
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/post-alert/post-alert.js +1 -1
- package/dist/collection/components/post-popover/post-popover.js +1 -1
- package/dist/collection/components/post-popovercontainer/post-popovercontainer.js +1 -1
- package/dist/collection/components/post-tabs/post-tabs.js +3 -1
- package/dist/collection/components/post-tooltip/post-tooltip.js +1 -1
- package/dist/components/package.js +1 -1
- package/dist/components/post-alert2.js +1 -1
- package/dist/components/post-popovercontainer2.js +29 -20
- package/dist/components/post-tabs2.js +1 -1
- package/dist/docs.json +25 -8
- package/dist/esm/{index-d9331ff3.js → index-b40b8259.js} +232 -214
- package/dist/esm/index.js +16 -16
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{package-37b02bc3.js → package-baed1bbc.js} +1 -1
- package/dist/esm/{post-accordion-7eaa090e.js → post-accordion-63757789.js} +2 -2
- package/dist/esm/{post-accordion-item-d5466ca0.js → post-accordion-item-ff713ffa.js} +2 -2
- package/dist/esm/post-accordion-item.entry.js +3 -3
- package/dist/esm/post-accordion.entry.js +3 -3
- package/dist/esm/{post-alert-5bc0d11c.js → post-alert-90030a07.js} +3 -3
- package/dist/esm/post-alert.entry.js +3 -3
- package/dist/esm/{post-card-control-d64be740.js → post-card-control-a77d7957.js} +2 -2
- package/dist/esm/post-card-control.entry.js +3 -3
- package/dist/esm/{post-collapsible-0bb7ca9a.js → post-collapsible-2fd13f4e.js} +2 -2
- package/dist/esm/post-collapsible.entry.js +3 -3
- package/dist/esm/post-components.js +3 -3
- package/dist/esm/{post-icon-8d59faf7.js → post-icon-725a0fba.js} +2 -2
- package/dist/esm/post-icon.entry.js +3 -3
- package/dist/esm/{post-popover-0ebc24f5.js → post-popover-23ed2cdf.js} +2 -2
- package/dist/esm/post-popover.entry.js +3 -3
- package/dist/esm/{post-popovercontainer-5c0ba050.js → post-popovercontainer-f5625d65.js} +31 -22
- package/dist/esm/post-popovercontainer.entry.js +3 -3
- package/dist/esm/{post-rating-40195437.js → post-rating-0bfc12ec.js} +2 -2
- package/dist/esm/post-rating.entry.js +3 -3
- package/dist/esm/{post-tab-header-ff165ebb.js → post-tab-header-5be0820b.js} +2 -2
- package/dist/esm/post-tab-header.entry.js +3 -3
- package/dist/esm/{post-tab-panel-d40b9704.js → post-tab-panel-a2a06c2d.js} +2 -2
- package/dist/esm/post-tab-panel.entry.js +3 -3
- package/dist/esm/{post-tabs-6ee5542b.js → post-tabs-c1cf60cd.js} +3 -3
- package/dist/esm/post-tabs.entry.js +3 -3
- package/dist/esm/{post-tag-e76f88e5.js → post-tag-1158169f.js} +2 -2
- package/dist/esm/post-tag.entry.js +3 -3
- package/dist/esm/{post-tooltip-990b8b2b.js → post-tooltip-966fde7a.js} +2 -2
- package/dist/esm/post-tooltip.entry.js +3 -3
- package/dist/post-components/index.esm.js +1 -1
- package/dist/post-components/p-09c9ec65.entry.js +1 -0
- package/dist/post-components/p-105f8fe5.entry.js +1 -0
- package/dist/post-components/{p-287f66b9.js → p-11e13d7d.js} +1 -1
- package/dist/post-components/p-1d351eda.js +2 -0
- package/dist/post-components/p-408e8d5c.entry.js +1 -0
- package/dist/post-components/{p-ee12644d.js → p-40cbd3a9.js} +1 -1
- package/dist/post-components/p-418e4351.entry.js +1 -0
- package/dist/post-components/{p-aef9ee8b.js → p-41bd4480.js} +1 -1
- package/dist/post-components/{p-3ce051c9.js → p-4f16eac0.js} +1 -1
- package/dist/post-components/{p-deb19ca0.js → p-6fa5a17d.js} +1 -1
- package/dist/post-components/p-803678de.entry.js +1 -0
- package/dist/post-components/p-8ba9721a.entry.js +1 -0
- package/dist/post-components/p-92636363.js +1 -0
- package/dist/post-components/p-9ac48e84.entry.js +1 -0
- package/dist/post-components/p-9c5b9e7c.entry.js +1 -0
- package/dist/post-components/{p-f86b2ea1.js → p-9c842093.js} +1 -1
- package/dist/post-components/{p-3f2c54ad.js → p-b3a7e242.js} +1 -1
- package/dist/post-components/p-b5f6a7b5.entry.js +1 -0
- package/dist/post-components/p-b675a470.entry.js +1 -0
- package/dist/post-components/p-ba275788.entry.js +1 -0
- package/dist/post-components/p-c2906b17.js +1 -0
- package/dist/post-components/{p-0637689e.js → p-c3e6894d.js} +1 -1
- package/dist/post-components/{p-d6e0e495.js → p-cbca927d.js} +1 -1
- package/dist/post-components/p-ce4fff0a.js +1 -0
- package/dist/post-components/p-daf27e9c.entry.js +1 -0
- package/dist/post-components/{p-69bd634e.js → p-f11cb5ab.js} +1 -1
- package/dist/post-components/p-f4b64493.entry.js +1 -0
- package/dist/post-components/p-f665b245.entry.js +1 -0
- package/dist/post-components/p-f80d0c5f.js +1 -0
- package/dist/post-components/p-fa1125d9.js +1 -0
- package/dist/post-components/post-components.esm.js +1 -1
- package/dist/types/components/post-tabs/post-tabs.d.ts +2 -0
- package/dist/types/stencil-public-runtime.d.ts +0 -2
- package/loader/index.d.ts +3 -0
- package/package.json +9 -9
- package/dist/collection/index.spec.js +0 -27
- package/dist/post-components/p-0ba99d76.entry.js +0 -1
- package/dist/post-components/p-0e97fb19.entry.js +0 -1
- package/dist/post-components/p-19ee1efc.entry.js +0 -1
- package/dist/post-components/p-23e7f6e3.entry.js +0 -1
- package/dist/post-components/p-305ab60c.js +0 -1
- package/dist/post-components/p-62229794.entry.js +0 -1
- package/dist/post-components/p-7dc73c43.entry.js +0 -1
- package/dist/post-components/p-7e59cbd2.js +0 -1
- package/dist/post-components/p-8559d3c0.entry.js +0 -1
- package/dist/post-components/p-941e5ef0.js +0 -1
- package/dist/post-components/p-95003bde.entry.js +0 -1
- package/dist/post-components/p-a1da0539.js +0 -1
- package/dist/post-components/p-a5d9115f.entry.js +0 -1
- package/dist/post-components/p-a9aa57f0.entry.js +0 -1
- package/dist/post-components/p-c21da8cb.js +0 -1
- package/dist/post-components/p-c655db7c.entry.js +0 -1
- package/dist/post-components/p-ca2ff4bb.entry.js +0 -1
- package/dist/post-components/p-d2eafe06.entry.js +0 -1
- package/dist/post-components/p-d9eab6d9.js +0 -2
- package/dist/post-components/p-ff0b0a9a.entry.js +0 -1
|
@@ -120,12 +120,21 @@ function getPaddingObject(padding) {
|
|
|
120
120
|
};
|
|
121
121
|
}
|
|
122
122
|
function rectToClientRect(rect) {
|
|
123
|
+
const {
|
|
124
|
+
x,
|
|
125
|
+
y,
|
|
126
|
+
width,
|
|
127
|
+
height
|
|
128
|
+
} = rect;
|
|
123
129
|
return {
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
130
|
+
width,
|
|
131
|
+
height,
|
|
132
|
+
top: y,
|
|
133
|
+
left: x,
|
|
134
|
+
right: x + width,
|
|
135
|
+
bottom: y + height,
|
|
136
|
+
x,
|
|
137
|
+
y
|
|
129
138
|
};
|
|
130
139
|
}
|
|
131
140
|
|
|
@@ -1192,6 +1201,15 @@ function isOverflowElement(element) {
|
|
|
1192
1201
|
function isTableElement(element) {
|
|
1193
1202
|
return ['table', 'td', 'th'].includes(getNodeName(element));
|
|
1194
1203
|
}
|
|
1204
|
+
function isTopLayer(element) {
|
|
1205
|
+
return [':popover-open', ':modal'].some(selector => {
|
|
1206
|
+
try {
|
|
1207
|
+
return element.matches(selector);
|
|
1208
|
+
} catch (e) {
|
|
1209
|
+
return false;
|
|
1210
|
+
}
|
|
1211
|
+
});
|
|
1212
|
+
}
|
|
1195
1213
|
function isContainingBlock(element) {
|
|
1196
1214
|
const webkit = isWebKit();
|
|
1197
1215
|
const css = getComputedStyle(element);
|
|
@@ -1202,11 +1220,13 @@ function isContainingBlock(element) {
|
|
|
1202
1220
|
function getContainingBlock(element) {
|
|
1203
1221
|
let currentNode = getParentNode(element);
|
|
1204
1222
|
while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
|
|
1223
|
+
if (isTopLayer(currentNode)) {
|
|
1224
|
+
return null;
|
|
1225
|
+
}
|
|
1205
1226
|
if (isContainingBlock(currentNode)) {
|
|
1206
1227
|
return currentNode;
|
|
1207
|
-
} else {
|
|
1208
|
-
currentNode = getParentNode(currentNode);
|
|
1209
1228
|
}
|
|
1229
|
+
currentNode = getParentNode(currentNode);
|
|
1210
1230
|
}
|
|
1211
1231
|
return null;
|
|
1212
1232
|
}
|
|
@@ -1228,8 +1248,8 @@ function getNodeScroll(element) {
|
|
|
1228
1248
|
};
|
|
1229
1249
|
}
|
|
1230
1250
|
return {
|
|
1231
|
-
scrollLeft: element.
|
|
1232
|
-
scrollTop: element.
|
|
1251
|
+
scrollLeft: element.scrollX,
|
|
1252
|
+
scrollTop: element.scrollY
|
|
1233
1253
|
};
|
|
1234
1254
|
}
|
|
1235
1255
|
function getParentNode(node) {
|
|
@@ -1401,17 +1421,6 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
1401
1421
|
});
|
|
1402
1422
|
}
|
|
1403
1423
|
|
|
1404
|
-
const topLayerSelectors = [':popover-open', ':modal'];
|
|
1405
|
-
function isTopLayer(element) {
|
|
1406
|
-
return topLayerSelectors.some(selector => {
|
|
1407
|
-
try {
|
|
1408
|
-
return element.matches(selector);
|
|
1409
|
-
} catch (e) {
|
|
1410
|
-
return false;
|
|
1411
|
-
}
|
|
1412
|
-
});
|
|
1413
|
-
}
|
|
1414
|
-
|
|
1415
1424
|
function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
1416
1425
|
let {
|
|
1417
1426
|
elements,
|
|
@@ -145,7 +145,7 @@ const PostTabs = /*@__PURE__*/ proxyCustomElement(class PostTabs extends HTMLEle
|
|
|
145
145
|
nextTab.focus();
|
|
146
146
|
}
|
|
147
147
|
render() {
|
|
148
|
-
return (h(Host, { key: '
|
|
148
|
+
return (h(Host, { key: 'f7aabebf0645b5d9db9028a0b1807e49d6f4e994', "data-version": version }, h("div", { key: 'b62f738a4df453f9acf94825f2d1626dc40c4eb1', class: "tabs-wrapper", part: "tabs" }, h("div", { key: 'a9bd32fc939cfdff73d2c48982551cceedb5bd2a', class: "tabs", role: "tablist" }, h("slot", { key: '4a8c2bc4815debd4d6951acbce224d3f1fd6b169', name: "tabs", onSlotchange: () => this.enableTabs() }))), h("div", { key: 'c7b2543a1decdc2bfe7a683b7bd193586485d012', class: "tab-content", part: "content" }, h("slot", { key: 'af19b3e89f8ca0cecf59f4426e4b5d3ac4efbc75', onSlotchange: () => this.moveMisplacedTabs() }))));
|
|
149
149
|
}
|
|
150
150
|
get host() { return this; }
|
|
151
151
|
static get style() { return PostTabsStyle0; }
|
package/dist/docs.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2024-
|
|
2
|
+
"timestamp": "2024-07-10T09:47:50",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
|
-
"version": "4.
|
|
5
|
+
"version": "4.19.1",
|
|
6
6
|
"typescriptVersion": "5.4.5"
|
|
7
7
|
},
|
|
8
8
|
"components": [
|
|
@@ -1303,7 +1303,7 @@
|
|
|
1303
1303
|
"Placement": {
|
|
1304
1304
|
"location": "import",
|
|
1305
1305
|
"path": "@floating-ui/dom",
|
|
1306
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
1306
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.7/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
1307
1307
|
}
|
|
1308
1308
|
}
|
|
1309
1309
|
},
|
|
@@ -1552,7 +1552,7 @@
|
|
|
1552
1552
|
"Placement": {
|
|
1553
1553
|
"location": "import",
|
|
1554
1554
|
"path": "@floating-ui/dom",
|
|
1555
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
1555
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.7/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
1556
1556
|
}
|
|
1557
1557
|
}
|
|
1558
1558
|
},
|
|
@@ -2048,6 +2048,14 @@
|
|
|
2048
2048
|
{
|
|
2049
2049
|
"name": "slot",
|
|
2050
2050
|
"text": "default - Slot for placing tab panels. Each tab panel should be a <post-tab-panel> element."
|
|
2051
|
+
},
|
|
2052
|
+
{
|
|
2053
|
+
"name": "part",
|
|
2054
|
+
"text": "tabs - Add custom styles for the tab header container."
|
|
2055
|
+
},
|
|
2056
|
+
{
|
|
2057
|
+
"name": "part",
|
|
2058
|
+
"text": "content - Add custom styles for the tab panel container."
|
|
2051
2059
|
}
|
|
2052
2060
|
],
|
|
2053
2061
|
"usage": {},
|
|
@@ -2152,7 +2160,16 @@
|
|
|
2152
2160
|
"docs": "Slot for placing tab headers. Each tab header should be a <post-tab-header> element."
|
|
2153
2161
|
}
|
|
2154
2162
|
],
|
|
2155
|
-
"parts": [
|
|
2163
|
+
"parts": [
|
|
2164
|
+
{
|
|
2165
|
+
"name": "content",
|
|
2166
|
+
"docs": "Add custom styles for the tab panel container."
|
|
2167
|
+
},
|
|
2168
|
+
{
|
|
2169
|
+
"name": "tabs",
|
|
2170
|
+
"docs": "Add custom styles for the tab header container."
|
|
2171
|
+
}
|
|
2172
|
+
],
|
|
2156
2173
|
"dependents": [],
|
|
2157
2174
|
"dependencies": [],
|
|
2158
2175
|
"dependencyGraph": {}
|
|
@@ -2321,7 +2338,7 @@
|
|
|
2321
2338
|
"Placement": {
|
|
2322
2339
|
"location": "import",
|
|
2323
2340
|
"path": "@floating-ui/dom",
|
|
2324
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
2341
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.7/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
2325
2342
|
}
|
|
2326
2343
|
}
|
|
2327
2344
|
},
|
|
@@ -2536,10 +2553,10 @@
|
|
|
2536
2553
|
"docstring": "",
|
|
2537
2554
|
"path": "src/components/post-alert/alert-types.ts"
|
|
2538
2555
|
},
|
|
2539
|
-
"../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
2556
|
+
"../../node_modules/.pnpm/@floating-ui+dom@1.6.7/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement": {
|
|
2540
2557
|
"declaration": "any",
|
|
2541
2558
|
"docstring": "",
|
|
2542
|
-
"path": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
2559
|
+
"path": "../../node_modules/.pnpm/@floating-ui+dom@1.6.7/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts"
|
|
2543
2560
|
}
|
|
2544
2561
|
}
|
|
2545
2562
|
}
|