@swisspost/design-system-components 8.10.1 → 8.11.0
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-72b9122e.js → index-e1f32cce.js} +14 -1
- package/dist/cjs/index.cjs.js +17 -17
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{package-075febd4.js → package-34044e64.js} +1 -1
- package/dist/cjs/{post-accordion-75e6eb65.js → post-accordion-9f51fe20.js} +2 -2
- package/dist/cjs/{post-accordion-item-3d532e1c.js → post-accordion-item-60f1b7d5.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-6ca91c9a.js → post-alert-749a4f26.js} +2 -2
- package/dist/cjs/post-alert.cjs.entry.js +3 -3
- package/dist/cjs/{post-card-control-cf7f8a7b.js → post-card-control-9ac3840c.js} +2 -2
- package/dist/cjs/post-card-control.cjs.entry.js +3 -3
- package/dist/cjs/{post-collapsible-trigger-72f69145.js → post-collapsible-trigger-0733052f.js} +11 -4
- package/dist/cjs/post-collapsible_2.cjs.entry.js +3 -3
- package/dist/cjs/post-components.cjs.js +2 -2
- package/dist/cjs/{post-icon-31237866.js → post-icon-2be2402c.js} +37 -44
- package/dist/cjs/post-icon.cjs.entry.js +3 -3
- package/dist/cjs/{post-logo-d5b56fdf.js → post-logo-408aa692.js} +2 -2
- package/dist/cjs/post-logo.cjs.entry.js +3 -3
- package/dist/cjs/{post-popover-9341e98d.js → post-popover-0c87b275.js} +2 -2
- package/dist/cjs/post-popover.cjs.entry.js +3 -3
- package/dist/cjs/{post-popovercontainer-d1e24031.js → post-popovercontainer-585e6d57.js} +2 -2
- package/dist/cjs/post-popovercontainer.cjs.entry.js +3 -3
- package/dist/cjs/{post-rating-f28e9669.js → post-rating-ca7246e4.js} +2 -2
- package/dist/cjs/post-rating.cjs.entry.js +3 -3
- package/dist/cjs/{post-tab-header-88a5a2e8.js → post-tab-header-d48ea5cf.js} +2 -2
- package/dist/cjs/post-tab-header.cjs.entry.js +3 -3
- package/dist/cjs/{post-tab-panel-a8081393.js → post-tab-panel-57f6023f.js} +2 -2
- package/dist/cjs/post-tab-panel.cjs.entry.js +3 -3
- package/dist/cjs/{post-tabs-58f46013.js → post-tabs-92a4a0c8.js} +2 -2
- package/dist/cjs/post-tabs.cjs.entry.js +3 -3
- package/dist/cjs/{post-tag-7c39768f.js → post-tag-2e8d8d18.js} +2 -2
- package/dist/cjs/post-tag.cjs.entry.js +3 -3
- package/dist/cjs/{post-tooltip-0b8746e4.js → post-tooltip-33873313.js} +2 -2
- package/dist/cjs/post-tooltip.cjs.entry.js +3 -3
- package/dist/collection/animations/collapse.js +1 -1
- package/dist/collection/components/post-collapsible/post-collapsible.js +10 -3
- package/dist/collection/components/post-icon/post-icon.js +36 -43
- package/dist/components/package.js +1 -1
- package/dist/components/post-collapsible2.js +9 -2
- package/dist/components/post-icon2.js +36 -43
- package/dist/docs.json +2 -2
- package/dist/esm/{index-61528ac5.js → index-e1b64755.js} +14 -1
- package/dist/esm/index.js +17 -17
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{package-27c9b485.js → package-80969aa6.js} +1 -1
- package/dist/esm/{post-accordion-c751c053.js → post-accordion-9a583ead.js} +2 -2
- package/dist/esm/{post-accordion-item-d78c2d45.js → post-accordion-item-4414dc67.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-e12042a7.js → post-alert-57f2c870.js} +2 -2
- package/dist/esm/post-alert.entry.js +3 -3
- package/dist/esm/{post-card-control-6fbe8710.js → post-card-control-69fb2766.js} +2 -2
- package/dist/esm/post-card-control.entry.js +3 -3
- package/dist/esm/{post-collapsible-trigger-09c613c5.js → post-collapsible-trigger-63443528.js} +11 -4
- package/dist/esm/post-collapsible_2.entry.js +3 -3
- package/dist/esm/post-components.js +3 -3
- package/dist/esm/{post-icon-a3077af9.js → post-icon-ebb1aa21.js} +37 -44
- package/dist/esm/post-icon.entry.js +3 -3
- package/dist/esm/{post-logo-0af50626.js → post-logo-42ee2031.js} +2 -2
- package/dist/esm/post-logo.entry.js +3 -3
- package/dist/esm/{post-popover-8717cc25.js → post-popover-27a08ed5.js} +2 -2
- package/dist/esm/post-popover.entry.js +3 -3
- package/dist/esm/{post-popovercontainer-88ca79d7.js → post-popovercontainer-eb7aed93.js} +2 -2
- package/dist/esm/post-popovercontainer.entry.js +3 -3
- package/dist/esm/{post-rating-b93b4be6.js → post-rating-08949dd4.js} +2 -2
- package/dist/esm/post-rating.entry.js +3 -3
- package/dist/esm/{post-tab-header-5cb9ceb2.js → post-tab-header-933d9cf0.js} +2 -2
- package/dist/esm/post-tab-header.entry.js +3 -3
- package/dist/esm/{post-tab-panel-8274ad47.js → post-tab-panel-6a299e69.js} +2 -2
- package/dist/esm/post-tab-panel.entry.js +3 -3
- package/dist/esm/{post-tabs-5a5ad6d8.js → post-tabs-d35d46b3.js} +2 -2
- package/dist/esm/post-tabs.entry.js +3 -3
- package/dist/esm/{post-tag-f1b66323.js → post-tag-23b9433d.js} +2 -2
- package/dist/esm/post-tag.entry.js +3 -3
- package/dist/esm/{post-tooltip-e3cc07ce.js → post-tooltip-3bd0dc04.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-41ce2017.js → p-11845570.js} +1 -1
- package/dist/post-components/{p-2f2e2480.js → p-1c44c521.js} +1 -1
- package/dist/post-components/p-1e3b018d.entry.js +1 -0
- package/dist/post-components/p-263bd2ab.js +1 -0
- package/dist/post-components/p-28f7ed1f.entry.js +1 -0
- package/dist/post-components/p-2980c6be.entry.js +1 -0
- package/dist/post-components/p-2a0cf622.entry.js +1 -0
- package/dist/post-components/p-3a272ff5.js +1 -0
- package/dist/post-components/{p-343f6de1.js → p-3eab790d.js} +2 -2
- package/dist/post-components/p-3f946c8a.entry.js +1 -0
- package/dist/post-components/{p-8de5fb0c.js → p-45ec3b5f.js} +1 -1
- package/dist/post-components/p-464294a1.js +1 -0
- package/dist/post-components/{p-2e84ed24.js → p-4b292bc5.js} +1 -1
- package/dist/post-components/{p-87c12206.js → p-4d592e53.js} +1 -1
- package/dist/post-components/p-52827246.entry.js +1 -0
- package/dist/post-components/{p-624edd79.js → p-6f1a9a7d.js} +1 -1
- package/dist/post-components/{p-d6a6a17e.js → p-70061637.js} +1 -1
- package/dist/post-components/{p-82687973.entry.js → p-8454a987.entry.js} +1 -1
- package/dist/post-components/p-87acb7ec.entry.js +1 -0
- package/dist/post-components/p-8ab565a6.js +1 -0
- package/dist/post-components/p-a9abe4fa.entry.js +1 -0
- package/dist/post-components/{p-6d694626.js → p-b040c9b2.js} +1 -1
- package/dist/post-components/p-bba92665.entry.js +1 -0
- package/dist/post-components/{p-c9fed82f.js → p-c8e60eaa.js} +1 -1
- package/dist/post-components/{p-fbb37b73.js → p-cbea07db.js} +1 -1
- package/dist/post-components/p-d5c8d0f0.entry.js +1 -0
- package/dist/post-components/p-da006e65.entry.js +1 -0
- package/dist/post-components/{p-c5ced99b.js → p-df4a6696.js} +1 -1
- package/dist/post-components/p-e53a790c.entry.js +1 -0
- package/dist/post-components/p-e8f67578.entry.js +1 -0
- package/dist/post-components/{p-aef5acbc.js → p-ea083d7e.js} +1 -1
- package/dist/post-components/p-ef0cf8b4.entry.js +1 -0
- package/dist/post-components/post-components.esm.js +1 -1
- package/dist/types/animations/collapse.d.ts +1 -0
- package/loaders/package.js +1 -1
- package/loaders/post-collapsible2.js +9 -2
- package/loaders/post-icon2.js +36 -43
- package/package.json +2 -2
- package/dist/post-components/p-0114ebad.entry.js +0 -1
- package/dist/post-components/p-0d5caecd.entry.js +0 -1
- package/dist/post-components/p-1116dd9c.js +0 -1
- package/dist/post-components/p-17a0403b.entry.js +0 -1
- package/dist/post-components/p-1817b8af.entry.js +0 -1
- package/dist/post-components/p-1ce84d68.js +0 -1
- package/dist/post-components/p-2a040a47.entry.js +0 -1
- package/dist/post-components/p-30964d83.entry.js +0 -1
- package/dist/post-components/p-33c4caca.entry.js +0 -1
- package/dist/post-components/p-41c22c08.js +0 -1
- package/dist/post-components/p-58f4ce1d.entry.js +0 -1
- package/dist/post-components/p-6b2cae0d.js +0 -1
- package/dist/post-components/p-905d12b1.entry.js +0 -1
- package/dist/post-components/p-abf90293.entry.js +0 -1
- package/dist/post-components/p-c54bb204.entry.js +0 -1
- package/dist/post-components/p-cadfb16a.entry.js +0 -1
- package/dist/post-components/p-da233a1c.entry.js +0 -1
- package/dist/post-components/p-ee42e275.entry.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
const attributeObserver = require('./attribute-observer-10f08c04.js');
|
|
6
6
|
|
|
7
7
|
const postPopoverCss = "/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */.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:4px;color:var(--post-gray-80);transition:opacity 250ms,border-color 250ms,background-color 250ms,color 250ms;cursor:pointer}.btn-close{outline-style:none !important;outline-offset:2px !important;outline-width:2px !important;outline-color:var(--post-focus-color) !important}.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-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: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{-webkit-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\");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:1.5rem;width:1.5rem}:where(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .btn-close{color:var(--post-contrast-color)}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:var(--post-contrast-color)}.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}*{box-sizing:border-box}:host{--post-contrast-color:#fff;--post-bg-rgb:51, 51, 51;display:block}.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}.popover-container{display:flex;align-items:self-start;padding:.5em;min-width:160px;max-width:280px}@media (max-width: 599.98px){.popover-container{max-width:100%}}.popover-content{padding:.5em;flex-grow:1}.btn-close{color:inherit}";
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postPopover = require('./post-popover-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postPopover = require('./post-popover-0c87b275.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
require('./attribute-observer-10f08c04.js');
|
|
9
9
|
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Custom positioning reference element.
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postPopovercontainer = require('./post-popovercontainer-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postPopovercontainer = require('./post-popovercontainer-585e6d57.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
|
|
6
6
|
const postRatingCss = "/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */:host{display:inline-block}.rating{display:flex;flex-wrap:wrap;overflow:hidden;margin:0 -0.25rem;border-radius:4px}.rating .star{--post-rating-star-stroke:hsl(0, 0%, 40%);--post-rating-star-fill:#fff;position:relative;width:2rem;height:2rem;cursor:pointer}.rating .star .stroke,.rating .star .fill{display:block;width:100%;height:100%;transition:all ease 100ms}.rating .star .stroke{position:absolute;inset:auto;z-index:1;color:var(--post-rating-star-stroke)}.rating .star .fill{margin:1px;width:calc(100% - 2px);height:calc(100% - 2px);color:var(--post-rating-star-fill)}.rating .star.before-hover{--post-rating-star-stroke:hsl(0, 0%, 40%);--post-rating-star-fill:#fc0}.rating .star.active{--post-rating-star-stroke:hsl(0, 0%, 20%);--post-rating-star-fill:#fc0}.rating .star.hover{--post-rating-star-stroke:hsl(0, 0%, 40%);--post-rating-star-fill:#fc0}.rating .star.after-active{--post-rating-star-stroke:hsl(0, 0%, 40%);--post-rating-star-fill:hsl(0, 0%, 80%)}.rating :focus{outline:none}.rating:focus-visible{outline-offset:2px;outline:2px solid #1976c8}.rating[aria-readonly=true] .star,.rating[aria-disabled=true] .star{cursor:default}.rating[aria-disabled=true] .star{--post-rating-star-stroke:hsl(0, 0%, 60%);--post-rating-star-fill:#fff}.rating[aria-disabled=true] .star.active{cursor:default;--post-rating-star-stroke:hsl(0, 0%, 60%);--post-rating-star-fill:hsl(0, 0%, 90%)}";
|
|
7
7
|
const PostRatingStyle0 = postRatingCss;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postRating = require('./post-rating-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postRating = require('./post-rating-ca7246e4.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
const checkNonEmpty = require('./check-non-empty-eeaa8f77.js');
|
|
6
6
|
|
|
7
7
|
const postTabHeaderCss = ".tab-title[role=tab]{display:inline-block;cursor:pointer;position:relative;box-sizing:border-box;padding:1rem;transition:background-color 100ms;border-right:1px solid rgba(0,0,0,0);border-left:1px solid rgba(0,0,0,0);outline-color:currentColor;opacity:.7;color:var(--post-contrast-color);text-decoration:none;background-color:rgba(0,0,0,0)}.tab-title[role=tab]:focus{background-color:unset;color:var(--post-contrast-color)}.tab-title[role=tab]:hover{opacity:1;background-color:rgba(var(--post-contrast-color-rgb), 0.6);color:var(--post-contrast-color-inverted)}.tab-title[role=tab]:focus-visible{outline:rgba(0,0,0,0);opacity:1;background-color:rgba(var(--post-contrast-color-rgb), 0.6);color:var(--post-contrast-color-inverted);box-shadow:none}.tab-title[role=tab]:focus-visible::after{content:\"\";display:block;position:absolute;top:2px;right:1px;bottom:0;left:1px;box-shadow:0 0 0 1px #fff,0 0 0 2px #333}.tab-title[role=tab].active{z-index:1;border-right-color:#ccc;border-left-color:#ccc;opacity:1;background-color:var(--post-contrast-color-inverted);color:var(--post-contrast-color);font-weight:700}.tab-title[role=tab].active::before{content:\"\";display:block;position:absolute;top:0;right:-1px;left:-1px;height:.25rem;background-color:#fc0}:where(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .tab-title[role=tab]:hover{background-color:rgba(255,255,255,.2)}:where(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .tab-title[role=tab]:focus-visible{background-color:rgba(255,255,255,.2)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.tab-title[role=tab]{opacity:1;border-left-color:Canvas;border-right-color:Canvas;color:LinkText}.tab-title[role=tab]:hover,.tab-title[role=tab]:focus,.tab-title[role=tab]:focus-within,.tab-title[role=tab]:focus-visible{outline:2px solid Highlight;outline-offset:-0.25rem}.tab-title[role=tab].active{border-left-color:ButtonText;border-right-color:ButtonText;color:Highlight}.tab-title[role=tab].active::before{background-color:Highlight}}.bg-yellow .tab-title{background-color:#fc0}.bg-yellow .tab-title.active{background-color:#fc0}.bg-yellow .nav-item{background-color:#fc0}.bg-white .tab-title{background-color:#fff}.bg-white .tab-title.active{background-color:#fff}.bg-white .nav-item{background-color:#fff}.bg-light .tab-title{background-color:#faf9f8}.bg-light .tab-title.active{background-color:#faf9f8}.bg-light .nav-item{background-color:#faf9f8}.bg-gray .tab-title{background-color:#f4f3f1}.bg-gray .tab-title.active{background-color:#f4f3f1}.bg-gray .nav-item{background-color:#f4f3f1}.bg-dark .tab-title{background-color:#333}.bg-dark .tab-title.active{background-color:#333}.bg-dark .nav-item{background-color:#333}.bg-black .tab-title{background-color:#000}.bg-black .tab-title.active{background-color:#000}.bg-black .nav-item{background-color:#000}.bg-primary .tab-title{background-color:#333}.bg-primary .tab-title.active{background-color:#333}.bg-primary .nav-item{background-color:#333}.bg-secondary .tab-title{background-color:#666}.bg-secondary .tab-title.active{background-color:#666}.bg-secondary .nav-item{background-color:#666}.bg-success .tab-title{background-color:#2c871d}.bg-success .tab-title.active{background-color:#2c871d}.bg-success .nav-item{background-color:#2c871d}.bg-warning .tab-title{background-color:#f49e00}.bg-warning .tab-title.active{background-color:#f49e00}.bg-warning .nav-item{background-color:#f49e00}.bg-error .tab-title{background-color:#a51728}.bg-error .tab-title.active{background-color:#a51728}.bg-error .nav-item{background-color:#a51728}.bg-info .tab-title{background-color:#cce4ee}.bg-info .tab-title.active{background-color:#cce4ee}.bg-info .nav-item{background-color:#cce4ee}.bg-success-background .tab-title{background-color:#c0debb}.bg-success-background .tab-title.active{background-color:#c0debb}.bg-success-background .nav-item{background-color:#c0debb}.bg-warning-background .tab-title{background-color:#fce2b2}.bg-warning-background .tab-title.active{background-color:#fce2b2}.bg-warning-background .nav-item{background-color:#fce2b2}.bg-error-background .tab-title{background-color:#ffdade}.bg-error-background .tab-title.active{background-color:#ffdade}.bg-error-background .nav-item{background-color:#ffdade}.bg-nightblue .tab-title{background-color:#004976}.bg-nightblue .tab-title.active{background-color:#004976}.bg-nightblue .nav-item{background-color:#004976}.bg-nightblue-bright .tab-title{background-color:#0076a8}.bg-nightblue-bright .tab-title.active{background-color:#0076a8}.bg-nightblue-bright .nav-item{background-color:#0076a8}.bg-petrol .tab-title{background-color:#006d68}.bg-petrol .tab-title.active{background-color:#006d68}.bg-petrol .nav-item{background-color:#006d68}.bg-petrol-bright .tab-title{background-color:#00968f}.bg-petrol-bright .tab-title.active{background-color:#00968f}.bg-petrol-bright .nav-item{background-color:#00968f}.bg-coral .tab-title{background-color:#9e2a2f}.bg-coral .tab-title.active{background-color:#9e2a2f}.bg-coral .nav-item{background-color:#9e2a2f}.bg-coral-bright .tab-title{background-color:#e03c31}.bg-coral-bright .tab-title.active{background-color:#e03c31}.bg-coral-bright .nav-item{background-color:#e03c31}.bg-olive .tab-title{background-color:#716135}.bg-olive .tab-title.active{background-color:#716135}.bg-olive .nav-item{background-color:#716135}.bg-olive-bright .tab-title{background-color:#aa9d2e}.bg-olive-bright .tab-title.active{background-color:#aa9d2e}.bg-olive-bright .nav-item{background-color:#aa9d2e}.bg-purple .tab-title{background-color:#80276c}.bg-purple .tab-title.active{background-color:#80276c}.bg-purple .nav-item{background-color:#80276c}.bg-purple-bright .tab-title{background-color:#c5299b}.bg-purple-bright .tab-title.active{background-color:#c5299b}.bg-purple-bright .nav-item{background-color:#c5299b}.bg-aubergine .tab-title{background-color:#523178}.bg-aubergine .tab-title.active{background-color:#523178}.bg-aubergine .nav-item{background-color:#523178}.bg-aubergine-bright .tab-title{background-color:#7566a0}.bg-aubergine-bright .tab-title.active{background-color:#7566a0}.bg-aubergine-bright .nav-item{background-color:#7566a0}[class*=bg-] .tab-title.active:focus::after{background-color:rgba(255,255,255,.2)}@supports selector(*:focus-visible){[class*=bg-] .tab-title.active:focus::after{background-color:unset}[class*=bg-] .tab-title.active:focus-visible::after{background-color:rgba(255,255,255,.2)}}/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */:host{display:block}.tab-title{padding:0;overflow:visible;border:0;background:none;color:inherit;font:inherit;-webkit-user-select:none;user-select:none;appearance:button}";
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postTabHeader = require('./post-tab-header-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postTabHeader = require('./post-tab-header-d48ea5cf.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
require('./check-non-empty-eeaa8f77.js');
|
|
9
9
|
require('./constants-238701d3.js');
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
|
|
6
6
|
const postTabPanelCss = ":host{display:none}";
|
|
7
7
|
const PostTabPanelStyle0 = postTabPanelCss;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postTabPanel = require('./post-tab-panel-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postTabPanel = require('./post-tab-panel-57f6023f.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
const fade = require('./fade-35a3633a.js');
|
|
6
6
|
|
|
7
7
|
/**
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postTabs = require('./post-tabs-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postTabs = require('./post-tabs-92a4a0c8.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
require('./fade-35a3633a.js');
|
|
9
9
|
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
|
|
6
6
|
const postTagCss = "/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */.tag,.tag:where(:has(:not(pre))){--post-tag-bg:hsl(0, 0%, 90%);--post-tag-fg:#000;display:inline-flex;align-items:center;gap:.25rem;padding:0 .5rem;max-width:100%;background-color:var(--post-tag-bg);border:1px solid rgba(0,0,0,0);border-radius:.25rem;font-size:1rem;line-height:1.875rem;white-space:nowrap;color:var(--post-tag-fg)}.tag post-icon,.tag:where(:has(:not(pre))) post-icon{flex:0 0 auto;width:1.25rem;height:1.25rem}.tag .tag-text,.tag:where(:has(:not(pre))) .tag-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tag .tag-text svg,.tag .tag-text img,.tag:where(:has(:not(pre))) .tag-text svg,.tag:where(:has(:not(pre))) .tag-text img{display:inline-block;height:1.25rem !important;vertical-align:text-top}.tag.tag-sm,.tag:where(:has(:not(pre))).tag-sm{line-height:1.5rem}.tag.tag-sm .tag-icon,.tag:where(:has(:not(pre))).tag-sm .tag-icon{width:1rem;height:1rem}.tag.tag-white,.tag:where(:has(:not(pre))).tag-white{--post-tag-bg:#fff;--post-tag-fg:#000}.tag.tag-yellow,.tag:where(:has(:not(pre))).tag-yellow{--post-tag-bg:#fc0;--post-tag-fg:#000}.tag.tag-success,.tag:where(:has(:not(pre))).tag-success{--post-tag-bg:#2c871d;--post-tag-fg:#fff}.tag.tag-warning,.tag:where(:has(:not(pre))).tag-warning{--post-tag-bg:#f49e00;--post-tag-fg:#000}.tag.tag-danger,.tag:where(:has(:not(pre))).tag-danger{--post-tag-bg:#a51728;--post-tag-fg:#fff}.tag.tag-info,.tag:where(:has(:not(pre))).tag-info{--post-tag-bg:#cce4ee;--post-tag-fg:#000}.tag.tag-white,.tag:where(:has(:not(pre))).tag-white{border-color:var(--post-contrast-color)}pre .tag,pre .tag:where(:has(:not(pre))){display:inline;padding:initial;max-width:initial;background:initial;border:initial;border-radius:initial;font-size:inherit;line-height:inherit;white-space:unset}*,*:before,*:after{box-sizing:border-box}.tag-text ::slotted(svg),.tag-text ::slotted(img){display:inline-block !important;height:1.25rem !important;vertical-align:text-top !important}";
|
|
7
7
|
const PostTagStyle0 = postTagCss;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postTag = require('./post-tag-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postTag = require('./post-tag-2e8d8d18.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const _package = require('./package-
|
|
3
|
+
const index = require('./index-e1f32cce.js');
|
|
4
|
+
const _package = require('./package-34044e64.js');
|
|
5
5
|
const attributeObserver = require('./attribute-observer-10f08c04.js');
|
|
6
6
|
const index$1 = require('./index-01f30442.js');
|
|
7
7
|
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const postTooltip = require('./post-tooltip-
|
|
6
|
-
require('./index-
|
|
7
|
-
require('./package-
|
|
5
|
+
const postTooltip = require('./post-tooltip-33873313.js');
|
|
6
|
+
require('./index-e1f32cce.js');
|
|
7
|
+
require('./package-34044e64.js');
|
|
8
8
|
require('./attribute-observer-10f08c04.js');
|
|
9
9
|
require('./index-01f30442.js');
|
|
10
10
|
require('./constants-238701d3.js');
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const collapseDuration = 350;
|
|
2
2
|
const collapseEasing = 'ease';
|
|
3
|
-
const collapsedKeyframe = { height: '0', overflow: 'hidden' };
|
|
3
|
+
export const collapsedKeyframe = { height: '0', overflow: 'hidden' };
|
|
4
4
|
const animationOptions = {
|
|
5
5
|
duration: collapseDuration,
|
|
6
6
|
easing: collapseEasing,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { h, Host, } from "@stencil/core";
|
|
2
2
|
import { version } from "../../../../package";
|
|
3
|
-
import { collapse, expand } from "../../animations/collapse";
|
|
3
|
+
import { collapse, collapsedKeyframe, expand } from "../../animations/collapse";
|
|
4
4
|
import { checkEmptyOrType, isMotionReduced } from "../../utils/index";
|
|
5
5
|
/**
|
|
6
6
|
* @slot default - Slot for placing content within the collapsible element.
|
|
@@ -13,7 +13,14 @@ export class PostCollapsible {
|
|
|
13
13
|
}
|
|
14
14
|
collapsedChange() {
|
|
15
15
|
checkEmptyOrType(this.collapsed, 'boolean', 'The `collapsed` property of the `post-collapsible` must be a boolean.');
|
|
16
|
-
|
|
16
|
+
if (!this.isLoaded) {
|
|
17
|
+
const expandedKeyframe = { height: 'auto', overflow: 'visible' };
|
|
18
|
+
Object.assign(this.host.style, this.collapsed ? collapsedKeyframe : expandedKeyframe);
|
|
19
|
+
this.isOpen = !this.collapsed;
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
void this.toggle(!this.collapsed);
|
|
23
|
+
}
|
|
17
24
|
}
|
|
18
25
|
componentDidLoad() {
|
|
19
26
|
this.collapsedChange();
|
|
@@ -47,7 +54,7 @@ export class PostCollapsible {
|
|
|
47
54
|
triggers.forEach(trigger => trigger.update());
|
|
48
55
|
}
|
|
49
56
|
render() {
|
|
50
|
-
return (h(Host, { key: '
|
|
57
|
+
return (h(Host, { key: 'ca849a2c9845cca621404f364dfd3973e3883309', "data-version": version }, h("slot", { key: '276f555d524d9c22856146611df3de69303511e4' })));
|
|
51
58
|
}
|
|
52
59
|
static get is() { return "post-collapsible"; }
|
|
53
60
|
static get encapsulation() { return "shadow"; }
|
|
@@ -47,52 +47,45 @@ export class PostIcon {
|
|
|
47
47
|
validateScale(newValue = this.scale) {
|
|
48
48
|
checkEmptyOrType(newValue, 'number', 'The post-icon "scale" prop should be a number.');
|
|
49
49
|
}
|
|
50
|
-
// Construct the icon
|
|
50
|
+
// Construct the icon URL according to the following rules:
|
|
51
|
+
// - URL = current domain + base[href] + meta[data-post-icon-base] (or component base)
|
|
52
|
+
// - If base[href] is not relative, it's used instead of current domain + base[href]
|
|
53
|
+
// - If meta[data-post-icon-base] (or component base) is not relative, it's used as is
|
|
51
54
|
getUrl() {
|
|
52
|
-
var _a, _b
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
const
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
55
|
+
var _a, _b;
|
|
56
|
+
const fileName = `${this.name}.svg`;
|
|
57
|
+
const currentDomain = window.location.origin;
|
|
58
|
+
const baseHref = ((_a = document.querySelector('base[href]')) === null || _a === void 0 ? void 0 : _a.getAttribute('href')) || '';
|
|
59
|
+
const isBaseHrefAbsolute = /^https?:\/\//.test(baseHref);
|
|
60
|
+
const metaIconBase = ((_b = document
|
|
61
|
+
.querySelector('meta[name="design-system-settings"]')) === null || _b === void 0 ? void 0 : _b.getAttribute('data-post-icon-base')) || '';
|
|
62
|
+
const iconBase = this.base || metaIconBase;
|
|
63
|
+
const isIconBaseAbsolute = /^https?:\/\//.test(iconBase);
|
|
64
|
+
const normalizedBaseHref = normalizeUrl(baseHref);
|
|
65
|
+
const normalizedIconBase = normalizeUrl(iconBase);
|
|
66
|
+
function normalizeUrl(url) {
|
|
67
|
+
if (!url)
|
|
68
|
+
return '';
|
|
69
|
+
return url.endsWith('/') ? url : `${url}/`;
|
|
70
|
+
}
|
|
66
71
|
let url;
|
|
67
|
-
if (
|
|
68
|
-
|
|
72
|
+
if (isIconBaseAbsolute) {
|
|
73
|
+
// If icon base is absolute, use it as is
|
|
74
|
+
url = `${normalizedIconBase}${fileName}`;
|
|
69
75
|
}
|
|
70
|
-
else {
|
|
71
|
-
|
|
76
|
+
else if (isBaseHrefAbsolute) {
|
|
77
|
+
// If baseHref is absolute, don't use current domain
|
|
78
|
+
url = `${normalizedBaseHref}${normalizedIconBase}${fileName}`;
|
|
72
79
|
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
}
|
|
80
|
-
function getUrlObject(url) {
|
|
81
|
-
if (url) {
|
|
82
|
-
return definesDomain(url) ? new URL(url) : new URL(url, window.location.origin);
|
|
83
|
-
}
|
|
84
|
-
else {
|
|
85
|
-
return null;
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
function definesDomain(url) {
|
|
89
|
-
return url ? /^https?:\/\//.test(url) : false;
|
|
90
|
-
}
|
|
91
|
-
function definesSlug(url) {
|
|
92
|
-
const urlObject = getUrlObject(url);
|
|
93
|
-
return Boolean(/^\/.+/.test(urlObject === null || urlObject === void 0 ? void 0 : urlObject.pathname));
|
|
94
|
-
}
|
|
80
|
+
else if (iconBase || baseHref) {
|
|
81
|
+
// Standard case: domain + baseHref + iconBase
|
|
82
|
+
url = `${currentDomain}${normalizedBaseHref}${normalizedIconBase}${fileName}`;
|
|
83
|
+
}
|
|
84
|
+
else {
|
|
85
|
+
// Fallback to CDN if no paths are specified
|
|
86
|
+
url = `${CDN_URL}/${fileName}`;
|
|
95
87
|
}
|
|
88
|
+
return url.replace(/([^:])\/\//g, '$1/');
|
|
96
89
|
}
|
|
97
90
|
getStyles() {
|
|
98
91
|
const url = this.getUrl();
|
|
@@ -115,7 +108,7 @@ export class PostIcon {
|
|
|
115
108
|
this.validateAnimation();
|
|
116
109
|
}
|
|
117
110
|
render() {
|
|
118
|
-
return (h(Host, { key: '
|
|
111
|
+
return (h(Host, { key: '9492ae6c7871d0e0a4469c2d5acba0b7113c79ff', "data-version": version }, h("span", { key: 'c3225cf8dbd4133d5517f78daf9e104bf18b4a23', style: this.getStyles() })));
|
|
119
112
|
}
|
|
120
113
|
static get is() { return "post-icon"; }
|
|
121
114
|
static get encapsulation() { return "shadow"; }
|
|
@@ -223,7 +216,7 @@ export class PostIcon {
|
|
|
223
216
|
"text": "The name/id of the icon (e.g. 1000, 1001, ...)."
|
|
224
217
|
},
|
|
225
218
|
"attribute": "name",
|
|
226
|
-
"reflect":
|
|
219
|
+
"reflect": true
|
|
227
220
|
},
|
|
228
221
|
"rotate": {
|
|
229
222
|
"type": "number",
|
|
@@ -39,7 +39,14 @@ const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible e
|
|
|
39
39
|
}
|
|
40
40
|
collapsedChange() {
|
|
41
41
|
checkEmptyOrType(this.collapsed, 'boolean', 'The `collapsed` property of the `post-collapsible` must be a boolean.');
|
|
42
|
-
|
|
42
|
+
if (!this.isLoaded) {
|
|
43
|
+
const expandedKeyframe = { height: 'auto', overflow: 'visible' };
|
|
44
|
+
Object.assign(this.host.style, this.collapsed ? collapsedKeyframe : expandedKeyframe);
|
|
45
|
+
this.isOpen = !this.collapsed;
|
|
46
|
+
}
|
|
47
|
+
else {
|
|
48
|
+
void this.toggle(!this.collapsed);
|
|
49
|
+
}
|
|
43
50
|
}
|
|
44
51
|
componentDidLoad() {
|
|
45
52
|
this.collapsedChange();
|
|
@@ -73,7 +80,7 @@ const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible e
|
|
|
73
80
|
triggers.forEach(trigger => trigger.update());
|
|
74
81
|
}
|
|
75
82
|
render() {
|
|
76
|
-
return (h(Host, { key: '
|
|
83
|
+
return (h(Host, { key: 'ca849a2c9845cca621404f364dfd3973e3883309', "data-version": version }, h("slot", { key: '276f555d524d9c22856146611df3de69303511e4' })));
|
|
77
84
|
}
|
|
78
85
|
get host() { return this; }
|
|
79
86
|
static get watchers() { return {
|
|
@@ -53,52 +53,45 @@ const PostIcon = /*@__PURE__*/ proxyCustomElement(class PostIcon extends HTMLEle
|
|
|
53
53
|
validateScale(newValue = this.scale) {
|
|
54
54
|
checkEmptyOrType(newValue, 'number', 'The post-icon "scale" prop should be a number.');
|
|
55
55
|
}
|
|
56
|
-
// Construct the icon
|
|
56
|
+
// Construct the icon URL according to the following rules:
|
|
57
|
+
// - URL = current domain + base[href] + meta[data-post-icon-base] (or component base)
|
|
58
|
+
// - If base[href] is not relative, it's used instead of current domain + base[href]
|
|
59
|
+
// - If meta[data-post-icon-base] (or component base) is not relative, it's used as is
|
|
57
60
|
getUrl() {
|
|
58
|
-
var _a, _b
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
const
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
const
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
61
|
+
var _a, _b;
|
|
62
|
+
const fileName = `${this.name}.svg`;
|
|
63
|
+
const currentDomain = window.location.origin;
|
|
64
|
+
const baseHref = ((_a = document.querySelector('base[href]')) === null || _a === void 0 ? void 0 : _a.getAttribute('href')) || '';
|
|
65
|
+
const isBaseHrefAbsolute = /^https?:\/\//.test(baseHref);
|
|
66
|
+
const metaIconBase = ((_b = document
|
|
67
|
+
.querySelector('meta[name="design-system-settings"]')) === null || _b === void 0 ? void 0 : _b.getAttribute('data-post-icon-base')) || '';
|
|
68
|
+
const iconBase = this.base || metaIconBase;
|
|
69
|
+
const isIconBaseAbsolute = /^https?:\/\//.test(iconBase);
|
|
70
|
+
const normalizedBaseHref = normalizeUrl(baseHref);
|
|
71
|
+
const normalizedIconBase = normalizeUrl(iconBase);
|
|
72
|
+
function normalizeUrl(url) {
|
|
73
|
+
if (!url)
|
|
74
|
+
return '';
|
|
75
|
+
return url.endsWith('/') ? url : `${url}/`;
|
|
76
|
+
}
|
|
72
77
|
let url;
|
|
73
|
-
if (
|
|
74
|
-
|
|
78
|
+
if (isIconBaseAbsolute) {
|
|
79
|
+
// If icon base is absolute, use it as is
|
|
80
|
+
url = `${normalizedIconBase}${fileName}`;
|
|
75
81
|
}
|
|
76
|
-
else {
|
|
77
|
-
|
|
82
|
+
else if (isBaseHrefAbsolute) {
|
|
83
|
+
// If baseHref is absolute, don't use current domain
|
|
84
|
+
url = `${normalizedBaseHref}${normalizedIconBase}${fileName}`;
|
|
78
85
|
}
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
}
|
|
86
|
-
function getUrlObject(url) {
|
|
87
|
-
if (url) {
|
|
88
|
-
return definesDomain(url) ? new URL(url) : new URL(url, window.location.origin);
|
|
89
|
-
}
|
|
90
|
-
else {
|
|
91
|
-
return null;
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
function definesDomain(url) {
|
|
95
|
-
return url ? /^https?:\/\//.test(url) : false;
|
|
96
|
-
}
|
|
97
|
-
function definesSlug(url) {
|
|
98
|
-
const urlObject = getUrlObject(url);
|
|
99
|
-
return Boolean(/^\/.+/.test(urlObject === null || urlObject === void 0 ? void 0 : urlObject.pathname));
|
|
100
|
-
}
|
|
86
|
+
else if (iconBase || baseHref) {
|
|
87
|
+
// Standard case: domain + baseHref + iconBase
|
|
88
|
+
url = `${currentDomain}${normalizedBaseHref}${normalizedIconBase}${fileName}`;
|
|
89
|
+
}
|
|
90
|
+
else {
|
|
91
|
+
// Fallback to CDN if no paths are specified
|
|
92
|
+
url = `${CDN_URL}/${fileName}`;
|
|
101
93
|
}
|
|
94
|
+
return url.replace(/([^:])\/\//g, '$1/');
|
|
102
95
|
}
|
|
103
96
|
getStyles() {
|
|
104
97
|
const url = this.getUrl();
|
|
@@ -121,7 +114,7 @@ const PostIcon = /*@__PURE__*/ proxyCustomElement(class PostIcon extends HTMLEle
|
|
|
121
114
|
this.validateAnimation();
|
|
122
115
|
}
|
|
123
116
|
render() {
|
|
124
|
-
return (h(Host, { key: '
|
|
117
|
+
return (h(Host, { key: '9492ae6c7871d0e0a4469c2d5acba0b7113c79ff', "data-version": version }, h("span", { key: 'c3225cf8dbd4133d5517f78daf9e104bf18b4a23', style: this.getStyles() })));
|
|
125
118
|
}
|
|
126
119
|
get host() { return this; }
|
|
127
120
|
static get watchers() { return {
|
|
@@ -139,7 +132,7 @@ const PostIcon = /*@__PURE__*/ proxyCustomElement(class PostIcon extends HTMLEle
|
|
|
139
132
|
"base": [1],
|
|
140
133
|
"flipH": [4, "flip-h"],
|
|
141
134
|
"flipV": [4, "flip-v"],
|
|
142
|
-
"name": [
|
|
135
|
+
"name": [513],
|
|
143
136
|
"rotate": [2],
|
|
144
137
|
"scale": [2]
|
|
145
138
|
}, undefined, {
|
package/dist/docs.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2025-
|
|
2
|
+
"timestamp": "2025-06-23T11:06:35",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
5
|
"version": "4.19.2",
|
|
@@ -1229,7 +1229,7 @@
|
|
|
1229
1229
|
},
|
|
1230
1230
|
"mutable": false,
|
|
1231
1231
|
"attr": "name",
|
|
1232
|
-
"reflectToAttr":
|
|
1232
|
+
"reflectToAttr": true,
|
|
1233
1233
|
"docs": "The name/id of the icon (e.g. 1000, 1001, ...).",
|
|
1234
1234
|
"docsTags": [],
|
|
1235
1235
|
"values": [
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const NAMESPACE = 'post-components';
|
|
2
|
-
const BUILD = /* post-components */ { allRenderFn: false, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: true, hasRenderFn: true, hostListener: true, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: true, hydratedClass: false, hydratedSelectorName: "data-hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: true, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: true, propString: true, reflect:
|
|
2
|
+
const BUILD = /* post-components */ { allRenderFn: false, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: true, hasRenderFn: true, hostListener: true, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: true, hydratedClass: false, hydratedSelectorName: "data-hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: true, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: true, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: true, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: true, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: true, watchCallback: true };
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
5
|
Stencil Client Platform v4.19.2 | MIT Licensed | https://stenciljs.com
|
|
@@ -1029,6 +1029,12 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1029
1029
|
const oldVNode = hostRef.$vnode$ || newVNode(null, null);
|
|
1030
1030
|
const rootVnode = isHost(renderFnResults) ? renderFnResults : h(null, null, renderFnResults);
|
|
1031
1031
|
hostTagName = hostElm.tagName;
|
|
1032
|
+
if (cmpMeta.$attrsToReflect$) {
|
|
1033
|
+
rootVnode.$attrs$ = rootVnode.$attrs$ || {};
|
|
1034
|
+
cmpMeta.$attrsToReflect$.map(
|
|
1035
|
+
([propName, attribute]) => rootVnode.$attrs$[attribute] = hostElm[propName]
|
|
1036
|
+
);
|
|
1037
|
+
}
|
|
1032
1038
|
if (isInitialLoad && rootVnode.$attrs$) {
|
|
1033
1039
|
for (const key of Object.keys(rootVnode.$attrs$)) {
|
|
1034
1040
|
if (hostElm.hasAttribute(key) && !["key", "ref", "style", "class"].includes(key)) {
|
|
@@ -1402,8 +1408,12 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1402
1408
|
/* @__PURE__ */ new Set([
|
|
1403
1409
|
...Object.keys((_b = cmpMeta.$watchers$) != null ? _b : {}),
|
|
1404
1410
|
...members.filter(([_, m]) => m[0] & 15 /* HasAttribute */).map(([propName, m]) => {
|
|
1411
|
+
var _a2;
|
|
1405
1412
|
const attrName = m[1] || propName;
|
|
1406
1413
|
attrNameToPropName.set(attrName, propName);
|
|
1414
|
+
if (m[0] & 512 /* ReflectAttr */) {
|
|
1415
|
+
(_a2 = cmpMeta.$attrsToReflect$) == null ? void 0 : _a2.push([propName, attrName]);
|
|
1416
|
+
}
|
|
1407
1417
|
return attrName;
|
|
1408
1418
|
})
|
|
1409
1419
|
])
|
|
@@ -1596,6 +1606,9 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1596
1606
|
{
|
|
1597
1607
|
cmpMeta.$listeners$ = compactMeta[3];
|
|
1598
1608
|
}
|
|
1609
|
+
{
|
|
1610
|
+
cmpMeta.$attrsToReflect$ = [];
|
|
1611
|
+
}
|
|
1599
1612
|
{
|
|
1600
1613
|
cmpMeta.$watchers$ = (_a2 = compactMeta[4]) != null ? _a2 : {};
|
|
1601
1614
|
}
|