@porsche-design-system/components-react 3.0.0-alpha.1 → 3.0.0-alpha.3
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/CHANGELOG.md +351 -3
- package/OSS_NOTICE +65234 -2280
- package/esm/lib/components/accordion.wrapper.js +2 -1
- package/esm/lib/components/banner.wrapper.js +3 -3
- package/esm/lib/components/carousel.wrapper.js +4 -3
- package/esm/lib/components/content-wrapper.wrapper.js +1 -1
- package/esm/lib/components/divider.wrapper.js +3 -3
- package/esm/lib/components/link-social.wrapper.js +1 -1
- package/esm/lib/components/link-tile.wrapper.js +1 -1
- package/esm/lib/components/modal.wrapper.js +4 -3
- package/esm/lib/components/model-signature.wrapper.js +22 -0
- package/esm/lib/components/pagination.wrapper.js +4 -3
- package/esm/lib/components/scroller.wrapper.js +3 -3
- package/esm/lib/components/segmented-control.wrapper.js +2 -1
- package/esm/lib/components/stepper-horizontal.wrapper.js +2 -1
- package/esm/lib/components/switch.wrapper.js +2 -1
- package/esm/lib/components/table.wrapper.js +2 -1
- package/esm/lib/components/tabs-bar.wrapper.js +4 -3
- package/esm/lib/components/tabs.wrapper.js +4 -3
- package/esm/lib/components/text-field-wrapper.wrapper.js +3 -3
- package/esm/lib/components/text-list.wrapper.js +3 -3
- package/esm/lib/components/textarea-wrapper.wrapper.js +3 -3
- package/esm/public-api.js +1 -0
- package/lib/components/accordion.wrapper.d.ts +12 -4
- package/lib/components/accordion.wrapper.js +2 -1
- package/lib/components/banner.wrapper.d.ts +18 -2
- package/lib/components/banner.wrapper.js +3 -3
- package/lib/components/button-group.wrapper.d.ts +2 -2
- package/lib/components/button-pure.wrapper.d.ts +15 -15
- package/lib/components/button.wrapper.d.ts +5 -5
- package/lib/components/carousel.wrapper.d.ts +43 -9
- package/lib/components/carousel.wrapper.js +4 -3
- package/lib/components/checkbox-wrapper.wrapper.d.ts +5 -5
- package/lib/components/content-wrapper.wrapper.d.ts +2 -2
- package/lib/components/content-wrapper.wrapper.js +1 -1
- package/lib/components/display.wrapper.d.ts +2 -2
- package/lib/components/divider.wrapper.d.ts +13 -5
- package/lib/components/divider.wrapper.js +3 -3
- package/lib/components/fieldset-wrapper.wrapper.d.ts +5 -5
- package/lib/components/flex-item.wrapper.d.ts +2 -2
- package/lib/components/flex.wrapper.d.ts +2 -2
- package/lib/components/grid-item.wrapper.d.ts +2 -2
- package/lib/components/grid.wrapper.d.ts +2 -2
- package/lib/components/heading.wrapper.d.ts +2 -2
- package/lib/components/headline.wrapper.d.ts +2 -2
- package/lib/components/icon.wrapper.d.ts +2 -2
- package/lib/components/index.d.ts +1 -0
- package/lib/components/inline-notification.wrapper.d.ts +5 -5
- package/lib/components/link-pure.wrapper.d.ts +15 -15
- package/lib/components/link-social.wrapper.d.ts +8 -8
- package/lib/components/link-social.wrapper.js +1 -1
- package/lib/components/link-tile.wrapper.d.ts +7 -7
- package/lib/components/link-tile.wrapper.js +1 -1
- package/lib/components/link.wrapper.d.ts +5 -5
- package/lib/components/marque.wrapper.d.ts +5 -5
- package/lib/components/modal.wrapper.d.ts +22 -6
- package/lib/components/modal.wrapper.js +4 -3
- package/lib/components/model-signature.wrapper.d.ts +38 -0
- package/lib/components/model-signature.wrapper.js +24 -0
- package/lib/components/pagination.wrapper.d.ts +31 -15
- package/lib/components/pagination.wrapper.js +4 -3
- package/lib/components/popover.wrapper.d.ts +5 -5
- package/lib/components/radio-button-wrapper.wrapper.d.ts +5 -5
- package/lib/components/scroller.wrapper.d.ts +27 -11
- package/lib/components/scroller.wrapper.js +3 -3
- package/lib/components/segmented-control-item.wrapper.d.ts +5 -5
- package/lib/components/segmented-control.wrapper.d.ts +12 -4
- package/lib/components/segmented-control.wrapper.js +2 -1
- package/lib/components/select-wrapper.wrapper.d.ts +7 -7
- package/lib/components/spinner.wrapper.d.ts +2 -2
- package/lib/components/stepper-horizontal-item.wrapper.d.ts +5 -5
- package/lib/components/stepper-horizontal.wrapper.d.ts +13 -5
- package/lib/components/stepper-horizontal.wrapper.js +2 -1
- package/lib/components/switch.wrapper.d.ts +13 -5
- package/lib/components/switch.wrapper.js +2 -1
- package/lib/components/table-body.wrapper.d.ts +2 -2
- package/lib/components/table-cell.wrapper.d.ts +2 -2
- package/lib/components/table-head-cell.wrapper.d.ts +2 -2
- package/lib/components/table-head-row.wrapper.d.ts +2 -2
- package/lib/components/table-head.wrapper.d.ts +2 -2
- package/lib/components/table-row.wrapper.d.ts +2 -2
- package/lib/components/table.wrapper.d.ts +13 -5
- package/lib/components/table.wrapper.js +2 -1
- package/lib/components/tabs-bar.wrapper.d.ts +27 -11
- package/lib/components/tabs-bar.wrapper.js +4 -3
- package/lib/components/tabs-item.wrapper.d.ts +2 -2
- package/lib/components/tabs.wrapper.d.ts +27 -11
- package/lib/components/tabs.wrapper.js +4 -3
- package/lib/components/tag-dismissible.wrapper.d.ts +2 -2
- package/lib/components/tag.wrapper.d.ts +5 -5
- package/lib/components/text-field-wrapper.wrapper.d.ts +17 -9
- package/lib/components/text-field-wrapper.wrapper.js +3 -3
- package/lib/components/text-list-item.wrapper.d.ts +2 -2
- package/lib/components/text-list.wrapper.d.ts +21 -13
- package/lib/components/text-list.wrapper.js +3 -3
- package/lib/components/text.wrapper.d.ts +2 -2
- package/lib/components/textarea-wrapper.wrapper.d.ts +15 -7
- package/lib/components/textarea-wrapper.wrapper.js +3 -3
- package/lib/components/toast.wrapper.d.ts +2 -2
- package/lib/types.d.ts +164 -60
- package/package.json +2 -2
- package/public-api.js +2 -0
- package/ssr/components/dist/styles/esm/styles-entry.js +563 -2449
- package/ssr/components/dist/utils/esm/utils-entry.js +167 -2045
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/accordion.wrapper.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/banner.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/carousel.wrapper.js +5 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/content-wrapper.wrapper.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/divider.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/link-social.wrapper.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/link-tile.wrapper.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/modal.wrapper.js +5 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/model-signature.wrapper.js +37 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/pagination.wrapper.js +5 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/scroller.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/segmented-control.wrapper.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/stepper-horizontal.wrapper.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/switch.wrapper.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/table.wrapper.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/tabs-bar.wrapper.js +5 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/tabs.wrapper.js +5 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/text-field-wrapper.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/text-list-item.wrapper.js +2 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/text-list.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/textarea-wrapper.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/accordion.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/banner.js +3 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button-pure.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/carousel.js +9 -2
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/display.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/divider.js +6 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/heading.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/headline.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/icon.js +9 -2
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/inline-notification.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-pure.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-social.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-tile.js +8 -12
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/marque.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/modal.js +7 -2
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/model-signature.js +17 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/pagination.js +15 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/popover.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/scroller.js +8 -3
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/segmented-control-item.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select-wrapper.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/state-message.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/stepper-horizontal-item.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/stepper-horizontal.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/switch.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/table-head-cell.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/table.js +1 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tabs-bar.js +6 -2
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tabs.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tag-dismissible.js +5 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tag.js +10 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text-field-wrapper.js +14 -7
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text-list-item.js +1 -3
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text-list.js +5 -7
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text.js +14 -2
- package/ssr/components-react/projects/react-ssr-wrapper/src/public-api.js +2 -0
- package/ssr/esm/components/dist/styles/esm/styles-entry.js +536 -2423
- package/ssr/esm/components/dist/utils/esm/utils-entry.js +163 -2046
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/accordion.wrapper.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/banner.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/carousel.wrapper.js +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/content-wrapper.wrapper.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/divider.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/link-social.wrapper.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/link-tile.wrapper.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/modal.wrapper.js +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/model-signature.wrapper.js +35 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/pagination.wrapper.js +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/scroller.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/segmented-control.wrapper.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/stepper-horizontal.wrapper.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/switch.wrapper.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/table.wrapper.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/tabs-bar.wrapper.js +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/tabs.wrapper.js +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/text-field-wrapper.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/text-list-item.wrapper.js +2 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/text-list.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/textarea-wrapper.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/accordion.js +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/banner.js +5 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button-group.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button-pure.js +4 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button.js +4 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/carousel.js +10 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/checkbox-wrapper.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/content-wrapper.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/display.js +3 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/divider.js +7 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/fieldset-wrapper.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/flex-item.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/flex.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/grid-item.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/grid.js +2 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/heading.js +3 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/headline.js +3 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/icon.js +10 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/inline-notification.js +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-pure.js +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-social.js +4 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-tile.js +10 -14
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link.js +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/marque.js +3 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/modal.js +8 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/model-signature.js +15 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/pagination.js +15 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/popover.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/scroller.js +8 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/segmented-control-item.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select-wrapper.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/state-message.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/stepper-horizontal-item.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/stepper-horizontal.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/switch.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/table-head-cell.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/table.js +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tabs-bar.js +6 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tabs.js +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tag-dismissible.js +5 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tag.js +10 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text-field-wrapper.js +15 -8
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text-list-item.js +2 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text-list.js +6 -8
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/text.js +14 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/public-api.js +1 -0
- package/ssr/lib/components/accordion.wrapper.d.ts +12 -4
- package/ssr/lib/components/banner.wrapper.d.ts +18 -2
- package/ssr/lib/components/button-group.wrapper.d.ts +2 -2
- package/ssr/lib/components/button-pure.wrapper.d.ts +15 -15
- package/ssr/lib/components/button.wrapper.d.ts +5 -5
- package/ssr/lib/components/carousel.wrapper.d.ts +43 -9
- package/ssr/lib/components/checkbox-wrapper.wrapper.d.ts +5 -5
- package/ssr/lib/components/content-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/display.wrapper.d.ts +2 -2
- package/ssr/lib/components/divider.wrapper.d.ts +13 -5
- package/ssr/lib/components/fieldset-wrapper.wrapper.d.ts +5 -5
- package/ssr/lib/components/flex-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/flex.wrapper.d.ts +2 -2
- package/ssr/lib/components/grid-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/grid.wrapper.d.ts +2 -2
- package/ssr/lib/components/heading.wrapper.d.ts +2 -2
- package/ssr/lib/components/headline.wrapper.d.ts +2 -2
- package/ssr/lib/components/icon.wrapper.d.ts +2 -2
- package/ssr/lib/components/index.d.ts +1 -0
- package/ssr/lib/components/inline-notification.wrapper.d.ts +5 -5
- package/ssr/lib/components/link-pure.wrapper.d.ts +15 -15
- package/ssr/lib/components/link-social.wrapper.d.ts +8 -8
- package/ssr/lib/components/link-tile.wrapper.d.ts +7 -7
- package/ssr/lib/components/link.wrapper.d.ts +5 -5
- package/ssr/lib/components/marque.wrapper.d.ts +5 -5
- package/ssr/lib/components/modal.wrapper.d.ts +22 -6
- package/ssr/lib/components/model-signature.wrapper.d.ts +38 -0
- package/ssr/lib/components/pagination.wrapper.d.ts +31 -15
- package/ssr/lib/components/popover.wrapper.d.ts +5 -5
- package/ssr/lib/components/radio-button-wrapper.wrapper.d.ts +5 -5
- package/ssr/lib/components/scroller.wrapper.d.ts +27 -11
- package/ssr/lib/components/segmented-control-item.wrapper.d.ts +5 -5
- package/ssr/lib/components/segmented-control.wrapper.d.ts +12 -4
- package/ssr/lib/components/select-wrapper.wrapper.d.ts +7 -7
- package/ssr/lib/components/spinner.wrapper.d.ts +2 -2
- package/ssr/lib/components/stepper-horizontal-item.wrapper.d.ts +5 -5
- package/ssr/lib/components/stepper-horizontal.wrapper.d.ts +13 -5
- package/ssr/lib/components/switch.wrapper.d.ts +13 -5
- package/ssr/lib/components/table-body.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-cell.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-head-cell.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-head-row.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-head.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-row.wrapper.d.ts +2 -2
- package/ssr/lib/components/table.wrapper.d.ts +13 -5
- package/ssr/lib/components/tabs-bar.wrapper.d.ts +27 -11
- package/ssr/lib/components/tabs-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/tabs.wrapper.d.ts +27 -11
- package/ssr/lib/components/tag-dismissible.wrapper.d.ts +2 -2
- package/ssr/lib/components/tag.wrapper.d.ts +5 -5
- package/ssr/lib/components/text-field-wrapper.wrapper.d.ts +17 -9
- package/ssr/lib/components/text-list-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/text-list.wrapper.d.ts +21 -13
- package/ssr/lib/components/text.wrapper.d.ts +2 -2
- package/ssr/lib/components/textarea-wrapper.wrapper.d.ts +15 -7
- package/ssr/lib/components/toast.wrapper.d.ts +2 -2
- package/ssr/lib/dsr-components/carousel.d.ts +1 -1
- package/ssr/lib/dsr-components/link-social.d.ts +1 -1
- package/ssr/lib/dsr-components/modal.d.ts +2 -1
- package/ssr/lib/dsr-components/model-signature.d.ts +5 -0
- package/ssr/lib/dsr-components/text-field-wrapper.d.ts +2 -0
- package/ssr/lib/dsr-components/text-list-item.d.ts +1 -2
- package/ssr/lib/types.d.ts +164 -60
|
@@ -58,6 +58,8 @@ const fontHyphenationStyle = {
|
|
|
58
58
|
|
|
59
59
|
const fontLineHeight = 'calc(6px + 2.125ex)';
|
|
60
60
|
|
|
61
|
+
const fontSizeTextXXSmall = '.75rem';
|
|
62
|
+
|
|
61
63
|
const fontSizeTextXSmall = 'clamp(0.81rem, 0.23vw + 0.77rem, 0.88rem)';
|
|
62
64
|
|
|
63
65
|
const fontSizeTextSmall = '1rem';
|
|
@@ -69,6 +71,7 @@ const fontSizeTextLarge = 'clamp(1.27rem, 0.51vw + 1.16rem, 1.78rem)';
|
|
|
69
71
|
const fontSizeTextXLarge = 'clamp(1.42rem, 0.94vw + 1.23rem, 2.37rem)';
|
|
70
72
|
|
|
71
73
|
const fontSizeText = {
|
|
74
|
+
xxSmall: fontSizeTextXXSmall,
|
|
72
75
|
xSmall: fontSizeTextXSmall,
|
|
73
76
|
small: fontSizeTextSmall,
|
|
74
77
|
medium: fontSizeTextMedium,
|
|
@@ -86,7 +89,7 @@ const fontSizeHeadingXLarge = fontSizeTextXLarge;
|
|
|
86
89
|
|
|
87
90
|
const fontSizeHeadingXXLarge = 'clamp(1.6rem, 1.56vw + 1.29rem, 3.16rem)';
|
|
88
91
|
|
|
89
|
-
const
|
|
92
|
+
const fontSizeDisplaySmall = 'clamp(1.8rem, 2.41vw + 1.32rem, 4.21rem)';
|
|
90
93
|
|
|
91
94
|
const fontSizeDisplayMedium = 'clamp(2.03rem, 3.58vw + 1.31rem, 5.61rem)';
|
|
92
95
|
|
|
@@ -106,8 +109,6 @@ const fontWeight = {
|
|
|
106
109
|
|
|
107
110
|
const fontStyleNormal = 'normal';
|
|
108
111
|
|
|
109
|
-
const fontStyleItalic = 'italic';
|
|
110
|
-
|
|
111
112
|
const fontVariant = 'normal';
|
|
112
113
|
|
|
113
114
|
const backdropFilter = 'blur(32px)';
|
|
@@ -116,19 +117,42 @@ const frostedGlassStyle = {
|
|
|
116
117
|
backdropFilter,
|
|
117
118
|
};
|
|
118
119
|
|
|
119
|
-
const
|
|
120
|
+
const _gradient = 'rgba(31,31,31,0.9) 0%,' +
|
|
121
|
+
'rgba(31,31,31,0.9) 20%,' +
|
|
122
|
+
'rgba(31,31,31,0.852589) 26.67%,' +
|
|
123
|
+
'rgba(32,32,32,0.768225) 33.33%,' +
|
|
124
|
+
'rgba(33,33,33,0.668116) 40%,' +
|
|
125
|
+
'rgba(34,34,34,0.557309) 46.67%,' +
|
|
126
|
+
'rgba(35,35,35,0.442691) 53.33%,' +
|
|
127
|
+
'rgba(36,36,36,0.331884) 60%,' +
|
|
128
|
+
'rgba(37,37,37,0.231775) 66.67%,' +
|
|
129
|
+
'rgba(38,38,38,0.147411) 73.33%,' +
|
|
130
|
+
'rgba(39,39,39,0.0816599) 80%,' +
|
|
131
|
+
'rgba(39,39,39,0.03551) 86.67%,' +
|
|
132
|
+
'rgba(39,39,39,0.0086472) 93.33%,' +
|
|
133
|
+
'rgba(39,39,39,0)';
|
|
134
|
+
|
|
135
|
+
const gradientToBottomStyle = {
|
|
136
|
+
background: `linear-gradient(to bottom, ${_gradient} 100%);`,
|
|
137
|
+
};
|
|
138
|
+
|
|
139
|
+
const gradientToTopStyle = {
|
|
140
|
+
background: `linear-gradient(to top, ${_gradient} 100%);`,
|
|
141
|
+
};
|
|
142
|
+
|
|
143
|
+
const breakpointBase = 0;
|
|
120
144
|
|
|
121
|
-
const breakpointXS =
|
|
145
|
+
const breakpointXS = 480;
|
|
122
146
|
|
|
123
|
-
const breakpointS =
|
|
147
|
+
const breakpointS = 760;
|
|
124
148
|
|
|
125
|
-
const breakpointM =
|
|
149
|
+
const breakpointM = 1000;
|
|
126
150
|
|
|
127
|
-
const breakpointL =
|
|
151
|
+
const breakpointL = 1300;
|
|
128
152
|
|
|
129
|
-
const breakpointXL =
|
|
153
|
+
const breakpointXL = 1760;
|
|
130
154
|
|
|
131
|
-
const breakpointXXL =
|
|
155
|
+
const breakpointXXL = 1920;
|
|
132
156
|
|
|
133
157
|
const breakpoint = {
|
|
134
158
|
base: breakpointBase,
|
|
@@ -141,15 +165,13 @@ const breakpoint = {
|
|
|
141
165
|
};
|
|
142
166
|
|
|
143
167
|
function getMediaQueryMin(min) {
|
|
144
|
-
return `@media(min-width:${breakpoint[min]})`;
|
|
168
|
+
return `@media(min-width:${breakpoint[min]}px)`;
|
|
145
169
|
}
|
|
146
170
|
|
|
147
171
|
const spacingFluidMedium = 'clamp(16px, 1.25vw + 12px, 36px)';
|
|
148
172
|
|
|
149
173
|
const gridGap = spacingFluidMedium;
|
|
150
174
|
|
|
151
|
-
const gridWidthMin = '320px';
|
|
152
|
-
|
|
153
175
|
const gridWidthMax = '2560px';
|
|
154
176
|
|
|
155
177
|
// fluid sizing calculated by https://fluidtypography.com/#app-get-started
|
|
@@ -160,70 +182,12 @@ const gridSafeZoneBase = 'clamp(22px, 10.625vw - 12px, 192px)';
|
|
|
160
182
|
// gridSafeZoneXXL: Viewport Width Range = 1920 - 2560px / Size Range = 192 - 512px
|
|
161
183
|
const gridSafeZoneXXL = 'clamp(192px, 50vw - 768px, 512px)';
|
|
162
184
|
|
|
163
|
-
const gridFullColumnStart = 'full-start';
|
|
164
|
-
|
|
165
|
-
const gridExtendedColumnStart = 'extended-start';
|
|
166
|
-
|
|
167
|
-
const gridBasicColumnStart = 'basic-start';
|
|
168
|
-
|
|
169
|
-
const gridNarrowColumnStart = 'narrow-start';
|
|
170
|
-
|
|
171
|
-
const gridNarrowColumnEnd = 'narrow-end';
|
|
172
|
-
|
|
173
|
-
const gridBasicColumnEnd = 'basic-end';
|
|
174
|
-
|
|
175
|
-
const gridExtendedColumnEnd = 'extended-end';
|
|
176
|
-
|
|
177
|
-
const gridFullColumnEnd = 'full-end';
|
|
178
|
-
|
|
179
|
-
const _cssVariableGridExtendedSpanOneHalf = '--pds-grid-extended-span-one-half';
|
|
180
|
-
const _cssVariableGridBasicSpanOneHalf = '--pds-grid-basic-span-one-half';
|
|
181
|
-
const _cssVariableGridBasicSpanOneThird = '--pds-grid-basic-span-one-third';
|
|
182
|
-
const _cssVariableGridBasicSpanTwoThirds = '--pds-grid-basic-span-two-thirds';
|
|
183
|
-
const _cssVariableGridNarrowSpanOneHalf = '--pds-grid-narrow-span-one-half';
|
|
184
|
-
const _cssVariableGridSafeZone = '--pds-internal-grid-safe-zone';
|
|
185
|
-
|
|
186
|
-
const outerColumn = `minmax(0, calc(var(${_cssVariableGridSafeZone}) - ${gridGap}))`;
|
|
187
|
-
const column = 'minmax(0, 1fr)';
|
|
188
|
-
const getColumns = (repeat) => (repeat > 1 ? `repeat(${repeat}, ${column})` : column);
|
|
189
|
-
const getColumnSpan = (span) => `span ${span}`;
|
|
190
|
-
const getGridTemplateColumns = (layout) => layout === 'mobile'
|
|
191
|
-
? `[${gridFullColumnStart}] ${outerColumn} [${gridExtendedColumnStart} ${gridBasicColumnStart} ${gridNarrowColumnStart}] ${getColumns(6)} [${gridNarrowColumnEnd} ${gridBasicColumnEnd} ${gridExtendedColumnEnd}] ${outerColumn} [${gridFullColumnEnd}]`
|
|
192
|
-
: `[${gridFullColumnStart}] ${outerColumn} [${gridExtendedColumnStart}] ${getColumns(1)} [${gridBasicColumnStart}] ${getColumns(2)} [${gridNarrowColumnStart}] ${getColumns(8)} [${gridNarrowColumnEnd}] ${getColumns(2)} [${gridBasicColumnEnd}] ${getColumns(1)} [${gridExtendedColumnEnd}] ${outerColumn} [${gridFullColumnEnd}]`;
|
|
193
|
-
({
|
|
194
|
-
[_cssVariableGridSafeZone]: gridSafeZoneBase,
|
|
195
|
-
[_cssVariableGridExtendedSpanOneHalf]: getColumnSpan(3),
|
|
196
|
-
[_cssVariableGridBasicSpanOneHalf]: getColumnSpan(3),
|
|
197
|
-
[_cssVariableGridBasicSpanOneThird]: getColumnSpan(2),
|
|
198
|
-
[_cssVariableGridBasicSpanTwoThirds]: getColumnSpan(4),
|
|
199
|
-
[_cssVariableGridNarrowSpanOneHalf]: getColumnSpan(3),
|
|
200
|
-
display: 'grid',
|
|
201
|
-
gridGap,
|
|
202
|
-
gridTemplateColumns: getGridTemplateColumns('mobile'),
|
|
203
|
-
minWidth: gridWidthMin,
|
|
204
|
-
maxWidth: gridWidthMax,
|
|
205
|
-
margin: 0,
|
|
206
|
-
padding: `0 calc(50% - ${gridWidthMax} / 2)`,
|
|
207
|
-
boxSizing: 'content-box',
|
|
208
|
-
[getMediaQueryMin('s')]: {
|
|
209
|
-
[_cssVariableGridExtendedSpanOneHalf]: getColumnSpan(7),
|
|
210
|
-
[_cssVariableGridBasicSpanOneHalf]: getColumnSpan(6),
|
|
211
|
-
[_cssVariableGridBasicSpanOneThird]: getColumnSpan(4),
|
|
212
|
-
[_cssVariableGridBasicSpanTwoThirds]: getColumnSpan(8),
|
|
213
|
-
[_cssVariableGridNarrowSpanOneHalf]: getColumnSpan(4),
|
|
214
|
-
gridTemplateColumns: getGridTemplateColumns('desktop'),
|
|
215
|
-
},
|
|
216
|
-
[getMediaQueryMin('xxl')]: {
|
|
217
|
-
[_cssVariableGridSafeZone]: gridSafeZoneXXL,
|
|
218
|
-
},
|
|
219
|
-
});
|
|
220
|
-
|
|
221
185
|
function getMediaQueryMax(max) {
|
|
222
|
-
return `@media(max-width:${breakpoint[max]
|
|
186
|
+
return `@media(max-width:${breakpoint[max] - 1}px)`;
|
|
223
187
|
}
|
|
224
188
|
|
|
225
189
|
function getMediaQueryMinMax(min, max) {
|
|
226
|
-
return `@media(min-width:${breakpoint[min]}) and (max-width:${breakpoint[max]
|
|
190
|
+
return `@media(min-width:${breakpoint[min]}px) and (max-width:${breakpoint[max] - 1}px)`;
|
|
227
191
|
}
|
|
228
192
|
|
|
229
193
|
const spacingStaticXSmall = '4px';
|
|
@@ -236,9 +200,13 @@ const spacingStaticLarge = '32px';
|
|
|
236
200
|
|
|
237
201
|
const spacingFluidXSmall = 'clamp(4px, 0.25vw + 3px, 8px)';
|
|
238
202
|
|
|
203
|
+
const spacingFluidSmall = 'clamp(8px, 0.5vw + 6px, 16px)';
|
|
204
|
+
|
|
205
|
+
const spacingFluidLarge = 'clamp(32px, 2.75vw + 23px, 76px)';
|
|
206
|
+
|
|
239
207
|
const themeDarkBackgroundShading = 'rgba(1, 2, 5, 0.67)';
|
|
240
208
|
|
|
241
|
-
const _displayFontPartA = `${
|
|
209
|
+
const _displayFontPartA = `${fontStyleNormal} ${fontVariant} ${fontWeightRegular} `;
|
|
242
210
|
const _displayFontPartB = `/${fontLineHeight} ${fontFamily}`;
|
|
243
211
|
|
|
244
212
|
const displayMediumStyle = {
|
|
@@ -264,6 +232,10 @@ const headingLargeStyle = {
|
|
|
264
232
|
font: `${_headingFontPartA}${fontSizeHeadingLarge}${_headingFontPartB}`,
|
|
265
233
|
};
|
|
266
234
|
|
|
235
|
+
const headingXLargeStyle = {
|
|
236
|
+
font: `${_headingFontPartA}${fontSizeHeadingXLarge}${_headingFontPartB}`,
|
|
237
|
+
};
|
|
238
|
+
|
|
267
239
|
const headingXXLargeStyle = {
|
|
268
240
|
font: `${_headingFontPartA}${fontSizeHeadingXXLarge}${_headingFontPartB}`,
|
|
269
241
|
};
|
|
@@ -281,13 +253,18 @@ const textSmallStyle = {
|
|
|
281
253
|
...fontHyphenationStyle,
|
|
282
254
|
};
|
|
283
255
|
|
|
256
|
+
const textLargeStyle = {
|
|
257
|
+
font: `${_textFontPartA}${fontSizeTextLarge}${_textFontPartB}`,
|
|
258
|
+
...fontHyphenationStyle,
|
|
259
|
+
};
|
|
260
|
+
|
|
284
261
|
// TODO: we shouldn't exclude xxl breakpoint
|
|
285
262
|
const mediaQueries = Object.entries(breakpoint)
|
|
286
263
|
.filter(([key]) => key !== 'xxl')
|
|
287
|
-
.map(([, val]) => `(min-width:${val})`);
|
|
264
|
+
.map(([, val]) => `(min-width:${val}px)`);
|
|
288
265
|
hasWindow && window.matchMedia ? mediaQueries.map(window.matchMedia) : [];
|
|
289
266
|
|
|
290
|
-
Object.entries(breakpoint).reduce((result, [key, val]) => (Object.assign(Object.assign({}, result), { [val]: key })), {});
|
|
267
|
+
Object.entries(breakpoint).reduce((result, [key, val]) => (Object.assign(Object.assign({}, result), { [`${val}px`]: key })), {});
|
|
291
268
|
|
|
292
269
|
const hasVisibleIcon = (iconName, iconSource) => {
|
|
293
270
|
return iconName !== 'none' || !!iconSource;
|
|
@@ -497,12 +474,6 @@ var _typeof$1 = typeof Symbol === "function" && typeof Symbol.iterator === "symb
|
|
|
497
474
|
|
|
498
475
|
var isBrowser = (typeof window === "undefined" ? "undefined" : _typeof$1(window)) === "object" && (typeof document === "undefined" ? "undefined" : _typeof$1(document)) === 'object' && document.nodeType === 9;
|
|
499
476
|
|
|
500
|
-
var module$1 = /*#__PURE__*/Object.freeze({
|
|
501
|
-
__proto__: null,
|
|
502
|
-
default: isBrowser,
|
|
503
|
-
isBrowser: isBrowser
|
|
504
|
-
});
|
|
505
|
-
|
|
506
477
|
var isProduction = process.env.NODE_ENV === 'production';
|
|
507
478
|
function warning(condition, message) {
|
|
508
479
|
if (!isProduction) {
|
|
@@ -1050,7 +1021,7 @@ function () {
|
|
|
1050
1021
|
|
|
1051
1022
|
return ConditionalRule;
|
|
1052
1023
|
}();
|
|
1053
|
-
var keyRegExp = /@media|@supports\s+/;
|
|
1024
|
+
var keyRegExp = /@container|@media|@supports\s+/;
|
|
1054
1025
|
var pluginConditionalRule = {
|
|
1055
1026
|
onCreateRule: function onCreateRule(key, styles, options) {
|
|
1056
1027
|
return keyRegExp.test(key) ? new ConditionalRule(key, styles, options) : null;
|
|
@@ -1347,7 +1318,7 @@ var pluginSimpleRule = {
|
|
|
1347
1318
|
}
|
|
1348
1319
|
};
|
|
1349
1320
|
|
|
1350
|
-
var plugins
|
|
1321
|
+
var plugins = [pluginStyleRule, pluginConditionalRule, pluginKeyframesRule, pluginKeyframeRule, pluginFontFaceRule, pluginViewportRule, pluginSimpleRule];
|
|
1351
1322
|
|
|
1352
1323
|
var defaultUpdateOptions = {
|
|
1353
1324
|
process: true
|
|
@@ -2614,7 +2585,7 @@ var Jss =
|
|
|
2614
2585
|
function () {
|
|
2615
2586
|
function Jss(options) {
|
|
2616
2587
|
this.id = instanceCounter++;
|
|
2617
|
-
this.version = "10.
|
|
2588
|
+
this.version = "10.10.0";
|
|
2618
2589
|
this.plugins = new PluginsRegistry();
|
|
2619
2590
|
this.options = {
|
|
2620
2591
|
id: {
|
|
@@ -2628,8 +2599,8 @@ function () {
|
|
|
2628
2599
|
minify: false
|
|
2629
2600
|
});
|
|
2630
2601
|
|
|
2631
|
-
for (var i = 0; i < plugins
|
|
2632
|
-
this.plugins.use(plugins
|
|
2602
|
+
for (var i = 0; i < plugins.length; i++) {
|
|
2603
|
+
this.plugins.use(plugins[i], {
|
|
2633
2604
|
queue: 'internal'
|
|
2634
2605
|
});
|
|
2635
2606
|
}
|
|
@@ -2894,54 +2865,24 @@ var jss_esm = /*#__PURE__*/Object.freeze({
|
|
|
2894
2865
|
toCssValue: toCssValue
|
|
2895
2866
|
});
|
|
2896
2867
|
|
|
2897
|
-
function getAugmentedNamespace(n) {
|
|
2898
|
-
if (n.__esModule) return n;
|
|
2899
|
-
var f = n.default;
|
|
2900
|
-
if (typeof f == "function") {
|
|
2901
|
-
var a = function a () {
|
|
2902
|
-
if (this instanceof a) {
|
|
2903
|
-
var args = [null];
|
|
2904
|
-
args.push.apply(args, arguments);
|
|
2905
|
-
var Ctor = Function.bind.apply(f, args);
|
|
2906
|
-
return new Ctor();
|
|
2907
|
-
}
|
|
2908
|
-
return f.apply(this, arguments);
|
|
2909
|
-
};
|
|
2910
|
-
a.prototype = f.prototype;
|
|
2911
|
-
} else a = {};
|
|
2912
|
-
Object.defineProperty(a, '__esModule', {value: true});
|
|
2913
|
-
Object.keys(n).forEach(function (k) {
|
|
2914
|
-
var d = Object.getOwnPropertyDescriptor(n, k);
|
|
2915
|
-
Object.defineProperty(a, k, d.get ? d : {
|
|
2916
|
-
enumerable: true,
|
|
2917
|
-
get: function () {
|
|
2918
|
-
return n[k];
|
|
2919
|
-
}
|
|
2920
|
-
});
|
|
2921
|
-
});
|
|
2922
|
-
return a;
|
|
2923
|
-
}
|
|
2924
|
-
|
|
2925
2868
|
/* eslint-disable no-var, prefer-template */
|
|
2926
2869
|
var uppercasePattern = /[A-Z]/g;
|
|
2927
2870
|
var msPattern = /^ms-/;
|
|
2928
|
-
var cache
|
|
2871
|
+
var cache = {};
|
|
2929
2872
|
|
|
2930
2873
|
function toHyphenLower(match) {
|
|
2931
2874
|
return '-' + match.toLowerCase()
|
|
2932
2875
|
}
|
|
2933
2876
|
|
|
2934
2877
|
function hyphenateStyleName(name) {
|
|
2935
|
-
if (cache
|
|
2936
|
-
return cache
|
|
2878
|
+
if (cache.hasOwnProperty(name)) {
|
|
2879
|
+
return cache[name]
|
|
2937
2880
|
}
|
|
2938
2881
|
|
|
2939
2882
|
var hName = name.replace(uppercasePattern, toHyphenLower);
|
|
2940
|
-
return (cache
|
|
2883
|
+
return (cache[name] = msPattern.test(hName) ? '-' + hName : hName)
|
|
2941
2884
|
}
|
|
2942
2885
|
|
|
2943
|
-
var index_cjs = hyphenateStyleName;
|
|
2944
|
-
|
|
2945
2886
|
/**
|
|
2946
2887
|
* Convert camel cased property names to dash separated.
|
|
2947
2888
|
*/
|
|
@@ -2950,7 +2891,7 @@ function convertCase(style) {
|
|
|
2950
2891
|
var converted = {};
|
|
2951
2892
|
|
|
2952
2893
|
for (var prop in style) {
|
|
2953
|
-
var key = prop.indexOf('--') === 0 ? prop :
|
|
2894
|
+
var key = prop.indexOf('--') === 0 ? prop : hyphenateStyleName(prop);
|
|
2954
2895
|
converted[key] = style[prop];
|
|
2955
2896
|
}
|
|
2956
2897
|
|
|
@@ -2984,7 +2925,7 @@ function camelCase() {
|
|
|
2984
2925
|
return value;
|
|
2985
2926
|
}
|
|
2986
2927
|
|
|
2987
|
-
var hyphenatedProp =
|
|
2928
|
+
var hyphenatedProp = hyphenateStyleName(prop); // There was no camel case in place
|
|
2988
2929
|
|
|
2989
2930
|
if (prop === hyphenatedProp) return value;
|
|
2990
2931
|
rule.prop(hyphenatedProp, value); // Core will ignore that property value we set the proper one above.
|
|
@@ -3289,6 +3230,34 @@ function jssNested() {
|
|
|
3289
3230
|
};
|
|
3290
3231
|
}
|
|
3291
3232
|
|
|
3233
|
+
function getAugmentedNamespace(n) {
|
|
3234
|
+
if (n.__esModule) return n;
|
|
3235
|
+
var f = n.default;
|
|
3236
|
+
if (typeof f == "function") {
|
|
3237
|
+
var a = function a () {
|
|
3238
|
+
if (this instanceof a) {
|
|
3239
|
+
var args = [null];
|
|
3240
|
+
args.push.apply(args, arguments);
|
|
3241
|
+
var Ctor = Function.bind.apply(f, args);
|
|
3242
|
+
return new Ctor();
|
|
3243
|
+
}
|
|
3244
|
+
return f.apply(this, arguments);
|
|
3245
|
+
};
|
|
3246
|
+
a.prototype = f.prototype;
|
|
3247
|
+
} else a = {};
|
|
3248
|
+
Object.defineProperty(a, '__esModule', {value: true});
|
|
3249
|
+
Object.keys(n).forEach(function (k) {
|
|
3250
|
+
var d = Object.getOwnPropertyDescriptor(n, k);
|
|
3251
|
+
Object.defineProperty(a, k, d.get ? d : {
|
|
3252
|
+
enumerable: true,
|
|
3253
|
+
get: function () {
|
|
3254
|
+
return n[k];
|
|
3255
|
+
}
|
|
3256
|
+
});
|
|
3257
|
+
});
|
|
3258
|
+
return a;
|
|
3259
|
+
}
|
|
3260
|
+
|
|
3292
3261
|
var _tslib$1 = {};
|
|
3293
3262
|
|
|
3294
3263
|
(function (exports) {
|
|
@@ -3697,10 +3666,10 @@ const themeLight = {
|
|
|
3697
3666
|
contrastHighColor: '#535457',
|
|
3698
3667
|
contrastHighColorDarken: '#353638',
|
|
3699
3668
|
contrastHighColorLighten: '#717276',
|
|
3700
|
-
hoverColor: 'rgba(148, 149, 152,
|
|
3669
|
+
hoverColor: 'rgba(148, 149, 152, .18)',
|
|
3701
3670
|
hoverColorDarken: '#75767A',
|
|
3702
3671
|
activeColor: 'rgba(148, 149, 152, 0.20)',
|
|
3703
|
-
focusColor: '#
|
|
3672
|
+
focusColor: '#1A44EA',
|
|
3704
3673
|
disabledColor: '#949598',
|
|
3705
3674
|
errorColor: '#E7323B',
|
|
3706
3675
|
errorColorDarken: '#C51720',
|
|
@@ -3735,10 +3704,10 @@ const themeDark = {
|
|
|
3735
3704
|
contrastHighColor: '#AFB0B3',
|
|
3736
3705
|
contrastHighColorDarken: '#909195',
|
|
3737
3706
|
contrastHighColorLighten: '#CECFD1',
|
|
3738
|
-
hoverColor: 'rgba(
|
|
3739
|
-
hoverColorDarken: '#
|
|
3707
|
+
hoverColor: 'rgba(148, 149, 152, .18)',
|
|
3708
|
+
hoverColorDarken: '#75767A',
|
|
3740
3709
|
activeColor: 'rgba(126, 127, 130, 0.20)',
|
|
3741
|
-
focusColor: '#
|
|
3710
|
+
focusColor: '#1A44EA',
|
|
3742
3711
|
disabledColor: '#7E7F82',
|
|
3743
3712
|
errorColor: '#CB3333',
|
|
3744
3713
|
errorColorDarken: '#9A2727',
|
|
@@ -3800,6 +3769,14 @@ const getInsetJssStyle = (value = 0) => {
|
|
|
3800
3769
|
bottom: value,
|
|
3801
3770
|
};
|
|
3802
3771
|
};
|
|
3772
|
+
// reset initial styles, e.g. in case link-pure is used with slotted anchor and nested within e.g. an accordion
|
|
3773
|
+
const getResetInitialStylesForSlottedAnchor = {
|
|
3774
|
+
margin: 0,
|
|
3775
|
+
padding: 0,
|
|
3776
|
+
outline: 0,
|
|
3777
|
+
borderRadius: 0,
|
|
3778
|
+
background: 'transparent',
|
|
3779
|
+
};
|
|
3803
3780
|
const getFocusJssStyle = (opts) => {
|
|
3804
3781
|
const { pseudo, offset: outlineOffset, color: outlineColor, } = Object.assign({ color: 'currentColor', offset: 2 }, opts);
|
|
3805
3782
|
return pseudo
|
|
@@ -3918,14 +3895,14 @@ const buildResponsiveStyles = (rawValue, getJssStyle) => {
|
|
|
3918
3895
|
[getMediaQueryMin(breakpointValue)]: getJssStyle(value[breakpointValue]) })), getJssStyle(value.base))
|
|
3919
3896
|
: getJssStyle(value);
|
|
3920
3897
|
};
|
|
3921
|
-
const isObject
|
|
3898
|
+
const isObject = (obj) => typeof obj === 'object' && !Array.isArray(obj);
|
|
3922
3899
|
// NOTE: taken from https://stackoverflow.com/a/48218209
|
|
3923
3900
|
const mergeDeep = (...objects) => {
|
|
3924
3901
|
return objects.reduce((prev, obj) => {
|
|
3925
3902
|
Object.keys(obj).forEach((key) => {
|
|
3926
3903
|
const pVal = prev[key];
|
|
3927
3904
|
const oVal = obj[key];
|
|
3928
|
-
if (isObject
|
|
3905
|
+
if (isObject(pVal) && isObject(oVal)) {
|
|
3929
3906
|
prev[key] = mergeDeep(pVal, oVal);
|
|
3930
3907
|
}
|
|
3931
3908
|
else {
|
|
@@ -3936,1961 +3913,131 @@ const mergeDeep = (...objects) => {
|
|
|
3936
3913
|
}, {});
|
|
3937
3914
|
};
|
|
3938
3915
|
|
|
3939
|
-
|
|
3940
|
-
{ name: 'Model', id: 'model' },
|
|
3941
|
-
{ name: 'Interest', id: 'interest' },
|
|
3942
|
-
{ name: 'VIN', id: 'vin' },
|
|
3943
|
-
{ name: 'Purchase Intention', id: 'purchaseIntention' },
|
|
3944
|
-
{ name: 'Status', id: 'status' },
|
|
3945
|
-
{ name: 'Comment', id: 'comment' },
|
|
3946
|
-
{ name: 'Lead ID', id: 'leadId' },
|
|
3947
|
-
{ name: 'Action', id: 'action', hideLabel: true },
|
|
3948
|
-
].map((item, i) => ({
|
|
3949
|
-
...item,
|
|
3950
|
-
...(i > 0 &&
|
|
3951
|
-
i < 7 &&
|
|
3952
|
-
i !== 5 && {
|
|
3953
|
-
active: i === 1,
|
|
3954
|
-
direction: 'asc',
|
|
3955
|
-
}),
|
|
3956
|
-
}));
|
|
3957
|
-
|
|
3958
|
-
[
|
|
3959
|
-
{ name: 'Column 1', id: 'col1' },
|
|
3960
|
-
{ name: 'Column 2', id: 'col2' },
|
|
3961
|
-
{ name: 'Column 3', id: 'col3' },
|
|
3962
|
-
].map((item, i) => ({
|
|
3963
|
-
...item,
|
|
3964
|
-
active: i === 1,
|
|
3965
|
-
direction: 'asc',
|
|
3966
|
-
}));
|
|
3967
|
-
|
|
3968
|
-
Array.from(Array(4)).map(() => ({
|
|
3969
|
-
imageUrl: 'https://nav.porsche.com/00BC524/series-assets/1366/911@2x.jpg',
|
|
3970
|
-
imageWidth: 80,
|
|
3971
|
-
imageHeight: 48,
|
|
3972
|
-
html: "<a href='#'>link</a> <b>bold</b> <i>italic</i> <strong>strong</strong> <em>emphasized</em>",
|
|
3973
|
-
longText: 'Lorem ipsum dolor sit amet, consetetur sadipscing elitr',
|
|
3974
|
-
shortText: 'Some text',
|
|
3975
|
-
}));
|
|
3976
|
-
|
|
3977
|
-
var now = Date.now();
|
|
3978
|
-
var fnValuesNs = "fnValues" + now;
|
|
3979
|
-
var fnRuleNs = "fnStyle" + ++now;
|
|
3980
|
-
|
|
3981
|
-
var functionPlugin = function functionPlugin() {
|
|
3982
|
-
return {
|
|
3983
|
-
onCreateRule: function onCreateRule(name, decl, options) {
|
|
3984
|
-
if (typeof decl !== 'function') return null;
|
|
3985
|
-
var rule = createRule(name, {}, options);
|
|
3986
|
-
rule[fnRuleNs] = decl;
|
|
3987
|
-
return rule;
|
|
3988
|
-
},
|
|
3989
|
-
onProcessStyle: function onProcessStyle(style, rule) {
|
|
3990
|
-
// We need to extract function values from the declaration, so that we can keep core unaware of them.
|
|
3991
|
-
// We need to do that only once.
|
|
3992
|
-
// We don't need to extract functions on each style update, since this can happen only once.
|
|
3993
|
-
// We don't support function values inside of function rules.
|
|
3994
|
-
if (fnValuesNs in rule || fnRuleNs in rule) return style;
|
|
3995
|
-
var fnValues = {};
|
|
3996
|
-
|
|
3997
|
-
for (var prop in style) {
|
|
3998
|
-
var value = style[prop];
|
|
3999
|
-
if (typeof value !== 'function') continue;
|
|
4000
|
-
delete style[prop];
|
|
4001
|
-
fnValues[prop] = value;
|
|
4002
|
-
}
|
|
4003
|
-
|
|
4004
|
-
rule[fnValuesNs] = fnValues;
|
|
4005
|
-
return style;
|
|
4006
|
-
},
|
|
4007
|
-
onUpdate: function onUpdate(data, rule, sheet, options) {
|
|
4008
|
-
var styleRule = rule;
|
|
4009
|
-
var fnRule = styleRule[fnRuleNs]; // If we have a style function, the entire rule is dynamic and style object
|
|
4010
|
-
// will be returned from that function.
|
|
4011
|
-
|
|
4012
|
-
if (fnRule) {
|
|
4013
|
-
// Empty object will remove all currently defined props
|
|
4014
|
-
// in case function rule returns a falsy value.
|
|
4015
|
-
styleRule.style = fnRule(data) || {};
|
|
4016
|
-
|
|
4017
|
-
if (process.env.NODE_ENV === 'development') {
|
|
4018
|
-
for (var prop in styleRule.style) {
|
|
4019
|
-
if (typeof styleRule.style[prop] === 'function') {
|
|
4020
|
-
process.env.NODE_ENV !== "production" ? warning(false, '[JSS] Function values inside function rules are not supported.') : void 0;
|
|
4021
|
-
break;
|
|
4022
|
-
}
|
|
4023
|
-
}
|
|
4024
|
-
}
|
|
4025
|
-
}
|
|
3916
|
+
const hasDocument = typeof document !== 'undefined';
|
|
4026
3917
|
|
|
4027
|
-
|
|
3918
|
+
hasDocument && 'scrollBehavior' in document.documentElement.style;
|
|
4028
3919
|
|
|
4029
|
-
|
|
4030
|
-
|
|
4031
|
-
styleRule.prop(_prop, fnValues[_prop](data), options);
|
|
4032
|
-
}
|
|
4033
|
-
}
|
|
4034
|
-
}
|
|
4035
|
-
};
|
|
3920
|
+
const isThemeDark = (theme) => {
|
|
3921
|
+
return theme === 'dark';
|
|
4036
3922
|
};
|
|
4037
3923
|
|
|
4038
|
-
|
|
4039
|
-
|
|
4040
|
-
|
|
4041
|
-
|
|
4042
|
-
|
|
4043
|
-
|
|
4044
|
-
result = Symbol.observable;
|
|
4045
|
-
} else {
|
|
4046
|
-
result = Symbol('observable');
|
|
4047
|
-
Symbol.observable = result;
|
|
4048
|
-
}
|
|
4049
|
-
} else {
|
|
4050
|
-
result = '@@observable';
|
|
4051
|
-
}
|
|
4052
|
-
|
|
4053
|
-
return result;
|
|
4054
|
-
}
|
|
4055
|
-
|
|
4056
|
-
/* global window */
|
|
4057
|
-
|
|
4058
|
-
var root;
|
|
4059
|
-
|
|
4060
|
-
if (typeof self !== 'undefined') {
|
|
4061
|
-
root = self;
|
|
4062
|
-
} else if (typeof window !== 'undefined') {
|
|
4063
|
-
root = window;
|
|
4064
|
-
} else if (typeof global !== 'undefined') {
|
|
4065
|
-
root = global;
|
|
4066
|
-
} else if (typeof module !== 'undefined') {
|
|
4067
|
-
root = module;
|
|
4068
|
-
} else {
|
|
4069
|
-
root = Function('return this')();
|
|
4070
|
-
}
|
|
4071
|
-
|
|
4072
|
-
var result = symbolObservablePonyfill(root);
|
|
4073
|
-
|
|
4074
|
-
var isObservable = function isObservable(value) {
|
|
4075
|
-
return value && value[result] && value === value[result]();
|
|
3924
|
+
const formatObjectOutput = (value) => {
|
|
3925
|
+
return JSON.stringify(value)
|
|
3926
|
+
.replace(/"([a-zA-Z?]+)":/g, '$1:') // remove double quotes from keys
|
|
3927
|
+
.replace(/([,:{])/g, '$1 ') // add space after following: ,:{
|
|
3928
|
+
.replace(/(})/g, ' $1') // add space before following: }
|
|
3929
|
+
.replace(/^"(.+)"$/, '$1'); // remove wrapping double quotes
|
|
4076
3930
|
};
|
|
3931
|
+
'value, ' +
|
|
3932
|
+
formatObjectOutput(BREAKPOINTS.reduce((prev, key) => (Object.assign(Object.assign({}, prev), { [key + (key !== 'base' ? '?' : '')]: 'value' })), {})).replace(/"/g, '');
|
|
4077
3933
|
|
|
4078
|
-
|
|
4079
|
-
return {
|
|
4080
|
-
onCreateRule: function onCreateRule(name, decl, options) {
|
|
4081
|
-
if (!isObservable(decl)) return null;
|
|
4082
|
-
var style$ = decl;
|
|
4083
|
-
var rule = createRule(name, {}, options); // TODO
|
|
4084
|
-
// Call `stream.subscribe()` returns a subscription, which should be explicitly
|
|
4085
|
-
// unsubscribed from when we know this sheet is no longer needed.
|
|
4086
|
-
|
|
4087
|
-
style$.subscribe(function (style) {
|
|
4088
|
-
for (var prop in style) {
|
|
4089
|
-
rule.prop(prop, style[prop], updateOptions);
|
|
4090
|
-
}
|
|
4091
|
-
});
|
|
4092
|
-
return rule;
|
|
4093
|
-
},
|
|
4094
|
-
onProcessRule: function onProcessRule(rule) {
|
|
4095
|
-
if (rule && rule.type !== 'style') return;
|
|
4096
|
-
var styleRule = rule;
|
|
4097
|
-
var style = styleRule.style;
|
|
4098
|
-
|
|
4099
|
-
var _loop = function _loop(prop) {
|
|
4100
|
-
var value = style[prop];
|
|
4101
|
-
if (!isObservable(value)) return "continue";
|
|
4102
|
-
delete style[prop];
|
|
4103
|
-
value.subscribe({
|
|
4104
|
-
next: function next(nextValue) {
|
|
4105
|
-
styleRule.prop(prop, nextValue, updateOptions);
|
|
4106
|
-
}
|
|
4107
|
-
});
|
|
4108
|
-
};
|
|
4109
|
-
|
|
4110
|
-
for (var prop in style) {
|
|
4111
|
-
var _ret = _loop(prop);
|
|
3934
|
+
const HEADING_TAGS = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6'];
|
|
4112
3935
|
|
|
4113
|
-
|
|
4114
|
-
|
|
4115
|
-
}
|
|
4116
|
-
|
|
3936
|
+
const getComponentCss$T = (size, compact, open, theme) => {
|
|
3937
|
+
const { primaryColor, hoverColor, focusColor, contrastLowColor } = getThemedColors(theme);
|
|
3938
|
+
const border = `1px solid ${contrastLowColor}`;
|
|
3939
|
+
return getCss(Object.assign(Object.assign({ '@global': {
|
|
3940
|
+
':host': addImportantToEachRule(Object.assign({ display: 'block' }, hostHiddenStyles)),
|
|
3941
|
+
button: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', position: 'relative', justifyContent: 'space-between', margin: '2px 0', width: '100%', textDecoration: 'none', border: 0, outline: 0, gap: '24px', background: 'transparent', cursor: 'pointer', textAlign: 'left', color: primaryColor }, textSmallStyle), { fontWeight: fontWeight.semiBold }), buildResponsiveStyles(size, (s) => ({
|
|
3942
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
3943
|
+
// @ts-ignore
|
|
3944
|
+
fontSize: fontSizeText[s],
|
|
3945
|
+
padding: compact ? '4px 0' : `${s === 'medium' ? '20px' : '12px'} 0`,
|
|
3946
|
+
}))), mergeDeep({
|
|
3947
|
+
'&::before': Object.assign({ content: '""', position: 'absolute', borderRadius: borderRadiusSmall, left: '-4px', right: '-4px' }, (compact
|
|
3948
|
+
? {
|
|
3949
|
+
top: '2px',
|
|
3950
|
+
bottom: '2px',
|
|
3951
|
+
}
|
|
3952
|
+
: {
|
|
3953
|
+
top: '6px',
|
|
3954
|
+
bottom: '6px',
|
|
3955
|
+
})),
|
|
3956
|
+
}, hoverMediaQuery({
|
|
3957
|
+
'&::before': {
|
|
3958
|
+
transition: getTransition('background-color'),
|
|
3959
|
+
},
|
|
3960
|
+
'&:hover::before': {
|
|
3961
|
+
background: hoverColor,
|
|
3962
|
+
},
|
|
3963
|
+
}))), { '&:focus::before': {
|
|
3964
|
+
border: `${borderWidthBase} solid ${focusColor}`,
|
|
3965
|
+
}, '&:not(:focus-visible)::before': {
|
|
3966
|
+
border: 0,
|
|
3967
|
+
} }),
|
|
3968
|
+
} }, (!compact && {
|
|
3969
|
+
root: {
|
|
3970
|
+
borderBottom: border,
|
|
3971
|
+
},
|
|
3972
|
+
})), { heading: {
|
|
3973
|
+
margin: 0,
|
|
3974
|
+
padding: 0,
|
|
3975
|
+
}, icon: {
|
|
3976
|
+
width: fontLineHeight,
|
|
3977
|
+
height: fontLineHeight,
|
|
3978
|
+
transformOrigin: '50% 50%',
|
|
3979
|
+
transform: open ? 'rotate3d(0)' : 'rotate3d(0,0,1,90deg)',
|
|
3980
|
+
transition: getTransition('transform'),
|
|
3981
|
+
}, collapsible: Object.assign({ color: primaryColor, padding: 0, overflow: 'hidden' }, (open
|
|
3982
|
+
? {
|
|
3983
|
+
height: 'auto',
|
|
3984
|
+
paddingBottom: compact ? spacingStaticSmall : '24px',
|
|
3985
|
+
visibility: 'visible',
|
|
3986
|
+
transition: getTransition('height') + `,visibility ${transitionDuration}`,
|
|
3987
|
+
animation: `$open ${transitionDuration} ease forwards`,
|
|
3988
|
+
}
|
|
3989
|
+
: {
|
|
3990
|
+
height: 0,
|
|
3991
|
+
visibility: 'hidden',
|
|
3992
|
+
transition: getTransition('height') + `,visibility ${transitionDuration} linear ${transitionDuration}`,
|
|
3993
|
+
})),
|
|
3994
|
+
// TODO: this doesn't get shortened and results in `keyframes-open` for some unknown reason
|
|
3995
|
+
'@keyframes open': {
|
|
3996
|
+
'0%,99%': {
|
|
3997
|
+
overflow: 'hidden',
|
|
3998
|
+
},
|
|
3999
|
+
'100%': {
|
|
4000
|
+
overflow: 'visible',
|
|
4001
|
+
},
|
|
4002
|
+
} }));
|
|
4117
4003
|
};
|
|
4118
4004
|
|
|
4119
|
-
|
|
4120
|
-
|
|
4121
|
-
|
|
4122
|
-
|
|
4123
|
-
* - Requires semicolon and new line after the value (except of last line)
|
|
4124
|
-
* - No nested rules support
|
|
4125
|
-
*/
|
|
4126
|
-
|
|
4127
|
-
var parse = function parse(cssText) {
|
|
4128
|
-
var style = {};
|
|
4129
|
-
var split = cssText.split(semiWithNl);
|
|
4130
|
-
|
|
4131
|
-
for (var i = 0; i < split.length; i++) {
|
|
4132
|
-
var decl = (split[i] || '').trim();
|
|
4133
|
-
if (!decl) continue;
|
|
4134
|
-
var colonIndex = decl.indexOf(':');
|
|
4135
|
-
|
|
4136
|
-
if (colonIndex === -1) {
|
|
4137
|
-
process.env.NODE_ENV !== "production" ? warning(false, "[JSS] Malformed CSS string \"" + decl + "\"") : void 0;
|
|
4138
|
-
continue;
|
|
4139
|
-
}
|
|
4140
|
-
|
|
4141
|
-
var prop = decl.substr(0, colonIndex).trim();
|
|
4142
|
-
var value = decl.substr(colonIndex + 1).trim();
|
|
4143
|
-
style[prop] = value;
|
|
4144
|
-
}
|
|
4005
|
+
const TOAST_Z_INDEX = 999999;
|
|
4006
|
+
const MODAL_Z_INDEX = 99999;
|
|
4007
|
+
const POPOVER_Z_INDEX = 9999;
|
|
4008
|
+
const BANNER_Z_INDEX = 99;
|
|
4145
4009
|
|
|
4146
|
-
|
|
4010
|
+
const oneColumnWidthS = `calc((100% - ${gridSafeZoneBase} * 2 - ${gridGap} * 13) / 14)`;
|
|
4011
|
+
const oneColumnWidthXXL = `calc((min(100%, ${gridWidthMax}) - ${gridSafeZoneXXL} * 2 - ${gridGap} * 13) / 14)`;
|
|
4012
|
+
const offsetHorizontalXXL = `max(0px, (100% - ${gridWidthMax}) / 2)`;
|
|
4013
|
+
const widthMap$1 = {
|
|
4014
|
+
narrow: {
|
|
4015
|
+
padding: `0 ${gridSafeZoneBase}`,
|
|
4016
|
+
[getMediaQueryMin('s')]: {
|
|
4017
|
+
padding: `0 calc(${gridSafeZoneBase} + ${gridGap} * 3 + ${oneColumnWidthS} * 3)`,
|
|
4018
|
+
},
|
|
4019
|
+
[getMediaQueryMin('xxl')]: {
|
|
4020
|
+
padding: `0 calc(${offsetHorizontalXXL} + ${gridSafeZoneXXL} + ${gridGap} * 3 + ${oneColumnWidthXXL} * 3)`,
|
|
4021
|
+
},
|
|
4022
|
+
},
|
|
4023
|
+
basic: {
|
|
4024
|
+
padding: `0 ${gridSafeZoneBase}`,
|
|
4025
|
+
[getMediaQueryMin('s')]: {
|
|
4026
|
+
padding: `0 calc(${gridSafeZoneBase} + ${gridGap} + ${oneColumnWidthS})`,
|
|
4027
|
+
},
|
|
4028
|
+
[getMediaQueryMin('xxl')]: {
|
|
4029
|
+
padding: `0 calc(${offsetHorizontalXXL} + ${gridSafeZoneXXL} + ${gridGap} + ${oneColumnWidthXXL})`,
|
|
4030
|
+
},
|
|
4031
|
+
},
|
|
4032
|
+
extended: {
|
|
4033
|
+
padding: `0 ${gridSafeZoneBase}`,
|
|
4034
|
+
[getMediaQueryMin('xxl')]: {
|
|
4035
|
+
padding: `0 calc(${offsetHorizontalXXL} + ${gridSafeZoneXXL})`,
|
|
4036
|
+
},
|
|
4037
|
+
},
|
|
4147
4038
|
};
|
|
4148
|
-
|
|
4149
|
-
|
|
4150
|
-
if (typeof rule.style === 'string') {
|
|
4151
|
-
rule.style = parse(rule.style);
|
|
4152
|
-
}
|
|
4153
|
-
};
|
|
4154
|
-
|
|
4155
|
-
function templatePlugin() {
|
|
4156
|
-
return {
|
|
4157
|
-
onProcessRule: onProcessRule
|
|
4158
|
-
};
|
|
4159
|
-
}
|
|
4160
|
-
|
|
4161
|
-
var isObject = function isObject(obj) {
|
|
4162
|
-
return obj && typeof obj === 'object' && !Array.isArray(obj);
|
|
4163
|
-
};
|
|
4164
|
-
|
|
4165
|
-
var valueNs = "extendCurrValue" + Date.now();
|
|
4166
|
-
|
|
4167
|
-
function mergeExtend(style, rule, sheet, newStyle) {
|
|
4168
|
-
var extendType = typeof style.extend; // Extend using a rule name.
|
|
4169
|
-
|
|
4170
|
-
if (extendType === 'string') {
|
|
4171
|
-
if (!sheet) return;
|
|
4172
|
-
var refRule = sheet.getRule(style.extend);
|
|
4173
|
-
if (!refRule) return;
|
|
4174
|
-
|
|
4175
|
-
if (refRule === rule) {
|
|
4176
|
-
process.env.NODE_ENV !== "production" ? warning(false, "[JSS] A rule tries to extend itself \n" + rule.toString()) : void 0;
|
|
4177
|
-
return;
|
|
4178
|
-
}
|
|
4179
|
-
|
|
4180
|
-
var parent = refRule.options.parent;
|
|
4181
|
-
|
|
4182
|
-
if (parent) {
|
|
4183
|
-
var originalStyle = parent.rules.raw[style.extend];
|
|
4184
|
-
extend(originalStyle, rule, sheet, newStyle);
|
|
4185
|
-
}
|
|
4186
|
-
|
|
4187
|
-
return;
|
|
4188
|
-
} // Extend using an array.
|
|
4189
|
-
|
|
4190
|
-
|
|
4191
|
-
if (Array.isArray(style.extend)) {
|
|
4192
|
-
for (var index = 0; index < style.extend.length; index++) {
|
|
4193
|
-
var singleExtend = style.extend[index];
|
|
4194
|
-
var singleStyle = typeof singleExtend === 'string' ? _extends({}, style, {
|
|
4195
|
-
extend: singleExtend
|
|
4196
|
-
}) : style.extend[index];
|
|
4197
|
-
extend(singleStyle, rule, sheet, newStyle);
|
|
4198
|
-
}
|
|
4199
|
-
|
|
4200
|
-
return;
|
|
4201
|
-
} // Extend is a style object.
|
|
4202
|
-
|
|
4203
|
-
|
|
4204
|
-
for (var prop in style.extend) {
|
|
4205
|
-
if (prop === 'extend') {
|
|
4206
|
-
extend(style.extend.extend, rule, sheet, newStyle);
|
|
4207
|
-
continue;
|
|
4208
|
-
}
|
|
4209
|
-
|
|
4210
|
-
if (isObject(style.extend[prop])) {
|
|
4211
|
-
if (!(prop in newStyle)) newStyle[prop] = {};
|
|
4212
|
-
extend(style.extend[prop], rule, sheet, newStyle[prop]);
|
|
4213
|
-
continue;
|
|
4214
|
-
}
|
|
4215
|
-
|
|
4216
|
-
newStyle[prop] = style.extend[prop];
|
|
4217
|
-
}
|
|
4218
|
-
}
|
|
4219
|
-
|
|
4220
|
-
function mergeRest(style, rule, sheet, newStyle) {
|
|
4221
|
-
// Copy base style.
|
|
4222
|
-
for (var prop in style) {
|
|
4223
|
-
if (prop === 'extend') continue;
|
|
4224
|
-
|
|
4225
|
-
if (isObject(newStyle[prop]) && isObject(style[prop])) {
|
|
4226
|
-
extend(style[prop], rule, sheet, newStyle[prop]);
|
|
4227
|
-
continue;
|
|
4228
|
-
}
|
|
4229
|
-
|
|
4230
|
-
if (isObject(style[prop])) {
|
|
4231
|
-
newStyle[prop] = extend(style[prop], rule, sheet);
|
|
4232
|
-
continue;
|
|
4233
|
-
}
|
|
4234
|
-
|
|
4235
|
-
newStyle[prop] = style[prop];
|
|
4236
|
-
}
|
|
4237
|
-
}
|
|
4238
|
-
/**
|
|
4239
|
-
* Recursively extend styles.
|
|
4240
|
-
*/
|
|
4241
|
-
|
|
4242
|
-
|
|
4243
|
-
function extend(style, rule, sheet, newStyle) {
|
|
4244
|
-
if (newStyle === void 0) {
|
|
4245
|
-
newStyle = {};
|
|
4246
|
-
}
|
|
4247
|
-
|
|
4248
|
-
mergeExtend(style, rule, sheet, newStyle);
|
|
4249
|
-
mergeRest(style, rule, sheet, newStyle);
|
|
4250
|
-
return newStyle;
|
|
4251
|
-
}
|
|
4252
|
-
/**
|
|
4253
|
-
* Handle `extend` property.
|
|
4254
|
-
*/
|
|
4255
|
-
|
|
4256
|
-
|
|
4257
|
-
function jssExtend() {
|
|
4258
|
-
function onProcessStyle(style, rule, sheet) {
|
|
4259
|
-
if ('extend' in style) return extend(style, rule, sheet);
|
|
4260
|
-
return style;
|
|
4261
|
-
}
|
|
4262
|
-
|
|
4263
|
-
function onChangeValue(value, prop, rule) {
|
|
4264
|
-
if (prop !== 'extend') return value; // Value is empty, remove properties set previously.
|
|
4265
|
-
|
|
4266
|
-
if (value == null || value === false) {
|
|
4267
|
-
for (var key in rule[valueNs]) {
|
|
4268
|
-
rule.prop(key, null);
|
|
4269
|
-
}
|
|
4270
|
-
|
|
4271
|
-
rule[valueNs] = null;
|
|
4272
|
-
return null;
|
|
4273
|
-
}
|
|
4274
|
-
|
|
4275
|
-
if (typeof value === 'object') {
|
|
4276
|
-
for (var _key in value) {
|
|
4277
|
-
rule.prop(_key, value[_key]);
|
|
4278
|
-
}
|
|
4279
|
-
|
|
4280
|
-
rule[valueNs] = value;
|
|
4281
|
-
} // Make sure we don't set the value in the core.
|
|
4282
|
-
|
|
4283
|
-
|
|
4284
|
-
return null;
|
|
4285
|
-
}
|
|
4286
|
-
|
|
4287
|
-
return {
|
|
4288
|
-
onProcessStyle: onProcessStyle,
|
|
4289
|
-
onChangeValue: onChangeValue
|
|
4290
|
-
};
|
|
4291
|
-
}
|
|
4292
|
-
|
|
4293
|
-
/**
|
|
4294
|
-
* Set selector.
|
|
4295
|
-
*
|
|
4296
|
-
* @param original rule
|
|
4297
|
-
* @param className class string
|
|
4298
|
-
* @return flag indicating function was successfull or not
|
|
4299
|
-
*/
|
|
4300
|
-
|
|
4301
|
-
function registerClass(rule, className) {
|
|
4302
|
-
// Skip falsy values
|
|
4303
|
-
if (!className) return true; // Support array of class names `{composes: ['foo', 'bar']}`
|
|
4304
|
-
|
|
4305
|
-
if (Array.isArray(className)) {
|
|
4306
|
-
for (var index = 0; index < className.length; index++) {
|
|
4307
|
-
var isSetted = registerClass(rule, className[index]);
|
|
4308
|
-
if (!isSetted) return false;
|
|
4309
|
-
}
|
|
4310
|
-
|
|
4311
|
-
return true;
|
|
4312
|
-
} // Support space separated class names `{composes: 'foo bar'}`
|
|
4313
|
-
|
|
4314
|
-
|
|
4315
|
-
if (className.indexOf(' ') > -1) {
|
|
4316
|
-
return registerClass(rule, className.split(' '));
|
|
4317
|
-
}
|
|
4318
|
-
|
|
4319
|
-
var parent = rule.options.parent; // It is a ref to a local rule.
|
|
4320
|
-
|
|
4321
|
-
if (className[0] === '$') {
|
|
4322
|
-
var refRule = parent.getRule(className.substr(1));
|
|
4323
|
-
|
|
4324
|
-
if (!refRule) {
|
|
4325
|
-
process.env.NODE_ENV !== "production" ? warning(false, "[JSS] Referenced rule is not defined. \n" + rule.toString()) : void 0;
|
|
4326
|
-
return false;
|
|
4327
|
-
}
|
|
4328
|
-
|
|
4329
|
-
if (refRule === rule) {
|
|
4330
|
-
process.env.NODE_ENV !== "production" ? warning(false, "[JSS] Cyclic composition detected. \n" + rule.toString()) : void 0;
|
|
4331
|
-
return false;
|
|
4332
|
-
}
|
|
4333
|
-
|
|
4334
|
-
parent.classes[rule.key] += " " + parent.classes[refRule.key];
|
|
4335
|
-
return true;
|
|
4336
|
-
}
|
|
4337
|
-
|
|
4338
|
-
parent.classes[rule.key] += " " + className;
|
|
4339
|
-
return true;
|
|
4340
|
-
}
|
|
4341
|
-
/**
|
|
4342
|
-
* Convert compose property to additional class, remove property from original styles.
|
|
4343
|
-
*/
|
|
4344
|
-
|
|
4345
|
-
|
|
4346
|
-
function jssCompose() {
|
|
4347
|
-
function onProcessStyle(style, rule) {
|
|
4348
|
-
if (!('composes' in style)) return style;
|
|
4349
|
-
registerClass(rule, style.composes); // Remove composes property to prevent infinite loop.
|
|
4350
|
-
|
|
4351
|
-
delete style.composes;
|
|
4352
|
-
return style;
|
|
4353
|
-
}
|
|
4354
|
-
|
|
4355
|
-
return {
|
|
4356
|
-
onProcessStyle: onProcessStyle
|
|
4357
|
-
};
|
|
4358
|
-
}
|
|
4359
|
-
|
|
4360
|
-
var px = hasCSSTOMSupport && CSS ? CSS.px : 'px';
|
|
4361
|
-
var ms = hasCSSTOMSupport && CSS ? CSS.ms : 'ms';
|
|
4362
|
-
var percent = hasCSSTOMSupport && CSS ? CSS.percent : '%';
|
|
4363
|
-
/**
|
|
4364
|
-
* Generated jss-plugin-default-unit CSS property units
|
|
4365
|
-
*/
|
|
4366
|
-
|
|
4367
|
-
var defaultUnits = {
|
|
4368
|
-
// Animation properties
|
|
4369
|
-
'animation-delay': ms,
|
|
4370
|
-
'animation-duration': ms,
|
|
4371
|
-
// Background properties
|
|
4372
|
-
'background-position': px,
|
|
4373
|
-
'background-position-x': px,
|
|
4374
|
-
'background-position-y': px,
|
|
4375
|
-
'background-size': px,
|
|
4376
|
-
// Border Properties
|
|
4377
|
-
border: px,
|
|
4378
|
-
'border-bottom': px,
|
|
4379
|
-
'border-bottom-left-radius': px,
|
|
4380
|
-
'border-bottom-right-radius': px,
|
|
4381
|
-
'border-bottom-width': px,
|
|
4382
|
-
'border-left': px,
|
|
4383
|
-
'border-left-width': px,
|
|
4384
|
-
'border-radius': px,
|
|
4385
|
-
'border-right': px,
|
|
4386
|
-
'border-right-width': px,
|
|
4387
|
-
'border-top': px,
|
|
4388
|
-
'border-top-left-radius': px,
|
|
4389
|
-
'border-top-right-radius': px,
|
|
4390
|
-
'border-top-width': px,
|
|
4391
|
-
'border-width': px,
|
|
4392
|
-
'border-block': px,
|
|
4393
|
-
'border-block-end': px,
|
|
4394
|
-
'border-block-end-width': px,
|
|
4395
|
-
'border-block-start': px,
|
|
4396
|
-
'border-block-start-width': px,
|
|
4397
|
-
'border-block-width': px,
|
|
4398
|
-
'border-inline': px,
|
|
4399
|
-
'border-inline-end': px,
|
|
4400
|
-
'border-inline-end-width': px,
|
|
4401
|
-
'border-inline-start': px,
|
|
4402
|
-
'border-inline-start-width': px,
|
|
4403
|
-
'border-inline-width': px,
|
|
4404
|
-
'border-start-start-radius': px,
|
|
4405
|
-
'border-start-end-radius': px,
|
|
4406
|
-
'border-end-start-radius': px,
|
|
4407
|
-
'border-end-end-radius': px,
|
|
4408
|
-
// Margin properties
|
|
4409
|
-
margin: px,
|
|
4410
|
-
'margin-bottom': px,
|
|
4411
|
-
'margin-left': px,
|
|
4412
|
-
'margin-right': px,
|
|
4413
|
-
'margin-top': px,
|
|
4414
|
-
'margin-block': px,
|
|
4415
|
-
'margin-block-end': px,
|
|
4416
|
-
'margin-block-start': px,
|
|
4417
|
-
'margin-inline': px,
|
|
4418
|
-
'margin-inline-end': px,
|
|
4419
|
-
'margin-inline-start': px,
|
|
4420
|
-
// Padding properties
|
|
4421
|
-
padding: px,
|
|
4422
|
-
'padding-bottom': px,
|
|
4423
|
-
'padding-left': px,
|
|
4424
|
-
'padding-right': px,
|
|
4425
|
-
'padding-top': px,
|
|
4426
|
-
'padding-block': px,
|
|
4427
|
-
'padding-block-end': px,
|
|
4428
|
-
'padding-block-start': px,
|
|
4429
|
-
'padding-inline': px,
|
|
4430
|
-
'padding-inline-end': px,
|
|
4431
|
-
'padding-inline-start': px,
|
|
4432
|
-
// Mask properties
|
|
4433
|
-
'mask-position-x': px,
|
|
4434
|
-
'mask-position-y': px,
|
|
4435
|
-
'mask-size': px,
|
|
4436
|
-
// Width and height properties
|
|
4437
|
-
height: px,
|
|
4438
|
-
width: px,
|
|
4439
|
-
'min-height': px,
|
|
4440
|
-
'max-height': px,
|
|
4441
|
-
'min-width': px,
|
|
4442
|
-
'max-width': px,
|
|
4443
|
-
// Position properties
|
|
4444
|
-
bottom: px,
|
|
4445
|
-
left: px,
|
|
4446
|
-
top: px,
|
|
4447
|
-
right: px,
|
|
4448
|
-
inset: px,
|
|
4449
|
-
'inset-block': px,
|
|
4450
|
-
'inset-block-end': px,
|
|
4451
|
-
'inset-block-start': px,
|
|
4452
|
-
'inset-inline': px,
|
|
4453
|
-
'inset-inline-end': px,
|
|
4454
|
-
'inset-inline-start': px,
|
|
4455
|
-
// Shadow properties
|
|
4456
|
-
'box-shadow': px,
|
|
4457
|
-
'text-shadow': px,
|
|
4458
|
-
// Column properties
|
|
4459
|
-
'column-gap': px,
|
|
4460
|
-
'column-rule': px,
|
|
4461
|
-
'column-rule-width': px,
|
|
4462
|
-
'column-width': px,
|
|
4463
|
-
// Font and text properties
|
|
4464
|
-
'font-size': px,
|
|
4465
|
-
'font-size-delta': px,
|
|
4466
|
-
'letter-spacing': px,
|
|
4467
|
-
'text-decoration-thickness': px,
|
|
4468
|
-
'text-indent': px,
|
|
4469
|
-
'text-stroke': px,
|
|
4470
|
-
'text-stroke-width': px,
|
|
4471
|
-
'word-spacing': px,
|
|
4472
|
-
// Motion properties
|
|
4473
|
-
motion: px,
|
|
4474
|
-
'motion-offset': px,
|
|
4475
|
-
// Outline properties
|
|
4476
|
-
outline: px,
|
|
4477
|
-
'outline-offset': px,
|
|
4478
|
-
'outline-width': px,
|
|
4479
|
-
// Perspective properties
|
|
4480
|
-
perspective: px,
|
|
4481
|
-
'perspective-origin-x': percent,
|
|
4482
|
-
'perspective-origin-y': percent,
|
|
4483
|
-
// Transform properties
|
|
4484
|
-
'transform-origin': percent,
|
|
4485
|
-
'transform-origin-x': percent,
|
|
4486
|
-
'transform-origin-y': percent,
|
|
4487
|
-
'transform-origin-z': percent,
|
|
4488
|
-
// Transition properties
|
|
4489
|
-
'transition-delay': ms,
|
|
4490
|
-
'transition-duration': ms,
|
|
4491
|
-
// Alignment properties
|
|
4492
|
-
'vertical-align': px,
|
|
4493
|
-
'flex-basis': px,
|
|
4494
|
-
// Some random properties
|
|
4495
|
-
'shape-margin': px,
|
|
4496
|
-
size: px,
|
|
4497
|
-
gap: px,
|
|
4498
|
-
// Grid properties
|
|
4499
|
-
grid: px,
|
|
4500
|
-
'grid-gap': px,
|
|
4501
|
-
'row-gap': px,
|
|
4502
|
-
'grid-row-gap': px,
|
|
4503
|
-
'grid-column-gap': px,
|
|
4504
|
-
'grid-template-rows': px,
|
|
4505
|
-
'grid-template-columns': px,
|
|
4506
|
-
'grid-auto-rows': px,
|
|
4507
|
-
'grid-auto-columns': px,
|
|
4508
|
-
// Not existing properties.
|
|
4509
|
-
// Used to avoid issues with jss-plugin-expand integration.
|
|
4510
|
-
'box-shadow-x': px,
|
|
4511
|
-
'box-shadow-y': px,
|
|
4512
|
-
'box-shadow-blur': px,
|
|
4513
|
-
'box-shadow-spread': px,
|
|
4514
|
-
'font-line-height': px,
|
|
4515
|
-
'text-shadow-x': px,
|
|
4516
|
-
'text-shadow-y': px,
|
|
4517
|
-
'text-shadow-blur': px
|
|
4518
|
-
};
|
|
4519
|
-
|
|
4520
|
-
/**
|
|
4521
|
-
* Clones the object and adds a camel cased property version.
|
|
4522
|
-
*/
|
|
4523
|
-
|
|
4524
|
-
function addCamelCasedVersion(obj) {
|
|
4525
|
-
var regExp = /(-[a-z])/g;
|
|
4526
|
-
|
|
4527
|
-
var replace = function replace(str) {
|
|
4528
|
-
return str[1].toUpperCase();
|
|
4529
|
-
};
|
|
4530
|
-
|
|
4531
|
-
var newObj = {};
|
|
4532
|
-
|
|
4533
|
-
for (var key in obj) {
|
|
4534
|
-
newObj[key] = obj[key];
|
|
4535
|
-
newObj[key.replace(regExp, replace)] = obj[key];
|
|
4536
|
-
}
|
|
4537
|
-
|
|
4538
|
-
return newObj;
|
|
4539
|
-
}
|
|
4540
|
-
|
|
4541
|
-
var units = addCamelCasedVersion(defaultUnits);
|
|
4542
|
-
/**
|
|
4543
|
-
* Recursive deep style passing function
|
|
4544
|
-
*/
|
|
4545
|
-
|
|
4546
|
-
function iterate(prop, value, options) {
|
|
4547
|
-
if (value == null) return value;
|
|
4548
|
-
|
|
4549
|
-
if (Array.isArray(value)) {
|
|
4550
|
-
for (var i = 0; i < value.length; i++) {
|
|
4551
|
-
value[i] = iterate(prop, value[i], options);
|
|
4552
|
-
}
|
|
4553
|
-
} else if (typeof value === 'object') {
|
|
4554
|
-
if (prop === 'fallbacks') {
|
|
4555
|
-
for (var innerProp in value) {
|
|
4556
|
-
value[innerProp] = iterate(innerProp, value[innerProp], options);
|
|
4557
|
-
}
|
|
4558
|
-
} else {
|
|
4559
|
-
for (var _innerProp in value) {
|
|
4560
|
-
value[_innerProp] = iterate(prop + "-" + _innerProp, value[_innerProp], options);
|
|
4561
|
-
}
|
|
4562
|
-
} // eslint-disable-next-line no-restricted-globals
|
|
4563
|
-
|
|
4564
|
-
} else if (typeof value === 'number' && isNaN(value) === false) {
|
|
4565
|
-
var unit = options[prop] || units[prop]; // Add the unit if available, except for the special case of 0px.
|
|
4566
|
-
|
|
4567
|
-
if (unit && !(value === 0 && unit === px)) {
|
|
4568
|
-
return typeof unit === 'function' ? unit(value).toString() : "" + value + unit;
|
|
4569
|
-
}
|
|
4570
|
-
|
|
4571
|
-
return value.toString();
|
|
4572
|
-
}
|
|
4573
|
-
|
|
4574
|
-
return value;
|
|
4575
|
-
}
|
|
4576
|
-
/**
|
|
4577
|
-
* Add unit to numeric values.
|
|
4578
|
-
*/
|
|
4579
|
-
|
|
4580
|
-
|
|
4581
|
-
function defaultUnit(options) {
|
|
4582
|
-
if (options === void 0) {
|
|
4583
|
-
options = {};
|
|
4584
|
-
}
|
|
4585
|
-
|
|
4586
|
-
var camelCasedOptions = addCamelCasedVersion(options);
|
|
4587
|
-
|
|
4588
|
-
function onProcessStyle(style, rule) {
|
|
4589
|
-
if (rule.type !== 'style') return style;
|
|
4590
|
-
|
|
4591
|
-
for (var prop in style) {
|
|
4592
|
-
style[prop] = iterate(prop, style[prop], camelCasedOptions);
|
|
4593
|
-
}
|
|
4594
|
-
|
|
4595
|
-
return style;
|
|
4596
|
-
}
|
|
4597
|
-
|
|
4598
|
-
function onChangeValue(value, prop) {
|
|
4599
|
-
return iterate(prop, value, camelCasedOptions);
|
|
4600
|
-
}
|
|
4601
|
-
|
|
4602
|
-
return {
|
|
4603
|
-
onProcessStyle: onProcessStyle,
|
|
4604
|
-
onChangeValue: onChangeValue
|
|
4605
|
-
};
|
|
4606
|
-
}
|
|
4607
|
-
|
|
4608
|
-
/**
|
|
4609
|
-
* A scheme for converting properties from array to regular style.
|
|
4610
|
-
* All properties listed below will be transformed to a string separated by space.
|
|
4611
|
-
*/
|
|
4612
|
-
var propArray = {
|
|
4613
|
-
'background-size': true,
|
|
4614
|
-
'background-position': true,
|
|
4615
|
-
border: true,
|
|
4616
|
-
'border-bottom': true,
|
|
4617
|
-
'border-left': true,
|
|
4618
|
-
'border-top': true,
|
|
4619
|
-
'border-right': true,
|
|
4620
|
-
'border-radius': true,
|
|
4621
|
-
'border-image': true,
|
|
4622
|
-
'border-width': true,
|
|
4623
|
-
'border-style': true,
|
|
4624
|
-
'border-color': true,
|
|
4625
|
-
'box-shadow': true,
|
|
4626
|
-
flex: true,
|
|
4627
|
-
margin: true,
|
|
4628
|
-
padding: true,
|
|
4629
|
-
outline: true,
|
|
4630
|
-
'transform-origin': true,
|
|
4631
|
-
transform: true,
|
|
4632
|
-
transition: true
|
|
4633
|
-
/**
|
|
4634
|
-
* A scheme for converting arrays to regular styles inside of objects.
|
|
4635
|
-
* For e.g.: "{position: [0, 0]}" => "background-position: 0 0;".
|
|
4636
|
-
*/
|
|
4637
|
-
|
|
4638
|
-
};
|
|
4639
|
-
var propArrayInObj = {
|
|
4640
|
-
position: true,
|
|
4641
|
-
// background-position
|
|
4642
|
-
size: true // background-size
|
|
4643
|
-
|
|
4644
|
-
/**
|
|
4645
|
-
* A scheme for parsing and building correct styles from passed objects.
|
|
4646
|
-
*/
|
|
4647
|
-
|
|
4648
|
-
};
|
|
4649
|
-
var propObj = {
|
|
4650
|
-
padding: {
|
|
4651
|
-
top: 0,
|
|
4652
|
-
right: 0,
|
|
4653
|
-
bottom: 0,
|
|
4654
|
-
left: 0
|
|
4655
|
-
},
|
|
4656
|
-
margin: {
|
|
4657
|
-
top: 0,
|
|
4658
|
-
right: 0,
|
|
4659
|
-
bottom: 0,
|
|
4660
|
-
left: 0
|
|
4661
|
-
},
|
|
4662
|
-
background: {
|
|
4663
|
-
attachment: null,
|
|
4664
|
-
color: null,
|
|
4665
|
-
image: null,
|
|
4666
|
-
position: null,
|
|
4667
|
-
repeat: null
|
|
4668
|
-
},
|
|
4669
|
-
border: {
|
|
4670
|
-
width: null,
|
|
4671
|
-
style: null,
|
|
4672
|
-
color: null
|
|
4673
|
-
},
|
|
4674
|
-
'border-top': {
|
|
4675
|
-
width: null,
|
|
4676
|
-
style: null,
|
|
4677
|
-
color: null
|
|
4678
|
-
},
|
|
4679
|
-
'border-right': {
|
|
4680
|
-
width: null,
|
|
4681
|
-
style: null,
|
|
4682
|
-
color: null
|
|
4683
|
-
},
|
|
4684
|
-
'border-bottom': {
|
|
4685
|
-
width: null,
|
|
4686
|
-
style: null,
|
|
4687
|
-
color: null
|
|
4688
|
-
},
|
|
4689
|
-
'border-left': {
|
|
4690
|
-
width: null,
|
|
4691
|
-
style: null,
|
|
4692
|
-
color: null
|
|
4693
|
-
},
|
|
4694
|
-
outline: {
|
|
4695
|
-
width: null,
|
|
4696
|
-
style: null,
|
|
4697
|
-
color: null
|
|
4698
|
-
},
|
|
4699
|
-
'list-style': {
|
|
4700
|
-
type: null,
|
|
4701
|
-
position: null,
|
|
4702
|
-
image: null
|
|
4703
|
-
},
|
|
4704
|
-
transition: {
|
|
4705
|
-
property: null,
|
|
4706
|
-
duration: null,
|
|
4707
|
-
'timing-function': null,
|
|
4708
|
-
timingFunction: null,
|
|
4709
|
-
// Needed for avoiding comilation issues with jss-plugin-camel-case
|
|
4710
|
-
delay: null
|
|
4711
|
-
},
|
|
4712
|
-
animation: {
|
|
4713
|
-
name: null,
|
|
4714
|
-
duration: null,
|
|
4715
|
-
'timing-function': null,
|
|
4716
|
-
timingFunction: null,
|
|
4717
|
-
// Needed to avoid compilation issues with jss-plugin-camel-case
|
|
4718
|
-
delay: null,
|
|
4719
|
-
'iteration-count': null,
|
|
4720
|
-
iterationCount: null,
|
|
4721
|
-
// Needed to avoid compilation issues with jss-plugin-camel-case
|
|
4722
|
-
direction: null,
|
|
4723
|
-
'fill-mode': null,
|
|
4724
|
-
fillMode: null,
|
|
4725
|
-
// Needed to avoid compilation issues with jss-plugin-camel-case
|
|
4726
|
-
'play-state': null,
|
|
4727
|
-
playState: null // Needed to avoid compilation issues with jss-plugin-camel-case
|
|
4728
|
-
|
|
4729
|
-
},
|
|
4730
|
-
'box-shadow': {
|
|
4731
|
-
x: 0,
|
|
4732
|
-
y: 0,
|
|
4733
|
-
blur: 0,
|
|
4734
|
-
spread: 0,
|
|
4735
|
-
color: null,
|
|
4736
|
-
inset: null
|
|
4737
|
-
},
|
|
4738
|
-
'text-shadow': {
|
|
4739
|
-
x: 0,
|
|
4740
|
-
y: 0,
|
|
4741
|
-
blur: null,
|
|
4742
|
-
color: null
|
|
4743
|
-
}
|
|
4744
|
-
/**
|
|
4745
|
-
* A scheme for converting non-standart properties inside object.
|
|
4746
|
-
* For e.g.: include 'border-radius' property inside 'border' object.
|
|
4747
|
-
*/
|
|
4748
|
-
|
|
4749
|
-
};
|
|
4750
|
-
var customPropObj = {
|
|
4751
|
-
border: {
|
|
4752
|
-
radius: 'border-radius',
|
|
4753
|
-
image: 'border-image',
|
|
4754
|
-
width: 'border-width',
|
|
4755
|
-
style: 'border-style',
|
|
4756
|
-
color: 'border-color'
|
|
4757
|
-
},
|
|
4758
|
-
'border-bottom': {
|
|
4759
|
-
width: 'border-bottom-width',
|
|
4760
|
-
style: 'border-bottom-style',
|
|
4761
|
-
color: 'border-bottom-color'
|
|
4762
|
-
},
|
|
4763
|
-
'border-top': {
|
|
4764
|
-
width: 'border-top-width',
|
|
4765
|
-
style: 'border-top-style',
|
|
4766
|
-
color: 'border-top-color'
|
|
4767
|
-
},
|
|
4768
|
-
'border-left': {
|
|
4769
|
-
width: 'border-left-width',
|
|
4770
|
-
style: 'border-left-style',
|
|
4771
|
-
color: 'border-left-color'
|
|
4772
|
-
},
|
|
4773
|
-
'border-right': {
|
|
4774
|
-
width: 'border-right-width',
|
|
4775
|
-
style: 'border-right-style',
|
|
4776
|
-
color: 'border-right-color'
|
|
4777
|
-
},
|
|
4778
|
-
background: {
|
|
4779
|
-
size: 'background-size',
|
|
4780
|
-
image: 'background-image'
|
|
4781
|
-
},
|
|
4782
|
-
font: {
|
|
4783
|
-
style: 'font-style',
|
|
4784
|
-
variant: 'font-variant',
|
|
4785
|
-
weight: 'font-weight',
|
|
4786
|
-
stretch: 'font-stretch',
|
|
4787
|
-
size: 'font-size',
|
|
4788
|
-
family: 'font-family',
|
|
4789
|
-
lineHeight: 'line-height',
|
|
4790
|
-
// Needed to avoid compilation issues with jss-plugin-camel-case
|
|
4791
|
-
'line-height': 'line-height'
|
|
4792
|
-
},
|
|
4793
|
-
flex: {
|
|
4794
|
-
grow: 'flex-grow',
|
|
4795
|
-
basis: 'flex-basis',
|
|
4796
|
-
direction: 'flex-direction',
|
|
4797
|
-
wrap: 'flex-wrap',
|
|
4798
|
-
flow: 'flex-flow',
|
|
4799
|
-
shrink: 'flex-shrink'
|
|
4800
|
-
},
|
|
4801
|
-
align: {
|
|
4802
|
-
self: 'align-self',
|
|
4803
|
-
items: 'align-items',
|
|
4804
|
-
content: 'align-content'
|
|
4805
|
-
},
|
|
4806
|
-
grid: {
|
|
4807
|
-
'template-columns': 'grid-template-columns',
|
|
4808
|
-
templateColumns: 'grid-template-columns',
|
|
4809
|
-
'template-rows': 'grid-template-rows',
|
|
4810
|
-
templateRows: 'grid-template-rows',
|
|
4811
|
-
'template-areas': 'grid-template-areas',
|
|
4812
|
-
templateAreas: 'grid-template-areas',
|
|
4813
|
-
template: 'grid-template',
|
|
4814
|
-
'auto-columns': 'grid-auto-columns',
|
|
4815
|
-
autoColumns: 'grid-auto-columns',
|
|
4816
|
-
'auto-rows': 'grid-auto-rows',
|
|
4817
|
-
autoRows: 'grid-auto-rows',
|
|
4818
|
-
'auto-flow': 'grid-auto-flow',
|
|
4819
|
-
autoFlow: 'grid-auto-flow',
|
|
4820
|
-
row: 'grid-row',
|
|
4821
|
-
column: 'grid-column',
|
|
4822
|
-
'row-start': 'grid-row-start',
|
|
4823
|
-
rowStart: 'grid-row-start',
|
|
4824
|
-
'row-end': 'grid-row-end',
|
|
4825
|
-
rowEnd: 'grid-row-end',
|
|
4826
|
-
'column-start': 'grid-column-start',
|
|
4827
|
-
columnStart: 'grid-column-start',
|
|
4828
|
-
'column-end': 'grid-column-end',
|
|
4829
|
-
columnEnd: 'grid-column-end',
|
|
4830
|
-
area: 'grid-area',
|
|
4831
|
-
gap: 'grid-gap',
|
|
4832
|
-
'row-gap': 'grid-row-gap',
|
|
4833
|
-
rowGap: 'grid-row-gap',
|
|
4834
|
-
'column-gap': 'grid-column-gap',
|
|
4835
|
-
columnGap: 'grid-column-gap'
|
|
4836
|
-
}
|
|
4837
|
-
};
|
|
4838
|
-
|
|
4839
|
-
/* eslint-disable no-use-before-define */
|
|
4840
|
-
/**
|
|
4841
|
-
* Map values by given prop.
|
|
4842
|
-
*
|
|
4843
|
-
* @param {Array} array of values
|
|
4844
|
-
* @param {String} original property
|
|
4845
|
-
* @param {String} original rule
|
|
4846
|
-
* @return {String} mapped values
|
|
4847
|
-
*/
|
|
4848
|
-
|
|
4849
|
-
function mapValuesByProp(value, prop, rule) {
|
|
4850
|
-
return value.map(function (item) {
|
|
4851
|
-
return objectToArray(item, prop, rule, false, true);
|
|
4852
|
-
});
|
|
4853
|
-
}
|
|
4854
|
-
/**
|
|
4855
|
-
* Convert array to nested array, if needed
|
|
4856
|
-
*/
|
|
4857
|
-
|
|
4858
|
-
|
|
4859
|
-
function processArray(value, prop, scheme, rule) {
|
|
4860
|
-
if (scheme[prop] == null) return value;
|
|
4861
|
-
if (value.length === 0) return [];
|
|
4862
|
-
if (Array.isArray(value[0])) return processArray(value[0], prop, scheme, rule);
|
|
4863
|
-
|
|
4864
|
-
if (typeof value[0] === 'object') {
|
|
4865
|
-
return mapValuesByProp(value, prop, rule);
|
|
4866
|
-
}
|
|
4867
|
-
|
|
4868
|
-
return [value];
|
|
4869
|
-
}
|
|
4870
|
-
/**
|
|
4871
|
-
* Convert object to array.
|
|
4872
|
-
*/
|
|
4873
|
-
|
|
4874
|
-
|
|
4875
|
-
function objectToArray(value, prop, rule, isFallback, isInArray) {
|
|
4876
|
-
if (!(propObj[prop] || customPropObj[prop])) return [];
|
|
4877
|
-
var result = []; // Check if exists any non-standard property
|
|
4878
|
-
|
|
4879
|
-
if (customPropObj[prop]) {
|
|
4880
|
-
// eslint-disable-next-line no-param-reassign
|
|
4881
|
-
value = customPropsToStyle(value, rule, customPropObj[prop], isFallback);
|
|
4882
|
-
} // Pass throught all standart props
|
|
4883
|
-
|
|
4884
|
-
|
|
4885
|
-
if (Object.keys(value).length) {
|
|
4886
|
-
for (var baseProp in propObj[prop]) {
|
|
4887
|
-
if (value[baseProp]) {
|
|
4888
|
-
if (Array.isArray(value[baseProp])) {
|
|
4889
|
-
result.push(propArrayInObj[baseProp] === null ? value[baseProp] : value[baseProp].join(' '));
|
|
4890
|
-
} else result.push(value[baseProp]);
|
|
4891
|
-
|
|
4892
|
-
continue;
|
|
4893
|
-
} // Add default value from props config.
|
|
4894
|
-
|
|
4895
|
-
|
|
4896
|
-
if (propObj[prop][baseProp] != null) {
|
|
4897
|
-
result.push(propObj[prop][baseProp]);
|
|
4898
|
-
}
|
|
4899
|
-
}
|
|
4900
|
-
}
|
|
4901
|
-
|
|
4902
|
-
if (!result.length || isInArray) return result;
|
|
4903
|
-
return [result];
|
|
4904
|
-
}
|
|
4905
|
-
/**
|
|
4906
|
-
* Convert custom properties values to styles adding them to rule directly
|
|
4907
|
-
*/
|
|
4908
|
-
|
|
4909
|
-
|
|
4910
|
-
function customPropsToStyle(value, rule, customProps, isFallback) {
|
|
4911
|
-
for (var prop in customProps) {
|
|
4912
|
-
var propName = customProps[prop]; // If current property doesn't exist already in rule - add new one
|
|
4913
|
-
|
|
4914
|
-
if (typeof value[prop] !== 'undefined' && (isFallback || !rule.prop(propName))) {
|
|
4915
|
-
var _styleDetector;
|
|
4916
|
-
|
|
4917
|
-
var appendedValue = styleDetector((_styleDetector = {}, _styleDetector[propName] = value[prop], _styleDetector), rule)[propName]; // Add style directly in rule
|
|
4918
|
-
|
|
4919
|
-
if (isFallback) rule.style.fallbacks[propName] = appendedValue;else rule.style[propName] = appendedValue;
|
|
4920
|
-
} // Delete converted property to avoid double converting
|
|
4921
|
-
|
|
4922
|
-
|
|
4923
|
-
delete value[prop];
|
|
4924
|
-
}
|
|
4925
|
-
|
|
4926
|
-
return value;
|
|
4927
|
-
}
|
|
4928
|
-
/**
|
|
4929
|
-
* Detect if a style needs to be converted.
|
|
4930
|
-
*/
|
|
4931
|
-
|
|
4932
|
-
|
|
4933
|
-
function styleDetector(style, rule, isFallback) {
|
|
4934
|
-
for (var prop in style) {
|
|
4935
|
-
var value = style[prop];
|
|
4936
|
-
|
|
4937
|
-
if (Array.isArray(value)) {
|
|
4938
|
-
// Check double arrays to avoid recursion.
|
|
4939
|
-
if (!Array.isArray(value[0])) {
|
|
4940
|
-
if (prop === 'fallbacks') {
|
|
4941
|
-
for (var index = 0; index < style.fallbacks.length; index++) {
|
|
4942
|
-
style.fallbacks[index] = styleDetector(style.fallbacks[index], rule, true);
|
|
4943
|
-
}
|
|
4944
|
-
|
|
4945
|
-
continue;
|
|
4946
|
-
}
|
|
4947
|
-
|
|
4948
|
-
style[prop] = processArray(value, prop, propArray, rule); // Avoid creating properties with empty values
|
|
4949
|
-
|
|
4950
|
-
if (!style[prop].length) delete style[prop];
|
|
4951
|
-
}
|
|
4952
|
-
} else if (typeof value === 'object') {
|
|
4953
|
-
if (prop === 'fallbacks') {
|
|
4954
|
-
style.fallbacks = styleDetector(style.fallbacks, rule, true);
|
|
4955
|
-
continue;
|
|
4956
|
-
}
|
|
4957
|
-
|
|
4958
|
-
style[prop] = objectToArray(value, prop, rule, isFallback); // Avoid creating properties with empty values
|
|
4959
|
-
|
|
4960
|
-
if (!style[prop].length) delete style[prop];
|
|
4961
|
-
} // Maybe a computed value resulting in an empty string
|
|
4962
|
-
else if (style[prop] === '') delete style[prop];
|
|
4963
|
-
}
|
|
4964
|
-
|
|
4965
|
-
return style;
|
|
4966
|
-
}
|
|
4967
|
-
/**
|
|
4968
|
-
* Adds possibility to write expanded styles.
|
|
4969
|
-
*/
|
|
4970
|
-
|
|
4971
|
-
|
|
4972
|
-
function jssExpand() {
|
|
4973
|
-
function onProcessStyle(style, rule) {
|
|
4974
|
-
if (!style || rule.type !== 'style') return style;
|
|
4975
|
-
|
|
4976
|
-
if (Array.isArray(style)) {
|
|
4977
|
-
// Pass rules one by one and reformat them
|
|
4978
|
-
for (var index = 0; index < style.length; index++) {
|
|
4979
|
-
style[index] = styleDetector(style[index], rule);
|
|
4980
|
-
}
|
|
4981
|
-
|
|
4982
|
-
return style;
|
|
4983
|
-
}
|
|
4984
|
-
|
|
4985
|
-
return styleDetector(style, rule);
|
|
4986
|
-
}
|
|
4987
|
-
|
|
4988
|
-
return {
|
|
4989
|
-
onProcessStyle: onProcessStyle
|
|
4990
|
-
};
|
|
4991
|
-
}
|
|
4992
|
-
|
|
4993
|
-
var cssVendor_cjs = {};
|
|
4994
|
-
|
|
4995
|
-
var require$$0 = /*@__PURE__*/getAugmentedNamespace(module$1);
|
|
4996
|
-
|
|
4997
|
-
var toConsumableArrayExports = {};
|
|
4998
|
-
var toConsumableArray = {
|
|
4999
|
-
get exports(){ return toConsumableArrayExports; },
|
|
5000
|
-
set exports(v){ toConsumableArrayExports = v; },
|
|
5001
|
-
};
|
|
5002
|
-
|
|
5003
|
-
var arrayWithoutHolesExports = {};
|
|
5004
|
-
var arrayWithoutHoles = {
|
|
5005
|
-
get exports(){ return arrayWithoutHolesExports; },
|
|
5006
|
-
set exports(v){ arrayWithoutHolesExports = v; },
|
|
5007
|
-
};
|
|
5008
|
-
|
|
5009
|
-
var arrayLikeToArrayExports = {};
|
|
5010
|
-
var arrayLikeToArray = {
|
|
5011
|
-
get exports(){ return arrayLikeToArrayExports; },
|
|
5012
|
-
set exports(v){ arrayLikeToArrayExports = v; },
|
|
5013
|
-
};
|
|
5014
|
-
|
|
5015
|
-
(function (module) {
|
|
5016
|
-
function _arrayLikeToArray(arr, len) {
|
|
5017
|
-
if (len == null || len > arr.length) len = arr.length;
|
|
5018
|
-
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
5019
|
-
return arr2;
|
|
5020
|
-
}
|
|
5021
|
-
module.exports = _arrayLikeToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5022
|
-
} (arrayLikeToArray));
|
|
5023
|
-
|
|
5024
|
-
(function (module) {
|
|
5025
|
-
var arrayLikeToArray = arrayLikeToArrayExports;
|
|
5026
|
-
function _arrayWithoutHoles(arr) {
|
|
5027
|
-
if (Array.isArray(arr)) return arrayLikeToArray(arr);
|
|
5028
|
-
}
|
|
5029
|
-
module.exports = _arrayWithoutHoles, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5030
|
-
} (arrayWithoutHoles));
|
|
5031
|
-
|
|
5032
|
-
var iterableToArrayExports = {};
|
|
5033
|
-
var iterableToArray = {
|
|
5034
|
-
get exports(){ return iterableToArrayExports; },
|
|
5035
|
-
set exports(v){ iterableToArrayExports = v; },
|
|
5036
|
-
};
|
|
5037
|
-
|
|
5038
|
-
(function (module) {
|
|
5039
|
-
function _iterableToArray(iter) {
|
|
5040
|
-
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
5041
|
-
}
|
|
5042
|
-
module.exports = _iterableToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5043
|
-
} (iterableToArray));
|
|
5044
|
-
|
|
5045
|
-
var unsupportedIterableToArrayExports = {};
|
|
5046
|
-
var unsupportedIterableToArray = {
|
|
5047
|
-
get exports(){ return unsupportedIterableToArrayExports; },
|
|
5048
|
-
set exports(v){ unsupportedIterableToArrayExports = v; },
|
|
5049
|
-
};
|
|
5050
|
-
|
|
5051
|
-
(function (module) {
|
|
5052
|
-
var arrayLikeToArray = arrayLikeToArrayExports;
|
|
5053
|
-
function _unsupportedIterableToArray(o, minLen) {
|
|
5054
|
-
if (!o) return;
|
|
5055
|
-
if (typeof o === "string") return arrayLikeToArray(o, minLen);
|
|
5056
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
5057
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
5058
|
-
if (n === "Map" || n === "Set") return Array.from(o);
|
|
5059
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);
|
|
5060
|
-
}
|
|
5061
|
-
module.exports = _unsupportedIterableToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5062
|
-
} (unsupportedIterableToArray));
|
|
5063
|
-
|
|
5064
|
-
var nonIterableSpreadExports = {};
|
|
5065
|
-
var nonIterableSpread = {
|
|
5066
|
-
get exports(){ return nonIterableSpreadExports; },
|
|
5067
|
-
set exports(v){ nonIterableSpreadExports = v; },
|
|
5068
|
-
};
|
|
5069
|
-
|
|
5070
|
-
(function (module) {
|
|
5071
|
-
function _nonIterableSpread() {
|
|
5072
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
5073
|
-
}
|
|
5074
|
-
module.exports = _nonIterableSpread, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5075
|
-
} (nonIterableSpread));
|
|
5076
|
-
|
|
5077
|
-
(function (module) {
|
|
5078
|
-
var arrayWithoutHoles = arrayWithoutHolesExports;
|
|
5079
|
-
var iterableToArray = iterableToArrayExports;
|
|
5080
|
-
var unsupportedIterableToArray = unsupportedIterableToArrayExports;
|
|
5081
|
-
var nonIterableSpread = nonIterableSpreadExports;
|
|
5082
|
-
function _toConsumableArray(arr) {
|
|
5083
|
-
return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();
|
|
5084
|
-
}
|
|
5085
|
-
module.exports = _toConsumableArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5086
|
-
} (toConsumableArray));
|
|
5087
|
-
|
|
5088
|
-
Object.defineProperty(cssVendor_cjs, '__esModule', { value: true });
|
|
5089
|
-
|
|
5090
|
-
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
|
|
5091
|
-
|
|
5092
|
-
var isInBrowser = _interopDefault(require$$0);
|
|
5093
|
-
var _toConsumableArray = _interopDefault(toConsumableArrayExports);
|
|
5094
|
-
|
|
5095
|
-
// Export javascript style and css style vendor prefixes.
|
|
5096
|
-
var js = '';
|
|
5097
|
-
var css = '';
|
|
5098
|
-
var vendor = '';
|
|
5099
|
-
var browser = '';
|
|
5100
|
-
var isTouch = isInBrowser && 'ontouchstart' in document.documentElement; // We should not do anything if required serverside.
|
|
5101
|
-
|
|
5102
|
-
if (isInBrowser) {
|
|
5103
|
-
// Order matters. We need to check Webkit the last one because
|
|
5104
|
-
// other vendors use to add Webkit prefixes to some properties
|
|
5105
|
-
var jsCssMap = {
|
|
5106
|
-
Moz: '-moz-',
|
|
5107
|
-
ms: '-ms-',
|
|
5108
|
-
O: '-o-',
|
|
5109
|
-
Webkit: '-webkit-'
|
|
5110
|
-
};
|
|
5111
|
-
|
|
5112
|
-
var _document$createEleme = document.createElement('p'),
|
|
5113
|
-
style = _document$createEleme.style;
|
|
5114
|
-
|
|
5115
|
-
var testProp = 'Transform';
|
|
5116
|
-
|
|
5117
|
-
for (var key in jsCssMap) {
|
|
5118
|
-
if (key + testProp in style) {
|
|
5119
|
-
js = key;
|
|
5120
|
-
css = jsCssMap[key];
|
|
5121
|
-
break;
|
|
5122
|
-
}
|
|
5123
|
-
} // Correctly detect the Edge browser.
|
|
5124
|
-
|
|
5125
|
-
|
|
5126
|
-
if (js === 'Webkit' && 'msHyphens' in style) {
|
|
5127
|
-
js = 'ms';
|
|
5128
|
-
css = jsCssMap.ms;
|
|
5129
|
-
browser = 'edge';
|
|
5130
|
-
} // Correctly detect the Safari browser.
|
|
5131
|
-
|
|
5132
|
-
|
|
5133
|
-
if (js === 'Webkit' && '-apple-trailing-word' in style) {
|
|
5134
|
-
vendor = 'apple';
|
|
5135
|
-
}
|
|
5136
|
-
}
|
|
5137
|
-
/**
|
|
5138
|
-
* Vendor prefix string for the current browser.
|
|
5139
|
-
*
|
|
5140
|
-
* @type {{js: String, css: String, vendor: String, browser: String}}
|
|
5141
|
-
* @api public
|
|
5142
|
-
*/
|
|
5143
|
-
|
|
5144
|
-
|
|
5145
|
-
var prefix = {
|
|
5146
|
-
js: js,
|
|
5147
|
-
css: css,
|
|
5148
|
-
vendor: vendor,
|
|
5149
|
-
browser: browser,
|
|
5150
|
-
isTouch: isTouch
|
|
5151
|
-
};
|
|
5152
|
-
|
|
5153
|
-
/**
|
|
5154
|
-
* Test if a keyframe at-rule should be prefixed or not
|
|
5155
|
-
*
|
|
5156
|
-
* @param {String} vendor prefix string for the current browser.
|
|
5157
|
-
* @return {String}
|
|
5158
|
-
* @api public
|
|
5159
|
-
*/
|
|
5160
|
-
|
|
5161
|
-
function supportedKeyframes(key) {
|
|
5162
|
-
// Keyframes is already prefixed. e.g. key = '@-webkit-keyframes a'
|
|
5163
|
-
if (key[1] === '-') return key; // No need to prefix IE/Edge. Older browsers will ignore unsupported rules.
|
|
5164
|
-
// https://caniuse.com/#search=keyframes
|
|
5165
|
-
|
|
5166
|
-
if (prefix.js === 'ms') return key;
|
|
5167
|
-
return "@" + prefix.css + "keyframes" + key.substr(10);
|
|
5168
|
-
}
|
|
5169
|
-
|
|
5170
|
-
// https://caniuse.com/#search=appearance
|
|
5171
|
-
|
|
5172
|
-
var appearence = {
|
|
5173
|
-
noPrefill: ['appearance'],
|
|
5174
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5175
|
-
if (prop !== 'appearance') return false;
|
|
5176
|
-
if (prefix.js === 'ms') return "-webkit-" + prop;
|
|
5177
|
-
return prefix.css + prop;
|
|
5178
|
-
}
|
|
5179
|
-
};
|
|
5180
|
-
|
|
5181
|
-
// https://caniuse.com/#search=color-adjust
|
|
5182
|
-
|
|
5183
|
-
var colorAdjust = {
|
|
5184
|
-
noPrefill: ['color-adjust'],
|
|
5185
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5186
|
-
if (prop !== 'color-adjust') return false;
|
|
5187
|
-
if (prefix.js === 'Webkit') return prefix.css + "print-" + prop;
|
|
5188
|
-
return prop;
|
|
5189
|
-
}
|
|
5190
|
-
};
|
|
5191
|
-
|
|
5192
|
-
var regExp = /[-\s]+(.)?/g;
|
|
5193
|
-
/**
|
|
5194
|
-
* Replaces the letter with the capital letter
|
|
5195
|
-
*
|
|
5196
|
-
* @param {String} match
|
|
5197
|
-
* @param {String} c
|
|
5198
|
-
* @return {String}
|
|
5199
|
-
* @api private
|
|
5200
|
-
*/
|
|
5201
|
-
|
|
5202
|
-
function toUpper(match, c) {
|
|
5203
|
-
return c ? c.toUpperCase() : '';
|
|
5204
|
-
}
|
|
5205
|
-
/**
|
|
5206
|
-
* Convert dash separated strings to camel-cased.
|
|
5207
|
-
*
|
|
5208
|
-
* @param {String} str
|
|
5209
|
-
* @return {String}
|
|
5210
|
-
* @api private
|
|
5211
|
-
*/
|
|
5212
|
-
|
|
5213
|
-
|
|
5214
|
-
function camelize(str) {
|
|
5215
|
-
return str.replace(regExp, toUpper);
|
|
5216
|
-
}
|
|
5217
|
-
|
|
5218
|
-
/**
|
|
5219
|
-
* Convert dash separated strings to pascal cased.
|
|
5220
|
-
*
|
|
5221
|
-
* @param {String} str
|
|
5222
|
-
* @return {String}
|
|
5223
|
-
* @api private
|
|
5224
|
-
*/
|
|
5225
|
-
|
|
5226
|
-
function pascalize(str) {
|
|
5227
|
-
return camelize("-" + str);
|
|
5228
|
-
}
|
|
5229
|
-
|
|
5230
|
-
// but we can use a longhand property instead.
|
|
5231
|
-
// https://caniuse.com/#search=mask
|
|
5232
|
-
|
|
5233
|
-
var mask = {
|
|
5234
|
-
noPrefill: ['mask'],
|
|
5235
|
-
supportedProperty: function supportedProperty(prop, style) {
|
|
5236
|
-
if (!/^mask/.test(prop)) return false;
|
|
5237
|
-
|
|
5238
|
-
if (prefix.js === 'Webkit') {
|
|
5239
|
-
var longhand = 'mask-image';
|
|
5240
|
-
|
|
5241
|
-
if (camelize(longhand) in style) {
|
|
5242
|
-
return prop;
|
|
5243
|
-
}
|
|
5244
|
-
|
|
5245
|
-
if (prefix.js + pascalize(longhand) in style) {
|
|
5246
|
-
return prefix.css + prop;
|
|
5247
|
-
}
|
|
5248
|
-
}
|
|
5249
|
-
|
|
5250
|
-
return prop;
|
|
5251
|
-
}
|
|
5252
|
-
};
|
|
5253
|
-
|
|
5254
|
-
// https://caniuse.com/#search=text-orientation
|
|
5255
|
-
|
|
5256
|
-
var textOrientation = {
|
|
5257
|
-
noPrefill: ['text-orientation'],
|
|
5258
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5259
|
-
if (prop !== 'text-orientation') return false;
|
|
5260
|
-
|
|
5261
|
-
if (prefix.vendor === 'apple' && !prefix.isTouch) {
|
|
5262
|
-
return prefix.css + prop;
|
|
5263
|
-
}
|
|
5264
|
-
|
|
5265
|
-
return prop;
|
|
5266
|
-
}
|
|
5267
|
-
};
|
|
5268
|
-
|
|
5269
|
-
// https://caniuse.com/#search=transform
|
|
5270
|
-
|
|
5271
|
-
var transform = {
|
|
5272
|
-
noPrefill: ['transform'],
|
|
5273
|
-
supportedProperty: function supportedProperty(prop, style, options) {
|
|
5274
|
-
if (prop !== 'transform') return false;
|
|
5275
|
-
|
|
5276
|
-
if (options.transform) {
|
|
5277
|
-
return prop;
|
|
5278
|
-
}
|
|
5279
|
-
|
|
5280
|
-
return prefix.css + prop;
|
|
5281
|
-
}
|
|
5282
|
-
};
|
|
5283
|
-
|
|
5284
|
-
// https://caniuse.com/#search=transition
|
|
5285
|
-
|
|
5286
|
-
var transition = {
|
|
5287
|
-
noPrefill: ['transition'],
|
|
5288
|
-
supportedProperty: function supportedProperty(prop, style, options) {
|
|
5289
|
-
if (prop !== 'transition') return false;
|
|
5290
|
-
|
|
5291
|
-
if (options.transition) {
|
|
5292
|
-
return prop;
|
|
5293
|
-
}
|
|
5294
|
-
|
|
5295
|
-
return prefix.css + prop;
|
|
5296
|
-
}
|
|
5297
|
-
};
|
|
5298
|
-
|
|
5299
|
-
// https://caniuse.com/#search=writing-mode
|
|
5300
|
-
|
|
5301
|
-
var writingMode = {
|
|
5302
|
-
noPrefill: ['writing-mode'],
|
|
5303
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5304
|
-
if (prop !== 'writing-mode') return false;
|
|
5305
|
-
|
|
5306
|
-
if (prefix.js === 'Webkit' || prefix.js === 'ms' && prefix.browser !== 'edge') {
|
|
5307
|
-
return prefix.css + prop;
|
|
5308
|
-
}
|
|
5309
|
-
|
|
5310
|
-
return prop;
|
|
5311
|
-
}
|
|
5312
|
-
};
|
|
5313
|
-
|
|
5314
|
-
// https://caniuse.com/#search=user-select
|
|
5315
|
-
|
|
5316
|
-
var userSelect = {
|
|
5317
|
-
noPrefill: ['user-select'],
|
|
5318
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5319
|
-
if (prop !== 'user-select') return false;
|
|
5320
|
-
|
|
5321
|
-
if (prefix.js === 'Moz' || prefix.js === 'ms' || prefix.vendor === 'apple') {
|
|
5322
|
-
return prefix.css + prop;
|
|
5323
|
-
}
|
|
5324
|
-
|
|
5325
|
-
return prop;
|
|
5326
|
-
}
|
|
5327
|
-
};
|
|
5328
|
-
|
|
5329
|
-
// https://caniuse.com/#search=multicolumn
|
|
5330
|
-
// https://github.com/postcss/autoprefixer/issues/491
|
|
5331
|
-
// https://github.com/postcss/autoprefixer/issues/177
|
|
5332
|
-
|
|
5333
|
-
var breakPropsOld = {
|
|
5334
|
-
supportedProperty: function supportedProperty(prop, style) {
|
|
5335
|
-
if (!/^break-/.test(prop)) return false;
|
|
5336
|
-
|
|
5337
|
-
if (prefix.js === 'Webkit') {
|
|
5338
|
-
var jsProp = "WebkitColumn" + pascalize(prop);
|
|
5339
|
-
return jsProp in style ? prefix.css + "column-" + prop : false;
|
|
5340
|
-
}
|
|
5341
|
-
|
|
5342
|
-
if (prefix.js === 'Moz') {
|
|
5343
|
-
var _jsProp = "page" + pascalize(prop);
|
|
5344
|
-
|
|
5345
|
-
return _jsProp in style ? "page-" + prop : false;
|
|
5346
|
-
}
|
|
5347
|
-
|
|
5348
|
-
return false;
|
|
5349
|
-
}
|
|
5350
|
-
};
|
|
5351
|
-
|
|
5352
|
-
// See https://github.com/postcss/autoprefixer/issues/324.
|
|
5353
|
-
|
|
5354
|
-
var inlineLogicalOld = {
|
|
5355
|
-
supportedProperty: function supportedProperty(prop, style) {
|
|
5356
|
-
if (!/^(border|margin|padding)-inline/.test(prop)) return false;
|
|
5357
|
-
if (prefix.js === 'Moz') return prop;
|
|
5358
|
-
var newProp = prop.replace('-inline', '');
|
|
5359
|
-
return prefix.js + pascalize(newProp) in style ? prefix.css + newProp : false;
|
|
5360
|
-
}
|
|
5361
|
-
};
|
|
5362
|
-
|
|
5363
|
-
// Camelization is required because we can't test using.
|
|
5364
|
-
// CSS syntax for e.g. in FF.
|
|
5365
|
-
|
|
5366
|
-
var unprefixed = {
|
|
5367
|
-
supportedProperty: function supportedProperty(prop, style) {
|
|
5368
|
-
return camelize(prop) in style ? prop : false;
|
|
5369
|
-
}
|
|
5370
|
-
};
|
|
5371
|
-
|
|
5372
|
-
var prefixed = {
|
|
5373
|
-
supportedProperty: function supportedProperty(prop, style) {
|
|
5374
|
-
var pascalized = pascalize(prop); // Return custom CSS variable without prefixing.
|
|
5375
|
-
|
|
5376
|
-
if (prop[0] === '-') return prop; // Return already prefixed value without prefixing.
|
|
5377
|
-
|
|
5378
|
-
if (prop[0] === '-' && prop[1] === '-') return prop;
|
|
5379
|
-
if (prefix.js + pascalized in style) return prefix.css + prop; // Try webkit fallback.
|
|
5380
|
-
|
|
5381
|
-
if (prefix.js !== 'Webkit' && "Webkit" + pascalized in style) return "-webkit-" + prop;
|
|
5382
|
-
return false;
|
|
5383
|
-
}
|
|
5384
|
-
};
|
|
5385
|
-
|
|
5386
|
-
// https://caniuse.com/#search=scroll-snap
|
|
5387
|
-
|
|
5388
|
-
var scrollSnap = {
|
|
5389
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5390
|
-
if (prop.substring(0, 11) !== 'scroll-snap') return false;
|
|
5391
|
-
|
|
5392
|
-
if (prefix.js === 'ms') {
|
|
5393
|
-
return "" + prefix.css + prop;
|
|
5394
|
-
}
|
|
5395
|
-
|
|
5396
|
-
return prop;
|
|
5397
|
-
}
|
|
5398
|
-
};
|
|
5399
|
-
|
|
5400
|
-
// https://caniuse.com/#search=overscroll-behavior
|
|
5401
|
-
|
|
5402
|
-
var overscrollBehavior = {
|
|
5403
|
-
supportedProperty: function supportedProperty(prop) {
|
|
5404
|
-
if (prop !== 'overscroll-behavior') return false;
|
|
5405
|
-
|
|
5406
|
-
if (prefix.js === 'ms') {
|
|
5407
|
-
return prefix.css + "scroll-chaining";
|
|
5408
|
-
}
|
|
5409
|
-
|
|
5410
|
-
return prop;
|
|
5411
|
-
}
|
|
5412
|
-
};
|
|
5413
|
-
|
|
5414
|
-
var propMap = {
|
|
5415
|
-
'flex-grow': 'flex-positive',
|
|
5416
|
-
'flex-shrink': 'flex-negative',
|
|
5417
|
-
'flex-basis': 'flex-preferred-size',
|
|
5418
|
-
'justify-content': 'flex-pack',
|
|
5419
|
-
order: 'flex-order',
|
|
5420
|
-
'align-items': 'flex-align',
|
|
5421
|
-
'align-content': 'flex-line-pack' // 'align-self' is handled by 'align-self' plugin.
|
|
5422
|
-
|
|
5423
|
-
}; // Support old flex spec from 2012.
|
|
5424
|
-
|
|
5425
|
-
var flex2012 = {
|
|
5426
|
-
supportedProperty: function supportedProperty(prop, style) {
|
|
5427
|
-
var newProp = propMap[prop];
|
|
5428
|
-
if (!newProp) return false;
|
|
5429
|
-
return prefix.js + pascalize(newProp) in style ? prefix.css + newProp : false;
|
|
5430
|
-
}
|
|
5431
|
-
};
|
|
5432
|
-
|
|
5433
|
-
var propMap$1 = {
|
|
5434
|
-
flex: 'box-flex',
|
|
5435
|
-
'flex-grow': 'box-flex',
|
|
5436
|
-
'flex-direction': ['box-orient', 'box-direction'],
|
|
5437
|
-
order: 'box-ordinal-group',
|
|
5438
|
-
'align-items': 'box-align',
|
|
5439
|
-
'flex-flow': ['box-orient', 'box-direction'],
|
|
5440
|
-
'justify-content': 'box-pack'
|
|
5441
|
-
};
|
|
5442
|
-
var propKeys = Object.keys(propMap$1);
|
|
5443
|
-
|
|
5444
|
-
var prefixCss = function prefixCss(p) {
|
|
5445
|
-
return prefix.css + p;
|
|
5446
|
-
}; // Support old flex spec from 2009.
|
|
5447
|
-
|
|
5448
|
-
|
|
5449
|
-
var flex2009 = {
|
|
5450
|
-
supportedProperty: function supportedProperty(prop, style, _ref) {
|
|
5451
|
-
var multiple = _ref.multiple;
|
|
5452
|
-
|
|
5453
|
-
if (propKeys.indexOf(prop) > -1) {
|
|
5454
|
-
var newProp = propMap$1[prop];
|
|
5455
|
-
|
|
5456
|
-
if (!Array.isArray(newProp)) {
|
|
5457
|
-
return prefix.js + pascalize(newProp) in style ? prefix.css + newProp : false;
|
|
5458
|
-
}
|
|
5459
|
-
|
|
5460
|
-
if (!multiple) return false;
|
|
5461
|
-
|
|
5462
|
-
for (var i = 0; i < newProp.length; i++) {
|
|
5463
|
-
if (!(prefix.js + pascalize(newProp[0]) in style)) {
|
|
5464
|
-
return false;
|
|
5465
|
-
}
|
|
5466
|
-
}
|
|
5467
|
-
|
|
5468
|
-
return newProp.map(prefixCss);
|
|
5469
|
-
}
|
|
5470
|
-
|
|
5471
|
-
return false;
|
|
5472
|
-
}
|
|
5473
|
-
};
|
|
5474
|
-
|
|
5475
|
-
// plugins = [
|
|
5476
|
-
// ...plugins,
|
|
5477
|
-
// breakPropsOld,
|
|
5478
|
-
// inlineLogicalOld,
|
|
5479
|
-
// unprefixed,
|
|
5480
|
-
// prefixed,
|
|
5481
|
-
// scrollSnap,
|
|
5482
|
-
// flex2012,
|
|
5483
|
-
// flex2009
|
|
5484
|
-
// ]
|
|
5485
|
-
// Plugins without 'noPrefill' value, going last.
|
|
5486
|
-
// 'flex-*' plugins should be at the bottom.
|
|
5487
|
-
// 'flex2009' going after 'flex2012'.
|
|
5488
|
-
// 'prefixed' going after 'unprefixed'
|
|
5489
|
-
|
|
5490
|
-
var plugins = [appearence, colorAdjust, mask, textOrientation, transform, transition, writingMode, userSelect, breakPropsOld, inlineLogicalOld, unprefixed, prefixed, scrollSnap, overscrollBehavior, flex2012, flex2009];
|
|
5491
|
-
var propertyDetectors = plugins.filter(function (p) {
|
|
5492
|
-
return p.supportedProperty;
|
|
5493
|
-
}).map(function (p) {
|
|
5494
|
-
return p.supportedProperty;
|
|
5495
|
-
});
|
|
5496
|
-
var noPrefill = plugins.filter(function (p) {
|
|
5497
|
-
return p.noPrefill;
|
|
5498
|
-
}).reduce(function (a, p) {
|
|
5499
|
-
a.push.apply(a, _toConsumableArray(p.noPrefill));
|
|
5500
|
-
return a;
|
|
5501
|
-
}, []);
|
|
5502
|
-
|
|
5503
|
-
var el;
|
|
5504
|
-
var cache = {};
|
|
5505
|
-
|
|
5506
|
-
if (isInBrowser) {
|
|
5507
|
-
el = document.createElement('p'); // We test every property on vendor prefix requirement.
|
|
5508
|
-
// Once tested, result is cached. It gives us up to 70% perf boost.
|
|
5509
|
-
// http://jsperf.com/element-style-object-access-vs-plain-object
|
|
5510
|
-
//
|
|
5511
|
-
// Prefill cache with known css properties to reduce amount of
|
|
5512
|
-
// properties we need to feature test at runtime.
|
|
5513
|
-
// http://davidwalsh.name/vendor-prefix
|
|
5514
|
-
|
|
5515
|
-
var computed = window.getComputedStyle(document.documentElement, '');
|
|
5516
|
-
|
|
5517
|
-
for (var key$1 in computed) {
|
|
5518
|
-
// eslint-disable-next-line no-restricted-globals
|
|
5519
|
-
if (!isNaN(key$1)) cache[computed[key$1]] = computed[key$1];
|
|
5520
|
-
} // Properties that cannot be correctly detected using the
|
|
5521
|
-
// cache prefill method.
|
|
5522
|
-
|
|
5523
|
-
|
|
5524
|
-
noPrefill.forEach(function (x) {
|
|
5525
|
-
return delete cache[x];
|
|
5526
|
-
});
|
|
5527
|
-
}
|
|
5528
|
-
/**
|
|
5529
|
-
* Test if a property is supported, returns supported property with vendor
|
|
5530
|
-
* prefix if required. Returns `false` if not supported.
|
|
5531
|
-
*
|
|
5532
|
-
* @param {String} prop dash separated
|
|
5533
|
-
* @param {Object} [options]
|
|
5534
|
-
* @return {String|Boolean}
|
|
5535
|
-
* @api public
|
|
5536
|
-
*/
|
|
5537
|
-
|
|
5538
|
-
|
|
5539
|
-
function supportedProperty(prop, options) {
|
|
5540
|
-
if (options === void 0) {
|
|
5541
|
-
options = {};
|
|
5542
|
-
}
|
|
5543
|
-
|
|
5544
|
-
// For server-side rendering.
|
|
5545
|
-
if (!el) return prop; // Remove cache for benchmark tests or return property from the cache.
|
|
5546
|
-
|
|
5547
|
-
if (process.env.NODE_ENV !== 'benchmark' && cache[prop] != null) {
|
|
5548
|
-
return cache[prop];
|
|
5549
|
-
} // Check if 'transition' or 'transform' natively supported in browser.
|
|
5550
|
-
|
|
5551
|
-
|
|
5552
|
-
if (prop === 'transition' || prop === 'transform') {
|
|
5553
|
-
options[prop] = prop in el.style;
|
|
5554
|
-
} // Find a plugin for current prefix property.
|
|
5555
|
-
|
|
5556
|
-
|
|
5557
|
-
for (var i = 0; i < propertyDetectors.length; i++) {
|
|
5558
|
-
cache[prop] = propertyDetectors[i](prop, el.style, options); // Break loop, if value found.
|
|
5559
|
-
|
|
5560
|
-
if (cache[prop]) break;
|
|
5561
|
-
} // Reset styles for current property.
|
|
5562
|
-
// Firefox can even throw an error for invalid properties, e.g., "0".
|
|
5563
|
-
|
|
5564
|
-
|
|
5565
|
-
try {
|
|
5566
|
-
el.style[prop] = '';
|
|
5567
|
-
} catch (err) {
|
|
5568
|
-
return false;
|
|
5569
|
-
}
|
|
5570
|
-
|
|
5571
|
-
return cache[prop];
|
|
5572
|
-
}
|
|
5573
|
-
|
|
5574
|
-
var cache$1 = {};
|
|
5575
|
-
var transitionProperties = {
|
|
5576
|
-
transition: 1,
|
|
5577
|
-
'transition-property': 1,
|
|
5578
|
-
'-webkit-transition': 1,
|
|
5579
|
-
'-webkit-transition-property': 1
|
|
5580
|
-
};
|
|
5581
|
-
var transPropsRegExp = /(^\s*[\w-]+)|, (\s*[\w-]+)(?![^()]*\))/g;
|
|
5582
|
-
var el$1;
|
|
5583
|
-
/**
|
|
5584
|
-
* Returns prefixed value transition/transform if needed.
|
|
5585
|
-
*
|
|
5586
|
-
* @param {String} match
|
|
5587
|
-
* @param {String} p1
|
|
5588
|
-
* @param {String} p2
|
|
5589
|
-
* @return {String}
|
|
5590
|
-
* @api private
|
|
5591
|
-
*/
|
|
5592
|
-
|
|
5593
|
-
function prefixTransitionCallback(match, p1, p2) {
|
|
5594
|
-
if (p1 === 'var') return 'var';
|
|
5595
|
-
if (p1 === 'all') return 'all';
|
|
5596
|
-
if (p2 === 'all') return ', all';
|
|
5597
|
-
var prefixedValue = p1 ? supportedProperty(p1) : ", " + supportedProperty(p2);
|
|
5598
|
-
if (!prefixedValue) return p1 || p2;
|
|
5599
|
-
return prefixedValue;
|
|
5600
|
-
}
|
|
5601
|
-
|
|
5602
|
-
if (isInBrowser) el$1 = document.createElement('p');
|
|
5603
|
-
/**
|
|
5604
|
-
* Returns prefixed value if needed. Returns `false` if value is not supported.
|
|
5605
|
-
*
|
|
5606
|
-
* @param {String} property
|
|
5607
|
-
* @param {String} value
|
|
5608
|
-
* @return {String|Boolean}
|
|
5609
|
-
* @api public
|
|
5610
|
-
*/
|
|
5611
|
-
|
|
5612
|
-
function supportedValue(property, value) {
|
|
5613
|
-
// For server-side rendering.
|
|
5614
|
-
var prefixedValue = value;
|
|
5615
|
-
if (!el$1 || property === 'content') return value; // It is a string or a number as a string like '1'.
|
|
5616
|
-
// We want only prefixable values here.
|
|
5617
|
-
// eslint-disable-next-line no-restricted-globals
|
|
5618
|
-
|
|
5619
|
-
if (typeof prefixedValue !== 'string' || !isNaN(parseInt(prefixedValue, 10))) {
|
|
5620
|
-
return prefixedValue;
|
|
5621
|
-
} // Create cache key for current value.
|
|
5622
|
-
|
|
5623
|
-
|
|
5624
|
-
var cacheKey = property + prefixedValue; // Remove cache for benchmark tests or return value from cache.
|
|
5625
|
-
|
|
5626
|
-
if (process.env.NODE_ENV !== 'benchmark' && cache$1[cacheKey] != null) {
|
|
5627
|
-
return cache$1[cacheKey];
|
|
5628
|
-
} // IE can even throw an error in some cases, for e.g. style.content = 'bar'.
|
|
5629
|
-
|
|
5630
|
-
|
|
5631
|
-
try {
|
|
5632
|
-
// Test value as it is.
|
|
5633
|
-
el$1.style[property] = prefixedValue;
|
|
5634
|
-
} catch (err) {
|
|
5635
|
-
// Return false if value not supported.
|
|
5636
|
-
cache$1[cacheKey] = false;
|
|
5637
|
-
return false;
|
|
5638
|
-
} // If 'transition' or 'transition-property' property.
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
if (transitionProperties[property]) {
|
|
5642
|
-
prefixedValue = prefixedValue.replace(transPropsRegExp, prefixTransitionCallback);
|
|
5643
|
-
} else if (el$1.style[property] === '') {
|
|
5644
|
-
// Value with a vendor prefix.
|
|
5645
|
-
prefixedValue = prefix.css + prefixedValue; // Hardcode test to convert "flex" to "-ms-flexbox" for IE10.
|
|
5646
|
-
|
|
5647
|
-
if (prefixedValue === '-ms-flex') el$1.style[property] = '-ms-flexbox'; // Test prefixed value.
|
|
5648
|
-
|
|
5649
|
-
el$1.style[property] = prefixedValue; // Return false if value not supported.
|
|
5650
|
-
|
|
5651
|
-
if (el$1.style[property] === '') {
|
|
5652
|
-
cache$1[cacheKey] = false;
|
|
5653
|
-
return false;
|
|
5654
|
-
}
|
|
5655
|
-
} // Reset styles for current property.
|
|
5656
|
-
|
|
5657
|
-
|
|
5658
|
-
el$1.style[property] = ''; // Write current value to cache.
|
|
5659
|
-
|
|
5660
|
-
cache$1[cacheKey] = prefixedValue;
|
|
5661
|
-
return cache$1[cacheKey];
|
|
5662
|
-
}
|
|
5663
|
-
|
|
5664
|
-
cssVendor_cjs.prefix = prefix;
|
|
5665
|
-
var supportedKeyframes_1 = cssVendor_cjs.supportedKeyframes = supportedKeyframes;
|
|
5666
|
-
var supportedProperty_1 = cssVendor_cjs.supportedProperty = supportedProperty;
|
|
5667
|
-
var supportedValue_1 = cssVendor_cjs.supportedValue = supportedValue;
|
|
5668
|
-
|
|
5669
|
-
/**
|
|
5670
|
-
* Add vendor prefix to a property name when needed.
|
|
5671
|
-
*/
|
|
5672
|
-
|
|
5673
|
-
function jssVendorPrefixer() {
|
|
5674
|
-
function onProcessRule(rule) {
|
|
5675
|
-
if (rule.type === 'keyframes') {
|
|
5676
|
-
var atRule = rule;
|
|
5677
|
-
atRule.at = supportedKeyframes_1(atRule.at);
|
|
5678
|
-
}
|
|
5679
|
-
}
|
|
5680
|
-
|
|
5681
|
-
function prefixStyle(style) {
|
|
5682
|
-
for (var prop in style) {
|
|
5683
|
-
var value = style[prop];
|
|
5684
|
-
|
|
5685
|
-
if (prop === 'fallbacks' && Array.isArray(value)) {
|
|
5686
|
-
style[prop] = value.map(prefixStyle);
|
|
5687
|
-
continue;
|
|
5688
|
-
}
|
|
5689
|
-
|
|
5690
|
-
var changeProp = false;
|
|
5691
|
-
var supportedProp = supportedProperty_1(prop);
|
|
5692
|
-
if (supportedProp && supportedProp !== prop) changeProp = true;
|
|
5693
|
-
var changeValue = false;
|
|
5694
|
-
var supportedValue$1 = supportedValue_1(supportedProp, toCssValue(value));
|
|
5695
|
-
if (supportedValue$1 && supportedValue$1 !== value) changeValue = true;
|
|
5696
|
-
|
|
5697
|
-
if (changeProp || changeValue) {
|
|
5698
|
-
if (changeProp) delete style[prop];
|
|
5699
|
-
style[supportedProp || prop] = supportedValue$1 || value;
|
|
5700
|
-
}
|
|
5701
|
-
}
|
|
5702
|
-
|
|
5703
|
-
return style;
|
|
5704
|
-
}
|
|
5705
|
-
|
|
5706
|
-
function onProcessStyle(style, rule) {
|
|
5707
|
-
if (rule.type !== 'style') return style;
|
|
5708
|
-
return prefixStyle(style);
|
|
5709
|
-
}
|
|
5710
|
-
|
|
5711
|
-
function onChangeValue(value, prop) {
|
|
5712
|
-
return supportedValue_1(prop, toCssValue(value)) || value;
|
|
5713
|
-
}
|
|
5714
|
-
|
|
5715
|
-
return {
|
|
5716
|
-
onProcessRule: onProcessRule,
|
|
5717
|
-
onProcessStyle: onProcessStyle,
|
|
5718
|
-
onChangeValue: onChangeValue
|
|
5719
|
-
};
|
|
5720
|
-
}
|
|
5721
|
-
|
|
5722
|
-
/**
|
|
5723
|
-
* Sort props by length.
|
|
5724
|
-
*/
|
|
5725
|
-
function jssPropsSort() {
|
|
5726
|
-
var sort = function sort(prop0, prop1) {
|
|
5727
|
-
if (prop0.length === prop1.length) {
|
|
5728
|
-
return prop0 > prop1 ? 1 : -1;
|
|
5729
|
-
}
|
|
5730
|
-
|
|
5731
|
-
return prop0.length - prop1.length;
|
|
5732
|
-
};
|
|
5733
|
-
|
|
5734
|
-
return {
|
|
5735
|
-
onProcessStyle: function onProcessStyle(style, rule) {
|
|
5736
|
-
if (rule.type !== 'style') return style;
|
|
5737
|
-
var newStyle = {};
|
|
5738
|
-
var props = Object.keys(style).sort(sort);
|
|
5739
|
-
|
|
5740
|
-
for (var i = 0; i < props.length; i++) {
|
|
5741
|
-
newStyle[props[i]] = style[props[i]];
|
|
5742
|
-
}
|
|
5743
|
-
|
|
5744
|
-
return newStyle;
|
|
5745
|
-
}
|
|
5746
|
-
};
|
|
5747
|
-
}
|
|
5748
|
-
|
|
5749
|
-
var create = function create(options) {
|
|
5750
|
-
if (options === void 0) {
|
|
5751
|
-
options = {};
|
|
5752
|
-
}
|
|
5753
|
-
|
|
5754
|
-
return {
|
|
5755
|
-
plugins: [functionPlugin(), observablePlugin(options.observable), templatePlugin(), jssGlobal(), jssExtend(), jssNested(), jssCompose(), camelCase(), defaultUnit(options.defaultUnit), jssExpand(), jssVendorPrefixer(), jssPropsSort()]
|
|
5756
|
-
};
|
|
5757
|
-
};
|
|
5758
|
-
|
|
5759
|
-
index.setup({
|
|
5760
|
-
...create(),
|
|
5761
|
-
createGenerateId: () => (rule) => rule.key,
|
|
5762
|
-
plugins: [...create().plugins, dist({ combineMediaQueries: true })],
|
|
5763
|
-
});
|
|
5764
|
-
|
|
5765
|
-
const hasDocument = typeof document !== 'undefined';
|
|
5766
|
-
|
|
5767
|
-
hasDocument && 'scrollBehavior' in document.documentElement.style;
|
|
5768
|
-
const win = typeof window !== 'undefined' ? window : {};
|
|
5769
|
-
win.document || { head: {} };
|
|
5770
|
-
(win.HTMLElement || class {
|
|
5771
|
-
});
|
|
5772
|
-
|
|
5773
|
-
const isThemeDark = (theme) => {
|
|
5774
|
-
return theme === 'dark';
|
|
5775
|
-
};
|
|
5776
|
-
|
|
5777
|
-
const formatObjectOutput = (value) => {
|
|
5778
|
-
return JSON.stringify(value)
|
|
5779
|
-
.replace(/"([a-zA-Z?]+)":/g, '$1:') // remove double quotes from keys
|
|
5780
|
-
.replace(/([,:{])/g, '$1 ') // add space after following: ,:{
|
|
5781
|
-
.replace(/(})/g, ' $1') // add space before following: }
|
|
5782
|
-
.replace(/^"(.+)"$/, '$1'); // remove wrapping double quotes
|
|
5783
|
-
};
|
|
5784
|
-
'value, ' +
|
|
5785
|
-
formatObjectOutput(BREAKPOINTS.reduce((prev, key) => (Object.assign(Object.assign({}, prev), { [key + (key !== 'base' ? '?' : '')]: 'value' })), {})).replace(/"/g, '');
|
|
5786
|
-
|
|
5787
|
-
const HEADING_TAGS = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6'];
|
|
5788
|
-
|
|
5789
|
-
const getComponentCss$S = (size, compact, open, theme) => {
|
|
5790
|
-
const { primaryColor, hoverColor, focusColor, contrastLowColor } = getThemedColors(theme);
|
|
5791
|
-
const border = `1px solid ${contrastLowColor}`;
|
|
5792
|
-
return getCss(Object.assign(Object.assign({ '@global': {
|
|
5793
|
-
':host': addImportantToEachRule(Object.assign({ display: 'block' }, hostHiddenStyles)),
|
|
5794
|
-
button: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', position: 'relative', justifyContent: 'space-between', margin: '2px 0', width: '100%', textDecoration: 'none', border: 0, outline: 0, gap: '24px', background: 'transparent', cursor: 'pointer', textAlign: 'left', color: primaryColor }, textSmallStyle), { fontWeight: fontWeight.semiBold }), buildResponsiveStyles(size, (s) => ({
|
|
5795
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
5796
|
-
// @ts-ignore
|
|
5797
|
-
fontSize: fontSizeText[s],
|
|
5798
|
-
padding: compact ? '4px 0' : `${s === 'medium' ? '20px' : '12px'} 0`,
|
|
5799
|
-
}))), mergeDeep({
|
|
5800
|
-
'&::before': Object.assign({ content: '""', position: 'absolute', borderRadius: borderRadiusSmall, left: '-4px', right: '-4px' }, (compact
|
|
5801
|
-
? {
|
|
5802
|
-
top: '2px',
|
|
5803
|
-
bottom: '2px',
|
|
5804
|
-
}
|
|
5805
|
-
: {
|
|
5806
|
-
top: '6px',
|
|
5807
|
-
bottom: '6px',
|
|
5808
|
-
})),
|
|
5809
|
-
}, hoverMediaQuery({
|
|
5810
|
-
'&::before': {
|
|
5811
|
-
transition: getTransition('background-color'),
|
|
5812
|
-
},
|
|
5813
|
-
'&:hover::before': {
|
|
5814
|
-
background: hoverColor,
|
|
5815
|
-
},
|
|
5816
|
-
}))), { '&:focus::before': {
|
|
5817
|
-
border: `${borderWidthBase} solid ${focusColor}`,
|
|
5818
|
-
}, '&:not(:focus-visible)::before': {
|
|
5819
|
-
border: 0,
|
|
5820
|
-
} }),
|
|
5821
|
-
} }, (!compact && {
|
|
5822
|
-
root: {
|
|
5823
|
-
borderBottom: border,
|
|
5824
|
-
},
|
|
5825
|
-
})), { heading: {
|
|
5826
|
-
margin: 0,
|
|
5827
|
-
padding: 0,
|
|
5828
|
-
}, icon: {
|
|
5829
|
-
width: fontLineHeight,
|
|
5830
|
-
height: fontLineHeight,
|
|
5831
|
-
transformOrigin: '50% 50%',
|
|
5832
|
-
transform: open ? 'rotate3d(0)' : 'rotate3d(0,0,1,90deg)',
|
|
5833
|
-
transition: getTransition('transform'),
|
|
5834
|
-
}, collapsible: Object.assign({ padding: 0, overflow: 'hidden' }, (open
|
|
5835
|
-
? {
|
|
5836
|
-
height: 'auto',
|
|
5837
|
-
paddingBottom: compact ? spacingStaticSmall : '24px',
|
|
5838
|
-
visibility: 'visible',
|
|
5839
|
-
transition: getTransition('height') + `,visibility ${transitionDuration}`,
|
|
5840
|
-
animation: `$open ${transitionDuration} ease forwards`,
|
|
5841
|
-
}
|
|
5842
|
-
: {
|
|
5843
|
-
height: 0,
|
|
5844
|
-
visibility: 'hidden',
|
|
5845
|
-
transition: getTransition('height') + `,visibility ${transitionDuration} linear ${transitionDuration}`,
|
|
5846
|
-
})),
|
|
5847
|
-
// TODO: this doesn't get shortened and results in `keyframes-open` for some unknown reason
|
|
5848
|
-
'@keyframes open': {
|
|
5849
|
-
'0%,99%': {
|
|
5850
|
-
overflow: 'hidden',
|
|
5851
|
-
},
|
|
5852
|
-
'100%': {
|
|
5853
|
-
overflow: 'visible',
|
|
5854
|
-
},
|
|
5855
|
-
} }));
|
|
5856
|
-
};
|
|
5857
|
-
|
|
5858
|
-
const TOAST_Z_INDEX = 999999;
|
|
5859
|
-
const MODAL_Z_INDEX = 99999;
|
|
5860
|
-
const POPOVER_Z_INDEX = 9999;
|
|
5861
|
-
const BANNER_Z_INDEX = 99;
|
|
5862
|
-
|
|
5863
|
-
const oneColumnWidthS = `calc((100% - ${gridSafeZoneBase} * 2 - ${gridGap} * 13) / 14)`;
|
|
5864
|
-
const oneColumnWidthXXL = `calc((min(100%, ${gridWidthMax}) - ${gridSafeZoneXXL} * 2 - ${gridGap} * 13) / 14)`;
|
|
5865
|
-
const offsetHorizontalXXL = `max(0px, (100% - ${gridWidthMax}) / 2)`;
|
|
5866
|
-
const widthMap$1 = {
|
|
5867
|
-
narrow: {
|
|
5868
|
-
padding: `0 ${gridSafeZoneBase}`,
|
|
5869
|
-
[getMediaQueryMin('s')]: {
|
|
5870
|
-
padding: `0 calc(${gridSafeZoneBase} + ${gridGap} * 3 + ${oneColumnWidthS} * 3)`,
|
|
5871
|
-
},
|
|
5872
|
-
[getMediaQueryMin('xxl')]: {
|
|
5873
|
-
padding: `0 calc(${offsetHorizontalXXL} + ${gridSafeZoneXXL} + ${gridGap} * 3 + ${oneColumnWidthXXL} * 3)`,
|
|
5874
|
-
},
|
|
5875
|
-
},
|
|
5876
|
-
basic: {
|
|
5877
|
-
padding: `0 ${gridSafeZoneBase}`,
|
|
5878
|
-
[getMediaQueryMin('s')]: {
|
|
5879
|
-
padding: `0 calc(${gridSafeZoneBase} + ${gridGap} + ${oneColumnWidthS})`,
|
|
5880
|
-
},
|
|
5881
|
-
[getMediaQueryMin('xxl')]: {
|
|
5882
|
-
padding: `0 calc(${offsetHorizontalXXL} + ${gridSafeZoneXXL} + ${gridGap} + ${oneColumnWidthXXL})`,
|
|
5883
|
-
},
|
|
5884
|
-
},
|
|
5885
|
-
extended: {
|
|
5886
|
-
padding: `0 ${gridSafeZoneBase}`,
|
|
5887
|
-
[getMediaQueryMin('xxl')]: {
|
|
5888
|
-
padding: `0 calc(${offsetHorizontalXXL} + ${gridSafeZoneXXL})`,
|
|
5889
|
-
},
|
|
5890
|
-
},
|
|
5891
|
-
};
|
|
5892
|
-
const getContentWrapperStyle = (width) => {
|
|
5893
|
-
return Object.assign({ display: 'block', margin: 0, padding: `0 ${offsetHorizontalXXL}`, width: 'auto', minWidth: 0, maxWidth: gridWidthMax }, widthMap$1[width]);
|
|
4039
|
+
const getContentWrapperStyle = (width) => {
|
|
4040
|
+
return Object.assign({ display: 'block', margin: 0, padding: `0 ${offsetHorizontalXXL}`, width: 'auto', minWidth: 0, maxWidth: gridWidthMax }, widthMap$1[width]);
|
|
5894
4041
|
};
|
|
5895
4042
|
|
|
5896
4043
|
const easeInQuad = 'cubic-bezier(0.45,0,0.55,1)';
|
|
@@ -5942,12 +4089,12 @@ const widthMap = {
|
|
|
5942
4089
|
extended: 'extended',
|
|
5943
4090
|
basic: 'basic',
|
|
5944
4091
|
};
|
|
5945
|
-
const getComponentCss$
|
|
4092
|
+
const getComponentCss$S = (width) => {
|
|
5946
4093
|
return getCss({
|
|
5947
4094
|
'@global': {
|
|
5948
4095
|
':host': Object.assign(Object.assign({
|
|
5949
4096
|
// TODO: Why is nothing set as important here?
|
|
5950
|
-
[bannerPositionTopVar]: bannerOffset, [bannerPositionBottomVar]: bannerOffset,
|
|
4097
|
+
[bannerPositionTopVar]: bannerOffset, [bannerPositionBottomVar]: bannerOffset, position: `var(${bannerPositionTypeVar},fixed)`, zIndex: `var(${bannerZIndexVar},${BANNER_Z_INDEX})`, opacity: 0, left: 0, right: 0, willChange: 'opacity,transform' }, mergeDeep(addImportantToEachRule(Object.assign(Object.assign({}, getContentWrapperStyle(widthMap[width])), hostHiddenStyles)), {
|
|
5951
4098
|
[mediaQueryBase]: {
|
|
5952
4099
|
bottom: `var(${bannerPositionBottomVar})`,
|
|
5953
4100
|
},
|
|
@@ -5975,42 +4122,25 @@ const getDirectionJssStyle = (direction) => {
|
|
|
5975
4122
|
column: {
|
|
5976
4123
|
flexFlow: 'column nowrap',
|
|
5977
4124
|
alignItems: 'stretch',
|
|
5978
|
-
marginRight: 0,
|
|
5979
|
-
marginLeft: 0,
|
|
5980
4125
|
},
|
|
5981
4126
|
row: {
|
|
5982
4127
|
flexFlow: 'row wrap',
|
|
5983
4128
|
alignItems: 'center',
|
|
5984
|
-
marginRight: `-${spacingStaticSmall}`,
|
|
5985
|
-
marginLeft: `-${spacingStaticSmall}`,
|
|
5986
|
-
},
|
|
5987
|
-
};
|
|
5988
|
-
return style[direction];
|
|
5989
|
-
};
|
|
5990
|
-
const getDirectionSlottedJssStyle = (direction) => {
|
|
5991
|
-
const style = {
|
|
5992
|
-
column: {
|
|
5993
|
-
marginRight: 0,
|
|
5994
|
-
marginLeft: 0,
|
|
5995
|
-
},
|
|
5996
|
-
row: {
|
|
5997
|
-
marginRight: spacingStaticSmall,
|
|
5998
|
-
marginLeft: spacingStaticSmall,
|
|
5999
4129
|
},
|
|
6000
4130
|
};
|
|
6001
4131
|
return style[direction];
|
|
6002
4132
|
};
|
|
6003
|
-
const getComponentCss$
|
|
4133
|
+
const getComponentCss$R = (direction) => {
|
|
6004
4134
|
return getCss({
|
|
6005
4135
|
'@global': {
|
|
6006
4136
|
':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)),
|
|
6007
|
-
div: Object.assign({ display: 'flex',
|
|
6008
|
-
'::slotted(*)': addImportantToEachRule(Object.assign({ marginTop: spacingStaticMedium }, buildResponsiveStyles(direction, getDirectionSlottedJssStyle))),
|
|
4137
|
+
div: Object.assign({ display: 'flex', gap: spacingFluidSmall }, buildResponsiveStyles(direction, getDirectionJssStyle)),
|
|
6009
4138
|
},
|
|
6010
4139
|
});
|
|
6011
4140
|
};
|
|
6012
4141
|
|
|
6013
4142
|
const fontSizeTextMap = {
|
|
4143
|
+
'xx-small': fontSizeTextXXSmall,
|
|
6014
4144
|
'x-small': fontSizeTextXSmall,
|
|
6015
4145
|
small: fontSizeTextSmall,
|
|
6016
4146
|
medium: fontSizeTextMedium,
|
|
@@ -6033,13 +4163,13 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
6033
4163
|
const { primaryColor, disabledColor, hoverColor, focusColor } = getThemedColors(theme);
|
|
6034
4164
|
const hasIcon = hasVisibleIcon(icon, iconSource);
|
|
6035
4165
|
return Object.assign({ '@global': {
|
|
6036
|
-
':host': Object.assign(Object.assign({}, addImportantToEachRule(Object.assign({ transform: 'translate3d(0,0,0)', outline: 0 }, hostHiddenStyles))), buildResponsiveStyles(stretch, (responsiveStretch) => (Object.assign({ display: responsiveStretch ? 'block' : 'inline-block' }, (!responsiveStretch && { verticalAlign: 'top' }))))),
|
|
4166
|
+
':host': Object.assign(Object.assign({}, addImportantToEachRule(Object.assign({ transform: 'translate3d(0,0,0)', outline: 0 }, hostHiddenStyles))), buildResponsiveStyles(stretch, (responsiveStretch) => (Object.assign({ display: responsiveStretch ? 'block' : 'inline-block', width: responsiveStretch ? '100%' : 'auto' }, (!responsiveStretch && { verticalAlign: 'top' }))))),
|
|
6037
4167
|
}, root: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', gap: spacingStaticXSmall, width: '100%', margin: 0, padding: 0, color: isDisabledOrLoading ? disabledColor : primaryColor, outline: 0 }, textSmallStyle), mergeDeep(buildResponsiveStyles(stretch, (stretchValue) => ({
|
|
6038
4168
|
justifyContent: stretchValue ? 'space-between' : 'flex-start',
|
|
6039
4169
|
alignItems: stretchValue ? 'center' : 'flex-start',
|
|
6040
4170
|
})), buildResponsiveStyles(size, (sizeValue) => ({
|
|
6041
4171
|
fontSize: getFontSizeText(sizeValue),
|
|
6042
|
-
})))), { '&::before': Object.assign(Object.assign(Object.assign({ content: '""', position: '
|
|
4172
|
+
})))), { '&::before': Object.assign(Object.assign(Object.assign({ content: '""', position: 'absolute', top: offsetVertical, bottom: offsetVertical }, buildResponsiveStyles(hideLabel, (hideLabelValue) => ({
|
|
6043
4173
|
right: hideLabelValue ? offsetVertical : offsetHorizontal,
|
|
6044
4174
|
left: hideLabelValue || hasIcon ? offsetVertical : offsetHorizontal,
|
|
6045
4175
|
}))), { borderRadius: borderRadiusSmall, transition: getTransition('background-color') }), (active && Object.assign(Object.assign({}, frostedGlassStyle), { backgroundColor: hoverColor }))) }), (!isDisabledOrLoading &&
|
|
@@ -6067,7 +4197,7 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
6067
4197
|
}));
|
|
6068
4198
|
};
|
|
6069
4199
|
|
|
6070
|
-
const getComponentCss$
|
|
4200
|
+
const getComponentCss$Q = (icon, iconSource, active, isLoading, isDisabledOrLoading, stretch, size, hideLabel, alignLabel, theme) => {
|
|
6071
4201
|
const hasIcon = hasVisibleIcon(icon, iconSource);
|
|
6072
4202
|
return getCss(mergeDeep(getLinkButtonPureStyles(icon, iconSource, active, isDisabledOrLoading, stretch, size, hideLabel, alignLabel, false, theme), Object.assign({ root: {
|
|
6073
4203
|
appearance: 'none',
|
|
@@ -6118,7 +4248,7 @@ const getLinkButtonStyles = (icon, iconSource, variant, hideLabel, isDisabledOrL
|
|
|
6118
4248
|
const { focusColor } = getThemedColors(theme);
|
|
6119
4249
|
const hasIcon = hasVisibleIcon(icon, iconSource) || hideLabel;
|
|
6120
4250
|
return Object.assign({ '@global': {
|
|
6121
|
-
':host':
|
|
4251
|
+
':host': Object.assign({ display: 'inline-block' }, addImportantToEachRule(Object.assign({ verticalAlign: 'top', outline: 0 }, hostHiddenStyles))),
|
|
6122
4252
|
}, root: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', alignItems: 'flex-start', justifyContent: 'center', width: '100%', minWidth: '54px', minHeight: '54px', boxSizing: 'border-box', outline: 0, textAlign: 'left', appearance: 'none', textDecoration: 'none', border: `2px solid ${borderColor}`, borderRadius: borderRadiusSmall, transform: 'translate3d(0,0,0)', // creates new stacking context (for slotted anchor + focus)
|
|
6123
4253
|
backgroundColor, color: textColor }, textSmallStyle), { transition: ['background-color', 'border-color', 'color'].map(getTransition).join() }), buildResponsiveStyles(hideLabel, (hideLabelValue) => ({
|
|
6124
4254
|
padding: hideLabelValue ? '13px' : hasIcon ? '13px 26px 13px 18px' : '13px 26px',
|
|
@@ -6165,7 +4295,7 @@ const getDisabledColors = (variant, loading, theme) => {
|
|
|
6165
4295
|
};
|
|
6166
4296
|
return colors[variant === 'tertiary' ? 'secondary' : variant];
|
|
6167
4297
|
};
|
|
6168
|
-
const getComponentCss$
|
|
4298
|
+
const getComponentCss$P = (icon, iconSource, variant, hideLabel, disabled, loading, theme) => {
|
|
6169
4299
|
const disabledOrLoading = isDisabledOrLoading(disabled, loading);
|
|
6170
4300
|
const { textColor, borderColor, backgroundColor } = getDisabledColors(variant, loading, theme);
|
|
6171
4301
|
const isPrimary = variant === 'primary';
|
|
@@ -6190,28 +4320,76 @@ const getComponentCss$O = (icon, iconSource, variant, hideLabel, disabled, loadi
|
|
|
6190
4320
|
})) })));
|
|
6191
4321
|
};
|
|
6192
4322
|
|
|
4323
|
+
const carouselTransitionDuration = 400;
|
|
6193
4324
|
const bulletActiveClass = 'bullet--active';
|
|
4325
|
+
const selectorHeading = 'h2,::slotted([slot=heading])';
|
|
4326
|
+
const selectorDescription = 'p,::slotted([slot=description])';
|
|
6194
4327
|
const mediaQueryS = getMediaQueryMin('s');
|
|
6195
|
-
const
|
|
6196
|
-
|
|
6197
|
-
|
|
4328
|
+
const mediaQueryXXL = getMediaQueryMin('xxl');
|
|
4329
|
+
// we need an explicit grid template, therefor we need to calculate the button group width
|
|
4330
|
+
const buttonSize$1 = `calc(${spacingStaticSmall} * 2 + ${fontLineHeight})`;
|
|
4331
|
+
// + 2px, compensates hover offset of button-pure
|
|
4332
|
+
const buttonGroupWidth = `calc(${buttonSize$1} * 2 + ${spacingStaticXSmall} + 2px)`;
|
|
4333
|
+
// we don't need to abstract spacing definitions since component content-wrapper is deprecated and will be removed soon
|
|
4334
|
+
const gridColumn1FrS = `calc((100% - ${gridSafeZoneBase} * 2 - ${gridGap} * 13) / 14)`;
|
|
4335
|
+
const gridColumn1FrXXL = `calc((min(100%, ${gridWidthMax}) - ${gridSafeZoneXXL} * 2 - ${gridGap} * 13) / 14)`;
|
|
4336
|
+
const spacingMap = {
|
|
4337
|
+
basic: {
|
|
4338
|
+
padding: `0 ${gridSafeZoneBase}`,
|
|
4339
|
+
[mediaQueryS]: {
|
|
4340
|
+
padding: `0 calc(${gridSafeZoneBase} + ${gridGap} + ${gridColumn1FrS})`,
|
|
4341
|
+
},
|
|
4342
|
+
[mediaQueryXXL]: {
|
|
4343
|
+
padding: `0 calc(${gridSafeZoneXXL} + ${gridGap} + ${gridColumn1FrXXL})`,
|
|
4344
|
+
},
|
|
4345
|
+
},
|
|
4346
|
+
extended: {
|
|
4347
|
+
padding: `0 ${gridSafeZoneBase}`,
|
|
4348
|
+
[mediaQueryXXL]: {
|
|
4349
|
+
padding: `0 ${gridSafeZoneXXL}`,
|
|
4350
|
+
},
|
|
4351
|
+
},
|
|
4352
|
+
};
|
|
4353
|
+
const getComponentCss$O = (width, hasPagination, alignHeader, theme) => {
|
|
4354
|
+
const { primaryColor, contrastMediumColor } = getThemedColors(theme);
|
|
4355
|
+
const isHeaderAlignCenter = alignHeader === 'center';
|
|
6198
4356
|
return getCss(Object.assign({ '@global': {
|
|
6199
|
-
':host': addImportantToEachRule(Object.assign({ display: '
|
|
6200
|
-
|
|
6201
|
-
} }, hostHiddenStyles)),
|
|
6202
|
-
|
|
6203
|
-
|
|
4357
|
+
':host': addImportantToEachRule(Object.assign({ display: 'flex', gap: spacingFluidMedium, flexDirection: 'column', maxWidth: gridWidthMax,
|
|
4358
|
+
// relevant for viewport width > 2560px
|
|
4359
|
+
paddingLeft: `calc(50% - ${gridWidthMax} / 2)`, paddingRight: `calc(50% - ${gridWidthMax} / 2)`, boxSizing: 'content-box' }, hostHiddenStyles)),
|
|
4360
|
+
[selectorHeading]: addImportantToEachRule(Object.assign(Object.assign({}, headingXLargeStyle), { maxWidth: '56.25rem', margin: 0 })),
|
|
4361
|
+
[selectorDescription]: addImportantToEachRule(Object.assign(Object.assign({}, textSmallStyle), { maxWidth: '34.375rem', margin: `${spacingFluidXSmall} 0 0` })),
|
|
4362
|
+
[`${selectorHeading},${selectorDescription}`]: addImportantToEachRule({
|
|
4363
|
+
color: primaryColor,
|
|
4364
|
+
[mediaQueryS]: isHeaderAlignCenter
|
|
4365
|
+
? {
|
|
4366
|
+
gridColumn: 2,
|
|
4367
|
+
textAlign: 'center', // relevant when text becomes multiline
|
|
4368
|
+
}
|
|
4369
|
+
: {
|
|
4370
|
+
gridColumn: '1 / 3',
|
|
4371
|
+
},
|
|
4372
|
+
}),
|
|
4373
|
+
}, header: Object.assign({ display: 'grid' }, mergeDeep(spacingMap[width], {
|
|
4374
|
+
[mediaQueryS]: Object.assign({ fontFamily, fontSize: fontSizeTextSmall, columnGap: spacingStaticMedium, gridTemplateColumns: `${buttonGroupWidth} minmax(0px, 1fr) ${buttonGroupWidth}` }, (isHeaderAlignCenter && {
|
|
4375
|
+
justifyItems: 'center', // relevant when max-width of heading or description is reached
|
|
4376
|
+
})),
|
|
4377
|
+
})), nav: {
|
|
4378
|
+
display: 'none',
|
|
4379
|
+
[mediaQueryS]: {
|
|
4380
|
+
display: 'flex',
|
|
4381
|
+
gap: spacingStaticXSmall,
|
|
4382
|
+
gridArea: '1 / 3 / 3 / auto',
|
|
4383
|
+
alignItems: 'end',
|
|
4384
|
+
},
|
|
4385
|
+
}, btn: {
|
|
4386
|
+
padding: spacingStaticSmall,
|
|
6204
4387
|
}, splide: {
|
|
6205
4388
|
overflow: 'hidden',
|
|
6206
4389
|
// visibility: 'hidden',
|
|
6207
|
-
'&__track': Object.assign(Object.assign({ cursor: 'grab' }, (
|
|
6208
|
-
|
|
6209
|
-
|
|
6210
|
-
padding: `0 calc(${gridSafeZoneBase} + 7%) 0 ${gridSafeZoneBase}`,
|
|
6211
|
-
[mediaQueryXl$1]: {
|
|
6212
|
-
padding: `0 calc(${gridSafeZoneBase} + 7%) 0 ${gridSafeZoneBase}`,
|
|
6213
|
-
},
|
|
6214
|
-
}))), { '&--draggable': {
|
|
4390
|
+
'&__track': Object.assign(Object.assign({ cursor: 'grab' }, addImportantToEachRule(Object.assign(Object.assign({}, spacingMap[width]), { [getMediaQueryMax('xs')]: {
|
|
4391
|
+
paddingRight: `calc(${gridSafeZoneBase} + ${gridGap})`, // we need to give cut off slides a bit more space on mobile views
|
|
4392
|
+
} }))), { '&--draggable': {
|
|
6215
4393
|
userSelect: 'none',
|
|
6216
4394
|
WebkitUserSelect: 'none',
|
|
6217
4395
|
WebkitTouchCallout: 'none',
|
|
@@ -6219,42 +4397,21 @@ const getComponentCss$N = (wrapContent, disablePagination, theme) => {
|
|
|
6219
4397
|
'&__list': Object.assign({ display: 'flex', height: '100%' }, getBackfaceVisibilityJssStyle()),
|
|
6220
4398
|
'&__slide': Object.assign(Object.assign({ position: 'relative', flexShrink: 0 }, getBackfaceVisibilityJssStyle()), { transform: 'translateZ(0)' }),
|
|
6221
4399
|
'&__sr': getScreenReaderOnlyJssStyle(), // appears in the DOM when sliding
|
|
6222
|
-
},
|
|
6223
|
-
|
|
6224
|
-
|
|
6225
|
-
|
|
6226
|
-
// }
|
|
6227
|
-
// .splide.is-initialized:not(.is-active) .splide__list {
|
|
6228
|
-
// display: block,
|
|
6229
|
-
// }
|
|
6230
|
-
header: {
|
|
6231
|
-
display: 'grid',
|
|
6232
|
-
gap: gridGap,
|
|
6233
|
-
padding: wrapContent ? `0 ${gridSafeZoneBase}` : null,
|
|
6234
|
-
[mediaQueryS]: {
|
|
6235
|
-
gridTemplateColumns: `minmax(0px, 1fr) ${pxToRemWithUnit(80)}`,
|
|
6236
|
-
position: 'relative',
|
|
6237
|
-
minHeight: pxToRemWithUnit(40), // actual height of prev/next buttons
|
|
6238
|
-
},
|
|
6239
|
-
}, nav: {
|
|
6240
|
-
display: 'none',
|
|
6241
|
-
[mediaQueryS]: {
|
|
6242
|
-
display: 'grid',
|
|
6243
|
-
gridAutoFlow: 'column',
|
|
6244
|
-
position: 'absolute',
|
|
6245
|
-
right: wrapContent ? gridSafeZoneBase : 0,
|
|
6246
|
-
bottom: 0,
|
|
6247
|
-
},
|
|
6248
|
-
}, btn: {
|
|
6249
|
-
padding: pxToRemWithUnit(8),
|
|
6250
|
-
} }, (disablePagination !== true && {
|
|
6251
|
-
pagination: Object.assign(Object.assign({}, buildResponsiveStyles(disablePagination, (value) => ({ display: value ? 'none' : 'grid' }))), { gridAutoColumns: pxToRemWithUnit(8), gridAutoFlow: 'column', justifyContent: 'center', gap: pxToRemWithUnit(8), height: pxToRemWithUnit(8) }),
|
|
4400
|
+
} }, (hasPagination && {
|
|
4401
|
+
pagination: Object.assign(Object.assign({}, buildResponsiveStyles(hasPagination, (hasPaginationValue) => ({
|
|
4402
|
+
display: hasPaginationValue ? 'flex' : 'none',
|
|
4403
|
+
}))), { justifyContent: 'center', gap: spacingStaticSmall }),
|
|
6252
4404
|
bullet: {
|
|
6253
|
-
borderRadius:
|
|
6254
|
-
background:
|
|
4405
|
+
borderRadius: borderRadiusSmall,
|
|
4406
|
+
background: contrastMediumColor,
|
|
4407
|
+
// set transition to have the same speed as switching slides in splide
|
|
4408
|
+
transition: `background-color ${carouselTransitionDuration}ms, width ${carouselTransitionDuration}ms`,
|
|
4409
|
+
width: '8px',
|
|
4410
|
+
height: '8px',
|
|
6255
4411
|
},
|
|
6256
4412
|
[bulletActiveClass]: {
|
|
6257
4413
|
background: primaryColor,
|
|
4414
|
+
width: '20px',
|
|
6258
4415
|
},
|
|
6259
4416
|
})));
|
|
6260
4417
|
};
|
|
@@ -6335,7 +4492,7 @@ const getInlineSVGBackgroundImage = (path) => {
|
|
|
6335
4492
|
return `url('data:image/svg+xml;charset=UTF-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">${path}</svg>')`;
|
|
6336
4493
|
};
|
|
6337
4494
|
|
|
6338
|
-
const getComponentCss$
|
|
4495
|
+
const getComponentCss$N = (hideLabel, state, isDisabled, theme) => {
|
|
6339
4496
|
const checkedIconColor = getThemedColors(theme === 'light' ? 'dark' : 'light').primaryColor.replace(/#/g, '%23');
|
|
6340
4497
|
const indeterminateIconColor = getThemedColors(theme).primaryColor.replace(/#/g, '%23');
|
|
6341
4498
|
return getCss(mergeDeep(getCheckboxRadioJssStyle(hideLabel, state, isDisabled, theme), {
|
|
@@ -6355,7 +4512,7 @@ const getComponentCss$M = (hideLabel, state, isDisabled, theme) => {
|
|
|
6355
4512
|
}));
|
|
6356
4513
|
};
|
|
6357
4514
|
|
|
6358
|
-
const getComponentCss$
|
|
4515
|
+
const getComponentCss$M = (width) => {
|
|
6359
4516
|
return getCss({
|
|
6360
4517
|
'@global': {
|
|
6361
4518
|
':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)),
|
|
@@ -6370,19 +4527,14 @@ const getThemedTypographyColor = (theme, textColor) => {
|
|
|
6370
4527
|
const { primaryColor, contrastHighColor, contrastMediumColor, contrastLowColor, successColor, errorColor, warningColor, infoColor, } = getThemedColors(theme);
|
|
6371
4528
|
const colorMap = {
|
|
6372
4529
|
primary: primaryColor,
|
|
6373
|
-
brand: primaryColor,
|
|
6374
4530
|
default: primaryColor,
|
|
6375
4531
|
'contrast-low': contrastLowColor,
|
|
6376
|
-
'neutral-contrast-low': contrastLowColor,
|
|
6377
4532
|
'contrast-medium': contrastMediumColor,
|
|
6378
|
-
'neutral-contrast-medium': contrastMediumColor,
|
|
6379
4533
|
'contrast-high': contrastHighColor,
|
|
6380
|
-
'neutral-contrast-high': contrastHighColor,
|
|
6381
4534
|
'notification-success': successColor,
|
|
6382
4535
|
'notification-warning': warningColor,
|
|
6383
4536
|
'notification-error': errorColor,
|
|
6384
4537
|
'notification-info': infoColor,
|
|
6385
|
-
'notification-neutral': infoColor,
|
|
6386
4538
|
inherit: 'currentColor',
|
|
6387
4539
|
};
|
|
6388
4540
|
return colorMap[textColor];
|
|
@@ -6417,10 +4569,11 @@ const getTypographySlottedJssStyle = () => {
|
|
|
6417
4569
|
};
|
|
6418
4570
|
|
|
6419
4571
|
const sizeMap$5 = {
|
|
4572
|
+
small: fontSizeDisplaySmall,
|
|
6420
4573
|
medium: fontSizeDisplayMedium,
|
|
6421
4574
|
large: fontSizeDisplayLarge,
|
|
6422
4575
|
};
|
|
6423
|
-
const getComponentCss$
|
|
4576
|
+
const getComponentCss$L = (size, align, color, ellipsis, theme) => {
|
|
6424
4577
|
return getCss({
|
|
6425
4578
|
'@global': {
|
|
6426
4579
|
':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)),
|
|
@@ -6434,12 +4587,12 @@ const getComponentCss$K = (size, align, color, ellipsis, theme) => {
|
|
|
6434
4587
|
});
|
|
6435
4588
|
};
|
|
6436
4589
|
|
|
6437
|
-
const getComponentCss$
|
|
4590
|
+
const getComponentCss$K = (color, orientation, theme) => {
|
|
6438
4591
|
const { contrastLowColor, contrastMediumColor, contrastHighColor } = getThemedColors(theme);
|
|
6439
4592
|
const colorMap = {
|
|
6440
|
-
'
|
|
6441
|
-
'
|
|
6442
|
-
'
|
|
4593
|
+
'contrast-low': contrastLowColor,
|
|
4594
|
+
'contrast-medium': contrastMediumColor,
|
|
4595
|
+
'contrast-high': contrastHighColor,
|
|
6443
4596
|
};
|
|
6444
4597
|
return getCss({
|
|
6445
4598
|
'@global': {
|
|
@@ -6449,7 +4602,7 @@ const getComponentCss$J = (color, orientation, theme) => {
|
|
|
6449
4602
|
});
|
|
6450
4603
|
};
|
|
6451
4604
|
|
|
6452
|
-
const getComponentCss$
|
|
4605
|
+
const getComponentCss$J = (state, labelSize, hasLabel, theme) => {
|
|
6453
4606
|
return getCss(Object.assign(Object.assign({ '@global': Object.assign({ ':host': addImportantToEachRule(Object.assign({ display: 'block' }, hostHiddenStyles)), fieldset: {
|
|
6454
4607
|
margin: 0,
|
|
6455
4608
|
padding: 0,
|
|
@@ -6473,7 +4626,7 @@ const flexItemWidths = {
|
|
|
6473
4626
|
full: 100,
|
|
6474
4627
|
auto: 'auto',
|
|
6475
4628
|
};
|
|
6476
|
-
const getComponentCss$
|
|
4629
|
+
const getComponentCss$I = (width, offset, alignSelf, grow, shrink, flex) => {
|
|
6477
4630
|
return getCss({
|
|
6478
4631
|
'@global': {
|
|
6479
4632
|
':host': addImportantToEachRule(Object.assign(Object.assign({ boxSizing: 'border-box' }, hostHiddenStyles), mergeDeep(buildResponsiveStyles(width, (widthResponsive) => ({
|
|
@@ -6491,7 +4644,7 @@ const getComponentCss$H = (width, offset, alignSelf, grow, shrink, flex) => {
|
|
|
6491
4644
|
});
|
|
6492
4645
|
};
|
|
6493
4646
|
|
|
6494
|
-
const getComponentCss$
|
|
4647
|
+
const getComponentCss$H = (inline, wrap, direction, justifyContent, alignItems, alignContent) => {
|
|
6495
4648
|
return getCss({
|
|
6496
4649
|
'@global': {
|
|
6497
4650
|
':host': addImportantToEachRule(mergeDeep(hostHiddenStyles, buildResponsiveStyles(inline, (inlineResponsive) => ({
|
|
@@ -6513,7 +4666,7 @@ const gutter$1 = `calc(${gridGap} / 2)`;
|
|
|
6513
4666
|
const gridItemWidths = [
|
|
6514
4667
|
0, 8.333333, 16.666667, 25, 33.333333, 41.666667, 50, 58.333333, 66.666667, 75, 83.333333, 91.666667, 100,
|
|
6515
4668
|
];
|
|
6516
|
-
const getComponentCss$
|
|
4669
|
+
const getComponentCss$G = (size, offset) => {
|
|
6517
4670
|
return getCss({
|
|
6518
4671
|
'@global': {
|
|
6519
4672
|
':host': addImportantToEachRule(Object.assign(Object.assign({ paddingLeft: gutter$1, paddingRight: gutter$1, boxSizing: 'border-box' }, hostHiddenStyles), mergeDeep(buildResponsiveStyles(size, (sizeResponsive) => ({
|
|
@@ -6527,7 +4680,7 @@ const getComponentCss$F = (size, offset) => {
|
|
|
6527
4680
|
};
|
|
6528
4681
|
|
|
6529
4682
|
const gutter = `calc(${gridGap} / -2)`;
|
|
6530
|
-
const getComponentCss$
|
|
4683
|
+
const getComponentCss$F = (direction, wrap) => {
|
|
6531
4684
|
return getCss({
|
|
6532
4685
|
'@global': {
|
|
6533
4686
|
':host': addImportantToEachRule(Object.assign(Object.assign({ display: 'flex', flex: 'auto', width: 'auto', marginLeft: gutter, marginRight: gutter }, hostHiddenStyles), mergeDeep(buildResponsiveStyles(direction, (flexDirection) => ({ flexDirection })), buildResponsiveStyles(wrap, (flexWrap) => ({ flexWrap }))))),
|
|
@@ -6541,9 +4694,8 @@ const sizeMap$4 = {
|
|
|
6541
4694
|
large: fontSizeHeadingLarge,
|
|
6542
4695
|
'x-large': fontSizeHeadingXLarge,
|
|
6543
4696
|
'xx-large': fontSizeHeadingXXLarge,
|
|
6544
|
-
'xxx-large': fontSizeHeadingXXXLarge,
|
|
6545
4697
|
};
|
|
6546
|
-
const getComponentCss$
|
|
4698
|
+
const getComponentCss$E = (size, align, color, ellipsis, theme) => {
|
|
6547
4699
|
return getCss({
|
|
6548
4700
|
'@global': {
|
|
6549
4701
|
':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)),
|
|
@@ -6585,6 +4737,7 @@ const getHeadlineVariantJssStyle = (variant) => {
|
|
|
6585
4737
|
}));
|
|
6586
4738
|
};
|
|
6587
4739
|
const textSizeMap = {
|
|
4740
|
+
'xx-small': fontSizeTextXXSmall,
|
|
6588
4741
|
'x-small': fontSizeTextXSmall,
|
|
6589
4742
|
small: fontSizeTextSmall,
|
|
6590
4743
|
medium: fontSizeTextMedium,
|
|
@@ -6596,7 +4749,7 @@ const getTextSizeJssStyle = (textSize) => {
|
|
|
6596
4749
|
fontSize: textSize === 'inherit' ? textSize : textSizeMap[textSize],
|
|
6597
4750
|
};
|
|
6598
4751
|
};
|
|
6599
|
-
const getComponentCss$
|
|
4752
|
+
const getComponentCss$D = (variant, align, color, ellipsis, theme) => {
|
|
6600
4753
|
return getCss({
|
|
6601
4754
|
'@global': {
|
|
6602
4755
|
':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)),
|
|
@@ -6610,64 +4763,57 @@ const getComponentCss$C = (variant, align, color, ellipsis, theme) => {
|
|
|
6610
4763
|
});
|
|
6611
4764
|
};
|
|
6612
4765
|
|
|
4766
|
+
const toFilter = (values) => `invert(${values[0]}%) sepia(${values[1]}%) saturate(${values[2]}%) hue-rotate(${values[3]}deg) brightness(${values[4]}%) contrast(${values[5]}%)`;
|
|
4767
|
+
|
|
4768
|
+
const filterLightContrastLow = toFilter([93, 11, 36, 201, 89, 102]);
|
|
4769
|
+
const filterLightContrastMedium = toFilter([65, 6, 119, 187, 90, 92]);
|
|
4770
|
+
const filterLightContrastHigh = toFilter([40, 2, 686, 187, 80, 94]);
|
|
4771
|
+
const filterDarkContrastLow = toFilter([20, 7, 421, 202, 97, 82]);
|
|
4772
|
+
const filterDarkContrastMedium = toFilter([54, 4, 229, 187, 91, 84]);
|
|
4773
|
+
const filterDarkContrastHigh = toFilter([68, 6, 108, 187, 104, 88]);
|
|
4774
|
+
|
|
4775
|
+
const filterLightNotificationSuccess = toFilter([62, 61, 551, 86, 86, 80]);
|
|
4776
|
+
const filterLightNotificationWarning = toFilter([74, 91, 343, 348, 92, 86]);
|
|
4777
|
+
const filterLightNotificationError = toFilter([25, 62, 2003, 335, 100, 97]);
|
|
4778
|
+
const filterLightNotificationInfo = toFilter([31, 32, 5493, 216, 90, 107]);
|
|
4779
|
+
const filterDarkNotificationSuccess = toFilter([59, 22, 1342, 86, 96, 88]);
|
|
4780
|
+
const filterDarkNotificationWarning = toFilter([72, 94, 303, 354, 89, 94]);
|
|
4781
|
+
const filterDarkNotificationError = toFilter([28, 34, 3133, 333, 95, 100]);
|
|
4782
|
+
const filterDarkNotificationInfo = toFilter([31, 32, 5493, 216, 90, 107]);
|
|
4783
|
+
|
|
4784
|
+
const filterLightPrimary = toFilter([3, 7, 2930, 188, 91, 103]);
|
|
4785
|
+
const filterDarkPrimary = toFilter([97, 55, 2840, 180, 114, 103]);
|
|
4786
|
+
|
|
6613
4787
|
const sizeMap$3 = {
|
|
4788
|
+
'xx-small': fontSizeTextXXSmall,
|
|
6614
4789
|
'x-small': fontSizeTextXSmall,
|
|
6615
4790
|
small: fontSizeTextSmall,
|
|
6616
4791
|
medium: fontSizeTextMedium,
|
|
6617
4792
|
large: fontSizeTextLarge,
|
|
6618
4793
|
'x-large': fontSizeTextXLarge,
|
|
6619
4794
|
};
|
|
6620
|
-
// TODO, use Tuple to reduce chunk size
|
|
6621
|
-
const filterLightPrimary = 'invert(3%) sepia(7%) saturate(2930%) hue-rotate(188deg) brightness(91%) contrast(103%)';
|
|
6622
|
-
const filterLightContrastLow = 'invert(93%) sepia(11%) saturate(36%) hue-rotate(201deg) brightness(89%) contrast(102%)';
|
|
6623
|
-
const filterLightContrastMedium = 'invert(65%) sepia(6%) saturate(119%) hue-rotate(187deg) brightness(90%) contrast(92%)';
|
|
6624
|
-
const filterLightContrastHigh = 'invert(40%) sepia(2%) saturate(686%) hue-rotate(187deg) brightness(80%) contrast(94%)';
|
|
6625
|
-
const filterLightNotificationSuccess = 'invert(62%) sepia(61%) saturate(551%) hue-rotate(86deg) brightness(86%) contrast(80%)';
|
|
6626
|
-
const filterLightNotificationWarning = 'invert(74%) sepia(91%) saturate(343%) hue-rotate(348deg) brightness(92%) contrast(86%)';
|
|
6627
|
-
const filterLightNotificationError = 'invert(25%) sepia(62%) saturate(2003%) hue-rotate(335deg) brightness(100%) contrast(97%)';
|
|
6628
|
-
const filterLightNotificationInfo = 'invert(31%) sepia(32%) saturate(5493%) hue-rotate(216deg) brightness(90%) contrast(107%)';
|
|
6629
|
-
const filterDarkPrimary = 'invert(97%) sepia(55%) saturate(2840%) hue-rotate(180deg) brightness(114%) contrast(103%)';
|
|
6630
|
-
const filterDarkContrastLow = 'invert(20%) sepia(7%) saturate(421%) hue-rotate(202deg) brightness(97%) contrast(82%)';
|
|
6631
|
-
const filterDarkContrastMedium = 'invert(54%) sepia(4%) saturate(229%) hue-rotate(187deg) brightness(91%) contrast(84%)';
|
|
6632
|
-
const filterDarkContrastHigh = 'invert(68%) sepia(6%) saturate(108%) hue-rotate(187deg) brightness(104%) contrast(88%)';
|
|
6633
|
-
const filterDarkNotificationSuccess = 'invert(59%) sepia(22%) saturate(1342%) hue-rotate(86deg) brightness(96%) contrast(88%)';
|
|
6634
|
-
const filterDarkNotificationWarning = 'invert(72%) sepia(94%) saturate(303%) hue-rotate(354deg) brightness(89%) contrast(94%)';
|
|
6635
|
-
const filterDarkNotificationError = 'invert(28%) sepia(34%) saturate(3133%) hue-rotate(333deg) brightness(95%) contrast(100%)';
|
|
6636
|
-
const filterDarkNotificationInfo = 'invert(31%) sepia(32%) saturate(5493%) hue-rotate(216deg) brightness(90%) contrast(107%)';
|
|
6637
4795
|
const filter = {
|
|
6638
4796
|
light: {
|
|
6639
4797
|
primary: filterLightPrimary,
|
|
6640
|
-
|
|
6641
|
-
default: filterLightPrimary,
|
|
6642
|
-
disabled: filterLightContrastMedium,
|
|
4798
|
+
'state-disabled': filterLightContrastMedium,
|
|
6643
4799
|
'contrast-low': filterLightContrastLow,
|
|
6644
|
-
'neutral-contrast-low': filterLightContrastLow,
|
|
6645
4800
|
'contrast-medium': filterLightContrastMedium,
|
|
6646
|
-
'neutral-contrast-medium': filterLightContrastMedium,
|
|
6647
4801
|
'contrast-high': filterLightContrastHigh,
|
|
6648
|
-
'neutral-contrast-high': filterLightContrastHigh,
|
|
6649
4802
|
'notification-success': filterLightNotificationSuccess,
|
|
6650
4803
|
'notification-warning': filterLightNotificationWarning,
|
|
6651
4804
|
'notification-error': filterLightNotificationError,
|
|
6652
4805
|
'notification-info': filterLightNotificationInfo,
|
|
6653
|
-
'notification-neutral': filterLightNotificationInfo, // deprecated
|
|
6654
4806
|
},
|
|
6655
4807
|
dark: {
|
|
6656
4808
|
primary: filterDarkPrimary,
|
|
6657
|
-
|
|
6658
|
-
default: filterDarkPrimary,
|
|
6659
|
-
disabled: filterDarkContrastMedium,
|
|
4809
|
+
'state-disabled': filterDarkContrastMedium,
|
|
6660
4810
|
'contrast-low': filterDarkContrastLow,
|
|
6661
|
-
'neutral-contrast-low': filterDarkContrastLow,
|
|
6662
4811
|
'contrast-medium': filterDarkContrastMedium,
|
|
6663
|
-
'neutral-contrast-medium': filterDarkContrastMedium,
|
|
6664
4812
|
'contrast-high': filterDarkContrastHigh,
|
|
6665
|
-
'neutral-contrast-high': filterDarkContrastHigh,
|
|
6666
4813
|
'notification-success': filterDarkNotificationSuccess,
|
|
6667
4814
|
'notification-warning': filterDarkNotificationWarning,
|
|
6668
4815
|
'notification-error': filterDarkNotificationError,
|
|
6669
4816
|
'notification-info': filterDarkNotificationInfo,
|
|
6670
|
-
'notification-neutral': filterDarkNotificationInfo, // deprecated
|
|
6671
4817
|
},
|
|
6672
4818
|
};
|
|
6673
4819
|
const forceRerenderAnimationStyle = {
|
|
@@ -6680,13 +4826,14 @@ const forceRerenderAnimationStyle = {
|
|
|
6680
4826
|
};
|
|
6681
4827
|
const keyFramesLight = 'rerender-light';
|
|
6682
4828
|
const keyFramesDark = 'rerender-dark';
|
|
6683
|
-
const getComponentCss$
|
|
4829
|
+
const getComponentCss$C = (color, size, theme) => {
|
|
6684
4830
|
const isColorInherit = color === 'inherit';
|
|
6685
4831
|
const isSizeInherit = size === 'inherit';
|
|
4832
|
+
const isDark = isThemeDark(theme);
|
|
6686
4833
|
return getCss({
|
|
6687
4834
|
'@global': Object.assign({ ':host': Object.assign({ display: 'inline-block', verticalAlign: 'top' }, addImportantToEachRule(hostHiddenStyles)), img: Object.assign(Object.assign({ display: 'block', margin: 0, padding: 0 }, (!isColorInherit && {
|
|
6688
4835
|
filter: filter[theme][color],
|
|
6689
|
-
WebkitAnimation: `${
|
|
4836
|
+
WebkitAnimation: `${isDark ? keyFramesDark : keyFramesLight} 1ms`, // needed to enforce repaint in Safari if theme is switched programmatically.
|
|
6690
4837
|
})), (isSizeInherit
|
|
6691
4838
|
? {
|
|
6692
4839
|
width: size,
|
|
@@ -6697,7 +4844,7 @@ const getComponentCss$B = (color, size, theme) => {
|
|
|
6697
4844
|
height: fontLineHeight,
|
|
6698
4845
|
font: `${sizeMap$3[size]} ${fontFamily}`,
|
|
6699
4846
|
})) }, (!isColorInherit && {
|
|
6700
|
-
[`@keyframes ${
|
|
4847
|
+
[`@keyframes ${isDark ? keyFramesDark : keyFramesLight}`]: forceRerenderAnimationStyle,
|
|
6701
4848
|
})),
|
|
6702
4849
|
});
|
|
6703
4850
|
};
|
|
@@ -6746,7 +4893,7 @@ const getNotificationContentJssStyle = () => ({
|
|
|
6746
4893
|
});
|
|
6747
4894
|
|
|
6748
4895
|
const mediaQueryMaxS = getMediaQueryMax('s');
|
|
6749
|
-
const getComponentCss$
|
|
4896
|
+
const getComponentCss$B = (state, hasAction, hasClose, theme) => {
|
|
6750
4897
|
return getCss(Object.assign({ '@global': {
|
|
6751
4898
|
':host': addImportantToEachRule(Object.assign(Object.assign({}, getNotificationRootJssStyle(state, hasAction, hasClose, theme)), hostHiddenStyles)),
|
|
6752
4899
|
h5: headingSmallStyle,
|
|
@@ -6764,18 +4911,13 @@ const getComponentCss$A = (state, hasAction, hasClose, theme) => {
|
|
|
6764
4911
|
})));
|
|
6765
4912
|
};
|
|
6766
4913
|
|
|
6767
|
-
const getComponentCss$
|
|
4914
|
+
const getComponentCss$A = (icon, iconSource, active, stretch, size, hideLabel, alignLabel, underline, hasSlottedAnchor, theme) => {
|
|
6768
4915
|
const { focusColor } = getThemedColors(theme);
|
|
6769
4916
|
const hasIcon = hasVisibleIcon(icon, iconSource);
|
|
6770
4917
|
return getCss(mergeDeep(getLinkButtonPureStyles(icon, iconSource, active, false, stretch, size, hideLabel, alignLabel, hasSlottedAnchor, theme), Object.assign(Object.assign({}, (hasSlottedAnchor && {
|
|
6771
4918
|
'@global': addImportantToEachRule({
|
|
6772
4919
|
'::slotted': {
|
|
6773
|
-
'&(a)': {
|
|
6774
|
-
outline: 0,
|
|
6775
|
-
textDecoration: underline ? 'underline' : 'none',
|
|
6776
|
-
font: 'inherit',
|
|
6777
|
-
color: 'inherit',
|
|
6778
|
-
},
|
|
4920
|
+
'&(a)': Object.assign(Object.assign({}, getResetInitialStylesForSlottedAnchor), { outline: 0, textDecoration: underline ? 'underline' : 'none', font: 'inherit', color: 'inherit' }),
|
|
6779
4921
|
// The clickable area for Safari < ~15 (<= release date: 2021-10-28) is reduced to the slotted anchor itself,
|
|
6780
4922
|
// since Safari prior to this major release does not support pseudo-elements in the slotted context
|
|
6781
4923
|
// (https://bugs.webkit.org/show_bug.cgi?id=178237)
|
|
@@ -6796,17 +4938,12 @@ const getComponentCss$z = (icon, iconSource, active, stretch, size, hideLabel, a
|
|
|
6796
4938
|
} })));
|
|
6797
4939
|
};
|
|
6798
4940
|
|
|
6799
|
-
const getComponentCss$
|
|
4941
|
+
const getComponentCss$z = (icon, iconSource, variant, hideLabel, hasSlottedAnchor, theme) => {
|
|
6800
4942
|
const { focusColor } = getThemedColors(theme);
|
|
6801
4943
|
return getCss(mergeDeep(getLinkButtonStyles(icon, iconSource, variant, hideLabel, false, hasSlottedAnchor, theme), Object.assign({}, (hasSlottedAnchor && {
|
|
6802
4944
|
'@global': addImportantToEachRule({
|
|
6803
4945
|
'::slotted': {
|
|
6804
|
-
'&(a)': {
|
|
6805
|
-
outline: 0,
|
|
6806
|
-
textDecoration: 'none',
|
|
6807
|
-
font: 'inherit',
|
|
6808
|
-
color: 'inherit',
|
|
6809
|
-
},
|
|
4946
|
+
'&(a)': Object.assign(Object.assign({}, getResetInitialStylesForSlottedAnchor), { outline: 0, textDecoration: 'none', font: 'inherit', color: 'inherit' }),
|
|
6810
4947
|
// The clickable area for Safari < ~15 (<= release date: 2021-10-28) is reduced to the slotted anchor itself,
|
|
6811
4948
|
// since Safari prior to this major release does not support pseudo-elements in the slotted context
|
|
6812
4949
|
// (https://bugs.webkit.org/show_bug.cgi?id=178237)
|
|
@@ -6827,9 +4964,7 @@ const getComponentCss$y = (icon, iconSource, variant, hideLabel, hasSlottedAncho
|
|
|
6827
4964
|
};
|
|
6828
4965
|
|
|
6829
4966
|
const fontWeightMap = {
|
|
6830
|
-
thin: fontWeightRegular,
|
|
6831
4967
|
regular: fontWeightRegular,
|
|
6832
|
-
semibold: fontWeightSemiBold$1,
|
|
6833
4968
|
'semi-bold': fontWeightSemiBold$1,
|
|
6834
4969
|
bold: fontWeightBold,
|
|
6835
4970
|
};
|
|
@@ -6845,44 +4980,26 @@ const aspectRatioPaddingTop = {
|
|
|
6845
4980
|
'9:16': '177.75%',
|
|
6846
4981
|
};
|
|
6847
4982
|
const getGradientBackground = (isCompact, isTopAligned) => {
|
|
6848
|
-
|
|
6849
|
-
'rgba(31,31,31,0.9) 20%,' +
|
|
6850
|
-
'rgba(31,31,31,0.852589) 26.67%,' +
|
|
6851
|
-
'rgba(32,32,32,0.768225) 33.33%,' +
|
|
6852
|
-
'rgba(33,33,33,0.668116) 40%,' +
|
|
6853
|
-
'rgba(34,34,34,0.557309) 46.67%,' +
|
|
6854
|
-
'rgba(35,35,35,0.442691) 53.33%,' +
|
|
6855
|
-
'rgba(36,36,36,0.331884) 60%,' +
|
|
6856
|
-
'rgba(37,37,37,0.231775) 66.67%,' +
|
|
6857
|
-
'rgba(38,38,38,0.147411) 73.33%,' +
|
|
6858
|
-
'rgba(39,39,39,0.0816599) 80%,' +
|
|
6859
|
-
'rgba(39,39,39,0.03551) 86.67%,' +
|
|
6860
|
-
'rgba(39,39,39,0.0086472) 93.33%,' +
|
|
6861
|
-
'rgba(39,39,39,0)';
|
|
6862
|
-
return isCompact && isTopAligned
|
|
6863
|
-
? `linear-gradient(${gradient} 100%);`
|
|
6864
|
-
: `linear-gradient(to top, ${gradient} 100%);`;
|
|
4983
|
+
return isCompact && isTopAligned ? gradientToBottomStyle : gradientToTopStyle;
|
|
6865
4984
|
};
|
|
6866
4985
|
const sizeMap$2 = {
|
|
6867
|
-
inherit: {
|
|
6868
|
-
|
|
6869
|
-
},
|
|
6870
|
-
default: { fontSize: '1.25rem' },
|
|
4986
|
+
inherit: { fontSize: 'inherit' },
|
|
4987
|
+
default: { fontSize: fontSizeTextMedium },
|
|
6871
4988
|
};
|
|
6872
|
-
const getComponentCss$
|
|
4989
|
+
const getComponentCss$y = (aspectRatio, size, weight, align, compact, hasGradient) => {
|
|
6873
4990
|
const isTopAligned = align === 'top';
|
|
6874
|
-
const paddingSizeXS = pxToRemWithUnit(24);
|
|
6875
|
-
const gradientPadding = pxToRemWithUnit(72);
|
|
6876
4991
|
return getCss({
|
|
6877
|
-
'@global': Object.assign(Object.assign({ ':host': Object.assign({ display: 'block' }, addImportantToEachRule(
|
|
4992
|
+
'@global': Object.assign(Object.assign({ ':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)) }, addImportantToEachRule({
|
|
6878
4993
|
'::slotted(picture),::slotted(img)': Object.assign({ transition: getTransition('transform') }, getBackfaceVisibilityJssStyle()),
|
|
6879
|
-
'::slotted(picture)': Object.assign({ position: 'absolute' }, getInsetJssStyle()),
|
|
4994
|
+
'::slotted(picture)': Object.assign({ position: 'absolute' }, getInsetJssStyle(0)),
|
|
6880
4995
|
'::slotted(img)': {
|
|
6881
4996
|
height: '100%',
|
|
6882
4997
|
width: '100%',
|
|
6883
4998
|
objectFit: 'cover',
|
|
6884
4999
|
},
|
|
6885
|
-
})), { p: Object.assign(Object.assign(
|
|
5000
|
+
})), { p: Object.assign(Object.assign({ color: getThemedTypographyColor('dark', 'primary'), maxWidth: pxToRemWithUnit(550), margin: 0 }, textLargeStyle), mergeDeep(buildResponsiveStyles(size, (s) => sizeMap$2[s]), buildResponsiveStyles(weight, (w) => ({
|
|
5001
|
+
fontWeight: getFontWeight(w === 'semibold' ? 'semi-bold' : w),
|
|
5002
|
+
})))) }),
|
|
6886
5003
|
root: Object.assign(Object.assign({ height: 0, position: 'relative', transform: 'translate3d(0,0,0)' }, hoverMediaQuery({
|
|
6887
5004
|
'&:hover': {
|
|
6888
5005
|
'& ::slotted(picture),::slotted(img)': addImportantToEachRule({
|
|
@@ -6892,24 +5009,20 @@ const getComponentCss$x = (aspectRatio, size, weight, align, compact, hasGradien
|
|
|
6892
5009
|
})), buildResponsiveStyles(aspectRatio, (ratio) => ({
|
|
6893
5010
|
paddingTop: aspectRatioPaddingTop[ratio],
|
|
6894
5011
|
}))),
|
|
6895
|
-
'image-container': Object.assign(
|
|
6896
|
-
content: Object.assign(Object.assign(Object.assign({ position: 'absolute' }, (isTopAligned ? { top: 0 } : { bottom: 0 })), { left: 0, right: 0, display: 'grid', justifyItems: 'start', padding: align === 'bottom'
|
|
6897
|
-
? `${
|
|
6898
|
-
: `${
|
|
6899
|
-
|
|
6900
|
-
|
|
6901
|
-
|
|
6902
|
-
|
|
6903
|
-
})), buildResponsiveStyles(compact, (isCompact) => isCompact
|
|
6904
|
-
? Object.assign({ alignItems: 'center', gridTemplateColumns: `auto ${pxToRemWithUnit(24)}`, gridTemplateRows: 'auto' }, (isTopAligned ? { top: 0 } : { bottom: 0 })) : { gridTemplateRows: 'auto auto', gridTemplateColumns: 'auto' }))),
|
|
5012
|
+
'image-container': Object.assign({ position: 'absolute', overflow: 'hidden', borderRadius: borderRadiusMedium }, getInsetJssStyle(0)),
|
|
5013
|
+
content: Object.assign(Object.assign(Object.assign(Object.assign({ position: 'absolute' }, (isTopAligned ? { top: 0 } : { bottom: 0 })), { left: 0, right: 0, display: 'grid', justifyItems: 'start', borderRadius: borderRadiusMedium, padding: align === 'bottom'
|
|
5014
|
+
? `${spacingFluidLarge} ${spacingFluidMedium} ${spacingFluidMedium}`
|
|
5015
|
+
: `${spacingFluidMedium} ${spacingFluidMedium} ${spacingFluidLarge}`, gap: spacingStaticMedium }), mergeDeep(hasGradient &&
|
|
5016
|
+
buildResponsiveStyles(compact, (isCompact) => getGradientBackground(isCompact, isTopAligned)), buildResponsiveStyles(compact, (isCompact) => isCompact
|
|
5017
|
+
? Object.assign({ alignItems: 'center', gridTemplateColumns: 'auto 24px', gridTemplateRows: 'auto' }, (isTopAligned ? { top: 0 } : { bottom: 0 })) : { gridTemplateRows: 'auto auto', gridTemplateColumns: 'auto' }))), { '@media (forced-colors: active)': {
|
|
5018
|
+
background: 'rgba(0,0,0,0.7)',
|
|
5019
|
+
} }),
|
|
6905
5020
|
'link-pure': buildResponsiveStyles(compact, (isCompact) => ({
|
|
6906
5021
|
display: isCompact ? 'inline-block' : 'none',
|
|
6907
5022
|
})),
|
|
6908
|
-
link: Object.assign({ minHeight: '
|
|
6909
|
-
//
|
|
6910
|
-
|
|
6911
|
-
'&::after': Object.assign({ content: '""', position: 'fixed' }, getInsetJssStyle()),
|
|
6912
|
-
},
|
|
5023
|
+
link: Object.assign({ minHeight: '54px' }, buildResponsiveStyles(compact, (isCompact) => ({ display: isCompact ? 'none' : 'inline-block' }))),
|
|
5024
|
+
// is used for expanded click-area only
|
|
5025
|
+
'link-overlay': Object.assign(Object.assign({ position: 'fixed' }, getInsetJssStyle(0)), { outline: 0 }),
|
|
6913
5026
|
});
|
|
6914
5027
|
};
|
|
6915
5028
|
|
|
@@ -6923,7 +5036,7 @@ const baseSizes = {
|
|
|
6923
5036
|
height: '72px',
|
|
6924
5037
|
},
|
|
6925
5038
|
};
|
|
6926
|
-
const getComponentCss$
|
|
5039
|
+
const getComponentCss$x = (size) => {
|
|
6927
5040
|
return getCss({
|
|
6928
5041
|
'@global': {
|
|
6929
5042
|
':host': Object.assign({ position: 'relative', display: 'inline-flex', verticalAlign: 'top' }, addImportantToEachRule(Object.assign({ outline: 0 }, hostHiddenStyles))),
|
|
@@ -6961,7 +5074,7 @@ const getFullscreenJssStyles = (fullscreen) => {
|
|
|
6961
5074
|
minWidth: pxToRemWithUnit(275.2),
|
|
6962
5075
|
maxWidth: pxToRemWithUnit(1536),
|
|
6963
5076
|
minHeight: 'auto',
|
|
6964
|
-
margin: `
|
|
5077
|
+
margin: `clamp(16px, 7vh, 192px) ${gridSafeZoneBase}`,
|
|
6965
5078
|
borderRadius: borderRadiusMedium,
|
|
6966
5079
|
};
|
|
6967
5080
|
};
|
|
@@ -6977,7 +5090,7 @@ const isFullscreenForXl = (fullscreen) => {
|
|
|
6977
5090
|
return BREAKPOINTS.indexOf(lastTrueBreakpoint) > BREAKPOINTS.indexOf(lastFalseBreakpoint);
|
|
6978
5091
|
}
|
|
6979
5092
|
};
|
|
6980
|
-
const getSlottedJssStyle = (marginValue, hasHeader,
|
|
5093
|
+
const getSlottedJssStyle = (marginValue, hasHeader, hasDismissButton) => {
|
|
6981
5094
|
const marginPx = `${-marginValue}px`;
|
|
6982
5095
|
const marginRem = pxToRemWithUnit(-marginValue);
|
|
6983
5096
|
return Object.assign(Object.assign({ [`&(.${stretchToFullModalWidthClassName})`]: {
|
|
@@ -6985,13 +5098,13 @@ const getSlottedJssStyle = (marginValue, hasHeader, disableCloseButton) => {
|
|
|
6985
5098
|
margin: `0 ${marginPx}`,
|
|
6986
5099
|
} }, (!hasHeader && {
|
|
6987
5100
|
[`&(.${stretchToFullModalWidthClassName}:first-child)`]: {
|
|
6988
|
-
marginTop:
|
|
5101
|
+
marginTop: hasDismissButton ? marginRem : marginPx,
|
|
6989
5102
|
},
|
|
6990
5103
|
})), { [`&(.${stretchToFullModalWidthClassName}:last-child)`]: {
|
|
6991
5104
|
marginBottom: marginPx,
|
|
6992
5105
|
} });
|
|
6993
5106
|
};
|
|
6994
|
-
const getComponentCss$
|
|
5107
|
+
const getComponentCss$w = (open, fullscreen, hasDismissButton, hasHeader) => {
|
|
6995
5108
|
const isFullscreenForXlAndXxl = isFullscreenForXl(fullscreen);
|
|
6996
5109
|
return getCss(Object.assign(Object.assign({ '@global': {
|
|
6997
5110
|
':host': Object.assign(Object.assign({}, addImportantToEachRule(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ position: 'fixed' }, getInsetJssStyle()), { zIndex: MODAL_Z_INDEX, display: 'flex', alignItems: 'center', justifyContent: 'center', flexWrap: 'wrap' }), (open
|
|
@@ -7004,8 +5117,8 @@ const getComponentCss$v = (open, fullscreen, disableCloseButton, hasHeader) => {
|
|
|
7004
5117
|
visibility: 'hidden',
|
|
7005
5118
|
})), hostHiddenStyles), {
|
|
7006
5119
|
// workaround via pseudo element to fix stacking (black) background in safari
|
|
7007
|
-
'&::before': Object.assign(Object.assign(Object.assign({ content: '""', position: 'fixed' }, getInsetJssStyle()), { background: themeDarkBackgroundShading }), frostedGlassStyle) }))), { overflowY: 'auto' }),
|
|
7008
|
-
'::slotted': addImportantToEachRule(Object.assign({}, mergeDeep(getSlottedJssStyle(32, hasHeader,
|
|
5120
|
+
'&::before': Object.assign(Object.assign(Object.assign(Object.assign({ content: '""', position: 'fixed' }, getInsetJssStyle()), { background: themeDarkBackgroundShading }), frostedGlassStyle), { pointerEvents: 'none' }) }))), { overflowY: 'auto' }),
|
|
5121
|
+
'::slotted': addImportantToEachRule(Object.assign({}, mergeDeep(getSlottedJssStyle(32, hasHeader, hasDismissButton), buildResponsiveStyles(fullscreen, (fullscreenValue) => ({
|
|
7009
5122
|
[`&(.${stretchToFullModalWidthClassName}`]: {
|
|
7010
5123
|
'&:first-child)': {
|
|
7011
5124
|
borderRadius: fullscreenValue ? 0 : '8px 8px 0 0',
|
|
@@ -7021,10 +5134,10 @@ const getComponentCss$v = (open, fullscreen, disableCloseButton, hasHeader) => {
|
|
|
7021
5134
|
boxSizing: 'border-box',
|
|
7022
5135
|
transition: `transform .6s ${transitionTimingFunction}`,
|
|
7023
5136
|
transform: open ? 'scale3d(1,1,1)' : 'scale3d(.9,.9,1)',
|
|
7024
|
-
padding:
|
|
7025
|
-
backgroundColor,
|
|
5137
|
+
padding: hasDismissButton ? `${pxToRemWithUnit(32)} 32px 32px 32px` : '32px',
|
|
5138
|
+
background: backgroundColor,
|
|
7026
5139
|
outline: 0,
|
|
7027
|
-
'&:focus::before': Object.assign({ content: '""', position: 'fixed', border: `${borderWidthBase} solid
|
|
5140
|
+
'&:focus::before': Object.assign({ content: '""', position: 'fixed', border: `${borderWidthBase} solid`, pointerEvents: 'none' }, buildResponsiveStyles(fullscreen, (fullscreenValue) => (Object.assign({ borderRadius: fullscreenValue ? 0 : '12px', borderColor: fullscreenValue ? lightThemePrimaryColor : darkThemePrimaryColor }, getInsetJssStyle(fullscreenValue ? 0 : -4))))),
|
|
7028
5141
|
'&:not(:focus-visible)::before': {
|
|
7029
5142
|
border: 0,
|
|
7030
5143
|
},
|
|
@@ -7035,18 +5148,39 @@ const getComponentCss$v = (open, fullscreen, disableCloseButton, hasHeader) => {
|
|
|
7035
5148
|
header: {
|
|
7036
5149
|
padding: '0 0 8px',
|
|
7037
5150
|
},
|
|
7038
|
-
})),
|
|
7039
|
-
|
|
7040
|
-
top: '8px',
|
|
7041
|
-
right: '8px',
|
|
7042
|
-
border: `2px solid ${backgroundColor}`,
|
|
7043
|
-
borderRadius: '4px',
|
|
7044
|
-
backgroundColor,
|
|
5151
|
+
})), (hasDismissButton && {
|
|
5152
|
+
dismiss: Object.assign({ position: 'absolute', top: '8px', right: '8px', border: `2px solid ${backgroundColor}`, borderRadius: '4px', background: backgroundColor }, hoverMediaQuery({
|
|
7045
5153
|
'&:hover': {
|
|
7046
|
-
|
|
5154
|
+
background: 'transparent',
|
|
7047
5155
|
borderColor: 'transparent',
|
|
7048
5156
|
},
|
|
7049
|
-
}
|
|
5157
|
+
})),
|
|
5158
|
+
})));
|
|
5159
|
+
};
|
|
5160
|
+
|
|
5161
|
+
const colorToFilterMap = {
|
|
5162
|
+
light: {
|
|
5163
|
+
primary: filterLightPrimary,
|
|
5164
|
+
'contrast-low': filterLightContrastLow,
|
|
5165
|
+
'contrast-medium': filterLightContrastMedium,
|
|
5166
|
+
'contrast-high': filterLightContrastHigh,
|
|
5167
|
+
},
|
|
5168
|
+
dark: {
|
|
5169
|
+
primary: filterDarkPrimary,
|
|
5170
|
+
'contrast-low': filterDarkContrastLow,
|
|
5171
|
+
'contrast-medium': filterDarkContrastMedium,
|
|
5172
|
+
'contrast-high': filterDarkContrastHigh,
|
|
5173
|
+
},
|
|
5174
|
+
};
|
|
5175
|
+
const getComponentCss$v = (size, color, theme) => {
|
|
5176
|
+
const isSizeInherit = size === 'inherit';
|
|
5177
|
+
const isColorInherit = color === 'inherit';
|
|
5178
|
+
return getCss({
|
|
5179
|
+
'@global': {
|
|
5180
|
+
':host': Object.assign({ display: 'block' }, addImportantToEachRule(hostHiddenStyles)),
|
|
5181
|
+
img: Object.assign(Object.assign({ display: 'block', pointerEvents: 'none' }, (!isColorInherit && { filter: colorToFilterMap[theme][color] })), (isSizeInherit && { height: size })),
|
|
5182
|
+
},
|
|
5183
|
+
});
|
|
7050
5184
|
};
|
|
7051
5185
|
|
|
7052
5186
|
const mediaQueryMinS = getMediaQueryMin('s');
|
|
@@ -7242,27 +5376,34 @@ const getComponentCss$s = (hideLabel, state, isDisabled, theme) => {
|
|
|
7242
5376
|
|
|
7243
5377
|
const gradientColorMap = {
|
|
7244
5378
|
light: {
|
|
7245
|
-
|
|
7246
|
-
surface: '238,239,242',
|
|
5379
|
+
'background-base': '255,255,255',
|
|
5380
|
+
'background-surface': '238,239,242',
|
|
7247
5381
|
},
|
|
7248
5382
|
dark: {
|
|
7249
|
-
|
|
7250
|
-
surface: '33,34,37',
|
|
5383
|
+
'background-base': '14,14,18',
|
|
5384
|
+
'background-surface': '33,34,37',
|
|
7251
5385
|
},
|
|
7252
5386
|
};
|
|
7253
5387
|
const getGradient = (theme, gradientColorTheme) => {
|
|
7254
5388
|
const gradientColor = gradientColorMap[theme][gradientColorTheme];
|
|
7255
|
-
return (`rgba(${gradientColor},1)
|
|
7256
|
-
`rgba(${gradientColor},0.
|
|
7257
|
-
`rgba(${gradientColor},0.
|
|
7258
|
-
`rgba(${gradientColor},0.331884) 60%,` +
|
|
7259
|
-
`rgba(${gradientColor},0.0816599) 80%,` +
|
|
5389
|
+
return (`rgba(${gradientColor},1) 20%,` +
|
|
5390
|
+
`rgba(${gradientColor},0.6) 48%,` +
|
|
5391
|
+
`rgba(${gradientColor},0.3) 68%,` +
|
|
7260
5392
|
`rgba(${gradientColor},0)`);
|
|
7261
5393
|
};
|
|
7262
|
-
const getComponentCss$r = (
|
|
7263
|
-
const { backgroundColor, backgroundSurfaceColor, focusColor } = getThemedColors(
|
|
7264
|
-
const { hoverColor } = getThemedColors(theme);
|
|
5394
|
+
const getComponentCss$r = (gradientColor, isNextHidden, isPrevHidden, scrollIndicatorPosition, theme) => {
|
|
5395
|
+
const { backgroundColor, backgroundSurfaceColor, focusColor, hoverColor } = getThemedColors(theme);
|
|
7265
5396
|
const isDarkTheme = isThemeDark(theme);
|
|
5397
|
+
const backgroundColorMap = {
|
|
5398
|
+
dark: {
|
|
5399
|
+
'background-base': backgroundSurfaceColor,
|
|
5400
|
+
'background-surface': backgroundColor,
|
|
5401
|
+
},
|
|
5402
|
+
light: {
|
|
5403
|
+
'background-base': backgroundColor,
|
|
5404
|
+
'background-surface': backgroundSurfaceColor,
|
|
5405
|
+
},
|
|
5406
|
+
};
|
|
7266
5407
|
const actionPrevNextStyles = {
|
|
7267
5408
|
position: 'relative',
|
|
7268
5409
|
padding: '4px 0',
|
|
@@ -7273,19 +5414,17 @@ const getComponentCss$r = (gradientColorTheme, isNextHidden, isPrevHidden, scrol
|
|
|
7273
5414
|
return getCss({
|
|
7274
5415
|
'@global': {
|
|
7275
5416
|
':host': addImportantToEachRule(Object.assign({ display: 'block', height: 'inherit' }, hostHiddenStyles)),
|
|
7276
|
-
button: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', pointerEvents: 'auto', alignItems: 'center', justifyContent: 'center' }, textSmallStyle), { height: `calc(${fontLineHeight} + 4px)`, width: `calc(${fontLineHeight} + 4px)`, border: 0, outline: 0, cursor: 'pointer', background:
|
|
5417
|
+
button: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', pointerEvents: 'auto', alignItems: 'center', justifyContent: 'center' }, textSmallStyle), { height: `calc(${fontLineHeight} + 4px)`, width: `calc(${fontLineHeight} + 4px)`, border: 0, outline: 0, cursor: 'pointer', background: backgroundColorMap[theme][gradientColor], borderRadius: borderRadiusSmall }), frostedGlassStyle), { visibility: 'hidden' }), (!isDarkTheme && dropShadowLowStyle)), hoverMediaQuery({
|
|
7277
5418
|
transition: getTransition('background-color'),
|
|
7278
|
-
'&:hover': Object.assign({ background: hoverColor },
|
|
7279
|
-
'& > .icon': {
|
|
7280
|
-
filter: 'invert(97%) sepia(55%) saturate(2840%) hue-rotate(180deg) brightness(114%) contrast(103%)', // TODO: this is not shared from icon?
|
|
7281
|
-
},
|
|
7282
|
-
})),
|
|
5419
|
+
'&:hover': Object.assign(Object.assign({}, frostedGlassStyle), { background: hoverColor }),
|
|
7283
5420
|
})),
|
|
7284
5421
|
},
|
|
7285
|
-
root:
|
|
7286
|
-
|
|
7287
|
-
gridTemplateColumns:
|
|
7288
|
-
|
|
5422
|
+
root: {
|
|
5423
|
+
display: 'grid',
|
|
5424
|
+
gridTemplateColumns: `calc(${fontLineHeight} + 24px) minmax(0, 1fr) calc(${fontLineHeight} + 24px)`,
|
|
5425
|
+
margin: '0 -4px',
|
|
5426
|
+
height: 'inherit',
|
|
5427
|
+
},
|
|
7289
5428
|
'scroll-area': {
|
|
7290
5429
|
gridArea: '1 / 1 / 1 / -1',
|
|
7291
5430
|
padding: '4px',
|
|
@@ -7326,10 +5465,10 @@ const getComponentCss$r = (gradientColorTheme, isNextHidden, isPrevHidden, scrol
|
|
|
7326
5465
|
right: 0,
|
|
7327
5466
|
},
|
|
7328
5467
|
},
|
|
7329
|
-
'action-prev': Object.assign(Object.assign({}, actionPrevNextStyles), { marginLeft: '-1px', gridArea: '1 / 1 / 1 / 1', justifyContent: 'flex-start', background: `linear-gradient(to right, ${getGradient(theme,
|
|
5468
|
+
'action-prev': Object.assign(Object.assign({}, actionPrevNextStyles), { marginLeft: '-1px', gridArea: '1 / 1 / 1 / 1', justifyContent: 'flex-start', background: `linear-gradient(to right, ${getGradient(theme, gradientColor)} 100%)`, visibility: isPrevHidden ? 'hidden' : 'visible', '& button': Object.assign({ marginLeft: '8px' }, hoverMediaQuery({
|
|
7330
5469
|
visibility: isPrevHidden ? 'hidden' : 'visible',
|
|
7331
5470
|
})) }),
|
|
7332
|
-
'action-next': Object.assign(Object.assign({}, actionPrevNextStyles), { marginRight: '-1px', gridArea: '1 / 3 / 1 / 3', justifyContent: 'flex-end', background: `linear-gradient(to left, ${getGradient(theme,
|
|
5471
|
+
'action-next': Object.assign(Object.assign({}, actionPrevNextStyles), { marginRight: '-1px', gridArea: '1 / 3 / 1 / 3', justifyContent: 'flex-end', background: `linear-gradient(to left, ${getGradient(theme, gradientColor)} 100%)`, visibility: isNextHidden ? 'hidden' : 'visible', '& button': Object.assign({ marginRight: '8px' }, hoverMediaQuery({
|
|
7333
5472
|
visibility: isNextHidden ? 'hidden' : 'visible',
|
|
7334
5473
|
})) }),
|
|
7335
5474
|
});
|
|
@@ -7392,7 +5531,9 @@ const getComponentCss$p = (maxWidth) => {
|
|
|
7392
5531
|
const getBaseChildStyles = (child, state, theme, additionalDefaultJssStyle) => {
|
|
7393
5532
|
const { primaryColor, contrastLowColor, contrastMediumColor, disabledColor } = getThemedColors(theme);
|
|
7394
5533
|
const { formStateColor, formStateHoverColor } = getThemedFormStateColors(theme, state);
|
|
7395
|
-
return Object.assign(Object.assign(Object.assign({ [`::slotted(${child})`]: Object.assign({ display: 'block', width: '100%', height:
|
|
5534
|
+
return Object.assign(Object.assign(Object.assign({ [`::slotted(${child})`]: Object.assign({ display: 'block', width: '100%', height: child !== 'textarea'
|
|
5535
|
+
? `calc(${fontLineHeight} + 10px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2)` // we need 10px additionally so input height becomes 54px
|
|
5536
|
+
: 'auto', margin: 0, outline: 0, WebkitAppearance: 'none', appearance: 'none', boxSizing: 'border-box', border: `${borderWidthBase} solid ${formStateColor || contrastMediumColor}`, borderRadius: borderRadiusSmall, background: 'transparent', font: textSmallStyle.font.replace('ex', 'ex + 6px'), textIndent: 0, color: primaryColor, transition: ['color', 'border-color', 'background-color'].map(getTransition).join() }, additionalDefaultJssStyle) }, hoverMediaQuery({
|
|
7396
5537
|
// with the media query the selector has higher priority and overrides disabled styles
|
|
7397
5538
|
[`::slotted(${child}:not(:disabled):not(:focus):not([readonly]):hover)`]: {
|
|
7398
5539
|
borderColor: formStateHoverColor || primaryColor,
|
|
@@ -7534,6 +5675,7 @@ const getSVGPath = (stepCount, numberedCircleColors, isStateCurrent) => {
|
|
|
7534
5675
|
const svgCirclePath = `<circle fill="${isStateCurrent ? primaryColor : 'none'}"${isStateCurrent ? '' : ` stroke="${fillColor}"`} stroke-width="1px" cx="12" cy="12" r="9"/>`;
|
|
7535
5676
|
// Full SVG is provided by design (./numbers_raw.svg), created with illustrator and optimized with ImageOptim.
|
|
7536
5677
|
// The optimized file can be found in ./numbers_optim.svg.
|
|
5678
|
+
// TODO: could certainly be optimized size wise by exporting icons larger and having less decimals
|
|
7537
5679
|
const svgNumberedCirclePaths = [
|
|
7538
5680
|
`${svgCirclePath}<path fill="${fillColor}" d="m12.33 8.67-2.43.91v-.94l2.6-1.03h.85v8.78h-1.02z"/>`,
|
|
7539
5681
|
`${svgCirclePath}<path fill="${fillColor}" d="m9.46 15.58c0-1.35.73-2.07 1.7-2.72l.95-.63c.78-.52 1.57-1.05 1.57-2.24 0-1.12-.62-1.58-1.7-1.58s-1.68.48-1.78 1.97h-.96c.06-1.82.78-2.91 2.74-2.91s2.72.92 2.72 2.52-.92 2.23-1.79 2.8l-.95.63c-1.11.75-1.52 1.18-1.52 2.01v.16h4.17v.81h-5.15v-.81z"/>`,
|
|
@@ -7617,7 +5759,7 @@ const getComponentCss$j = (alignLabel, hideLabel, stretch, checked, disabled, lo
|
|
|
7617
5759
|
const { buttonBorderColor, buttonBorderColorHover, buttonBackgroundColor, buttonBackgroundColorHover, toggleBackgroundColor, toggleBackgroundColorHover, textColor, } = getColors$1(checked, disabled, loading, theme);
|
|
7618
5760
|
const { focusColor } = getThemedColors(theme);
|
|
7619
5761
|
return getCss(Object.assign(Object.assign({ '@global': {
|
|
7620
|
-
':host': addImportantToEachRule(Object.assign(Object.assign({ outline: 0 }, hostHiddenStyles), buildResponsiveStyles(stretch, (stretchValue) => (Object.assign({ display: stretchValue ? 'block' : 'inline-block' }, (!stretchValue && { verticalAlign: 'top' })))))),
|
|
5762
|
+
':host': addImportantToEachRule(Object.assign(Object.assign({ outline: 0 }, hostHiddenStyles), buildResponsiveStyles(stretch, (stretchValue) => (Object.assign({ display: stretchValue ? 'block' : 'inline-block', width: stretchValue ? '100%' : 'auto' }, (!stretchValue && { verticalAlign: 'top' })))))),
|
|
7621
5763
|
}, root: Object.assign(Object.assign(Object.assign({ display: 'flex', alignItems: 'flex-start', gap: spacingStaticSmall, width: '100%', padding: 0, outline: 0, border: 0, textAlign: 'left', background: 'transparent', appearance: 'none', cursor: isDisabledOrLoading(disabled, loading) ? 'auto' : 'pointer' }, buildResponsiveStyles(stretch, (stretchValue) => ({
|
|
7622
5764
|
justifyContent: stretchValue ? 'space-between' : 'flex-start',
|
|
7623
5765
|
}))), (!isDisabledOrLoading(disabled, loading) &&
|
|
@@ -7797,38 +5939,14 @@ const transformSelector = (selector) => ['a', 'button'].map((tag) => selector.re
|
|
|
7797
5939
|
const getComponentCss$b = (size, weight, theme) => {
|
|
7798
5940
|
const { primaryColor, hoverColor, focusColor } = getThemedColors(theme);
|
|
7799
5941
|
return getCss({
|
|
7800
|
-
'@global': Object.assign({ ':host': Object.assign({ display: 'block' }, addImportantToEachRule(Object.assign({ position: 'relative',
|
|
5942
|
+
'@global': Object.assign({ ':host': Object.assign({ display: 'block' }, addImportantToEachRule(Object.assign({ position: 'relative',
|
|
5943
|
+
// TODO: probably not needed because there is no style with position: fixed
|
|
5944
|
+
transform: 'translate3d(0,0,0)' }, hostHiddenStyles))) }, addImportantToEachRule(Object.assign(Object.assign({
|
|
7801
5945
|
// would be nice to use shared selector like '::slotted([role])'
|
|
7802
5946
|
// but this doesn't work reliably when rendering in browser
|
|
7803
|
-
[transformSelector('::slotted([role])')]: {
|
|
7804
|
-
display: 'inline-block',
|
|
7805
|
-
position: 'relative',
|
|
7806
|
-
margin: '0 0 4px 0',
|
|
7807
|
-
padding: 0,
|
|
7808
|
-
verticalAlign: 'top',
|
|
7809
|
-
fontFamily: 'inherit',
|
|
7810
|
-
fontStyle: 'inherit',
|
|
7811
|
-
fontVariant: 'inherit',
|
|
7812
|
-
fontWeight: 'inherit',
|
|
7813
|
-
fontSize: 'inherit',
|
|
7814
|
-
lineHeight: 'inherit',
|
|
7815
|
-
whiteSpace: 'nowrap',
|
|
7816
|
-
boxSizing: 'border-box',
|
|
7817
|
-
WebkitAppearance: 'none',
|
|
7818
|
-
appearance: 'none',
|
|
7819
|
-
outline: 0,
|
|
7820
|
-
outlineOffset: '1px',
|
|
7821
|
-
textDecoration: 'none',
|
|
7822
|
-
textAlign: 'left',
|
|
7823
|
-
border: 0,
|
|
7824
|
-
background: 'transparent',
|
|
7825
|
-
color: primaryColor,
|
|
7826
|
-
cursor: 'pointer',
|
|
7827
|
-
borderRadius: borderRadiusSmall,
|
|
7828
|
-
'&::before': Object.assign({ content: '""', position: 'absolute', top: '-2px', bottom: '-2px', left: '-4px', right: '-4px', borderRadius: borderRadiusSmall, zIndex: '-1' }, hoverMediaQuery({
|
|
5947
|
+
[transformSelector('::slotted([role])')]: Object.assign(Object.assign({}, getResetInitialStylesForSlottedAnchor), { display: 'inline-block', position: 'relative', margin: '0 0 4px 0', padding: 0, verticalAlign: 'top', fontFamily: 'inherit', fontStyle: 'inherit', fontVariant: 'inherit', fontWeight: 'inherit', fontSize: 'inherit', lineHeight: 'inherit', whiteSpace: 'nowrap', boxSizing: 'border-box', WebkitAppearance: 'none', appearance: 'none', outline: 0, outlineOffset: '1px', textDecoration: 'none', textAlign: 'left', border: 0, background: 'transparent', color: primaryColor, cursor: 'pointer', borderRadius: borderRadiusSmall, '&::before': Object.assign({ content: '""', position: 'absolute', top: '-2px', bottom: '-2px', left: '-4px', right: '-4px', borderRadius: borderRadiusSmall, zIndex: '-1' }, hoverMediaQuery({
|
|
7829
5948
|
transition: getTransition('background'),
|
|
7830
|
-
})),
|
|
7831
|
-
} }, hoverMediaQuery({
|
|
5949
|
+
})) }) }, hoverMediaQuery({
|
|
7832
5950
|
[transformSelector('::slotted([role]:hover)::before')]: Object.assign(Object.assign({}, frostedGlassStyle), { background: hoverColor }),
|
|
7833
5951
|
})), {
|
|
7834
5952
|
// TODO: combine link-social-styles with link-button-styles and tabs-bar-styles
|
|
@@ -7845,7 +5963,7 @@ const getComponentCss$b = (size, weight, theme) => {
|
|
|
7845
5963
|
display: 'block',
|
|
7846
5964
|
position: 'absolute',
|
|
7847
5965
|
width: 0,
|
|
7848
|
-
height: weight === '
|
|
5966
|
+
height: weight === 'semi-bold' ? '2px' : '1.5px',
|
|
7849
5967
|
left: 0,
|
|
7850
5968
|
bottom: '-4px',
|
|
7851
5969
|
background: primaryColor,
|
|
@@ -7858,10 +5976,10 @@ const getComponentCss$b = (size, weight, theme) => {
|
|
|
7858
5976
|
};
|
|
7859
5977
|
|
|
7860
5978
|
const getComponentCss$a = (theme) => {
|
|
7861
|
-
const { focusColor } = getThemedColors(theme);
|
|
5979
|
+
const { primaryColor, focusColor } = getThemedColors(theme);
|
|
7862
5980
|
return getCss({
|
|
7863
5981
|
'@global': {
|
|
7864
|
-
':host': addImportantToEachRule(Object.assign(Object.assign({ display: 'block', position: 'relative' }, hostHiddenStyles), { outline: 0, '&::before': Object.assign({ content: '""', position: 'absolute' }, getInsetJssStyle(-4)), '&(:focus)::before': {
|
|
5982
|
+
':host': addImportantToEachRule(Object.assign(Object.assign({ display: 'block', position: 'relative', color: primaryColor }, hostHiddenStyles), { outline: 0, '&::before': Object.assign({ content: '""', position: 'absolute' }, getInsetJssStyle(-4)), '&(:focus)::before': {
|
|
7865
5983
|
border: `${borderWidthBase} solid ${focusColor}`,
|
|
7866
5984
|
borderRadius: borderRadiusSmall,
|
|
7867
5985
|
}, '&(:focus:not(:focus-visible))::before': {
|
|
@@ -7892,16 +6010,13 @@ const getTagFocusJssStyle = (themedColors) => {
|
|
|
7892
6010
|
};
|
|
7893
6011
|
const getThemedBackgroundColor = (tagColor, themedColors) => {
|
|
7894
6012
|
const colorMap = {
|
|
7895
|
-
'background-default': themedColors.backgroundColor,
|
|
7896
6013
|
'background-base': themedColors.backgroundColor,
|
|
7897
6014
|
'background-surface': themedColors.backgroundSurfaceColor,
|
|
7898
|
-
'neutral-contrast-high': themedColors.primaryColor,
|
|
7899
6015
|
primary: themedColors.primaryColor,
|
|
7900
|
-
'notification-
|
|
7901
|
-
'notification-
|
|
7902
|
-
'notification-success': themedColors.successSoftColor,
|
|
7903
|
-
'notification-error': themedColors.errorSoftColor,
|
|
7904
|
-
'notification-warning': themedColors.warningSoftColor,
|
|
6016
|
+
'notification-info-soft': themedColors.infoSoftColor,
|
|
6017
|
+
'notification-warning-soft': themedColors.warningSoftColor,
|
|
6018
|
+
'notification-success-soft': themedColors.successSoftColor,
|
|
6019
|
+
'notification-error-soft': themedColors.errorSoftColor,
|
|
7905
6020
|
};
|
|
7906
6021
|
return colorMap[tagColor];
|
|
7907
6022
|
};
|
|
@@ -7932,45 +6047,26 @@ const getComponentCss$8 = (color, hasLabel, theme) => {
|
|
|
7932
6047
|
}, 'sr-only': getScreenReaderOnlyJssStyle() }));
|
|
7933
6048
|
};
|
|
7934
6049
|
|
|
7935
|
-
const hasInvertedThemeColor = (tagColor, theme) => {
|
|
7936
|
-
const isDark = isThemeDark(theme);
|
|
7937
|
-
return ((!isDark && (tagColor === 'neutral-contrast-high' || tagColor === 'primary')) || // 'neutral-contrast-high' is deprecated (replaced with 'primary')
|
|
7938
|
-
(isDark &&
|
|
7939
|
-
tagColor !== 'background-surface' &&
|
|
7940
|
-
tagColor !== 'background-default' && // 'background-default' is deprecated (replaced with 'background-base')
|
|
7941
|
-
tagColor !== 'background-base' &&
|
|
7942
|
-
tagColor !== 'notification-neutral' && // 'notification-neutral' is deprecated (replaced with 'notification-info')
|
|
7943
|
-
tagColor !== 'notification-info' &&
|
|
7944
|
-
tagColor !== 'notification-warning' &&
|
|
7945
|
-
tagColor !== 'notification-success' &&
|
|
7946
|
-
tagColor !== 'notification-error'));
|
|
7947
|
-
};
|
|
7948
6050
|
const getThemedBackgroundHoverColor = (tagColor, themedColors, theme) => {
|
|
7949
6051
|
const isDark = isThemeDark(theme);
|
|
7950
|
-
const keySuffix = isDark ? '
|
|
7951
|
-
const primaryColor = isDark ? themedColors.contrastHighColorLighten : themedColors.contrastHighColor;
|
|
6052
|
+
const keySuffix = isDark ? 'Lighten' : 'Darken';
|
|
7952
6053
|
const colorMap = {
|
|
7953
|
-
'background-
|
|
7954
|
-
'background-
|
|
7955
|
-
|
|
7956
|
-
'
|
|
7957
|
-
|
|
7958
|
-
'notification-
|
|
7959
|
-
'notification-
|
|
7960
|
-
'notification-success': themedColors[`successSoft${keySuffix}`],
|
|
7961
|
-
'notification-error': themedColors[`errorSoft${keySuffix}`],
|
|
7962
|
-
'notification-warning': themedColors[`warningSoft${keySuffix}`],
|
|
6054
|
+
'background-base': themedColors[`backgroundColor${keySuffix}`],
|
|
6055
|
+
'background-surface': themedColors[`backgroundSurfaceColor${keySuffix}`],
|
|
6056
|
+
primary: isDark ? themedColors.contrastHighColorLighten : themedColors.contrastHighColor,
|
|
6057
|
+
'notification-info-soft': themedColors[`infoSoftColor${keySuffix}`],
|
|
6058
|
+
'notification-success-soft': themedColors[`successSoftColor${keySuffix}`],
|
|
6059
|
+
'notification-error-soft': themedColors[`errorSoftColor${keySuffix}`],
|
|
6060
|
+
'notification-warning-soft': themedColors[`warningSoftColor${keySuffix}`],
|
|
7963
6061
|
};
|
|
7964
6062
|
return colorMap[tagColor];
|
|
7965
6063
|
};
|
|
7966
6064
|
|
|
7967
6065
|
const getColors = (themedColors, tagColor, theme) => {
|
|
7968
|
-
const
|
|
7969
|
-
const { primaryColor } = hasInvertedTheme ? getInvertedThemedColors(theme) : themedColors;
|
|
7970
|
-
const { focusColor } = themedColors;
|
|
6066
|
+
const { primaryColor } = tagColor === 'primary' ? getInvertedThemedColors(theme) : themedColors;
|
|
7971
6067
|
return {
|
|
7972
6068
|
primaryColor,
|
|
7973
|
-
focusColor,
|
|
6069
|
+
focusColor: themedColors.focusColor,
|
|
7974
6070
|
backgroundColor: getThemedBackgroundColor(tagColor, themedColors),
|
|
7975
6071
|
backgroundHoverColor: getThemedBackgroundHoverColor(tagColor, themedColors, theme),
|
|
7976
6072
|
};
|
|
@@ -7981,27 +6077,14 @@ const getComponentCss$7 = (tagColor, isFocusable, theme) => {
|
|
|
7981
6077
|
return getCss({
|
|
7982
6078
|
'@global': {
|
|
7983
6079
|
':host': Object.assign({ display: 'inline-flex', verticalAlign: 'top' }, addImportantToEachRule(hostHiddenStyles)),
|
|
7984
|
-
span: Object.assign({ display: 'flex', gap: '2px', alignItems: 'center', position: 'relative', padding: '4px 9px', borderRadius: borderRadiusSmall, background: backgroundColor, color: primaryColor, font: textXSmallStyle.font, whiteSpace: 'nowrap' }, (isFocusable &&
|
|
7985
|
-
|
|
7986
|
-
|
|
7987
|
-
|
|
7988
|
-
|
|
7989
|
-
|
|
7990
|
-
|
|
7991
|
-
|
|
7992
|
-
position: 'static',
|
|
7993
|
-
textDecoration: 'underline',
|
|
7994
|
-
cursor: 'pointer',
|
|
7995
|
-
font: 'inherit',
|
|
7996
|
-
outline: 0,
|
|
7997
|
-
color: 'inherit',
|
|
7998
|
-
appearance: 'none',
|
|
7999
|
-
margin: 0,
|
|
8000
|
-
padding: 0,
|
|
8001
|
-
background: 0,
|
|
8002
|
-
border: 0,
|
|
8003
|
-
textAlign: 'left',
|
|
8004
|
-
} }, Object.entries(getTagFocusJssStyle(themedColors)).reduce((result, [key, value]) => {
|
|
6080
|
+
span: Object.assign({ display: 'flex', gap: '2px', alignItems: 'center', position: 'relative', padding: '4px 9px', borderRadius: borderRadiusSmall, background: backgroundColor, color: primaryColor, font: textXSmallStyle.font, whiteSpace: 'nowrap' }, (isFocusable &&
|
|
6081
|
+
hoverMediaQuery({
|
|
6082
|
+
transition: getTransition('background-color'),
|
|
6083
|
+
'&:hover': {
|
|
6084
|
+
background: backgroundHoverColor,
|
|
6085
|
+
},
|
|
6086
|
+
}))),
|
|
6087
|
+
'::slotted': addImportantToEachRule(Object.assign(Object.assign({ '&(a),&(button)': Object.assign(Object.assign({}, getResetInitialStylesForSlottedAnchor), { display: 'inline', position: 'static', textDecoration: 'underline', cursor: 'pointer', font: 'inherit', outline: 0, color: 'inherit', appearance: 'none', margin: 0, padding: 0, background: 0, border: 0, textAlign: 'left' }) }, Object.entries(getTagFocusJssStyle(themedColors)).reduce((result, [key, value]) => {
|
|
8005
6088
|
result[key.replace(/^&([a-z:\-()]*)(::[a-z\-]+)$/, '&(a$1)$2, &(button$1)$2')] = value;
|
|
8006
6089
|
return result;
|
|
8007
6090
|
}, {})), { '&(br)': {
|
|
@@ -8015,6 +6098,17 @@ const getComponentCss$7 = (tagColor, isFocusable, theme) => {
|
|
|
8015
6098
|
};
|
|
8016
6099
|
|
|
8017
6100
|
const isType = (inputType, typeToValidate) => inputType === typeToValidate;
|
|
6101
|
+
// eslint-disable-next-line no-underscore-dangle
|
|
6102
|
+
const _hasShowPickerSupport = () => {
|
|
6103
|
+
return (hasDocument &&
|
|
6104
|
+
'showPicker' in HTMLInputElement.prototype &&
|
|
6105
|
+
// TODO: it would be better to determinate support by checking for existence of "calendar-picker-indicator"
|
|
6106
|
+
!!window.navigator.userAgent.match(/chrome|chromium|crios|edg/i));
|
|
6107
|
+
};
|
|
6108
|
+
const hasShowPickerSupport = _hasShowPickerSupport();
|
|
6109
|
+
const showCustomCalendarOrTimeIndicator = (isCalendar, isTime) => {
|
|
6110
|
+
return hasShowPickerSupport && (isCalendar || isTime);
|
|
6111
|
+
};
|
|
8018
6112
|
|
|
8019
6113
|
const cssVariableInputPaddingLeft = '--p-internal-text-field-input-padding-left';
|
|
8020
6114
|
const cssVariableInputPaddingRight = '--p-internal-text-field-input-padding-right';
|
|
@@ -8039,18 +6133,21 @@ const getComponentCss$6 = (isDisabled, hideLabel, state, hasUnitOrVisibleCounter
|
|
|
8039
6133
|
const isSearch = isType(inputType, 'search');
|
|
8040
6134
|
const isPassword = isType(inputType, 'password');
|
|
8041
6135
|
const isNumber = isType(inputType, 'number');
|
|
6136
|
+
const isCalendar = isType(inputType, 'date') || isType(inputType, 'week') || isType(inputType, 'month');
|
|
6137
|
+
const isTime = isType(inputType, 'time');
|
|
8042
6138
|
const isSearchOrPassword = isSearch || isPassword;
|
|
8043
6139
|
const isSearchWithoutForm = isSearch && !isWithinForm;
|
|
8044
6140
|
const isSearchWithForm = isSearch && isWithinForm;
|
|
8045
|
-
|
|
6141
|
+
const isCalendarOrTimeWithCustomIndicator = showCustomCalendarOrTimeIndicator(isCalendar, isTime);
|
|
6142
|
+
return getCss(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ '@global': Object.assign({ ':host': Object.assign({ display: 'block' }, addImportantToEachRule(Object.assign({ [cssVariableInputPaddingLeft]: isSearchWithoutForm ? getInputPaddingHorizontal(1) : spacingStaticMedium, [cssVariableInputPaddingRight]: isSearchOrPassword || isCalendarOrTimeWithCustomIndicator
|
|
8046
6143
|
? getInputPaddingHorizontal(isSearchWithForm ? 2 : 1)
|
|
8047
|
-
: spacingStaticMedium }, hostHiddenStyles))) }, addImportantToEachRule(Object.assign(Object.assign({}, getBaseChildStyles('input', state, theme, Object.assign({ padding:
|
|
6144
|
+
: spacingStaticMedium }, hostHiddenStyles))) }, addImportantToEachRule(Object.assign(Object.assign({}, getBaseChildStyles('input', state, theme, Object.assign({ padding: `${spacingStaticSmall} var(${cssVariableInputPaddingRight}) ${spacingStaticSmall} var(${cssVariableInputPaddingLeft})` }, (isNumber && {
|
|
8048
6145
|
MozAppearance: 'textfield', // hides up/down spin button for Firefox
|
|
8049
6146
|
})))), { '::slotted': {
|
|
8050
6147
|
'&(input:-internal-autofill-selected),&(input:-internal-autofill-previewed),&(input:-webkit-autofill),&(input:-webkit-autofill:focus)': {
|
|
8051
6148
|
WebkitBackgroundClip: 'padding-box', // reset webkit autofill styles
|
|
8052
6149
|
},
|
|
8053
|
-
} }))) }, (isSearchOrPassword && {
|
|
6150
|
+
} }))) }, ((isSearchOrPassword || isCalendarOrTimeWithCustomIndicator) && {
|
|
8054
6151
|
button: Object.assign(Object.assign({}, baseButtonOrIconStyles), { right: getButtonOrIconOffsetHorizontal(1),
|
|
8055
6152
|
// TODO: maybe we should render hidden button conditionally, needs to be checked if a11y compliant
|
|
8056
6153
|
'&:not([hidden]) ~ .button': {
|
|
@@ -8076,42 +6173,58 @@ const getComponentCss$6 = (isDisabled, hideLabel, state, hasUnitOrVisibleCounter
|
|
|
8076
6173
|
'sr-only': Object.assign(Object.assign({}, getScreenReaderOnlyJssStyle()), { padding: 0 }) }));
|
|
8077
6174
|
};
|
|
8078
6175
|
|
|
8079
|
-
|
|
8080
|
-
const
|
|
8081
|
-
const
|
|
8082
|
-
|
|
8083
|
-
const
|
|
8084
|
-
|
|
8085
|
-
|
|
8086
|
-
|
|
8087
|
-
|
|
8088
|
-
|
|
6176
|
+
/** @deprecated */
|
|
6177
|
+
const isListTypeOrdered = (type) => type !== 'unordered';
|
|
6178
|
+
const isListTypeNumbered = (type) => type === 'numbered';
|
|
6179
|
+
|
|
6180
|
+
const cssVariablePseudoSuffix = '--p-internal-text-list-pseudo-suffix';
|
|
6181
|
+
const cssVariablePaddingTop = '--p-internal-text-list-padding-top';
|
|
6182
|
+
const cssVariablePaddingBottom = '--p-internal-text-list-padding-bottom';
|
|
6183
|
+
const cssVariableUnorderedPaddingLeft = '--p-internal-text-list-unordered-padding-left';
|
|
6184
|
+
const cssVariableOrderedPaddingLeft = '--p-internal-text-list-ordered-padding-left';
|
|
6185
|
+
const cssVariableListStyleType = '--p-internal-text-list-list-style-type';
|
|
6186
|
+
const counter = 'p-text-list-counter';
|
|
6187
|
+
const getComponentCss$5 = (type, theme) => {
|
|
6188
|
+
const isOrderedList = isListTypeOrdered(type);
|
|
8089
6189
|
return getCss({
|
|
8090
6190
|
'@global': {
|
|
8091
|
-
':host':
|
|
8092
|
-
|
|
8093
|
-
|
|
8094
|
-
|
|
8095
|
-
|
|
8096
|
-
|
|
8097
|
-
|
|
8098
|
-
|
|
6191
|
+
':host': Object.assign({ display: 'block' }, addImportantToEachRule(Object.assign({ counterReset: counter }, hostHiddenStyles))),
|
|
6192
|
+
'ol,ul': Object.assign(Object.assign({}, textSmallStyle), { color: getThemedColors(theme).primaryColor, margin: 0, padding: `var(${cssVariablePaddingTop},0) 0 var(${cssVariablePaddingBottom},0) ${isOrderedList
|
|
6193
|
+
? `var(${cssVariableOrderedPaddingLeft},1.5rem)` // reserves space for ::before (root ordered list)
|
|
6194
|
+
: `var(${cssVariableUnorderedPaddingLeft},.375rem)` // reserves space for ::marker "•" (root unordered list)
|
|
6195
|
+
}`, listStyleType: isOrderedList ? 'none' : `var(${cssVariableListStyleType},'•')` }),
|
|
6196
|
+
// css selector for text-list-item
|
|
6197
|
+
'::slotted(*)': addImportantToEachRule(Object.assign({ [cssVariablePaddingTop]: spacingStaticXSmall,
|
|
6198
|
+
// TODO: in case it's last root list item with a nested list it would result in outer spacing which is not desired
|
|
6199
|
+
[cssVariablePaddingBottom]: spacingStaticMedium, [cssVariableOrderedPaddingLeft]: '2rem', [cssVariableUnorderedPaddingLeft]: '.625rem', [cssVariableListStyleType]: '"–"' }, (isOrderedList && {
|
|
6200
|
+
'&::before': {
|
|
6201
|
+
content: `counters(${counter},'.',${isListTypeNumbered(type) ? 'decimal' : 'lower-latin'}) var(${cssVariablePseudoSuffix},'.')`,
|
|
6202
|
+
counterIncrement: counter,
|
|
6203
|
+
position: 'absolute',
|
|
6204
|
+
top: 0,
|
|
6205
|
+
left: 0,
|
|
6206
|
+
transform: 'translate(-100%,0)',
|
|
6207
|
+
},
|
|
6208
|
+
}))),
|
|
8099
6209
|
},
|
|
8100
6210
|
});
|
|
8101
6211
|
};
|
|
8102
6212
|
|
|
8103
|
-
const getComponentCss$4 = (
|
|
6213
|
+
const getComponentCss$4 = () => {
|
|
8104
6214
|
return getCss({
|
|
8105
|
-
'@global': {
|
|
8106
|
-
':host': Object.assign({ display: '
|
|
8107
|
-
'
|
|
8108
|
-
|
|
6215
|
+
'@global': addImportantToEachRule({
|
|
6216
|
+
':host': Object.assign({ display: 'list-item', position: 'relative', font: 'inherit', color: 'inherit', listStyleType: 'inherit', paddingLeft: spacingStaticMedium }, hostHiddenStyles),
|
|
6217
|
+
'::slotted(*)': {
|
|
6218
|
+
[cssVariablePseudoSuffix]: '""', // don't show suffix "." for nested ordered list
|
|
6219
|
+
},
|
|
6220
|
+
}),
|
|
8109
6221
|
});
|
|
8110
6222
|
};
|
|
8111
6223
|
|
|
8112
6224
|
const TEXT_TAGS = ['p', 'span', 'div', 'address', 'blockquote', 'figcaption', 'cite', 'time', 'legend'];
|
|
8113
6225
|
|
|
8114
6226
|
const sizeMap = {
|
|
6227
|
+
'xx-small': fontSizeTextXXSmall,
|
|
8115
6228
|
'x-small': fontSizeTextXSmall,
|
|
8116
6229
|
small: fontSizeTextSmall,
|
|
8117
6230
|
medium: fontSizeTextMedium,
|
|
@@ -8181,4 +6294,4 @@ const getComponentCss = () => {
|
|
|
8181
6294
|
});
|
|
8182
6295
|
};
|
|
8183
6296
|
|
|
8184
|
-
export { getComponentCss$
|
|
6297
|
+
export { getComponentCss$T as getAccordionCss, getComponentCss$S as getBannerCss, getComponentCss$P as getButtonCss, getComponentCss$R as getButtonGroupCss, getComponentCss$Q as getButtonPureCss, getComponentCss$O as getCarouselCss, getComponentCss$N as getCheckboxWrapperCss, getComponentCss$M as getContentWrapperCss, getComponentCss$L as getDisplayCss, getComponentCss$K as getDividerCss, getComponentCss$J as getFieldsetWrapperCss, getComponentCss$H as getFlexCss, getComponentCss$I as getFlexItemCss, getFunctionalComponentRequiredStyles, getFunctionalComponentStateMessageStyles, getComponentCss$F as getGridCss, getComponentCss$G as getGridItemCss, getComponentCss$E as getHeadingCss, getComponentCss$D as getHeadlineCss, getComponentCss$C as getIconCss, getComponentCss$B as getInlineNotificationCss, getComponentCss$z as getLinkCss, getComponentCss$A as getLinkPureCss, getComponentCss$z as getLinkSocialCss, getComponentCss$y as getLinkTileCss, getComponentCss$x as getMarqueCss, getComponentCss$w as getModalCss, getComponentCss$v as getModelSignatureCss, getComponentCss$u as getPaginationCss, getComponentCss$t as getPopoverCss, getComponentCss$s as getRadioButtonWrapperCss, getComponentCss$r as getScrollerCss, getComponentCss$p as getSegmentedControlCss, getComponentCss$q as getSegmentedControlItemCss, getComponentCss$o as getSelectWrapperCss, getComponentCss$m as getSpinnerCss, getComponentCss$k as getStepperHorizontalCss, getComponentCss$l as getStepperHorizontalItemCss, getComponentCss$j as getSwitchCss, getComponentCss$i as getTableBodyCss, getComponentCss$h as getTableCellCss, getComponentCss$c as getTableCss, getComponentCss$g as getTableHeadCellCss, getComponentCss$e as getTableHeadCss, getComponentCss$f as getTableHeadRowCss, getComponentCss$d as getTableRowCss, getComponentCss$b as getTabsBarCss, getComponentCss$9 as getTabsCss, getComponentCss$a as getTabsItemCss, getComponentCss$7 as getTagCss, getComponentCss$8 as getTagDismissibleCss, getComponentCss$3 as getTextCss, getComponentCss$6 as getTextFieldWrapperCss, getComponentCss$5 as getTextListCss, getComponentCss$4 as getTextListItemCss, getComponentCss$2 as getTextareaWrapperCss, getComponentCss as getToastCss };
|