@swisspost/design-system-components 10.0.0-next.38 → 10.0.0-next.39
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-2b2b85e5.js +96 -0
- package/dist/cjs/index.cjs.js +23 -27
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{package-3e61e6f3.js → package-29dc73af.js} +1 -1
- package/dist/cjs/placement-b2bb6ec4.js +18 -0
- package/dist/cjs/{post-accordion-e54524be.js → post-accordion-c433c493.js} +8 -8
- package/dist/cjs/{post-accordion-item-86f11a16.js → post-accordion-item-8d5a301d.js} +5 -5
- package/dist/cjs/post-accordion-item.cjs.entry.js +3 -7
- package/dist/cjs/post-accordion.cjs.entry.js +3 -3
- package/dist/cjs/{post-avatar-22bfd12e.js → post-avatar-421043df.js} +21 -4
- package/dist/cjs/post-avatar.cjs.entry.js +3 -4
- package/dist/cjs/{post-back-to-top-f682ea05.js → post-back-to-top-3cca3803.js} +8 -11
- package/dist/cjs/post-back-to-top.cjs.entry.js +3 -5
- package/dist/cjs/{post-banner-5c749a94.js → post-banner-2e99c9d8.js} +12 -17
- package/dist/cjs/post-banner.cjs.entry.js +3 -8
- package/dist/cjs/post-breadcrumb-item_2.cjs.entry.js +3 -7
- package/dist/cjs/{post-breadcrumbs-76f55ae5.js → post-breadcrumbs-1be50860.js} +13 -7
- package/dist/cjs/post-breadcrumbs.cjs.entry.js +3 -3
- package/dist/cjs/{post-card-control-161a7102.js → post-card-control-0bfdad92.js} +42 -21
- package/dist/cjs/post-card-control.cjs.entry.js +3 -5
- package/dist/cjs/post-closebutton_15.cjs.entry.js +5 -9
- package/dist/cjs/{post-collapsible-trigger-6cdf4481.js → post-collapsible-trigger-4180b218.js} +5 -8
- package/dist/cjs/post-collapsible_2.cjs.entry.js +3 -8
- package/dist/cjs/post-components.cjs.js +1 -1
- package/dist/cjs/{post-footer-15d78645.js → post-footer-92adffac.js} +12 -2
- package/dist/cjs/post-footer.cjs.entry.js +3 -2
- package/dist/cjs/{post-linkarea-095d1928.js → post-linkarea-26c457b3.js} +1 -1
- package/dist/cjs/post-linkarea.cjs.entry.js +2 -2
- package/dist/cjs/{post-menu-item-387e079b.js → post-menu-item-d0a53c84.js} +3 -3
- package/dist/cjs/{post-popover-388c8091.js → post-popover-36cead3d.js} +20 -5
- package/dist/cjs/post-popover.cjs.entry.js +4 -2
- package/dist/cjs/{post-rating-246e4d89.js → post-rating-f50a9939.js} +29 -8
- package/dist/cjs/post-rating.cjs.entry.js +4 -2
- package/dist/cjs/{post-tab-header-0e9d0e06.js → post-tab-header-f47508da.js} +3 -3
- package/dist/cjs/post-tab-header.cjs.entry.js +3 -4
- package/dist/cjs/{post-tab-panel-f952714f.js → post-tab-panel-7c51798b.js} +11 -2
- package/dist/cjs/post-tab-panel.cjs.entry.js +4 -2
- package/dist/cjs/{post-tabs-97c30d81.js → post-tabs-2debea01.js} +2 -2
- package/dist/cjs/post-tabs.cjs.entry.js +2 -2
- package/dist/cjs/{post-tag-58003cf0.js → post-tag-ac62c57f.js} +18 -5
- package/dist/cjs/post-tag.cjs.entry.js +4 -2
- package/dist/cjs/{post-togglebutton-87c984d8.js → post-togglebutton-43c46511.js} +85 -88
- package/dist/cjs/{post-tooltip-28e7711a.js → post-tooltip-b7dcfb44.js} +11 -10
- package/dist/cjs/{post-tooltip-trigger-cbc53d14.js → post-tooltip-trigger-904061b6.js} +6 -8
- package/dist/cjs/post-tooltip-trigger.cjs.entry.js +3 -3
- package/dist/cjs/post-tooltip.cjs.entry.js +4 -3
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/post-accordion/post-accordion.js +7 -7
- package/dist/collection/components/post-accordion-item/post-accordion-item.js +3 -3
- package/dist/collection/components/post-avatar/post-avatar.js +25 -2
- package/dist/collection/components/post-back-to-top/post-back-to-top.js +8 -10
- package/dist/collection/components/post-banner/post-banner.js +13 -18
- package/dist/collection/components/post-breadcrumb-item/post-breadcrumb-item.js +1 -1
- package/dist/collection/components/post-breadcrumbs/post-breadcrumbs.js +15 -7
- package/dist/collection/components/post-card-control/post-card-control.js +58 -33
- package/dist/collection/components/post-closebutton/post-closebutton.js +1 -1
- package/dist/collection/components/post-collapsible/post-collapsible.js +1 -1
- package/dist/collection/components/post-collapsible-trigger/post-collapsible-trigger.js +4 -5
- package/dist/collection/components/post-footer/post-footer.js +14 -2
- package/dist/collection/components/post-header/post-header.css +1 -1
- package/dist/collection/components/post-header/post-header.js +29 -54
- package/dist/collection/components/post-icon/post-icon.js +17 -37
- package/dist/collection/components/post-language-option/post-language-option.js +13 -13
- package/dist/collection/components/post-language-switch/post-language-switch.js +5 -5
- package/dist/collection/components/post-logo/post-logo.js +2 -2
- package/dist/collection/components/post-mainnavigation/post-mainnavigation.css +1 -1
- package/dist/collection/components/post-megadropdown/post-megadropdown.css +1 -1
- package/dist/collection/components/post-megadropdown-trigger/post-megadropdown-trigger.css +1 -1
- package/dist/collection/components/post-megadropdown-trigger/post-megadropdown-trigger.js +3 -3
- package/dist/collection/components/post-menu/post-menu.js +13 -2
- package/dist/collection/components/post-menu-trigger/post-menu-trigger.js +3 -3
- package/dist/collection/components/post-popover/post-popover.js +21 -2
- package/dist/collection/components/post-popovercontainer/post-popovercontainer.js +26 -4
- package/dist/collection/components/post-rating/post-rating.js +29 -2
- package/dist/collection/components/post-tab-header/post-tab-header.js +5 -10
- package/dist/collection/components/post-tab-panel/post-tab-panel.js +13 -2
- package/dist/collection/components/post-tabs/post-tabs.js +2 -2
- package/dist/collection/components/post-tag/post-tag.js +23 -11
- package/dist/collection/components/post-togglebutton/post-togglebutton.js +1 -12
- package/dist/collection/components/post-tooltip/post-tooltip.css +1 -1
- package/dist/collection/components/post-tooltip/post-tooltip.js +12 -12
- package/dist/collection/components/post-tooltip-trigger/post-tooltip-trigger.js +5 -7
- package/dist/collection/types/index.js +2 -0
- package/dist/collection/types/placement.js +14 -0
- package/dist/collection/types/property-types.js +1 -0
- package/dist/collection/utils/is-value-empty.js +4 -0
- package/dist/collection/utils/property-checkers/check-one-of.js +3 -4
- package/dist/collection/utils/property-checkers/check-pattern.js +3 -4
- package/dist/collection/utils/property-checkers/check-type.js +4 -6
- package/dist/collection/utils/property-checkers/check-url.js +5 -5
- package/dist/collection/utils/property-checkers/constants.js +1 -1
- package/dist/collection/utils/property-checkers/empty-or.js +4 -6
- package/dist/collection/utils/property-checkers/index.js +6 -6
- package/dist/collection/utils/property-checkers/required-and.js +14 -0
- package/dist/components/index2.js +60 -19
- package/dist/components/package.js +1 -1
- package/dist/components/post-accordion-item2.js +4 -4
- package/dist/components/post-accordion2.js +7 -7
- package/dist/components/post-avatar2.js +24 -4
- package/dist/components/post-back-to-top2.js +9 -12
- package/dist/components/post-banner2.js +12 -18
- package/dist/components/post-breadcrumb-item2.js +2 -2
- package/dist/components/post-breadcrumbs2.js +14 -7
- package/dist/components/post-card-control2.js +41 -16
- package/dist/components/post-closebutton2.js +1 -1
- package/dist/components/post-collapsible-trigger2.js +3 -5
- package/dist/components/post-collapsible2.js +2 -2
- package/dist/components/post-footer2.js +13 -1
- package/dist/components/post-header2.js +31 -33
- package/dist/components/post-icon2.js +9 -25
- package/dist/components/post-language-option2.js +9 -10
- package/dist/components/post-language-switch2.js +4 -6
- package/dist/components/post-logo2.js +2 -2
- package/dist/components/post-mainnavigation2.js +1 -1
- package/dist/components/post-megadropdown-trigger2.js +4 -4
- package/dist/components/post-megadropdown2.js +1 -1
- package/dist/components/post-menu-trigger2.js +3 -3
- package/dist/components/post-menu2.js +12 -2
- package/dist/components/post-popover2.js +20 -3
- package/dist/components/post-popovercontainer2.js +37 -3
- package/dist/components/post-rating2.js +26 -1
- package/dist/components/post-tab-header2.js +2 -2
- package/dist/components/post-tab-panel2.js +12 -1
- package/dist/components/post-tabs2.js +1 -1
- package/dist/components/post-tag2.js +19 -5
- package/dist/components/post-togglebutton2.js +1 -12
- package/dist/components/post-tooltip-trigger2.js +5 -7
- package/dist/components/post-tooltip2.js +11 -11
- package/dist/components/switch-variants.js +3 -0
- package/dist/docs.json +39 -87
- package/dist/esm/index-ffccd040.js +88 -0
- package/dist/esm/index.js +23 -27
- package/dist/esm/loader.js +1 -1
- package/dist/esm/package-8503eaa8.js +3 -0
- package/dist/esm/placement-8d56605d.js +16 -0
- package/dist/esm/{post-accordion-03796d13.js → post-accordion-9365faca.js} +8 -8
- package/dist/esm/{post-accordion-item-d29c49e5.js → post-accordion-item-2dc8e3b7.js} +5 -5
- package/dist/esm/post-accordion-item.entry.js +3 -7
- package/dist/esm/post-accordion.entry.js +3 -3
- package/dist/esm/{post-avatar-639dc17a.js → post-avatar-4f73dc4d.js} +21 -4
- package/dist/esm/post-avatar.entry.js +3 -4
- package/dist/esm/{post-back-to-top-8099279e.js → post-back-to-top-8f759d32.js} +8 -11
- package/dist/esm/post-back-to-top.entry.js +3 -5
- package/dist/esm/{post-banner-54834fbf.js → post-banner-ad979275.js} +12 -17
- package/dist/esm/post-banner.entry.js +3 -8
- package/dist/esm/post-breadcrumb-item_2.entry.js +3 -7
- package/dist/esm/{post-breadcrumbs-caf56014.js → post-breadcrumbs-a20336c7.js} +13 -7
- package/dist/esm/post-breadcrumbs.entry.js +3 -3
- package/dist/esm/{post-card-control-b063586b.js → post-card-control-3c77e778.js} +37 -16
- package/dist/esm/post-card-control.entry.js +3 -5
- package/dist/esm/post-closebutton_15.entry.js +5 -9
- package/dist/esm/{post-collapsible-trigger-727bcde1.js → post-collapsible-trigger-5fd0e193.js} +5 -8
- package/dist/esm/post-collapsible_2.entry.js +3 -8
- package/dist/esm/post-components.js +1 -1
- package/dist/esm/{post-footer-16f1a8de.js → post-footer-3e117b5a.js} +12 -2
- package/dist/esm/post-footer.entry.js +3 -2
- package/dist/esm/{post-linkarea-4e4228fb.js → post-linkarea-16a14609.js} +1 -1
- package/dist/esm/post-linkarea.entry.js +2 -2
- package/dist/esm/{post-menu-item-e9dd8173.js → post-menu-item-b1604fe4.js} +3 -3
- package/dist/esm/{post-popover-46ede6b5.js → post-popover-49096648.js} +17 -2
- package/dist/esm/post-popover.entry.js +4 -2
- package/dist/esm/{post-rating-8d0d970b.js → post-rating-405bee8f.js} +23 -2
- package/dist/esm/post-rating.entry.js +4 -2
- package/dist/esm/{post-tab-header-8224c7c2.js → post-tab-header-b228c217.js} +3 -3
- package/dist/esm/post-tab-header.entry.js +3 -4
- package/dist/esm/{post-tab-panel-dfdeccd3.js → post-tab-panel-98110b64.js} +11 -2
- package/dist/esm/post-tab-panel.entry.js +4 -2
- package/dist/esm/{post-tabs-fabd0569.js → post-tabs-44d9313c.js} +2 -2
- package/dist/esm/post-tabs.entry.js +2 -2
- package/dist/esm/{post-tag-13994238.js → post-tag-99cc9616.js} +18 -5
- package/dist/esm/post-tag.entry.js +4 -2
- package/dist/esm/{post-togglebutton-87967c5b.js → post-togglebutton-ea73e63f.js} +85 -88
- package/dist/esm/{post-tooltip-eecaa4c7.js → post-tooltip-78cd2988.js} +11 -10
- package/dist/esm/{post-tooltip-trigger-642cbb22.js → post-tooltip-trigger-bdb21c45.js} +6 -8
- package/dist/esm/post-tooltip-trigger.entry.js +3 -3
- package/dist/esm/post-tooltip.entry.js +4 -3
- package/dist/post-components/index.esm.js +1 -1
- package/dist/post-components/p-09dd5aa4.js +1 -0
- package/dist/post-components/{p-19317b15.js → p-0f9322e5.js} +2 -2
- package/dist/post-components/{p-0dcd25ab.js → p-11572299.js} +1 -1
- package/dist/post-components/p-19a83519.entry.js +1 -0
- package/dist/post-components/p-1afb3c43.entry.js +1 -0
- package/dist/post-components/p-214cd032.js +1 -0
- package/dist/post-components/p-21e5b028.js +1 -0
- package/dist/post-components/p-2320305b.js +1 -0
- package/dist/post-components/p-2523f97b.entry.js +1 -0
- package/dist/post-components/p-2bd3a436.js +1 -0
- package/dist/post-components/p-2ce8fbf5.js +1 -0
- package/dist/post-components/p-2f879f4e.entry.js +1 -0
- package/dist/post-components/p-33e26845.entry.js +1 -0
- package/dist/post-components/p-38b1c71e.entry.js +1 -0
- package/dist/post-components/p-38d59732.js +1 -0
- package/dist/post-components/p-3a67f1ff.js +1 -0
- package/dist/post-components/p-41450b6c.entry.js +1 -0
- package/dist/post-components/p-4c23ed05.entry.js +1 -0
- package/dist/post-components/p-57746c40.js +1 -0
- package/dist/post-components/p-59a38c23.js +1 -0
- package/dist/post-components/p-6313d72e.entry.js +1 -0
- package/dist/post-components/p-64e0b0fc.js +1 -0
- package/dist/post-components/p-658a2e34.entry.js +1 -0
- package/dist/post-components/p-746d3cd3.entry.js +1 -0
- package/dist/post-components/p-79a2dad0.entry.js +1 -0
- package/dist/post-components/p-7dd1807c.js +1 -0
- package/dist/post-components/p-817fbeaf.js +1 -0
- package/dist/post-components/p-85950200.js +1 -0
- package/dist/post-components/p-8ebecf22.entry.js +1 -0
- package/dist/post-components/p-8ed1cb53.entry.js +1 -0
- package/dist/post-components/p-91244b25.js +1 -0
- package/dist/post-components/{p-a07f85ee.js → p-91675004.js} +1 -1
- package/dist/post-components/p-94ebc430.js +1 -0
- package/dist/post-components/p-95727a4f.entry.js +1 -0
- package/dist/post-components/p-a844da3a.entry.js +1 -0
- package/dist/post-components/{p-692ba59d.js → p-af900651.js} +1 -1
- package/dist/post-components/p-b176309b.js +1 -0
- package/dist/post-components/p-b373659e.entry.js +1 -0
- package/dist/post-components/p-b500b245.js +1 -0
- package/dist/post-components/p-bf182745.entry.js +1 -0
- package/dist/post-components/p-c9b6f9e7.entry.js +1 -0
- package/dist/post-components/p-cb7d8f67.entry.js +1 -0
- package/dist/post-components/p-e28eb73a.js +1 -0
- package/dist/post-components/post-components.css +1 -0
- package/dist/post-components/post-components.esm.js +1 -1
- package/dist/prebuild.js +26 -0
- package/dist/types/components/post-accordion/post-accordion.d.ts +2 -1
- package/dist/types/components/post-avatar/post-avatar.d.ts +3 -0
- package/dist/types/components/post-back-to-top/post-back-to-top.d.ts +1 -1
- package/dist/types/components/post-banner/post-banner.d.ts +3 -4
- package/dist/types/components/post-breadcrumbs/post-breadcrumbs.d.ts +2 -1
- package/dist/types/components/post-card-control/post-card-control.d.ts +10 -6
- package/dist/types/components/post-footer/post-footer.d.ts +2 -0
- package/dist/types/components/post-header/post-header.d.ts +5 -9
- package/dist/types/components/post-icon/post-icon.d.ts +5 -7
- package/dist/types/components/post-language-option/post-language-option.d.ts +5 -5
- package/dist/types/components/post-logo/post-logo.d.ts +1 -1
- package/dist/types/components/post-menu/post-menu.d.ts +1 -0
- package/dist/types/components/post-popover/post-popover.d.ts +2 -0
- package/dist/types/components/post-popovercontainer/post-popovercontainer.d.ts +3 -0
- package/dist/types/components/post-rating/post-rating.d.ts +4 -0
- package/dist/types/components/post-tab-header/post-tab-header.d.ts +1 -1
- package/dist/types/components/post-tab-panel/post-tab-panel.d.ts +1 -0
- package/dist/types/components/post-tabs/post-tabs.d.ts +1 -1
- package/dist/types/components/post-tag/post-tag.d.ts +5 -3
- package/dist/types/components/post-togglebutton/post-togglebutton.d.ts +0 -1
- package/dist/types/components/post-tooltip/post-tooltip.d.ts +3 -3
- package/dist/types/components.d.ts +38 -59
- package/dist/types/home/runner/work/design-system/design-system/packages/components/.stencil/prebuild.d.ts +1 -0
- package/dist/types/index.d.ts +2 -2
- package/dist/types/types/index.d.ts +2 -0
- package/dist/types/types/placement.d.ts +1 -0
- package/dist/types/types/property-types.d.ts +1 -0
- package/dist/types/utils/is-value-empty.d.ts +1 -0
- package/dist/types/utils/property-checkers/check-one-of.d.ts +1 -1
- package/dist/types/utils/property-checkers/check-pattern.d.ts +1 -1
- package/dist/types/utils/property-checkers/check-type.d.ts +2 -2
- package/dist/types/utils/property-checkers/check-url.d.ts +1 -1
- package/dist/types/utils/property-checkers/constants.d.ts +1 -1
- package/dist/types/utils/property-checkers/empty-or.d.ts +3 -1
- package/dist/types/utils/property-checkers/index.d.ts +16 -9
- package/dist/types/utils/property-checkers/required-and.d.ts +3 -0
- package/loaders/index2.js +60 -19
- package/loaders/package.js +1 -1
- package/loaders/post-accordion-item2.js +4 -4
- package/loaders/post-accordion.js +7 -7
- package/loaders/post-avatar.js +24 -4
- package/loaders/post-back-to-top.js +9 -12
- package/loaders/post-banner.js +12 -18
- package/loaders/post-breadcrumb-item2.js +2 -2
- package/loaders/post-breadcrumbs.js +14 -7
- package/loaders/post-card-control.js +41 -16
- package/loaders/post-closebutton.js +1 -1
- package/loaders/post-collapsible-trigger2.js +3 -5
- package/loaders/post-collapsible2.js +2 -2
- package/loaders/post-footer.js +13 -1
- package/loaders/post-header.js +31 -33
- package/loaders/post-icon2.js +9 -25
- package/loaders/post-language-option.js +9 -10
- package/loaders/post-language-switch.js +4 -6
- package/loaders/post-logo.js +2 -2
- package/loaders/post-mainnavigation.js +1 -1
- package/loaders/post-megadropdown-trigger.js +4 -4
- package/loaders/post-megadropdown.js +1 -1
- package/loaders/post-menu-trigger2.js +3 -3
- package/loaders/post-menu2.js +12 -2
- package/loaders/post-popover.js +20 -3
- package/loaders/post-popovercontainer.js +1 -1
- package/loaders/post-popovercontainer2.js +37 -3
- package/loaders/post-rating.js +26 -1
- package/loaders/post-tab-header.js +2 -2
- package/loaders/post-tab-panel.js +12 -1
- package/loaders/post-tabs.js +1 -1
- package/loaders/post-tag.js +19 -5
- package/loaders/post-togglebutton.js +1 -12
- package/loaders/post-tooltip-trigger.js +5 -7
- package/loaders/post-tooltip.js +11 -11
- package/loaders/switch-variants.js +3 -0
- package/package.json +19 -9
- package/dist/cjs/check-non-empty-bd99d236.js +0 -15
- package/dist/cjs/check-one-of-75d270b5.js +0 -13
- package/dist/cjs/check-type-cdbf6d29.js +0 -21
- package/dist/cjs/check-url-220a286c.js +0 -19
- package/dist/cjs/constants-238701d3.js +0 -5
- package/dist/cjs/index-23e36ff7.js +0 -37
- package/dist/collection/utils/property-checkers/check-non-empty.js +0 -10
- package/dist/components/check-non-empty.js +0 -13
- package/dist/components/check-one-of.js +0 -11
- package/dist/components/check-type.js +0 -19
- package/dist/components/constants.js +0 -3
- package/dist/esm/check-non-empty-258a56b3.js +0 -13
- package/dist/esm/check-one-of-0bee20f5.js +0 -11
- package/dist/esm/check-type-37d5d307.js +0 -19
- package/dist/esm/check-url-17962bc8.js +0 -17
- package/dist/esm/constants-8d548297.js +0 -3
- package/dist/esm/index-8f8fe5b0.js +0 -32
- package/dist/esm/package-33ac2576.js +0 -3
- package/dist/post-components/p-0539071d.js +0 -1
- package/dist/post-components/p-181c73d5.js +0 -1
- package/dist/post-components/p-1ef9415b.js +0 -1
- package/dist/post-components/p-24d0695f.entry.js +0 -1
- package/dist/post-components/p-2e50a07d.entry.js +0 -1
- package/dist/post-components/p-30eb4d87.js +0 -1
- package/dist/post-components/p-440193f4.js +0 -1
- package/dist/post-components/p-46008c18.entry.js +0 -1
- package/dist/post-components/p-47ab2c2b.entry.js +0 -1
- package/dist/post-components/p-4c049de0.entry.js +0 -1
- package/dist/post-components/p-4c4acc32.entry.js +0 -1
- package/dist/post-components/p-5d473fcd.js +0 -1
- package/dist/post-components/p-5d539b30.js +0 -1
- package/dist/post-components/p-6783e509.entry.js +0 -1
- package/dist/post-components/p-6933fb57.entry.js +0 -1
- package/dist/post-components/p-72197a6b.js +0 -1
- package/dist/post-components/p-7709c14a.js +0 -1
- package/dist/post-components/p-77910344.entry.js +0 -1
- package/dist/post-components/p-80e5100e.entry.js +0 -1
- package/dist/post-components/p-84fbf49c.js +0 -1
- package/dist/post-components/p-85fdc2d3.js +0 -1
- package/dist/post-components/p-8c09291c.js +0 -1
- package/dist/post-components/p-93da1a5f.js +0 -1
- package/dist/post-components/p-9b8ee310.entry.js +0 -1
- package/dist/post-components/p-9efb84d3.entry.js +0 -1
- package/dist/post-components/p-9fbf2f82.entry.js +0 -1
- package/dist/post-components/p-a25019de.js +0 -1
- package/dist/post-components/p-a710ee00.js +0 -1
- package/dist/post-components/p-b94e5b4d.entry.js +0 -1
- package/dist/post-components/p-c2348d3d.js +0 -1
- package/dist/post-components/p-c6b03446.entry.js +0 -1
- package/dist/post-components/p-d0dfd5f9.js +0 -1
- package/dist/post-components/p-d45df336.js +0 -1
- package/dist/post-components/p-d4890d50.entry.js +0 -1
- package/dist/post-components/p-d5210531.entry.js +0 -1
- package/dist/post-components/p-dd39c542.entry.js +0 -1
- package/dist/post-components/p-df6c8a4c.js +0 -1
- package/dist/post-components/p-e068a41e.js +0 -1
- package/dist/post-components/p-e585c6fe.js +0 -1
- package/dist/post-components/p-f2c4a48d.js +0 -1
- package/dist/post-components/p-f31b9b5d.entry.js +0 -1
- package/dist/post-components/p-f58252d5.entry.js +0 -1
- package/dist/post-components/p-fda767f0.js +0 -1
- package/dist/types/utils/property-checkers/check-non-empty.d.ts +0 -3
- package/loaders/check-non-empty.js +0 -13
- package/loaders/check-one-of.js +0 -11
- package/loaders/check-type.js +0 -19
- package/loaders/constants.js +0 -3
package/loaders/post-popover.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { P as PLACEMENT_TYPES, d as defineCustomElement$2 } from './post-popovercontainer2.js';
|
|
3
3
|
import { v as version } from './package.js';
|
|
4
|
-
import {
|
|
4
|
+
import { I as IS_BROWSER } from './breakpoints.js';
|
|
5
|
+
import { d as checkEmptyOrOneOf, c as checkRequiredAndType } from './index2.js';
|
|
5
6
|
|
|
6
7
|
function getAttributeObserver(attribute, handler) {
|
|
7
8
|
/**
|
|
@@ -50,6 +51,12 @@ const globalToggleHandler = (e) => {
|
|
|
50
51
|
popover?.toggle(currentElement);
|
|
51
52
|
};
|
|
52
53
|
const PostPopover$1 = /*@__PURE__*/ proxyCustomElement(class PostPopover extends HTMLElement {
|
|
54
|
+
validatePlacement() {
|
|
55
|
+
checkEmptyOrOneOf(this, 'placement', PLACEMENT_TYPES);
|
|
56
|
+
}
|
|
57
|
+
validateCloseButtonCaption() {
|
|
58
|
+
checkRequiredAndType(this, 'closeButtonCaption', 'string');
|
|
59
|
+
}
|
|
53
60
|
constructor() {
|
|
54
61
|
super();
|
|
55
62
|
this.__registerHost();
|
|
@@ -78,6 +85,8 @@ const PostPopover$1 = /*@__PURE__*/ proxyCustomElement(class PostPopover extends
|
|
|
78
85
|
this.triggers.forEach(trigger => trigger.setAttribute('aria-expanded', 'false'));
|
|
79
86
|
}
|
|
80
87
|
componentDidLoad() {
|
|
88
|
+
this.validatePlacement();
|
|
89
|
+
this.validateCloseButtonCaption();
|
|
81
90
|
this.popoverRef.addEventListener('beforetoggle', this.localBeforeToggleHandler);
|
|
82
91
|
}
|
|
83
92
|
disconnectedCallback() {
|
|
@@ -97,6 +106,7 @@ const PostPopover$1 = /*@__PURE__*/ proxyCustomElement(class PostPopover extends
|
|
|
97
106
|
*/
|
|
98
107
|
async show(target) {
|
|
99
108
|
this.popoverRef.show(target);
|
|
109
|
+
console.log(this.popoverRef);
|
|
100
110
|
target.setAttribute('aria-expanded', 'true');
|
|
101
111
|
}
|
|
102
112
|
/**
|
|
@@ -127,9 +137,13 @@ const PostPopover$1 = /*@__PURE__*/ proxyCustomElement(class PostPopover extends
|
|
|
127
137
|
trigger.setAttribute('aria-expanded', force ? 'false' : null);
|
|
128
138
|
}
|
|
129
139
|
render() {
|
|
130
|
-
return (h(Host, { key: '
|
|
140
|
+
return (h(Host, { key: '3dc7041d2208523956f62fedcf1dfbdee5302006', "data-version": version }, h("post-popovercontainer", { key: 'c4a93a401ab5f6605dec49e509c5188bf05004be', arrow: this.arrow, placement: this.placement, ref: e => (this.popoverRef = e) }, h("div", { key: '9c4d4c36c811ac443e98716c3b013de97eaa624d', class: "popover-container" }, h("div", { key: 'e256d82cb50ddfd7af6368c707afd0b1e5c8e7aa', class: "popover-content" }, h("slot", { key: '7da07c358162b0e5bfd13561d5ac1e94d028a917' })), h("button", { key: 'c1fef4bf8383e92d34367966ae980983c77e15e4', class: "btn-close", onClick: () => this.hide() }, h("span", { key: '066b77e1883d64b937319a20e0e6e35fa0168d48', class: "visually-hidden" }, this.closeButtonCaption))))));
|
|
131
141
|
}
|
|
132
142
|
get host() { return this; }
|
|
143
|
+
static get watchers() { return {
|
|
144
|
+
"placement": ["validatePlacement"],
|
|
145
|
+
"closeButtonCaption": ["validateCloseButtonCaption"]
|
|
146
|
+
}; }
|
|
133
147
|
static get style() { return PostPopoverStyle0; }
|
|
134
148
|
}, [1, "post-popover", {
|
|
135
149
|
"placement": [1],
|
|
@@ -138,6 +152,9 @@ const PostPopover$1 = /*@__PURE__*/ proxyCustomElement(class PostPopover extends
|
|
|
138
152
|
"show": [64],
|
|
139
153
|
"hide": [64],
|
|
140
154
|
"toggle": [64]
|
|
155
|
+
}, undefined, {
|
|
156
|
+
"placement": ["validatePlacement"],
|
|
157
|
+
"closeButtonCaption": ["validateCloseButtonCaption"]
|
|
141
158
|
}]);
|
|
142
159
|
function defineCustomElement$1() {
|
|
143
160
|
if (typeof customElements === "undefined") {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { a as PostPopovercontainer$1, d as defineCustomElement$1 } from './post-popovercontainer2.js';
|
|
2
2
|
|
|
3
3
|
const PostPopovercontainer = PostPopovercontainer$1;
|
|
4
4
|
const defineCustomElement = defineCustomElement$1;
|
|
@@ -1,7 +1,23 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement as HTMLElement$1, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { I as IS_BROWSER } from './breakpoints.js';
|
|
3
|
+
import { d as checkEmptyOrOneOf, a as checkEmptyOrType } from './index2.js';
|
|
3
4
|
import { v as version } from './package.js';
|
|
4
5
|
|
|
6
|
+
const PLACEMENT_TYPES = [
|
|
7
|
+
'top',
|
|
8
|
+
'right',
|
|
9
|
+
'bottom',
|
|
10
|
+
'left',
|
|
11
|
+
'top-start',
|
|
12
|
+
'top-end',
|
|
13
|
+
'right-start',
|
|
14
|
+
'right-end',
|
|
15
|
+
'bottom-start',
|
|
16
|
+
'bottom-end',
|
|
17
|
+
'left-start',
|
|
18
|
+
'left-end',
|
|
19
|
+
];
|
|
20
|
+
|
|
5
21
|
/**
|
|
6
22
|
* Custom positioning reference element.
|
|
7
23
|
* @see https://floating-ui.com/docs/virtual-elements
|
|
@@ -2754,6 +2770,15 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
|
|
|
2754
2770
|
this.manualClose = false;
|
|
2755
2771
|
this.safeSpace = undefined;
|
|
2756
2772
|
}
|
|
2773
|
+
validatePlacement() {
|
|
2774
|
+
checkEmptyOrOneOf(this, 'placement', PLACEMENT_TYPES);
|
|
2775
|
+
}
|
|
2776
|
+
validateEdgeGap() {
|
|
2777
|
+
checkEmptyOrType(this, 'edgeGap', 'number');
|
|
2778
|
+
}
|
|
2779
|
+
validateSafeSpace() {
|
|
2780
|
+
checkEmptyOrOneOf(this, 'safeSpace', ['triangle', 'trapezoid']);
|
|
2781
|
+
}
|
|
2757
2782
|
/**
|
|
2758
2783
|
* Updates cursor position for safe space feature when popover is open.
|
|
2759
2784
|
* Sets CSS custom properties for dynamic styling of safe area.
|
|
@@ -2963,11 +2988,16 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
|
|
|
2963
2988
|
}
|
|
2964
2989
|
render() {
|
|
2965
2990
|
const animationClass = this.animation ? `animate-${this.animation}` : '';
|
|
2966
|
-
return (h(Host, { key: '
|
|
2991
|
+
return (h(Host, { key: '7b5c3ad89739db0387473db9228014ca9596b8a3', "data-version": version, popover: this.manualClose ? 'manual' : 'auto' }, h("div", { key: '0db14a34b3bb8e248bb0adead08afc9b7007edf6', class: animationClass }, this.arrow && (h("span", { key: 'e7061112aebb882194b79e82535074f34ddbbfd1', class: "arrow", ref: el => {
|
|
2967
2992
|
this.arrowRef = el;
|
|
2968
|
-
} })), h("slot", { key: '
|
|
2993
|
+
} })), h("slot", { key: 'efc25097a97f87a9eb742379d8a70b0fc2c78682' }))));
|
|
2969
2994
|
}
|
|
2970
2995
|
get host() { return this; }
|
|
2996
|
+
static get watchers() { return {
|
|
2997
|
+
"placement": ["validatePlacement"],
|
|
2998
|
+
"edgeGap": ["validateEdgeGap"],
|
|
2999
|
+
"safeSpace": ["validateSafeSpace"]
|
|
3000
|
+
}; }
|
|
2971
3001
|
static get style() { return PostPopovercontainerStyle0; }
|
|
2972
3002
|
}, [4, "post-popovercontainer", {
|
|
2973
3003
|
"placement": [1],
|
|
@@ -2979,6 +3009,10 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
|
|
|
2979
3009
|
"show": [64],
|
|
2980
3010
|
"hide": [64],
|
|
2981
3011
|
"toggle": [64]
|
|
3012
|
+
}, undefined, {
|
|
3013
|
+
"placement": ["validatePlacement"],
|
|
3014
|
+
"edgeGap": ["validateEdgeGap"],
|
|
3015
|
+
"safeSpace": ["validateSafeSpace"]
|
|
2982
3016
|
}]);
|
|
2983
3017
|
PostPopovercontainer.STATIC_SIDES = {
|
|
2984
3018
|
top: 'bottom',
|
|
@@ -3014,4 +3048,4 @@ function defineCustomElement() {
|
|
|
3014
3048
|
} });
|
|
3015
3049
|
}
|
|
3016
3050
|
|
|
3017
|
-
export {
|
|
3051
|
+
export { PLACEMENT_TYPES as P, PostPopovercontainer as a, defineCustomElement as d };
|
package/loaders/post-rating.js
CHANGED
|
@@ -1,11 +1,27 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { v as version } from './package.js';
|
|
3
|
+
import { c as checkRequiredAndType } from './index2.js';
|
|
4
|
+
import './breakpoints.js';
|
|
3
5
|
import { d as defineCustomElement$2 } from './post-icon2.js';
|
|
4
6
|
|
|
5
7
|
const postRatingCss = "@keyframes popIn{from{transform:scale(0.9);opacity:0;transition-property:transform,opacity,overlay,display;transition-behavior:allow-discrete;transition-duration:var(--post-transition-duration, 0.35s);transition-timing-function:linear(0, 0.007, 0.029 2.2%, 0.118 4.7%, 0.625 14.4%, 0.826 19%, 0.902, 0.962, 1.008 26.1%, 1.041 28.7%, 1.064 32.1%, 1.07 36%, 1.061 40.5%, 1.015 53.4%, 0.999 61.6%, 0.995 71.2%, 1)}to{opacity:1;transform:scale(1)}}:host{display:inline-block}.rating{display:flex;flex-wrap:wrap;overflow:hidden;margin:0 calc(var(--post-core-dimension-4)*-1);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:var(--post-core-dimension-2);outline:var(--post-core-dimension-2) 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%)}";
|
|
6
8
|
const PostRatingStyle0 = postRatingCss;
|
|
7
9
|
|
|
8
10
|
const PostRating$1 = /*@__PURE__*/ proxyCustomElement(class PostRating extends HTMLElement {
|
|
11
|
+
validateLabel() {
|
|
12
|
+
checkRequiredAndType(this, 'label', 'string');
|
|
13
|
+
}
|
|
14
|
+
validateStars() {
|
|
15
|
+
checkRequiredAndType(this, 'stars', 'number');
|
|
16
|
+
}
|
|
17
|
+
validateCurrentRating() {
|
|
18
|
+
checkRequiredAndType(this, 'currentRating', 'number');
|
|
19
|
+
}
|
|
20
|
+
componentWillLoad() {
|
|
21
|
+
this.validateLabel();
|
|
22
|
+
this.validateStars();
|
|
23
|
+
this.validateCurrentRating();
|
|
24
|
+
}
|
|
9
25
|
constructor() {
|
|
10
26
|
super();
|
|
11
27
|
this.__registerHost();
|
|
@@ -74,7 +90,7 @@ const PostRating$1 = /*@__PURE__*/ proxyCustomElement(class PostRating extends H
|
|
|
74
90
|
}
|
|
75
91
|
}
|
|
76
92
|
render() {
|
|
77
|
-
return (h(Host, { key: '
|
|
93
|
+
return (h(Host, { key: '91f3a00b43c003fdeae8c56df2aff30218d44974', "data-version": version }, h("div", { key: '02b0c4a6cce70faf47f0cbed806c0cec02eae56b', role: "slider", class: "rating", tabindex: "0", "aria-label": this.label, "aria-valuemin": "0", "aria-valuemax": this.stars, "aria-valuenow": this.currentRating, "aria-valuetext": `${this.currentRating} out of ${this.stars}`, "aria-readonly": this.readonly ? 'true' : 'false', onKeyDown: this.keydownHandler, onBlur: this.blurHandler }, Array.from({ length: this.stars }).map((v, i) => (h("div", { key: `star-${v}`, "aria-hidden": "true", class: {
|
|
78
94
|
'star': true,
|
|
79
95
|
'before-hover': i < this.hoveredIndex,
|
|
80
96
|
'active': i < Math.round(this.currentRating),
|
|
@@ -83,6 +99,11 @@ const PostRating$1 = /*@__PURE__*/ proxyCustomElement(class PostRating extends H
|
|
|
83
99
|
}, onClick: () => this.update(i + 1), onMouseEnter: e => this.hoverHandler(i, e), onMouseLeave: e => this.hoverHandler(i, e) }, h("post-icon", { name: "2062", class: "stroke" }), h("post-icon", { name: "2574", class: "fill" })))))));
|
|
84
100
|
}
|
|
85
101
|
get host() { return this; }
|
|
102
|
+
static get watchers() { return {
|
|
103
|
+
"label": ["validateLabel"],
|
|
104
|
+
"stars": ["validateStars"],
|
|
105
|
+
"currentRating": ["validateCurrentRating"]
|
|
106
|
+
}; }
|
|
86
107
|
static get style() { return PostRatingStyle0; }
|
|
87
108
|
}, [1, "post-rating", {
|
|
88
109
|
"label": [1],
|
|
@@ -90,6 +111,10 @@ const PostRating$1 = /*@__PURE__*/ proxyCustomElement(class PostRating extends H
|
|
|
90
111
|
"currentRating": [1026, "current-rating"],
|
|
91
112
|
"readonly": [4],
|
|
92
113
|
"hoveredIndex": [32]
|
|
114
|
+
}, undefined, {
|
|
115
|
+
"label": ["validateLabel"],
|
|
116
|
+
"stars": ["validateStars"],
|
|
117
|
+
"currentRating": ["validateCurrentRating"]
|
|
93
118
|
}]);
|
|
94
119
|
function defineCustomElement$1() {
|
|
95
120
|
if (typeof customElements === "undefined") {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { v as version } from './package.js';
|
|
3
|
-
import { c as
|
|
3
|
+
import { c as checkRequiredAndType } from './index2.js';
|
|
4
4
|
import './breakpoints.js';
|
|
5
5
|
import { n as nanoid } from './index.browser.js';
|
|
6
6
|
|
|
@@ -16,7 +16,7 @@ const PostTabHeader$1 = /*@__PURE__*/ proxyCustomElement(class PostTabHeader ext
|
|
|
16
16
|
this.panel = undefined;
|
|
17
17
|
}
|
|
18
18
|
validateFor() {
|
|
19
|
-
|
|
19
|
+
checkRequiredAndType(this, 'panel', 'string');
|
|
20
20
|
}
|
|
21
21
|
componentWillLoad() {
|
|
22
22
|
this.tabId = `tab-${this.host.id || nanoid(6)}`;
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { v as version } from './package.js';
|
|
3
3
|
import { n as nanoid } from './index.browser.js';
|
|
4
|
+
import { c as checkRequiredAndType } from './index2.js';
|
|
5
|
+
import './breakpoints.js';
|
|
4
6
|
|
|
5
7
|
const postTabPanelCss = ":host{display:none}";
|
|
6
8
|
const PostTabPanelStyle0 = postTabPanelCss;
|
|
@@ -13,18 +15,27 @@ const PostTabPanel$1 = /*@__PURE__*/ proxyCustomElement(class PostTabPanel exten
|
|
|
13
15
|
this.panelId = undefined;
|
|
14
16
|
this.name = undefined;
|
|
15
17
|
}
|
|
18
|
+
validateName() {
|
|
19
|
+
checkRequiredAndType(this, 'name', 'string');
|
|
20
|
+
}
|
|
16
21
|
componentWillLoad() {
|
|
22
|
+
this.validateName();
|
|
17
23
|
// get the id set on the host element or use a random id by default
|
|
18
24
|
this.panelId = `panel-${this.host.id || nanoid(6)}`;
|
|
19
25
|
}
|
|
20
26
|
render() {
|
|
21
|
-
return (h(Host, { key: '
|
|
27
|
+
return (h(Host, { key: 'aef9d8692392f57745c0d0a0af13fedb6f67f231', "data-version": version, id: this.panelId, role: "tabpanel" }, h("slot", { key: '1e51f8680f4e7bdcb37994db3e70e828dde61dc0' })));
|
|
22
28
|
}
|
|
23
29
|
get host() { return this; }
|
|
30
|
+
static get watchers() { return {
|
|
31
|
+
"name": ["validateName"]
|
|
32
|
+
}; }
|
|
24
33
|
static get style() { return PostTabPanelStyle0; }
|
|
25
34
|
}, [1, "post-tab-panel", {
|
|
26
35
|
"name": [513],
|
|
27
36
|
"panelId": [32]
|
|
37
|
+
}, undefined, {
|
|
38
|
+
"name": ["validateName"]
|
|
28
39
|
}]);
|
|
29
40
|
function defineCustomElement$1() {
|
|
30
41
|
if (typeof customElements === "undefined") {
|
package/loaders/post-tabs.js
CHANGED
|
@@ -164,7 +164,7 @@ const PostTabs$1 = /*@__PURE__*/ proxyCustomElement(class PostTabs extends HTMLE
|
|
|
164
164
|
nextTab.focus();
|
|
165
165
|
}
|
|
166
166
|
render() {
|
|
167
|
-
return (h(Host, { key: '
|
|
167
|
+
return (h(Host, { key: 'b38b216caa48cb36b73f36669a650bc88b56c860', "data-version": version }, h("div", { key: '751f88c9f0241e42b6c8d996b3645c26113f0ce2', class: "tabs-wrapper", part: "tabs" }, h("div", { key: 'd194ce33913a2ed6abbdd939ad5dcdc74e6f6798', class: "tabs", role: "tablist" }, h("slot", { key: '46fb9cf2d52fadf9418dff7050b78274457c3b0a', name: "tabs", onSlotchange: () => this.enableTabs() }))), h("div", { key: 'db2bfba595dab2730b9189a935dcd99504d7bad6', class: "tab-content", part: "content" }, h("slot", { key: '35795441e71901727fad9d759da483f55a865e97', onSlotchange: () => this.moveMisplacedTabs() }))));
|
|
168
168
|
}
|
|
169
169
|
get host() { return this; }
|
|
170
170
|
static get style() { return PostTabsStyle0; }
|
package/loaders/post-tag.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { v as version } from './package.js';
|
|
3
|
+
import { d as checkEmptyOrOneOf, a as checkEmptyOrType } from './index2.js';
|
|
4
|
+
import './breakpoints.js';
|
|
3
5
|
import { d as defineCustomElement$2 } from './post-icon2.js';
|
|
4
6
|
|
|
5
7
|
const postTagCss = "@keyframes popIn{from{transform:scale(0.9);opacity:0;transition-property:transform,opacity,overlay,display;transition-behavior:allow-discrete;transition-duration:var(--post-transition-duration, 0.35s);transition-timing-function:linear(0, 0.007, 0.029 2.2%, 0.118 4.7%, 0.625 14.4%, 0.826 19%, 0.902, 0.962, 1.008 26.1%, 1.041 28.7%, 1.064 32.1%, 1.07 36%, 1.061 40.5%, 1.015 53.4%, 0.999 61.6%, 0.995 71.2%, 1)}to{opacity:1;transform:scale(1)}}.tag,.tag:where(:has(:not(pre))){--post-tag-bg:hsl(0, 0%, 90%);--post-tag-fg:#000;display:inline-flex;align-items:center;gap:var(--post-core-dimension-4);padding:0 var(--post-core-dimension-8);max-width:100%;background-color:var(--post-tag-bg);border:var(--post-core-dimension-1) solid rgba(0,0,0,0);border-radius:var(--post-core-dimension-4);font-size:1rem;line-height:calc(var(--post-core-dimension-32) - var(--post-core-dimension-1)*2);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:var(--post-core-dimension-24)}.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:#000}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}";
|
|
@@ -12,16 +14,21 @@ const PostTag$1 = /*@__PURE__*/ proxyCustomElement(class PostTag extends HTMLEle
|
|
|
12
14
|
this.__attachShadow();
|
|
13
15
|
this.classes = undefined;
|
|
14
16
|
this.variant = undefined;
|
|
15
|
-
this.size =
|
|
16
|
-
this.icon =
|
|
17
|
+
this.size = undefined;
|
|
18
|
+
this.icon = undefined;
|
|
17
19
|
this.setClasses = this.setClasses.bind(this);
|
|
18
20
|
}
|
|
19
21
|
variantChanged() {
|
|
22
|
+
checkEmptyOrOneOf(this, 'variant', ['white', 'info', 'success', 'error', 'warning', 'yellow']);
|
|
20
23
|
this.setClasses();
|
|
21
24
|
}
|
|
22
25
|
sizeChanged() {
|
|
26
|
+
checkEmptyOrOneOf(this, 'size', ['sm']);
|
|
23
27
|
this.setClasses();
|
|
24
28
|
}
|
|
29
|
+
validateName() {
|
|
30
|
+
checkEmptyOrType(this, 'icon', 'string');
|
|
31
|
+
}
|
|
25
32
|
setClasses() {
|
|
26
33
|
this.classes = [
|
|
27
34
|
'tag',
|
|
@@ -31,16 +38,22 @@ const PostTag$1 = /*@__PURE__*/ proxyCustomElement(class PostTag extends HTMLEle
|
|
|
31
38
|
.filter(c => c !== null)
|
|
32
39
|
.join(' ');
|
|
33
40
|
}
|
|
41
|
+
componentWillLoad() {
|
|
42
|
+
this.validateName();
|
|
43
|
+
this.variantChanged();
|
|
44
|
+
this.sizeChanged();
|
|
45
|
+
}
|
|
34
46
|
connectedCallback() {
|
|
35
47
|
this.setClasses();
|
|
36
48
|
}
|
|
37
49
|
render() {
|
|
38
|
-
return (h(Host, { key: '
|
|
50
|
+
return (h(Host, { key: 'ecc396b297434d07c2fbca896ad7dbb817c5e52c', "data-version": version }, h("div", { key: 'cf43facc3b6d7caa329fb2b62a67931e53aaeb98', class: this.classes }, this.icon ? h("post-icon", { name: this.icon }) : null, h("div", { key: '60232a82d9c231da41d22dd5e50744378dab54aa', class: "tag-text" }, h("slot", { key: '6b95fe941aac88e3ce6103187d5d831d53f8c315' })))));
|
|
39
51
|
}
|
|
40
52
|
get host() { return this; }
|
|
41
53
|
static get watchers() { return {
|
|
42
54
|
"variant": ["variantChanged"],
|
|
43
|
-
"size": ["sizeChanged"]
|
|
55
|
+
"size": ["sizeChanged"],
|
|
56
|
+
"icon": ["validateName"]
|
|
44
57
|
}; }
|
|
45
58
|
static get style() { return PostTagStyle0; }
|
|
46
59
|
}, [1, "post-tag", {
|
|
@@ -50,7 +63,8 @@ const PostTag$1 = /*@__PURE__*/ proxyCustomElement(class PostTag extends HTMLEle
|
|
|
50
63
|
"classes": [32]
|
|
51
64
|
}, undefined, {
|
|
52
65
|
"variant": ["variantChanged"],
|
|
53
|
-
"size": ["sizeChanged"]
|
|
66
|
+
"size": ["sizeChanged"],
|
|
67
|
+
"icon": ["validateName"]
|
|
54
68
|
}]);
|
|
55
69
|
function defineCustomElement$1() {
|
|
56
70
|
if (typeof customElements === "undefined") {
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { v as version } from './package.js';
|
|
3
|
-
import { c as checkType } from './check-type.js';
|
|
4
|
-
import './breakpoints.js';
|
|
5
3
|
|
|
6
4
|
const postTogglebuttonCss = ":host{cursor:pointer;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}:host(:focus-visible){outline-style:var(--post-core-border-style-solid) !important}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){:host(:focus-visible){outline-color:Highlight !important}}:host([aria-pressed=true]) ::slotted([data-showwhen=untoggled]){display:none}:host([aria-pressed=false]) ::slotted([data-showwhen=toggled]){display:none}";
|
|
7
5
|
const PostTogglebuttonStyle0 = postTogglebuttonCss;
|
|
@@ -23,27 +21,18 @@ const PostTogglebutton$1 = /*@__PURE__*/ proxyCustomElement(class PostTogglebutt
|
|
|
23
21
|
};
|
|
24
22
|
this.toggled = false;
|
|
25
23
|
}
|
|
26
|
-
validateToggled() {
|
|
27
|
-
checkType(this, 'toggled', 'boolean');
|
|
28
|
-
}
|
|
29
24
|
componentWillLoad() {
|
|
30
|
-
this.validateToggled();
|
|
31
25
|
// add event listener to not override listener that might be set on the host
|
|
32
26
|
this.host.addEventListener('click', () => this.handleClick());
|
|
33
27
|
this.host.addEventListener('keydown', (e) => this.handleKeydown(e));
|
|
34
28
|
}
|
|
35
29
|
render() {
|
|
36
|
-
return (h(Host, { key: '
|
|
30
|
+
return (h(Host, { key: 'd79b9952861afa27d8d1c5afb492e585bdc8a722', "data-version": version, role: "button", tabindex: "0", "aria-pressed": this.toggled.toString() }, h("slot", { key: 'aad4cc86756d0688d10f1b28dc14d6b464ab8830' })));
|
|
37
31
|
}
|
|
38
32
|
get host() { return this; }
|
|
39
|
-
static get watchers() { return {
|
|
40
|
-
"toggled": ["validateToggled"]
|
|
41
|
-
}; }
|
|
42
33
|
static get style() { return PostTogglebuttonStyle0; }
|
|
43
34
|
}, [1, "post-togglebutton", {
|
|
44
35
|
"toggled": [1028]
|
|
45
|
-
}, undefined, {
|
|
46
|
-
"toggled": ["validateToggled"]
|
|
47
36
|
}]);
|
|
48
37
|
function defineCustomElement$1() {
|
|
49
38
|
if (typeof customElements === "undefined") {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement as HTMLElement$1, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { I as IS_BROWSER } from './breakpoints.js';
|
|
3
|
-
import {
|
|
3
|
+
import { a as checkEmptyOrType } from './index2.js';
|
|
4
4
|
import { v as version$1 } from './package.js';
|
|
5
5
|
|
|
6
6
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -4535,15 +4535,13 @@ const PostTooltipTrigger$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltipT
|
|
|
4535
4535
|
this.boundTooltipHandler = this.handleTooltipEvent.bind(this);
|
|
4536
4536
|
}
|
|
4537
4537
|
validateControlFor() {
|
|
4538
|
-
|
|
4538
|
+
checkEmptyOrType(this, 'for', 'string');
|
|
4539
4539
|
}
|
|
4540
4540
|
get tooltip() {
|
|
4541
4541
|
if (!IS_BROWSER)
|
|
4542
4542
|
return null;
|
|
4543
4543
|
const ref = document.getElementById(this.for);
|
|
4544
|
-
return ref?.localName === 'post-tooltip'
|
|
4545
|
-
? ref
|
|
4546
|
-
: null;
|
|
4544
|
+
return ref?.localName === 'post-tooltip' ? ref : null;
|
|
4547
4545
|
}
|
|
4548
4546
|
componentDidLoad() {
|
|
4549
4547
|
this.setupTrigger();
|
|
@@ -4651,7 +4649,7 @@ const PostTooltipTrigger$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltipT
|
|
|
4651
4649
|
handleLeave(event) {
|
|
4652
4650
|
const newTarget = event.relatedTarget;
|
|
4653
4651
|
if ((this.tooltip && newTarget && this.tooltip.contains(newTarget)) ||
|
|
4654
|
-
|
|
4652
|
+
newTarget === this.trigger) {
|
|
4655
4653
|
return;
|
|
4656
4654
|
}
|
|
4657
4655
|
this.interestLostHandler();
|
|
@@ -4675,7 +4673,7 @@ const PostTooltipTrigger$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltipT
|
|
|
4675
4673
|
this.tooltip?.hide();
|
|
4676
4674
|
}
|
|
4677
4675
|
render() {
|
|
4678
|
-
return (h(Host, { key: '
|
|
4676
|
+
return (h(Host, { key: '2dc6f70e4dc7706a69efcede935e85faede3b73c', "data-version": version$1 }, h("slot", { key: 'b6301a66707d85a06b053a0a70a2a0cbc62877b3', onSlotchange: () => this.handleSlotChange() })));
|
|
4679
4677
|
}
|
|
4680
4678
|
get host() { return this; }
|
|
4681
4679
|
static get watchers() { return {
|
package/loaders/post-tooltip.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { v as version } from './package.js';
|
|
3
|
-
import {
|
|
3
|
+
import { d as checkEmptyOrOneOf } from './index2.js';
|
|
4
4
|
import './breakpoints.js';
|
|
5
|
-
import { d as defineCustomElement$2 } from './post-popovercontainer2.js';
|
|
5
|
+
import { P as PLACEMENT_TYPES, d as defineCustomElement$2 } from './post-popovercontainer2.js';
|
|
6
6
|
|
|
7
|
-
const postTooltipCss = ":host{display:none}:host([open]){display:
|
|
7
|
+
const postTooltipCss = ":host{display:none}:host([open]){display:contents}post-popovercontainer[arrow]::after{position:absolute;content:\"\";inset:-13px;z-index:-1}post-popovercontainer>div{padding:var(--post-core-dimension-4) var(--post-core-dimension-8);max-width:280px;min-height:32px;word-wrap:break-word;white-space:normal}";
|
|
8
8
|
const PostTooltipStyle0 = postTooltipCss;
|
|
9
9
|
|
|
10
10
|
const PostTooltip$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends HTMLElement {
|
|
@@ -14,14 +14,14 @@ const PostTooltip$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends
|
|
|
14
14
|
this.__attachShadow();
|
|
15
15
|
this.placement = 'top';
|
|
16
16
|
this.arrow = false;
|
|
17
|
-
this.animation =
|
|
17
|
+
this.animation = undefined;
|
|
18
18
|
this.open = false;
|
|
19
19
|
}
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
validatePlacement() {
|
|
21
|
+
checkEmptyOrOneOf(this, 'placement', PLACEMENT_TYPES);
|
|
22
22
|
}
|
|
23
|
-
|
|
24
|
-
this.
|
|
23
|
+
componentWillLoad() {
|
|
24
|
+
this.validatePlacement();
|
|
25
25
|
}
|
|
26
26
|
componentDidLoad() {
|
|
27
27
|
if (!this.host.id) {
|
|
@@ -62,11 +62,11 @@ const PostTooltip$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends
|
|
|
62
62
|
}
|
|
63
63
|
render() {
|
|
64
64
|
const popoverClass = `${this.arrow ? 'has-arrow' : ''}`;
|
|
65
|
-
return (h(Host, { key: '
|
|
65
|
+
return (h(Host, { key: 'e6bb167dd89c7549f4bed625dbeb652eac871ce5', "data-version": version, role: "tooltip" }, h("post-popovercontainer", { key: 'f5dc041dc440f7dc5410e9ee020f51a974ff3e83', safeSpace: "trapezoid", class: popoverClass, arrow: this.arrow, animation: this.animation, placement: this.placement, onPostToggle: e => this.handleToggle(e), ref: (el) => (this.popoverRef = el) }, h("slot", { key: 'e1ee7b0cfb57dc927a96574b10af50c3bd12328c' }))));
|
|
66
66
|
}
|
|
67
67
|
get host() { return this; }
|
|
68
68
|
static get watchers() { return {
|
|
69
|
-
"
|
|
69
|
+
"placement": ["validatePlacement"]
|
|
70
70
|
}; }
|
|
71
71
|
static get style() { return PostTooltipStyle0; }
|
|
72
72
|
}, [1, "post-tooltip", {
|
|
@@ -78,7 +78,7 @@ const PostTooltip$1 = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends
|
|
|
78
78
|
"hide": [64],
|
|
79
79
|
"toggle": [64]
|
|
80
80
|
}, undefined, {
|
|
81
|
-
"
|
|
81
|
+
"placement": ["validatePlacement"]
|
|
82
82
|
}]);
|
|
83
83
|
function defineCustomElement$1() {
|
|
84
84
|
if (typeof customElements === "undefined") {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@swisspost/design-system-components",
|
|
3
|
-
"version": "10.0.0-next.
|
|
3
|
+
"version": "10.0.0-next.39",
|
|
4
4
|
"description": "A collection of web components built with Stencil JS for the Swiss Post Design System.",
|
|
5
5
|
"author": "Swiss Post <design-system@post.ch>",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@floating-ui/dom": "1.7.0",
|
|
33
33
|
"@oddbird/popover-polyfill": "0.5.2",
|
|
34
|
-
"@swisspost/design-system-icons": "10.0.0-next.
|
|
35
|
-
"@swisspost/design-system-styles": "10.0.0-next.
|
|
34
|
+
"@swisspost/design-system-icons": "10.0.0-next.39",
|
|
35
|
+
"@swisspost/design-system-styles": "10.0.0-next.39",
|
|
36
36
|
"ally.js": "1.4.1",
|
|
37
37
|
"long-press-event": "2.5.0",
|
|
38
38
|
"nanoid": "5.1.5"
|
|
@@ -48,20 +48,24 @@
|
|
|
48
48
|
"@stencil/react-output-target": "0.5.3",
|
|
49
49
|
"@stencil/sass": "3.0.12",
|
|
50
50
|
"@types/jest": "29.5.14",
|
|
51
|
+
"@types/mock-fs": "4.13.4",
|
|
51
52
|
"@types/node": "22.10.5",
|
|
52
53
|
"@typescript-eslint/parser": "7.18.0",
|
|
53
54
|
"bootstrap": "5.3.3",
|
|
55
|
+
"copyfiles": "2.4.1",
|
|
54
56
|
"cypress": "14.3.2",
|
|
55
|
-
"cypress-axe": "1.
|
|
57
|
+
"cypress-axe": "1.6.0",
|
|
56
58
|
"cypress-storybook": "1.0.0",
|
|
57
59
|
"eslint": "9.18.0",
|
|
58
60
|
"eslint-plugin-react": "7.37.4",
|
|
59
61
|
"globals": "16.0.0",
|
|
62
|
+
"mock-fs": "5.5.0",
|
|
60
63
|
"rimraf": "6.0.1",
|
|
61
64
|
"rollup-plugin-postcss": "4.0.2",
|
|
62
65
|
"sass": "1.78.0",
|
|
63
66
|
"throttle-debounce": "5.0.2",
|
|
64
67
|
"ts-jest": "29.2.5",
|
|
68
|
+
"ts-node": "10.9.2",
|
|
65
69
|
"typescript": "5.8.3",
|
|
66
70
|
"typescript-eslint": "8.20.0",
|
|
67
71
|
"eslint-plugin-cypress": "4.2.0"
|
|
@@ -75,17 +79,23 @@
|
|
|
75
79
|
"frontend"
|
|
76
80
|
],
|
|
77
81
|
"scripts": {
|
|
78
|
-
"play": "stencil build --dev --port 9200 --serve --watch --docs --docs-readme",
|
|
79
|
-
"start": "stencil build --dev --watch --docs --docs-readme",
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
+
"play": "pnpm prebuild:script && stencil build --dev --port 9200 --serve --watch --docs --docs-readme",
|
|
83
|
+
"start": "pnpm prebuild:script && stencil build --dev --watch --docs --docs-readme",
|
|
84
|
+
"prebuild": "pnpm clean && pnpm prebuild:script",
|
|
85
|
+
"build": "stencil build --docs-readme",
|
|
86
|
+
"postbuild": "pnpm copy:styles:components-react & pnpm copy:styles:components-angular",
|
|
87
|
+
"clean": "rimraf dist hydrate loader loaders www src/styles/generated ../components-react/src/components/stencil-generated/ ../components-angular/projects/components/src/lib/stencil-generated/",
|
|
82
88
|
"unit": "stencil test --spec",
|
|
83
89
|
"unit:watch": "stencil test --spec --watchAll --silent",
|
|
90
|
+
"unit:updatesnapshot": "stencil test --spec --updateSnapshot",
|
|
84
91
|
"e2e": "cypress run --browser chrome",
|
|
85
92
|
"e2e:watch": "cypress open",
|
|
86
93
|
"e2e:ci": "xvfb-run -a cypress run --browser chrome",
|
|
87
94
|
"lint": "eslint",
|
|
88
95
|
"lint:fix": "eslint --fix",
|
|
89
|
-
"generate": "stencil generate"
|
|
96
|
+
"generate": "stencil generate",
|
|
97
|
+
"prebuild:script": "ts-node prebuild.ts",
|
|
98
|
+
"copy:styles:components-react": "copyfiles -f www/build/post-components.css ../components-react/src/components/stencil-generated/",
|
|
99
|
+
"copy:styles:components-angular": "copyfiles -f www/build/post-components.css ../components-angular/projects/components/src/lib/stencil-generated/"
|
|
90
100
|
}
|
|
91
101
|
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const constants = require('./constants-238701d3.js');
|
|
4
|
-
|
|
5
|
-
function checkNonEmpty(component, prop, customMessage) {
|
|
6
|
-
const componentName = component.host.localName;
|
|
7
|
-
const value = component[prop];
|
|
8
|
-
const defaultMessage = `The prop \`${String(prop)}\` of the \`${componentName}\` component is required.`;
|
|
9
|
-
const message = customMessage || defaultMessage;
|
|
10
|
-
if (constants.EMPTY_VALUES.some(v => v === value)) {
|
|
11
|
-
throw new Error(message);
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
exports.checkNonEmpty = checkNonEmpty;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
function checkOneOf(component, prop, possibleValues, customMessage) {
|
|
4
|
-
const componentName = component.host.localName;
|
|
5
|
-
const value = component[prop];
|
|
6
|
-
const defaultMessage = `The prop \`${String(prop)}\` of the \`${componentName}\` component must be one of the following values: ${possibleValues.join(', ')}.`;
|
|
7
|
-
const message = customMessage || defaultMessage;
|
|
8
|
-
if (!possibleValues.includes(value)) {
|
|
9
|
-
throw new Error(message);
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
exports.checkOneOf = checkOneOf;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
function checkType(component, prop, type, customMessage) {
|
|
4
|
-
const componentName = component.host.localName;
|
|
5
|
-
const value = component[prop];
|
|
6
|
-
const typeIsArray = type === 'array';
|
|
7
|
-
const valueIsArray = Array.isArray(value);
|
|
8
|
-
const defaultMessage = `The prop \`${String(prop)}\` of the \`${componentName}\` component must be of type \`
|
|
9
|
-
${type}\`.`;
|
|
10
|
-
const message = customMessage || defaultMessage;
|
|
11
|
-
if (typeIsArray || valueIsArray) {
|
|
12
|
-
if (valueIsArray !== typeIsArray) {
|
|
13
|
-
throw new Error(message);
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
else if (typeof value !== type) {
|
|
17
|
-
throw new Error(message);
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
exports.checkType = checkType;
|