@ids-group-ltd/ids-design-system 0.13.4 → 0.14.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 +584 -0
- package/components.md +100 -52
- package/design-system.md +2 -0
- package/docs/agent/INDEX.md +3 -2
- package/docs/agent/charts/column-series-component.md +1 -1
- package/docs/agent/charts/ds-bar-chart.md +2 -1
- package/docs/agent/charts/ds-chart.md +3 -1
- package/docs/agent/charts/ds-config.md +3 -1
- package/docs/agent/charts/ds-line-chart.md +3 -3
- package/docs/agent/charts/ds-pie-chart.md +4 -3
- package/docs/agent/charts/line-series-component.md +1 -1
- package/docs/agent/feedback/ds-alert.md +1 -0
- package/docs/agent/feedback/ds-badge.md +1 -1
- package/docs/agent/feedback/ds-banner.md +1 -0
- package/docs/agent/feedback/ds-skeleton.md +2 -2
- package/docs/agent/feedback/ds-tag.md +1 -1
- package/docs/agent/forms/ds-autocomplete.md +2 -2
- package/docs/agent/forms/ds-button.md +1 -1
- package/docs/agent/forms/ds-color-picker.md +1 -1
- package/docs/agent/forms/ds-date-picker.md +2 -2
- package/docs/agent/forms/ds-filter-bar.md +1 -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 +2 -2
- package/docs/agent/forms/ds-otp-input.md +1 -1
- package/docs/agent/forms/ds-search.md +3 -3
- package/docs/agent/forms/ds-split-button.md +1 -1
- package/docs/agent/forms/ds-switch.md +4 -2
- package/docs/agent/forms/ds-textarea.md +2 -1
- package/docs/agent/foundations/tokens.md +1 -1
- package/docs/agent/navigation/ds-app-layout.md +2 -2
- package/docs/agent/navigation/ds-auth-layout.md +4 -4
- package/docs/agent/navigation/ds-page-header.md +1 -1
- package/docs/agent/navigation/ds-pagination.md +2 -2
- package/docs/agent/platform/ds-config.md +3 -3
- package/docs/agent/platform/ds-intl.md +33 -0
- package/docs/agent/surfaces/ds-accordion.md +2 -2
- package/docs/agent/tables/ds-cell-template.md +1 -1
- package/docs/agent/tables/ds-table.md +5 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-accordion.mjs +9 -5
- 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 +21 -10
- 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 +9 -5
- 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 +8 -8
- 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 +13 -8
- 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 +5 -3
- 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 +5 -10
- 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 +12 -8
- 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 +21 -10
- 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 +56 -32
- 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 +7 -6
- 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 +4 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs +4 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart-data-table.mjs +15 -3
- 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 +5 -3
- 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 +45 -39
- 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 +414 -105
- package/fesm2022/ids-group-ltd-ids-design-system-components-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs +9 -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 +22 -18
- 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 +16 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-description-list.mjs +4 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-description-list.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs +7 -4
- 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 +12 -6
- 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-filter-bar.mjs +13 -7
- 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 +40 -42
- 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 +13 -9
- 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 +3 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-icon-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-input.mjs +5 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-input.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-line-chart.mjs +27 -23
- package/fesm2022/ids-group-ltd-ids-design-system-components-line-chart.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-modal.mjs +62 -13
- 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 +15 -10
- 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 +5 -4
- 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 +13 -7
- 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-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 +22 -13
- 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 +12 -11
- 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 +55 -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-scatter-chart.mjs +41 -12
- 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 +13 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-search.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs +4 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav-footer.mjs +4 -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 +5 -3
- 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 +37 -4
- 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 +8 -7
- package/fesm2022/ids-group-ltd-ids-design-system-components-slider.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-spinner.mjs +5 -3
- 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 +9 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-split-button.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-stepper.mjs +6 -4
- 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 +20 -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 +18 -15
- 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 +9 -6
- 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.mjs +47 -38
- 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 +5 -3
- 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 +9 -5
- 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 +26 -4
- 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 +12 -10
- package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-toast.mjs +8 -6
- package/fesm2022/ids-group-ltd-ids-design-system-components-toast.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-w3w.mjs +5 -3
- 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 +14 -15
- 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 +345 -66
- package/fesm2022/ids-group-ltd-ids-design-system-components.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-core.mjs +361 -6
- package/fesm2022/ids-group-ltd-ids-design-system-core.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system.mjs +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system.mjs.map +1 -1
- package/migrations/0.10.0.json +1 -1
- package/migrations/0.10.1.json +1 -1
- package/migrations/0.12.2.json +4 -1
- package/migrations/0.13.3.json +32 -10
- package/migrations/0.13.4.json +1630 -132
- package/migrations/0.14.0.json +615 -0
- package/migrations/0.14.1.json +856 -0
- package/migrations/0.5.0.json +10 -4
- package/migrations/0.7.0.json +5 -2
- package/migrations/0.9.0.json +5 -2
- package/migrations/README.md +7 -2
- package/package.json +1 -1
- package/schematics/check-overrides/index.cjs +56 -0
- package/schematics/check-overrides/scan.cjs +74 -0
- package/schematics/check-overrides/schema.json +19 -0
- package/schematics/check-overrides/surface.json +2304 -0
- package/schematics/collection.json +5 -0
- package/styles/_chart-frame.scss +4 -4
- package/styles/_chart-interactive.scss +33 -0
- package/styles/_chart-motion.scss +17 -10
- package/styles/_field-box.scss +12 -0
- package/styles/_overlay-motion.scss +20 -10
- package/styles/_skeleton-shimmer.scss +4 -1
- package/styles/_tokens-charts.scss +1 -1
- package/styles/_tokens.scss +1 -1
- package/types/ids-group-ltd-ids-design-system-components-accordion.d.ts +11 -2
- package/types/ids-group-ltd-ids-design-system-components-alert.d.ts +4 -0
- package/types/ids-group-ltd-ids-design-system-components-app-layout.d.ts +5 -2
- package/types/ids-group-ltd-ids-design-system-components-auth-layout.d.ts +5 -5
- package/types/ids-group-ltd-ids-design-system-components-autocomplete.d.ts +7 -4
- package/types/ids-group-ltd-ids-design-system-components-avatar-group.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-avatar.d.ts +5 -3
- package/types/ids-group-ltd-ids-design-system-components-badge.d.ts +6 -2
- package/types/ids-group-ltd-ids-design-system-components-banner.d.ts +4 -0
- package/types/ids-group-ltd-ids-design-system-components-bar-chart.d.ts +20 -14
- package/types/ids-group-ltd-ids-design-system-components-breadcrumbs.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-button.d.ts +2 -2
- package/types/ids-group-ltd-ids-design-system-components-chart-data-table.d.ts +5 -0
- package/types/ids-group-ltd-ids-design-system-components-chart-legend.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-chart-tooltip.d.ts +11 -6
- package/types/ids-group-ltd-ids-design-system-components-chart.d.ts +155 -36
- package/types/ids-group-ltd-ids-design-system-components-color-picker.d.ts +6 -2
- package/types/ids-group-ltd-ids-design-system-components-column-chart.d.ts +11 -8
- package/types/ids-group-ltd-ids-design-system-components-date-picker.d.ts +9 -3
- package/types/ids-group-ltd-ids-design-system-components-description-list.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-drawer.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-dropzone.d.ts +3 -0
- package/types/ids-group-ltd-ids-design-system-components-filter-bar.d.ts +9 -4
- package/types/ids-group-ltd-ids-design-system-components-funnel-chart.d.ts +13 -13
- package/types/ids-group-ltd-ids-design-system-components-heatmap-chart.d.ts +7 -5
- 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 +17 -11
- package/types/ids-group-ltd-ids-design-system-components-modal.d.ts +6 -0
- package/types/ids-group-ltd-ids-design-system-components-multi-select.d.ts +11 -6
- package/types/ids-group-ltd-ids-design-system-components-number-stepper.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-otp-input.d.ts +6 -2
- package/types/ids-group-ltd-ids-design-system-components-pagination.d.ts +17 -10
- package/types/ids-group-ltd-ids-design-system-components-password-rules.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-pie-chart.d.ts +25 -14
- package/types/ids-group-ltd-ids-design-system-components-scatter-chart.d.ts +15 -6
- package/types/ids-group-ltd-ids-design-system-components-search.d.ts +9 -3
- package/types/ids-group-ltd-ids-design-system-components-select.d.ts +3 -2
- package/types/ids-group-ltd-ids-design-system-components-sidenav-footer.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-sidenav.d.ts +3 -1
- package/types/ids-group-ltd-ids-design-system-components-skeleton.d.ts +6 -1
- package/types/ids-group-ltd-ids-design-system-components-slider.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-spinner.d.ts +6 -4
- package/types/ids-group-ltd-ids-design-system-components-split-button.d.ts +5 -2
- package/types/ids-group-ltd-ids-design-system-components-stepper.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-switch.d.ts +10 -1
- package/types/ids-group-ltd-ids-design-system-components-table-export.d.ts +1 -0
- package/types/ids-group-ltd-ids-design-system-components-table.d.ts +44 -28
- package/types/ids-group-ltd-ids-design-system-components-tabs.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-tag.d.ts +6 -2
- package/types/ids-group-ltd-ids-design-system-components-textarea.d.ts +15 -0
- package/types/ids-group-ltd-ids-design-system-components-time-picker.d.ts +3 -0
- package/types/ids-group-ltd-ids-design-system-components-toast.d.ts +3 -0
- package/types/ids-group-ltd-ids-design-system-components-w3w.d.ts +2 -0
- package/types/ids-group-ltd-ids-design-system-components-waterfall-chart.d.ts +7 -5
- package/types/ids-group-ltd-ids-design-system-components.d.ts +83 -17
- package/types/ids-group-ltd-ids-design-system-core.d.ts +420 -14
- package/types/ids-group-ltd-ids-design-system.d.ts +3 -3
package/migrations/0.5.0.json
CHANGED
|
@@ -6,13 +6,16 @@
|
|
|
6
6
|
"kind": "selector-rename",
|
|
7
7
|
"old": "ds-combobox",
|
|
8
8
|
"new": "ds-autocomplete",
|
|
9
|
-
"action": "Replace the element selector `ds-combobox` with `ds-autocomplete
|
|
9
|
+
"action": "Replace the element selector `ds-combobox` with `ds-autocomplete`, in templates and in any stylesheet rule that names the element.",
|
|
10
10
|
"note": "A rename to the industry word for the control. Behaviour is unchanged.",
|
|
11
11
|
"searchHints": [
|
|
12
12
|
"<ds-combobox",
|
|
13
13
|
"ds-combobox"
|
|
14
14
|
],
|
|
15
|
-
"surface":
|
|
15
|
+
"surface": [
|
|
16
|
+
"template",
|
|
17
|
+
"style"
|
|
18
|
+
]
|
|
16
19
|
},
|
|
17
20
|
{
|
|
18
21
|
"id": "combobox-component-class-rename",
|
|
@@ -84,13 +87,16 @@
|
|
|
84
87
|
"kind": "selector-rename",
|
|
85
88
|
"old": "ds-dropdown",
|
|
86
89
|
"new": "ds-select",
|
|
87
|
-
"action": "Replace `ds-dropdown` with `ds-select
|
|
90
|
+
"action": "Replace `ds-dropdown` with `ds-select` in templates and in any stylesheet rule that names the element, then apply `dropdown-error-input-rename` and `dropdown-option-groups-fold` to the same elements.",
|
|
88
91
|
"note": "ds-dropdown is gone; ds-select is the one select-only picker, and it carries the CVA, invalid and hint, required and optional, per-option icons and readOnly.",
|
|
89
92
|
"searchHints": [
|
|
90
93
|
"<ds-dropdown",
|
|
91
94
|
"ds-dropdown"
|
|
92
95
|
],
|
|
93
|
-
"surface":
|
|
96
|
+
"surface": [
|
|
97
|
+
"template",
|
|
98
|
+
"style"
|
|
99
|
+
]
|
|
94
100
|
},
|
|
95
101
|
{
|
|
96
102
|
"id": "dropdown-error-input-rename",
|
package/migrations/0.7.0.json
CHANGED
|
@@ -203,12 +203,15 @@
|
|
|
203
203
|
"kind": "selector-rename",
|
|
204
204
|
"old": "ds-app-shell",
|
|
205
205
|
"new": "ds-app-layout",
|
|
206
|
-
"action": "Rename the element and its closing tag from `ds-app-shell` to `ds-app-layout`, then apply the class, service and token items below.",
|
|
206
|
+
"action": "Rename the element and its closing tag from `ds-app-shell` to `ds-app-layout`, and any stylesheet rule that names the element with it, then apply the class, service and token items below.",
|
|
207
207
|
"note": "Behaviour is unchanged; the component shipped as ds-app-shell in the tagged 0.6.3 source.",
|
|
208
208
|
"searchHints": [
|
|
209
209
|
"ds-app-shell"
|
|
210
210
|
],
|
|
211
|
-
"surface":
|
|
211
|
+
"surface": [
|
|
212
|
+
"template",
|
|
213
|
+
"style"
|
|
214
|
+
]
|
|
212
215
|
},
|
|
213
216
|
{
|
|
214
217
|
"id": "app-shell-class-to-app-layout",
|
package/migrations/0.9.0.json
CHANGED
|
@@ -44,13 +44,16 @@
|
|
|
44
44
|
"kind": "selector-rename",
|
|
45
45
|
"old": "ds-auth-shell",
|
|
46
46
|
"new": "ds-auth-layout",
|
|
47
|
-
"action": "Rename the element and its closing tag from `ds-auth-shell` to `ds-auth-layout`, then apply the class and token items below.",
|
|
47
|
+
"action": "Rename the element and its closing tag from `ds-auth-shell` to `ds-auth-layout`, and any stylesheet rule that names the element with it, then apply the class and token items below.",
|
|
48
48
|
"appliesWhen": "Behaviour, inputs and slots are unchanged — `brand`, `logoLetter`, `tagline`, `cardElevation`, `cardPadding`, `[brand]`, `[dsBrandName]` and `dsAuthSupport` all keep their names.",
|
|
49
49
|
"note": "\"Shell\" is not this library's word for a layout: the app-level one became ds-app-layout in 0.7.0, and calling the auth counterpart a shell put the split vocabulary back. It shipped as ds-auth-shell in exactly one release.",
|
|
50
50
|
"searchHints": [
|
|
51
51
|
"ds-auth-shell"
|
|
52
52
|
],
|
|
53
|
-
"surface":
|
|
53
|
+
"surface": [
|
|
54
|
+
"template",
|
|
55
|
+
"style"
|
|
56
|
+
]
|
|
54
57
|
},
|
|
55
58
|
{
|
|
56
59
|
"id": "auth-shell-class-to-auth-layout",
|
package/migrations/README.md
CHANGED
|
@@ -16,7 +16,8 @@ One file per released version — `migrations/<version>.json` — mirroring that
|
|
|
16
16
|
"deleteList": [ { "id": "<slug>", "surface": "<surface>", "find": ["<shape>", "..."],
|
|
17
17
|
"why": "<what made it unnecessary>",
|
|
18
18
|
"replaceWith": "<the API that replaces it>" } ],
|
|
19
|
-
"informational": [ "<one-line FYI per non-actionable change group>"
|
|
19
|
+
"informational": [ "<one-line FYI per non-actionable change group>" |
|
|
20
|
+
{ "text": "...", "verify": "<one concrete eyeball check>" } ] }
|
|
20
21
|
```
|
|
21
22
|
|
|
22
23
|
- `kind` ∈ `selector-rename | type-rename | input-rename | output-rename | token-rename |
|
|
@@ -26,7 +27,8 @@ One file per released version — `migrations/<version>.json` — mirroring that
|
|
|
26
27
|
a value absent from the map is undocumented-as-changed and must be left untouched.
|
|
27
28
|
- `old` of an element-scoped item is `element[attr]`.
|
|
28
29
|
- **`surface`** — which of the consumer's artifacts changes: their `template`, their `typescript`,
|
|
29
|
-
their `style`, their app `config`, or `none` when the only action is to LOOK
|
|
30
|
+
their `style`, their app `config`, or `none` when the only action is to LOOK (an item keeps
|
|
31
|
+
`surface: none` only beside a `restore` or a conditional `action`). It is a required
|
|
30
32
|
statement, not a hint: `none` and "the author forgot" must not read the same to a finder.
|
|
31
33
|
- **`detect`** — the shapes to grep for when `old` is a DS symbol the affected code never mentions.
|
|
32
34
|
Written the way the consumer writes it (`orderBy: sortKey`, `?? config.control?.size`), not the
|
|
@@ -49,6 +51,9 @@ One file per released version — `migrations/<version>.json` — mirroring that
|
|
|
49
51
|
- **`pitfall`** — the way to apply the item mechanically correctly and still ship a broken app.
|
|
50
52
|
Read it before deciding a clean build means done.
|
|
51
53
|
- **`deleteList`** — the structured form of "what you can now delete" (see below).
|
|
54
|
+
- **`informational`** — a non-actionable FYI, a bare string or `{ "text": "...", "verify": "..." }`
|
|
55
|
+
where `verify` is the one eyeball check for a change to rendering alone (no symbol for a grep or
|
|
56
|
+
a build to catch).
|
|
52
57
|
|
|
53
58
|
**Why:** an upgrade tool can read the plan out of the prose changelog, but it re-derives it on
|
|
54
59
|
every run. A shipped manifest makes it deterministic: the tool validates and prefers the
|
package/package.json
CHANGED
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.checkOverrides = checkOverrides;
|
|
4
|
+
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
|
+
const scan_cjs_1 = require("./scan.cjs");
|
|
6
|
+
const STYLE_FILE = /\.(scss|css|sass|less)$/;
|
|
7
|
+
const TOKEN_ONLY_FILE = /\.(html|ts)$/;
|
|
8
|
+
const SKIPPED_DIR = /\/(node_modules|dist|\.angular)\//;
|
|
9
|
+
// `style.` catches `[style.--ds-x]="…"`, `setProperty('` catches
|
|
10
|
+
// `el.style.setProperty('--ds-x', …)`. Everything else on an .html/.ts line is prose or an
|
|
11
|
+
// unrelated binding, not a custom-property write.
|
|
12
|
+
const BINDING_MARKER = /style\.|setProperty\('/;
|
|
13
|
+
/**
|
|
14
|
+
* `ng g @ids-group-ltd/ids-design-system:check-overrides` — reports every `--ds-*` a consumer's
|
|
15
|
+
* stylesheets set that the installed version never reads, and every `ds-*` selector naming a class
|
|
16
|
+
* its components do not render. Read-only: it changes no file.
|
|
17
|
+
*/
|
|
18
|
+
function checkOverrides(options) {
|
|
19
|
+
return (tree, context) => {
|
|
20
|
+
const surface = require('./surface.json');
|
|
21
|
+
const readTokens = new Set(surface.tokens);
|
|
22
|
+
let tokenHits = 0;
|
|
23
|
+
let classHits = 0;
|
|
24
|
+
tree.getDir(options.path ?? '/').visit((path, entry) => {
|
|
25
|
+
if (SKIPPED_DIR.test(`${path}/`) || !entry)
|
|
26
|
+
return;
|
|
27
|
+
const isStyleFile = STYLE_FILE.test(path);
|
|
28
|
+
const isTokenOnlyFile = !isStyleFile && TOKEN_ONLY_FILE.test(path);
|
|
29
|
+
if (!isStyleFile && !isTokenOnlyFile)
|
|
30
|
+
return;
|
|
31
|
+
const content = entry.content.toString('utf8');
|
|
32
|
+
const tokenSource = isStyleFile
|
|
33
|
+
? content
|
|
34
|
+
: content
|
|
35
|
+
.split(/\r\n|\n/)
|
|
36
|
+
.map((line) => (BINDING_MARKER.test(line) ? line : ''))
|
|
37
|
+
.join('\n');
|
|
38
|
+
for (const hit of (0, scan_cjs_1.findWriteOnlyTokens)(tokenSource, readTokens)) {
|
|
39
|
+
context.logger.warn(`${path}:${hit.line} ${hit.token} is not read by @ids-group-ltd/ids-design-system ${surface.version}`);
|
|
40
|
+
tokenHits++;
|
|
41
|
+
}
|
|
42
|
+
if (isStyleFile) {
|
|
43
|
+
for (const hit of (0, scan_cjs_1.findDeadClasses)(content, surface.classes)) {
|
|
44
|
+
context.logger.warn(`${path}:${hit.line} ${hit.selector} .${hit.className}: ${hit.selector} renders no such class in ${surface.version}`);
|
|
45
|
+
classHits++;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
const summary = `check-overrides: ${tokenHits} write-only token(s), ${classHits} dead class(es)`;
|
|
50
|
+
context.logger.info(summary);
|
|
51
|
+
if (options.strict && tokenHits + classHits > 0) {
|
|
52
|
+
throw new schematics_1.SchematicsException(summary);
|
|
53
|
+
}
|
|
54
|
+
return tree;
|
|
55
|
+
};
|
|
56
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Pure text scanning, no devkit import, so `tools/check-overrides-selftest.mjs` can exercise it
|
|
3
|
+
// directly with `node:assert` instead of a schematic tree.
|
|
4
|
+
//
|
|
5
|
+
// Both scans work line by line: a `ds-*` selector and the class it dead-styles have to share a
|
|
6
|
+
// line to be caught. A class inside a nested SCSS block under `ds-x {` on another line is not
|
|
7
|
+
// resolved — documented in README.md alongside the schematic.
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.findWriteOnlyTokens = findWriteOnlyTokens;
|
|
10
|
+
exports.findDeadClasses = findDeadClasses;
|
|
11
|
+
// Comments are stripped per line so a token or selector only mentioned in prose never reports a
|
|
12
|
+
// hit; a `/* … */` spanning several lines is tracked across them.
|
|
13
|
+
function linesWithoutComments(text) {
|
|
14
|
+
let inBlockComment = false;
|
|
15
|
+
return text.split(/\r\n|\n/).map((rawLine) => {
|
|
16
|
+
let line = rawLine;
|
|
17
|
+
if (inBlockComment) {
|
|
18
|
+
const end = line.indexOf('*/');
|
|
19
|
+
if (end === -1)
|
|
20
|
+
return '';
|
|
21
|
+
line = line.slice(end + 2);
|
|
22
|
+
inBlockComment = false;
|
|
23
|
+
}
|
|
24
|
+
const lineCommentAt = line.indexOf('//');
|
|
25
|
+
if (lineCommentAt !== -1)
|
|
26
|
+
line = line.slice(0, lineCommentAt);
|
|
27
|
+
let cleaned = '';
|
|
28
|
+
let rest = line;
|
|
29
|
+
for (;;) {
|
|
30
|
+
const blockStart = rest.indexOf('/*');
|
|
31
|
+
if (blockStart === -1) {
|
|
32
|
+
cleaned += rest;
|
|
33
|
+
break;
|
|
34
|
+
}
|
|
35
|
+
cleaned += rest.slice(0, blockStart);
|
|
36
|
+
const blockEnd = rest.indexOf('*/', blockStart + 2);
|
|
37
|
+
if (blockEnd === -1) {
|
|
38
|
+
inBlockComment = true;
|
|
39
|
+
break;
|
|
40
|
+
}
|
|
41
|
+
rest = rest.slice(blockEnd + 2);
|
|
42
|
+
}
|
|
43
|
+
return cleaned;
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
function findWriteOnlyTokens(text, readTokens) {
|
|
47
|
+
const hits = [];
|
|
48
|
+
linesWithoutComments(text).forEach((line, index) => {
|
|
49
|
+
for (const match of line.matchAll(/(--ds-[a-z0-9-]+)\s*:/g)) {
|
|
50
|
+
const token = match[1];
|
|
51
|
+
if (!readTokens.has(token))
|
|
52
|
+
hits.push({ token, line: index + 1 });
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
return hits;
|
|
56
|
+
}
|
|
57
|
+
function findDeadClasses(text, classesBySelector) {
|
|
58
|
+
const hits = [];
|
|
59
|
+
linesWithoutComments(text).forEach((line, index) => {
|
|
60
|
+
for (const match of line.matchAll(/\b(ds-[a-z0-9-]+)\b([^{;,]*)/g)) {
|
|
61
|
+
const selector = match[1];
|
|
62
|
+
const knownClasses = classesBySelector[selector];
|
|
63
|
+
if (!knownClasses)
|
|
64
|
+
continue;
|
|
65
|
+
for (const classMatch of match[2].matchAll(/\.(-?[_a-zA-Z][\w-]*)/g)) {
|
|
66
|
+
const className = classMatch[1];
|
|
67
|
+
if (!knownClasses.includes(className)) {
|
|
68
|
+
hits.push({ selector, className, line: index + 1 });
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
return hits;
|
|
74
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/schema",
|
|
3
|
+
"$id": "IdsCheckOverrides",
|
|
4
|
+
"title": "IDS check-overrides Options",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"strict": {
|
|
8
|
+
"type": "boolean",
|
|
9
|
+
"default": false,
|
|
10
|
+
"description": "Fail when anything is reported."
|
|
11
|
+
},
|
|
12
|
+
"path": {
|
|
13
|
+
"type": "string",
|
|
14
|
+
"default": "/",
|
|
15
|
+
"description": "Workspace folder to scan."
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"required": []
|
|
19
|
+
}
|