@ids-group-ltd/ids-design-system 0.14.8 → 0.15.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/CHANGELOG.md +1145 -234
- package/components.md +122 -53
- package/docs/agent/INDEX.md +5 -3
- package/docs/agent/charts/column-series-component.md +1 -1
- package/docs/agent/charts/ds-bar-chart.md +7 -4
- package/docs/agent/charts/ds-chart.md +1 -1
- package/docs/agent/charts/ds-column-chart.md +2 -1
- package/docs/agent/charts/ds-funnel-chart.md +1 -1
- package/docs/agent/charts/ds-heatmap-chart.md +2 -1
- package/docs/agent/charts/ds-line-chart.md +3 -3
- package/docs/agent/charts/ds-pie-chart.md +3 -2
- package/docs/agent/charts/ds-scatter-chart.md +2 -1
- package/docs/agent/charts/ds-waterfall-chart.md +2 -2
- package/docs/agent/charts/line-series-component.md +1 -1
- package/docs/agent/feedback/ds-alert.md +1 -0
- package/docs/agent/feedback/ds-banner.md +1 -0
- package/docs/agent/feedback/ds-loading-overlay.md +2 -0
- package/docs/agent/feedback/ds-skeleton.md +1 -1
- package/docs/agent/feedback/ds-toast.md +2 -0
- package/docs/agent/forms/ds-autocomplete.md +1 -1
- package/docs/agent/forms/ds-button.md +1 -0
- package/docs/agent/forms/ds-checkbox.md +1 -1
- package/docs/agent/forms/ds-color-picker.md +1 -1
- package/docs/agent/forms/ds-date-picker.md +2 -1
- package/docs/agent/forms/ds-icon-button.md +1 -1
- package/docs/agent/forms/ds-input.md +1 -1
- package/docs/agent/forms/ds-multi-select.md +1 -1
- package/docs/agent/forms/ds-otp-input.md +1 -1
- package/docs/agent/forms/ds-radio-group.md +1 -1
- package/docs/agent/forms/ds-segmented.md +1 -1
- package/docs/agent/forms/ds-select.md +1 -1
- package/docs/agent/forms/ds-slider.md +1 -1
- package/docs/agent/forms/ds-switch.md +1 -1
- package/docs/agent/forms/ds-textarea.md +1 -1
- package/docs/agent/forms/ds-time-picker.md +1 -1
- package/docs/agent/forms/the-picker-family-ds-select-ds-multi-select-ds-autocomplete.md +1 -1
- package/docs/agent/foundations/global-helper-classes.md +4 -4
- package/docs/agent/foundations/tokens.md +1 -1
- package/docs/agent/navigation/ds-pagination.md +2 -1
- package/docs/agent/overlays/ds-bottom-sheet.md +1 -1
- package/docs/agent/overlays/ds-definition-term.md +10 -0
- package/docs/agent/overlays/ds-drawer.md +1 -1
- package/docs/agent/overlays/ds-info-hint.md +29 -0
- package/docs/agent/overlays/ds-menu.md +1 -1
- package/docs/agent/overlays/ds-modal-card.md +1 -1
- package/docs/agent/overlays/ds-modal.md +19 -1
- package/docs/agent/overlays/ds-tooltip-panel.md +1 -1
- package/docs/agent/overlays/ds-tooltip.md +3 -3
- package/docs/agent/tables/ds-table-columns.md +2 -0
- package/docs/agent/tables/ds-table.md +4 -3
- package/eslint/deprecated-api.json +889 -0
- package/eslint/index.mjs +394 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-accordion.mjs +4 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-accordion.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-alert.mjs +6 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-alert.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-app-layout.mjs +6 -12
- package/fesm2022/ids-group-ltd-ids-design-system-components-app-layout.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-auth-layout.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-auth-layout.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-autocomplete.mjs +27 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-autocomplete.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-avatar-group.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-avatar-group.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-avatar.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-avatar.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-badge.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-badge.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-banner.mjs +6 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-banner.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-bar-chart.mjs +169 -37
- package/fesm2022/ids-group-ltd-ids-design-system-components-bar-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-bar.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-bar.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-bottom-sheet.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-bottom-sheet.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-breadcrumbs.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-button-group.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-button-group.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs +8 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-calendar-day.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-calendar-day.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-card.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-card.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-data-table.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-data-table.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-legend.mjs +7 -17
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-legend.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-tooltip.mjs +875 -90
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-tooltip.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart.mjs +2183 -1232
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-checkbox.mjs +10 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-checkbox.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs +15 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-column-chart.mjs +50 -11
- package/fesm2022/ids-group-ltd-ids-design-system-components-column-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs +22 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-definition-term.mjs +107 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-definition-term.mjs.map +1 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-description-list.mjs +4 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-description-list.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-divider.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-divider.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs +5 -15
- package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-dropzone.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-dropzone.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-empty-state.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-empty-state.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-field-group.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-field-group.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-field-message.mjs +44 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-field-message.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-filter-bar.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-filter-bar.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-funnel-chart.mjs +11 -22
- package/fesm2022/ids-group-ltd-ids-design-system-components-funnel-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-heatmap-chart.mjs +51 -21
- package/fesm2022/ids-group-ltd-ids-design-system-components-heatmap-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-icon-button.mjs +5 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-icon-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-info-hint.mjs +110 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-info-hint.mjs.map +1 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-input.mjs +11 -7
- package/fesm2022/ids-group-ltd-ids-design-system-components-input.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-layout.mjs +6 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-layout.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-line-chart.mjs +41 -46
- package/fesm2022/ids-group-ltd-ids-design-system-components-line-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-list.mjs +4 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-list.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-loading-overlay.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-loading-overlay.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-menu.mjs +183 -31
- package/fesm2022/ids-group-ltd-ids-design-system-components-menu.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-modal.mjs +21 -26
- package/fesm2022/ids-group-ltd-ids-design-system-components-modal.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-multi-select.mjs +27 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-multi-select.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-number-stepper.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-number-stepper.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-otp-input.mjs +10 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-otp-input.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-page-footer.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-page-footer.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-page-header.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-page-header.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-pagination.mjs +14 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-pagination.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-password-rules.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-password-rules.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-pie-chart.mjs +106 -29
- package/fesm2022/ids-group-ltd-ids-design-system-components-pie-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-popover.mjs +7 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-popover.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-radio-group.mjs +12 -7
- package/fesm2022/ids-group-ltd-ids-design-system-components-radio-group.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-scatter-chart.mjs +140 -26
- package/fesm2022/ids-group-ltd-ids-design-system-components-scatter-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-search.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-search.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-segmented.mjs +10 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-segmented.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs +29 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-show-dirty.mjs +55 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-show-dirty.mjs.map +1 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav-footer.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav-footer.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav.mjs +6 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-skeleton.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-skeleton.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-slider.mjs +10 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-slider.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-sparkline.mjs +5 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-sparkline.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-spinner.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-spinner.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-split-button.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-split-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-stat.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-stat.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-status-dot.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-status-dot.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-stepper.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-stepper.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-switch.mjs +10 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-switch.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-table-columns.mjs +36 -18
- package/fesm2022/ids-group-ltd-ids-design-system-components-table-columns.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-table-export.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-table-export.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-table-resize.mjs +17 -0
- package/fesm2022/ids-group-ltd-ids-design-system-components-table-resize.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-table.mjs +193 -19
- package/fesm2022/ids-group-ltd-ids-design-system-components-table.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-tabs.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-tabs.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-tag.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-tag.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-textarea.mjs +15 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-textarea.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs +26 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-timeline.mjs +4 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-timeline.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-toast.mjs +20 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-toast.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-toggle-button.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-toggle-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-tooltip.mjs +434 -157
- package/fesm2022/ids-group-ltd-ids-design-system-components-tooltip.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-topbar.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-topbar.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-tree.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-tree.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-w3w.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-w3w.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-waterfall-chart.mjs +18 -11
- package/fesm2022/ids-group-ltd-ids-design-system-components-waterfall-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components.mjs +323 -68
- package/fesm2022/ids-group-ltd-ids-design-system-components.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-core.mjs +27 -83
- package/fesm2022/ids-group-ltd-ids-design-system-core.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-icons.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-icons.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-overlay.mjs +1 -0
- package/fesm2022/ids-group-ltd-ids-design-system-overlay.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system.mjs +3 -0
- package/fesm2022/ids-group-ltd-ids-design-system.mjs.map +1 -1
- package/migrations/0.10.0.json +79 -21
- package/migrations/0.10.1.json +38 -21
- package/migrations/0.10.2.json +44 -7
- package/migrations/0.10.3.json +7 -5
- package/migrations/0.11.0.json +10 -7
- package/migrations/0.11.1.json +25 -14
- package/migrations/0.11.2.json +3 -3
- package/migrations/0.11.3.json +9 -6
- package/migrations/0.11.4.json +13 -12
- package/migrations/0.12.1.json +41 -14
- package/migrations/0.12.2.json +7 -6
- package/migrations/0.12.3.json +3 -3
- package/migrations/0.13.0.json +11 -11
- package/migrations/0.13.1.json +60 -8
- package/migrations/0.13.2.json +98 -44
- package/migrations/0.13.3.json +46 -16
- package/migrations/0.13.4.json +23 -22
- package/migrations/0.14.0.json +5 -5
- package/migrations/0.14.1.json +5 -5
- package/migrations/0.14.2.json +1 -1
- package/migrations/0.14.4.json +6 -5
- package/migrations/0.14.5.json +13 -7
- package/migrations/0.14.6.json +2 -2
- package/migrations/0.14.8.json +26 -2
- package/migrations/0.15.0.json +999 -0
- package/migrations/0.15.1.json +738 -0
- package/migrations/0.2.0.json +2 -2
- package/migrations/0.3.0.json +43 -6
- package/migrations/0.4.0.json +95 -13
- package/migrations/0.5.0.json +116 -10
- package/migrations/0.5.1.json +97 -11
- package/migrations/0.6.0.json +30 -1
- package/migrations/0.6.1.json +22 -1
- package/migrations/0.6.2.json +8 -4
- package/migrations/0.6.3.json +17 -5
- package/migrations/0.7.0.json +58 -9
- package/migrations/0.7.1.json +62 -8
- package/migrations/0.8.0.json +60 -12
- package/migrations/0.9.0.json +68 -25
- package/migrations/0.9.1.json +1 -1
- package/migrations/README.md +57 -3
- package/package.json +27 -1
- package/schematics/check-overrides/index.cjs +4 -11
- package/schematics/check-overrides/scan.cjs +12 -1
- package/schematics/check-overrides/surface.json +94 -11
- package/schematics/ng-add/index.cjs +7 -1
- package/stylelint/deprecated-tokens.json +2711 -0
- package/stylelint/index.mjs +94 -0
- package/stylelint/since-version.mjs +26 -0
- package/styles/_chart-frame.scss +14 -0
- package/styles/_chart-interactive.scss +26 -1
- package/styles/_chart-motion.scss +50 -17
- package/styles/_chip-row.scss +5 -2
- package/styles/_clear-button.scss +2 -0
- package/styles/_component-base.scss +56 -0
- package/styles/_dismiss-button.scss +16 -0
- package/styles/_dropdown-overlay.scss +19 -0
- package/styles/_focus.scss +4 -1
- package/styles/_link.scss +35 -12
- package/styles/_overlay-motion.scss +4 -6
- package/styles/_pinned.scss +43 -0
- package/styles/_skeleton-shimmer.scss +2 -8
- package/styles/_table-controls.scss +4 -0
- package/styles/_target.scss +40 -0
- package/styles/_text-clip.scss +23 -4
- package/styles/_tokens.scss +3 -1
- package/styles/_typography.scss +2 -0
- package/styles/_visually-hidden.scss +2 -0
- package/styles/ds.scss +0 -1
- package/themes/README.md +60 -7
- package/themes/_semantic.scss +5 -8
- package/themes/dark/_theme.scss +5 -8
- package/types/ids-group-ltd-ids-design-system-components-alert.d.ts +1 -1
- package/types/ids-group-ltd-ids-design-system-components-autocomplete.d.ts +6 -1
- package/types/ids-group-ltd-ids-design-system-components-banner.d.ts +1 -1
- package/types/ids-group-ltd-ids-design-system-components-bar-chart.d.ts +74 -4
- package/types/ids-group-ltd-ids-design-system-components-button.d.ts +3 -2
- package/types/ids-group-ltd-ids-design-system-components-chart-legend.d.ts +4 -4
- package/types/ids-group-ltd-ids-design-system-components-chart-tooltip.d.ts +87 -7
- package/types/ids-group-ltd-ids-design-system-components-chart.d.ts +207 -29
- package/types/ids-group-ltd-ids-design-system-components-checkbox.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-color-picker.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-column-chart.d.ts +30 -4
- package/types/ids-group-ltd-ids-design-system-components-date-picker.d.ts +3 -1
- package/types/ids-group-ltd-ids-design-system-components-definition-term.d.ts +22 -0
- package/types/ids-group-ltd-ids-design-system-components-drawer.d.ts +0 -1
- package/types/ids-group-ltd-ids-design-system-components-field-message.d.ts +19 -2
- package/types/ids-group-ltd-ids-design-system-components-funnel-chart.d.ts +7 -6
- package/types/ids-group-ltd-ids-design-system-components-heatmap-chart.d.ts +22 -8
- package/types/ids-group-ltd-ids-design-system-components-icon-button.d.ts +3 -2
- package/types/ids-group-ltd-ids-design-system-components-info-hint.d.ts +23 -0
- package/types/ids-group-ltd-ids-design-system-components-input.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-line-chart.d.ts +18 -7
- package/types/ids-group-ltd-ids-design-system-components-menu.d.ts +14 -3
- package/types/ids-group-ltd-ids-design-system-components-modal.d.ts +0 -2
- package/types/ids-group-ltd-ids-design-system-components-multi-select.d.ts +6 -1
- package/types/ids-group-ltd-ids-design-system-components-otp-input.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-pagination.d.ts +5 -3
- package/types/ids-group-ltd-ids-design-system-components-pie-chart.d.ts +26 -7
- package/types/ids-group-ltd-ids-design-system-components-popover.d.ts +2 -1
- package/types/ids-group-ltd-ids-design-system-components-radio-group.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-scatter-chart.d.ts +52 -10
- package/types/ids-group-ltd-ids-design-system-components-segmented.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-select.d.ts +6 -1
- package/types/ids-group-ltd-ids-design-system-components-show-dirty.d.ts +29 -0
- package/types/ids-group-ltd-ids-design-system-components-slider.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-switch.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-table-resize.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-table.d.ts +39 -9
- package/types/ids-group-ltd-ids-design-system-components-textarea.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-time-picker.d.ts +3 -1
- package/types/ids-group-ltd-ids-design-system-components-toast.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-tooltip.d.ts +54 -24
- package/types/ids-group-ltd-ids-design-system-components-waterfall-chart.d.ts +9 -2
- package/types/ids-group-ltd-ids-design-system-components.d.ts +135 -35
- package/types/ids-group-ltd-ids-design-system-core.d.ts +46 -23
- package/types/ids-group-ltd-ids-design-system.d.ts +6 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { inject, computed, signal, PLATFORM_ID, DestroyRef, effect, InjectionToken, ElementRef, afterNextRender, NgZone, untracked, afterRenderEffect, TemplateRef, Directive, Injector, input, booleanAttribute, numberAttribute, DOCUMENT } from '@angular/core';
|
|
3
|
-
import { DS_CONFIG, reportDevWarning, injectDsLocale, DS_INTL
|
|
3
|
+
import { DS_CONFIG, reportDevWarning, resolveWithConfig, injectDsLocale, DS_INTL } from '@ids-group-ltd/ids-design-system/core';
|
|
4
4
|
import { isPlatformBrowser } from '@angular/common';
|
|
5
5
|
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
6
6
|
import { NgForm, FormGroupDirective, NgControl } from '@angular/forms';
|
|
@@ -575,16 +575,6 @@ function lineSegments(points) {
|
|
|
575
575
|
}
|
|
576
576
|
return segments;
|
|
577
577
|
}
|
|
578
|
-
/** `''` rather than a partial list when a coordinate is unplottable: one `NaN` voids the whole
|
|
579
|
-
* `points` attribute and the line vanishes silently.
|
|
580
|
-
*
|
|
581
|
-
* @internal */
|
|
582
|
-
function polylinePoints(segment) {
|
|
583
|
-
if (segment.length === 0 || !segment.every(isPlottable)) {
|
|
584
|
-
return '';
|
|
585
|
-
}
|
|
586
|
-
return segment.map((point) => coordinatePair(point)).join(' ');
|
|
587
|
-
}
|
|
588
578
|
/** Fritsch-Carlson tangents: the slope at each reading, clamped so no segment turns back on itself.
|
|
589
579
|
* A zero slope on either side pins the tangent flat, keeping a plateau flat. */
|
|
590
580
|
function monotoneTangents(segment) {
|
|
@@ -734,12 +724,6 @@ function niceDomain(domainMin, domainMax, targetCount) {
|
|
|
734
724
|
max: Math.ceil(domainMax / step) * step,
|
|
735
725
|
};
|
|
736
726
|
}
|
|
737
|
-
/** Distance between two ticks, which `formatTick` needs to pick a precision; a single tick has no step.
|
|
738
|
-
*
|
|
739
|
-
* @internal */
|
|
740
|
-
function tickStep(ticks) {
|
|
741
|
-
return ticks.length > 1 ? ticks[1] - ticks[0] : 0;
|
|
742
|
-
}
|
|
743
727
|
/** @internal */
|
|
744
728
|
function linearScale(domainMin, domainMax, rangeSize) {
|
|
745
729
|
const span = domainMax - domainMin;
|
|
@@ -748,42 +732,6 @@ function linearScale(domainMin, domainMax, rangeSize) {
|
|
|
748
732
|
}
|
|
749
733
|
return (value) => ((value - domainMin) / span) * rangeSize;
|
|
750
734
|
}
|
|
751
|
-
/** Positions for marks that sit at a category rather than inside it (a line's readings): first at
|
|
752
|
-
* the plot's start, last at its end, a single reading in the middle.
|
|
753
|
-
*
|
|
754
|
-
* `step` is the distance between neighbours; at the two ends that slot is half outside the plot and
|
|
755
|
-
* the caller clamps it.
|
|
756
|
-
*
|
|
757
|
-
* @internal */
|
|
758
|
-
function pointScale(count, rangeSize) {
|
|
759
|
-
const total = Number.isFinite(count) && count > 0 ? Math.floor(count) : 0;
|
|
760
|
-
const size = Number.isFinite(rangeSize) && rangeSize > 0 ? rangeSize : 0;
|
|
761
|
-
if (total === 0) {
|
|
762
|
-
return { step: 0, count: 0, position: () => 0, indexAt: () => -1 };
|
|
763
|
-
}
|
|
764
|
-
if (total === 1) {
|
|
765
|
-
return {
|
|
766
|
-
step: size,
|
|
767
|
-
count: 1,
|
|
768
|
-
position: () => size / 2,
|
|
769
|
-
indexAt: () => 0,
|
|
770
|
-
};
|
|
771
|
-
}
|
|
772
|
-
const step = size / (total - 1);
|
|
773
|
-
return {
|
|
774
|
-
step,
|
|
775
|
-
count: total,
|
|
776
|
-
position: (index) => Math.min(Math.max(index, 0), total - 1) * step,
|
|
777
|
-
// Nearest reading, not the slot the pointer is over: the end slots are half-width.
|
|
778
|
-
indexAt: (offset) => {
|
|
779
|
-
if (!Number.isFinite(offset) || step === 0) {
|
|
780
|
-
return -1;
|
|
781
|
-
}
|
|
782
|
-
const index = Math.round(offset / step);
|
|
783
|
-
return Math.min(Math.max(index, 0), total - 1);
|
|
784
|
-
},
|
|
785
|
-
};
|
|
786
|
-
}
|
|
787
735
|
/** @internal */
|
|
788
736
|
function bandScale(count, rangeSize, paddingRatio) {
|
|
789
737
|
if (count <= 0) {
|
|
@@ -846,12 +794,171 @@ function staggerDelay(index, count, stepMs) {
|
|
|
846
794
|
function leaveMark(event) {
|
|
847
795
|
event.target.classList.add('mark-leave');
|
|
848
796
|
}
|
|
797
|
+
// A CSS duration (`300ms`, `0.3s`) in milliseconds; anything unparsable is `0`.
|
|
798
|
+
function cssDurationMs(duration) {
|
|
799
|
+
const value = parseFloat(duration);
|
|
800
|
+
if (!Number.isFinite(value)) {
|
|
801
|
+
return 0;
|
|
802
|
+
}
|
|
803
|
+
return duration.trim().endsWith('ms') ? value : value * 1000;
|
|
804
|
+
}
|
|
805
|
+
/** How far a glide starts in. A glide re-aimed every frame, as a fast pointer re-aims it, otherwise
|
|
806
|
+
* draws its zero-progress frame each time and stands still until the pointer stops. @internal */
|
|
807
|
+
const CHART_GLIDE_HEAD_START_MS = 1000 / 30;
|
|
808
|
+
/** The duration and easing `element` inherits from `--ds-motion-chart-<timing>-*`, or `null` when the
|
|
809
|
+
* duration is zero, as under reduced motion.
|
|
810
|
+
*
|
|
811
|
+
* @internal */
|
|
812
|
+
function chartTiming(element, timing) {
|
|
813
|
+
const style = getComputedStyle(element);
|
|
814
|
+
const duration = cssDurationMs(style.getPropertyValue(`--ds-motion-chart-${timing}-duration`));
|
|
815
|
+
if (duration <= 0) {
|
|
816
|
+
return null;
|
|
817
|
+
}
|
|
818
|
+
return {
|
|
819
|
+
duration,
|
|
820
|
+
easing: style.getPropertyValue(`--ds-motion-chart-${timing}-easing`).trim() ||
|
|
821
|
+
'ease',
|
|
822
|
+
};
|
|
823
|
+
}
|
|
824
|
+
/** The delay `element` inherits from `--ds-motion-chart-<delay>-delay`, in milliseconds; `0` under
|
|
825
|
+
* reduced motion.
|
|
826
|
+
*
|
|
827
|
+
* @internal */
|
|
828
|
+
function chartDelay(element, delay) {
|
|
829
|
+
return cssDurationMs(getComputedStyle(element).getPropertyValue(`--ds-motion-chart-${delay}-delay`));
|
|
830
|
+
}
|
|
831
|
+
/** Eases `apply` from `from` to `to` on the timing `element` inherits (`--ds-motion-chart-<timing>-*`),
|
|
832
|
+
* for geometry CSS cannot interpolate. A zero duration, as under reduced motion, applies `to` at once.
|
|
833
|
+
* `onDone` runs after the last apply, inside this call when there is no motion. Returns the cancel;
|
|
834
|
+
* a caller starting the next tween cancels this one and passes what it last applied.
|
|
835
|
+
*
|
|
836
|
+
* Frames run in whatever zone the call runs in: call it outside Angular's zone, or every frame is
|
|
837
|
+
* an application tick.
|
|
838
|
+
*
|
|
839
|
+
* @internal */
|
|
840
|
+
function tweenMarks(element, from, to, apply, timing = 'mark', onDone = () => undefined) {
|
|
841
|
+
const eased = chartTiming(element, timing);
|
|
842
|
+
if (!eased ||
|
|
843
|
+
from.length !== to.length ||
|
|
844
|
+
typeof KeyframeEffect === 'undefined') {
|
|
845
|
+
apply(to);
|
|
846
|
+
onDone();
|
|
847
|
+
return () => undefined;
|
|
848
|
+
}
|
|
849
|
+
// A target-less effect is only a clock: it eases by the token's own curve, whatever its form.
|
|
850
|
+
const clock = new Animation(new KeyframeEffect(null, null, {
|
|
851
|
+
...eased,
|
|
852
|
+
delay: -CHART_GLIDE_HEAD_START_MS,
|
|
853
|
+
fill: 'forwards',
|
|
854
|
+
}));
|
|
855
|
+
let frame = 0;
|
|
856
|
+
const step = () => {
|
|
857
|
+
const progress = clock.effect?.getComputedTiming().progress ?? 1;
|
|
858
|
+
apply(to.map((value, index) => from[index] + (value - from[index]) * progress));
|
|
859
|
+
if (clock.playState !== 'finished') {
|
|
860
|
+
frame = requestAnimationFrame(step);
|
|
861
|
+
return;
|
|
862
|
+
}
|
|
863
|
+
onDone();
|
|
864
|
+
};
|
|
865
|
+
clock.play();
|
|
866
|
+
frame = requestAnimationFrame(step);
|
|
867
|
+
return () => {
|
|
868
|
+
cancelAnimationFrame(frame);
|
|
869
|
+
clock.cancel();
|
|
870
|
+
};
|
|
871
|
+
}
|
|
872
|
+
/** Runs `run` two frames from now, outside Angular's zone; returns the cancel.
|
|
873
|
+
*
|
|
874
|
+
* @internal */
|
|
875
|
+
function afterTwoFrames(zone, run) {
|
|
876
|
+
let first = 0;
|
|
877
|
+
let second = 0;
|
|
878
|
+
// Outside the zone: under zone.js each frame callback is a full application tick.
|
|
879
|
+
zone.runOutsideAngular(() => {
|
|
880
|
+
first = requestAnimationFrame(() => {
|
|
881
|
+
second = requestAnimationFrame(run);
|
|
882
|
+
});
|
|
883
|
+
});
|
|
884
|
+
return () => {
|
|
885
|
+
cancelAnimationFrame(first);
|
|
886
|
+
cancelAnimationFrame(second);
|
|
887
|
+
};
|
|
888
|
+
}
|
|
889
|
+
|
|
890
|
+
/** Marks a chart's skeleton draws when nothing is known about the data. @internal */
|
|
891
|
+
const CHART_SKELETON_COUNT = 5;
|
|
892
|
+
const COLUMN_HEIGHTS = [0.45, 0.62, 0.52, 0.75, 0.9, 0.68, 0.58];
|
|
893
|
+
const LINE_HEIGHTS = [0.42, 0.52, 0.47, 0.62, 0.58, 0.72, 0.68];
|
|
894
|
+
// Sums to zero, so a long run keeps returning to the opening total instead of sinking to the axis.
|
|
895
|
+
const STEP_DELTAS = [-0.16, -0.14, 0.08, -0.1, 0.2, 0.12];
|
|
896
|
+
const percent = (fraction) => `${Math.round(fraction * 10000) / 100}%`;
|
|
897
|
+
/** How many marks the skeleton draws: the data's own count once it is known, else the input. @internal */
|
|
898
|
+
function skeletonMarkCount(dataLength, skeletonCount) {
|
|
899
|
+
if (dataLength > 0) {
|
|
900
|
+
return dataLength;
|
|
901
|
+
}
|
|
902
|
+
return Number.isFinite(skeletonCount) && skeletonCount >= 1
|
|
903
|
+
? Math.floor(skeletonCount)
|
|
904
|
+
: CHART_SKELETON_COUNT;
|
|
905
|
+
}
|
|
906
|
+
/** Column heights as fractions of the plot, a fixed rise and fall that reads as a column chart. @internal */
|
|
907
|
+
function skeletonColumnHeights(count) {
|
|
908
|
+
return Array.from({ length: count }, (unused, index) => COLUMN_HEIGHTS[index % COLUMN_HEIGHTS.length]);
|
|
909
|
+
}
|
|
910
|
+
/** A 4px band through one point per category centre, as a `clip-path` over the whole plot. @internal */
|
|
911
|
+
function skeletonLineClip(count) {
|
|
912
|
+
const length = Math.max(count, 2);
|
|
913
|
+
const points = Array.from({ length }, (unused, index) => ({
|
|
914
|
+
x: percent((index + 0.5) / length),
|
|
915
|
+
y: percent(1 - LINE_HEIGHTS[index % LINE_HEIGHTS.length]),
|
|
916
|
+
}));
|
|
917
|
+
const top = points.map(({ x, y }) => `${x} calc(${y} - 2px)`);
|
|
918
|
+
const bottom = points.reverse().map(({ x, y }) => `${x} calc(${y} + 2px)`);
|
|
919
|
+
return `polygon(${[...top, ...bottom].join(', ')})`;
|
|
920
|
+
}
|
|
921
|
+
/** Waterfall steps as fractions of the plot: a total, floating deltas off the running total, and
|
|
922
|
+
* the closing total standing on the axis. @internal */
|
|
923
|
+
function skeletonWaterfallSteps(count) {
|
|
924
|
+
if (count <= 1) {
|
|
925
|
+
return count === 1 ? [{ bottom: 0, height: 0.85 }] : [];
|
|
926
|
+
}
|
|
927
|
+
let running = 0.9;
|
|
928
|
+
const steps = [{ bottom: 0, height: running }];
|
|
929
|
+
for (let index = 1; index < count - 1; index++) {
|
|
930
|
+
const next = Math.min(0.9, Math.max(0.2, running + STEP_DELTAS[(index - 1) % STEP_DELTAS.length]));
|
|
931
|
+
steps.push({
|
|
932
|
+
bottom: Math.min(running, next),
|
|
933
|
+
height: Math.abs(running - next),
|
|
934
|
+
});
|
|
935
|
+
running = next;
|
|
936
|
+
}
|
|
937
|
+
steps.push({ bottom: 0, height: running });
|
|
938
|
+
return steps.map(({ bottom, height }) => ({
|
|
939
|
+
bottom: Math.round(bottom * 100) / 100,
|
|
940
|
+
height: Math.round(height * 100) / 100,
|
|
941
|
+
}));
|
|
942
|
+
}
|
|
943
|
+
/** One `clip-path` per funnel stage: equal steps narrowing to 40% of the width at the bottom. @internal */
|
|
944
|
+
function skeletonFunnelClips(count) {
|
|
945
|
+
const step = 0.3 / Math.max(count, 1);
|
|
946
|
+
return Array.from({ length: count }, (unused, index) => {
|
|
947
|
+
const top = percent(index * step);
|
|
948
|
+
const bottom = percent((index + 1) * step);
|
|
949
|
+
const topEnd = percent(1 - index * step);
|
|
950
|
+
const bottomEnd = percent(1 - (index + 1) * step);
|
|
951
|
+
return `polygon(${top} 0, ${topEnd} 0, ${bottomEnd} 100%, ${bottom} 100%)`;
|
|
952
|
+
});
|
|
953
|
+
}
|
|
849
954
|
|
|
850
955
|
// A chart stays warm from its first answer until the pointer leaves it; one set for the page, as a legend and its plot are one chart.
|
|
851
956
|
const warmCharts = new WeakSet();
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
957
|
+
/** The chart `element` sits in.
|
|
958
|
+
*
|
|
959
|
+
* @internal */
|
|
960
|
+
function chartOf(element) {
|
|
961
|
+
return element ? element.closest('figure') : null;
|
|
855
962
|
}
|
|
856
963
|
function warmUp(chart) {
|
|
857
964
|
if (warmCharts.has(chart)) {
|
|
@@ -866,7 +973,8 @@ function warmUp(chart) {
|
|
|
866
973
|
};
|
|
867
974
|
document.addEventListener('pointerover', coolOnLeave, true);
|
|
868
975
|
}
|
|
869
|
-
/** Call from
|
|
976
|
+
/** Call from an injection context; the caller's own `leave` cancels the wait, and so does destroying
|
|
977
|
+
* the context. `delayMs` is read at each `schedule`.
|
|
870
978
|
*
|
|
871
979
|
* @internal */
|
|
872
980
|
function chartDwell(delayMs) {
|
|
@@ -877,12 +985,14 @@ function chartDwell(delayMs) {
|
|
|
877
985
|
waiting = null;
|
|
878
986
|
}
|
|
879
987
|
};
|
|
988
|
+
inject(DestroyRef).onDestroy(cancel);
|
|
880
989
|
return {
|
|
881
990
|
schedule(target, answer, event) {
|
|
882
991
|
const pointer = typeof PointerEvent !== 'undefined' &&
|
|
883
992
|
event instanceof PointerEvent &&
|
|
884
993
|
event.pointerType !== 'touch';
|
|
885
|
-
const
|
|
994
|
+
const node = event.currentTarget ?? event.target;
|
|
995
|
+
const chart = chartOf(node instanceof Element ? node : null);
|
|
886
996
|
const delay = Math.max(delayMs(), 0);
|
|
887
997
|
if (!pointer || delay === 0 || (chart && warmCharts.has(chart))) {
|
|
888
998
|
cancel();
|
|
@@ -910,6 +1020,22 @@ function chartDwell(delayMs) {
|
|
|
910
1020
|
cancel,
|
|
911
1021
|
};
|
|
912
1022
|
}
|
|
1023
|
+
/** Sets `highlighted` to the item the pointer rests on, after the dwell, and back to `null` when it
|
|
1024
|
+
* leaves. Call from an injection context.
|
|
1025
|
+
*
|
|
1026
|
+
* @internal */
|
|
1027
|
+
function dwellHighlight(highlighted, delayMs) {
|
|
1028
|
+
const dwell = chartDwell(delayMs);
|
|
1029
|
+
return {
|
|
1030
|
+
enter(item, event) {
|
|
1031
|
+
dwell.schedule(item, () => highlighted.set(item), event);
|
|
1032
|
+
},
|
|
1033
|
+
leave() {
|
|
1034
|
+
dwell.cancel();
|
|
1035
|
+
highlighted.set(null);
|
|
1036
|
+
},
|
|
1037
|
+
};
|
|
1038
|
+
}
|
|
913
1039
|
|
|
914
1040
|
/** Where a roving tabindex lands after `key`, or `null` when the key does not traverse.
|
|
915
1041
|
* The ends wrap, as in `ds-radio-group`; Home and End jump to either extreme.
|
|
@@ -966,6 +1092,15 @@ function rovingMarks(count) {
|
|
|
966
1092
|
},
|
|
967
1093
|
};
|
|
968
1094
|
}
|
|
1095
|
+
/** Whether a `pointerout` from `hit` left the mark, rather than crossing into another part of it.
|
|
1096
|
+
*
|
|
1097
|
+
* @internal */
|
|
1098
|
+
function leftMark(event, hit) {
|
|
1099
|
+
const next = event.relatedTarget instanceof Element
|
|
1100
|
+
? event.relatedTarget.closest('[data-mark-index]')
|
|
1101
|
+
: null;
|
|
1102
|
+
return next !== hit.element;
|
|
1103
|
+
}
|
|
969
1104
|
/** The mark an event on the marks' parent came from (the nearest `[data-mark-index]`), or `null`.
|
|
970
1105
|
*
|
|
971
1106
|
* @internal */
|
|
@@ -1250,6 +1385,15 @@ function resolveReserveMessage(reserveMessage, appWideDefaultApplies = () => tru
|
|
|
1250
1385
|
? (config.field?.reserveMessage ?? false)
|
|
1251
1386
|
: false));
|
|
1252
1387
|
}
|
|
1388
|
+
/**
|
|
1389
|
+
* Resolves a field's `showDirty`: the input, then `DS_CONFIG.field.showDirty`, then `false`.
|
|
1390
|
+
*
|
|
1391
|
+
* Call from a field initializer (an injection context).
|
|
1392
|
+
*/
|
|
1393
|
+
function resolveShowDirty(showDirty) {
|
|
1394
|
+
const config = inject(DS_CONFIG);
|
|
1395
|
+
return computed(() => showDirty() ?? config.field?.showDirty ?? false);
|
|
1396
|
+
}
|
|
1253
1397
|
|
|
1254
1398
|
const NO_ERRORS = [];
|
|
1255
1399
|
/**
|
|
@@ -1275,7 +1419,12 @@ function trimmedText(value) {
|
|
|
1275
1419
|
return value?.trim() ?? '';
|
|
1276
1420
|
}
|
|
1277
1421
|
const EMPTY_MESSAGE = { text: '', state: 'default' };
|
|
1278
|
-
const NO_CONTROL = {
|
|
1422
|
+
const NO_CONTROL = {
|
|
1423
|
+
errors: NO_ERRORS,
|
|
1424
|
+
touched: false,
|
|
1425
|
+
pending: false,
|
|
1426
|
+
dirty: false,
|
|
1427
|
+
};
|
|
1279
1428
|
/**
|
|
1280
1429
|
* Resolves the one message a field shows, from every source that can supply one.
|
|
1281
1430
|
*
|
|
@@ -1365,7 +1514,10 @@ function resolveFieldMessage(sources) {
|
|
|
1365
1514
|
}
|
|
1366
1515
|
return sources.success?.() ? 'success' : null;
|
|
1367
1516
|
}, ...(ngDevMode ? [{ debugName: "paintedState" }] : /* istanbul ignore next */ []));
|
|
1368
|
-
|
|
1517
|
+
const pending = computed(() => (sources.pending?.() ?? false) || controlState().pending, ...(ngDevMode ? [{ debugName: "pending" }] : /* istanbul ignore next */ []));
|
|
1518
|
+
const changed = computed(() => (sources.showDirty?.() ?? false) &&
|
|
1519
|
+
((sources.dirty?.() ?? false) || controlState().dirty), ...(ngDevMode ? [{ debugName: "changed" }] : /* istanbul ignore next */ []));
|
|
1520
|
+
return { message, invalid, controlState: paintedState, pending, changed };
|
|
1369
1521
|
}
|
|
1370
1522
|
/**
|
|
1371
1523
|
* `NgControl` cannot be injected in the constructor (`NG_VALUE_ACCESSOR` points at the field
|
|
@@ -1390,6 +1542,8 @@ function watchNgControl() {
|
|
|
1390
1542
|
const sync = () => state.set({
|
|
1391
1543
|
errors: fromValidationErrors(control.errors),
|
|
1392
1544
|
touched: control.touched || submitted(),
|
|
1545
|
+
pending: control.pending,
|
|
1546
|
+
dirty: control.dirty,
|
|
1393
1547
|
});
|
|
1394
1548
|
// Signal forms bridges an NgControl whose `control` has no `events` stream. Staying at
|
|
1395
1549
|
// NO_CONTROL is deliberate: the component's own inputs carry errors and touched there.
|
|
@@ -1484,6 +1638,26 @@ class DsFieldBase extends DsMessageBase {
|
|
|
1484
1638
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: DsFieldBase, decorators: [{
|
|
1485
1639
|
type: Directive
|
|
1486
1640
|
}], propDecorators: { errors: [{ type: i0.Input, args: [{ isSignal: true, alias: "errors", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], touched: [{ type: i0.Input, args: [{ isSignal: true, alias: "touched", required: false }] }] } });
|
|
1641
|
+
/**
|
|
1642
|
+
* The form-state inputs of a DS value control: what signal forms binds by name beyond `errors`
|
|
1643
|
+
* and `touched`. Reactive and template-driven forms are read through `NgControl` instead.
|
|
1644
|
+
* @internal
|
|
1645
|
+
*/
|
|
1646
|
+
class DsFormControlBase extends DsFieldBase {
|
|
1647
|
+
/** Whether an async validator is running. Bound by signal forms; shows a trailing spinner. */
|
|
1648
|
+
pending = input(false, { ...(ngDevMode ? { debugName: "pending" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1649
|
+
/** Whether the user has changed the value. Bound by signal forms; drawn only under `showDirty`. */
|
|
1650
|
+
dirty = input(false, { ...(ngDevMode ? { debugName: "dirty" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1651
|
+
/** Marks a changed value with a dot and a "Changed" line. Unset falls back to
|
|
1652
|
+
* `DS_CONFIG.field.showDirty`, then `false`. */
|
|
1653
|
+
showDirty = input(null, { ...(ngDevMode ? { debugName: "showDirty" } : /* istanbul ignore next */ {}), transform: (value) => (value == null ? null : booleanAttribute(value)) });
|
|
1654
|
+
showDirtyResolved = resolveShowDirty(this.showDirty);
|
|
1655
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: DsFormControlBase, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1656
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.22", type: DsFormControlBase, isStandalone: true, inputs: { pending: { classPropertyName: "pending", publicName: "pending", isSignal: true, isRequired: false, transformFunction: null }, dirty: { classPropertyName: "dirty", publicName: "dirty", isSignal: true, isRequired: false, transformFunction: null }, showDirty: { classPropertyName: "showDirty", publicName: "showDirty", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0 });
|
|
1657
|
+
}
|
|
1658
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: DsFormControlBase, decorators: [{
|
|
1659
|
+
type: Directive
|
|
1660
|
+
}], propDecorators: { pending: [{ type: i0.Input, args: [{ isSignal: true, alias: "pending", required: false }] }], dirty: [{ type: i0.Input, args: [{ isSignal: true, alias: "dirty", required: false }] }], showDirty: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDirty", required: false }] }] } });
|
|
1487
1661
|
|
|
1488
1662
|
/**
|
|
1489
1663
|
* Value elements are searched FIRST: the number stepper renders its decrement button before its
|
|
@@ -1562,7 +1736,7 @@ function blurOwnControl(host) {
|
|
|
1562
1736
|
* `FormControl.disable()` reaches the control, and call `markTouched()` from a blur handler.
|
|
1563
1737
|
* @internal
|
|
1564
1738
|
*/
|
|
1565
|
-
class DsControlValueAccessor extends
|
|
1739
|
+
class DsControlValueAccessor extends DsFormControlBase {
|
|
1566
1740
|
/** Hides the control. Inline `display`: the `hidden` attribute loses to each control's `:host` display. */
|
|
1567
1741
|
hidden = input(false, { ...(ngDevMode ? { debugName: "hidden" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1568
1742
|
hostElement = inject(ElementRef);
|
|
@@ -1609,7 +1783,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImpo
|
|
|
1609
1783
|
* state and call `markTouched()` from a blur handler.
|
|
1610
1784
|
* @internal
|
|
1611
1785
|
*/
|
|
1612
|
-
class DsBooleanControlValueAccessor extends
|
|
1786
|
+
class DsBooleanControlValueAccessor extends DsFormControlBase {
|
|
1613
1787
|
/** Hides the control; see `DsControlValueAccessor.hidden`. */
|
|
1614
1788
|
hidden = input(false, { ...(ngDevMode ? { debugName: "hidden" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1615
1789
|
hostElement = inject(ElementRef);
|
|
@@ -1789,8 +1963,12 @@ const NO_HOVER_DELAY_INPUT = signal(null, ...(ngDevMode ? [{ debugName: "NO_HOVE
|
|
|
1789
1963
|
function optional(input) {
|
|
1790
1964
|
return computed(() => input()?.() ?? null);
|
|
1791
1965
|
}
|
|
1792
|
-
/** Default hover delay, in milliseconds. @internal */
|
|
1793
1966
|
const CHART_HOVER_DELAY_MS = 0;
|
|
1967
|
+
/** How long a pointer rests on a mark before the chart answers, in milliseconds:
|
|
1968
|
+
* `DS_CONFIG.chart.hoverDelayMs`, else `0`. Call from an injection context. @internal */
|
|
1969
|
+
function chartHoverDelayMs() {
|
|
1970
|
+
return resolveWithConfig(NO_HOVER_DELAY_INPUT, (config) => config.chart?.hoverDelayMs, CHART_HOVER_DELAY_MS);
|
|
1971
|
+
}
|
|
1794
1972
|
/** Default tooltip linger, in milliseconds; long enough to cross to the next mark. @internal */
|
|
1795
1973
|
const CHART_TOOLTIP_LINGER_MS = 500;
|
|
1796
1974
|
/** Resolves each input, then `DS_CONFIG.chart`, then the built-in; copy resolves input, then `DS_INTL.chart`.
|
|
@@ -1807,7 +1985,7 @@ function resolveChartDefaults(inputs) {
|
|
|
1807
1985
|
valueFormat: resolveWithConfig(inputs.valueFormat, (config) => config.chart?.valueFormat, chartValueFormat(locale)),
|
|
1808
1986
|
tooltipLingerMs: resolveWithConfig(optional(() => inputs.tooltipLingerMs), (config) => config.chart?.tooltipLingerMs, CHART_TOOLTIP_LINGER_MS),
|
|
1809
1987
|
pinOnClick: resolveWithConfig(optional(() => inputs.pinOnClick), (config) => config.chart?.pinOnClick, true),
|
|
1810
|
-
hoverDelayMs:
|
|
1988
|
+
hoverDelayMs: chartHoverDelayMs(),
|
|
1811
1989
|
tooltipSwatches: resolveWithConfig(optional(() => inputs.tooltipSwatches), (config) => config.chart?.tooltipSwatches, 'auto'),
|
|
1812
1990
|
};
|
|
1813
1991
|
}
|
|
@@ -1821,7 +1999,8 @@ class DsChartBase {
|
|
|
1821
1999
|
caption = input(null, ...(ngDevMode ? [{ debugName: "caption" }] : /* istanbul ignore next */ []));
|
|
1822
2000
|
/** Accessible name. Generated from the data when omitted. */
|
|
1823
2001
|
summary = input(null, ...(ngDevMode ? [{ debugName: "summary" }] : /* istanbul ignore next */ []));
|
|
1824
|
-
/**
|
|
2002
|
+
/** With no data, draws a skeleton in the chart's shape: `skeletonCount` marks where the chart has
|
|
2003
|
+
* it, the data's count once known. With data on screen, keeps the plot under `ds-loading-overlay`. */
|
|
1825
2004
|
loading = input(false, { ...(ngDevMode ? { debugName: "loading" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1826
2005
|
/** Shows `errorText` in place of the plot. Separate from `loading` and from empty data. */
|
|
1827
2006
|
error = input(false, { ...(ngDevMode ? { debugName: "error" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
@@ -1838,8 +2017,9 @@ class DsChartBase {
|
|
|
1838
2017
|
/** Whether the tooltip draws a colour dot beside each reading. Unset falls back to
|
|
1839
2018
|
* `DS_CONFIG.chart.tooltipSwatches`, then shows them for two to four readings. */
|
|
1840
2019
|
tooltipSwatches = input(null, { ...(ngDevMode ? { debugName: "tooltipSwatches" } : /* istanbul ignore next */ {}), transform: (value) => value == null ? null : booleanAttribute(value) });
|
|
1841
|
-
/** How long the tooltip stays after the pointer leaves the mark
|
|
1842
|
-
* it at once.
|
|
2020
|
+
/** How long the tooltip stays after the pointer leaves the mark for another part of the chart,
|
|
2021
|
+
* in milliseconds; zero closes it at once. A pointer that leaves the chart closes it at once
|
|
2022
|
+
* whatever this says. Unset falls back to `DS_CONFIG.chart.tooltipLingerMs`, then 500. */
|
|
1843
2023
|
tooltipLingerMs = input(null, { ...(ngDevMode ? { debugName: "tooltipLingerMs" } : /* istanbul ignore next */ {}), transform: (raw) => (raw == null ? null : numberAttribute(raw)) });
|
|
1844
2024
|
/** Holds the clicked mark and its tooltip until a second click, Escape or a press outside.
|
|
1845
2025
|
* Unset falls back to `DS_CONFIG.chart.pinOnClick`, then `true`. The click output fires either way. */
|
|
@@ -1856,6 +2036,13 @@ class DsChartBase {
|
|
|
1856
2036
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: DsChartBase, decorators: [{
|
|
1857
2037
|
type: Directive
|
|
1858
2038
|
}], propDecorators: { frame: [{ type: i0.Input, args: [{ isSignal: true, alias: "frame", required: false }] }], caption: [{ type: i0.Input, args: [{ isSignal: true, alias: "caption", required: false }] }], summary: [{ type: i0.Input, args: [{ isSignal: true, alias: "summary", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], error: [{ type: i0.Input, args: [{ isSignal: true, alias: "error", required: false }] }], emptyText: [{ type: i0.Input, args: [{ isSignal: true, alias: "emptyText", required: false }] }], errorText: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorText", required: false }] }], valueFormat: [{ type: i0.Input, args: [{ isSignal: true, alias: "valueFormat", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], tooltipSwatches: [{ type: i0.Input, args: [{ isSignal: true, alias: "tooltipSwatches", required: false }] }], tooltipLingerMs: [{ type: i0.Input, args: [{ isSignal: true, alias: "tooltipLingerMs", required: false }] }], pinOnClick: [{ type: i0.Input, args: [{ isSignal: true, alias: "pinOnClick", required: false }] }] } });
|
|
2039
|
+
/** Whether the marks keyed `key` fade while `highlighted` is singled out: only under `dimOthers`,
|
|
2040
|
+
* and never the highlighted marks themselves.
|
|
2041
|
+
*
|
|
2042
|
+
* @internal */
|
|
2043
|
+
function dimmedBy(dimOthers, highlighted, key) {
|
|
2044
|
+
return dimOthers && highlighted !== null && highlighted !== key;
|
|
2045
|
+
}
|
|
1859
2046
|
|
|
1860
2047
|
/**
|
|
1861
2048
|
* Focuses the field's inner `input`/`textarea` when the click lands on the frame chrome
|
|
@@ -1891,6 +2078,56 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImpo
|
|
|
1891
2078
|
}]
|
|
1892
2079
|
}] });
|
|
1893
2080
|
|
|
2081
|
+
const TABBABLE_CANDIDATES = 'a[href], button, input, select, textarea, [tabindex], [contenteditable="true"]';
|
|
2082
|
+
function isTabbable(element) {
|
|
2083
|
+
return (element.isConnected &&
|
|
2084
|
+
element.tabIndex >= 0 &&
|
|
2085
|
+
!element.disabled &&
|
|
2086
|
+
!element.closest('[inert]') &&
|
|
2087
|
+
element.checkVisibility());
|
|
2088
|
+
}
|
|
2089
|
+
function tabbableNeighbour(leaving, within) {
|
|
2090
|
+
const candidates = Array.from(within.querySelectorAll(TABBABLE_CANDIDATES)).filter((element) => !leaving.contains(element) && isTabbable(element));
|
|
2091
|
+
const following = candidates.find((element) => leaving.compareDocumentPosition(element) &
|
|
2092
|
+
Node.DOCUMENT_POSITION_FOLLOWING);
|
|
2093
|
+
return following ?? candidates.at(-1) ?? null;
|
|
2094
|
+
}
|
|
2095
|
+
/**
|
|
2096
|
+
* When focus is inside `leaving`, which is about to be removed, moves it to the nearest tabbable
|
|
2097
|
+
* element inside `within`: the next one in document order, else the previous one, else `fallback`.
|
|
2098
|
+
* @internal
|
|
2099
|
+
*/
|
|
2100
|
+
function moveFocusOutOf(leaving, within, fallback = null) {
|
|
2101
|
+
if (!leaving.contains(leaving.ownerDocument.activeElement)) {
|
|
2102
|
+
return;
|
|
2103
|
+
}
|
|
2104
|
+
const target = tabbableNeighbour(leaving, within) ??
|
|
2105
|
+
(fallback && isTabbable(fallback) ? fallback : null);
|
|
2106
|
+
target?.focus();
|
|
2107
|
+
}
|
|
2108
|
+
/**
|
|
2109
|
+
* Returns a function that, after the next render, focuses `target()` when focus has fallen to
|
|
2110
|
+
* `<body>` - its element was removed or disabled under it. Focus the app moved elsewhere is left alone.
|
|
2111
|
+
*
|
|
2112
|
+
* Must be called from an injection context.
|
|
2113
|
+
* @internal
|
|
2114
|
+
*/
|
|
2115
|
+
function focusRescue() {
|
|
2116
|
+
const injector = inject(Injector);
|
|
2117
|
+
const documentRef = inject(DOCUMENT);
|
|
2118
|
+
return (target) => afterNextRender(() => {
|
|
2119
|
+
const active = documentRef.activeElement;
|
|
2120
|
+
// A focused control that turns disabled still reads as active until the browser's focus fixup.
|
|
2121
|
+
const lost = !active ||
|
|
2122
|
+
active === documentRef.body ||
|
|
2123
|
+
!active.isConnected ||
|
|
2124
|
+
active.disabled === true;
|
|
2125
|
+
if (lost) {
|
|
2126
|
+
target()?.focus();
|
|
2127
|
+
}
|
|
2128
|
+
}, { injector });
|
|
2129
|
+
}
|
|
2130
|
+
|
|
1894
2131
|
let nextId = 0;
|
|
1895
2132
|
/** Process-wide counter for SSR-safe control ids (no DOM dependency).
|
|
1896
2133
|
* @internal
|
|
@@ -2162,6 +2399,23 @@ function closeOnScroll(overlayRef, close) {
|
|
|
2162
2399
|
doc.addEventListener('scroll', onScroll, true);
|
|
2163
2400
|
return () => doc.removeEventListener('scroll', onScroll, true);
|
|
2164
2401
|
}
|
|
2402
|
+
/** Calls `onEscape` when `Escape` is pressed anywhere on `target`, in the CAPTURE phase so a handler
|
|
2403
|
+
* further down cannot swallow it. Returns the removal. A null target (no document, as on the
|
|
2404
|
+
* server) listens to nothing.
|
|
2405
|
+
* @internal
|
|
2406
|
+
*/
|
|
2407
|
+
function listenForEscape(target, onEscape) {
|
|
2408
|
+
if (!target) {
|
|
2409
|
+
return () => undefined;
|
|
2410
|
+
}
|
|
2411
|
+
const onKeydown = (event) => {
|
|
2412
|
+
if (event.key === 'Escape') {
|
|
2413
|
+
onEscape();
|
|
2414
|
+
}
|
|
2415
|
+
};
|
|
2416
|
+
target.addEventListener('keydown', onKeydown, true);
|
|
2417
|
+
return () => target.removeEventListener('keydown', onKeydown, true);
|
|
2418
|
+
}
|
|
2165
2419
|
/**
|
|
2166
2420
|
* Syncs a component's "which overlay is mine, and is it open" state when THIS overlay detaches,
|
|
2167
2421
|
* skipping the write when a newer one has taken over.
|
|
@@ -2246,6 +2500,7 @@ function announceOptionCount(count, active) {
|
|
|
2246
2500
|
region.setAttribute('aria-live', 'polite');
|
|
2247
2501
|
region.setAttribute('aria-atomic', 'true');
|
|
2248
2502
|
// Off-screen, not `display: none`, which would remove it from the accessibility tree.
|
|
2503
|
+
// glyph-clip-guard: visually hidden live region
|
|
2249
2504
|
region.style.cssText =
|
|
2250
2505
|
'position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;margin:-1px;padding:0';
|
|
2251
2506
|
documentRef.body.appendChild(region);
|
|
@@ -2406,5 +2661,5 @@ function createTypeAhead() {
|
|
|
2406
2661
|
* Generated bundle index. Do not edit.
|
|
2407
2662
|
*/
|
|
2408
2663
|
|
|
2409
|
-
export {
|
|
2664
|
+
export { CHART_GLIDE_HEAD_START_MS, CHART_HEAT_COLORS, CHART_RAMP_COLORS, CHART_RENDER_GATE_PASSED, CHART_SERIES_COLORS, CHART_SKELETON_COUNT, CHART_TOOLTIP_LINGER_MS, DS_FIELD_WARNING_KIND, DsBooleanControlValueAccessor, DsChartBase, DsChipTemplateDirective, DsControlValueAccessor, DsCreateTemplateDirective, DsEmptyTemplateDirective, DsFieldBase, DsFormControlBase, DsGroupLabelTemplateDirective, DsMessageBase, DsOptionTemplateDirective, DsPanelFooterTemplateDirective, DsPanelHeaderTemplateDirective, DsPickerTriggerDirective, DsStaticPreview, FieldClickFocusDirective, ProjectionDroppedDirective, afterTwoFrames, announceOptionCount, areaPath, bandPath, bandScale, chartColors, chartDelay, chartDwell, chartHoverDelayMs, chartOf, chartRenderGate, chartTiming, chartValueFormat, chipFit, clearOnDetach, closeOnOutsidePointer, closeOnScroll, createTypeAhead, decimationTarget, describeSeries, describeShare, dimmedBy, disposeWithLeave, domainMinOf, dropdownOverlay, dsAriaCurrent, dsDestination, dwellHighlight, elementWidth, focusIsInside, focusMark, focusRescue, formatPercent, formatTick, formatValue, formatWholePercent, forwardOverlayTokens, labelInterval, largestRemainder, leaveMark, leftMark, linePath, lineSegments, linearScale, listenForEscape, listenForMarkFocus, lttbDecimate, markAt, markOf, minMaxDecimate, moveFocusOutOf, needsDecimating, nextControlId, nextRovingIndex, niceDomain, overlayPlacementOf, panelClassesOf, prepareOverlayEnter, readOnHostResize, resolveBrandValue, resolveChartDefaults, resolveFieldMessage, rotationWouldFit, roundStepAtLeast, rovingMarks, scrollActiveOptionIntoView, shareOfTotal, skeletonColumnHeights, skeletonFunnelClips, skeletonLineClip, skeletonMarkCount, skeletonWaterfallSteps, staggerDelay, tickValues, trimmedText, tweenMarks, valueControlBridge, watchElementWidth };
|
|
2410
2665
|
//# sourceMappingURL=ids-group-ltd-ids-design-system-components.mjs.map
|