@swisspost/design-system-components 9.0.0-next.10 → 9.0.0-next.12
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.cjs.js +19 -19
- package/dist/cjs/{package-aaec3cba.js → package-0bd6fb0d.js} +1 -1
- package/dist/cjs/{post-accordion-85bf5e0a.js → post-accordion-7aadd881.js} +1 -1
- package/dist/cjs/{post-accordion-item-957b3464.js → post-accordion-item-bd033c7f.js} +4 -4
- package/dist/cjs/post-accordion-item.cjs.entry.js +2 -2
- package/dist/cjs/post-accordion.cjs.entry.js +2 -2
- package/dist/cjs/{post-avatar-58540591.js → post-avatar-5dbdf70d.js} +1 -1
- package/dist/cjs/post-avatar.cjs.entry.js +2 -2
- package/dist/cjs/{post-back-to-top-db5c7d01.js → post-back-to-top-71bc912c.js} +1 -1
- package/dist/cjs/post-back-to-top.cjs.entry.js +2 -2
- package/dist/cjs/post-banner-d4e0c73c.js +91 -0
- package/dist/cjs/post-banner.cjs.entry.js +2 -2
- package/dist/cjs/{post-breadcrumb-cacca682.js → post-breadcrumb-531c4f79.js} +1 -1
- package/dist/cjs/post-breadcrumb-item_2.cjs.entry.js +2 -2
- package/dist/cjs/post-breadcrumb.cjs.entry.js +2 -2
- package/dist/cjs/post-card-control-332f6f1f.js +272 -0
- package/dist/cjs/post-card-control.cjs.entry.js +2 -2
- package/dist/cjs/post-closebutton_15.cjs.entry.js +2 -2
- package/dist/cjs/{post-collapsible-trigger-067d1f4c.js → post-collapsible-trigger-02924200.js} +2 -2
- package/dist/cjs/post-collapsible_2.cjs.entry.js +2 -2
- package/dist/cjs/{post-footer-beeb36c8.js → post-footer-96d7bd47.js} +1 -1
- package/dist/cjs/post-footer.cjs.entry.js +2 -2
- package/dist/cjs/{post-menu-item-e0e214b9.js → post-menu-item-3f73fb4d.js} +1 -1
- package/dist/cjs/{post-popover-7acbdf17.js → post-popover-64195ffd.js} +2 -2
- package/dist/cjs/post-popover.cjs.entry.js +2 -2
- package/dist/cjs/{post-rating-ac1b9b3c.js → post-rating-bd27ebfc.js} +1 -1
- package/dist/cjs/post-rating.cjs.entry.js +2 -2
- package/dist/cjs/{post-tab-header-a3d28719.js → post-tab-header-1f057694.js} +1 -1
- package/dist/cjs/post-tab-header.cjs.entry.js +2 -2
- package/dist/cjs/{post-tab-panel-4562e265.js → post-tab-panel-3eedcd19.js} +1 -1
- package/dist/cjs/post-tab-panel.cjs.entry.js +2 -2
- package/dist/cjs/{post-tabs-80f65e1d.js → post-tabs-ea94b243.js} +1 -1
- package/dist/cjs/post-tabs.cjs.entry.js +2 -2
- package/dist/cjs/{post-tag-5741a78d.js → post-tag-1d75024b.js} +1 -1
- package/dist/cjs/post-tag.cjs.entry.js +2 -2
- package/dist/cjs/{post-togglebutton-245e33f1.js → post-togglebutton-876f7892.js} +89 -25
- package/dist/cjs/{post-tooltip-cefce5e1.js → post-tooltip-e4ef3c7e.js} +1 -1
- package/dist/cjs/post-tooltip.cjs.entry.js +2 -2
- package/dist/collection/components/post-accordion-item/post-accordion-item.js +3 -3
- package/dist/collection/components/post-banner/post-banner.css +1 -1
- package/dist/collection/components/post-card-control/post-card-control.css +1 -1
- package/dist/collection/components/post-collapsible/post-collapsible.css +1 -1
- package/dist/collection/components/post-logo/post-logo.css +1 -1
- package/dist/collection/components/post-logo/post-logo.js +1 -1
- package/dist/collection/components/post-mainnavigation/post-mainnavigation.css +1 -1
- package/dist/collection/components/post-menu/post-menu.js +1 -1
- package/dist/collection/components/post-popover/post-popover.css +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-tooltip/post-tooltip.js +1 -1
- package/dist/components/package.js +1 -1
- package/dist/components/post-accordion-item2.js +3 -3
- package/dist/components/post-banner2.js +1 -1
- package/dist/components/post-card-control2.js +1 -1
- package/dist/components/post-collapsible2.js +1 -1
- package/dist/components/post-logo2.js +2 -2
- package/dist/components/post-mainnavigation2.js +1 -1
- package/dist/components/post-popover2.js +1 -1
- package/dist/components/post-popovercontainer2.js +85 -21
- package/dist/docs.json +7 -7
- package/dist/esm/index.js +19 -19
- package/dist/esm/package-f8f7bb40.js +3 -0
- package/dist/esm/{post-accordion-3bf30525.js → post-accordion-ca48eb18.js} +1 -1
- package/dist/esm/{post-accordion-item-6683fbed.js → post-accordion-item-a461f2a7.js} +4 -4
- package/dist/esm/post-accordion-item.entry.js +2 -2
- package/dist/esm/post-accordion.entry.js +2 -2
- package/dist/esm/{post-avatar-3ddb4c79.js → post-avatar-0da1a2e8.js} +1 -1
- package/dist/esm/post-avatar.entry.js +2 -2
- package/dist/esm/{post-back-to-top-15ee2771.js → post-back-to-top-77471a90.js} +1 -1
- package/dist/esm/post-back-to-top.entry.js +2 -2
- package/dist/esm/post-banner-b0af5bd3.js +89 -0
- package/dist/esm/post-banner.entry.js +2 -2
- package/dist/esm/{post-breadcrumb-6252b112.js → post-breadcrumb-85ffd02f.js} +1 -1
- package/dist/esm/post-breadcrumb-item_2.entry.js +2 -2
- package/dist/esm/post-breadcrumb.entry.js +2 -2
- package/dist/esm/post-card-control-3225eb57.js +270 -0
- package/dist/esm/post-card-control.entry.js +2 -2
- package/dist/esm/post-closebutton_15.entry.js +2 -2
- package/dist/esm/{post-collapsible-trigger-b727bf7e.js → post-collapsible-trigger-883db3bf.js} +2 -2
- package/dist/esm/post-collapsible_2.entry.js +2 -2
- package/dist/esm/{post-footer-7a03a9bb.js → post-footer-7b0eb067.js} +1 -1
- package/dist/esm/post-footer.entry.js +2 -2
- package/dist/esm/{post-menu-item-3e168ecd.js → post-menu-item-37f637a3.js} +1 -1
- package/dist/esm/{post-popover-bff5cffd.js → post-popover-c24ecd38.js} +2 -2
- package/dist/esm/post-popover.entry.js +2 -2
- package/dist/esm/{post-rating-ce595a65.js → post-rating-e1c66e5c.js} +1 -1
- package/dist/esm/post-rating.entry.js +2 -2
- package/dist/esm/{post-tab-header-c864586f.js → post-tab-header-6a9b0153.js} +1 -1
- package/dist/esm/post-tab-header.entry.js +2 -2
- package/dist/esm/{post-tab-panel-800425b8.js → post-tab-panel-73b56a16.js} +1 -1
- package/dist/esm/post-tab-panel.entry.js +2 -2
- package/dist/esm/{post-tabs-e5aa8b08.js → post-tabs-02e523b8.js} +1 -1
- package/dist/esm/post-tabs.entry.js +2 -2
- package/dist/esm/{post-tag-fc3df50a.js → post-tag-43aba068.js} +1 -1
- package/dist/esm/post-tag.entry.js +2 -2
- package/dist/esm/{post-togglebutton-101dd3bd.js → post-togglebutton-c2231709.js} +89 -25
- package/dist/esm/{post-tooltip-e8484aea.js → post-tooltip-8271950c.js} +1 -1
- package/dist/esm/post-tooltip.entry.js +2 -2
- package/dist/post-components/index.esm.js +1 -1
- package/dist/post-components/{p-02bb5231.js → p-025688e5.js} +1 -1
- package/dist/post-components/p-08b51b35.entry.js +1 -0
- package/dist/post-components/{p-27ad2d1f.js → p-24c92608.js} +1 -1
- package/dist/post-components/p-25a57971.js +1 -0
- package/dist/post-components/{p-3de1151e.js → p-2cb4a8f1.js} +1 -1
- package/dist/post-components/{p-86a1ad40.js → p-33b64e0c.js} +1 -1
- package/dist/post-components/{p-fc09ac69.js → p-34d70cd5.js} +1 -1
- package/dist/post-components/p-350f3900.entry.js +1 -0
- package/dist/post-components/{p-eed26f43.js → p-35bc4554.js} +1 -1
- package/dist/post-components/p-38b259a4.entry.js +1 -0
- package/dist/post-components/p-3c6cef1e.entry.js +1 -0
- package/dist/post-components/{p-a3694196.js → p-4a713cf8.js} +1 -1
- package/dist/post-components/p-4b5e2b24.js +1 -0
- package/dist/post-components/p-54e58fc2.entry.js +1 -0
- package/dist/post-components/p-637759d6.js +1 -0
- package/dist/post-components/{p-bec07e51.js → p-7589a19f.js} +1 -1
- package/dist/post-components/p-7cce7342.entry.js +1 -0
- package/dist/post-components/p-819e19de.js +1 -0
- package/dist/post-components/p-82d48128.js +1 -0
- package/dist/post-components/{p-f35d5d4a.entry.js → p-85171893.entry.js} +1 -1
- package/dist/post-components/p-882fdd0c.entry.js +1 -0
- package/dist/post-components/{p-d1d9c9a5.js → p-94399c69.js} +1 -1
- package/dist/post-components/p-9a02b162.entry.js +1 -0
- package/dist/post-components/{p-9e287cb5.js → p-b1f5bc26.js} +1 -1
- package/dist/post-components/p-b2f239a1.entry.js +1 -0
- package/dist/post-components/{p-24476696.js → p-b571e5c8.js} +1 -1
- package/dist/post-components/{p-1d3acbfd.js → p-ba530822.js} +1 -1
- package/dist/post-components/p-bae1c85f.entry.js +1 -0
- package/dist/post-components/p-bdabdec5.js +1 -0
- package/dist/post-components/p-c1225174.entry.js +1 -0
- package/dist/post-components/p-c372a141.entry.js +1 -0
- package/dist/post-components/{p-6e6e5447.entry.js → p-c510d968.entry.js} +1 -1
- package/dist/post-components/p-c87c5d59.entry.js +1 -0
- package/dist/post-components/p-d04c1b7f.entry.js +1 -0
- package/dist/post-components/p-da300843.entry.js +1 -0
- package/dist/post-components/{p-faf15ec1.js → p-e2f886ab.js} +1 -1
- package/dist/post-components/p-fec04a15.entry.js +1 -0
- package/dist/post-components/post-components.esm.js +1 -1
- package/loaders/package.js +1 -1
- package/loaders/post-accordion-item2.js +3 -3
- package/loaders/post-banner.js +1 -1
- package/loaders/post-card-control.js +1 -1
- package/loaders/post-collapsible2.js +1 -1
- package/loaders/post-logo.js +2 -2
- package/loaders/post-mainnavigation.js +1 -1
- package/loaders/post-popover.js +1 -1
- package/loaders/post-popovercontainer2.js +85 -21
- package/package.json +10 -10
- package/dist/cjs/post-banner-727866d5.js +0 -91
- package/dist/cjs/post-card-control-f5d72ddc.js +0 -272
- package/dist/esm/package-2ee42825.js +0 -3
- package/dist/esm/post-banner-fc407f6e.js +0 -89
- package/dist/esm/post-card-control-cb3dfc60.js +0 -270
- package/dist/post-components/p-11880d55.js +0 -1
- package/dist/post-components/p-1489d777.entry.js +0 -1
- package/dist/post-components/p-19707347.entry.js +0 -1
- package/dist/post-components/p-25f6efab.entry.js +0 -1
- package/dist/post-components/p-29626238.entry.js +0 -1
- package/dist/post-components/p-339488ba.entry.js +0 -1
- package/dist/post-components/p-413d1fff.js +0 -1
- package/dist/post-components/p-47095b84.entry.js +0 -1
- package/dist/post-components/p-5b0703a4.entry.js +0 -1
- package/dist/post-components/p-618b8929.js +0 -1
- package/dist/post-components/p-66c8d0a2.entry.js +0 -1
- package/dist/post-components/p-80b282a2.js +0 -1
- package/dist/post-components/p-97647d03.entry.js +0 -1
- package/dist/post-components/p-98f1d284.js +0 -1
- package/dist/post-components/p-adc79d26.entry.js +0 -1
- package/dist/post-components/p-bcf94111.entry.js +0 -1
- package/dist/post-components/p-bd87a2b5.entry.js +0 -1
- package/dist/post-components/p-bec09df9.entry.js +0 -1
- package/dist/post-components/p-db2ac0a2.entry.js +0 -1
- package/dist/post-components/p-e93a4bd0.entry.js +0 -1
- package/dist/post-components/p-fa6c79b8.entry.js +0 -1
- package/dist/post-components/p-ffcd735f.js +0 -1
|
@@ -1156,6 +1156,9 @@ const size$1 = function (options) {
|
|
|
1156
1156
|
};
|
|
1157
1157
|
};
|
|
1158
1158
|
|
|
1159
|
+
function hasWindow() {
|
|
1160
|
+
return typeof window !== 'undefined';
|
|
1161
|
+
}
|
|
1159
1162
|
function getNodeName(node) {
|
|
1160
1163
|
if (isNode(node)) {
|
|
1161
1164
|
return (node.nodeName || '').toLowerCase();
|
|
@@ -1174,17 +1177,25 @@ function getDocumentElement(node) {
|
|
|
1174
1177
|
return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
|
|
1175
1178
|
}
|
|
1176
1179
|
function isNode(value) {
|
|
1180
|
+
if (!hasWindow()) {
|
|
1181
|
+
return false;
|
|
1182
|
+
}
|
|
1177
1183
|
return value instanceof Node || value instanceof getWindow(value).Node;
|
|
1178
1184
|
}
|
|
1179
1185
|
function isElement(value) {
|
|
1186
|
+
if (!hasWindow()) {
|
|
1187
|
+
return false;
|
|
1188
|
+
}
|
|
1180
1189
|
return value instanceof Element || value instanceof getWindow(value).Element;
|
|
1181
1190
|
}
|
|
1182
1191
|
function isHTMLElement(value) {
|
|
1192
|
+
if (!hasWindow()) {
|
|
1193
|
+
return false;
|
|
1194
|
+
}
|
|
1183
1195
|
return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
|
|
1184
1196
|
}
|
|
1185
1197
|
function isShadowRoot(value) {
|
|
1186
|
-
|
|
1187
|
-
if (typeof ShadowRoot === 'undefined') {
|
|
1198
|
+
if (!hasWindow() || typeof ShadowRoot === 'undefined') {
|
|
1188
1199
|
return false;
|
|
1189
1200
|
}
|
|
1190
1201
|
return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
|
|
@@ -1215,7 +1226,8 @@ function isContainingBlock(elementOrCss) {
|
|
|
1215
1226
|
const css = isElement(elementOrCss) ? getComputedStyle(elementOrCss) : elementOrCss;
|
|
1216
1227
|
|
|
1217
1228
|
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
1218
|
-
|
|
1229
|
+
// https://drafts.csswg.org/css-transforms-2/#individual-transforms
|
|
1230
|
+
return ['transform', 'translate', 'scale', 'rotate', 'perspective'].some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'].some(value => (css.willChange || '').includes(value)) || ['paint', 'layout', 'strict', 'content'].some(value => (css.contain || '').includes(value));
|
|
1219
1231
|
}
|
|
1220
1232
|
function getContainingBlock(element) {
|
|
1221
1233
|
let currentNode = getParentNode(element);
|
|
@@ -1288,10 +1300,14 @@ function getOverflowAncestors(node, list, traverseIframes) {
|
|
|
1288
1300
|
const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
|
|
1289
1301
|
const win = getWindow(scrollableAncestor);
|
|
1290
1302
|
if (isBody) {
|
|
1291
|
-
|
|
1303
|
+
const frameElement = getFrameElement(win);
|
|
1304
|
+
return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
|
|
1292
1305
|
}
|
|
1293
1306
|
return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
|
|
1294
1307
|
}
|
|
1308
|
+
function getFrameElement(win) {
|
|
1309
|
+
return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
|
|
1310
|
+
}
|
|
1295
1311
|
|
|
1296
1312
|
function getCssDimensions(element) {
|
|
1297
1313
|
const css = getComputedStyle(element);
|
|
@@ -1395,7 +1411,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
1395
1411
|
const win = getWindow(domElement);
|
|
1396
1412
|
const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;
|
|
1397
1413
|
let currentWin = win;
|
|
1398
|
-
let currentIFrame = currentWin
|
|
1414
|
+
let currentIFrame = getFrameElement(currentWin);
|
|
1399
1415
|
while (currentIFrame && offsetParent && offsetWin !== currentWin) {
|
|
1400
1416
|
const iframeScale = getScale(currentIFrame);
|
|
1401
1417
|
const iframeRect = currentIFrame.getBoundingClientRect();
|
|
@@ -1409,7 +1425,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
1409
1425
|
x += left;
|
|
1410
1426
|
y += top;
|
|
1411
1427
|
currentWin = getWindow(currentIFrame);
|
|
1412
|
-
currentIFrame = currentWin
|
|
1428
|
+
currentIFrame = getFrameElement(currentWin);
|
|
1413
1429
|
}
|
|
1414
1430
|
}
|
|
1415
1431
|
return rectToClientRect({
|
|
@@ -1420,6 +1436,31 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
1420
1436
|
});
|
|
1421
1437
|
}
|
|
1422
1438
|
|
|
1439
|
+
// If <html> has a CSS width greater than the viewport, then this will be
|
|
1440
|
+
// incorrect for RTL.
|
|
1441
|
+
function getWindowScrollBarX(element, rect) {
|
|
1442
|
+
const leftScroll = getNodeScroll(element).scrollLeft;
|
|
1443
|
+
if (!rect) {
|
|
1444
|
+
return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
|
|
1445
|
+
}
|
|
1446
|
+
return rect.left + leftScroll;
|
|
1447
|
+
}
|
|
1448
|
+
|
|
1449
|
+
function getHTMLOffset(documentElement, scroll, ignoreScrollbarX) {
|
|
1450
|
+
if (ignoreScrollbarX === void 0) {
|
|
1451
|
+
ignoreScrollbarX = false;
|
|
1452
|
+
}
|
|
1453
|
+
const htmlRect = documentElement.getBoundingClientRect();
|
|
1454
|
+
const x = htmlRect.left + scroll.scrollLeft - (ignoreScrollbarX ? 0 :
|
|
1455
|
+
// RTL <body> scrollbar.
|
|
1456
|
+
getWindowScrollBarX(documentElement, htmlRect));
|
|
1457
|
+
const y = htmlRect.top + scroll.scrollTop;
|
|
1458
|
+
return {
|
|
1459
|
+
x,
|
|
1460
|
+
y
|
|
1461
|
+
};
|
|
1462
|
+
}
|
|
1463
|
+
|
|
1423
1464
|
function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
1424
1465
|
let {
|
|
1425
1466
|
elements,
|
|
@@ -1451,11 +1492,12 @@ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
|
1451
1492
|
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
1452
1493
|
}
|
|
1453
1494
|
}
|
|
1495
|
+
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll, true) : createCoords(0);
|
|
1454
1496
|
return {
|
|
1455
1497
|
width: rect.width * scale.x,
|
|
1456
1498
|
height: rect.height * scale.y,
|
|
1457
|
-
x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x,
|
|
1458
|
-
y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y
|
|
1499
|
+
x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
|
|
1500
|
+
y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
|
|
1459
1501
|
};
|
|
1460
1502
|
}
|
|
1461
1503
|
|
|
@@ -1463,12 +1505,6 @@ function getClientRects(element) {
|
|
|
1463
1505
|
return Array.from(element.getClientRects());
|
|
1464
1506
|
}
|
|
1465
1507
|
|
|
1466
|
-
function getWindowScrollBarX(element) {
|
|
1467
|
-
// If <html> has a CSS width greater than the viewport, then this will be
|
|
1468
|
-
// incorrect for RTL.
|
|
1469
|
-
return getBoundingClientRect(getDocumentElement(element)).left + getNodeScroll(element).scrollLeft;
|
|
1470
|
-
}
|
|
1471
|
-
|
|
1472
1508
|
// Gets the entire size of the scrollable document area, even extending outside
|
|
1473
1509
|
// of the `<html>` and `<body>` rect bounds if horizontally scrollable.
|
|
1474
1510
|
function getDocumentRect(element) {
|
|
@@ -1543,9 +1579,10 @@ function getClientRectFromClippingAncestor(element, clippingAncestor, strategy)
|
|
|
1543
1579
|
} else {
|
|
1544
1580
|
const visualOffsets = getVisualOffsets(element);
|
|
1545
1581
|
rect = {
|
|
1546
|
-
...clippingAncestor,
|
|
1547
1582
|
x: clippingAncestor.x - visualOffsets.x,
|
|
1548
|
-
y: clippingAncestor.y - visualOffsets.y
|
|
1583
|
+
y: clippingAncestor.y - visualOffsets.y,
|
|
1584
|
+
width: clippingAncestor.width,
|
|
1585
|
+
height: clippingAncestor.height
|
|
1549
1586
|
};
|
|
1550
1587
|
}
|
|
1551
1588
|
return rectToClientRect(rect);
|
|
@@ -1650,11 +1687,14 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
|
|
|
1650
1687
|
offsets.x = offsetRect.x + offsetParent.clientLeft;
|
|
1651
1688
|
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
1652
1689
|
} else if (documentElement) {
|
|
1690
|
+
// If the <body> scrollbar appears on the left (e.g. RTL systems). Use
|
|
1691
|
+
// Firefox with layout.scrollbar.side = 3 in about:config to test this.
|
|
1653
1692
|
offsets.x = getWindowScrollBarX(documentElement);
|
|
1654
1693
|
}
|
|
1655
1694
|
}
|
|
1656
|
-
const
|
|
1657
|
-
const
|
|
1695
|
+
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
|
|
1696
|
+
const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
|
|
1697
|
+
const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
|
|
1658
1698
|
return {
|
|
1659
1699
|
x,
|
|
1660
1700
|
y,
|
|
@@ -1674,7 +1714,16 @@ function getTrueOffsetParent(element, polyfill) {
|
|
|
1674
1714
|
if (polyfill) {
|
|
1675
1715
|
return polyfill(element);
|
|
1676
1716
|
}
|
|
1677
|
-
|
|
1717
|
+
let rawOffsetParent = element.offsetParent;
|
|
1718
|
+
|
|
1719
|
+
// Firefox returns the <html> element as the offsetParent if it's non-static,
|
|
1720
|
+
// while Chrome and Safari return the <body> element. The <body> element must
|
|
1721
|
+
// be used to perform the correct calculations even if the <html> element is
|
|
1722
|
+
// non-static.
|
|
1723
|
+
if (getDocumentElement(element) === rawOffsetParent) {
|
|
1724
|
+
rawOffsetParent = rawOffsetParent.ownerDocument.body;
|
|
1725
|
+
}
|
|
1726
|
+
return rawOffsetParent;
|
|
1678
1727
|
}
|
|
1679
1728
|
|
|
1680
1729
|
// Gets the closest ancestor positioned element. Handles some edge cases,
|
|
@@ -1736,6 +1785,10 @@ const platform = {
|
|
|
1736
1785
|
isRTL
|
|
1737
1786
|
};
|
|
1738
1787
|
|
|
1788
|
+
function rectsAreEqual(a, b) {
|
|
1789
|
+
return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;
|
|
1790
|
+
}
|
|
1791
|
+
|
|
1739
1792
|
// https://samthor.au/2021/observing-dom/
|
|
1740
1793
|
function observeMove(element, onMove) {
|
|
1741
1794
|
let io = null;
|
|
@@ -1755,12 +1808,13 @@ function observeMove(element, onMove) {
|
|
|
1755
1808
|
threshold = 1;
|
|
1756
1809
|
}
|
|
1757
1810
|
cleanup();
|
|
1811
|
+
const elementRectForRootMargin = element.getBoundingClientRect();
|
|
1758
1812
|
const {
|
|
1759
1813
|
left,
|
|
1760
1814
|
top,
|
|
1761
1815
|
width,
|
|
1762
1816
|
height
|
|
1763
|
-
} =
|
|
1817
|
+
} = elementRectForRootMargin;
|
|
1764
1818
|
if (!skip) {
|
|
1765
1819
|
onMove();
|
|
1766
1820
|
}
|
|
@@ -1793,6 +1847,16 @@ function observeMove(element, onMove) {
|
|
|
1793
1847
|
refresh(false, ratio);
|
|
1794
1848
|
}
|
|
1795
1849
|
}
|
|
1850
|
+
if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {
|
|
1851
|
+
// It's possible that even though the ratio is reported as 1, the
|
|
1852
|
+
// element is not actually fully within the IntersectionObserver's root
|
|
1853
|
+
// area anymore. This can happen under performance constraints. This may
|
|
1854
|
+
// be a bug in the browser's IntersectionObserver implementation. To
|
|
1855
|
+
// work around this, we compare the element's bounding rect now with
|
|
1856
|
+
// what it was at the time we created the IntersectionObserver. If they
|
|
1857
|
+
// are not equal then the element moved, so we refresh.
|
|
1858
|
+
refresh();
|
|
1859
|
+
}
|
|
1796
1860
|
isFirstUpdate = false;
|
|
1797
1861
|
}
|
|
1798
1862
|
|
|
@@ -1870,7 +1934,7 @@ function autoUpdate(reference, floating, update, options) {
|
|
|
1870
1934
|
}
|
|
1871
1935
|
function frameLoop() {
|
|
1872
1936
|
const nextRefRect = getBoundingClientRect(reference);
|
|
1873
|
-
if (prevRefRect && (
|
|
1937
|
+
if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) {
|
|
1874
1938
|
update();
|
|
1875
1939
|
}
|
|
1876
1940
|
prevRefRect = nextRefRect;
|
package/dist/docs.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2025-01-
|
|
2
|
+
"timestamp": "2025-01-21T13:47:24",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
5
|
"version": "4.19.2",
|
|
@@ -2582,7 +2582,7 @@
|
|
|
2582
2582
|
"Placement": {
|
|
2583
2583
|
"location": "import",
|
|
2584
2584
|
"path": "@floating-ui/dom",
|
|
2585
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
2585
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.13/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
2586
2586
|
}
|
|
2587
2587
|
}
|
|
2588
2588
|
},
|
|
@@ -2933,7 +2933,7 @@
|
|
|
2933
2933
|
"Placement": {
|
|
2934
2934
|
"location": "import",
|
|
2935
2935
|
"path": "@floating-ui/dom",
|
|
2936
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
2936
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.13/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
2937
2937
|
}
|
|
2938
2938
|
}
|
|
2939
2939
|
},
|
|
@@ -3204,7 +3204,7 @@
|
|
|
3204
3204
|
"Placement": {
|
|
3205
3205
|
"location": "import",
|
|
3206
3206
|
"path": "@floating-ui/dom",
|
|
3207
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
3207
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.13/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
3208
3208
|
}
|
|
3209
3209
|
}
|
|
3210
3210
|
},
|
|
@@ -4067,7 +4067,7 @@
|
|
|
4067
4067
|
"Placement": {
|
|
4068
4068
|
"location": "import",
|
|
4069
4069
|
"path": "@floating-ui/dom",
|
|
4070
|
-
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
4070
|
+
"id": "../../node_modules/.pnpm/@floating-ui+dom@1.6.13/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement"
|
|
4071
4071
|
}
|
|
4072
4072
|
}
|
|
4073
4073
|
},
|
|
@@ -4301,10 +4301,10 @@
|
|
|
4301
4301
|
"docstring": "",
|
|
4302
4302
|
"path": "src/components/post-language-switch/switch-variants.ts"
|
|
4303
4303
|
},
|
|
4304
|
-
"../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
4304
|
+
"../../node_modules/.pnpm/@floating-ui+dom@1.6.13/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts::Placement": {
|
|
4305
4305
|
"declaration": "any",
|
|
4306
4306
|
"docstring": "",
|
|
4307
|
-
"path": "../../node_modules/.pnpm/@floating-ui+dom@1.6.
|
|
4307
|
+
"path": "../../node_modules/.pnpm/@floating-ui+dom@1.6.13/node_modules/@floating-ui/dom/dist/floating-ui.dom.d.ts"
|
|
4308
4308
|
}
|
|
4309
4309
|
}
|
|
4310
4310
|
}
|
package/dist/esm/index.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
export { P as PostAccordion } from './post-accordion-
|
|
2
|
-
export { P as PostAccordionItem } from './post-accordion-item-
|
|
3
|
-
export { P as PostAvatar } from './post-avatar-
|
|
4
|
-
export { P as PostBackToTop } from './post-back-to-top-
|
|
5
|
-
export { P as PostBanner } from './post-banner-
|
|
6
|
-
export { P as PostBreadcrumb } from './post-breadcrumb-
|
|
7
|
-
export { P as PostBreadcrumbItem, a as PostMenuItem } from './post-menu-item-
|
|
8
|
-
export { P as PostCardControl } from './post-card-control-
|
|
9
|
-
export { P as PostClosebutton, a as PostHeader, b as PostIcon, c as PostLanguageOption, d as PostLanguageSwitch, e as PostList, f as PostListItem, g as PostLogo, h as PostMainnavigation, i as PostMegadropdown, j as PostMegadropdownTrigger, k as PostMenu, l as PostMenuTrigger, m as PostPopovercontainer, n as PostTogglebutton } from './post-togglebutton-
|
|
10
|
-
export { P as PostCollapsible, a as PostCollapsibleTrigger } from './post-collapsible-trigger-
|
|
11
|
-
export { P as PostFooter } from './post-footer-
|
|
12
|
-
export { P as PostPopover } from './post-popover-
|
|
13
|
-
export { P as PostRating } from './post-rating-
|
|
14
|
-
export { P as PostTabs } from './post-tabs-
|
|
15
|
-
export { P as PostTabHeader } from './post-tab-header-
|
|
16
|
-
export { P as PostTabPanel } from './post-tab-panel-
|
|
17
|
-
export { P as PostTag } from './post-tag-
|
|
18
|
-
export { P as PostTooltip } from './post-tooltip-
|
|
1
|
+
export { P as PostAccordion } from './post-accordion-ca48eb18.js';
|
|
2
|
+
export { P as PostAccordionItem } from './post-accordion-item-a461f2a7.js';
|
|
3
|
+
export { P as PostAvatar } from './post-avatar-0da1a2e8.js';
|
|
4
|
+
export { P as PostBackToTop } from './post-back-to-top-77471a90.js';
|
|
5
|
+
export { P as PostBanner } from './post-banner-b0af5bd3.js';
|
|
6
|
+
export { P as PostBreadcrumb } from './post-breadcrumb-85ffd02f.js';
|
|
7
|
+
export { P as PostBreadcrumbItem, a as PostMenuItem } from './post-menu-item-37f637a3.js';
|
|
8
|
+
export { P as PostCardControl } from './post-card-control-3225eb57.js';
|
|
9
|
+
export { P as PostClosebutton, a as PostHeader, b as PostIcon, c as PostLanguageOption, d as PostLanguageSwitch, e as PostList, f as PostListItem, g as PostLogo, h as PostMainnavigation, i as PostMegadropdown, j as PostMegadropdownTrigger, k as PostMenu, l as PostMenuTrigger, m as PostPopovercontainer, n as PostTogglebutton } from './post-togglebutton-c2231709.js';
|
|
10
|
+
export { P as PostCollapsible, a as PostCollapsibleTrigger } from './post-collapsible-trigger-883db3bf.js';
|
|
11
|
+
export { P as PostFooter } from './post-footer-7b0eb067.js';
|
|
12
|
+
export { P as PostPopover } from './post-popover-c24ecd38.js';
|
|
13
|
+
export { P as PostRating } from './post-rating-e1c66e5c.js';
|
|
14
|
+
export { P as PostTabs } from './post-tabs-02e523b8.js';
|
|
15
|
+
export { P as PostTabHeader } from './post-tab-header-6a9b0153.js';
|
|
16
|
+
export { P as PostTabPanel } from './post-tab-panel-73b56a16.js';
|
|
17
|
+
export { P as PostTag } from './post-tag-43aba068.js';
|
|
18
|
+
export { P as PostTooltip } from './post-tooltip-8271950c.js';
|
|
19
19
|
import './index-6bfe6554.js';
|
|
20
|
-
import './package-
|
|
20
|
+
import './package-f8f7bb40.js';
|
|
21
21
|
import './heading-levels-5b7b4349.js';
|
|
22
22
|
import './check-one-of-6b3ef8eb.js';
|
|
23
23
|
import './index-b49c9904.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-6bfe6554.js';
|
|
2
|
-
import { v as version } from './package-
|
|
2
|
+
import { v as version } from './package-f8f7bb40.js';
|
|
3
3
|
import { H as HEADING_LEVELS } from './heading-levels-5b7b4349.js';
|
|
4
4
|
import { c as checkOneOf } from './check-one-of-6b3ef8eb.js';
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-6bfe6554.js';
|
|
2
|
-
import { v as version } from './package-
|
|
2
|
+
import { v as version } from './package-f8f7bb40.js';
|
|
3
3
|
import { H as HEADING_LEVELS } from './heading-levels-5b7b4349.js';
|
|
4
4
|
import { c as checkEmptyOrOneOf } from './index-b49c9904.js';
|
|
5
5
|
import { n as nanoid } from './index.browser-51485f85.js';
|
|
@@ -45,12 +45,12 @@ const PostAccordionItem = class {
|
|
|
45
45
|
}
|
|
46
46
|
render() {
|
|
47
47
|
var _a, _b;
|
|
48
|
-
const headingLevel = (_a = this.host.closest('post-
|
|
48
|
+
const headingLevel = (_a = this.host.closest('post-accordion')) === null || _a === void 0 ? void 0 : _a.getAttribute('heading-level');
|
|
49
49
|
const HeadingTag = `h${(_b = headingLevel !== null && headingLevel !== void 0 ? headingLevel : this.headingLevel) !== null && _b !== void 0 ? _b : 2}`;
|
|
50
|
-
return (h(Host, { key: '
|
|
50
|
+
return (h(Host, { key: '77851385edd1910f539ce61f1bf90bcebdeaa9ee', id: this.id, "data-version": version }, h("div", { key: '0d7ab4f69e350658908ac54aa1bdbdf07003f0e1', part: "accordion-item", class: "accordion-item" }, h("post-collapsible-trigger", { key: 'b0cc3c14a98575e1db7093a668557ee021fd7f8e', for: `${this.id}--collapse` }, h(HeadingTag, { key: '33f3066f1a866b519084012517d548dd9abd8093', class: "accordion-header", id: `${this.id}--header` }, h("button", { key: '1c29d71ea84789427c4bb4ca6f75f56ef0bc242e', type: "button", class: `accordion-button${this.collapsed ? ' collapsed' : ''}`, part: "button" }, h("span", { key: '0324ff7aa3e48a4b7964f043ae99cb5e136fbb54', class: {
|
|
51
51
|
'logo-container': true,
|
|
52
52
|
'has-image': !!this.slottedLogo,
|
|
53
|
-
} }, h("slot", { key: '
|
|
53
|
+
} }, h("slot", { key: 'a2a07235808a847097d78610d22efc8eb73bd2f0', name: "logo", onSlotchange: this.onSlotLogoChange.bind(this) })), h("slot", { key: '2f6cf7287b910b211e8ba646a8431eb634d89768', name: "header" }), h("post-icon", { key: '38f599c957e70027ebe84939f6146618a5a4b2f0', name: "2051" })))), h("post-collapsible", { key: 'a9fefff65fb48ac5a81c8fef3486dc84937de3a8', id: `${this.id}--collapse`, collapsed: this.collapsed, ref: el => (this.collapsible = el) }, h("div", { key: 'eddd1a7e8a583409908b7b0a91482cbdfd9e7c99', class: "accordion-body", part: "body" }, h("slot", { key: '1e82e00b05c16bd917e640738c5100689d2e7edf' }))))));
|
|
54
54
|
}
|
|
55
55
|
get host() { return getElement(this); }
|
|
56
56
|
static get watchers() { return {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { P as post_accordion_item } from './post-accordion-item-
|
|
1
|
+
export { P as post_accordion_item } from './post-accordion-item-a461f2a7.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
|
-
import './package-
|
|
3
|
+
import './package-f8f7bb40.js';
|
|
4
4
|
import './heading-levels-5b7b4349.js';
|
|
5
5
|
import './index-b49c9904.js';
|
|
6
6
|
import './constants-8d548297.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { P as post_accordion } from './post-accordion-
|
|
1
|
+
export { P as post_accordion } from './post-accordion-ca48eb18.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
|
-
import './package-
|
|
3
|
+
import './package-f8f7bb40.js';
|
|
4
4
|
import './heading-levels-5b7b4349.js';
|
|
5
5
|
import './check-one-of-6b3ef8eb.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-6bfe6554.js';
|
|
2
|
-
import { v as version } from './package-
|
|
2
|
+
import { v as version } from './package-f8f7bb40.js';
|
|
3
3
|
import { c as checkNonEmpty } from './check-non-empty-58bd6b17.js';
|
|
4
4
|
|
|
5
5
|
const postAvatarCss = "/*!\n * Copyright 2021 by Swiss Post, Information Technology\n */:host{--post-avatar-bg:var(--post-scheme-color-interactive-primary-enabled-bg2);--post-avatar-fg:var(--post-scheme-color-interactive-primary-enabled-fg3);display:inline-flex;position:relative;width:var(--post-device-sizing-interactive-icon-size3);height:var(--post-device-sizing-interactive-icon-size3);background-color:var(--post-scheme-color-interactive-primary-enabled-stroke3);border:var(--post-device-border-width-default) solid var(--post-scheme-color-interactive-primary-enabled-stroke3);border-radius:var(--post-device-border-radius-round);font-size:var(--post-device-font-size-8);vertical-align:top;line-height:1}:host::after{display:block;content:\"\";position:absolute;inset:0;z-index:1;border-radius:inherit}*,*::before,*::after{box-sizing:border-box}slot,img,::slotted(img){display:block;width:100%;height:100%}img,::slotted(img){border-radius:var(--post-device-border-radius-round)}::slotted(:not(img)){display:none !important}.initials{display:flex;justify-content:center;align-items:center;position:relative;z-index:2;width:100%;height:100%;background-color:var(--post-avatar-bg);border-radius:var(--post-device-border-radius-round);color:var(--post-avatar-fg);text-transform:uppercase}.initials span{width:1px !important;height:1px !important;padding:0 !important;margin:-1px !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;white-space:nowrap !important;border:0 !important}.initials span:not(caption){position:absolute !important}";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { P as post_avatar } from './post-avatar-
|
|
1
|
+
export { P as post_avatar } from './post-avatar-0da1a2e8.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
|
-
import './package-
|
|
3
|
+
import './package-f8f7bb40.js';
|
|
4
4
|
import './check-non-empty-58bd6b17.js';
|
|
5
5
|
import './constants-8d548297.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-6bfe6554.js';
|
|
2
2
|
import { s as slideUp, a as slideDown } from './slide-3422b8a3.js';
|
|
3
|
-
import { v as version } from './package-
|
|
3
|
+
import { v as version } from './package-f8f7bb40.js';
|
|
4
4
|
import { c as checkType } from './check-type-8828dbe4.js';
|
|
5
5
|
import { c as checkNonEmpty } from './check-non-empty-58bd6b17.js';
|
|
6
6
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { P as post_back_to_top } from './post-back-to-top-
|
|
1
|
+
export { P as post_back_to_top } from './post-back-to-top-77471a90.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
3
|
import './slide-3422b8a3.js';
|
|
4
|
-
import './package-
|
|
4
|
+
import './package-f8f7bb40.js';
|
|
5
5
|
import './check-type-8828dbe4.js';
|
|
6
6
|
import './check-non-empty-58bd6b17.js';
|
|
7
7
|
import './constants-8d548297.js';
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-6bfe6554.js';
|
|
2
|
+
import { v as version } from './package-f8f7bb40.js';
|
|
3
|
+
import { f as fadeOut } from './fade-7fd71785.js';
|
|
4
|
+
import { a as checkEmptyOrPattern, c as checkEmptyOrOneOf } from './index-b49c9904.js';
|
|
5
|
+
import { n as nanoid } from './index.browser-51485f85.js';
|
|
6
|
+
import { c as checkType } from './check-type-8828dbe4.js';
|
|
7
|
+
import { c as checkNonEmpty } from './check-non-empty-58bd6b17.js';
|
|
8
|
+
|
|
9
|
+
const BANNER_TYPES = ['neutral', 'success', 'warning', 'danger', 'info'];
|
|
10
|
+
|
|
11
|
+
const postBannerCss = ".banner,.alert{min-height:calc(var(--post-device-sizing-notification-icon-2) + (2 * var(--post-device-spacing-padding-10)));box-sizing:border-box;box-shadow:var(--post-device-elevation-100);border-radius:var(--post-device-border-radius-2);padding:var(--post-device-spacing-padding-10) var(--post-device-spacing-padding-10);padding-inline-start:calc(var(--post-device-spacing-padding-10) + var(--post-device-sizing-notification-icon-2) + var(--post-device-spacing-gap-inline-6));font-weight:400;border-style:var(--post-core-border-style-solid);border-width:var(--post-device-border-width-default);position:relative;color:var(--post-scheme-color-surface-default-fg);background-color:var(--post-scheme-color-signal-neutral);border-color:var(--post-scheme-color-signal-neutral-dark);color-scheme:var(--post-core-bg-scheme-light)}.banner:not(.no-icon)::before,.alert:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M31.986 15.73c-.503.16-1.03.27-1.586.27a5.24 5.24 0 0 1-4.43-2.448c-.73.382-1.547.62-2.427.62a5.257 5.257 0 0 1-5.257-5.258c0-.88.237-1.698.62-2.427a5.24 5.24 0 0 1-2.449-4.43c0-.714.145-1.393.403-2.014C16.574.028 16.29 0 16 0 7.163 0 0 7.163 0 16s7.163 16 16 16 16-7.163 16-16c0-.091-.012-.18-.014-.27M16 30.667c-8.087 0-14.667-6.58-14.667-14.667 0-7.806 6.13-14.207 13.828-14.643a6.54 6.54 0 0 0 2.116 5.56 6.3 6.3 0 0 0-.325 1.997 6.6 6.6 0 0 0 6.59 6.59c.677 0 1.346-.108 1.998-.324a6.54 6.54 0 0 0 5.067 2.15C29.933 24.796 23.639 30.667 16 30.667M11.352 14.17a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 1 1 1.334 1.334 1.336 1.336 0 0 1-1.334-1.334m13.981 8.496a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 0 1 2.667 0c0 .735-.598 1.333-1.333 1.333a1.335 1.335 0 0 1-1.334-1.333m-7.276-1.829a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.667a.667.667 0 1 1 .002-1.335.667.667 0 0 1-.002 1.335m7.772-6a2 2 0 1 0-4 0 2 2 0 0 0 4 0m-2 .666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M11.505 5.505a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M28.93 18.548a13.2 13.2 0 0 1-4.335 7.357.663.663 0 0 1-.94-.073.666.666 0 0 1 .073-.94 11.84 11.84 0 0 0 3.894-6.61.668.668 0 0 1 1.307.266m-6.668 8.212a.667.667 0 0 1-.295.896c-.837.423-1.722.757-2.63.99a.665.665 0 1 1-.33-1.292 11.7 11.7 0 0 0 2.359-.888.67.67 0 0 1 .896.294M4 15.921a.666.666 0 1 1-1.333 0 13.13 13.13 0 0 1 4.597-9.984.666.666 0 1 1 .867 1.013A11.8 11.8 0 0 0 4 15.92'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-signal-neutral-dark)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner:not(.no-icon)::before,.alert:not(.no-icon)::before{color:CanvasText}}.banner:has(>post-icon)::before,.alert:has(>post-icon)::before{content:none}.banner>post-icon,.alert>post-icon{background-color:var(--post-scheme-color-signal-neutral);color:var(--post-scheme-color-signal-neutral-dark)}.banner::before,.alert::before{content:\"\";display:block}.banner::before,.banner>post-icon,.alert::before,.alert>post-icon{position:absolute;height:var(--post-device-sizing-notification-icon-2);width:var(--post-device-sizing-notification-icon-2);left:var(--post-device-spacing-padding-10);top:var(--post-device-spacing-padding-10)}.banner.no-icon,.alert.no-icon{min-height:calc(2*var(--post-device-spacing-padding-10) + var(--post-core-dimension-24));padding-inline-start:var(--post-device-spacing-padding-10)}.banner.no-icon::before,.alert.no-icon::before{content:unset}.banner.no-icon>post-icon,.alert.no-icon>post-icon{display:none}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner,.alert{filter:none !important;border:2px solid CanvasText}}.banner:not(.banner-action):not(.alert-action),.alert:not(.banner-action):not(.alert-action){display:flex;flex-direction:column;justify-content:center;gap:var(--post-core-dimension-4)}.banner:not(.banner-action):not(.alert-action) a,.alert:not(.banner-action):not(.alert-action) a{font-weight:400}.banner:not(.banner-action):not(.alert-action) hr,.alert:not(.banner-action):not(.alert-action) hr{margin-block:var(--post-core-dimension-8) var(--post-core-dimension-12) !important}.banner:not(.banner-action):not(.alert-action)>*,.alert:not(.banner-action):not(.alert-action)>*{margin:0}.banner-container{border:unset;background-color:rgba(0,0,0,0)}.banner-dismissible,.alert-dismissible{pointer-events:auto;position:relative}.banner-dismissible:not(.banner-action):not(.alert-action),.alert-dismissible:not(.banner-action):not(.alert-action){padding-inline-end:calc(var(--post-device-spacing-padding-10) + var(--post-device-spacing-gap-inline-6) + var(--post-core-dimension-24))}.banner-dismissible>.btn-close,.alert-dismissible>.btn-close{position:absolute;inset-block-start:1rem;inset-inline-end:var(--post-device-spacing-padding-10)}.banner-buttons,.alert-buttons{display:flex;align-items:center;justify-content:flex-start;flex-direction:row-reverse;margin-block-start:var(--post-device-spacing-padding-block-10);gap:var(--post-device-spacing-gap-1)}@media (max-width: 779.98px){.banner-buttons,.alert-buttons{flex-direction:column}}.banner-action>.banner-content,.banner-action>.alert-content,.alert-action>.banner-content,.alert-action>.alert-content{display:flex;flex-direction:column;justify-content:center;gap:var(--post-core-dimension-4)}.banner-action>.banner-content a,.banner-action>.alert-content a,.alert-action>.banner-content a,.alert-action>.alert-content a{font-weight:400}.banner-action>.banner-content hr,.banner-action>.alert-content hr,.alert-action>.banner-content hr,.alert-action>.alert-content hr{margin-block:var(--post-core-dimension-8) var(--post-core-dimension-12) !important}.banner-action>.banner-content>*,.banner-action>.alert-content>*,.alert-action>.banner-content>*,.alert-action>.alert-content>*{margin:0}@media (max-width: 779.98px){.banner-action,.alert-action{flex-direction:column;align-items:stretch}.banner-action>.banner-content,.banner-action>.alert-content,.alert-action>.banner-content,.alert-action>.alert-content{padding-inline-start:var(--post-device-spacing-gap-inline-6)var(--post-device-sizing-notification-icon-2);padding-inline-end:var(--post-device-spacing-gap-inline-6)var(--post-core-dimension-24)}.banner-action.no-icon>.banner-content,.banner-action.no-icon>.alert-content,.alert-action.no-icon>.banner-content,.alert-action.no-icon>.alert-content{padding-inline-start:0}.banner-action>.banner-buttons,.banner-action>.alert-buttons,.alert-action>.banner-buttons,.alert-action>.alert-buttons{display:flex}.banner-action>.banner-buttons>.btn,.banner-action>.banner-buttons>::slotted(.btn),.banner-action>.alert-buttons>.btn,.banner-action>.alert-buttons>::slotted(.btn),.alert-action>.banner-buttons>.btn,.alert-action>.banner-buttons>::slotted(.btn),.alert-action>.alert-buttons>.btn,.alert-action>.alert-buttons>::slotted(.btn){flex:1 0 0;width:100%}.banner-action>.banner-buttons>.btn:first-child,.banner-action>.banner-buttons>::slotted(.btn:first-child),.banner-action>.alert-buttons>.btn:first-child,.banner-action>.alert-buttons>::slotted(.btn:first-child),.alert-action>.banner-buttons>.btn:first-child,.alert-action>.banner-buttons>::slotted(.btn:first-child),.alert-action>.alert-buttons>.btn:first-child,.alert-action>.alert-buttons>::slotted(.btn:first-child){margin-inline-start:0}}.banner-neutral,.alert-neutral{background-color:var(--post-scheme-color-signal-neutral);border-color:var(--post-scheme-color-signal-neutral-dark);color-scheme:var(--post-core-bg-scheme-light)}.banner-neutral:not(.no-icon)::before,.alert-neutral:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M31.986 15.73c-.503.16-1.03.27-1.586.27a5.24 5.24 0 0 1-4.43-2.448c-.73.382-1.547.62-2.427.62a5.257 5.257 0 0 1-5.257-5.258c0-.88.237-1.698.62-2.427a5.24 5.24 0 0 1-2.449-4.43c0-.714.145-1.393.403-2.014C16.574.028 16.29 0 16 0 7.163 0 0 7.163 0 16s7.163 16 16 16 16-7.163 16-16c0-.091-.012-.18-.014-.27M16 30.667c-8.087 0-14.667-6.58-14.667-14.667 0-7.806 6.13-14.207 13.828-14.643a6.54 6.54 0 0 0 2.116 5.56 6.3 6.3 0 0 0-.325 1.997 6.6 6.6 0 0 0 6.59 6.59c.677 0 1.346-.108 1.998-.324a6.54 6.54 0 0 0 5.067 2.15C29.933 24.796 23.639 30.667 16 30.667M11.352 14.17a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 1 1 1.334 1.334 1.336 1.336 0 0 1-1.334-1.334m13.981 8.496a2.667 2.667 0 1 0-5.333 0 2.667 2.667 0 0 0 5.333 0m-4 0a1.335 1.335 0 0 1 2.667 0c0 .735-.598 1.333-1.333 1.333a1.335 1.335 0 0 1-1.334-1.333m-7.276-1.829a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.667a.667.667 0 1 1 .002-1.335.667.667 0 0 1-.002 1.335m7.772-6a2 2 0 1 0-4 0 2 2 0 0 0 4 0m-2 .666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M11.505 5.505a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 2.666a.667.667 0 1 1 .001-1.334.667.667 0 0 1-.001 1.334M28.93 18.548a13.2 13.2 0 0 1-4.335 7.357.663.663 0 0 1-.94-.073.666.666 0 0 1 .073-.94 11.84 11.84 0 0 0 3.894-6.61.668.668 0 0 1 1.307.266m-6.668 8.212a.667.667 0 0 1-.295.896c-.837.423-1.722.757-2.63.99a.665.665 0 1 1-.33-1.292 11.7 11.7 0 0 0 2.359-.888.67.67 0 0 1 .896.294M4 15.921a.666.666 0 1 1-1.333 0 13.13 13.13 0 0 1 4.597-9.984.666.666 0 1 1 .867 1.013A11.8 11.8 0 0 0 4 15.92'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-signal-neutral-dark)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-neutral:not(.no-icon)::before,.alert-neutral:not(.no-icon)::before{color:CanvasText}}.banner-neutral:has(>post-icon)::before,.alert-neutral:has(>post-icon)::before{content:none}.banner-neutral>post-icon,.alert-neutral>post-icon{background-color:var(--post-scheme-color-signal-neutral);color:var(--post-scheme-color-signal-neutral-dark)}.banner-success,.alert-success{background-color:var(--post-scheme-color-interactive-notification-success-bg);border-color:var(--post-scheme-color-interactive-notification-success-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-success:not(.no-icon)::before,.alert-success:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m12.667 24.533-7.6-7.6 1.867-1.867 5.733 5.733 12.4-12.4 1.867 1.867z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-success-icon)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-success:not(.no-icon)::before,.alert-success:not(.no-icon)::before{color:CanvasText}}.banner-success:has(>post-icon)::before,.alert-success:has(>post-icon)::before{content:none}.banner-success>post-icon,.alert-success>post-icon{background-color:var(--post-scheme-color-interactive-notification-success-bg);color:var(--post-scheme-color-interactive-notification-success-icon)}.banner-warning,.alert-warning{background-color:var(--post-scheme-color-interactive-notification-warning-bg);border-color:var(--post-scheme-color-interactive-notification-warning-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-warning:not(.no-icon)::before,.alert-warning:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.67 4h2.67v18.67h-2.67zm0 21.33h2.67V28h-2.67z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-warning-icon)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-warning:not(.no-icon)::before,.alert-warning:not(.no-icon)::before{color:CanvasText}}.banner-warning:has(>post-icon)::before,.alert-warning:has(>post-icon)::before{content:none}.banner-warning>post-icon,.alert-warning>post-icon{background-color:var(--post-scheme-color-interactive-notification-warning-bg);color:var(--post-scheme-color-interactive-notification-warning-icon)}.banner-error,.alert-error{background-color:var(--post-scheme-color-interactive-notification-error-bg);border-color:var(--post-scheme-color-interactive-notification-error-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-error:not(.no-icon)::before,.alert-error:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.67 4h2.67v18.67h-2.67zm0 21.33h2.67V28h-2.67z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-error-icon)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-error:not(.no-icon)::before,.alert-error:not(.no-icon)::before{color:CanvasText}}.banner-error:has(>post-icon)::before,.alert-error:has(>post-icon)::before{content:none}.banner-error>post-icon,.alert-error>post-icon{background-color:var(--post-scheme-color-interactive-notification-error-bg);color:var(--post-scheme-color-interactive-notification-error-icon)}.banner-info,.alert-info{background-color:var(--post-scheme-color-interactive-notification-info-bg);border-color:var(--post-scheme-color-interactive-notification-info-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-info:not(.no-icon)::before,.alert-info:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M17.33 25.33v-16h-4.67V12h2v13.33h-2V28h6.67v-2.67zM14.67 4h2.67v2.67h-2.67z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-info-icon)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-info:not(.no-icon)::before,.alert-info:not(.no-icon)::before{color:CanvasText}}.banner-info:has(>post-icon)::before,.alert-info:has(>post-icon)::before{content:none}.banner-info>post-icon,.alert-info>post-icon{background-color:var(--post-scheme-color-interactive-notification-info-bg);color:var(--post-scheme-color-interactive-notification-info-icon)}.banner-danger,.alert-danger{background-color:var(--post-scheme-color-interactive-notification-error-bg);border-color:var(--post-scheme-color-interactive-notification-error-stroke);color-scheme:var(--post-core-bg-scheme-light)}.banner-danger:not(.no-icon)::before,.alert-danger:not(.no-icon)::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.67 4h2.67v18.67h-2.67zm0 21.33h2.67V28h-2.67z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;color:var(--post-scheme-color-interactive-notification-error-icon)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.banner-danger:not(.no-icon)::before,.alert-danger:not(.no-icon)::before{color:CanvasText}}.banner-danger:has(>post-icon)::before,.alert-danger:has(>post-icon)::before{content:none}.banner-danger>post-icon,.alert-danger>post-icon{background-color:var(--post-scheme-color-interactive-notification-error-bg);color:var(--post-scheme-color-interactive-notification-error-icon)}.btn-close{padding:0;overflow:visible;border:0;background:none;color:inherit;font:inherit;-webkit-user-select:none;user-select:none;appearance:button;border-radius:var(--post-device-border-radius-round);color:#000;transition:opacity 250ms,border-color 250ms,background-color 250ms,color 250ms;cursor:pointer}.btn-close{outline-offset:var(--post-device-spacing-padding-2) !important;outline:var(--post-scheme-color-interactive-focus-stroke) none var(--post-device-border-width-focus) !important}.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:var(--post-core-border-style-solid) !important;border-radius:4px}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-style:var(--post-core-border-style-solid) !important;border-radius:4px}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}.btn-close::before{mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m16.267 16.667 6.667-6.533-.933-1.067-6.667 6.667-6.667-6.667-.933 1.067 6.667 6.533-6.667 6.667 1.067.933 6.533-6.667 6.667 6.667.933-1.067z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;content:\"\";display:block;height:var(--post-core-dimension-24);width:var(--post-core-dimension-24)}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:#000}.btn-close:disabled{color:var(--post-gray-40)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close{color:CanvasText;forced-color-adjust:none}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:Highlight}}.btn-close-white{color:#e6e6e6}.btn-close-white:focus,.btn-close-white:not(:disabled):hover,.btn-close-white.pretend-hover{color:#fff}.btn-close-white:disabled{color:#999}/*!\n * Copyright 2021 by Swiss Post, Information Technology\n */:host{display:block}:host ::slotted(*){margin:0 !important}.visually-hidden{width:1px !important;height:1px !important;padding:0 !important;margin:-1px !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;white-space:nowrap !important;border:0 !important}.visually-hidden:not(caption){position:absolute !important}";
|
|
12
|
+
const PostBannerStyle0 = postBannerCss;
|
|
13
|
+
|
|
14
|
+
const PostBanner = class {
|
|
15
|
+
constructor(hostRef) {
|
|
16
|
+
registerInstance(this, hostRef);
|
|
17
|
+
this.postDismissed = createEvent(this, "postDismissed", 7);
|
|
18
|
+
this.bannerId = `p${nanoid(6)}`;
|
|
19
|
+
this.classes = undefined;
|
|
20
|
+
this.hasActions = undefined;
|
|
21
|
+
this.hasHeading = undefined;
|
|
22
|
+
this.onDismissButtonClick = () => this.dismiss();
|
|
23
|
+
this.dismissible = false;
|
|
24
|
+
this.dismissLabel = undefined;
|
|
25
|
+
this.icon = undefined;
|
|
26
|
+
this.type = 'neutral';
|
|
27
|
+
}
|
|
28
|
+
validateDismissible(isDismissible = this.dismissible) {
|
|
29
|
+
checkType(isDismissible, 'boolean', 'The post-banner "dismissible" prop should be a boolean.');
|
|
30
|
+
setTimeout(() => this.validateDismissLabel());
|
|
31
|
+
}
|
|
32
|
+
validateDismissLabel(dismissLabel = this.dismissLabel) {
|
|
33
|
+
if (this.dismissible) {
|
|
34
|
+
checkNonEmpty(dismissLabel, 'Dismissible post-banner\'s require a "dismiss-label" prop.');
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
validateIcon(icon = this.icon) {
|
|
38
|
+
checkEmptyOrPattern(icon, /\d{4}|none/, 'The post-banner "icon" prop should be a 4-digits string.');
|
|
39
|
+
}
|
|
40
|
+
validateType(type = this.type) {
|
|
41
|
+
checkEmptyOrOneOf(type, BANNER_TYPES, `The post-banner requires a type form: ${BANNER_TYPES.join(', ')}`);
|
|
42
|
+
}
|
|
43
|
+
componentDidLoad() {
|
|
44
|
+
this.validateDismissible();
|
|
45
|
+
this.validateIcon();
|
|
46
|
+
this.validateType();
|
|
47
|
+
}
|
|
48
|
+
componentWillRender() {
|
|
49
|
+
this.hasHeading = this.host.querySelectorAll('[slot=heading]').length > 0;
|
|
50
|
+
this.hasActions = this.host.querySelectorAll('[slot=actions]').length > 0;
|
|
51
|
+
this.classes = `banner ${this.type ? 'banner-' + this.type : ''}`;
|
|
52
|
+
if (this.dismissible)
|
|
53
|
+
this.classes += ' banner-dismissible';
|
|
54
|
+
if (this.hasActions)
|
|
55
|
+
this.classes += ' banner-action';
|
|
56
|
+
if (this.icon === 'none')
|
|
57
|
+
this.classes += ' no-icon';
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Triggers banner dismissal programmatically (same as clicking on the close button (×)).
|
|
61
|
+
*/
|
|
62
|
+
async dismiss() {
|
|
63
|
+
const dismissal = fadeOut(this.host);
|
|
64
|
+
await dismissal.finished;
|
|
65
|
+
this.host.remove();
|
|
66
|
+
this.postDismissed.emit();
|
|
67
|
+
}
|
|
68
|
+
render() {
|
|
69
|
+
const defaultBannerContent = [
|
|
70
|
+
this.hasHeading && (h("div", { key: `${this.bannerId}-heading`, class: "banner-heading" }, h("slot", { key: 'ac8774db27af4057a85f04f5864534c14f387cd7', name: "heading" }))),
|
|
71
|
+
h("slot", { key: `${this.bannerId}-message` }),
|
|
72
|
+
];
|
|
73
|
+
const actionBannerContent = [
|
|
74
|
+
h("div", { key: `${this.bannerId}-content`, class: "banner-content" }, defaultBannerContent),
|
|
75
|
+
h("div", { key: `${this.bannerId}-buttons`, class: "banner-buttons" }, h("slot", { key: 'e3652af90a4b54bf1297e4c78a32d64305674ff7', name: "actions" })),
|
|
76
|
+
];
|
|
77
|
+
return (h(Host, { key: '21bfb98ce6f38c03dca18877cd99d5ac2ebbafaf', "data-version": version }, h("div", { key: '728c307293908b86d6951d9edc420d8cf9074bc8', role: "alert", class: this.classes, part: this.classes }, this.dismissible && (h("button", { key: '6ac2f33805ae8dfc8f4a9444fa98153ce5009c72', class: "btn-close", onClick: this.onDismissButtonClick }, h("span", { key: 'ad9dd25cc1c43555115192ec04ce05ec54b793d4', class: "visually-hidden" }, this.dismissLabel))), this.icon && this.icon !== 'none' && (h("post-icon", { key: `${this.bannerId}-icon`, name: this.icon })), this.hasActions ? actionBannerContent : defaultBannerContent)));
|
|
78
|
+
}
|
|
79
|
+
get host() { return getElement(this); }
|
|
80
|
+
static get watchers() { return {
|
|
81
|
+
"dismissible": ["validateDismissible"],
|
|
82
|
+
"dismissLabel": ["validateDismissLabel"],
|
|
83
|
+
"icon": ["validateIcon"],
|
|
84
|
+
"type": ["validateType"]
|
|
85
|
+
}; }
|
|
86
|
+
};
|
|
87
|
+
PostBanner.style = PostBannerStyle0;
|
|
88
|
+
|
|
89
|
+
export { PostBanner as P };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { P as post_banner } from './post-banner-
|
|
1
|
+
export { P as post_banner } from './post-banner-b0af5bd3.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
|
-
import './package-
|
|
3
|
+
import './package-f8f7bb40.js';
|
|
4
4
|
import './fade-7fd71785.js';
|
|
5
5
|
import './index-b49c9904.js';
|
|
6
6
|
import './constants-8d548297.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-6bfe6554.js';
|
|
2
|
-
import { v as version } from './package-
|
|
2
|
+
import { v as version } from './package-f8f7bb40.js';
|
|
3
3
|
import { c as checkUrl } from './check-url-a974431e.js';
|
|
4
4
|
import { d as debounce } from './debounce-abe98cc2.js';
|
|
5
5
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { P as post_breadcrumb_item, a as post_menu_item } from './post-menu-item-
|
|
1
|
+
export { P as post_breadcrumb_item, a as post_menu_item } from './post-menu-item-37f637a3.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
|
-
import './package-
|
|
3
|
+
import './package-f8f7bb40.js';
|
|
4
4
|
import './index-b49c9904.js';
|
|
5
5
|
import './constants-8d548297.js';
|
|
6
6
|
import './check-one-of-6b3ef8eb.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { P as post_breadcrumb } from './post-breadcrumb-
|
|
1
|
+
export { P as post_breadcrumb } from './post-breadcrumb-85ffd02f.js';
|
|
2
2
|
import './index-6bfe6554.js';
|
|
3
|
-
import './package-
|
|
3
|
+
import './package-f8f7bb40.js';
|
|
4
4
|
import './check-url-a974431e.js';
|
|
5
5
|
import './debounce-abe98cc2.js';
|