scb-wc 0.1.264 → 0.1.266
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/README.md +16 -19
- package/_virtual/{_@oxc-project_runtime@0.139.0 → _@oxc-project_runtime@0.160.0}/helpers/esm/decorate.js +1 -2
- package/all.d.ts +0 -95
- package/all.js +0 -95
- package/bin/scb-wc.mjs +5 -1
- package/component-defaults.js +2 -2
- package/index.js +16 -111
- package/mvc/components/all.js +0 -95
- package/mvc/components/scb-breadcrumb/scb-breadcrumb-item.js +1 -1
- package/mvc/components/scb-breadcrumb/scb-breadcrumb.js +4 -4
- package/mvc/components/scb-button/scb-button.js +3 -3
- package/mvc/components/scb-divider/scb-divider.js +1 -1
- package/mvc/components/scb-icon-button/scb-icon-button.js +8 -8
- package/mvc/components/scb-link/scb-link.js +2 -2
- package/mvc/components/scb-link-button/scb-link-button.js +3 -3
- package/mvc/components/scb-options-menu/scb-options-menu-item.js +2 -2
- package/mvc/components/scb-options-menu/scb-options-menu.js +3 -3
- package/mvc/components/scb-options-menu/scb-options-sub-menu.js +2 -2
- package/mvc/components/scb-segmented-button/scb-segmented-button.js +1 -1
- package/mvc/components/scb-segmented-button/scb-segmented-item.js +2 -2
- package/mvc/components/scb-tabs/scb-primary-tab.js +2 -2
- package/mvc/components/scb-tabs/scb-secondary-tab.js +2 -2
- package/mvc/components/scb-tabs/scb-tabs.js +4 -4
- package/mvc/vendor/aria-references.internal.js +1 -1
- package/mvc/vendor/component-defaults.js +1 -1
- package/mvc/vendor/icon.js +2 -2
- package/mvc/vendor/lazy-focus-ring.js +2 -0
- package/mvc/vendor/lazy-ripple.js +2 -0
- package/mvc/vendor/md-focus-ring.js +2 -2
- package/mvc/vendor/preload-helper.js +1 -1
- package/mvc/vendor/ripple.js +2 -2
- package/mvc/vendor/rolldown-runtime.js +1 -1
- package/mvc/vendor/tab-styles.js +7 -6
- package/mvc/vendor/vendor.js +3 -3
- package/package.json +2 -427
- package/scb-breadcrumb/scb-breadcrumb-item.js +11 -15
- package/scb-breadcrumb/scb-breadcrumb.js +37 -38
- package/scb-button/scb-button.js +67 -76
- package/scb-components/scb-link/scb-link.d.ts +1 -0
- package/scb-divider/scb-divider.js +14 -15
- package/scb-icon-button/scb-icon-button.js +48 -57
- package/scb-link/scb-link.js +57 -35
- package/scb-link-button/scb-link-button.js +29 -30
- package/scb-options-menu/scb-options-menu-item.js +26 -37
- package/scb-options-menu/scb-options-menu.js +31 -42
- package/scb-options-menu/scb-options-sub-menu.js +28 -29
- package/scb-segmented-button/scb-segmented-button.js +26 -30
- package/scb-segmented-button/scb-segmented-item.js +20 -21
- package/scb-tabs/scb-primary-tab.js +12 -16
- package/scb-tabs/scb-secondary-tab.js +11 -15
- package/scb-tabs/scb-tabs.js +14 -15
- package/scb-wc.bundle.js +1639 -20889
- package/scb-wc.d.ts +0 -190
- package/shared/aria-references.internal.js +2 -9
- package/shared/lazy-focus-ring.js +1 -2
- package/shared/lazy-ripple.js +2 -3
- package/shared/manual-popover.js +2 -15
- package/mvc/components/scb-accordion/scb-accordion-item.js +0 -48
- package/mvc/components/scb-accordion/scb-accordion.js +0 -16
- package/mvc/components/scb-action-card/scb-action-card.js +0 -1
- package/mvc/components/scb-app-bar/scb-app-bar.js +0 -18
- package/mvc/components/scb-avatar/scb-avatar.js +0 -35
- package/mvc/components/scb-badge/scb-badge.js +0 -10
- package/mvc/components/scb-calendar/scb-calendar-event.js +0 -2
- package/mvc/components/scb-calendar/scb-calendar.js +0 -63
- package/mvc/components/scb-calendar-card/scb-calendar-card.js +0 -41
- package/mvc/components/scb-card/scb-action-card.js +0 -1
- package/mvc/components/scb-card/scb-card.js +0 -96
- package/mvc/components/scb-card/scb-container-card.js +0 -1
- package/mvc/components/scb-card/scb-link-card.js +0 -1
- package/mvc/components/scb-card/scb-list-card.js +0 -1
- package/mvc/components/scb-card/scb-social-card.js +0 -1
- package/mvc/components/scb-checkbox/scb-checkbox-group.js +0 -20
- package/mvc/components/scb-checkbox/scb-checkbox.js +0 -51
- package/mvc/components/scb-chevron/scb-chevron.js +0 -10
- package/mvc/components/scb-chip/scb-chip.js +0 -31
- package/mvc/components/scb-collapse/scb-collapse.js +0 -62
- package/mvc/components/scb-container-card/scb-container-card.js +0 -1
- package/mvc/components/scb-cookies-consent/scb-cookies-consent.js +0 -12
- package/mvc/components/scb-datepicker/scb-datepicker.js +0 -143
- package/mvc/components/scb-dialog/scb-dialog.js +0 -67
- package/mvc/components/scb-drawer/scb-drawer.js +0 -41
- package/mvc/components/scb-drop-zone/scb-drop-zone.js +0 -156
- package/mvc/components/scb-dropdown/scb-dropdown.js +0 -89
- package/mvc/components/scb-fact-card/scb-fact-card-content.js +0 -24
- package/mvc/components/scb-fact-card/scb-fact-card.js +0 -24
- package/mvc/components/scb-footer/scb-footer-section.js +0 -1
- package/mvc/components/scb-footer/scb-footer.js +0 -62
- package/mvc/components/scb-form-error-summary/scb-form-error-summary.js +0 -24
- package/mvc/components/scb-gallery-grid/scb-gallery-grid.js +0 -27
- package/mvc/components/scb-grid/scb-grid-item.js +0 -1
- package/mvc/components/scb-grid/scb-grid.js +0 -1
- package/mvc/components/scb-grid/scb-stack.js +0 -1
- package/mvc/components/scb-header/scb-header-menu-group.js +0 -1
- package/mvc/components/scb-header/scb-header-menu-item.js +0 -1
- package/mvc/components/scb-header/scb-header-tab.js +0 -1
- package/mvc/components/scb-header/scb-header-utility.js +0 -1
- package/mvc/components/scb-header/scb-header.js +0 -351
- package/mvc/components/scb-horizontal-scroller/scb-horizontal-scroller.js +0 -61
- package/mvc/components/scb-icon/scb-icon.js +0 -9
- package/mvc/components/scb-keyfigure-card/scb-keyfigure-card.js +0 -43
- package/mvc/components/scb-link-card/scb-link-card.js +0 -1
- package/mvc/components/scb-list/scb-list-item.js +0 -58
- package/mvc/components/scb-list/scb-list.js +0 -5
- package/mvc/components/scb-list-card/scb-list-card.js +0 -1
- package/mvc/components/scb-menu/scb-menu-item.js +0 -80
- package/mvc/components/scb-menu/scb-menu-section.js +0 -8
- package/mvc/components/scb-menu/scb-menu.js +0 -18
- package/mvc/components/scb-menu/scb-sub-menu.js +0 -5
- package/mvc/components/scb-nav/scb-nav-item.js +0 -1
- package/mvc/components/scb-nav/scb-nav.js +0 -39
- package/mvc/components/scb-notification-card/scb-notification-card.js +0 -45
- package/mvc/components/scb-overlay/scb-overlay.js +0 -9
- package/mvc/components/scb-pagination/scb-pagination.js +0 -104
- package/mvc/components/scb-progress-indicator/scb-progress-indicator.js +0 -21
- package/mvc/components/scb-progress-stepper/scb-progress-step.js +0 -44
- package/mvc/components/scb-progress-stepper/scb-progress-stepper.js +0 -13
- package/mvc/components/scb-radio-button/scb-radio-button.js +0 -52
- package/mvc/components/scb-radio-button/scb-radio-group.js +0 -20
- package/mvc/components/scb-scrollspy/scb-scrollspy.js +0 -20
- package/mvc/components/scb-search/scb-search.js +0 -57
- package/mvc/components/scb-select/scb-select-option.js +0 -19
- package/mvc/components/scb-select/scb-select.js +0 -91
- package/mvc/components/scb-skeleton/scb-skeleton.js +0 -5
- package/mvc/components/scb-slider/scb-slider.js +0 -84
- package/mvc/components/scb-snackbar/scb-snackbar.js +0 -71
- package/mvc/components/scb-social-card/scb-social-card.js +0 -1
- package/mvc/components/scb-status-pill/scb-status-pill.js +0 -4
- package/mvc/components/scb-stepper/scb-step.js +0 -70
- package/mvc/components/scb-stepper/scb-stepper.js +0 -11
- package/mvc/components/scb-switch/scb-switch.js +0 -71
- package/mvc/components/scb-table/scb-table.js +0 -5
- package/mvc/components/scb-table-advanced/scb-table-advanced.js +0 -26
- package/mvc/components/scb-table-next/read-table.js +0 -1
- package/mvc/components/scb-table-next/scb-table-next.js +0 -6
- package/mvc/components/scb-textfield/scb-textfield.js +0 -244
- package/mvc/components/scb-toc/scb-toc-item.js +0 -56
- package/mvc/components/scb-toc/scb-toc.js +0 -7
- package/mvc/components/scb-tooltip/scb-tooltip.js +0 -46
- package/mvc/components/scb-tour/scb-tour-step.js +0 -1
- package/mvc/components/scb-tour/scb-tour.js +0 -33
- package/mvc/components/scb-viz/scb-viz-actions-runtime.js +0 -2
- package/mvc/components/scb-viz/scb-viz-print-runtime.js +0 -134
- package/mvc/components/scb-viz/scb-viz-series-differentiation-registry.js +0 -1
- package/mvc/components/scb-viz/scb-viz-series-differentiation-runtime.js +0 -1
- package/mvc/components/scb-viz/scb-viz-table-runtime.js +0 -1
- package/mvc/components/scb-viz/scb-viz.js +0 -385
- package/mvc/components/shared/component-size-token.js +0 -1
- package/mvc/components/shared/lazy-focus-ring.js +0 -2
- package/mvc/components/shared/lazy-ripple.js +0 -2
- package/mvc/components/shared/manual-popover.js +0 -1
- package/mvc/components/shared/scb-icon-svg.js +0 -11
- package/mvc/vendor/assist-chip.js +0 -20
- package/mvc/vendor/checkbox-validator.js +0 -1
- package/mvc/vendor/chip-set.js +0 -2
- package/mvc/vendor/chip.js +0 -18
- package/mvc/vendor/delegate.js +0 -1
- package/mvc/vendor/elevation.js +0 -2
- package/mvc/vendor/filter-chip.js +0 -43
- package/mvc/vendor/focusable.js +0 -1
- package/mvc/vendor/form-associated.js +0 -1
- package/mvc/vendor/redispatch-event.js +0 -1
- package/mvc/vendor/runtime-colors.js +0 -1
- package/mvc/vendor/scb-card-variants.internal.js +0 -353
- package/mvc/vendor/scb-header-drawer.internal.js +0 -73
- package/mvc/vendor/shared-styles.js +0 -3
- package/mvc/vendor/validator.js +0 -1
- package/scb-accordion/scb-accordion-item.js +0 -620
- package/scb-accordion/scb-accordion.js +0 -206
- package/scb-action-card/scb-action-card.js +0 -2
- package/scb-app-bar/scb-app-bar.js +0 -534
- package/scb-avatar/scb-avatar.js +0 -431
- package/scb-badge/scb-badge.js +0 -186
- package/scb-calendar/scb-calendar-event.js +0 -48
- package/scb-calendar/scb-calendar.js +0 -867
- package/scb-calendar-card/scb-calendar-card.js +0 -680
- package/scb-card/scb-action-card.js +0 -2
- package/scb-card/scb-card-variants.internal.js +0 -233
- package/scb-card/scb-card.js +0 -2031
- package/scb-card/scb-container-card.js +0 -2
- package/scb-card/scb-link-card.js +0 -2
- package/scb-card/scb-list-card.js +0 -2
- package/scb-card/scb-social-card.js +0 -2
- package/scb-checkbox/scb-checkbox-group.js +0 -258
- package/scb-checkbox/scb-checkbox.js +0 -422
- package/scb-chevron/scb-chevron.js +0 -61
- package/scb-chip/scb-chip.js +0 -352
- package/scb-collapse/scb-collapse.js +0 -453
- package/scb-components/index.d.ts +0 -110
- package/scb-components/scb-accordion/scb-accordion-item.d.ts +0 -43
- package/scb-components/scb-accordion/scb-accordion.d.ts +0 -32
- package/scb-components/scb-action-card/scb-action-card.d.ts +0 -2
- package/scb-components/scb-app-bar/scb-app-bar.d.ts +0 -39
- package/scb-components/scb-avatar/scb-avatar.d.ts +0 -43
- package/scb-components/scb-badge/scb-badge.d.ts +0 -28
- package/scb-components/scb-calendar/scb-calendar-event.d.ts +0 -15
- package/scb-components/scb-calendar/scb-calendar.d.ts +0 -89
- package/scb-components/scb-calendar-card/scb-calendar-card.d.ts +0 -60
- package/scb-components/scb-card/scb-action-card.d.ts +0 -2
- package/scb-components/scb-card/scb-card.d.ts +0 -163
- package/scb-components/scb-card/scb-container-card.d.ts +0 -2
- package/scb-components/scb-card/scb-link-card.d.ts +0 -2
- package/scb-components/scb-card/scb-list-card.d.ts +0 -2
- package/scb-components/scb-card/scb-social-card.d.ts +0 -2
- package/scb-components/scb-checkbox/scb-checkbox-group.d.ts +0 -48
- package/scb-components/scb-checkbox/scb-checkbox.d.ts +0 -63
- package/scb-components/scb-chevron/scb-chevron.d.ts +0 -11
- package/scb-components/scb-chip/scb-chip.d.ts +0 -57
- package/scb-components/scb-collapse/scb-collapse.d.ts +0 -41
- package/scb-components/scb-container-card/scb-container-card.d.ts +0 -2
- package/scb-components/scb-cookies-consent/scb-cookies-consent.d.ts +0 -28
- package/scb-components/scb-datepicker/scb-datepicker.d.ts +0 -52
- package/scb-components/scb-dialog/scb-dialog.d.ts +0 -121
- package/scb-components/scb-drawer/scb-drawer.d.ts +0 -83
- package/scb-components/scb-drop-zone/scb-drop-zone.d.ts +0 -193
- package/scb-components/scb-dropdown/scb-dropdown.d.ts +0 -91
- package/scb-components/scb-fact-card/scb-fact-card-content.d.ts +0 -18
- package/scb-components/scb-fact-card/scb-fact-card.d.ts +0 -55
- package/scb-components/scb-footer/scb-footer-section.d.ts +0 -20
- package/scb-components/scb-footer/scb-footer.d.ts +0 -36
- package/scb-components/scb-form-error-summary/scb-form-error-summary.d.ts +0 -23
- package/scb-components/scb-gallery-grid/scb-gallery-grid.d.ts +0 -25
- package/scb-components/scb-grid/scb-grid-item.d.ts +0 -32
- package/scb-components/scb-grid/scb-grid.d.ts +0 -41
- package/scb-components/scb-grid/scb-stack.d.ts +0 -32
- package/scb-components/scb-header/scb-header-menu-group.d.ts +0 -12
- package/scb-components/scb-header/scb-header-menu-item.d.ts +0 -15
- package/scb-components/scb-header/scb-header-tab.d.ts +0 -15
- package/scb-components/scb-header/scb-header-utility.d.ts +0 -17
- package/scb-components/scb-header/scb-header.d.ts +0 -184
- package/scb-components/scb-horizontal-scroller/scb-horizontal-scroller.d.ts +0 -68
- package/scb-components/scb-icon/scb-icon.d.ts +0 -19
- package/scb-components/scb-keyfigure-card/scb-keyfigure-card.d.ts +0 -58
- package/scb-components/scb-link-card/scb-link-card.d.ts +0 -2
- package/scb-components/scb-list/scb-list-item.d.ts +0 -65
- package/scb-components/scb-list/scb-list.d.ts +0 -30
- package/scb-components/scb-list-card/scb-list-card.d.ts +0 -2
- package/scb-components/scb-menu/scb-menu-item.d.ts +0 -65
- package/scb-components/scb-menu/scb-menu-section.d.ts +0 -12
- package/scb-components/scb-menu/scb-menu.d.ts +0 -54
- package/scb-components/scb-menu/scb-sub-menu.d.ts +0 -14
- package/scb-components/scb-nav/scb-nav-item.d.ts +0 -20
- package/scb-components/scb-nav/scb-nav.d.ts +0 -72
- package/scb-components/scb-notification-card/scb-notification-card.d.ts +0 -56
- package/scb-components/scb-overlay/scb-overlay.d.ts +0 -24
- package/scb-components/scb-pagination/scb-pagination.d.ts +0 -47
- package/scb-components/scb-progress-indicator/scb-progress-indicator.d.ts +0 -32
- package/scb-components/scb-progress-stepper/scb-progress-step.d.ts +0 -29
- package/scb-components/scb-progress-stepper/scb-progress-stepper.d.ts +0 -29
- package/scb-components/scb-radio-button/scb-radio-button.d.ts +0 -24
- package/scb-components/scb-radio-button/scb-radio-group.d.ts +0 -54
- package/scb-components/scb-scrollspy/scb-scrollspy.d.ts +0 -217
- package/scb-components/scb-search/scb-search.d.ts +0 -116
- package/scb-components/scb-select/scb-select-option.d.ts +0 -20
- package/scb-components/scb-select/scb-select.d.ts +0 -95
- package/scb-components/scb-skeleton/scb-skeleton.d.ts +0 -36
- package/scb-components/scb-slider/scb-slider.d.ts +0 -64
- package/scb-components/scb-snackbar/scb-snackbar.d.ts +0 -28
- package/scb-components/scb-social-card/scb-social-card.d.ts +0 -2
- package/scb-components/scb-status-pill/scb-status-pill.d.ts +0 -23
- package/scb-components/scb-stepper/scb-step.d.ts +0 -31
- package/scb-components/scb-stepper/scb-stepper.d.ts +0 -50
- package/scb-components/scb-switch/scb-switch.d.ts +0 -65
- package/scb-components/scb-table/scb-table.d.ts +0 -41
- package/scb-components/scb-table-advanced/scb-table-advanced.d.ts +0 -58
- package/scb-components/scb-table-next/read-table.d.ts +0 -29
- package/scb-components/scb-table-next/scb-table-next.d.ts +0 -22
- package/scb-components/scb-textfield/scb-textfield.d.ts +0 -107
- package/scb-components/scb-toc/scb-toc-item.d.ts +0 -44
- package/scb-components/scb-toc/scb-toc.d.ts +0 -30
- package/scb-components/scb-tooltip/scb-tooltip.d.ts +0 -72
- package/scb-components/scb-tour/scb-tour-step.d.ts +0 -13
- package/scb-components/scb-tour/scb-tour.d.ts +0 -57
- package/scb-components/scb-viz/scb-viz-actions-runtime.d.ts +0 -26
- package/scb-components/scb-viz/scb-viz-print-runtime.d.ts +0 -36
- package/scb-components/scb-viz/scb-viz-series-differentiation-registry.d.ts +0 -21
- package/scb-components/scb-viz/scb-viz-series-differentiation-runtime.d.ts +0 -42
- package/scb-components/scb-viz/scb-viz-table-runtime.d.ts +0 -31
- package/scb-components/scb-viz/scb-viz.d.ts +0 -249
- package/scb-components/shared/component-size-token.d.ts +0 -1
- package/scb-components/shared/lazy-focus-ring.d.ts +0 -4
- package/scb-components/shared/lazy-ripple.d.ts +0 -9
- package/scb-components/shared/manual-popover.d.ts +0 -7
- package/scb-components/shared/scb-icon-svg.d.ts +0 -3
- package/scb-container-card/scb-container-card.js +0 -1
- package/scb-cookies-consent/scb-cookies-consent.js +0 -257
- package/scb-datepicker/scb-datepicker.js +0 -670
- package/scb-dialog/scb-dialog.js +0 -970
- package/scb-drawer/scb-drawer.js +0 -394
- package/scb-drop-zone/scb-drop-zone.js +0 -1259
- package/scb-dropdown/scb-dropdown.js +0 -840
- package/scb-fact-card/scb-fact-card-content.js +0 -236
- package/scb-fact-card/scb-fact-card.js +0 -441
- package/scb-footer/scb-footer-section.js +0 -23
- package/scb-footer/scb-footer.js +0 -402
- package/scb-form-error-summary/scb-form-error-summary.js +0 -179
- package/scb-gallery-grid/scb-gallery-grid.js +0 -312
- package/scb-grid/scb-grid-item.js +0 -107
- package/scb-grid/scb-grid.js +0 -206
- package/scb-grid/scb-stack.js +0 -134
- package/scb-header/scb-header-drawer.internal.js +0 -80
- package/scb-header/scb-header-menu-group.js +0 -21
- package/scb-header/scb-header-menu-item.js +0 -28
- package/scb-header/scb-header-tab.js +0 -31
- package/scb-header/scb-header-utility.js +0 -36
- package/scb-header/scb-header.js +0 -2541
- package/scb-horizontal-scroller/scb-horizontal-scroller.js +0 -494
- package/scb-icon/scb-icon.js +0 -108
- package/scb-keyfigure-card/scb-keyfigure-card.js +0 -599
- package/scb-link-card/scb-link-card.js +0 -1
- package/scb-list/scb-list-item.js +0 -650
- package/scb-list/scb-list.js +0 -162
- package/scb-list-card/scb-list-card.js +0 -1
- package/scb-menu/scb-menu-item.js +0 -497
- package/scb-menu/scb-menu-section.js +0 -77
- package/scb-menu/scb-menu.js +0 -313
- package/scb-menu/scb-sub-menu.js +0 -36
- package/scb-nav/scb-nav-item.js +0 -96
- package/scb-nav/scb-nav.js +0 -551
- package/scb-notification-card/scb-notification-card.js +0 -675
- package/scb-overlay/scb-overlay.js +0 -229
- package/scb-pagination/scb-pagination.js +0 -549
- package/scb-progress-indicator/scb-progress-indicator.js +0 -224
- package/scb-progress-stepper/scb-progress-step.js +0 -256
- package/scb-progress-stepper/scb-progress-stepper.js +0 -166
- package/scb-radio-button/scb-radio-button.js +0 -276
- package/scb-radio-button/scb-radio-group.js +0 -287
- package/scb-scrollspy/scb-scrollspy.js +0 -683
- package/scb-search/scb-search.js +0 -1075
- package/scb-select/scb-select-option.js +0 -245
- package/scb-select/scb-select.js +0 -1150
- package/scb-skeleton/scb-skeleton.js +0 -133
- package/scb-slider/scb-slider.js +0 -278
- package/scb-snackbar/scb-snackbar.js +0 -316
- package/scb-social-card/scb-social-card.js +0 -1
- package/scb-status-pill/scb-status-pill.js +0 -132
- package/scb-stepper/scb-step.js +0 -529
- package/scb-stepper/scb-stepper.js +0 -558
- package/scb-switch/scb-switch.js +0 -338
- package/scb-table/scb-table.js +0 -339
- package/scb-table-advanced/scb-table-advanced.js +0 -474
- package/scb-table-next/read-table.js +0 -87
- package/scb-table-next/scb-table-next.js +0 -226
- package/scb-textfield/scb-textfield.js +0 -1158
- package/scb-toc/scb-toc-item.js +0 -477
- package/scb-toc/scb-toc.js +0 -116
- package/scb-tooltip/scb-tooltip.js +0 -518
- package/scb-tour/scb-tour-step.js +0 -27
- package/scb-tour/scb-tour.js +0 -368
- package/scb-viz/scb-viz-actions-runtime.js +0 -144
- package/scb-viz/scb-viz-print-runtime.js +0 -173
- package/scb-viz/scb-viz-series-differentiation-registry.js +0 -117
- package/scb-viz/scb-viz-series-differentiation-runtime.js +0 -126
- package/scb-viz/scb-viz-table-runtime.js +0 -154
- package/scb-viz/scb-viz.js +0 -1966
- package/shared/component-size-token.js +0 -7
- package/shared/scb-icon-svg.js +0 -36
- package/starters/html/README.md +0 -24
- package/starters/html/dot-gitignore +0 -2
- package/starters/html/index.html +0 -12
- package/starters/html/main.js +0 -96
- package/starters/html/package.json +0 -16
- package/starters/html-service/README.md +0 -25
- package/starters/html-service/dot-gitignore +0 -2
- package/starters/html-service/index.html +0 -12
- package/starters/html-service/main.js +0 -79
- package/starters/html-service/package.json +0 -16
- package/starters/react/README.md +0 -24
- package/starters/react/dot-gitignore +0 -2
- package/starters/react/index.html +0 -12
- package/starters/react/package.json +0 -19
- package/starters/react/src/App.jsx +0 -85
- package/starters/react/src/main.jsx +0 -23
- package/starters/react/vite.config.js +0 -6
- package/starters/react-service/README.md +0 -25
- package/starters/react-service/dot-gitignore +0 -2
- package/starters/react-service/index.html +0 -12
- package/starters/react-service/package.json +0 -19
- package/starters/react-service/src/App.jsx +0 -67
- package/starters/react-service/src/main.jsx +0 -23
- package/starters/react-service/vite.config.js +0 -6
- package/tokens/generated/runtime-colors.js +0 -12
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
|
|
1
|
+
import { LitElement as e, css as t, html as n, nothing as r } from "lit";
|
|
2
|
+
import { customElement as i, property as a } from "lit/decorators.js";
|
|
3
|
+
import { forwardAriaReferences as o } from "../shared/aria-references.internal.js";
|
|
4
|
+
import { componentDefaults as s } from "../component-defaults.js";
|
|
5
|
+
import c from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
6
|
+
// src/scb-components/scb-icon-button/scb-icon-button.ts
|
|
7
7
|
var l = [
|
|
8
8
|
"aria-expanded",
|
|
9
9
|
"aria-disabled",
|
|
@@ -16,9 +16,9 @@ function f() {
|
|
|
16
16
|
function p() {
|
|
17
17
|
return d ??= import("../shared/lazy-ripple.js"), d;
|
|
18
18
|
}
|
|
19
|
-
var m = class extends
|
|
20
|
-
constructor(...
|
|
21
|
-
super(...
|
|
19
|
+
var m = class extends e {
|
|
20
|
+
constructor(...e) {
|
|
21
|
+
super(...e), this.icon = "home", this.ariaLabel = "", this.variant = "standard", this.size = s["scb-icon-button"].size, this.toggle = !1, this.selected = !1, this.toggleofficon = "add", this.toggleonicon = "remove", this.disabled = !1, this.href = "", this.target = "", this.rel = "", this.__filledValue = !1, this.__focusRingReady = !1, this.__focusRingImportRequested = !1, this.__rippleReady = !1, this.__pendingRippleClick = !1, this.__ensureFocusRing = () => {
|
|
22
22
|
this.__focusRingReady || this.__focusRingImportRequested || (this.__focusRingImportRequested = !0, f().then(({ ensureFocusRingReady: e }) => (e(), customElements.whenDefined("md-focus-ring"))).then(() => {
|
|
23
23
|
this.__focusRingReady = !0, this.toggleAttribute("data-native-focus-ring-ready", !0), this.requestUpdate(), this.updateComplete.then(() => this.__syncInteractiveState());
|
|
24
24
|
}));
|
|
@@ -32,15 +32,11 @@ var m = class extends r {
|
|
|
32
32
|
}, this.__onPointerInteraction = (e) => {
|
|
33
33
|
this.__ensureRipple(e);
|
|
34
34
|
}, this.__onClick = (e) => {
|
|
35
|
-
|
|
36
|
-
e.preventDefault(), e.stopPropagation();
|
|
37
|
-
return;
|
|
38
|
-
}
|
|
39
|
-
this.toggle && (this.selected = !this.selected, this.dispatchEvent(new CustomEvent("change", {
|
|
35
|
+
this.disabled ? (e.preventDefault(), e.stopPropagation()) : (this.toggle && (this.selected = !this.selected, this.dispatchEvent(new CustomEvent("change", {
|
|
40
36
|
detail: { selected: this.selected },
|
|
41
37
|
bubbles: !0,
|
|
42
38
|
composed: !0
|
|
43
|
-
}))), this.__ensureRipple(void 0, !0);
|
|
39
|
+
}))), this.__ensureRipple(void 0, !0));
|
|
44
40
|
};
|
|
45
41
|
}
|
|
46
42
|
get filled() {
|
|
@@ -68,16 +64,12 @@ var m = class extends r {
|
|
|
68
64
|
}
|
|
69
65
|
updated(e) {
|
|
70
66
|
super.updated(e);
|
|
71
|
-
let
|
|
72
|
-
|
|
67
|
+
let t = this.__getNativeControl();
|
|
68
|
+
t && o(this, t), (e.has("spacing") || e.has("spacingTop") || e.has("spacingBottom") || e.has("spacingLeft") || e.has("spacingRight")) && this.#e(), (this.__focusRingReady || this.__rippleReady) && this.updateComplete.then(() => this.__syncInteractiveState());
|
|
73
69
|
}
|
|
74
70
|
focus(e) {
|
|
75
71
|
let t = this.__getNativeControl();
|
|
76
|
-
|
|
77
|
-
t.focus(e);
|
|
78
|
-
return;
|
|
79
|
-
}
|
|
80
|
-
super.focus(e);
|
|
72
|
+
t ? t.focus(e) : super.focus(e);
|
|
81
73
|
}
|
|
82
74
|
__getNativeControl() {
|
|
83
75
|
return this.renderRoot.querySelector(".native-icon-button");
|
|
@@ -95,7 +87,7 @@ var m = class extends r {
|
|
|
95
87
|
await i(e, t, n, r), this.__syncInteractiveState();
|
|
96
88
|
}
|
|
97
89
|
__effectiveLabel() {
|
|
98
|
-
return (this.ariaLabel || this.getAttribute("aria-label") || "").trim() || this.__currentIcon() ||
|
|
90
|
+
return (this.ariaLabel || this.getAttribute("aria-label") || "").trim() || this.__currentIcon() || r;
|
|
99
91
|
}
|
|
100
92
|
__currentIcon() {
|
|
101
93
|
return this.toggle ? this.selected ? this.toggleonicon : this.toggleofficon : this.icon;
|
|
@@ -110,7 +102,7 @@ var m = class extends r {
|
|
|
110
102
|
t ? this.style.setProperty("--scb-icon-button-spacing-block-start", t) : this.style.removeProperty("--scb-icon-button-spacing-block-start"), n ? this.style.setProperty("--scb-icon-button-spacing-block-end", n) : this.style.removeProperty("--scb-icon-button-spacing-block-end"), r ? this.style.setProperty("--scb-icon-button-spacing-inline-start", r) : this.style.removeProperty("--scb-icon-button-spacing-inline-start"), i ? this.style.setProperty("--scb-icon-button-spacing-inline-end", i) : this.style.removeProperty("--scb-icon-button-spacing-inline-end");
|
|
111
103
|
}
|
|
112
104
|
static {
|
|
113
|
-
this.styles =
|
|
105
|
+
this.styles = t`
|
|
114
106
|
:host {
|
|
115
107
|
display: inline-flex;
|
|
116
108
|
margin-block-start: var(--scb-icon-button-spacing-block-start, 0);
|
|
@@ -357,20 +349,20 @@ var m = class extends r {
|
|
|
357
349
|
`;
|
|
358
350
|
}
|
|
359
351
|
__renderControl(e) {
|
|
360
|
-
let t = this.__effectiveLabel(),
|
|
361
|
-
return this.href ?
|
|
352
|
+
let t = this.__effectiveLabel(), i = this.getAttribute("aria-expanded") ?? r, a = this.getAttribute("aria-disabled") ?? r, o = this.toggle ? String(this.selected) : r, s = this.getAttribute("title") ?? r;
|
|
353
|
+
return this.href ? n`
|
|
362
354
|
<a
|
|
363
355
|
class="native-icon-button"
|
|
364
356
|
part="button"
|
|
365
|
-
href=${this.disabled ?
|
|
366
|
-
target=${this.target ||
|
|
367
|
-
rel=${this.rel ||
|
|
357
|
+
href=${this.disabled ? r : this.href}
|
|
358
|
+
target=${this.target || r}
|
|
359
|
+
rel=${this.rel || r}
|
|
368
360
|
title=${s}
|
|
369
361
|
aria-label=${t}
|
|
370
|
-
aria-expanded=${
|
|
371
|
-
aria-pressed=${
|
|
372
|
-
aria-disabled=${this.disabled ? "true" :
|
|
373
|
-
tabindex=${this.disabled ? "-1" :
|
|
362
|
+
aria-expanded=${i}
|
|
363
|
+
aria-pressed=${o}
|
|
364
|
+
aria-disabled=${this.disabled ? "true" : a}
|
|
365
|
+
tabindex=${this.disabled ? "-1" : r}
|
|
374
366
|
@click=${this.__onClick}
|
|
375
367
|
@focusin=${this.__onFocusIn}
|
|
376
368
|
@pointerenter=${this.__onPointerInteraction}
|
|
@@ -378,7 +370,7 @@ var m = class extends r {
|
|
|
378
370
|
>
|
|
379
371
|
${e}
|
|
380
372
|
</a>
|
|
381
|
-
` :
|
|
373
|
+
` : n`
|
|
382
374
|
<button
|
|
383
375
|
class="native-icon-button"
|
|
384
376
|
part="button"
|
|
@@ -386,9 +378,9 @@ var m = class extends r {
|
|
|
386
378
|
title=${s}
|
|
387
379
|
?disabled=${this.disabled}
|
|
388
380
|
aria-label=${t}
|
|
389
|
-
aria-expanded=${
|
|
390
|
-
aria-disabled=${
|
|
391
|
-
aria-pressed=${
|
|
381
|
+
aria-expanded=${i}
|
|
382
|
+
aria-disabled=${a}
|
|
383
|
+
aria-pressed=${o}
|
|
392
384
|
@click=${this.__onClick}
|
|
393
385
|
@focusin=${this.__onFocusIn}
|
|
394
386
|
@pointerenter=${this.__onPointerInteraction}
|
|
@@ -399,60 +391,59 @@ var m = class extends r {
|
|
|
399
391
|
`;
|
|
400
392
|
}
|
|
401
393
|
render() {
|
|
402
|
-
let e =
|
|
403
|
-
return
|
|
394
|
+
let e = this.__currentIcon(), t = n`<span class="native-icon" part="icon" aria-hidden="true">${e}</span>`;
|
|
395
|
+
return n`
|
|
404
396
|
<span class="native-icon-button-wrap">
|
|
405
|
-
${this.__renderControl(
|
|
406
|
-
${this.__rippleReady ?
|
|
407
|
-
${this.__focusRingReady ?
|
|
397
|
+
${this.__renderControl(t)}
|
|
398
|
+
${this.__rippleReady ? n`<md-ripple aria-hidden="true"></md-ripple>` : r}
|
|
399
|
+
${this.__focusRingReady ? n`<md-focus-ring aria-hidden="true"></md-focus-ring>` : r}
|
|
408
400
|
</span>
|
|
409
401
|
`;
|
|
410
402
|
}
|
|
411
403
|
};
|
|
412
|
-
|
|
404
|
+
c([a({ type: String })], m.prototype, "icon", void 0), c([a({
|
|
413
405
|
type: Boolean,
|
|
414
406
|
reflect: !0
|
|
415
|
-
})], m.prototype, "filled", null),
|
|
407
|
+
})], m.prototype, "filled", null), c([a({
|
|
416
408
|
type: Boolean,
|
|
417
409
|
attribute: "icon-filled",
|
|
418
410
|
reflect: !0
|
|
419
|
-
})], m.prototype, "iconFilled", null),
|
|
411
|
+
})], m.prototype, "iconFilled", null), c([a({
|
|
420
412
|
type: String,
|
|
421
413
|
attribute: "aria-label"
|
|
422
|
-
})], m.prototype, "ariaLabel", void 0),
|
|
414
|
+
})], m.prototype, "ariaLabel", void 0), c([a({
|
|
423
415
|
type: String,
|
|
424
416
|
reflect: !0
|
|
425
|
-
})], m.prototype, "variant", void 0),
|
|
417
|
+
})], m.prototype, "variant", void 0), c([a({
|
|
426
418
|
type: String,
|
|
427
419
|
reflect: !0
|
|
428
|
-
})], m.prototype, "size", void 0),
|
|
420
|
+
})], m.prototype, "size", void 0), c([a({
|
|
429
421
|
type: Boolean,
|
|
430
422
|
reflect: !0
|
|
431
|
-
})], m.prototype, "toggle", void 0),
|
|
423
|
+
})], m.prototype, "toggle", void 0), c([a({
|
|
432
424
|
type: Boolean,
|
|
433
425
|
reflect: !0
|
|
434
|
-
})], m.prototype, "selected", void 0),
|
|
426
|
+
})], m.prototype, "selected", void 0), c([a({ type: String })], m.prototype, "toggleofficon", void 0), c([a({ type: String })], m.prototype, "toggleonicon", void 0), c([a({
|
|
435
427
|
type: Boolean,
|
|
436
428
|
reflect: !0
|
|
437
|
-
})], m.prototype, "disabled", void 0),
|
|
429
|
+
})], m.prototype, "disabled", void 0), c([a({
|
|
438
430
|
type: String,
|
|
439
431
|
reflect: !0
|
|
440
|
-
})], m.prototype, "spacing", void 0),
|
|
432
|
+
})], m.prototype, "spacing", void 0), c([a({
|
|
441
433
|
type: String,
|
|
442
434
|
attribute: "spacing-top",
|
|
443
435
|
reflect: !0
|
|
444
|
-
})], m.prototype, "spacingTop", void 0),
|
|
436
|
+
})], m.prototype, "spacingTop", void 0), c([a({
|
|
445
437
|
type: String,
|
|
446
438
|
attribute: "spacing-bottom",
|
|
447
439
|
reflect: !0
|
|
448
|
-
})], m.prototype, "spacingBottom", void 0),
|
|
440
|
+
})], m.prototype, "spacingBottom", void 0), c([a({
|
|
449
441
|
type: String,
|
|
450
442
|
attribute: "spacing-left",
|
|
451
443
|
reflect: !0
|
|
452
|
-
})], m.prototype, "spacingLeft", void 0),
|
|
444
|
+
})], m.prototype, "spacingLeft", void 0), c([a({
|
|
453
445
|
type: String,
|
|
454
446
|
attribute: "spacing-right",
|
|
455
447
|
reflect: !0
|
|
456
|
-
})], m.prototype, "spacingRight", void 0),
|
|
457
|
-
//#endregion
|
|
448
|
+
})], m.prototype, "spacingRight", void 0), c([a({ type: String })], m.prototype, "href", void 0), c([a({ type: String })], m.prototype, "target", void 0), c([a({ type: String })], m.prototype, "rel", void 0), m = c([i("scb-icon-button")], m);
|
|
458
449
|
export { m as ScbIconButton };
|
package/scb-link/scb-link.js
CHANGED
|
@@ -1,28 +1,30 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i } from "lit/decorators.js";
|
|
3
|
+
import { ifDefined as a } from "lit/directives/if-defined.js";
|
|
4
|
+
import { ensureFocusRingOnFocusVisible as o } from "../shared/lazy-focus-ring.js";
|
|
5
|
+
import { componentDefaults as s } from "../component-defaults.js";
|
|
6
|
+
import c from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
7
|
+
// src/scb-components/scb-link/scb-link.ts
|
|
8
|
+
var l = class extends e {
|
|
9
|
+
constructor(...e) {
|
|
10
|
+
super(...e), this.href = "", this.disabled = !1, this.ariaLabel = "", this.size = s["scb-link"].size, this.spacing = void 0, this.spacingTop = void 0, this.spacingBottom = void 0, this.spacingLeft = void 0, this.spacingRight = void 0, this.#t = (e) => {
|
|
11
|
+
o(e);
|
|
12
|
+
let t = e.composedPath()[0];
|
|
13
|
+
t instanceof HTMLElement && t.matches(":focus-visible") && customElements.whenDefined("md-focus-ring").then(() => {
|
|
13
14
|
this.toggleAttribute("data-native-focus-ring-ready", !0);
|
|
14
15
|
let e = this.renderRoot.querySelector("md-focus-ring");
|
|
15
|
-
e.visible =
|
|
16
|
+
e.visible = t.matches(":focus-visible");
|
|
16
17
|
});
|
|
17
18
|
}, this.#n = (e) => {
|
|
18
19
|
this.disabled && (e.preventDefault(), e.stopPropagation());
|
|
19
20
|
};
|
|
20
21
|
}
|
|
21
22
|
static {
|
|
22
|
-
this.styles =
|
|
23
|
+
this.styles = t`
|
|
23
24
|
/*
|
|
24
25
|
Designstyrning:
|
|
25
26
|
- scb-link är en textlänk och ärver normalt font-size, line-height, tracking och weight från texten runt omkring.
|
|
27
|
+
- size väljer body-small, body-medium eller body-large. CSS-överstyrningar har fortsatt företräde.
|
|
26
28
|
- Länkfärg och understreck följer länktokens i src/tokens/source/typography.json och grundtokens i src/tokens/source/sizing.json.
|
|
27
29
|
- spacing-attributen är API-val per användning och ska inte bli en global länkstorlek.
|
|
28
30
|
*/
|
|
@@ -42,6 +44,24 @@ var c = class extends n {
|
|
|
42
44
|
margin-inline-end: var(--scb-link-spacing-inline-end, 0);
|
|
43
45
|
}
|
|
44
46
|
|
|
47
|
+
:host([size='small']) {
|
|
48
|
+
font-size: var(--scb-link-font-size, var(--scb-typography-body-small-size, var(--md-sys-typescale-body-small-size)));
|
|
49
|
+
line-height: var(--scb-link-line-height, var(--scb-typography-body-small-line-height, var(--md-sys-typescale-body-small-line-height)));
|
|
50
|
+
letter-spacing: var(--scb-link-letter-spacing, var(--scb-typography-body-small-tracking, var(--md-sys-typescale-body-small-tracking)));
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
:host([size='medium']) {
|
|
54
|
+
font-size: var(--scb-link-font-size, var(--scb-typography-body-medium-size, var(--md-sys-typescale-body-medium-size)));
|
|
55
|
+
line-height: var(--scb-link-line-height, var(--scb-typography-body-medium-line-height, var(--md-sys-typescale-body-medium-line-height)));
|
|
56
|
+
letter-spacing: var(--scb-link-letter-spacing, var(--scb-typography-body-medium-tracking, var(--md-sys-typescale-body-medium-tracking)));
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
:host([size='large']) {
|
|
60
|
+
font-size: var(--scb-link-font-size, var(--scb-typography-body-large-size, var(--md-sys-typescale-body-large-size)));
|
|
61
|
+
line-height: var(--scb-link-line-height, var(--scb-typography-body-large-line-height, var(--md-sys-typescale-body-large-line-height)));
|
|
62
|
+
letter-spacing: var(--scb-link-letter-spacing, var(--scb-typography-body-large-tracking, var(--md-sys-typescale-body-large-tracking)));
|
|
63
|
+
}
|
|
64
|
+
|
|
45
65
|
a {
|
|
46
66
|
position: relative;
|
|
47
67
|
text-decoration: var(--scb-link-decoration, underline);
|
|
@@ -105,7 +125,7 @@ var c = class extends n {
|
|
|
105
125
|
text-decoration: none;
|
|
106
126
|
cursor: default;
|
|
107
127
|
}
|
|
108
|
-
|
|
128
|
+
`;
|
|
109
129
|
}
|
|
110
130
|
firstUpdated() {
|
|
111
131
|
this.#e();
|
|
@@ -124,15 +144,15 @@ var c = class extends n {
|
|
|
124
144
|
}
|
|
125
145
|
render() {
|
|
126
146
|
let e = this.target === "_blank" && !this.rel ? "noopener noreferrer" : this.rel;
|
|
127
|
-
return
|
|
147
|
+
return n`
|
|
128
148
|
<a
|
|
129
149
|
part="anchor"
|
|
130
|
-
href=${
|
|
131
|
-
target=${
|
|
132
|
-
rel=${
|
|
133
|
-
download=${
|
|
150
|
+
href=${a(this.disabled ? void 0 : this.href || void 0)}
|
|
151
|
+
target=${a(this.target)}
|
|
152
|
+
rel=${a(e)}
|
|
153
|
+
download=${a(this.download)}
|
|
134
154
|
aria-disabled=${this.disabled ? "true" : "false"}
|
|
135
|
-
aria-label=${
|
|
155
|
+
aria-label=${a(this.ariaLabel || void 0)}
|
|
136
156
|
@click=${this.#n}
|
|
137
157
|
@focusin=${this.#t}
|
|
138
158
|
><slot></slot><md-focus-ring aria-hidden="true"></md-focus-ring></a>
|
|
@@ -141,43 +161,45 @@ var c = class extends n {
|
|
|
141
161
|
#t;
|
|
142
162
|
#n;
|
|
143
163
|
};
|
|
144
|
-
|
|
164
|
+
c([i({
|
|
145
165
|
type: String,
|
|
146
166
|
reflect: !0
|
|
147
|
-
})],
|
|
167
|
+
})], l.prototype, "href", void 0), c([i({
|
|
148
168
|
type: String,
|
|
149
169
|
reflect: !0
|
|
150
|
-
})],
|
|
170
|
+
})], l.prototype, "target", void 0), c([i({
|
|
151
171
|
type: String,
|
|
152
172
|
reflect: !0
|
|
153
|
-
})],
|
|
173
|
+
})], l.prototype, "rel", void 0), c([i({
|
|
154
174
|
type: String,
|
|
155
175
|
reflect: !0
|
|
156
|
-
})],
|
|
176
|
+
})], l.prototype, "download", void 0), c([i({
|
|
157
177
|
type: Boolean,
|
|
158
178
|
reflect: !0
|
|
159
|
-
})],
|
|
179
|
+
})], l.prototype, "disabled", void 0), c([i({
|
|
160
180
|
type: String,
|
|
161
181
|
attribute: "aria-label"
|
|
162
|
-
})],
|
|
182
|
+
})], l.prototype, "ariaLabel", void 0), c([i({
|
|
183
|
+
type: String,
|
|
184
|
+
reflect: !0
|
|
185
|
+
})], l.prototype, "size", void 0), c([i({
|
|
163
186
|
type: String,
|
|
164
187
|
reflect: !0
|
|
165
|
-
})],
|
|
188
|
+
})], l.prototype, "spacing", void 0), c([i({
|
|
166
189
|
type: String,
|
|
167
190
|
attribute: "spacing-top",
|
|
168
191
|
reflect: !0
|
|
169
|
-
})],
|
|
192
|
+
})], l.prototype, "spacingTop", void 0), c([i({
|
|
170
193
|
type: String,
|
|
171
194
|
attribute: "spacing-bottom",
|
|
172
195
|
reflect: !0
|
|
173
|
-
})],
|
|
196
|
+
})], l.prototype, "spacingBottom", void 0), c([i({
|
|
174
197
|
type: String,
|
|
175
198
|
attribute: "spacing-left",
|
|
176
199
|
reflect: !0
|
|
177
|
-
})],
|
|
200
|
+
})], l.prototype, "spacingLeft", void 0), c([i({
|
|
178
201
|
type: String,
|
|
179
202
|
attribute: "spacing-right",
|
|
180
203
|
reflect: !0
|
|
181
|
-
})],
|
|
182
|
-
|
|
183
|
-
export { c as ScbLink };
|
|
204
|
+
})], l.prototype, "spacingRight", void 0), l = c([r("scb-link")], l);
|
|
205
|
+
export { l as ScbLink };
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
var c = class extends
|
|
8
|
-
constructor(...
|
|
9
|
-
super(...
|
|
10
|
-
e
|
|
11
|
-
let
|
|
12
|
-
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i } from "lit/decorators.js";
|
|
3
|
+
import { ifDefined as a } from "lit/directives/if-defined.js";
|
|
4
|
+
import { ensureFocusRingOnFocusVisible as o } from "../shared/lazy-focus-ring.js";
|
|
5
|
+
import s from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
6
|
+
// src/scb-components/scb-link-button/scb-link-button.ts
|
|
7
|
+
var c = class extends e {
|
|
8
|
+
constructor(...e) {
|
|
9
|
+
super(...e), this.href = "", this.ariaLabel = "", this.variant = "filled", this.inverse = !1, this.external = !1, this.#e = (e) => {
|
|
10
|
+
o(e);
|
|
11
|
+
let t = e.composedPath()[0];
|
|
12
|
+
t instanceof HTMLElement && t.matches(":focus-visible") && customElements.whenDefined("md-focus-ring").then(() => {
|
|
13
13
|
this.toggleAttribute("data-native-focus-ring-ready", !0);
|
|
14
14
|
let e = this.renderRoot.querySelector("md-focus-ring");
|
|
15
|
-
e.visible =
|
|
15
|
+
e.visible = t.matches(":focus-visible");
|
|
16
16
|
});
|
|
17
17
|
};
|
|
18
18
|
}
|
|
19
19
|
static {
|
|
20
|
-
this.styles =
|
|
20
|
+
this.styles = t`
|
|
21
21
|
:host {
|
|
22
22
|
display: inline-flex;
|
|
23
23
|
inline-size: fit-content;
|
|
@@ -222,15 +222,15 @@ var c = class extends n {
|
|
|
222
222
|
}
|
|
223
223
|
render() {
|
|
224
224
|
let e = this.target === "_blank" && !this.rel ? "noopener noreferrer" : this.rel;
|
|
225
|
-
return
|
|
225
|
+
return n`
|
|
226
226
|
<a
|
|
227
227
|
class="link-button"
|
|
228
228
|
part="anchor"
|
|
229
|
-
href=${
|
|
230
|
-
target=${
|
|
231
|
-
rel=${
|
|
232
|
-
download=${
|
|
233
|
-
aria-label=${
|
|
229
|
+
href=${a(this.href || void 0)}
|
|
230
|
+
target=${a(this.target)}
|
|
231
|
+
rel=${a(e)}
|
|
232
|
+
download=${a(this.download)}
|
|
233
|
+
aria-label=${a(this.ariaLabel || void 0)}
|
|
234
234
|
@focusin=${this.#e}
|
|
235
235
|
>
|
|
236
236
|
<span class="label" part="label"><slot></slot></span>
|
|
@@ -247,30 +247,29 @@ var c = class extends n {
|
|
|
247
247
|
}
|
|
248
248
|
#e;
|
|
249
249
|
};
|
|
250
|
-
|
|
250
|
+
s([i({
|
|
251
251
|
type: String,
|
|
252
252
|
reflect: !0
|
|
253
|
-
})], c.prototype, "href", void 0),
|
|
253
|
+
})], c.prototype, "href", void 0), s([i({
|
|
254
254
|
type: String,
|
|
255
255
|
reflect: !0
|
|
256
|
-
})], c.prototype, "target", void 0),
|
|
256
|
+
})], c.prototype, "target", void 0), s([i({
|
|
257
257
|
type: String,
|
|
258
258
|
reflect: !0
|
|
259
|
-
})], c.prototype, "rel", void 0),
|
|
259
|
+
})], c.prototype, "rel", void 0), s([i({
|
|
260
260
|
type: String,
|
|
261
261
|
reflect: !0
|
|
262
|
-
})], c.prototype, "download", void 0),
|
|
262
|
+
})], c.prototype, "download", void 0), s([i({
|
|
263
263
|
type: String,
|
|
264
264
|
attribute: "aria-label"
|
|
265
|
-
})], c.prototype, "ariaLabel", void 0),
|
|
265
|
+
})], c.prototype, "ariaLabel", void 0), s([i({
|
|
266
266
|
type: String,
|
|
267
267
|
reflect: !0
|
|
268
|
-
})], c.prototype, "variant", void 0),
|
|
268
|
+
})], c.prototype, "variant", void 0), s([i({
|
|
269
269
|
type: Boolean,
|
|
270
270
|
reflect: !0
|
|
271
|
-
})], c.prototype, "inverse", void 0),
|
|
271
|
+
})], c.prototype, "inverse", void 0), s([i({
|
|
272
272
|
type: Boolean,
|
|
273
273
|
reflect: !0
|
|
274
|
-
})], c.prototype, "external", void 0), c =
|
|
275
|
-
//#endregion
|
|
274
|
+
})], c.prototype, "external", void 0), c = s([r("scb-link-button")], c);
|
|
276
275
|
export { c as ScbLinkButton };
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i } from "lit/decorators.js";
|
|
3
3
|
import "../scb-divider/scb-divider.js";
|
|
4
|
-
import { LitElement as n, css as r, html as i } from "lit";
|
|
5
|
-
import { customElement as a, property as o } from "lit/decorators.js";
|
|
6
4
|
import "@material/web/icon/icon.js";
|
|
7
5
|
import "@material/web/ripple/ripple.js";
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
import { ensureFocusRingOnFocusVisible as a } from "../shared/lazy-focus-ring.js";
|
|
7
|
+
import o from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
8
|
+
// src/scb-components/scb-options-menu/scb-options-menu-item.ts
|
|
9
|
+
var s = class extends e {
|
|
10
10
|
constructor(...e) {
|
|
11
11
|
super(...e), this.label = "", this.hasSubMenu = !1, this.openLeft = !1, this.divider = !1, this.leadingIcon = "", this.trailingIcon = "", this.itemHref = "", this.href = "", this._observedSubMenu = null, this._syncSubMenuFlags = () => {
|
|
12
12
|
let e = this.nextElementSibling, t = !!(e && e.tagName === "SCB-OPTIONS-SUB-MENU"), n = !!(t && e.hasAttribute("open-left"));
|
|
@@ -22,7 +22,7 @@ var s = class extends n {
|
|
|
22
22
|
let t = this.closest("scb-options-sub-menu");
|
|
23
23
|
if (t && t.open) {
|
|
24
24
|
let n = e.relatedTarget;
|
|
25
|
-
|
|
25
|
+
n && t.contains(n) || (t.dispatchEvent(new CustomEvent("hide-submenu", {
|
|
26
26
|
bubbles: !0,
|
|
27
27
|
composed: !0
|
|
28
28
|
})), t.dispatchEvent(new CustomEvent("hidesubmenu", {
|
|
@@ -34,25 +34,18 @@ var s = class extends n {
|
|
|
34
34
|
let e = this.nextElementSibling;
|
|
35
35
|
this.classList.contains("open-submenu") && (e && e.tagName === "SCB-OPTIONS-SUB-MENU" && e.hasAttribute("open") || this.classList.remove("open-submenu"));
|
|
36
36
|
}, this._onKeyDown = (e) => {
|
|
37
|
-
if (e.key === "Enter" || e.key === " ")
|
|
38
|
-
|
|
39
|
-
return;
|
|
40
|
-
}
|
|
41
|
-
if (e.key === "ArrowDown") {
|
|
37
|
+
if (e.key === "Enter" || e.key === " ") e.preventDefault(), this.handleClick(e);
|
|
38
|
+
else if (e.key === "ArrowDown") {
|
|
42
39
|
e.preventDefault();
|
|
43
40
|
let t = this.nextElementSibling;
|
|
44
41
|
for (; t && t.tagName !== "SCB-OPTIONS-MENU-ITEM";) t = t.nextElementSibling;
|
|
45
42
|
t && (t.shadowRoot?.querySelector("li"))?.focus();
|
|
46
|
-
|
|
47
|
-
}
|
|
48
|
-
if (e.key === "ArrowUp") {
|
|
43
|
+
} else if (e.key === "ArrowUp") {
|
|
49
44
|
e.preventDefault();
|
|
50
45
|
let t = this.previousElementSibling;
|
|
51
46
|
for (; t && t.tagName !== "SCB-OPTIONS-MENU-ITEM";) t = t.previousElementSibling;
|
|
52
47
|
t && (t.shadowRoot?.querySelector("li"))?.focus();
|
|
53
|
-
|
|
54
|
-
}
|
|
55
|
-
if (e.key === "ArrowRight") {
|
|
48
|
+
} else if (e.key === "ArrowRight") {
|
|
56
49
|
e.preventDefault();
|
|
57
50
|
let t = this.nextElementSibling;
|
|
58
51
|
t && t.tagName === "SCB-OPTIONS-SUB-MENU" && (t.hasAttribute("open") || (this._toggleSubMenu(), t.dispatchEvent(new CustomEvent("show-submenu", {
|
|
@@ -65,9 +58,7 @@ var s = class extends n {
|
|
|
65
58
|
let e = t.querySelector("scb-options-menu-item");
|
|
66
59
|
e && (e.shadowRoot?.querySelector("li"))?.focus();
|
|
67
60
|
}, 0));
|
|
68
|
-
|
|
69
|
-
}
|
|
70
|
-
if (e.key === "ArrowLeft") {
|
|
61
|
+
} else if (e.key === "ArrowLeft") {
|
|
71
62
|
e.preventDefault();
|
|
72
63
|
let t = this.nextElementSibling;
|
|
73
64
|
if (t && t.tagName === "SCB-OPTIONS-SUB-MENU" && t.hasAttribute("open")) {
|
|
@@ -85,12 +76,11 @@ var s = class extends n {
|
|
|
85
76
|
let e = n.previousElementSibling;
|
|
86
77
|
e && e.tagName === "SCB-OPTIONS-MENU-ITEM" && (e.shadowRoot?.querySelector("li"))?.focus();
|
|
87
78
|
}
|
|
88
|
-
return;
|
|
89
79
|
}
|
|
90
80
|
};
|
|
91
81
|
}
|
|
92
82
|
static {
|
|
93
|
-
this.styles =
|
|
83
|
+
this.styles = t`
|
|
94
84
|
:host {
|
|
95
85
|
display: block;
|
|
96
86
|
}
|
|
@@ -206,21 +196,21 @@ var s = class extends n {
|
|
|
206
196
|
this._subMenuChildObserver?.disconnect(), this._subMenuAttrObserver?.disconnect(), this._subMenuChildObserver = void 0, this._subMenuAttrObserver = void 0, this._observedSubMenu = null, super.disconnectedCallback();
|
|
207
197
|
}
|
|
208
198
|
render() {
|
|
209
|
-
return
|
|
210
|
-
${this.divider ?
|
|
211
|
-
<li @click=${this.handleClick} @keydown=${this._onKeyDown} @blur=${this._onBlur} @focus=${this._onFocus} @focusin=${
|
|
199
|
+
return n`
|
|
200
|
+
${this.divider ? n`<scb-divider></scb-divider>` : ""}
|
|
201
|
+
<li @click=${this.handleClick} @keydown=${this._onKeyDown} @blur=${this._onBlur} @focus=${this._onFocus} @focusin=${a} role="menuitem" tabindex="0">
|
|
212
202
|
|
|
213
203
|
|
|
214
204
|
<md-focus-ring inward></md-focus-ring>
|
|
215
|
-
${this._effectiveHref ?
|
|
216
|
-
${this.leadingIcon ?
|
|
205
|
+
${this._effectiveHref ? n`<a href="${this._effectiveHref}">
|
|
206
|
+
${this.leadingIcon ? n`<md-icon>${this.leadingIcon}</md-icon>` : ""}
|
|
217
207
|
<div class="label">${this.label}</div>
|
|
218
|
-
${this.trailingIcon ?
|
|
208
|
+
${this.trailingIcon ? n`<md-icon class="ti">${this.trailingIcon}</md-icon>` : ""}
|
|
219
209
|
<md-ripple></md-ripple>
|
|
220
|
-
</a>` :
|
|
221
|
-
${this.leadingIcon ?
|
|
210
|
+
</a>` : n`
|
|
211
|
+
${this.leadingIcon ? n`<md-icon>${this.leadingIcon}</md-icon>` : ""}
|
|
222
212
|
<div class="label">${this.label}</div>
|
|
223
|
-
${this.trailingIcon ?
|
|
213
|
+
${this.trailingIcon ? n`<md-icon class="ti">${this.trailingIcon}</md-icon>` : ""}
|
|
224
214
|
<md-ripple></md-ripple>
|
|
225
215
|
`}
|
|
226
216
|
</li>
|
|
@@ -259,15 +249,14 @@ var s = class extends n {
|
|
|
259
249
|
}))));
|
|
260
250
|
}
|
|
261
251
|
};
|
|
262
|
-
|
|
252
|
+
o([i({ type: String })], s.prototype, "label", void 0), o([i({ type: Boolean })], s.prototype, "hasSubMenu", void 0), o([i({ type: Boolean })], s.prototype, "openLeft", void 0), o([i({ type: Boolean })], s.prototype, "divider", void 0), o([i({
|
|
263
253
|
type: String,
|
|
264
254
|
attribute: "leading-icon"
|
|
265
|
-
})], s.prototype, "leadingIcon", void 0),
|
|
255
|
+
})], s.prototype, "leadingIcon", void 0), o([i({
|
|
266
256
|
type: String,
|
|
267
257
|
attribute: "trailing-icon"
|
|
268
|
-
})], s.prototype, "trailingIcon", void 0),
|
|
258
|
+
})], s.prototype, "trailingIcon", void 0), o([i({
|
|
269
259
|
type: String,
|
|
270
260
|
attribute: "item-href"
|
|
271
|
-
})], s.prototype, "itemHref", void 0),
|
|
272
|
-
//#endregion
|
|
261
|
+
})], s.prototype, "itemHref", void 0), o([i({ type: String })], s.prototype, "href", void 0), s = o([r("scb-options-menu-item")], s);
|
|
273
262
|
export { s as ScbOptionsMenuItem };
|