@repobit/dex-system-design 3.0.1 → 3.0.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 +14 -0
- package/dist/src/_bundled/oxc-project_runtime/helpers/esm/decorate.js +1 -0
- package/dist/src/components/accordion/accordion-bg.css.js +1 -288
- package/dist/src/components/accordion/accordion-bg.css.js.map +1 -1
- package/dist/src/components/accordion/accordion-bg.d.ts +5 -5
- package/dist/src/components/accordion/accordion-bg.js +15 -210
- package/dist/src/components/accordion/accordion-bg.js.map +1 -1
- package/dist/src/components/accordion/accordion-keyboard.js +1 -89
- package/dist/src/components/accordion/accordion-keyboard.js.map +1 -1
- package/dist/src/components/accordion/accordion-panel.js +1 -22
- package/dist/src/components/accordion/accordion-panel.js.map +1 -1
- package/dist/src/components/accordion/accordion.css.js +1 -380
- package/dist/src/components/accordion/accordion.css.js.map +1 -1
- package/dist/src/components/accordion/accordion.d.ts +7 -7
- package/dist/src/components/accordion/accordion.js +16 -138
- package/dist/src/components/accordion/accordion.js.map +1 -1
- package/dist/src/components/agent-endpoints/agent-endpoints.css.js +1 -88
- package/dist/src/components/agent-endpoints/agent-endpoints.css.js.map +1 -1
- package/dist/src/components/agent-endpoints/agent-endpoints.d.ts +4 -4
- package/dist/src/components/agent-endpoints/agent-endpoints.js +17 -76
- package/dist/src/components/agent-endpoints/agent-endpoints.js.map +1 -1
- package/dist/src/components/alert/alert.css.js +1 -217
- package/dist/src/components/alert/alert.css.js.map +1 -1
- package/dist/src/components/alert/alert.d.ts +4 -4
- package/dist/src/components/alert/alert.js +6 -110
- package/dist/src/components/alert/alert.js.map +1 -1
- package/dist/src/components/anchor/anchor-nav.css.js +1 -546
- package/dist/src/components/anchor/anchor-nav.css.js.map +1 -1
- package/dist/src/components/anchor/anchor-nav.d.ts +4 -4
- package/dist/src/components/anchor/anchor-nav.js +23 -567
- package/dist/src/components/anchor/anchor-nav.js.map +1 -1
- package/dist/src/components/annotation/annotation.css.js +1 -64
- package/dist/src/components/annotation/annotation.css.js.map +1 -1
- package/dist/src/components/annotation/annotation.d.ts +2 -2
- package/dist/src/components/annotation/annotation.js +7 -72
- package/dist/src/components/annotation/annotation.js.map +1 -1
- package/dist/src/components/audience-card/audience-card.css.js +1 -122
- package/dist/src/components/audience-card/audience-card.css.js.map +1 -1
- package/dist/src/components/audience-card/audience-card.d.ts +2 -2
- package/dist/src/components/audience-card/audience-card.js +8 -83
- package/dist/src/components/audience-card/audience-card.js.map +1 -1
- package/dist/src/components/avatar/avatar.css.js +1 -65
- package/dist/src/components/avatar/avatar.css.js.map +1 -1
- package/dist/src/components/avatar/avatar.d.ts +3 -3
- package/dist/src/components/avatar/avatar.js +6 -76
- package/dist/src/components/avatar/avatar.js.map +1 -1
- package/dist/src/components/awards/awards-flex.css.js +1 -273
- package/dist/src/components/awards/awards-flex.css.js.map +1 -1
- package/dist/src/components/awards/awards-flex.d.ts +12 -12
- package/dist/src/components/awards/awards-flex.js +33 -264
- package/dist/src/components/awards/awards-flex.js.map +1 -1
- package/dist/src/components/awards/awards-spotlight.css.js +1 -161
- package/dist/src/components/awards/awards-spotlight.css.js.map +1 -1
- package/dist/src/components/awards/awards-spotlight.d.ts +4 -4
- package/dist/src/components/awards/awards-spotlight.js +24 -140
- package/dist/src/components/awards/awards-spotlight.js.map +1 -1
- package/dist/src/components/awards/awards.css.js +1 -401
- package/dist/src/components/awards/awards.css.js.map +1 -1
- package/dist/src/components/awards/awards.d.ts +13 -13
- package/dist/src/components/awards/awards.js +26 -179
- package/dist/src/components/awards/awards.js.map +1 -1
- package/dist/src/components/awards/scroll-slides.js +1 -131
- package/dist/src/components/awards/scroll-slides.js.map +1 -1
- package/dist/src/components/back/back.css.js +1 -91
- package/dist/src/components/back/back.css.js.map +1 -1
- package/dist/src/components/back/back.d.ts +1 -1
- package/dist/src/components/back/back.js +8 -71
- package/dist/src/components/back/back.js.map +1 -1
- package/dist/src/components/badge/badge.css.js +1 -204
- package/dist/src/components/badge/badge.css.js.map +1 -1
- package/dist/src/components/badge/badge.d.ts +4 -4
- package/dist/src/components/badge/badge.js +2 -117
- package/dist/src/components/badge/badge.js.map +1 -1
- package/dist/src/components/bento-grid/bento-grid.css.js +16 -150
- package/dist/src/components/bento-grid/bento-grid.css.js.map +1 -1
- package/dist/src/components/bento-grid/bento-grid.d.ts +3 -3
- package/dist/src/components/bento-grid/bento-grid.js +10 -189
- package/dist/src/components/bento-grid/bento-grid.js.map +1 -1
- package/dist/src/components/bento-grid/bento-item.css.js +1 -338
- package/dist/src/components/bento-grid/bento-item.css.js.map +1 -1
- package/dist/src/components/bento-grid/bento-item.d.ts +3 -3
- package/dist/src/components/bento-grid/bento-item.js +10 -94
- package/dist/src/components/bento-grid/bento-item.js.map +1 -1
- package/dist/src/components/blockquote/blockquote.css.js +1 -54
- package/dist/src/components/blockquote/blockquote.css.js.map +1 -1
- package/dist/src/components/blockquote/blockquote.d.ts +2 -2
- package/dist/src/components/blockquote/blockquote.js +1 -44
- package/dist/src/components/blockquote/blockquote.js.map +1 -1
- package/dist/src/components/breadcrumb/breadcrumb.css.js +1 -168
- package/dist/src/components/breadcrumb/breadcrumb.css.js.map +1 -1
- package/dist/src/components/breadcrumb/breadcrumb.d.ts +5 -5
- package/dist/src/components/breadcrumb/breadcrumb.js +9 -166
- package/dist/src/components/breadcrumb/breadcrumb.js.map +1 -1
- package/dist/src/components/button/button.css.js +1 -843
- package/dist/src/components/button/button.css.js.map +1 -1
- package/dist/src/components/button/button.d.ts +5 -5
- package/dist/src/components/button/button.js +18 -420
- package/dist/src/components/button/button.js.map +1 -1
- package/dist/src/components/caption/caption.css.js +1 -29
- package/dist/src/components/caption/caption.css.js.map +1 -1
- package/dist/src/components/caption/caption.d.ts +3 -3
- package/dist/src/components/caption/caption.js +2 -36
- package/dist/src/components/caption/caption.js.map +1 -1
- package/dist/src/components/card-features/card-features.css.js +1 -120
- package/dist/src/components/card-features/card-features.css.js.map +1 -1
- package/dist/src/components/card-features/card-features.d.ts +3 -3
- package/dist/src/components/card-features/card-features.js +12 -145
- package/dist/src/components/card-features/card-features.js.map +1 -1
- package/dist/src/components/cards/card.css.js +1 -369
- package/dist/src/components/cards/card.css.js.map +1 -1
- package/dist/src/components/cards/card.d.ts +3 -3
- package/dist/src/components/cards/card.js +21 -312
- package/dist/src/components/cards/card.js.map +1 -1
- package/dist/src/components/carousel/carousel.css.js +1 -261
- package/dist/src/components/carousel/carousel.css.js.map +1 -1
- package/dist/src/components/carousel/carousel.d.ts +5 -5
- package/dist/src/components/carousel/carousel.js +13 -297
- package/dist/src/components/carousel/carousel.js.map +1 -1
- package/dist/src/components/checkbox/checkbox.css.js +1 -173
- package/dist/src/components/checkbox/checkbox.css.js.map +1 -1
- package/dist/src/components/checkbox/checkbox.d.ts +2 -2
- package/dist/src/components/checkbox/checkbox.js +5 -138
- package/dist/src/components/checkbox/checkbox.js.map +1 -1
- package/dist/src/components/code/code.css.js +1 -73
- package/dist/src/components/code/code.css.js.map +1 -1
- package/dist/src/components/code/code.d.ts +2 -2
- package/dist/src/components/code/code.js +4 -87
- package/dist/src/components/code/code.js.map +1 -1
- package/dist/src/components/compare/compare.css.js +1 -478
- package/dist/src/components/compare/compare.css.js.map +1 -1
- package/dist/src/components/compare/compare.d.ts +5 -5
- package/dist/src/components/compare/compare.js +23 -476
- package/dist/src/components/compare/compare.js.map +1 -1
- package/dist/src/components/comparison-panel/comparison-panel.css.js +1 -141
- package/dist/src/components/comparison-panel/comparison-panel.css.js.map +1 -1
- package/dist/src/components/comparison-panel/comparison-panel.d.ts +2 -2
- package/dist/src/components/comparison-panel/comparison-panel.js +18 -86
- package/dist/src/components/comparison-panel/comparison-panel.js.map +1 -1
- package/dist/src/components/compatibility-table/compatibility-table.css.js +1 -391
- package/dist/src/components/compatibility-table/compatibility-table.css.js.map +1 -1
- package/dist/src/components/compatibility-table/compatibility-table.d.ts +2 -2
- package/dist/src/components/compatibility-table/compatibility-table.js +26 -136
- package/dist/src/components/compatibility-table/compatibility-table.js.map +1 -1
- package/dist/src/components/cta-banner/cta-banner.css.js +1 -97
- package/dist/src/components/cta-banner/cta-banner.css.js.map +1 -1
- package/dist/src/components/cta-banner/cta-banner.d.ts +2 -2
- package/dist/src/components/cta-banner/cta-banner.js +8 -51
- package/dist/src/components/cta-banner/cta-banner.js.map +1 -1
- package/dist/src/components/display/display.css.js +1 -95
- package/dist/src/components/display/display.css.js.map +1 -1
- package/dist/src/components/display/display.d.ts +2 -2
- package/dist/src/components/display/display.js +3 -84
- package/dist/src/components/display/display.js.map +1 -1
- package/dist/src/components/divider/divider-horizontal.d.ts +2 -2
- package/dist/src/components/divider/divider-horizontal.js +4 -63
- package/dist/src/components/divider/divider-horizontal.js.map +1 -1
- package/dist/src/components/divider/divider-vertical.d.ts +2 -2
- package/dist/src/components/divider/divider-vertical.js +6 -61
- package/dist/src/components/divider/divider-vertical.js.map +1 -1
- package/dist/src/components/divider/divider.css.js +1 -20
- package/dist/src/components/divider/divider.css.js.map +1 -1
- package/dist/src/components/dropdown/dropdown.css.js +1 -121
- package/dist/src/components/dropdown/dropdown.css.js.map +1 -1
- package/dist/src/components/dropdown/dropdown.d.ts +5 -5
- package/dist/src/components/dropdown/dropdown.js +17 -283
- package/dist/src/components/dropdown/dropdown.js.map +1 -1
- package/dist/src/components/features/features.css.js +1 -123
- package/dist/src/components/features/features.css.js.map +1 -1
- package/dist/src/components/features/features.d.ts +5 -5
- package/dist/src/components/features/features.js +11 -71
- package/dist/src/components/features/features.js.map +1 -1
- package/dist/src/components/features-tab/features-tab.css.js +1 -100
- package/dist/src/components/features-tab/features-tab.css.js.map +1 -1
- package/dist/src/components/features-tab/features-tab.d.ts +5 -5
- package/dist/src/components/features-tab/features-tab.js +9 -70
- package/dist/src/components/features-tab/features-tab.js.map +1 -1
- package/dist/src/components/fieldset/fieldset.css.js +1 -28
- package/dist/src/components/fieldset/fieldset.css.js.map +1 -1
- package/dist/src/components/fieldset/fieldset.d.ts +2 -2
- package/dist/src/components/fieldset/fieldset.js +3 -31
- package/dist/src/components/fieldset/fieldset.js.map +1 -1
- package/dist/src/components/footer/footer-images.js +5 -27
- package/dist/src/components/footer/footer-images.js.map +1 -1
- package/dist/src/components/footer/footer-links-group.css.js +1 -33
- package/dist/src/components/footer/footer-links-group.css.js.map +1 -1
- package/dist/src/components/footer/footer-links-group.d.ts +3 -3
- package/dist/src/components/footer/footer-links-group.js +3 -32
- package/dist/src/components/footer/footer-links-group.js.map +1 -1
- package/dist/src/components/footer/footer-locale.js +1 -45
- package/dist/src/components/footer/footer-locale.js.map +1 -1
- package/dist/src/components/footer/footer-lp.d.ts +7 -7
- package/dist/src/components/footer/footer-lp.js +8 -121
- package/dist/src/components/footer/footer-lp.js.map +1 -1
- package/dist/src/components/footer/footer-nav-menu.css.js +1 -61
- package/dist/src/components/footer/footer-nav-menu.css.js.map +1 -1
- package/dist/src/components/footer/footer-nav-menu.d.ts +3 -3
- package/dist/src/components/footer/footer-nav-menu.js +3 -47
- package/dist/src/components/footer/footer-nav-menu.js.map +1 -1
- package/dist/src/components/footer/footer.css.js +1 -664
- package/dist/src/components/footer/footer.css.js.map +1 -1
- package/dist/src/components/footer/footer.d.ts +13 -13
- package/dist/src/components/footer/footer.js +20 -305
- package/dist/src/components/footer/footer.js.map +1 -1
- package/dist/src/components/footer/localeMap.js +1 -1
- package/dist/src/components/footer/localeMap.js.map +1 -1
- package/dist/src/components/grid/grid.css.js +1 -78
- package/dist/src/components/grid/grid.css.js.map +1 -1
- package/dist/src/components/grid/grid.d.ts +2 -2
- package/dist/src/components/grid/grid.js +9 -126
- package/dist/src/components/grid/grid.js.map +1 -1
- package/dist/src/components/header/header-code.css.js +1 -369
- package/dist/src/components/header/header-code.css.js.map +1 -1
- package/dist/src/components/header/header-code.d.ts +4 -4
- package/dist/src/components/header/header-code.js +15 -163
- package/dist/src/components/header/header-code.js.map +1 -1
- package/dist/src/components/header/header.css.js +1 -757
- package/dist/src/components/header/header.css.js.map +1 -1
- package/dist/src/components/header/header.d.ts +7 -7
- package/dist/src/components/header/header.js +4 -212
- package/dist/src/components/header/header.js.map +1 -1
- package/dist/src/components/heading/heading.css.js +1 -89
- package/dist/src/components/heading/heading.css.js.map +1 -1
- package/dist/src/components/heading/heading.d.ts +2 -2
- package/dist/src/components/heading/heading.js +1 -108
- package/dist/src/components/heading/heading.js.map +1 -1
- package/dist/src/components/help-text/help-text.css.js +1 -19
- package/dist/src/components/help-text/help-text.css.js.map +1 -1
- package/dist/src/components/help-text/help-text.d.ts +2 -2
- package/dist/src/components/help-text/help-text.js +3 -31
- package/dist/src/components/help-text/help-text.js.map +1 -1
- package/dist/src/components/hero/hero.css.js +1 -362
- package/dist/src/components/hero/hero.css.js.map +1 -1
- package/dist/src/components/hero/hero.d.ts +3 -3
- package/dist/src/components/hero/hero.js +12 -164
- package/dist/src/components/hero/hero.js.map +1 -1
- package/dist/src/components/highlight/highlight.css.js +1 -175
- package/dist/src/components/highlight/highlight.css.js.map +1 -1
- package/dist/src/components/highlight/highlight.d.ts +3 -3
- package/dist/src/components/highlight/highlight.js +4 -115
- package/dist/src/components/highlight/highlight.js.map +1 -1
- package/dist/src/components/icons/analysis-icon.d.ts +1 -1
- package/dist/src/components/icons/analysis-icon.js +2 -20
- package/dist/src/components/icons/analysis-icon.js.map +1 -1
- package/dist/src/components/icons/arrow-down-icon.d.ts +1 -1
- package/dist/src/components/icons/arrow-down-icon.js +2 -20
- package/dist/src/components/icons/arrow-down-icon.js.map +1 -1
- package/dist/src/components/icons/arrow-icon.d.ts +1 -1
- package/dist/src/components/icons/arrow-icon.js +2 -48
- package/dist/src/components/icons/arrow-icon.js.map +1 -1
- package/dist/src/components/icons/arrow-right-icon.d.ts +1 -1
- package/dist/src/components/icons/arrow-right-icon.js +2 -45
- package/dist/src/components/icons/arrow-right-icon.js.map +1 -1
- package/dist/src/components/icons/arrow-up-icon.d.ts +1 -1
- package/dist/src/components/icons/arrow-up-icon.js +2 -33
- package/dist/src/components/icons/arrow-up-icon.js.map +1 -1
- package/dist/src/components/icons/av-comparatives-icon.js +2 -31
- package/dist/src/components/icons/av-comparatives-icon.js.map +1 -1
- package/dist/src/components/icons/bd-ai-icon.js +2 -31
- package/dist/src/components/icons/bd-ai-icon.js.map +1 -1
- package/dist/src/components/icons/best-brands-icon.js +2 -31
- package/dist/src/components/icons/best-brands-icon.js.map +1 -1
- package/dist/src/components/icons/brand-signature-icon.d.ts +1 -1
- package/dist/src/components/icons/brand-signature-icon.js +2 -46
- package/dist/src/components/icons/brand-signature-icon.js.map +1 -1
- package/dist/src/components/icons/check-icon.d.ts +1 -1
- package/dist/src/components/icons/check-icon.js +2 -31
- package/dist/src/components/icons/check-icon.js.map +1 -1
- package/dist/src/components/icons/circle-info-icon.d.ts +1 -1
- package/dist/src/components/icons/circle-info-icon.js +2 -35
- package/dist/src/components/icons/circle-info-icon.js.map +1 -1
- package/dist/src/components/icons/close-icon.d.ts +1 -1
- package/dist/src/components/icons/close-icon.js +2 -20
- package/dist/src/components/icons/close-icon.js.map +1 -1
- package/dist/src/components/icons/enterprise-icon.d.ts +1 -1
- package/dist/src/components/icons/enterprise-icon.js +2 -22
- package/dist/src/components/icons/enterprise-icon.js.map +1 -1
- package/dist/src/components/icons/family-icon.d.ts +1 -1
- package/dist/src/components/icons/family-icon.js +2 -20
- package/dist/src/components/icons/family-icon.js.map +1 -1
- package/dist/src/components/icons/globe-icon.d.ts +1 -1
- package/dist/src/components/icons/globe-icon.js +2 -20
- package/dist/src/components/icons/globe-icon.js.map +1 -1
- package/dist/src/components/icons/guide-icon.d.ts +1 -1
- package/dist/src/components/icons/guide-icon.js +2 -20
- package/dist/src/components/icons/guide-icon.js.map +1 -1
- package/dist/src/components/icons/home-icon.d.ts +1 -1
- package/dist/src/components/icons/home-icon.js +2 -22
- package/dist/src/components/icons/home-icon.js.map +1 -1
- package/dist/src/components/icons/icon-element.js +1 -162
- package/dist/src/components/icons/icon-element.js.map +1 -1
- package/dist/src/components/icons/icons.d.ts +23 -23
- package/dist/src/components/icons/icons.js +1 -42
- package/dist/src/components/icons/individual-icon.d.ts +1 -1
- package/dist/src/components/icons/individual-icon.js +2 -20
- package/dist/src/components/icons/individual-icon.js.map +1 -1
- package/dist/src/components/icons/laurel-icon.d.ts +1 -1
- package/dist/src/components/icons/laurel-icon.js +2 -24
- package/dist/src/components/icons/laurel-icon.js.map +1 -1
- package/dist/src/components/icons/machine-learning-icon.d.ts +1 -1
- package/dist/src/components/icons/machine-learning-icon.js +2 -20
- package/dist/src/components/icons/machine-learning-icon.js.map +1 -1
- package/dist/src/components/icons/marks.d.ts +9 -9
- package/dist/src/components/icons/marks.js +1 -41
- package/dist/src/components/icons/minus-icon.d.ts +1 -1
- package/dist/src/components/icons/minus-icon.js +2 -19
- package/dist/src/components/icons/minus-icon.js.map +1 -1
- package/dist/src/components/icons/missing-icon.d.ts +1 -1
- package/dist/src/components/icons/missing-icon.js +3 -53
- package/dist/src/components/icons/missing-icon.js.map +1 -1
- package/dist/src/components/icons/pause-icon.d.ts +1 -1
- package/dist/src/components/icons/pause-icon.js +2 -22
- package/dist/src/components/icons/pause-icon.js.map +1 -1
- package/dist/src/components/icons/pc-mag-2024-icon.js +2 -31
- package/dist/src/components/icons/pc-mag-2024-icon.js.map +1 -1
- package/dist/src/components/icons/pc-mag-business-icon.js +2 -31
- package/dist/src/components/icons/pc-mag-business-icon.js.map +1 -1
- package/dist/src/components/icons/pc-mag-icon.js +2 -31
- package/dist/src/components/icons/pc-mag-icon.js.map +1 -1
- package/dist/src/components/icons/pc-mag-readers-icon.js +2 -30
- package/dist/src/components/icons/pc-mag-readers-icon.js.map +1 -1
- package/dist/src/components/icons/play-icon.d.ts +1 -1
- package/dist/src/components/icons/play-icon.js +2 -22
- package/dist/src/components/icons/play-icon.js.map +1 -1
- package/dist/src/components/icons/plus-icon.d.ts +1 -1
- package/dist/src/components/icons/plus-icon.js +2 -19
- package/dist/src/components/icons/plus-icon.js.map +1 -1
- package/dist/src/components/icons/quote-icon.d.ts +1 -1
- package/dist/src/components/icons/quote-icon.js +2 -30
- package/dist/src/components/icons/quote-icon.js.map +1 -1
- package/dist/src/components/icons/small-business-icon.d.ts +1 -1
- package/dist/src/components/icons/small-business-icon.js +2 -22
- package/dist/src/components/icons/small-business-icon.js.map +1 -1
- package/dist/src/components/icons/top-product-icon.js +2 -31
- package/dist/src/components/icons/top-product-icon.js.map +1 -1
- package/dist/src/components/image/image.css.js +1 -106
- package/dist/src/components/image/image.css.js.map +1 -1
- package/dist/src/components/image/image.d.ts +2 -2
- package/dist/src/components/image/image.js +10 -115
- package/dist/src/components/image/image.js.map +1 -1
- package/dist/src/components/input/input-clipboard.css.js +1 -93
- package/dist/src/components/input/input-clipboard.css.js.map +1 -1
- package/dist/src/components/input/input-clipboard.d.ts +5 -5
- package/dist/src/components/input/input-clipboard.js +20 -257
- package/dist/src/components/input/input-clipboard.js.map +1 -1
- package/dist/src/components/input/input.css.js +1 -9
- package/dist/src/components/input/input.css.js.map +1 -1
- package/dist/src/components/input/input.d.ts +4 -4
- package/dist/src/components/input/input.js +19 -202
- package/dist/src/components/input/input.js.map +1 -1
- package/dist/src/components/install-options/install-options.css.js +1 -308
- package/dist/src/components/install-options/install-options.css.js.map +1 -1
- package/dist/src/components/install-options/install-options.d.ts +4 -4
- package/dist/src/components/install-options/install-options.js +28 -159
- package/dist/src/components/install-options/install-options.js.map +1 -1
- package/dist/src/components/label/label.css.js +1 -33
- package/dist/src/components/label/label.css.js.map +1 -1
- package/dist/src/components/label/label.d.ts +3 -3
- package/dist/src/components/label/label.js +3 -135
- package/dist/src/components/label/label.js.map +1 -1
- package/dist/src/components/light-carousel/light-carousel.css.js +1 -270
- package/dist/src/components/light-carousel/light-carousel.css.js.map +1 -1
- package/dist/src/components/light-carousel/light-carousel.d.ts +3 -3
- package/dist/src/components/light-carousel/light-carousel.js +16 -181
- package/dist/src/components/light-carousel/light-carousel.js.map +1 -1
- package/dist/src/components/link/link.css.js +1 -288
- package/dist/src/components/link/link.css.js.map +1 -1
- package/dist/src/components/link/link.d.ts +3 -3
- package/dist/src/components/link/link.js +6 -233
- package/dist/src/components/link/link.js.map +1 -1
- package/dist/src/components/list/list-item/list-item.css.js +1 -167
- package/dist/src/components/list/list-item/list-item.css.js.map +1 -1
- package/dist/src/components/list/list-item/list-item.d.ts +3 -3
- package/dist/src/components/list/list-item/list-item.js +3 -122
- package/dist/src/components/list/list-item/list-item.js.map +1 -1
- package/dist/src/components/list/list.css.js +1 -180
- package/dist/src/components/list/list.css.js.map +1 -1
- package/dist/src/components/list/list.d.ts +1 -1
- package/dist/src/components/list/list.js +5 -82
- package/dist/src/components/list/list.js.map +1 -1
- package/dist/src/components/logo-marquee/logo-marquee.css.js +1 -93
- package/dist/src/components/logo-marquee/logo-marquee.css.js.map +1 -1
- package/dist/src/components/logo-marquee/logo-marquee.d.ts +3 -3
- package/dist/src/components/logo-marquee/logo-marquee.js +6 -147
- package/dist/src/components/logo-marquee/logo-marquee.js.map +1 -1
- package/dist/src/components/modal/modal.css.js +1 -203
- package/dist/src/components/modal/modal.css.js.map +1 -1
- package/dist/src/components/modal/modal.d.ts +3 -3
- package/dist/src/components/modal/modal.js +3 -131
- package/dist/src/components/modal/modal.js.map +1 -1
- package/dist/src/components/motion-art/motion-art.d.ts +1 -1
- package/dist/src/components/motion-art/motion-art.js +1 -114
- package/dist/src/components/motion-art/motion-art.js.map +1 -1
- package/dist/src/components/overview/overview.css.js +1 -125
- package/dist/src/components/overview/overview.css.js.map +1 -1
- package/dist/src/components/overview/overview.d.ts +2 -2
- package/dist/src/components/overview/overview.js +9 -50
- package/dist/src/components/overview/overview.js.map +1 -1
- package/dist/src/components/page-switcher/page-switcher.css.js +1 -174
- package/dist/src/components/page-switcher/page-switcher.css.js.map +1 -1
- package/dist/src/components/page-switcher/page-switcher.d.ts +2 -2
- package/dist/src/components/page-switcher/page-switcher.js +6 -62
- package/dist/src/components/page-switcher/page-switcher.js.map +1 -1
- package/dist/src/components/pagination-dots/pagination-dots.css.js +1 -160
- package/dist/src/components/pagination-dots/pagination-dots.css.js.map +1 -1
- package/dist/src/components/pagination-dots/pagination-dots.d.ts +2 -2
- package/dist/src/components/pagination-dots/pagination-dots.js +10 -210
- package/dist/src/components/pagination-dots/pagination-dots.js.map +1 -1
- package/dist/src/components/paragraph/paragraph.css.js +1 -101
- package/dist/src/components/paragraph/paragraph.css.js.map +1 -1
- package/dist/src/components/paragraph/paragraph.d.ts +2 -2
- package/dist/src/components/paragraph/paragraph.js +3 -119
- package/dist/src/components/paragraph/paragraph.js.map +1 -1
- package/dist/src/components/partner-banner/partner-banner.css.js +1 -245
- package/dist/src/components/partner-banner/partner-banner.css.js.map +1 -1
- package/dist/src/components/partner-banner/partner-banner.d.ts +1 -1
- package/dist/src/components/partner-banner/partner-banner.js +6 -81
- package/dist/src/components/partner-banner/partner-banner.js.map +1 -1
- package/dist/src/components/picture/picture.css.js +1 -208
- package/dist/src/components/picture/picture.css.js.map +1 -1
- package/dist/src/components/picture/picture.d.ts +2 -2
- package/dist/src/components/picture/picture.js +14 -186
- package/dist/src/components/picture/picture.js.map +1 -1
- package/dist/src/components/post-card/post-card.css.js +1 -149
- package/dist/src/components/post-card/post-card.css.js.map +1 -1
- package/dist/src/components/post-card/post-card.d.ts +2 -2
- package/dist/src/components/post-card/post-card.js +5 -97
- package/dist/src/components/post-card/post-card.js.map +1 -1
- package/dist/src/components/pricing-cards/adopt-styles.js +1 -18
- package/dist/src/components/pricing-cards/adopt-styles.js.map +1 -1
- package/dist/src/components/pricing-cards/new-pricing-card.d.ts +2 -2
- package/dist/src/components/pricing-cards/new-pricing-card.js +4 -49
- package/dist/src/components/pricing-cards/new-pricing-card.js.map +1 -1
- package/dist/src/components/pricing-cards/new-pricing.css.js +1 -74
- package/dist/src/components/pricing-cards/new-pricing.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-actions.css.js +1 -11
- package/dist/src/components/pricing-cards/pricing-card-actions.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-actions.d.ts +2 -2
- package/dist/src/components/pricing-cards/pricing-card-actions.js +2 -59
- package/dist/src/components/pricing-cards/pricing-card-actions.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-container.css.js +1 -41
- package/dist/src/components/pricing-cards/pricing-card-container.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-container.d.ts +1 -1
- package/dist/src/components/pricing-cards/pricing-card-container.js +2 -40
- package/dist/src/components/pricing-cards/pricing-card-container.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-header.css.js +1 -82
- package/dist/src/components/pricing-cards/pricing-card-header.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-header.d.ts +5 -5
- package/dist/src/components/pricing-cards/pricing-card-header.js +7 -70
- package/dist/src/components/pricing-cards/pricing-card-header.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-pricing.css.js +1 -92
- package/dist/src/components/pricing-cards/pricing-card-pricing.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-pricing.d.ts +6 -6
- package/dist/src/components/pricing-cards/pricing-card-pricing.js +7 -87
- package/dist/src/components/pricing-cards/pricing-card-pricing.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-show-more.css.js +1 -29
- package/dist/src/components/pricing-cards/pricing-card-show-more.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card-show-more.d.ts +4 -4
- package/dist/src/components/pricing-cards/pricing-card-show-more.js +5 -41
- package/dist/src/components/pricing-cards/pricing-card-show-more.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card.css.js +1 -660
- package/dist/src/components/pricing-cards/pricing-card.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-card.d.ts +7 -7
- package/dist/src/components/pricing-cards/pricing-card.js +53 -639
- package/dist/src/components/pricing-cards/pricing-card.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-feature-item.css.js +1 -34
- package/dist/src/components/pricing-cards/pricing-feature-item.css.js.map +1 -1
- package/dist/src/components/pricing-cards/pricing-feature-item.d.ts +2 -2
- package/dist/src/components/pricing-cards/pricing-feature-item.js +2 -22
- package/dist/src/components/pricing-cards/pricing-feature-item.js.map +1 -1
- package/dist/src/components/process-steps/process-steps.css.js +1 -106
- package/dist/src/components/process-steps/process-steps.css.js.map +1 -1
- package/dist/src/components/process-steps/process-steps.d.ts +5 -5
- package/dist/src/components/process-steps/process-steps.js +10 -78
- package/dist/src/components/process-steps/process-steps.js.map +1 -1
- package/dist/src/components/progress/progress.css.js +1 -123
- package/dist/src/components/progress/progress.css.js.map +1 -1
- package/dist/src/components/progress/progress.d.ts +2 -2
- package/dist/src/components/progress/progress.js +6 -72
- package/dist/src/components/progress/progress.js.map +1 -1
- package/dist/src/components/quick-answer/quick-answer.css.js +1 -130
- package/dist/src/components/quick-answer/quick-answer.css.js.map +1 -1
- package/dist/src/components/quick-answer/quick-answer.d.ts +2 -2
- package/dist/src/components/quick-answer/quick-answer.js +9 -49
- package/dist/src/components/quick-answer/quick-answer.js.map +1 -1
- package/dist/src/components/radio/radio-group.css.js +1 -41
- package/dist/src/components/radio/radio-group.css.js.map +1 -1
- package/dist/src/components/radio/radio-group.d.ts +1 -1
- package/dist/src/components/radio/radio-group.js +5 -92
- package/dist/src/components/radio/radio-group.js.map +1 -1
- package/dist/src/components/radio/radio.css.js +1 -193
- package/dist/src/components/radio/radio.css.js.map +1 -1
- package/dist/src/components/radio/radio.d.ts +4 -4
- package/dist/src/components/radio/radio.js +6 -263
- package/dist/src/components/radio/radio.js.map +1 -1
- package/dist/src/components/radio/toggle-radio.d.ts +2 -2
- package/dist/src/components/radio/toggle-radio.js +3 -39
- package/dist/src/components/radio/toggle-radio.js.map +1 -1
- package/dist/src/components/review/review-grid.css.js +1 -46
- package/dist/src/components/review/review-grid.css.js.map +1 -1
- package/dist/src/components/review/review-grid.d.ts +2 -2
- package/dist/src/components/review/review-grid.js +4 -49
- package/dist/src/components/review/review-grid.js.map +1 -1
- package/dist/src/components/review/review.css.js +1 -54
- package/dist/src/components/review/review.css.js.map +1 -1
- package/dist/src/components/review/review.d.ts +2 -2
- package/dist/src/components/review/review.js +2 -59
- package/dist/src/components/review/review.js.map +1 -1
- package/dist/src/components/section/section.css.js +1 -37
- package/dist/src/components/section/section.css.js.map +1 -1
- package/dist/src/components/section/section.d.ts +1 -1
- package/dist/src/components/section/section.js +1 -50
- package/dist/src/components/section/section.js.map +1 -1
- package/dist/src/components/section-header/section-header.css.js +1 -99
- package/dist/src/components/section-header/section-header.css.js.map +1 -1
- package/dist/src/components/section-header/section-header.d.ts +2 -2
- package/dist/src/components/section-header/section-header.js +4 -85
- package/dist/src/components/section-header/section-header.js.map +1 -1
- package/dist/src/components/shared/announcer.d.ts +1 -1
- package/dist/src/components/shared/announcer.js +1 -34
- package/dist/src/components/shared/announcer.js.map +1 -1
- package/dist/src/components/shared/controller.media-query.d.ts +1 -1
- package/dist/src/components/shared/controller.media-query.js +1 -57
- package/dist/src/components/shared/controller.media-query.js.map +1 -1
- package/dist/src/components/shared/define-element.js +1 -16
- package/dist/src/components/shared/define-element.js.map +1 -1
- package/dist/src/components/shared/ensemble.css.js +1 -101
- package/dist/src/components/shared/ensemble.css.js.map +1 -1
- package/dist/src/components/shared/events.js +0 -13
- package/dist/src/components/shared/fill-width.css.js +2 -27
- package/dist/src/components/shared/fill-width.css.js.map +1 -1
- package/dist/src/components/shared/form-control.d.ts +1 -1
- package/dist/src/components/shared/form-control.js +1 -198
- package/dist/src/components/shared/form-control.js.map +1 -1
- package/dist/src/components/shared/form-field.css.js +1 -258
- package/dist/src/components/shared/form-field.css.js.map +1 -1
- package/dist/src/components/shared/prop-vocabulary.js +1 -49
- package/dist/src/components/shared/prop-vocabulary.js.map +1 -1
- package/dist/src/components/shared/token-scales.js +1 -351
- package/dist/src/components/shared/token-scales.js.map +1 -1
- package/dist/src/components/skeleton/skeleton.css.js +1 -32
- package/dist/src/components/skeleton/skeleton.css.js.map +1 -1
- package/dist/src/components/skeleton/skeleton.d.ts +2 -2
- package/dist/src/components/skeleton/skeleton.js +4 -36
- package/dist/src/components/skeleton/skeleton.js.map +1 -1
- package/dist/src/components/spinner/spinner.css.js +1 -87
- package/dist/src/components/spinner/spinner.css.js.map +1 -1
- package/dist/src/components/spinner/spinner.d.ts +3 -3
- package/dist/src/components/spinner/spinner.js +3 -69
- package/dist/src/components/spinner/spinner.js.map +1 -1
- package/dist/src/components/spotlight-section/spotlight-section.css.js +1 -105
- package/dist/src/components/spotlight-section/spotlight-section.css.js.map +1 -1
- package/dist/src/components/spotlight-section/spotlight-section.d.ts +2 -2
- package/dist/src/components/spotlight-section/spotlight-section.js +11 -72
- package/dist/src/components/spotlight-section/spotlight-section.js.map +1 -1
- package/dist/src/components/stat/stat-highlight.js +6 -82
- package/dist/src/components/stat/stat-highlight.js.map +1 -1
- package/dist/src/components/stat/stat-tile.js +5 -52
- package/dist/src/components/stat/stat-tile.js.map +1 -1
- package/dist/src/components/stat/stat.css.js +1 -145
- package/dist/src/components/stat/stat.css.js.map +1 -1
- package/dist/src/components/stat/stat.d.ts +2 -2
- package/dist/src/components/stat/stat.js +1 -3
- package/dist/src/components/switch/switch.css.js +1 -175
- package/dist/src/components/switch/switch.css.js.map +1 -1
- package/dist/src/components/switch/switch.d.ts +4 -4
- package/dist/src/components/switch/switch.js +4 -99
- package/dist/src/components/switch/switch.js.map +1 -1
- package/dist/src/components/tab-list/tab-list.css.js +1 -289
- package/dist/src/components/tab-list/tab-list.css.js.map +1 -1
- package/dist/src/components/tab-list/tab-list.d.ts +1 -1
- package/dist/src/components/tab-list/tab-list.js +13 -191
- package/dist/src/components/tab-list/tab-list.js.map +1 -1
- package/dist/src/components/tabs/tabs.css.js +1 -77
- package/dist/src/components/tabs/tabs.css.js.map +1 -1
- package/dist/src/components/tabs/tabs.d.ts +6 -6
- package/dist/src/components/tabs/tabs.js +8 -220
- package/dist/src/components/tabs/tabs.js.map +1 -1
- package/dist/src/components/tag/tag.css.js +1 -52
- package/dist/src/components/tag/tag.css.js.map +1 -1
- package/dist/src/components/tag/tag.d.ts +2 -2
- package/dist/src/components/tag/tag.js +2 -37
- package/dist/src/components/tag/tag.js.map +1 -1
- package/dist/src/components/terminal/terminal-cursor.js +1 -65
- package/dist/src/components/terminal/terminal-cursor.js.map +1 -1
- package/dist/src/components/terminal/terminal-message.css.js +1 -409
- package/dist/src/components/terminal/terminal-message.css.js.map +1 -1
- package/dist/src/components/terminal/terminal-message.d.ts +5 -5
- package/dist/src/components/terminal/terminal-message.js +28 -183
- package/dist/src/components/terminal/terminal-message.js.map +1 -1
- package/dist/src/components/termsOfUse/terms.css.js +1 -55
- package/dist/src/components/termsOfUse/terms.css.js.map +1 -1
- package/dist/src/components/termsOfUse/terms.d.ts +5 -5
- package/dist/src/components/termsOfUse/terms.js +9 -82
- package/dist/src/components/termsOfUse/terms.js.map +1 -1
- package/dist/src/components/textarea/textarea.css.js +1 -49
- package/dist/src/components/textarea/textarea.css.js.map +1 -1
- package/dist/src/components/textarea/textarea.d.ts +5 -5
- package/dist/src/components/textarea/textarea.js +15 -160
- package/dist/src/components/textarea/textarea.js.map +1 -1
- package/dist/src/components/tooltip/tooltip.css.js +1 -96
- package/dist/src/components/tooltip/tooltip.css.js.map +1 -1
- package/dist/src/components/tooltip/tooltip.d.ts +2 -2
- package/dist/src/components/tooltip/tooltip.js +5 -285
- package/dist/src/components/tooltip/tooltip.js.map +1 -1
- package/dist/src/components/trust-panel/trust-panel.css.js +1 -228
- package/dist/src/components/trust-panel/trust-panel.css.js.map +1 -1
- package/dist/src/components/trust-panel/trust-panel.d.ts +4 -4
- package/dist/src/components/trust-panel/trust-panel.js +25 -104
- package/dist/src/components/trust-panel/trust-panel.js.map +1 -1
- package/dist/src/components/video/video.css.js +1 -20
- package/dist/src/components/video/video.css.js.map +1 -1
- package/dist/src/components/video/video.d.ts +2 -2
- package/dist/src/components/video/video.js +5 -88
- package/dist/src/components/video/video.js.map +1 -1
- package/dist/src/components/video-player/video-player.css.js +1 -167
- package/dist/src/components/video-player/video-player.css.js.map +1 -1
- package/dist/src/components/video-player/video-player.d.ts +2 -2
- package/dist/src/components/video-player/video-player.js +15 -150
- package/dist/src/components/video-player/video-player.js.map +1 -1
- package/dist/src/components/visually-hidden/visually-hidden.css.js +1 -22
- package/dist/src/components/visually-hidden/visually-hidden.css.js.map +1 -1
- package/dist/src/components/visually-hidden/visually-hidden.d.ts +2 -2
- package/dist/src/components/visually-hidden/visually-hidden.js +2 -22
- package/dist/src/components/visually-hidden/visually-hidden.js.map +1 -1
- package/dist/src/tokens/brand-layer.js +8 -162
- package/dist/src/tokens/brand-layer.js.map +1 -1
- package/dist/src/tokens/dark-derivation.js +1 -325
- package/dist/src/tokens/dark-derivation.js.map +1 -1
- package/dist/src/tokens/dark-findings.d.ts +1 -1
- package/dist/src/tokens/dark-findings.js +1 -204
- package/dist/src/tokens/dark-findings.js.map +1 -1
- package/dist/src/tokens/fonts.css +1 -166
- package/dist/src/tokens/layout.css +1 -61
- package/dist/src/tokens/story-chrome.js +27 -221
- package/dist/src/tokens/story-chrome.js.map +1 -1
- package/dist/src/tokens/themes/bitdefender.js +1 -30
- package/dist/src/tokens/themes/bitdefender.js.map +1 -1
- package/dist/src/tokens/themes/contract.js +1 -7
- package/dist/src/tokens/themes/contract.js.map +1 -1
- package/dist/src/tokens/themes/index.js +1 -39
- package/dist/src/tokens/themes/index.js.map +1 -1
- package/dist/src/tokens/token-map.js +1 -236
- package/dist/src/tokens/token-map.js.map +1 -1
- package/dist/src/tokens/token-purposes.js +1 -259
- package/dist/src/tokens/token-purposes.js.map +1 -1
- package/dist/src/tokens/tokens.css +1 -1809
- package/dist/src/tokens/tokens.js +1 -1865
- package/dist/src/tokens/tokens.js.map +1 -1
- package/dist/src/tokens/type-ceiling-words.js +1 -293
- package/dist/src/tokens/type-ceiling-words.js.map +1 -1
- package/package.json +16 -5
- package/schemas/component-manifest.json +1 -1
- package/dist/src/components/icons/icons.js.map +0 -1
- package/dist/src/components/icons/marks.js.map +0 -1
- package/dist/src/components/shared/events.js.map +0 -1
- package/dist/src/components/stat/stat.js.map +0 -1
|
@@ -1,444 +1,42 @@
|
|
|
1
|
-
var
|
|
2
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
-
};
|
|
7
|
-
import { LitElement, html, nothing } from "lit";
|
|
8
|
-
import { property } from "lit/decorators.js";
|
|
9
|
-
import { defineElement } from "../shared/define-element.js";
|
|
10
|
-
import { isOneOf } from "../shared/prop-vocabulary.js";
|
|
11
|
-
// Installs the design tokens into document scope; see src/tokens/tokens.ts
|
|
12
|
-
import "../../tokens/tokens.js";
|
|
13
|
-
import buttonsCSS from "./button.css.js";
|
|
14
|
-
import { fontSize, fontWeight } from "../shared/token-scales.js";
|
|
15
|
-
import { FormControl } from "../shared/form-control.js";
|
|
16
|
-
// the trailing arrow on bd-contact-button; an atom now, not a local registry
|
|
17
|
-
import "../icons/arrow-icon.js";
|
|
18
|
-
// "white" and "outline-white" are ButtonLink-only presets (no bd-button
|
|
19
|
-
// equivalent) used on a solid-colour banner (e.g. cta-banner) where a
|
|
20
|
-
// surface="dark" primary/tertiary button would still be too close in tone —
|
|
21
|
-
// they render a plain white fill / white 2px outline regardless of surface.
|
|
22
|
-
const VARIANTS = ["primary", "secondary", "tertiary", "ghost", "accent", "white", "outline-white"];
|
|
23
|
-
/**
|
|
24
|
-
* Pre-ds-button kind values, mapped onto the variant that reproduces them, so
|
|
25
|
-
* existing markup keeps rendering the same thing.
|
|
26
|
-
*/
|
|
27
|
-
const LEGACY_KINDS = {
|
|
28
|
-
"outline": "ghost", // dark 2px outline
|
|
29
|
-
"primary-outline": "tertiary", // blue 2px outline
|
|
30
|
-
// red is this system's conversion colour, not a danger signal, so both of
|
|
31
|
-
// these earlier names described the wrong thing
|
|
32
|
-
"danger": "accent",
|
|
33
|
-
"destructive": "accent"
|
|
34
|
-
};
|
|
35
|
-
const SIZE_CLASS = { sm: "button--small", md: "button--medium", lg: "button--large" };
|
|
36
|
-
/* No size given: md below the lg breakpoint, lg from it -- the band the
|
|
37
|
-
websites ask for on desktop and the one that fits a phone or tablet row.
|
|
38
|
-
An explicit size still pins one band at every width. */
|
|
39
|
-
const RESPONSIVE_SIZE_CLASS = "button--responsive";
|
|
40
|
-
const SURFACES = ["light", "dark", "brand"];
|
|
41
|
-
const SHAPES = ["default", "rounded"];
|
|
42
|
-
const TYPES = ["button", "submit", "reset"];
|
|
43
|
-
/* custom-click bubbles and is composed, like every sibling event in the
|
|
44
|
-
package -- bd-checkbox's and bd-radio's change, bd-switch's and
|
|
45
|
-
bd-custom-input's bd-change. It was a plain Event, which does not bubble,
|
|
46
|
-
so it reached a listener on the button itself and nothing above it: a form
|
|
47
|
-
or a card delegating from a wrapper heard nothing. composed carries it out
|
|
48
|
-
of any shadow root the button is rendered inside, too. */
|
|
49
|
-
const clickEvent = () => new CustomEvent("custom-click", { bubbles: true, composed: true });
|
|
50
|
-
/**
|
|
51
|
-
* Everything bd-button and bd-button-link share.
|
|
52
|
-
*
|
|
53
|
-
* They differ only in the element they render, and that difference is
|
|
54
|
-
* semantic rather than visual: <button> performs an action in place, <a href>
|
|
55
|
-
* navigates. No CSS substitutes for it — only the link appears in a screen
|
|
56
|
-
* reader's list of links and offers open-in-new-tab, and only the button
|
|
57
|
-
* responds to Space as well as Enter.
|
|
58
|
-
*
|
|
59
|
-
* That element is exposed as part="button", for what only the element that
|
|
60
|
-
* takes the click can do -- a stretched-link ::after across a card, as
|
|
61
|
-
* bd-audience-card draws. Width has its own hook, --bd-button-width, because a
|
|
62
|
-
* part cannot be reached through ::slotted().
|
|
63
|
-
*/
|
|
64
|
-
class BdButtonBase extends LitElement {
|
|
65
|
-
constructor() {
|
|
66
|
-
super(...arguments);
|
|
67
|
-
// label is only an accessible name, never the visible text: defaulting it
|
|
68
|
-
// to a word like "Buy now" would override whatever the caller slotted
|
|
69
|
-
this.label = "";
|
|
70
|
-
// empty is the responsive default; see RESPONSIVE_SIZE_CLASS
|
|
71
|
-
this.size = "";
|
|
72
|
-
this.variant = "primary";
|
|
73
|
-
/** @deprecated pass `variant`. kind meant four different things across the
|
|
74
|
-
atoms; on this one it always meant appearance. */
|
|
75
|
-
this.kind = "";
|
|
76
|
-
this.fullWidth = false;
|
|
77
|
-
this.strong = false;
|
|
78
|
-
this.disabled = false;
|
|
79
|
-
this.loading = false;
|
|
80
|
-
this.fontSize = "";
|
|
81
|
-
this.fontWeight = "";
|
|
82
|
-
this.align = "left";
|
|
83
|
-
// "dark" retunes every variant for a hero or panel with a full background
|
|
84
|
-
// colour, "brand" for a band filled with the brand itself, in that brand's
|
|
85
|
-
// ink; see the SURFACE blocks in button.css.ts
|
|
86
|
-
this.surface = "light";
|
|
87
|
-
/** "rounded" takes the pill corner; see .button--rounded. */
|
|
88
|
-
this.shape = "default";
|
|
89
|
-
/** The accent variant reveals a trailing arrow on hover; this opts out. */
|
|
90
|
-
this.noArrow = false;
|
|
91
|
-
/* A circle holding one icon instead of a label: the homepage's audience
|
|
92
|
-
cards and the mobile menu toggle. A mode, not a variant, because every
|
|
93
|
-
variant, size, surface and state applies to it unchanged -- which is how
|
|
94
|
-
the Button icon sets in the foundation Figma file are drawn. With no
|
|
95
|
-
visible text there is nothing to name the control, so label becomes
|
|
96
|
-
required rather than optional. */
|
|
97
|
-
this.iconOnly = false;
|
|
98
|
-
/* Extra text a screen reader reads after the name, through
|
|
99
|
-
aria-describedby on the inner control. It has to be carried in here:
|
|
100
|
-
the control is in this shadow root, so an aria-describedby written on
|
|
101
|
-
the host, or pointing at an id outside, never reaches it. bd-tooltip
|
|
102
|
-
sets it on a bd-button trigger; a page can set it directly. */
|
|
103
|
-
this.description = "";
|
|
104
|
-
}
|
|
105
|
-
static { this.styles = [buttonsCSS]; }
|
|
106
|
-
willUpdate(changed) {
|
|
107
|
-
if (changed.has("kind") && this.kind)
|
|
108
|
-
this.variant = this.kind;
|
|
109
|
-
if (changed.has("variant") || changed.has("kind")) {
|
|
110
|
-
if (LEGACY_KINDS[this.variant])
|
|
111
|
-
this.variant = LEGACY_KINDS[this.variant];
|
|
112
|
-
if (!isOneOf(VARIANTS, this.variant))
|
|
113
|
-
this.variant = "primary";
|
|
114
|
-
}
|
|
115
|
-
if (changed.has("size") && !SIZE_CLASS[this.size])
|
|
116
|
-
this.size = "";
|
|
117
|
-
if (changed.has("surface") && !isOneOf(SURFACES, this.surface))
|
|
118
|
-
this.surface = "light";
|
|
119
|
-
if (changed.has("shape") && !isOneOf(SHAPES, this.shape))
|
|
120
|
-
this.shape = "default";
|
|
121
|
-
}
|
|
122
|
-
get _inert() {
|
|
123
|
-
return this.disabled || this.loading;
|
|
124
|
-
}
|
|
125
|
-
/* The hover arrow belongs to the conversion CTA -- what "danger" meant before
|
|
126
|
-
it became accent -- and never to a control that cannot be pressed. */
|
|
127
|
-
get _hasArrow() {
|
|
128
|
-
// an icon-only circle has no label to slide aside
|
|
129
|
-
return this.variant === "accent" && !this.noArrow && !this._inert && !this.iconOnly;
|
|
130
|
-
}
|
|
131
|
-
get _classes() {
|
|
132
|
-
return [
|
|
133
|
-
"button",
|
|
134
|
-
`button--${this.variant}`,
|
|
135
|
-
SIZE_CLASS[this.size] || RESPONSIVE_SIZE_CLASS,
|
|
136
|
-
this.iconOnly ? "button--icon-only" : "",
|
|
137
|
-
// a circle stretched to the container is a pill, not this control
|
|
138
|
-
this.fullWidth && !this.iconOnly ? "max--width" : "",
|
|
139
|
-
this.strong ? "button--bold" : "",
|
|
140
|
-
// the circle is already the roundest shape there is
|
|
141
|
-
this.shape === "rounded" && !this.iconOnly ? "button--rounded" : "",
|
|
142
|
-
this._hasArrow ? "button--with-arrow" : "",
|
|
143
|
-
this.loading ? "button--loading" : ""
|
|
144
|
-
].filter(Boolean).join(" ");
|
|
145
|
-
}
|
|
146
|
-
/**
|
|
147
|
-
* font-size and font-weight are step names resolved to token references by
|
|
148
|
-
* shared/token-scales.ts; anything off-scale is dropped.
|
|
149
|
-
*/
|
|
150
|
-
get _inlineStyle() {
|
|
151
|
-
return [
|
|
152
|
-
["font-size", fontSize(this.fontSize)],
|
|
153
|
-
["font-weight", fontWeight(this.fontWeight)]
|
|
154
|
-
].filter(([, v]) => v).map(([p, v]) => `${p}: ${v};`)
|
|
155
|
-
.join(" ");
|
|
156
|
-
}
|
|
157
|
-
/** The spinner is decorative — aria-busy on the control carries the state. */
|
|
158
|
-
get _content() {
|
|
159
|
-
if (this.iconOnly)
|
|
160
|
-
return this._iconContent;
|
|
161
|
-
return html `${this.loading
|
|
162
|
-
? html `<span class="spinner" aria-hidden="true"></span>`
|
|
163
|
-
: nothing}<span class="button__label"><slot>${this.label}</slot></span>${this._hasArrow
|
|
164
|
-
? html `<bd-arrow-icon class="button__arrow" aria-hidden="true"></bd-arrow-icon>`
|
|
165
|
-
: nothing}`;
|
|
166
|
-
}
|
|
167
|
-
/**
|
|
168
|
-
* One glyph, never a glyph and a spinner side by side: the circle holds a
|
|
169
|
-
* single item, so loading replaces the icon rather than joining it.
|
|
170
|
-
*
|
|
171
|
-
* The icon is a slot so any bd-*-icon can go in; with nothing slotted it is
|
|
172
|
-
* the arrow, the system's only true shafted arrow and the default the Figma
|
|
173
|
-
* sets draw. The button and icon scales share step names -- sm 16, md 20,
|
|
174
|
-
* lg 24 against padding 8, 12 and 16 -- and the circle comes out 32, 44 and
|
|
175
|
-
* 56. The glyph reads its step from --bd-button-icon-size through
|
|
176
|
-
* .button__icon rather than a size attribute, so the responsive default
|
|
177
|
-
* resizes it at the breakpoint along with the circle.
|
|
178
|
-
*/
|
|
179
|
-
get _describedBy() {
|
|
180
|
-
return this.description ? "description" : nothing;
|
|
181
|
-
}
|
|
182
|
-
get _description() {
|
|
183
|
-
return this.description ? html `<span id="description" hidden>${this.description}</span>` : nothing;
|
|
184
|
-
}
|
|
185
|
-
get _iconContent() {
|
|
186
|
-
if (this.loading)
|
|
187
|
-
return html `<span class="spinner" aria-hidden="true"></span>`;
|
|
188
|
-
return html `<slot><bd-arrow-icon class="button__icon" aria-hidden="true"></bd-arrow-icon></slot>`;
|
|
189
|
-
}
|
|
190
|
-
_handleClick(e) {
|
|
191
|
-
if (this._inert) {
|
|
192
|
-
e.preventDefault();
|
|
193
|
-
e.stopPropagation();
|
|
194
|
-
return;
|
|
195
|
-
}
|
|
196
|
-
this.dispatchEvent(clickEvent());
|
|
197
|
-
}
|
|
198
|
-
}
|
|
199
|
-
__decorate([
|
|
200
|
-
property({ type: String })
|
|
201
|
-
], BdButtonBase.prototype, "label", void 0);
|
|
202
|
-
__decorate([
|
|
203
|
-
property({ type: String })
|
|
204
|
-
], BdButtonBase.prototype, "size", void 0);
|
|
205
|
-
__decorate([
|
|
206
|
-
property({ type: String, reflect: true })
|
|
207
|
-
], BdButtonBase.prototype, "variant", void 0);
|
|
208
|
-
__decorate([
|
|
209
|
-
property({ type: String })
|
|
210
|
-
], BdButtonBase.prototype, "kind", void 0);
|
|
211
|
-
__decorate([
|
|
212
|
-
property({ type: Boolean, attribute: "fullwidth" })
|
|
213
|
-
], BdButtonBase.prototype, "fullWidth", void 0);
|
|
214
|
-
__decorate([
|
|
215
|
-
property({ type: Boolean })
|
|
216
|
-
], BdButtonBase.prototype, "strong", void 0);
|
|
217
|
-
__decorate([
|
|
218
|
-
property({ type: Boolean, reflect: true })
|
|
219
|
-
], BdButtonBase.prototype, "disabled", void 0);
|
|
220
|
-
__decorate([
|
|
221
|
-
property({ type: Boolean, reflect: true })
|
|
222
|
-
], BdButtonBase.prototype, "loading", void 0);
|
|
223
|
-
__decorate([
|
|
224
|
-
property({ type: String, attribute: "font-size" })
|
|
225
|
-
], BdButtonBase.prototype, "fontSize", void 0);
|
|
226
|
-
__decorate([
|
|
227
|
-
property({ type: String, attribute: "font-weight" })
|
|
228
|
-
], BdButtonBase.prototype, "fontWeight", void 0);
|
|
229
|
-
__decorate([
|
|
230
|
-
property({ type: String })
|
|
231
|
-
], BdButtonBase.prototype, "align", void 0);
|
|
232
|
-
__decorate([
|
|
233
|
-
property({ type: String, reflect: true })
|
|
234
|
-
], BdButtonBase.prototype, "surface", void 0);
|
|
235
|
-
__decorate([
|
|
236
|
-
property({ type: String, reflect: true })
|
|
237
|
-
], BdButtonBase.prototype, "shape", void 0);
|
|
238
|
-
__decorate([
|
|
239
|
-
property({ type: Boolean, attribute: "no-arrow" })
|
|
240
|
-
], BdButtonBase.prototype, "noArrow", void 0);
|
|
241
|
-
__decorate([
|
|
242
|
-
property({ type: Boolean, attribute: "icon-only", reflect: true })
|
|
243
|
-
], BdButtonBase.prototype, "iconOnly", void 0);
|
|
244
|
-
__decorate([
|
|
245
|
-
property({ type: String })
|
|
246
|
-
], BdButtonBase.prototype, "description", void 0);
|
|
247
|
-
/**
|
|
248
|
-
* Performs an action in place -- and, with type="submit" or "reset", that
|
|
249
|
-
* action is the form it sits in.
|
|
250
|
-
*
|
|
251
|
-
* The <button> it renders is in this shadow root, where it has no form owner,
|
|
252
|
-
* so a type on it could never reach a form: a page that wanted bd-button to
|
|
253
|
-
* submit had to fall back to a native one. The element is form-associated
|
|
254
|
-
* instead (shared/form-control.ts), and does the submit or reset itself:
|
|
255
|
-
* requestSubmit(), so the form validates first and fires submit as it would
|
|
256
|
-
* for a native button, or reset(). A <fieldset disabled> around it disables
|
|
257
|
-
* it too, and el.click() presses it.
|
|
258
|
-
*
|
|
259
|
-
* type defaults to "button", not the native "submit": every bd-button on a
|
|
260
|
-
* page today was written to do nothing to its form, and stays that way.
|
|
261
|
-
*/
|
|
262
|
-
let Button = class Button extends FormControl(BdButtonBase) {
|
|
263
|
-
constructor() {
|
|
264
|
-
super(...arguments);
|
|
265
|
-
this.type = "button";
|
|
266
|
-
}
|
|
267
|
-
willUpdate(changed) {
|
|
268
|
-
super.willUpdate(changed);
|
|
269
|
-
if (changed.has("type") && !isOneOf(TYPES, this.type))
|
|
270
|
-
this.type = "button";
|
|
271
|
-
}
|
|
272
|
-
get _control() {
|
|
273
|
-
return this.renderRoot?.querySelector?.("button");
|
|
274
|
-
}
|
|
275
|
-
get _inert() {
|
|
276
|
-
return super._inert || this._formDisabled;
|
|
277
|
-
}
|
|
278
|
-
// el.click() and a <label for> press it, as they press a native button
|
|
279
|
-
_activate() {
|
|
280
|
-
this._control?.click();
|
|
281
|
-
}
|
|
282
|
-
_handleClick(e) {
|
|
283
|
-
super._handleClick(e);
|
|
284
|
-
if (this._inert)
|
|
285
|
-
return;
|
|
286
|
-
if (this.type === "submit")
|
|
287
|
-
this.form?.requestSubmit();
|
|
288
|
-
else if (this.type === "reset")
|
|
289
|
-
this.form?.reset();
|
|
290
|
-
}
|
|
291
|
-
render() {
|
|
292
|
-
return html `
|
|
1
|
+
import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import{fontSize as t,fontWeight as n}from"../shared/token-scales.js";import r from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import{isOneOf as i}from"../shared/prop-vocabulary.js";import a from"./button.css.js";import{FormControl as o}from"../shared/form-control.js";import"../icons/arrow-icon.js";import{LitElement as s,html as c,nothing as l}from"lit";import{property as u}from"lit/decorators.js";var d=[`primary`,`secondary`,`tertiary`,`ghost`,`accent`,`white`,`outline-white`],f={outline:`ghost`,"primary-outline":`tertiary`,danger:`accent`,destructive:`accent`},p={sm:`button--small`,md:`button--medium`,lg:`button--large`},m=`button--responsive`,h=[`light`,`dark`,`brand`],g=[`default`,`rounded`],_=[`button`,`submit`,`reset`],v=()=>new CustomEvent(`custom-click`,{bubbles:!0,composed:!0}),y=class extends s{constructor(...e){super(...e),this.label=``,this.size=``,this.variant=`primary`,this.kind=``,this.fullWidth=!1,this.strong=!1,this.disabled=!1,this.loading=!1,this.fontSize=``,this.fontWeight=``,this.align=`left`,this.surface=`light`,this.shape=`default`,this.noArrow=!1,this.iconOnly=!1,this.description=``}static{this.styles=[a]}willUpdate(e){e.has(`kind`)&&this.kind&&(this.variant=this.kind),(e.has(`variant`)||e.has(`kind`))&&(f[this.variant]&&(this.variant=f[this.variant]),i(d,this.variant)||(this.variant=`primary`)),e.has(`size`)&&!p[this.size]&&(this.size=``),e.has(`surface`)&&!i(h,this.surface)&&(this.surface=`light`),e.has(`shape`)&&!i(g,this.shape)&&(this.shape=`default`)}get _inert(){return this.disabled||this.loading}get _hasArrow(){return this.variant===`accent`&&!this.noArrow&&!this._inert&&!this.iconOnly}get _classes(){return[`button`,`button--${this.variant}`,p[this.size]||m,this.iconOnly?`button--icon-only`:``,this.fullWidth&&!this.iconOnly?`max--width`:``,this.strong?`button--bold`:``,this.shape===`rounded`&&!this.iconOnly?`button--rounded`:``,this._hasArrow?`button--with-arrow`:``,this.loading?`button--loading`:``].filter(Boolean).join(` `)}get _inlineStyle(){return[[`font-size`,t(this.fontSize)],[`font-weight`,n(this.fontWeight)]].filter(([,e])=>e).map(([e,t])=>`${e}: ${t};`).join(` `)}get _content(){return this.iconOnly?this._iconContent:c`${this.loading?c`<span class="spinner" aria-hidden="true"></span>`:l}<span class="button__label"><slot>${this.label}</slot></span>${this._hasArrow?c`<bd-arrow-icon class="button__arrow" aria-hidden="true"></bd-arrow-icon>`:l}`}get _describedBy(){return this.description?`description`:l}get _description(){return this.description?c`<span id="description" hidden>${this.description}</span>`:l}get _iconContent(){return this.loading?c`<span class="spinner" aria-hidden="true"></span>`:c`<slot><bd-arrow-icon class="button__icon" aria-hidden="true"></bd-arrow-icon></slot>`}_handleClick(e){this._inert?(e.preventDefault(),e.stopPropagation()):this.dispatchEvent(v())}};r([u({type:String})],y.prototype,`label`,void 0),r([u({type:String})],y.prototype,`size`,void 0),r([u({type:String,reflect:!0})],y.prototype,`variant`,void 0),r([u({type:String})],y.prototype,`kind`,void 0),r([u({type:Boolean,attribute:`fullwidth`})],y.prototype,`fullWidth`,void 0),r([u({type:Boolean})],y.prototype,`strong`,void 0),r([u({type:Boolean,reflect:!0})],y.prototype,`disabled`,void 0),r([u({type:Boolean,reflect:!0})],y.prototype,`loading`,void 0),r([u({type:String,attribute:`font-size`})],y.prototype,`fontSize`,void 0),r([u({type:String,attribute:`font-weight`})],y.prototype,`fontWeight`,void 0),r([u({type:String})],y.prototype,`align`,void 0),r([u({type:String,reflect:!0})],y.prototype,`surface`,void 0),r([u({type:String,reflect:!0})],y.prototype,`shape`,void 0),r([u({type:Boolean,attribute:`no-arrow`})],y.prototype,`noArrow`,void 0),r([u({type:Boolean,attribute:`icon-only`,reflect:!0})],y.prototype,`iconOnly`,void 0),r([u({type:String})],y.prototype,`description`,void 0);var b=class extends o(y){constructor(...e){super(...e),this.type=`button`}willUpdate(e){super.willUpdate(e),e.has(`type`)&&!i(_,this.type)&&(this.type=`button`)}get _control(){return this.renderRoot?.querySelector?.(`button`)}get _inert(){return super._inert||this._formDisabled}_activate(){this._control?.click()}_handleClick(e){super._handleClick(e),!this._inert&&(this.type===`submit`?this.form?.requestSubmit():this.type===`reset`&&this.form?.reset())}render(){return c`
|
|
293
2
|
<button
|
|
294
3
|
type="button"
|
|
295
4
|
part="button"
|
|
296
5
|
class="${this._classes}"
|
|
297
|
-
aria-label="${this.label
|
|
298
|
-
aria-busy="${this.loading
|
|
6
|
+
aria-label="${this.label||l}"
|
|
7
|
+
aria-busy="${this.loading?`true`:l}"
|
|
299
8
|
aria-describedby="${this._describedBy}"
|
|
300
|
-
?disabled="${this.disabled
|
|
9
|
+
?disabled="${this.disabled||this._formDisabled}"
|
|
301
10
|
style="${this._inlineStyle}"
|
|
302
11
|
@click=${this._handleClick}
|
|
303
12
|
>${this._content}</button>${this._description}
|
|
304
|
-
|
|
305
|
-
}
|
|
306
|
-
};
|
|
307
|
-
__decorate([
|
|
308
|
-
property({ type: String })
|
|
309
|
-
], Button.prototype, "type", void 0);
|
|
310
|
-
Button = __decorate([
|
|
311
|
-
defineElement("bd-button")
|
|
312
|
-
], Button);
|
|
313
|
-
/** Navigates. Looks identical; is not the same control. */
|
|
314
|
-
let ButtonLink = class ButtonLink extends BdButtonBase {
|
|
315
|
-
constructor() {
|
|
316
|
-
super();
|
|
317
|
-
this.href = "";
|
|
318
|
-
this.buyLink = false;
|
|
319
|
-
/* The base class comment calls <a href> the element that navigates and
|
|
320
|
-
"offers open-in-new-tab" -- and until now the atom could not express
|
|
321
|
-
that, so a consumer needing a new tab had to hand-roll the anchor and
|
|
322
|
-
lost the button's focus ring, disabled state and typography with it. */
|
|
323
|
-
this.target = "";
|
|
324
|
-
this.rel = "";
|
|
325
|
-
this.align = "left";
|
|
326
|
-
}
|
|
327
|
-
/* A buy link's href is the store's to fill, on the anchor in this shadow
|
|
328
|
-
root -- and @repobit/dex-store-elements only searches the shadow tree of a
|
|
329
|
-
host matching '[shadow], [data-bd-watch-shadow]' (renders/index.ts), the
|
|
330
|
-
same opt-in bd-header reflects. Without it the store never found the
|
|
331
|
-
anchor, and every buy link rendered with no href at all.
|
|
332
|
-
|
|
333
|
-
Set on connect, not in an update. The store hears of a new element from
|
|
334
|
-
its MutationObserver, whose callback runs before the element's first
|
|
335
|
-
update, and reads the opt-in then and not again. Set in willUpdate, it was
|
|
336
|
-
there for the links on the page when the store first looked and missing
|
|
337
|
-
for every link rendered after -- the cards a plan switch brings in.
|
|
338
|
-
connectedCallback runs inside the insertion, so the attribute and the
|
|
339
|
-
shadow root are both in place when the observer reads them. */
|
|
340
|
-
connectedCallback() {
|
|
341
|
-
super.connectedCallback();
|
|
342
|
-
this.toggleAttribute("data-bd-watch-shadow", this.buyLink);
|
|
343
|
-
}
|
|
344
|
-
// buyLink changed on a link already on the page
|
|
345
|
-
willUpdate(changed) {
|
|
346
|
-
super.willUpdate(changed);
|
|
347
|
-
if (changed.has("buyLink") && this.isConnected)
|
|
348
|
-
this.toggleAttribute("data-bd-watch-shadow", this.buyLink);
|
|
349
|
-
}
|
|
350
|
-
/* Reverse tabnabbing is the reason rather than convention: a new tab opened
|
|
351
|
-
from here keeps a window.opener handle back unless rel says otherwise. An
|
|
352
|
-
explicit rel always wins, so a consumer can still opt out deliberately. */
|
|
353
|
-
get _rel() {
|
|
354
|
-
if (this.rel)
|
|
355
|
-
return this.rel;
|
|
356
|
-
return this.target === "_blank" ? "noopener noreferrer" : "";
|
|
357
|
-
}
|
|
358
|
-
render() {
|
|
359
|
-
// A link has no native disabled state. Dropping the href stops it being a
|
|
360
|
-
// link at all, so the state is announced with aria-disabled and the role
|
|
361
|
-
// is restored explicitly; tabindex keeps it out of the tab order.
|
|
362
|
-
const href = this._inert || !this.href ? nothing : this.href;
|
|
363
|
-
return html `
|
|
13
|
+
`}};r([u({type:String})],b.prototype,`type`,void 0),b=r([e(`bd-button`)],b);var x=class extends y{constructor(){super(),this.href=``,this.buyLink=!1,this.target=``,this.rel=``,this.align=`left`}connectedCallback(){super.connectedCallback(),this.toggleAttribute(`data-bd-watch-shadow`,this.buyLink)}willUpdate(e){super.willUpdate(e),e.has(`buyLink`)&&this.isConnected&&this.toggleAttribute(`data-bd-watch-shadow`,this.buyLink)}get _rel(){return this.rel?this.rel:this.target===`_blank`?`noopener noreferrer`:``}render(){let e=this._inert||!this.href?l:this.href;return c`
|
|
364
14
|
<a
|
|
365
15
|
part="button"
|
|
366
|
-
href="${
|
|
367
|
-
target="${this.target
|
|
368
|
-
rel="${this._rel
|
|
369
|
-
role="${this._inert
|
|
370
|
-
tabindex="${this._inert
|
|
16
|
+
href="${e}"
|
|
17
|
+
target="${this.target||l}"
|
|
18
|
+
rel="${this._rel||l}"
|
|
19
|
+
role="${this._inert?`link`:l}"
|
|
20
|
+
tabindex="${this._inert?`-1`:l}"
|
|
371
21
|
class="${this._classes}"
|
|
372
|
-
aria-label="${this.label
|
|
373
|
-
aria-busy="${this.loading
|
|
374
|
-
aria-disabled="${this.disabled
|
|
22
|
+
aria-label="${this.label||l}"
|
|
23
|
+
aria-busy="${this.loading?`true`:l}"
|
|
24
|
+
aria-disabled="${this.disabled?`true`:l}"
|
|
375
25
|
aria-describedby="${this._describedBy}"
|
|
376
26
|
style="${this._inlineStyle}"
|
|
377
27
|
@click=${this._handleClick}
|
|
378
28
|
?data-store-render="${this.buyLink}"
|
|
379
29
|
?data-store-buy-link="${this.buyLink}"
|
|
380
30
|
>${this._content}</a>${this._description}
|
|
381
|
-
|
|
382
|
-
}
|
|
383
|
-
};
|
|
384
|
-
__decorate([
|
|
385
|
-
property({ type: String })
|
|
386
|
-
], ButtonLink.prototype, "href", void 0);
|
|
387
|
-
__decorate([
|
|
388
|
-
property({ type: Boolean })
|
|
389
|
-
], ButtonLink.prototype, "buyLink", void 0);
|
|
390
|
-
__decorate([
|
|
391
|
-
property({ type: String })
|
|
392
|
-
], ButtonLink.prototype, "target", void 0);
|
|
393
|
-
__decorate([
|
|
394
|
-
property({ type: String })
|
|
395
|
-
], ButtonLink.prototype, "rel", void 0);
|
|
396
|
-
ButtonLink = __decorate([
|
|
397
|
-
defineElement("bd-button-link")
|
|
398
|
-
], ButtonLink);
|
|
399
|
-
/**
|
|
400
|
-
* A fixed "Contact us" CTA — a preset rather than a variant, with no size or
|
|
401
|
-
* kind axis. Its trailing arrow is bd-arrow-icon, an atom.
|
|
402
|
-
*/
|
|
403
|
-
let ContactButton = class ContactButton extends LitElement {
|
|
404
|
-
constructor() {
|
|
405
|
-
super(...arguments);
|
|
406
|
-
this.label = "Contact us";
|
|
407
|
-
this.href = "";
|
|
408
|
-
this.align = "left";
|
|
409
|
-
this.shape = "default";
|
|
410
|
-
}
|
|
411
|
-
static { this.styles = [buttonsCSS]; }
|
|
412
|
-
_handleClick() {
|
|
413
|
-
this.dispatchEvent(clickEvent());
|
|
414
|
-
}
|
|
415
|
-
render() {
|
|
416
|
-
return html `
|
|
31
|
+
`}};r([u({type:String})],x.prototype,`href`,void 0),r([u({type:Boolean})],x.prototype,`buyLink`,void 0),r([u({type:String})],x.prototype,`target`,void 0),r([u({type:String})],x.prototype,`rel`,void 0),x=r([e(`bd-button-link`)],x);var S=class extends s{constructor(...e){super(...e),this.label=`Contact us`,this.href=``,this.align=`left`,this.shape=`default`}static{this.styles=[a]}_handleClick(){this.dispatchEvent(v())}render(){return c`
|
|
417
32
|
<a
|
|
418
|
-
class="button bd-contact-btn ${this.shape
|
|
419
|
-
href="${this.href
|
|
420
|
-
aria-label="${this.label
|
|
33
|
+
class="button bd-contact-btn ${this.shape===`rounded`?`button--rounded`:``}"
|
|
34
|
+
href="${this.href||l}"
|
|
35
|
+
aria-label="${this.label||l}"
|
|
421
36
|
@click=${this._handleClick}
|
|
422
37
|
>
|
|
423
38
|
${this.label}
|
|
424
39
|
<bd-arrow-icon aria-hidden="true"></bd-arrow-icon>
|
|
425
40
|
</a>
|
|
426
|
-
|
|
427
|
-
}
|
|
428
|
-
};
|
|
429
|
-
__decorate([
|
|
430
|
-
property({ type: String })
|
|
431
|
-
], ContactButton.prototype, "label", void 0);
|
|
432
|
-
__decorate([
|
|
433
|
-
property({ type: String })
|
|
434
|
-
], ContactButton.prototype, "href", void 0);
|
|
435
|
-
__decorate([
|
|
436
|
-
property({ type: String })
|
|
437
|
-
], ContactButton.prototype, "align", void 0);
|
|
438
|
-
__decorate([
|
|
439
|
-
property({ type: String, reflect: true })
|
|
440
|
-
], ContactButton.prototype, "shape", void 0);
|
|
441
|
-
ContactButton = __decorate([
|
|
442
|
-
defineElement("bd-contact-button")
|
|
443
|
-
], ContactButton);
|
|
41
|
+
`}};r([u({type:String})],S.prototype,`label`,void 0),r([u({type:String})],S.prototype,`href`,void 0),r([u({type:String})],S.prototype,`align`,void 0),r([u({type:String,reflect:!0})],S.prototype,`shape`,void 0),S=r([e(`bd-contact-button`)],S);
|
|
444
42
|
//# sourceMappingURL=button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../../src/components/button/button.ts"],"names":[],"mappings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IAAI,CAAC,IAAI,IAAI,OAAO;sBACd,IAAI,CAAC,KAAK,IAAI,OAAO;iBAC1B,IAAI,CAAC,YAAY;;UAExB,IAAI,CAAC,KAAK;;;KAGf,CAAC;IACJ,CAAC;;AAxBD;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;4CACN;AAErB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;2CACjB;AAEV;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;4CACL;AAEtB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CACjB;AAVrB,aAAa;IADlB,aAAa,CAAC,mBAAmB,CAAC;GAC7B,aAAa,CA6BlB","sourcesContent":["import { LitElement, html, nothing, type PropertyValues } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"../shared/define-element.ts\";\nimport { isOneOf, type Size } from \"../shared/prop-vocabulary.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"../../tokens/tokens.ts\";\nimport buttonsCSS from \"./button.css.ts\";\nimport { fontSize, fontWeight, type FontSizeStep, type FontWeightStep } from \"../shared/token-scales.ts\";\nimport { FormControl } from \"../shared/form-control.ts\";\n// the trailing arrow on bd-contact-button; an atom now, not a local registry\nimport \"../icons/arrow-icon.ts\";\n\n// \"white\" and \"outline-white\" are ButtonLink-only presets (no bd-button\n// equivalent) used on a solid-colour banner (e.g. cta-banner) where a\n// surface=\"dark\" primary/tertiary button would still be too close in tone —\n// they render a plain white fill / white 2px outline regardless of surface.\nconst VARIANTS = [\"primary\", \"secondary\", \"tertiary\", \"ghost\", \"accent\", \"white\", \"outline-white\"] as const;\n\n/**\n * Pre-ds-button kind values, mapped onto the variant that reproduces them, so\n * existing markup keeps rendering the same thing.\n */\nconst LEGACY_KINDS: Record<string, Variant> = {\n \"outline\" : \"ghost\", // dark 2px outline\n \"primary-outline\": \"tertiary\", // blue 2px outline\n // red is this system's conversion colour, not a danger signal, so both of\n // these earlier names described the wrong thing\n \"danger\" : \"accent\",\n \"destructive\" : \"accent\"\n};\n\nconst SIZE_CLASS: Record<string, string> = { sm: \"button--small\", md: \"button--medium\", lg: \"button--large\" };\n/* No size given: md below the lg breakpoint, lg from it -- the band the\n websites ask for on desktop and the one that fits a phone or tablet row.\n An explicit size still pins one band at every width. */\nconst RESPONSIVE_SIZE_CLASS = \"button--responsive\";\nconst SURFACES = [\"light\", \"dark\", \"brand\"] as const;\nconst SHAPES = [\"default\", \"rounded\"] as const;\nconst TYPES = [\"button\", \"submit\", \"reset\"] as const;\n\ntype Variant = typeof VARIANTS[number];\ntype Surface = typeof SURFACES[number];\ntype Shape = typeof SHAPES[number];\ntype ButtonType = typeof TYPES[number];\ntype Align = \"left\" | \"center\" | \"right\";\n\n/* custom-click bubbles and is composed, like every sibling event in the\n package -- bd-checkbox's and bd-radio's change, bd-switch's and\n bd-custom-input's bd-change. It was a plain Event, which does not bubble,\n so it reached a listener on the button itself and nothing above it: a form\n or a card delegating from a wrapper heard nothing. composed carries it out\n of any shadow root the button is rendered inside, too. */\nconst clickEvent = () => new CustomEvent(\"custom-click\", { bubbles: true, composed: true });\n\n/**\n * Everything bd-button and bd-button-link share.\n *\n * They differ only in the element they render, and that difference is\n * semantic rather than visual: <button> performs an action in place, <a href>\n * navigates. No CSS substitutes for it — only the link appears in a screen\n * reader's list of links and offers open-in-new-tab, and only the button\n * responds to Space as well as Enter.\n *\n * That element is exposed as part=\"button\", for what only the element that\n * takes the click can do -- a stretched-link ::after across a card, as\n * bd-audience-card draws. Width has its own hook, --bd-button-width, because a\n * part cannot be reached through ::slotted().\n */\nclass BdButtonBase extends LitElement {\n static styles = [buttonsCSS];\n\n // label is only an accessible name, never the visible text: defaulting it\n // to a word like \"Buy now\" would override whatever the caller slotted\n @property({ type: String })\n label = \"\";\n // empty is the responsive default; see RESPONSIVE_SIZE_CLASS\n @property({ type: String })\n size: Size | \"\" = \"\";\n @property({ type: String, reflect: true })\n variant: Variant = \"primary\";\n /** @deprecated pass `variant`. kind meant four different things across the\n atoms; on this one it always meant appearance. */\n @property({ type: String })\n kind = \"\";\n @property({ type: Boolean, attribute: \"fullwidth\" })\n fullWidth = false;\n @property({ type: Boolean })\n strong = false;\n @property({ type: Boolean, reflect: true })\n disabled = false;\n @property({ type: Boolean, reflect: true })\n loading = false;\n @property({ type: String, attribute: \"font-size\" })\n fontSize: FontSizeStep | \"\" = \"\";\n @property({ type: String, attribute: \"font-weight\" })\n fontWeight: FontWeightStep | \"\" = \"\";\n @property({ type: String })\n align: Align = \"left\";\n // \"dark\" retunes every variant for a hero or panel with a full background\n // colour, \"brand\" for a band filled with the brand itself, in that brand's\n // ink; see the SURFACE blocks in button.css.ts\n @property({ type: String, reflect: true })\n surface: Surface = \"light\";\n /** \"rounded\" takes the pill corner; see .button--rounded. */\n @property({ type: String, reflect: true })\n shape: Shape = \"default\";\n /** The accent variant reveals a trailing arrow on hover; this opts out. */\n @property({ type: Boolean, attribute: \"no-arrow\" })\n noArrow = false;\n /* A circle holding one icon instead of a label: the homepage's audience\n cards and the mobile menu toggle. A mode, not a variant, because every\n variant, size, surface and state applies to it unchanged -- which is how\n the Button icon sets in the foundation Figma file are drawn. With no\n visible text there is nothing to name the control, so label becomes\n required rather than optional. */\n @property({ type: Boolean, attribute: \"icon-only\", reflect: true })\n iconOnly = false;\n /* Extra text a screen reader reads after the name, through\n aria-describedby on the inner control. It has to be carried in here:\n the control is in this shadow root, so an aria-describedby written on\n the host, or pointing at an id outside, never reaches it. bd-tooltip\n sets it on a bd-button trigger; a page can set it directly. */\n @property({ type: String })\n description = \"\";\n\n willUpdate(changed: PropertyValues<this>) {\n if (changed.has(\"kind\") && this.kind) this.variant = this.kind as Variant;\n if (changed.has(\"variant\") || changed.has(\"kind\")) {\n if (LEGACY_KINDS[this.variant]) this.variant = LEGACY_KINDS[this.variant];\n if (!isOneOf(VARIANTS, this.variant)) this.variant = \"primary\";\n }\n if (changed.has(\"size\") && !SIZE_CLASS[this.size]) this.size = \"\";\n if (changed.has(\"surface\") && !isOneOf(SURFACES, this.surface)) this.surface = \"light\";\n if (changed.has(\"shape\") && !isOneOf(SHAPES, this.shape)) this.shape = \"default\";\n }\n\n get _inert() {\n return this.disabled || this.loading;\n }\n\n /* The hover arrow belongs to the conversion CTA -- what \"danger\" meant before\n it became accent -- and never to a control that cannot be pressed. */\n get _hasArrow() {\n // an icon-only circle has no label to slide aside\n return this.variant === \"accent\" && !this.noArrow && !this._inert && !this.iconOnly;\n }\n\n get _classes() {\n return [\n \"button\",\n `button--${this.variant}`,\n SIZE_CLASS[this.size] || RESPONSIVE_SIZE_CLASS,\n this.iconOnly ? \"button--icon-only\" : \"\",\n // a circle stretched to the container is a pill, not this control\n this.fullWidth && !this.iconOnly ? \"max--width\" : \"\",\n this.strong ? \"button--bold\" : \"\",\n // the circle is already the roundest shape there is\n this.shape === \"rounded\" && !this.iconOnly ? \"button--rounded\" : \"\",\n this._hasArrow ? \"button--with-arrow\" : \"\",\n this.loading ? \"button--loading\" : \"\"\n ].filter(Boolean).join(\" \");\n }\n\n /**\n * font-size and font-weight are step names resolved to token references by\n * shared/token-scales.ts; anything off-scale is dropped.\n */\n get _inlineStyle() {\n return [\n [\"font-size\", fontSize(this.fontSize)],\n [\"font-weight\", fontWeight(this.fontWeight)]\n ].filter(([, v]) => v).map(([p, v]) => `${p}: ${v};`)\n .join(\" \");\n }\n\n /** The spinner is decorative — aria-busy on the control carries the state. */\n get _content() {\n if (this.iconOnly) return this._iconContent;\n return html`${this.loading\n ? html`<span class=\"spinner\" aria-hidden=\"true\"></span>`\n : nothing}<span class=\"button__label\"><slot>${this.label}</slot></span>${this._hasArrow\n ? html`<bd-arrow-icon class=\"button__arrow\" aria-hidden=\"true\"></bd-arrow-icon>`\n : nothing}`;\n }\n\n /**\n * One glyph, never a glyph and a spinner side by side: the circle holds a\n * single item, so loading replaces the icon rather than joining it.\n *\n * The icon is a slot so any bd-*-icon can go in; with nothing slotted it is\n * the arrow, the system's only true shafted arrow and the default the Figma\n * sets draw. The button and icon scales share step names -- sm 16, md 20,\n * lg 24 against padding 8, 12 and 16 -- and the circle comes out 32, 44 and\n * 56. The glyph reads its step from --bd-button-icon-size through\n * .button__icon rather than a size attribute, so the responsive default\n * resizes it at the breakpoint along with the circle.\n */\n get _describedBy() {\n return this.description ? \"description\" : nothing;\n }\n\n get _description() {\n return this.description ? html`<span id=\"description\" hidden>${this.description}</span>` : nothing;\n }\n\n get _iconContent() {\n if (this.loading) return html`<span class=\"spinner\" aria-hidden=\"true\"></span>`;\n return html`<slot><bd-arrow-icon class=\"button__icon\" aria-hidden=\"true\"></bd-arrow-icon></slot>`;\n }\n\n _handleClick(e: MouseEvent) {\n if (this._inert) {\n e.preventDefault();\n e.stopPropagation();\n return;\n }\n this.dispatchEvent(clickEvent());\n }\n}\n\n/**\n * Performs an action in place -- and, with type=\"submit\" or \"reset\", that\n * action is the form it sits in.\n *\n * The <button> it renders is in this shadow root, where it has no form owner,\n * so a type on it could never reach a form: a page that wanted bd-button to\n * submit had to fall back to a native one. The element is form-associated\n * instead (shared/form-control.ts), and does the submit or reset itself:\n * requestSubmit(), so the form validates first and fires submit as it would\n * for a native button, or reset(). A <fieldset disabled> around it disables\n * it too, and el.click() presses it.\n *\n * type defaults to \"button\", not the native \"submit\": every bd-button on a\n * page today was written to do nothing to its form, and stays that way.\n */\n@defineElement(\"bd-button\")\nclass Button extends FormControl(BdButtonBase) {\n @property({ type: String })\n type: ButtonType = \"button\";\n\n willUpdate(changed: PropertyValues<this>) {\n super.willUpdate(changed);\n if (changed.has(\"type\") && !isOneOf(TYPES, this.type)) this.type = \"button\";\n }\n\n protected get _control(): HTMLButtonElement | null {\n return this.renderRoot?.querySelector?.(\"button\");\n }\n\n get _inert() {\n return super._inert || this._formDisabled;\n }\n\n // el.click() and a <label for> press it, as they press a native button\n protected _activate() {\n this._control?.click();\n }\n\n _handleClick(e: MouseEvent) {\n super._handleClick(e);\n if (this._inert) return;\n if (this.type === \"submit\") this.form?.requestSubmit();\n else if (this.type === \"reset\") this.form?.reset();\n }\n\n render() {\n return html`\n <button\n type=\"button\"\n part=\"button\"\n class=\"${this._classes}\"\n aria-label=\"${this.label || nothing}\"\n aria-busy=\"${this.loading ? \"true\" : nothing}\"\n aria-describedby=\"${this._describedBy}\"\n ?disabled=\"${this.disabled || this._formDisabled}\"\n style=\"${this._inlineStyle}\"\n @click=${this._handleClick}\n >${this._content}</button>${this._description}\n `;\n }\n}\n\n/** Navigates. Looks identical; is not the same control. */\n@defineElement(\"bd-button-link\")\nclass ButtonLink extends BdButtonBase {\n @property({ type: String })\n href = \"\";\n @property({ type: Boolean })\n buyLink = false;\n /* The base class comment calls <a href> the element that navigates and\n \"offers open-in-new-tab\" -- and until now the atom could not express\n that, so a consumer needing a new tab had to hand-roll the anchor and\n lost the button's focus ring, disabled state and typography with it. */\n @property({ type: String })\n target = \"\";\n @property({ type: String })\n rel = \"\";\n\n constructor() {\n super();\n this.align = \"left\";\n }\n\n /* A buy link's href is the store's to fill, on the anchor in this shadow\n root -- and @repobit/dex-store-elements only searches the shadow tree of a\n host matching '[shadow], [data-bd-watch-shadow]' (renders/index.ts), the\n same opt-in bd-header reflects. Without it the store never found the\n anchor, and every buy link rendered with no href at all.\n\n Set on connect, not in an update. The store hears of a new element from\n its MutationObserver, whose callback runs before the element's first\n update, and reads the opt-in then and not again. Set in willUpdate, it was\n there for the links on the page when the store first looked and missing\n for every link rendered after -- the cards a plan switch brings in.\n connectedCallback runs inside the insertion, so the attribute and the\n shadow root are both in place when the observer reads them. */\n connectedCallback() {\n super.connectedCallback();\n this.toggleAttribute(\"data-bd-watch-shadow\", this.buyLink);\n }\n\n // buyLink changed on a link already on the page\n willUpdate(changed: PropertyValues<this>) {\n super.willUpdate(changed);\n if (changed.has(\"buyLink\") && this.isConnected) this.toggleAttribute(\"data-bd-watch-shadow\", this.buyLink);\n }\n\n /* Reverse tabnabbing is the reason rather than convention: a new tab opened\n from here keeps a window.opener handle back unless rel says otherwise. An\n explicit rel always wins, so a consumer can still opt out deliberately. */\n get _rel() {\n if (this.rel) return this.rel;\n return this.target === \"_blank\" ? \"noopener noreferrer\" : \"\";\n }\n\n render() {\n // A link has no native disabled state. Dropping the href stops it being a\n // link at all, so the state is announced with aria-disabled and the role\n // is restored explicitly; tabindex keeps it out of the tab order.\n const href = this._inert || !this.href ? nothing : this.href;\n\n return html`\n <a\n part=\"button\"\n href=\"${href}\"\n target=\"${this.target || nothing}\"\n rel=\"${this._rel || nothing}\"\n role=\"${this._inert ? \"link\" : nothing}\"\n tabindex=\"${this._inert ? \"-1\" : nothing}\"\n class=\"${this._classes}\"\n aria-label=\"${this.label || nothing}\"\n aria-busy=\"${this.loading ? \"true\" : nothing}\"\n aria-disabled=\"${this.disabled ? \"true\" : nothing}\"\n aria-describedby=\"${this._describedBy}\"\n style=\"${this._inlineStyle}\"\n @click=${this._handleClick}\n ?data-store-render=\"${this.buyLink}\"\n ?data-store-buy-link=\"${this.buyLink}\"\n >${this._content}</a>${this._description}\n `;\n }\n}\n\n/**\n * A fixed \"Contact us\" CTA — a preset rather than a variant, with no size or\n * kind axis. Its trailing arrow is bd-arrow-icon, an atom.\n */\n@defineElement(\"bd-contact-button\")\nclass ContactButton extends LitElement {\n static styles = [buttonsCSS];\n\n @property({ type: String })\n label = \"Contact us\";\n @property({ type: String })\n href = \"\";\n @property({ type: String })\n align: Align = \"left\";\n @property({ type: String, reflect: true })\n shape: Shape = \"default\";\n\n _handleClick() {\n this.dispatchEvent(clickEvent());\n }\n\n render() {\n return html`\n <a\n class=\"button bd-contact-btn ${this.shape === \"rounded\" ? \"button--rounded\" : \"\"}\"\n href=\"${this.href || nothing}\"\n aria-label=\"${this.label || nothing}\"\n @click=${this._handleClick}\n >\n ${this.label}\n <bd-arrow-icon aria-hidden=\"true\"></bd-arrow-icon>\n </a>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-button\" : Button;\n \"bd-button-link\" : ButtonLink;\n \"bd-contact-button\": ContactButton;\n }\n interface HTMLElementEventMap {\n \"custom-click\": CustomEvent<null>;\n }\n}"]}
|
|
1
|
+
{"version":3,"file":"button.js","names":["buttonsCSS","_decorate","__decorate","button_css_default","VARIANTS","LEGACY_KINDS","\"outline\"","\"danger\"","\"destructive\"","SIZE_CLASS","RESPONSIVE_SIZE_CLASS","SURFACES","SHAPES","TYPES","clickEvent","BdButtonBase","LitElement","_args","changed","isOneOf","fontSize","fontWeight","v","p","nothing","property","Button","FormControl","_args2","defineElement","ButtonLink","href","ContactButton","_args3"],"sources":["../../../../src/components/button/button.ts"],"sourcesContent":["import { LitElement, html, nothing, type PropertyValues } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { isOneOf, type Size } from \"#shared/prop-vocabulary.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport buttonsCSS from \"./button.css.ts\";\nimport { fontSize, fontWeight, type FontSizeStep, type FontWeightStep } from \"#shared/token-scales.ts\";\nimport { FormControl } from \"#shared/form-control.ts\";\n// the trailing arrow on bd-contact-button; an atom now, not a local registry\nimport \"#components/icons/arrow-icon.ts\";\n\n// \"white\" and \"outline-white\" are ButtonLink-only presets (no bd-button\n// equivalent) used on a solid-colour banner (e.g. cta-banner) where a\n// surface=\"dark\" primary/tertiary button would still be too close in tone —\n// they render a plain white fill / white 2px outline regardless of surface.\nconst VARIANTS = [\"primary\", \"secondary\", \"tertiary\", \"ghost\", \"accent\", \"white\", \"outline-white\"] as const;\n\n/**\n * Pre-ds-button kind values, mapped onto the variant that reproduces them, so\n * existing markup keeps rendering the same thing.\n */\nconst LEGACY_KINDS: Record<string, Variant> = {\n \"outline\" : \"ghost\", // dark 2px outline\n \"primary-outline\": \"tertiary\", // blue 2px outline\n // red is this system's conversion colour, not a danger signal, so both of\n // these earlier names described the wrong thing\n \"danger\" : \"accent\",\n \"destructive\" : \"accent\"\n};\n\nconst SIZE_CLASS: Record<string, string> = { sm: \"button--small\", md: \"button--medium\", lg: \"button--large\" };\n/* No size given: md below the lg breakpoint, lg from it -- the band the\n websites ask for on desktop and the one that fits a phone or tablet row.\n An explicit size still pins one band at every width. */\nconst RESPONSIVE_SIZE_CLASS = \"button--responsive\";\nconst SURFACES = [\"light\", \"dark\", \"brand\"] as const;\nconst SHAPES = [\"default\", \"rounded\"] as const;\nconst TYPES = [\"button\", \"submit\", \"reset\"] as const;\n\ntype Variant = typeof VARIANTS[number];\ntype Surface = typeof SURFACES[number];\ntype Shape = typeof SHAPES[number];\ntype ButtonType = typeof TYPES[number];\ntype Align = \"left\" | \"center\" | \"right\";\n\n/* custom-click bubbles and is composed, like every sibling event in the\n package -- bd-checkbox's and bd-radio's change, bd-switch's and\n bd-custom-input's bd-change. It was a plain Event, which does not bubble,\n so it reached a listener on the button itself and nothing above it: a form\n or a card delegating from a wrapper heard nothing. composed carries it out\n of any shadow root the button is rendered inside, too. */\nconst clickEvent = () => new CustomEvent(\"custom-click\", { bubbles: true, composed: true });\n\n/**\n * Everything bd-button and bd-button-link share.\n *\n * They differ only in the element they render, and that difference is\n * semantic rather than visual: <button> performs an action in place, <a href>\n * navigates. No CSS substitutes for it — only the link appears in a screen\n * reader's list of links and offers open-in-new-tab, and only the button\n * responds to Space as well as Enter.\n *\n * That element is exposed as part=\"button\", for what only the element that\n * takes the click can do -- a stretched-link ::after across a card, as\n * bd-audience-card draws. Width has its own hook, --bd-button-width, because a\n * part cannot be reached through ::slotted().\n */\nclass BdButtonBase extends LitElement {\n static styles = [buttonsCSS];\n\n // label is only an accessible name, never the visible text: defaulting it\n // to a word like \"Buy now\" would override whatever the caller slotted\n @property({ type: String })\n label = \"\";\n // empty is the responsive default; see RESPONSIVE_SIZE_CLASS\n @property({ type: String })\n size: Size | \"\" = \"\";\n @property({ type: String, reflect: true })\n variant: Variant = \"primary\";\n /** @deprecated pass `variant`. kind meant four different things across the\n atoms; on this one it always meant appearance. */\n @property({ type: String })\n kind = \"\";\n @property({ type: Boolean, attribute: \"fullwidth\" })\n fullWidth = false;\n @property({ type: Boolean })\n strong = false;\n @property({ type: Boolean, reflect: true })\n disabled = false;\n @property({ type: Boolean, reflect: true })\n loading = false;\n @property({ type: String, attribute: \"font-size\" })\n fontSize: FontSizeStep | \"\" = \"\";\n @property({ type: String, attribute: \"font-weight\" })\n fontWeight: FontWeightStep | \"\" = \"\";\n @property({ type: String })\n align: Align = \"left\";\n // \"dark\" retunes every variant for a hero or panel with a full background\n // colour, \"brand\" for a band filled with the brand itself, in that brand's\n // ink; see the SURFACE blocks in button.css.ts\n @property({ type: String, reflect: true })\n surface: Surface = \"light\";\n /** \"rounded\" takes the pill corner; see .button--rounded. */\n @property({ type: String, reflect: true })\n shape: Shape = \"default\";\n /** The accent variant reveals a trailing arrow on hover; this opts out. */\n @property({ type: Boolean, attribute: \"no-arrow\" })\n noArrow = false;\n /* A circle holding one icon instead of a label: the homepage's audience\n cards and the mobile menu toggle. A mode, not a variant, because every\n variant, size, surface and state applies to it unchanged -- which is how\n the Button icon sets in the foundation Figma file are drawn. With no\n visible text there is nothing to name the control, so label becomes\n required rather than optional. */\n @property({ type: Boolean, attribute: \"icon-only\", reflect: true })\n iconOnly = false;\n /* Extra text a screen reader reads after the name, through\n aria-describedby on the inner control. It has to be carried in here:\n the control is in this shadow root, so an aria-describedby written on\n the host, or pointing at an id outside, never reaches it. bd-tooltip\n sets it on a bd-button trigger; a page can set it directly. */\n @property({ type: String })\n description = \"\";\n\n willUpdate(changed: PropertyValues<this>) {\n if (changed.has(\"kind\") && this.kind) this.variant = this.kind as Variant;\n if (changed.has(\"variant\") || changed.has(\"kind\")) {\n if (LEGACY_KINDS[this.variant]) this.variant = LEGACY_KINDS[this.variant];\n if (!isOneOf(VARIANTS, this.variant)) this.variant = \"primary\";\n }\n if (changed.has(\"size\") && !SIZE_CLASS[this.size]) this.size = \"\";\n if (changed.has(\"surface\") && !isOneOf(SURFACES, this.surface)) this.surface = \"light\";\n if (changed.has(\"shape\") && !isOneOf(SHAPES, this.shape)) this.shape = \"default\";\n }\n\n get _inert() {\n return this.disabled || this.loading;\n }\n\n /* The hover arrow belongs to the conversion CTA -- what \"danger\" meant before\n it became accent -- and never to a control that cannot be pressed. */\n get _hasArrow() {\n // an icon-only circle has no label to slide aside\n return this.variant === \"accent\" && !this.noArrow && !this._inert && !this.iconOnly;\n }\n\n get _classes() {\n return [\n \"button\",\n `button--${this.variant}`,\n SIZE_CLASS[this.size] || RESPONSIVE_SIZE_CLASS,\n this.iconOnly ? \"button--icon-only\" : \"\",\n // a circle stretched to the container is a pill, not this control\n this.fullWidth && !this.iconOnly ? \"max--width\" : \"\",\n this.strong ? \"button--bold\" : \"\",\n // the circle is already the roundest shape there is\n this.shape === \"rounded\" && !this.iconOnly ? \"button--rounded\" : \"\",\n this._hasArrow ? \"button--with-arrow\" : \"\",\n this.loading ? \"button--loading\" : \"\"\n ].filter(Boolean).join(\" \");\n }\n\n /**\n * font-size and font-weight are step names resolved to token references by\n * shared/token-scales.ts; anything off-scale is dropped.\n */\n get _inlineStyle() {\n return [\n [\"font-size\", fontSize(this.fontSize)],\n [\"font-weight\", fontWeight(this.fontWeight)]\n ].filter(([, v]) => v).map(([p, v]) => `${p}: ${v};`)\n .join(\" \");\n }\n\n /** The spinner is decorative — aria-busy on the control carries the state. */\n get _content() {\n if (this.iconOnly) return this._iconContent;\n return html`${this.loading\n ? html`<span class=\"spinner\" aria-hidden=\"true\"></span>`\n : nothing}<span class=\"button__label\"><slot>${this.label}</slot></span>${this._hasArrow\n ? html`<bd-arrow-icon class=\"button__arrow\" aria-hidden=\"true\"></bd-arrow-icon>`\n : nothing}`;\n }\n\n /**\n * One glyph, never a glyph and a spinner side by side: the circle holds a\n * single item, so loading replaces the icon rather than joining it.\n *\n * The icon is a slot so any bd-*-icon can go in; with nothing slotted it is\n * the arrow, the system's only true shafted arrow and the default the Figma\n * sets draw. The button and icon scales share step names -- sm 16, md 20,\n * lg 24 against padding 8, 12 and 16 -- and the circle comes out 32, 44 and\n * 56. The glyph reads its step from --bd-button-icon-size through\n * .button__icon rather than a size attribute, so the responsive default\n * resizes it at the breakpoint along with the circle.\n */\n get _describedBy() {\n return this.description ? \"description\" : nothing;\n }\n\n get _description() {\n return this.description ? html`<span id=\"description\" hidden>${this.description}</span>` : nothing;\n }\n\n get _iconContent() {\n if (this.loading) return html`<span class=\"spinner\" aria-hidden=\"true\"></span>`;\n return html`<slot><bd-arrow-icon class=\"button__icon\" aria-hidden=\"true\"></bd-arrow-icon></slot>`;\n }\n\n _handleClick(e: MouseEvent) {\n if (this._inert) {\n e.preventDefault();\n e.stopPropagation();\n return;\n }\n this.dispatchEvent(clickEvent());\n }\n}\n\n/**\n * Performs an action in place -- and, with type=\"submit\" or \"reset\", that\n * action is the form it sits in.\n *\n * The <button> it renders is in this shadow root, where it has no form owner,\n * so a type on it could never reach a form: a page that wanted bd-button to\n * submit had to fall back to a native one. The element is form-associated\n * instead (shared/form-control.ts), and does the submit or reset itself:\n * requestSubmit(), so the form validates first and fires submit as it would\n * for a native button, or reset(). A <fieldset disabled> around it disables\n * it too, and el.click() presses it.\n *\n * type defaults to \"button\", not the native \"submit\": every bd-button on a\n * page today was written to do nothing to its form, and stays that way.\n */\n@defineElement(\"bd-button\")\nclass Button extends FormControl(BdButtonBase) {\n @property({ type: String })\n type: ButtonType = \"button\";\n\n willUpdate(changed: PropertyValues<this>) {\n super.willUpdate(changed);\n if (changed.has(\"type\") && !isOneOf(TYPES, this.type)) this.type = \"button\";\n }\n\n protected get _control(): HTMLButtonElement | null {\n return this.renderRoot?.querySelector?.(\"button\");\n }\n\n get _inert() {\n return super._inert || this._formDisabled;\n }\n\n // el.click() and a <label for> press it, as they press a native button\n protected _activate() {\n this._control?.click();\n }\n\n _handleClick(e: MouseEvent) {\n super._handleClick(e);\n if (this._inert) return;\n if (this.type === \"submit\") this.form?.requestSubmit();\n else if (this.type === \"reset\") this.form?.reset();\n }\n\n render() {\n return html`\n <button\n type=\"button\"\n part=\"button\"\n class=\"${this._classes}\"\n aria-label=\"${this.label || nothing}\"\n aria-busy=\"${this.loading ? \"true\" : nothing}\"\n aria-describedby=\"${this._describedBy}\"\n ?disabled=\"${this.disabled || this._formDisabled}\"\n style=\"${this._inlineStyle}\"\n @click=${this._handleClick}\n >${this._content}</button>${this._description}\n `;\n }\n}\n\n/** Navigates. Looks identical; is not the same control. */\n@defineElement(\"bd-button-link\")\nclass ButtonLink extends BdButtonBase {\n @property({ type: String })\n href = \"\";\n @property({ type: Boolean })\n buyLink = false;\n /* The base class comment calls <a href> the element that navigates and\n \"offers open-in-new-tab\" -- and until now the atom could not express\n that, so a consumer needing a new tab had to hand-roll the anchor and\n lost the button's focus ring, disabled state and typography with it. */\n @property({ type: String })\n target = \"\";\n @property({ type: String })\n rel = \"\";\n\n constructor() {\n super();\n this.align = \"left\";\n }\n\n /* A buy link's href is the store's to fill, on the anchor in this shadow\n root -- and @repobit/dex-store-elements only searches the shadow tree of a\n host matching '[shadow], [data-bd-watch-shadow]' (renders/index.ts), the\n same opt-in bd-header reflects. Without it the store never found the\n anchor, and every buy link rendered with no href at all.\n\n Set on connect, not in an update. The store hears of a new element from\n its MutationObserver, whose callback runs before the element's first\n update, and reads the opt-in then and not again. Set in willUpdate, it was\n there for the links on the page when the store first looked and missing\n for every link rendered after -- the cards a plan switch brings in.\n connectedCallback runs inside the insertion, so the attribute and the\n shadow root are both in place when the observer reads them. */\n connectedCallback() {\n super.connectedCallback();\n this.toggleAttribute(\"data-bd-watch-shadow\", this.buyLink);\n }\n\n // buyLink changed on a link already on the page\n willUpdate(changed: PropertyValues<this>) {\n super.willUpdate(changed);\n if (changed.has(\"buyLink\") && this.isConnected) this.toggleAttribute(\"data-bd-watch-shadow\", this.buyLink);\n }\n\n /* Reverse tabnabbing is the reason rather than convention: a new tab opened\n from here keeps a window.opener handle back unless rel says otherwise. An\n explicit rel always wins, so a consumer can still opt out deliberately. */\n get _rel() {\n if (this.rel) return this.rel;\n return this.target === \"_blank\" ? \"noopener noreferrer\" : \"\";\n }\n\n render() {\n // A link has no native disabled state. Dropping the href stops it being a\n // link at all, so the state is announced with aria-disabled and the role\n // is restored explicitly; tabindex keeps it out of the tab order.\n const href = this._inert || !this.href ? nothing : this.href;\n\n return html`\n <a\n part=\"button\"\n href=\"${href}\"\n target=\"${this.target || nothing}\"\n rel=\"${this._rel || nothing}\"\n role=\"${this._inert ? \"link\" : nothing}\"\n tabindex=\"${this._inert ? \"-1\" : nothing}\"\n class=\"${this._classes}\"\n aria-label=\"${this.label || nothing}\"\n aria-busy=\"${this.loading ? \"true\" : nothing}\"\n aria-disabled=\"${this.disabled ? \"true\" : nothing}\"\n aria-describedby=\"${this._describedBy}\"\n style=\"${this._inlineStyle}\"\n @click=${this._handleClick}\n ?data-store-render=\"${this.buyLink}\"\n ?data-store-buy-link=\"${this.buyLink}\"\n >${this._content}</a>${this._description}\n `;\n }\n}\n\n/**\n * A fixed \"Contact us\" CTA — a preset rather than a variant, with no size or\n * kind axis. Its trailing arrow is bd-arrow-icon, an atom.\n */\n@defineElement(\"bd-contact-button\")\nclass ContactButton extends LitElement {\n static styles = [buttonsCSS];\n\n @property({ type: String })\n label = \"Contact us\";\n @property({ type: String })\n href = \"\";\n @property({ type: String })\n align: Align = \"left\";\n @property({ type: String, reflect: true })\n shape: Shape = \"default\";\n\n _handleClick() {\n this.dispatchEvent(clickEvent());\n }\n\n render() {\n return html`\n <a\n class=\"button bd-contact-btn ${this.shape === \"rounded\" ? \"button--rounded\" : \"\"}\"\n href=\"${this.href || nothing}\"\n aria-label=\"${this.label || nothing}\"\n @click=${this._handleClick}\n >\n ${this.label}\n <bd-arrow-icon aria-hidden=\"true\"></bd-arrow-icon>\n </a>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-button\" : Button;\n \"bd-button-link\" : ButtonLink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A4B,EAAc,mBAAmB,CAAA,EAAAG,CAAA"}
|
|
@@ -1,30 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
/** Styled entirely from design tokens — see npm run lint:tokens. */
|
|
3
|
-
export const captionCSS = css `
|
|
4
|
-
:host { display: block; }
|
|
5
|
-
|
|
6
|
-
figcaption {
|
|
7
|
-
font-family: var(--typography-caption-default-fontFamily);
|
|
8
|
-
font-size: var(--typography-caption-default-fontSize);
|
|
9
|
-
font-weight: var(--typography-caption-default-fontWeight);
|
|
10
|
-
line-height: var(--typography-caption-default-lineHeight);
|
|
11
|
-
letter-spacing: var(--typography-caption-default-letterSpacing);
|
|
12
|
-
color: var(--typography-caption-default-color);
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/* sm takes the caption-small role whole. Today it differs from
|
|
16
|
-
caption-default in tracking alone -- 0.025em against 0, the design's
|
|
17
|
-
caption/small -- so reading only letter-spacing drew the same thing, but
|
|
18
|
-
left the role's other four axes unread, and a change to any of them would
|
|
19
|
-
never have reached the element. The colour stays the default's: the role
|
|
20
|
-
carries none of its own. */
|
|
21
|
-
:host([size='sm']) figcaption {
|
|
22
|
-
font-family: var(--typography-caption-small-fontFamily);
|
|
23
|
-
font-size: var(--typography-caption-small-fontSize);
|
|
24
|
-
font-weight: var(--typography-caption-small-fontWeight);
|
|
25
|
-
line-height: var(--typography-caption-small-lineHeight);
|
|
26
|
-
letter-spacing: var(--typography-caption-small-letterSpacing);
|
|
27
|
-
}
|
|
28
|
-
`;
|
|
29
|
-
export default captionCSS;
|
|
1
|
+
import{css as e}from"lit";var t=e`:host{display:block}figcaption{font-family:var(--typography-caption-default-fontFamily);font-size:var(--typography-caption-default-fontSize);font-weight:var(--typography-caption-default-fontWeight);line-height:var(--typography-caption-default-lineHeight);letter-spacing:var(--typography-caption-default-letterSpacing);color:var(--typography-caption-default-color)}:host([size=sm]) figcaption{font-family:var(--typography-caption-small-fontFamily);font-size:var(--typography-caption-small-fontSize);font-weight:var(--typography-caption-small-fontWeight);line-height:var(--typography-caption-small-lineHeight);letter-spacing:var(--typography-caption-small-letterSpacing)}`;export{t as captionCSS,t as default};
|
|
30
2
|
//# sourceMappingURL=caption.css.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"caption.css.js","
|
|
1
|
+
{"version":3,"file":"caption.css.js","names":["captionCSS"],"sources":["../../../../src/components/caption/caption.css.ts"],"sourcesContent":["import { css } from 'lit';\n\n/** Styled entirely from design tokens — see npm run lint:tokens. */\nexport const captionCSS = css`\n :host { display: block; }\n\n figcaption {\n font-family: var(--typography-caption-default-fontFamily);\n font-size: var(--typography-caption-default-fontSize);\n font-weight: var(--typography-caption-default-fontWeight);\n line-height: var(--typography-caption-default-lineHeight);\n letter-spacing: var(--typography-caption-default-letterSpacing);\n color: var(--typography-caption-default-color);\n }\n\n /* sm takes the caption-small role whole. Today it differs from\n caption-default in tracking alone -- 0.025em against 0, the design's\n caption/small -- so reading only letter-spacing drew the same thing, but\n left the role's other four axes unread, and a change to any of them would\n never have reached the element. The colour stays the default's: the role\n carries none of its own. */\n :host([size='sm']) figcaption {\n font-family: var(--typography-caption-small-fontFamily);\n font-size: var(--typography-caption-small-fontSize);\n font-weight: var(--typography-caption-small-fontWeight);\n line-height: var(--typography-caption-small-lineHeight);\n letter-spacing: var(--typography-caption-small-letterSpacing);\n }\n`;\n\nexport default captionCSS;\n"],"mappings":"A,0BAGA,IAAaA,EAAa,CAAG,gqB"}
|