@ds-mo/ui 3.0.1 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.build-stamp +1 -1
- package/dist/angular/angular-component-lib/utils.d.ts +9 -0
- package/dist/angular/angular-component-lib/utils.js +58 -0
- package/dist/angular/boolean-value-accessor.d.ts +9 -0
- package/dist/angular/boolean-value-accessor.js +37 -0
- package/dist/angular/ds-app-shell.d.ts +12 -0
- package/dist/angular/ds-app-shell.js +38 -0
- package/dist/angular/ds-badge.d.ts +12 -0
- package/dist/angular/ds-badge.js +38 -0
- package/dist/angular/ds-banner.d.ts +15 -0
- package/dist/angular/ds-banner.js +42 -0
- package/dist/angular/ds-bar-nav.d.ts +18 -0
- package/dist/angular/ds-bar-nav.js +42 -0
- package/dist/angular/ds-button-filled.d.ts +15 -0
- package/dist/angular/ds-button-filled.js +43 -0
- package/dist/angular/ds-button-unfilled.d.ts +17 -0
- package/dist/angular/ds-button-unfilled.js +46 -0
- package/dist/angular/ds-card-data-viz-donut.d.ts +18 -0
- package/dist/angular/ds-card-data-viz-donut.js +42 -0
- package/dist/angular/ds-card-setting.d.ts +18 -0
- package/dist/angular/ds-card-setting.js +42 -0
- package/dist/angular/ds-card.d.ts +12 -0
- package/dist/angular/ds-card.js +38 -0
- package/dist/angular/ds-chart-bar.d.ts +12 -0
- package/dist/angular/ds-chart-bar.js +38 -0
- package/dist/angular/ds-chart-donut.d.ts +19 -0
- package/dist/angular/ds-chart-donut.js +42 -0
- package/dist/angular/ds-chart-legend.d.ts +30 -0
- package/dist/angular/ds-chart-legend.js +45 -0
- package/dist/angular/ds-chart-line.d.ts +12 -0
- package/dist/angular/ds-chart-line.js +38 -0
- package/dist/angular/ds-checkbox.d.ts +15 -0
- package/dist/angular/ds-checkbox.js +42 -0
- package/dist/angular/ds-chip.d.ts +18 -0
- package/dist/angular/ds-chip.js +42 -0
- package/dist/angular/ds-divider.d.ts +12 -0
- package/dist/angular/ds-divider.js +38 -0
- package/dist/angular/ds-empty-state.d.ts +12 -0
- package/dist/angular/ds-empty-state.js +38 -0
- package/dist/angular/ds-field.d.ts +12 -0
- package/dist/angular/ds-field.js +38 -0
- package/dist/angular/ds-icon.d.ts +12 -0
- package/dist/angular/ds-icon.js +38 -0
- package/dist/angular/ds-input.d.ts +17 -0
- package/dist/angular/ds-input.js +46 -0
- package/dist/angular/ds-loader.d.ts +12 -0
- package/dist/angular/ds-loader.js +38 -0
- package/dist/angular/ds-menu.d.ts +24 -0
- package/dist/angular/ds-menu.js +48 -0
- package/dist/angular/ds-modal.d.ts +15 -0
- package/dist/angular/ds-modal.js +42 -0
- package/dist/angular/ds-pagination.d.ts +15 -0
- package/dist/angular/ds-pagination.js +42 -0
- package/dist/angular/ds-panel-nav.d.ts +42 -0
- package/dist/angular/ds-panel-nav.js +58 -0
- package/dist/angular/ds-panel-tools.d.ts +33 -0
- package/dist/angular/ds-panel-tools.js +49 -0
- package/dist/angular/ds-radio-group.d.ts +15 -0
- package/dist/angular/ds-radio-group.js +42 -0
- package/dist/angular/ds-select.d.ts +18 -0
- package/dist/angular/ds-select.js +42 -0
- package/dist/angular/ds-shell-gradient-picker.d.ts +16 -0
- package/dist/angular/ds-shell-gradient-picker.js +42 -0
- package/dist/angular/ds-shell-gradient-swatch.d.ts +16 -0
- package/dist/angular/ds-shell-gradient-swatch.js +42 -0
- package/dist/angular/ds-skeleton.d.ts +12 -0
- package/dist/angular/ds-skeleton.js +38 -0
- package/dist/angular/ds-slider.d.ts +15 -0
- package/dist/angular/ds-slider.js +42 -0
- package/dist/angular/ds-tab-group-nav.d.ts +20 -0
- package/dist/angular/ds-tab-group-nav.js +46 -0
- package/dist/angular/ds-tab-group.d.ts +15 -0
- package/dist/angular/ds-tab-group.js +42 -0
- package/dist/angular/ds-table.d.ts +33 -0
- package/dist/angular/ds-table.js +48 -0
- package/dist/angular/ds-tag.d.ts +12 -0
- package/dist/angular/ds-tag.js +38 -0
- package/dist/angular/ds-text.d.ts +12 -0
- package/dist/angular/ds-text.js +38 -0
- package/dist/angular/ds-toggle.d.ts +15 -0
- package/dist/angular/ds-toggle.js +42 -0
- package/dist/angular/ds-tooltip-data-viz.d.ts +12 -0
- package/dist/angular/ds-tooltip-data-viz.js +38 -0
- package/dist/angular/ds-tooltip.d.ts +12 -0
- package/dist/angular/ds-tooltip.js +38 -0
- package/dist/angular/index.d.ts +2 -0
- package/dist/angular/index.js +43 -0
- package/dist/angular/proxies.d.ts +44 -0
- package/dist/angular/proxies.js +45 -0
- package/dist/angular/radio-value-accessor.d.ts +8 -0
- package/dist/angular/radio-value-accessor.js +34 -0
- package/dist/angular/select-value-accessor.d.ts +8 -0
- package/dist/angular/select-value-accessor.js +34 -0
- package/dist/angular/text-value-accessor.d.ts +8 -0
- package/dist/angular/text-value-accessor.js +34 -0
- package/dist/angular/value-accessor.d.ts +18 -0
- package/dist/angular/value-accessor.js +39 -0
- package/dist/components/ds-app-shell.js +1 -1
- package/dist/components/ds-bar-nav.js +1 -1
- package/dist/components/ds-bar-nav.js.map +1 -1
- package/dist/components/ds-button-filled.js +1 -1
- package/dist/components/ds-button-unfilled.js +1 -1
- package/dist/components/ds-card-data-viz-donut.js +1 -1
- package/dist/components/ds-card-data-viz-donut.js.map +1 -1
- package/dist/components/ds-card-setting.js +1 -1
- package/dist/components/ds-card-setting.js.map +1 -1
- package/dist/components/ds-chart-donut.js +1 -1
- package/dist/components/ds-chart-donut.js.map +1 -1
- package/dist/components/ds-chart-legend.js +1 -1
- package/dist/components/ds-chart-legend.js.map +1 -1
- package/dist/components/ds-checkbox.js +1 -1
- package/dist/components/ds-checkbox.js.map +1 -1
- package/dist/components/ds-chip.js +1 -1
- package/dist/components/ds-chip.js.map +1 -1
- package/dist/components/ds-empty-state.js +1 -1
- package/dist/components/ds-empty-state.js.map +1 -1
- package/dist/components/ds-input.js +1 -1
- package/dist/components/ds-input.js.map +1 -1
- package/dist/components/ds-menu.js +1 -1
- package/dist/components/ds-pagination.js +1 -1
- package/dist/components/ds-pagination.js.map +1 -1
- package/dist/components/ds-panel-nav.js +1 -1
- package/dist/components/ds-panel-nav.js.map +1 -1
- package/dist/components/ds-panel-tools.js +1 -1
- package/dist/components/ds-panel-tools.js.map +1 -1
- package/dist/components/ds-radio-group.js +1 -1
- package/dist/components/ds-radio-group.js.map +1 -1
- package/dist/components/ds-select.js +1 -1
- package/dist/components/ds-select.js.map +1 -1
- package/dist/components/ds-shell-gradient-picker.js +1 -1
- package/dist/components/ds-shell-gradient-swatch.js +1 -1
- package/dist/components/ds-tab-group-nav.js +1 -1
- package/dist/components/ds-tab-group.js +1 -1
- package/dist/components/ds-tab-group.js.map +1 -1
- package/dist/components/ds-table.js +1 -1
- package/dist/components/ds-table.js.map +1 -1
- package/dist/components/ds-toggle.js +1 -1
- package/dist/components/ds-toggle.js.map +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/index.js.map +1 -1
- package/dist/components/p-BBpASejH.js +2 -0
- package/dist/components/p-BBpASejH.js.map +1 -0
- package/dist/components/{p-D0gBLLJx.js → p-BFiaUYu7.js} +2 -2
- package/dist/components/p-BFiaUYu7.js.map +1 -0
- package/dist/components/p-CTK82RIw.js +2 -0
- package/dist/components/p-CTK82RIw.js.map +1 -0
- package/dist/components/{p-BSNlp8Di.js → p-Cp86p-11.js} +2 -2
- package/dist/components/{p-BSNlp8Di.js.map → p-Cp86p-11.js.map} +1 -1
- package/dist/components/{p-vlwhuqVn.js → p-DHjjwgku.js} +2 -2
- package/dist/components/{p-vlwhuqVn.js.map → p-DHjjwgku.js.map} +1 -1
- package/dist/components/{p-boPMASaQ.js → p-DOEMwKBb.js} +2 -2
- package/dist/components/{p-boPMASaQ.js.map → p-DOEMwKBb.js.map} +1 -1
- package/dist/components/{p-Co2kLhWu.js → p-DolYlDbY.js} +2 -2
- package/dist/components/p-DolYlDbY.js.map +1 -0
- package/dist/components/p-NkAPA-Dz.js +2 -0
- package/dist/components/p-NkAPA-Dz.js.map +1 -0
- package/dist/framework/angular.d.ts +6 -0
- package/dist/framework/angular.js +6 -0
- package/dist/lib/nav/chrome-transition.d.ts +8 -0
- package/dist/lib/nav/index.js.map +2 -2
- package/dist/lib/utils/format-compact-number.d.ts +1 -1
- package/dist/lib/utils/index.js +8 -1
- package/dist/lib/utils/index.js.map +2 -2
- package/dist/react/components.d.ts +44 -0
- package/{src/react/components.ts → dist/react/components.js} +0 -1
- package/dist/react/ds-app-shell.d.ts +9 -0
- package/dist/react/ds-app-shell.js +12 -0
- package/dist/react/ds-badge.d.ts +9 -0
- package/dist/react/ds-badge.js +12 -0
- package/dist/react/ds-banner.d.ts +12 -0
- package/dist/react/ds-banner.js +12 -0
- package/dist/react/ds-bar-nav.d.ts +12 -0
- package/dist/react/ds-bar-nav.js +12 -0
- package/dist/react/ds-button-filled.d.ts +12 -0
- package/dist/react/ds-button-filled.js +12 -0
- package/dist/react/ds-button-unfilled.d.ts +13 -0
- package/dist/react/ds-button-unfilled.js +15 -0
- package/dist/react/ds-card-data-viz-donut.d.ts +12 -0
- package/dist/react/ds-card-data-viz-donut.js +12 -0
- package/dist/react/ds-card-setting.d.ts +12 -0
- package/dist/react/ds-card-setting.js +12 -0
- package/dist/react/ds-card.d.ts +9 -0
- package/dist/react/ds-card.js +12 -0
- package/dist/react/ds-chart-bar.d.ts +9 -0
- package/dist/react/ds-chart-bar.js +12 -0
- package/dist/react/ds-chart-donut.d.ts +12 -0
- package/dist/react/ds-chart-donut.js +12 -0
- package/dist/react/ds-chart-legend.d.ts +16 -0
- package/dist/react/ds-chart-legend.js +15 -0
- package/dist/react/ds-chart-line.d.ts +9 -0
- package/dist/react/ds-chart-line.js +12 -0
- package/dist/react/ds-checkbox.d.ts +12 -0
- package/dist/react/ds-checkbox.js +12 -0
- package/dist/react/ds-chip.d.ts +12 -0
- package/dist/react/ds-chip.js +12 -0
- package/dist/react/ds-divider.d.ts +9 -0
- package/dist/react/ds-divider.js +12 -0
- package/dist/react/ds-empty-state.d.ts +9 -0
- package/dist/react/ds-empty-state.js +12 -0
- package/dist/react/ds-field.d.ts +9 -0
- package/dist/react/ds-field.js +12 -0
- package/dist/react/ds-icon.d.ts +9 -0
- package/dist/react/ds-icon.js +12 -0
- package/dist/react/ds-input.d.ts +13 -0
- package/dist/react/ds-input.js +15 -0
- package/dist/react/ds-loader.d.ts +9 -0
- package/dist/react/ds-loader.js +12 -0
- package/dist/react/ds-menu.d.ts +14 -0
- package/dist/react/ds-menu.js +16 -0
- package/dist/react/ds-modal.d.ts +12 -0
- package/dist/react/ds-modal.js +12 -0
- package/dist/react/ds-pagination.d.ts +12 -0
- package/dist/react/ds-pagination.js +12 -0
- package/dist/react/ds-panel-nav.d.ts +17 -0
- package/dist/react/ds-panel-nav.js +19 -0
- package/dist/react/ds-panel-tools.d.ts +17 -0
- package/dist/react/ds-panel-tools.js +16 -0
- package/dist/react/ds-radio-group.d.ts +12 -0
- package/dist/react/ds-radio-group.js +12 -0
- package/dist/react/ds-select.d.ts +12 -0
- package/dist/react/ds-select.js +12 -0
- package/dist/react/ds-shell-gradient-picker.d.ts +12 -0
- package/dist/react/ds-shell-gradient-picker.js +12 -0
- package/dist/react/ds-shell-gradient-swatch.d.ts +12 -0
- package/dist/react/ds-shell-gradient-swatch.js +12 -0
- package/dist/react/ds-skeleton.d.ts +9 -0
- package/dist/react/ds-skeleton.js +12 -0
- package/dist/react/ds-slider.d.ts +12 -0
- package/dist/react/ds-slider.js +12 -0
- package/dist/react/ds-tab-group-nav.d.ts +13 -0
- package/dist/react/ds-tab-group-nav.js +15 -0
- package/dist/react/ds-tab-group.d.ts +12 -0
- package/dist/react/ds-tab-group.js +12 -0
- package/dist/react/ds-table.d.ts +21 -0
- package/dist/react/ds-table.js +16 -0
- package/dist/react/ds-tag.d.ts +9 -0
- package/dist/react/ds-tag.js +12 -0
- package/dist/react/ds-text.d.ts +9 -0
- package/dist/react/ds-text.js +12 -0
- package/dist/react/ds-toggle.d.ts +12 -0
- package/dist/react/ds-toggle.js +12 -0
- package/dist/react/ds-tooltip-data-viz.d.ts +9 -0
- package/dist/react/ds-tooltip-data-viz.js +12 -0
- package/dist/react/ds-tooltip.d.ts +9 -0
- package/dist/react/ds-tooltip.js +12 -0
- package/dist/types/components/BarNav/BarNav.d.ts +1 -0
- package/dist/types/components/ButtonFilled/ButtonFilled.d.ts +1 -1
- package/dist/types/components/ButtonUnfilled/ButtonUnfilled.d.ts +1 -1
- package/dist/types/components/CardDataVizDonut/CardDataVizDonut.d.ts +1 -0
- package/dist/types/components/CardSetting/CardSetting.d.ts +3 -0
- package/dist/types/components/ChartDonut/ChartDonut.d.ts +2 -0
- package/dist/types/components/ChartLegend/ChartLegend.d.ts +1 -0
- package/dist/types/components/Checkbox/Checkbox.d.ts +12 -0
- package/dist/types/components/Chip/Chip.d.ts +2 -0
- package/dist/types/components/EmptyState/EmptyState.d.ts +2 -0
- package/dist/types/components/Input/Input.d.ts +14 -1
- package/dist/types/components/Menu/Menu.d.ts +2 -0
- package/dist/types/components/Pagination/Pagination.d.ts +3 -0
- package/dist/types/components/PanelNav/PanelNav.d.ts +7 -0
- package/dist/types/components/PanelTools/PanelTools.d.ts +2 -0
- package/dist/types/components/RadioGroup/RadioGroup.d.ts +13 -1
- package/dist/types/components/Select/Select.d.ts +13 -1
- package/dist/types/components/ShellGradientPicker/ShellGradientPicker.d.ts +1 -0
- package/dist/types/components/ShellGradientSwatch/ShellGradientSwatch.d.ts +1 -1
- package/dist/types/components/TabGroup/TabGroup.d.ts +1 -1
- package/dist/types/components/TabGroupNav/TabGroupNav.d.ts +1 -1
- package/dist/types/components/Table/Table.d.ts +6 -0
- package/dist/types/components/Toggle/Toggle.d.ts +12 -0
- package/dist/types/components.d.ts +525 -30
- package/dist/types/nav/chrome-transition.d.ts +8 -0
- package/dist/types/stencil-public-runtime.d.ts +1 -0
- package/dist/types/utils/format-compact-number.d.ts +1 -1
- package/package.json +58 -41
- package/dist/components/p-BiM6QBTF.js +0 -2
- package/dist/components/p-BiM6QBTF.js.map +0 -1
- package/dist/components/p-Co2kLhWu.js.map +0 -1
- package/dist/components/p-CsaW5gDM.js +0 -2
- package/dist/components/p-CsaW5gDM.js.map +0 -1
- package/dist/components/p-D0gBLLJx.js.map +0 -1
- package/dist/components/p-DEpLlQZK.js +0 -2
- package/dist/components/p-DEpLlQZK.js.map +0 -1
- package/src/angular/angular-component-lib/utils.ts +0 -65
- package/src/angular/index.ts +0 -45
- package/src/angular/proxies.ts +0 -1156
- package/src/react/ds-app-shell.ts +0 -26
- package/src/react/ds-badge.ts +0 -26
- package/src/react/ds-banner.ts +0 -27
- package/src/react/ds-bar-nav.ts +0 -27
- package/src/react/ds-button-filled.ts +0 -27
- package/src/react/ds-button-unfilled.ts +0 -33
- package/src/react/ds-card-data-viz-donut.ts +0 -27
- package/src/react/ds-card-setting.ts +0 -27
- package/src/react/ds-card.ts +0 -26
- package/src/react/ds-chart-bar.ts +0 -26
- package/src/react/ds-chart-donut.ts +0 -27
- package/src/react/ds-chart-legend.ts +0 -33
- package/src/react/ds-chart-line.ts +0 -26
- package/src/react/ds-checkbox.ts +0 -27
- package/src/react/ds-chip.ts +0 -27
- package/src/react/ds-divider.ts +0 -26
- package/src/react/ds-empty-state.ts +0 -26
- package/src/react/ds-field.ts +0 -26
- package/src/react/ds-icon.ts +0 -26
- package/src/react/ds-input.ts +0 -33
- package/src/react/ds-loader.ts +0 -26
- package/src/react/ds-menu.ts +0 -35
- package/src/react/ds-modal.ts +0 -27
- package/src/react/ds-pagination.ts +0 -27
- package/src/react/ds-panel-nav.ts +0 -41
- package/src/react/ds-panel-tools.ts +0 -35
- package/src/react/ds-radio-group.ts +0 -27
- package/src/react/ds-select.ts +0 -27
- package/src/react/ds-shell-gradient-picker.ts +0 -27
- package/src/react/ds-shell-gradient-swatch.ts +0 -27
- package/src/react/ds-skeleton.ts +0 -26
- package/src/react/ds-slider.ts +0 -27
- package/src/react/ds-tab-group-nav.ts +0 -33
- package/src/react/ds-tab-group.ts +0 -27
- package/src/react/ds-table.ts +0 -35
- package/src/react/ds-tag.ts +0 -26
- package/src/react/ds-text.ts +0 -26
- package/src/react/ds-toggle.ts +0 -27
- package/src/react/ds-tooltip-data-viz.ts +0 -26
- package/src/react/ds-tooltip.ts +0 -26
- package/src/wc/components/AppShell/AppShell.tsx +0 -377
- package/src/wc/components/Badge/Badge.tsx +0 -179
- package/src/wc/components/Badge/index.ts +0 -1
- package/src/wc/components/Banner/Banner.tsx +0 -156
- package/src/wc/components/BarNav/BarNav.tsx +0 -745
- package/src/wc/components/BarNav/bar-nav-dom-utils.ts +0 -23
- package/src/wc/components/BarNav/bar-nav-tabs-menu-utils.ts +0 -114
- package/src/wc/components/BarNav/bar-nav-types.ts +0 -3
- package/src/wc/components/BarNav/bar-nav-utils.ts +0 -67
- package/src/wc/components/BarNav/index.ts +0 -2
- package/src/wc/components/ButtonFilled/ButtonFilled.tsx +0 -171
- package/src/wc/components/ButtonFilled/index.ts +0 -7
- package/src/wc/components/ButtonUnfilled/ButtonUnfilled.tsx +0 -229
- package/src/wc/components/ButtonUnfilled/index.ts +0 -7
- package/src/wc/components/Card/Card.tsx +0 -78
- package/src/wc/components/Card/index.ts +0 -1
- package/src/wc/components/CardDataVizDonut/CardDataVizDonut.tsx +0 -108
- package/src/wc/components/CardDataVizDonut/index.ts +0 -1
- package/src/wc/components/CardSetting/CardSetting.tsx +0 -81
- package/src/wc/components/CardSetting/index.ts +0 -1
- package/src/wc/components/ChartBar/ChartBar.tsx +0 -88
- package/src/wc/components/ChartBar/index.ts +0 -1
- package/src/wc/components/ChartDonut/ChartDonut.tsx +0 -289
- package/src/wc/components/ChartDonut/index.ts +0 -1
- package/src/wc/components/ChartLegend/ChartLegend.tsx +0 -125
- package/src/wc/components/ChartLegend/index.ts +0 -2
- package/src/wc/components/ChartLine/ChartLine.tsx +0 -102
- package/src/wc/components/ChartLine/index.ts +0 -1
- package/src/wc/components/Checkbox/Checkbox.tsx +0 -60
- package/src/wc/components/Checkbox/index.ts +0 -1
- package/src/wc/components/Chip/Chip.tsx +0 -104
- package/src/wc/components/Chip/index.ts +0 -1
- package/src/wc/components/Divider/Divider.tsx +0 -107
- package/src/wc/components/Divider/index.ts +0 -2
- package/src/wc/components/EmptyState/EmptyState.tsx +0 -30
- package/src/wc/components/Field/Field.tsx +0 -30
- package/src/wc/components/Icon/Icon.tsx +0 -172
- package/src/wc/components/Icon/flag-icon-catalog.ts +0 -36
- package/src/wc/components/Icon/icon-cache.ts +0 -47
- package/src/wc/components/Icon/icon-svg.ts +0 -73
- package/src/wc/components/Icon/index.ts +0 -1
- package/src/wc/components/Icon/system-icon-catalog.ts +0 -401
- package/src/wc/components/Input/Input.tsx +0 -107
- package/src/wc/components/Input/index.ts +0 -1
- package/src/wc/components/Loader/Loader.tsx +0 -99
- package/src/wc/components/Loader/index.ts +0 -1
- package/src/wc/components/Menu/Menu.tsx +0 -437
- package/src/wc/components/Menu/menu-placement.ts +0 -26
- package/src/wc/components/Menu/menu-position.ts +0 -78
- package/src/wc/components/Menu/menu-types.ts +0 -39
- package/src/wc/components/Modal/Modal.tsx +0 -213
- package/src/wc/components/Pagination/Pagination.tsx +0 -97
- package/src/wc/components/PanelNav/PanelNav.tsx +0 -714
- package/src/wc/components/PanelNav/index.ts +0 -17
- package/src/wc/components/PanelNav/panel-nav-types.ts +0 -36
- package/src/wc/components/PanelNav/panel-nav-utils.ts +0 -79
- package/src/wc/components/PanelTools/PanelTools.tsx +0 -366
- package/src/wc/components/PanelTools/index.ts +0 -7
- package/src/wc/components/PanelTools/panel-tools-types.ts +0 -44
- package/src/wc/components/PanelTools/panel-tools-utils.ts +0 -50
- package/src/wc/components/RadioGroup/RadioGroup.tsx +0 -130
- package/src/wc/components/RadioGroup/index.ts +0 -1
- package/src/wc/components/Select/Select.tsx +0 -274
- package/src/wc/components/Select/index.ts +0 -1
- package/src/wc/components/ShellGradientPicker/ShellGradientPicker.tsx +0 -55
- package/src/wc/components/ShellGradientSwatch/ShellGradientSwatch.tsx +0 -69
- package/src/wc/components/ShellGradientSwatch/shell-gradient-swatch-types.ts +0 -17
- package/src/wc/components/Skeleton/Skeleton.tsx +0 -64
- package/src/wc/components/Skeleton/index.ts +0 -1
- package/src/wc/components/Slider/Slider.tsx +0 -76
- package/src/wc/components/Slider/index.ts +0 -1
- package/src/wc/components/TabGroup/TabGroup.tsx +0 -204
- package/src/wc/components/TabGroup/tab-item-utils.ts +0 -25
- package/src/wc/components/TabGroupNav/TabGroupNav.tsx +0 -347
- package/src/wc/components/Table/Table.tsx +0 -273
- package/src/wc/components/Tag/Tag.tsx +0 -63
- package/src/wc/components/Tag/index.ts +0 -1
- package/src/wc/components/Text/Text.tsx +0 -99
- package/src/wc/components/Text/index.ts +0 -12
- package/src/wc/components/Text/text-types.ts +0 -23
- package/src/wc/components/Text/text-utils.ts +0 -13
- package/src/wc/components/Toggle/Toggle.tsx +0 -43
- package/src/wc/components/Toggle/index.ts +0 -1
- package/src/wc/components/Tooltip/Tooltip.tsx +0 -413
- package/src/wc/components/TooltipDataViz/TooltipDataViz.tsx +0 -145
- package/src/wc/components/TooltipDataViz/index.ts +0 -1
- package/src/wc/components.d.ts +0 -3569
- package/src/wc/nav/badge-gradient-ring.ts +0 -109
- package/src/wc/nav/chrome-transition.ts +0 -62
- package/src/wc/nav/index.ts +0 -80
- package/src/wc/nav/nav-chrome.ts +0 -47
- package/src/wc/nav/shell-chrome-metrics.ts +0 -49
- package/src/wc/nav/shell-gradient-presets.ts +0 -60
- package/src/wc/nav/shell-gradient.ts +0 -94
- package/src/wc/nav/shell-shortcuts.ts +0 -63
- package/src/wc/nav/shell-view-transition.ts +0 -122
- package/src/wc/utils/chart-colors.ts +0 -7
- package/src/wc/utils/chart-types.ts +0 -25
- package/src/wc/utils/control-density.css +0 -43
- package/src/wc/utils/control-inactive.css +0 -20
- package/src/wc/utils/control-text.ts +0 -11
- package/src/wc/utils/control-width.css +0 -28
- package/src/wc/utils/control-width.ts +0 -10
- package/src/wc/utils/focus-ring.css +0 -33
- package/src/wc/utils/format-compact-number.ts +0 -27
- package/src/wc/utils/index.ts +0 -27
- package/src/wc/utils/interaction-fill.css +0 -162
- package/src/wc/utils/resolve-css-length-px.ts +0 -66
- package/src/wc/utils/resolve-css-time-ms.ts +0 -46
- package/src/wc/utils/scroll-edge-fade.css +0 -80
- package/src/wc/utils/scroll-edge-fade.ts +0 -148
- package/src/wc/utils/token-defaults.ts +0 -81
- package/src/wc/utils/truncate-svg-text.ts +0 -25
- package/src/wc/utils/typography.css +0 -146
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, State, Event, EventEmitter, h, Host } from '@stencil/core';
|
|
2
|
-
import { categoryColor } from '../../utils/chart-colors';
|
|
3
|
-
import { formatCompactNumber } from '../../utils';
|
|
4
|
-
import type { ChartLegendItem } from '../../utils/chart-types';
|
|
5
|
-
|
|
6
|
-
export type ChartLegendDirection = 'vertical' | 'horizontal';
|
|
7
|
-
|
|
8
|
-
const DIMMED_OPACITY = 0.25;
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Base legend for `ds-chart-*` components. Webapp's Overview widgets each style
|
|
12
|
-
* legends differently (list w/ values, compact chips, bare swatches, external
|
|
13
|
-
* stat callouts) — this covers the common "swatch + label + optional value" case.
|
|
14
|
-
* Consumers who need a different treatment skip this component entirely and
|
|
15
|
-
* render their own markup against the same `ChartDatum[]` data.
|
|
16
|
-
*/
|
|
17
|
-
@Component({
|
|
18
|
-
tag: 'ds-chart-legend',
|
|
19
|
-
styleUrl: 'ChartLegend.css',
|
|
20
|
-
scoped: true,
|
|
21
|
-
})
|
|
22
|
-
export class ChartLegend {
|
|
23
|
-
/** Legend entries. Set as a JS property (not an HTML attribute). */
|
|
24
|
-
@Prop() items: ChartLegendItem[] = [];
|
|
25
|
-
@Prop() direction: ChartLegendDirection = 'vertical';
|
|
26
|
-
/** Show each item's share of the total (of items with a `value`) alongside its count. */
|
|
27
|
-
@Prop() showPercentage: boolean = true;
|
|
28
|
-
/**
|
|
29
|
-
* Externally controlled highlight, matched by `label` — e.g. drive this from a sibling
|
|
30
|
-
* chart's `dsSliceHover` event to keep chart and legend hover in sync. Only dims the other
|
|
31
|
-
* rows' opacity (like a chart dimming its other slices) — it never shows the hover-fill,
|
|
32
|
-
* since that's reserved for a real pointer/keyboard interaction on this row.
|
|
33
|
-
*/
|
|
34
|
-
@Prop() activeLabel: string | null = null;
|
|
35
|
-
|
|
36
|
-
/** Own pointer/focus hover, kept separate from `activeLabel` so the hover-fill (a "you can
|
|
37
|
-
* click here" affordance) never shows just because an external row was synced in. */
|
|
38
|
-
@State() private hoveredLabel: string | null = null;
|
|
39
|
-
|
|
40
|
-
/** Fires on row hover/focus with the item, or `null` on leave/blur. */
|
|
41
|
-
@Event() dsItemHover!: EventEmitter<ChartLegendItem | null>;
|
|
42
|
-
/** Fires when a deep-linkable row (`item.href` set) is activated. */
|
|
43
|
-
@Event() dsItemClick!: EventEmitter<{ item: ChartLegendItem; originalEvent: MouseEvent }>;
|
|
44
|
-
|
|
45
|
-
private handleHover(item: ChartLegendItem | null) {
|
|
46
|
-
this.hoveredLabel = item?.label ?? null;
|
|
47
|
-
this.dsItemHover.emit(item);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
private handleClick = (item: ChartLegendItem, originalEvent: MouseEvent) => {
|
|
51
|
-
this.dsItemClick.emit({ item, originalEvent });
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
render() {
|
|
55
|
-
const total = this.items.reduce((sum, item) => sum + (item.value ?? 0), 0);
|
|
56
|
-
// Highlight/dim from either this component's own hover or an externally-synced label
|
|
57
|
-
// (e.g. a sibling ds-chart-donut slice) — same mechanism ds-chart-donut uses for its slices.
|
|
58
|
-
const highlightLabel = this.activeLabel ?? this.hoveredLabel;
|
|
59
|
-
|
|
60
|
-
return (
|
|
61
|
-
<Host class={{ 'chart-legend': true, [`chart-legend--${this.direction}`]: true }}>
|
|
62
|
-
{/* mouseleave lives on the list, not each row — the row-gap between items is still
|
|
63
|
-
inside the list's box, so crossing it while moving between rows never fires this.
|
|
64
|
-
Only actually leaving the whole list does, and that clears with no delay. */}
|
|
65
|
-
<ul class="chart-legend__list" onMouseLeave={() => this.handleHover(null)}>
|
|
66
|
-
{this.items.map((item, i) => {
|
|
67
|
-
const isDimmed = highlightLabel != null && item.label !== highlightLabel;
|
|
68
|
-
const RowTag = item.href ? 'a' : 'div';
|
|
69
|
-
|
|
70
|
-
return (
|
|
71
|
-
<li class="chart-legend__list-item" key={item.label}>
|
|
72
|
-
<RowTag
|
|
73
|
-
class={{
|
|
74
|
-
'chart-legend__item': true,
|
|
75
|
-
'chart-legend__item--interactive': !!item.href,
|
|
76
|
-
'ds-control--md': true,
|
|
77
|
-
'ds-interaction-fill': true,
|
|
78
|
-
'ds-focus-ring-inset': !!item.href,
|
|
79
|
-
}}
|
|
80
|
-
style={{ opacity: isDimmed ? String(DIMMED_OPACITY) : '1' }}
|
|
81
|
-
href={item.href}
|
|
82
|
-
onClick={item.href ? (e: MouseEvent) => this.handleClick(item, e) : undefined}
|
|
83
|
-
onMouseEnter={() => this.handleHover(item)}
|
|
84
|
-
onFocus={() => this.handleHover(item)}
|
|
85
|
-
onBlur={() => this.handleHover(null)}
|
|
86
|
-
>
|
|
87
|
-
<span class="chart-legend__swatch-box">
|
|
88
|
-
<span class="chart-legend__swatch" style={{ backgroundColor: item.color ?? categoryColor(i) }} />
|
|
89
|
-
</span>
|
|
90
|
-
<ds-text
|
|
91
|
-
class="chart-legend__label"
|
|
92
|
-
as="span"
|
|
93
|
-
variant="text-body-medium"
|
|
94
|
-
color="secondary"
|
|
95
|
-
lineTruncation={1}
|
|
96
|
-
title={item.label}
|
|
97
|
-
>
|
|
98
|
-
{item.label}
|
|
99
|
-
</ds-text>
|
|
100
|
-
{item.value != null && (
|
|
101
|
-
<ds-text
|
|
102
|
-
class="chart-legend__value"
|
|
103
|
-
as="span"
|
|
104
|
-
variant="text-body-medium"
|
|
105
|
-
color="primary"
|
|
106
|
-
lineTruncation={1}
|
|
107
|
-
title={String(item.value)}
|
|
108
|
-
>
|
|
109
|
-
{formatCompactNumber(item.value)}
|
|
110
|
-
</ds-text>
|
|
111
|
-
)}
|
|
112
|
-
{item.value != null && this.showPercentage && (
|
|
113
|
-
<ds-text class="chart-legend__percentage" as="span" variant="text-body-medium" color="primary">
|
|
114
|
-
{(total ? (item.value / total) * 100 : 0).toFixed(1)}%
|
|
115
|
-
</ds-text>
|
|
116
|
-
)}
|
|
117
|
-
</RowTag>
|
|
118
|
-
</li>
|
|
119
|
-
);
|
|
120
|
-
})}
|
|
121
|
-
</ul>
|
|
122
|
-
</Host>
|
|
123
|
-
);
|
|
124
|
-
}
|
|
125
|
-
}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, h, Host } from '@stencil/core';
|
|
2
|
-
import { line as lineShape } from 'd3-shape';
|
|
3
|
-
import { scaleLinear, scalePoint } from 'd3-scale';
|
|
4
|
-
import { max } from 'd3-array';
|
|
5
|
-
import { categoryColor } from '../../utils/chart-colors';
|
|
6
|
-
import type { ChartSeries } from '../../utils/chart-types';
|
|
7
|
-
|
|
8
|
-
const MARGIN = { top: 16, right: 16, bottom: 24, left: 32 };
|
|
9
|
-
|
|
10
|
-
@Component({
|
|
11
|
-
tag: 'ds-chart-line',
|
|
12
|
-
styleUrl: 'ChartLine.css',
|
|
13
|
-
scoped: true,
|
|
14
|
-
})
|
|
15
|
-
export class ChartLine {
|
|
16
|
-
/** One or more series to plot. Set as a JS property (not an HTML attribute). */
|
|
17
|
-
@Prop() series: ChartSeries[] = [];
|
|
18
|
-
/** X-axis labels — must match each series' `data` length. Set as a JS property. */
|
|
19
|
-
@Prop() categories: string[] = [];
|
|
20
|
-
@Prop() width: number = 480;
|
|
21
|
-
@Prop() height: number = 240;
|
|
22
|
-
@Prop() showPoints: boolean = true;
|
|
23
|
-
|
|
24
|
-
render() {
|
|
25
|
-
const innerWidth = this.width - MARGIN.left - MARGIN.right;
|
|
26
|
-
const innerHeight = this.height - MARGIN.top - MARGIN.bottom;
|
|
27
|
-
|
|
28
|
-
const allValues = this.series.flatMap(s => s.data);
|
|
29
|
-
const yMax = max(allValues) ?? 0;
|
|
30
|
-
|
|
31
|
-
const xScale = scalePoint<number>()
|
|
32
|
-
.domain(this.categories.map((_, i) => i))
|
|
33
|
-
.range([0, innerWidth]);
|
|
34
|
-
|
|
35
|
-
const yScale = scaleLinear()
|
|
36
|
-
.domain([0, yMax || 1])
|
|
37
|
-
.range([innerHeight, 0])
|
|
38
|
-
.nice();
|
|
39
|
-
|
|
40
|
-
const lineGenerator = lineShape<number>()
|
|
41
|
-
.x((_, i) => xScale(i) ?? 0)
|
|
42
|
-
.y(d => yScale(d));
|
|
43
|
-
|
|
44
|
-
const yTicks = yScale.ticks(4);
|
|
45
|
-
|
|
46
|
-
return (
|
|
47
|
-
<Host class="chart-line">
|
|
48
|
-
<svg
|
|
49
|
-
class="chart-line__svg"
|
|
50
|
-
viewBox={`0 0 ${this.width} ${this.height}`}
|
|
51
|
-
width={this.width}
|
|
52
|
-
height={this.height}
|
|
53
|
-
role="img"
|
|
54
|
-
aria-label={this.series.map(s => s.name).join(', ')}
|
|
55
|
-
>
|
|
56
|
-
<g transform={`translate(${MARGIN.left}, ${MARGIN.top})`}>
|
|
57
|
-
{yTicks.map(tick => (
|
|
58
|
-
<g key={`grid-${tick}`} transform={`translate(0, ${yScale(tick)})`}>
|
|
59
|
-
<line class="chart-line__gridline" x1={0} x2={innerWidth} />
|
|
60
|
-
<text class="chart-line__axis-label" x={-8} text-anchor="end" dominant-baseline="middle">
|
|
61
|
-
{tick}
|
|
62
|
-
</text>
|
|
63
|
-
</g>
|
|
64
|
-
))}
|
|
65
|
-
|
|
66
|
-
{this.categories.map((label, i) => (
|
|
67
|
-
<text
|
|
68
|
-
key={`x-${label}`}
|
|
69
|
-
class="chart-line__axis-label"
|
|
70
|
-
x={xScale(i) ?? 0}
|
|
71
|
-
y={innerHeight + 16}
|
|
72
|
-
text-anchor="middle"
|
|
73
|
-
>
|
|
74
|
-
{label}
|
|
75
|
-
</text>
|
|
76
|
-
))}
|
|
77
|
-
|
|
78
|
-
{this.series.map((s, si) => {
|
|
79
|
-
const color = s.color ?? categoryColor(si);
|
|
80
|
-
return (
|
|
81
|
-
<g key={s.name}>
|
|
82
|
-
<path class="chart-line__path" d={lineGenerator(s.data) ?? undefined} stroke={color} />
|
|
83
|
-
{this.showPoints &&
|
|
84
|
-
s.data.map((d, i) => (
|
|
85
|
-
<circle
|
|
86
|
-
key={`${s.name}-${i}`}
|
|
87
|
-
class="chart-line__point"
|
|
88
|
-
cx={xScale(i) ?? 0}
|
|
89
|
-
cy={yScale(d)}
|
|
90
|
-
r={3}
|
|
91
|
-
fill={color}
|
|
92
|
-
/>
|
|
93
|
-
))}
|
|
94
|
-
</g>
|
|
95
|
-
);
|
|
96
|
-
})}
|
|
97
|
-
</g>
|
|
98
|
-
</svg>
|
|
99
|
-
</Host>
|
|
100
|
-
);
|
|
101
|
-
}
|
|
102
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { ChartSeries } from '../../utils/chart-types';
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, Event, EventEmitter, h, Host } from '@stencil/core';
|
|
2
|
-
|
|
3
|
-
let idCounter = 0;
|
|
4
|
-
|
|
5
|
-
@Component({
|
|
6
|
-
tag: 'ds-checkbox',
|
|
7
|
-
styleUrl: 'Checkbox.css',
|
|
8
|
-
scoped: true,
|
|
9
|
-
})
|
|
10
|
-
export class Checkbox {
|
|
11
|
-
private labelId = `ds-checkbox-label-${++idCounter}`;
|
|
12
|
-
|
|
13
|
-
@Prop() label!: string;
|
|
14
|
-
@Prop({ mutable: true }) checked: boolean = false;
|
|
15
|
-
@Prop() indeterminate: boolean = false;
|
|
16
|
-
@Prop() isInactive: boolean = false;
|
|
17
|
-
|
|
18
|
-
@Event() dsChange!: EventEmitter<boolean>;
|
|
19
|
-
|
|
20
|
-
private handleActivate = () => {
|
|
21
|
-
if (this.isInactive) return;
|
|
22
|
-
this.checked = !this.checked;
|
|
23
|
-
this.dsChange.emit(this.checked);
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
private handleKeyDown = (e: KeyboardEvent) => {
|
|
27
|
-
if (e.key === ' ' || e.key === 'Enter') {
|
|
28
|
-
e.preventDefault();
|
|
29
|
-
this.handleActivate();
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
|
|
33
|
-
render() {
|
|
34
|
-
const isMarked = this.checked || this.indeterminate;
|
|
35
|
-
|
|
36
|
-
return (
|
|
37
|
-
<Host
|
|
38
|
-
role="checkbox"
|
|
39
|
-
aria-checked={this.indeterminate ? 'mixed' : String(this.checked)}
|
|
40
|
-
aria-disabled={this.isInactive || undefined}
|
|
41
|
-
aria-labelledby={this.labelId}
|
|
42
|
-
tabIndex={this.isInactive ? -1 : 0}
|
|
43
|
-
class={{ checkbox: true, 'ds-control-inactive': this.isInactive }}
|
|
44
|
-
onClick={this.handleActivate}
|
|
45
|
-
onKeyDown={this.handleKeyDown}
|
|
46
|
-
>
|
|
47
|
-
<span class={{ box: true, 'box--marked': isMarked }}>
|
|
48
|
-
{isMarked && (
|
|
49
|
-
<span class="checkmark" aria-hidden="true">
|
|
50
|
-
{this.indeterminate ? '−' : '✓'}
|
|
51
|
-
</span>
|
|
52
|
-
)}
|
|
53
|
-
</span>
|
|
54
|
-
<ds-text class="checkbox__label" as="span" variant="text-body-medium" textId={this.labelId}>
|
|
55
|
-
{this.label}
|
|
56
|
-
</ds-text>
|
|
57
|
-
</Host>
|
|
58
|
-
);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { } from './Checkbox';
|
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, Event, EventEmitter, h, Host } from '@stencil/core';
|
|
2
|
-
import { CONTROL_TEXT_VARIANT } from '../../utils';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Semantic chip state — replaces Tag’s intent × contrast matrix.
|
|
6
|
-
* - `default` — neutral faint
|
|
7
|
-
* - `active` — brand faint
|
|
8
|
-
* - `error` — negative faint
|
|
9
|
-
* - `caution` — caution faint
|
|
10
|
-
*/
|
|
11
|
-
export type ChipState = 'default' | 'active' | 'error' | 'caution';
|
|
12
|
-
export type ChipSize = 'md' | 'sm' | 'xs';
|
|
13
|
-
export type ChipBackground = 'faint' | 'medium' | 'bold' | 'strong' | 'always-dark';
|
|
14
|
-
|
|
15
|
-
/** Dismiss `ds-icon` size — same iconography metrics as Tag’s leading icon. */
|
|
16
|
-
const ICON_SIZE: Record<ChipSize, 'md' | 'sm' | 'xs'> = {
|
|
17
|
-
md: 'md',
|
|
18
|
-
sm: 'sm',
|
|
19
|
-
xs: 'xs',
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* Removable chip — same density recipe as Tag, but colored by semantic `state`
|
|
24
|
-
* (not intent × contrast). Not a toggle/select control; the only intentional
|
|
25
|
-
* action is remove.
|
|
26
|
-
*/
|
|
27
|
-
@Component({
|
|
28
|
-
tag: 'ds-chip',
|
|
29
|
-
styleUrl: 'Chip.css',
|
|
30
|
-
scoped: true,
|
|
31
|
-
})
|
|
32
|
-
export class Chip {
|
|
33
|
-
@Prop() label!: string;
|
|
34
|
-
/** Semantic color state. @default 'default' */
|
|
35
|
-
@Prop() state: ChipState = 'default';
|
|
36
|
-
@Prop() size: ChipSize = 'md';
|
|
37
|
-
@Prop() rounded: boolean = false;
|
|
38
|
-
/** When true (default), shows the trailing dismiss control. */
|
|
39
|
-
@Prop() removable: boolean = true;
|
|
40
|
-
@Prop() maxWidth: string | number | undefined;
|
|
41
|
-
@Prop() isInactive: boolean = false;
|
|
42
|
-
/** Surface context for interaction-fill tokens when the chip sits on a non-default surface. */
|
|
43
|
-
@Prop() background: ChipBackground | undefined;
|
|
44
|
-
|
|
45
|
-
/** Fired when the remove button is clicked. */
|
|
46
|
-
@Event() dsRemove!: EventEmitter<void>;
|
|
47
|
-
|
|
48
|
-
private handleRemove = (e: MouseEvent) => {
|
|
49
|
-
e.stopPropagation();
|
|
50
|
-
if (this.isInactive) return;
|
|
51
|
-
this.dsRemove.emit();
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
render() {
|
|
55
|
-
const textVariant = CONTROL_TEXT_VARIANT[this.size];
|
|
56
|
-
const iconSize = ICON_SIZE[this.size];
|
|
57
|
-
|
|
58
|
-
const maxWidthStyle = this.maxWidth != null
|
|
59
|
-
? { maxWidth: typeof this.maxWidth === 'number' ? `${this.maxWidth}px` : this.maxWidth }
|
|
60
|
-
: undefined;
|
|
61
|
-
|
|
62
|
-
return (
|
|
63
|
-
<Host
|
|
64
|
-
class={{
|
|
65
|
-
'tag': true,
|
|
66
|
-
'chip': true,
|
|
67
|
-
[`chip--${this.state}`]: true,
|
|
68
|
-
[`tag--size-${this.size}`]: true,
|
|
69
|
-
'ds-control--md': this.size === 'md',
|
|
70
|
-
'ds-control--sm': this.size === 'sm',
|
|
71
|
-
'ds-control--xs': this.size === 'xs',
|
|
72
|
-
'tag--rounded': this.rounded,
|
|
73
|
-
'tag--removable': this.removable,
|
|
74
|
-
/* Hover overlay on the chip surface — dismiss is the only action. */
|
|
75
|
-
'ds-interaction-fill': !this.isInactive && this.removable,
|
|
76
|
-
'ds-interaction-fill--on-medium': this.background === 'medium',
|
|
77
|
-
'ds-interaction-fill--on-bold': this.background === 'bold',
|
|
78
|
-
'ds-interaction-fill--on-strong': this.background === 'strong',
|
|
79
|
-
'ds-interaction-fill--on-always-dark': this.background === 'always-dark',
|
|
80
|
-
'ds-control-inactive': this.isInactive,
|
|
81
|
-
}}
|
|
82
|
-
style={maxWidthStyle}
|
|
83
|
-
aria-disabled={this.isInactive || undefined}
|
|
84
|
-
>
|
|
85
|
-
<ds-text class="tag__label" as="span" variant={textVariant} color="inherit">
|
|
86
|
-
{this.label}
|
|
87
|
-
</ds-text>
|
|
88
|
-
{this.removable && (
|
|
89
|
-
<button
|
|
90
|
-
type="button"
|
|
91
|
-
class="tag__remove ds-focus-ring-inset"
|
|
92
|
-
onClick={this.handleRemove}
|
|
93
|
-
aria-label={`Remove ${this.label}`}
|
|
94
|
-
disabled={this.isInactive || undefined}
|
|
95
|
-
>
|
|
96
|
-
<slot name="remove-icon">
|
|
97
|
-
<ds-icon class="tag__remove-x" name="Cross" size={iconSize} color="inherit"></ds-icon>
|
|
98
|
-
</slot>
|
|
99
|
-
</button>
|
|
100
|
-
)}
|
|
101
|
-
</Host>
|
|
102
|
-
);
|
|
103
|
-
}
|
|
104
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { ChipState, ChipSize, ChipBackground } from './Chip';
|
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, h, Host } from '@stencil/core';
|
|
2
|
-
|
|
3
|
-
export type DividerOrientation = 'horizontal' | 'vertical';
|
|
4
|
-
export type DividerSurface =
|
|
5
|
-
| 'default'
|
|
6
|
-
| 'on-bold-background'
|
|
7
|
-
| 'on-strong-background'
|
|
8
|
-
| 'on-medium-background'
|
|
9
|
-
| 'on-translucent-background'
|
|
10
|
-
| 'navigation'
|
|
11
|
-
| 'media'
|
|
12
|
-
| 'always-dark'
|
|
13
|
-
| 'inverted';
|
|
14
|
-
export type DividerInsetToken =
|
|
15
|
-
| 'space-000'
|
|
16
|
-
| 'space-012'
|
|
17
|
-
| 'space-025'
|
|
18
|
-
| 'space-050'
|
|
19
|
-
| 'space-075'
|
|
20
|
-
| 'space-100'
|
|
21
|
-
| 'space-125'
|
|
22
|
-
| 'space-150'
|
|
23
|
-
| 'space-175'
|
|
24
|
-
| 'space-200'
|
|
25
|
-
| 'space-250'
|
|
26
|
-
| 'space-300'
|
|
27
|
-
| 'space-400'
|
|
28
|
-
| 'space-600'
|
|
29
|
-
| 'space-800';
|
|
30
|
-
export type DividerInset = 'none' | DividerInsetToken | (string & {});
|
|
31
|
-
export type DividerLength = 'auto' | 'full' | (string & {});
|
|
32
|
-
|
|
33
|
-
const INSET_VALUE: Record<'none' | DividerInsetToken, string> = {
|
|
34
|
-
none: '0',
|
|
35
|
-
'space-000': 'var(--dimension-space-000)',
|
|
36
|
-
'space-012': 'var(--dimension-space-012)',
|
|
37
|
-
'space-025': 'var(--dimension-space-025)',
|
|
38
|
-
'space-050': 'var(--dimension-space-050)',
|
|
39
|
-
'space-075': 'var(--dimension-space-075)',
|
|
40
|
-
'space-100': 'var(--dimension-space-100)',
|
|
41
|
-
'space-125': 'var(--dimension-space-125)',
|
|
42
|
-
'space-150': 'var(--dimension-space-150)',
|
|
43
|
-
'space-175': 'var(--dimension-space-175)',
|
|
44
|
-
'space-200': 'var(--dimension-space-200)',
|
|
45
|
-
'space-250': 'var(--dimension-space-250)',
|
|
46
|
-
'space-300': 'var(--dimension-space-300)',
|
|
47
|
-
'space-400': 'var(--dimension-space-400)',
|
|
48
|
-
'space-600': 'var(--dimension-space-600)',
|
|
49
|
-
'space-800': 'var(--dimension-space-800)',
|
|
50
|
-
};
|
|
51
|
-
|
|
52
|
-
@Component({
|
|
53
|
-
tag: 'ds-divider',
|
|
54
|
-
styleUrl: 'Divider.css',
|
|
55
|
-
scoped: true,
|
|
56
|
-
})
|
|
57
|
-
export class Divider {
|
|
58
|
-
/** Direction of the divider line. Defaults to 'horizontal'. */
|
|
59
|
-
@Prop() orientation: DividerOrientation = 'horizontal';
|
|
60
|
-
|
|
61
|
-
/** Surface context so the divider uses the right TokoMo divider token. */
|
|
62
|
-
@Prop() surface: DividerSurface = 'default';
|
|
63
|
-
|
|
64
|
-
/** Insets the divider from its start/end edges. Accepts spacing token names or any CSS length. */
|
|
65
|
-
@Prop() inset: DividerInset = 'none';
|
|
66
|
-
|
|
67
|
-
/** Visual line length. Defaults to filling the available axis. Accepts any CSS length. */
|
|
68
|
-
@Prop() length: DividerLength = 'auto';
|
|
69
|
-
|
|
70
|
-
/** Expose the divider as a semantic separator. Visual-only dividers are hidden from assistive tech by default. */
|
|
71
|
-
@Prop() semantic: boolean = false;
|
|
72
|
-
|
|
73
|
-
private resolveInset(): string {
|
|
74
|
-
return Object.prototype.hasOwnProperty.call(INSET_VALUE, this.inset)
|
|
75
|
-
? INSET_VALUE[this.inset as keyof typeof INSET_VALUE]
|
|
76
|
-
: this.inset;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
private resolveLength(): string {
|
|
80
|
-
return this.length === 'auto' || this.length === 'full'
|
|
81
|
-
? '100%'
|
|
82
|
-
: this.length;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
render() {
|
|
86
|
-
const isVertical = this.orientation === 'vertical';
|
|
87
|
-
const hasCustomLength = this.length !== 'auto' && this.length !== 'full';
|
|
88
|
-
|
|
89
|
-
return (
|
|
90
|
-
<Host
|
|
91
|
-
role={this.semantic ? 'separator' : undefined}
|
|
92
|
-
aria-orientation={this.semantic ? this.orientation : undefined}
|
|
93
|
-
aria-hidden={this.semantic ? undefined : 'true'}
|
|
94
|
-
class={{
|
|
95
|
-
divider: true,
|
|
96
|
-
'divider--vertical': isVertical,
|
|
97
|
-
'divider--custom-length': hasCustomLength,
|
|
98
|
-
[`divider--surface-${this.surface}`]: true,
|
|
99
|
-
}}
|
|
100
|
-
style={{
|
|
101
|
-
'--_divider-inset': this.resolveInset(),
|
|
102
|
-
'--_divider-length': this.resolveLength(),
|
|
103
|
-
}}
|
|
104
|
-
/>
|
|
105
|
-
);
|
|
106
|
-
}
|
|
107
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, h, Host } from '@stencil/core';
|
|
2
|
-
|
|
3
|
-
export type EmptyStateType = 'no-content' | 'no-results' | 'no-results-filter' | 'no-access';
|
|
4
|
-
|
|
5
|
-
const DEFAULT_MESSAGES: Record<EmptyStateType, string> = {
|
|
6
|
-
'no-content': 'No page contents to display.',
|
|
7
|
-
'no-results': 'No results found.',
|
|
8
|
-
'no-results-filter': 'No results found. Please update search criteria.',
|
|
9
|
-
'no-access': "You don't have access to this page.",
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
@Component({
|
|
13
|
-
tag: 'ds-empty-state',
|
|
14
|
-
styleUrl: 'EmptyState.css',
|
|
15
|
-
scoped: true,
|
|
16
|
-
})
|
|
17
|
-
export class EmptyState {
|
|
18
|
-
@Prop() type: EmptyStateType = 'no-content';
|
|
19
|
-
@Prop() message: string | undefined;
|
|
20
|
-
|
|
21
|
-
render() {
|
|
22
|
-
return (
|
|
23
|
-
<Host>
|
|
24
|
-
<ds-text class="empty-state" as="p" variant="text-body-medium" color="secondary">
|
|
25
|
-
{this.message || DEFAULT_MESSAGES[this.type]}
|
|
26
|
-
</ds-text>
|
|
27
|
-
</Host>
|
|
28
|
-
);
|
|
29
|
-
}
|
|
30
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { Component, Prop, h, Host } from '@stencil/core';
|
|
2
|
-
|
|
3
|
-
let fieldCounter = 0;
|
|
4
|
-
|
|
5
|
-
@Component({
|
|
6
|
-
tag: 'ds-field',
|
|
7
|
-
styleUrl: 'Field.css',
|
|
8
|
-
scoped: true,
|
|
9
|
-
})
|
|
10
|
-
export class Field {
|
|
11
|
-
@Prop() label!: string;
|
|
12
|
-
/** ID forwarded to the slotted control via the label's `for` attribute. Auto-generated if omitted. */
|
|
13
|
-
@Prop() fieldId: string | undefined;
|
|
14
|
-
|
|
15
|
-
private resolvedId = `ds-field-${++fieldCounter}`;
|
|
16
|
-
|
|
17
|
-
render() {
|
|
18
|
-
const id = this.fieldId || this.resolvedId;
|
|
19
|
-
return (
|
|
20
|
-
<Host>
|
|
21
|
-
<div class="field">
|
|
22
|
-
<ds-text as="label" variant="text-body-small" emphasis for={id}>
|
|
23
|
-
{this.label}
|
|
24
|
-
</ds-text>
|
|
25
|
-
<slot />
|
|
26
|
-
</div>
|
|
27
|
-
</Host>
|
|
28
|
-
);
|
|
29
|
-
}
|
|
30
|
-
}
|