@assure-one/design-system 1.38.0 → 1.40.0

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.
Files changed (68) hide show
  1. package/README.md +63 -28
  2. package/codemods/README.md +76 -25
  3. package/codemods/lib/entry-map.mjs +315 -0
  4. package/codemods/lib/registry.mjs +28 -0
  5. package/codemods/lib/runner.mjs +8 -3
  6. package/codemods/run.mjs +27 -5
  7. package/codemods/transforms/cm-01-entry-imports.mjs +202 -0
  8. package/codemods/transforms/cm-15-dom-selectors.mjs +16 -9
  9. package/dist/brand-scope-BOHId6BY.d.ts +58 -0
  10. package/dist/brand-theme-ZYM867Jz.d.ts +59 -0
  11. package/dist/chunk-2MKLYYIY.js +3754 -0
  12. package/dist/chunk-2MKLYYIY.js.map +1 -0
  13. package/dist/chunk-6S2R2VWN.js +5527 -0
  14. package/dist/chunk-6S2R2VWN.js.map +1 -0
  15. package/dist/chunk-7U3ADR2Q.js +4336 -0
  16. package/dist/chunk-7U3ADR2Q.js.map +1 -0
  17. package/dist/chunk-CPOGSNXS.js +389 -0
  18. package/dist/chunk-CPOGSNXS.js.map +1 -0
  19. package/dist/chunk-EUHGZA6Q.js +313 -0
  20. package/dist/chunk-EUHGZA6Q.js.map +1 -0
  21. package/dist/chunk-KQBYTTAN.js +1829 -0
  22. package/dist/chunk-KQBYTTAN.js.map +1 -0
  23. package/dist/chunk-X76J4QSJ.js +164 -0
  24. package/dist/chunk-X76J4QSJ.js.map +1 -0
  25. package/dist/css/components.css +1 -1
  26. package/dist/css/legacy-aliases.css +2 -0
  27. package/dist/css/tailwind.css +2 -0
  28. package/dist/css/tokens.css +8 -6
  29. package/dist/data-table-view-ep8al7P9.d.ts +1132 -0
  30. package/dist/design-system-provider-CfD2g2lY.d.ts +142 -0
  31. package/dist/icons/index.d.ts +441 -3
  32. package/dist/icons/index.js +2 -1835
  33. package/dist/icons/index.js.map +1 -1
  34. package/dist/index.d.ts +404 -3847
  35. package/dist/index.js +8728 -24213
  36. package/dist/index.js.map +1 -1
  37. package/dist/legacy/index.d.ts +1464 -0
  38. package/dist/legacy/index.js +7 -0
  39. package/dist/legacy/index.js.map +1 -0
  40. package/dist/next/index.d.ts +2 -1
  41. package/dist/reference-BkDbrPIB.d.ts +310 -0
  42. package/dist/styles.css +2 -1
  43. package/dist/suite/index.d.ts +989 -0
  44. package/dist/suite/index.js +8 -0
  45. package/dist/suite/index.js.map +1 -0
  46. package/dist/{system-CyAVbHhM.d.ts → system-DfJIVBlJ.d.ts} +1 -310
  47. package/dist/testing/index.cjs +3 -2
  48. package/dist/testing/index.js +3 -2
  49. package/dist/tokens/index.d.ts +3 -61
  50. package/dist/tokens/index.js +3 -856
  51. package/dist/tokens/index.js.map +1 -1
  52. package/dist/{design-system-provider-B5MbvbRc.d.ts → types-Coqw8iaS.d.ts} +36 -142
  53. package/dist/vocab-DornLJbW.d.ts +76 -0
  54. package/docs/components.md +54 -52
  55. package/docs/components.registry.json +22 -8
  56. package/docs/for-ai-agents.md +12 -6
  57. package/package.json +17 -4
  58. package/public/brand/assure-audit-mark.svg +6 -0
  59. package/public/brand/assure-audit.svg +8 -0
  60. package/public/brand/assure-books-mark.svg +6 -0
  61. package/public/brand/assure-books.svg +8 -0
  62. package/public/brand/assure-pro-mark.svg +6 -0
  63. package/public/brand/assure-pro.svg +8 -0
  64. package/public/brand/assure-tax-mark.svg +6 -0
  65. package/public/brand/assure-tax.svg +8 -0
  66. package/public/brand/mycpe-teams-mark.svg +36 -0
  67. package/public/brand/mycpe-teams.svg +66 -0
  68. package/dist/index-vztxMSfl.d.ts +0 -512
package/README.md CHANGED
@@ -27,13 +27,23 @@ The single source of truth for visual design across all Assure products.
27
27
  pnpm add @assure-one/design-system
28
28
  ```
29
29
 
30
- Import the consumer stylesheet once in your root layout. Its bundled component
31
- utilities intentionally live below your app's Tailwind `utilities` layer, so
32
- local classes and responsive variants remain authoritative even when a bundler
33
- reorders CSS chunks:
30
+ Load the design system's CSS from your app's global stylesheet, as the split
31
+ entries, under one layer statement (Tailwind 4 in your build):
34
32
 
35
- ```ts
36
- import "@assure-one/design-system/styles.css";
33
+ ```css
34
+ /* src/app/globals.css — the layer statement is the first line of the file */
35
+ @layer theme, base, ds, components, utilities;
36
+
37
+ @import "tailwindcss";
38
+
39
+ @import "@assure-one/design-system/css/tokens.css";
40
+ @import "@assure-one/design-system/css/legacy-aliases.css"; /* optional */
41
+ @import "@assure-one/design-system/css/tailwind.css";
42
+ @import "@assure-one/design-system/css/shadcn.css"; /* optional */
43
+ @import "@assure-one/design-system/css/base.css"; /* optional */
44
+ @import "@assure-one/design-system/css/components.css";
45
+
46
+ @import "./ds-preset.css"; /* your app's preset, optional */
37
47
  ```
38
48
 
39
49
  Then use components:
@@ -46,32 +56,42 @@ export default function Page() {
46
56
  }
47
57
  ```
48
58
 
49
- ### The split CSS entries (experimental)
59
+ ### The split CSS entries
50
60
 
51
- `styles.css` stays the supported way to consume the design system, unchanged.
52
- Alongside it, the package now also publishes the individual stylesheets the new
53
- CSS mode is built from. They are **experimental**: nothing requires them yet,
54
- no component reads them, and importing them changes nothing on its own.
61
+ The split entries are the documented default CSS integration since 1.40. Every
62
+ design-system class is `ds:`-prefixed and compiled into `css/components.css`
63
+ inside `@layer ds`, so your own utilities always win over component styles and
64
+ your Tailwind build never has to scan our package.
55
65
 
56
- | Subpath | What it is |
57
- | -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
58
- | `./css/tokens.css` | The `--ds-*` design tokens: `:root`, the colour scheme scope and the brand scopes. Usable without any component. |
59
- | `./css/legacy-aliases.css` | Read-aliases from today's token names to the namespaced ones (`--color-surface: var(--ds-color-surface)`), for as long as your own CSS reads design-system token names. |
60
- | `./css/tailwind.css` | A Tailwind `@theme` bridge, so `bg-surface/40`, `hover:text-fg-3` and `rounded-control` compile in _your_ build instead of silently producing nothing. |
61
- | `./css/shadcn.css` | The app-vocabulary bridge: `background`, `foreground`, `primary`, `muted`, `destructive`, the radius scale and the rest, each reading one `--app-*` input you can override. |
62
- | `./css/base.css` | Optional document defaults: body background, ink, font and `color-scheme`. Ships no preflight, no element rules and no font import. |
63
- | `./css/components.css` | The component utilities compiled with Tailwind's `ds` prefix (`ds:flex`, `ds:bg-surface`), inside `@layer ds` and bound to the `--ds-*` tokens. **Unused until the class-vocabulary flip (W1-11):** no component emits a prefixed class yet, so importing it styles nothing. Published so the file, its size and its hygiene can be reviewed before the flip. |
66
+ | Subpath | What it is |
67
+ | -------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
68
+ | `./css/tokens.css` | The `--ds-*` design tokens: `:root`, the colour scheme scope and the brand scopes. Usable without any component. |
69
+ | `./css/legacy-aliases.css` | Read-aliases from today's token names to the namespaced ones (`--color-surface: var(--ds-color-surface)`), for as long as your own CSS reads design-system token names. |
70
+ | `./css/tailwind.css` | A Tailwind `@theme` bridge, so `bg-surface/40`, `hover:text-fg-3` and `rounded-control` compile in _your_ build instead of silently producing nothing. |
71
+ | `./css/shadcn.css` | The app-vocabulary bridge: `background`, `foreground`, `primary`, `muted`, `destructive`, the radius scale and the rest, each reading one `--app-*` input you can override. |
72
+ | `./css/base.css` | Optional document defaults: body background, ink, font and `color-scheme`. Ships no preflight, no element rules and no font import. |
73
+ | `./css/components.css` | The component utilities compiled with Tailwind's `ds` prefix (`ds:flex`, `ds:bg-surface`), inside `@layer ds` and bound to the `--ds-*` tokens. |
64
74
 
65
75
  Import order is `tokens.css` → `legacy-aliases.css` (optional) → `tailwind.css`
66
76
  → `shadcn.css` (optional) → `base.css` (optional) → `components.css`, after your own
67
77
  `@import "tailwindcss"` and under the layer statement
68
78
  `@layer theme, base, ds, components, utilities;`.
69
79
  [**`docs/integration/css.md`**](./docs/integration/css.md) has the full
70
- sequence, where the per-app preset goes, when the `@source` into our package may
71
- be removed, and the fixture run behind each of those claims. The reasoning lives
80
+ sequence, where the per-app preset goes, why no `@source` into our package is
81
+ needed, and the fixture run behind each of those claims. The reasoning lives
72
82
  in [ADR-004](./docs/adr/004-css-delivery-cascade.md) and
73
83
  [ADR-005](./docs/adr/005-app-vocabulary-bridge.md).
74
84
 
85
+ ### `styles.css` (deprecated)
86
+
87
+ `@assure-one/design-system/styles.css` — the all-in-one sheet with its own
88
+ preflight, a Google Fonts `@import` and the frozen unprefixed legacy utilities —
89
+ is **deprecated since 1.40** (registry `C-CSS-STYLES`). It still ships, unchanged,
90
+ and is removed in 3.0; the built file opens with a deprecation
91
+ banner. Moving to the split entries is a deliberate visual change (document font
92
+ size, fonts, preflight): follow [`docs/integration/css.md`](./docs/integration/css.md)
93
+ §6 and [`docs/migration/1.40.md`](./docs/migration/1.40.md).
94
+
75
95
  ### Runtime brand theming (experimental)
76
96
 
77
97
  For a tenant colour known only at runtime, `@assure-one/design-system/tokens`
@@ -89,11 +109,27 @@ canvas, and guarantees WCAG AA for every foreground it emits. The seed shape is
89
109
  gated by decision D7 and may change while that decision is open — see
90
110
  [`docs/integration/css.md`](./docs/integration/css.md#5-runtime-brand-theming).
91
111
 
112
+ ### Brand artwork
113
+
114
+ The Assure wordmarks and marks `Logo` renders ship inside the package, under
115
+ `public/brand/`. They are served by your app, not imported, so copy them once
116
+ into your public folder:
117
+
118
+ ```sh
119
+ cp -R node_modules/@assure-one/design-system/public/brand public/brand
120
+ ```
121
+
122
+ An app served from a subpath calls `setAssetBasePath("/my-base")` once before
123
+ first render instead of (or as well as) moving the files. A `Logo` whose
124
+ artwork does not load falls back to the brand glyph + text lockup, so nothing
125
+ is required to get a readable lockup.
126
+
92
127
  ### The provider and the `/next` entry (experimental)
93
128
 
94
129
  Nothing requires a provider: every component renders English strings, formats
95
- with `en-US` and (for `LinkButton` / `Logo`) routes through `next/link` on its
96
- own. `DesignSystemProvider` is the one optional, thin, client-side provider
130
+ with `en-US` and (for `LinkButton` / `Logo`) renders a plain `<a>` / `<img>`.
131
+ On Next.js, render `NextDesignSystemProvider` to get `next/link` routing and
132
+ `next/image`: the root imports no `next/*` since 2.0. `DesignSystemProvider` is the one optional, thin, client-side provider
97
133
  for what CSS cannot do — the generic strings, the locale, the text direction,
98
134
  the portal container, the link and image adapters, shared tooltip defaults and
99
135
  (opt-in) the toast region. It renders no DOM wrapper ([ADR-010](./docs/adr/010-design-system-provider.md)).
@@ -128,11 +164,10 @@ export default function RootLayout({ children }) {
128
164
  Pass the locale your app already knows server-side; the design system never
129
165
  reads `navigator.language` during render, so server and client HTML agree.
130
166
  - **`linkComponent` / `imageComponent`** — what `LinkButton` and `Logo` render
131
- through. Without them the components keep their static `next/link` /
132
- `next/image` imports until 2.0, so a Next.js app that renders no provider is
133
- unchanged. A non-Next app passes its router's link; a Next.js app uses
134
- `NextDesignSystemProvider` so it is ready for the 2.0 removal of the static
135
- imports.
167
+ through. Without them the components render a plain `<a>` / `<img>` (full
168
+ page navigation). A non-Next app passes its router's link; a Next.js app uses
169
+ `NextDesignSystemProvider`. `next` is an optional peer, needed only by the
170
+ `/next` entry.
136
171
  - **`portalContainer`**, **`dir`**, **`tooltip`**, **`toasts`** — documented on
137
172
  the props. `toasts` mounts the toast region for `useToast()`; leave it off if
138
173
  you already render `ToastProvider`.
@@ -19,6 +19,9 @@ node node_modules/@assure-one/design-system/codemods/run.mjs CM-02 src --report
19
19
 
20
20
  # Everything this project is missing, in program order
21
21
  node node_modules/@assure-one/design-system/codemods/run.mjs upgrade --dry
22
+
23
+ # Only what a project needs before 1.40 (docs/migration/1.40.md)
24
+ node node_modules/@assure-one/design-system/codemods/run.mjs upgrade --to 1.40 --dry
22
25
  ```
23
26
 
24
27
  There is deliberately **no** `bin` entry and **no** `exports` entry for the
@@ -30,6 +33,7 @@ is `pnpm codemods <id> <paths>`.
30
33
  | Option | Effect |
31
34
  | ------------------------------- | ------------------------------------------------------------------------------ |
32
35
  | `--dry` | report what would happen; write neither files nor the ledger |
36
+ | `--to <version>` | `upgrade` only: run the bundle that release needs (`--to 1.40`, see below) |
33
37
  | `--root <dir>` | project root (default: the nearest `package.json` above the working directory) |
34
38
  | `--report <prefix>` | write `<prefix>.json` and `<prefix>.md` |
35
39
  | `--json <file>` / `--md <file>` | write one of the two |
@@ -96,6 +100,19 @@ entry. Report-only codemods and dry runs never touch it. The consumer scanner
96
100
  reads the file and the migration dashboard shows the applied ids
97
101
  (`migration-status/<app>.json` → `codemodLedger`).
98
102
 
103
+ ## `upgrade --to 1.40`
104
+
105
+ `upgrade --to 1.40` runs, in program order, the codemods of the 1.40 bundle
106
+ (`UPGRADE_TARGETS` in `lib/registry.mjs`): one per registry contract that 1.40
107
+ removes or flips (plan §21.2) — CM-01, CM-04, CM-19, CM-12, and the finders
108
+ CM-15 and CM-16. A transforming codemod already in the ledger is skipped, so
109
+ the command is safe to repeat and safe from any 1.x; the report-only finders
110
+ run every time. With `--report <prefix>` each codemod writes
111
+ `<prefix>-<id>.json` and `.md`. The migration guide is
112
+ [`docs/migration/1.40.md`](../docs/migration/1.40.md). `--to 2` (also `2.0`,
113
+ `v2`) still works: it is the name the bundle had while Wave 9 was planned as
114
+ 2.0 (decision D11 shipped it as 1.40).
115
+
99
116
  ## Reports
100
117
 
101
118
  Every run produces the same report: a JSON document (`schema`, the codemod, the
@@ -107,28 +124,62 @@ the list a human has to pick up — spread props, dynamic expressions, conflicti
107
124
 
108
125
  ## Codemods
109
126
 
110
- | Id | Class | What it does |
111
- | ----- | ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
112
- | CM-05 | A | Button family `iconLeft` / `iconRight` → `iconStart` / `iconEnd` (pure rename; both names of one slot, spreads → "could not be transformed") |
113
- | CM-13 | A | `Tooltip delayMs` → `delayDuration` (pure rename, literal or dynamic value; both names, spreads → "could not be transformed") |
114
- | CM-07 | A | `inputSize` → `size` on `Input`, `Textarea`, `SearchInput` (pure rename, literal or dynamic value; both names, spreads → "could not be transformed") |
115
- | CM-02 | A | Button explicit default size: `size="md"` on every `Button`, `SubmitButton` and `LinkButton` that passes no `size` (pixel-neutral) |
116
- | CM-04 | R | Button family legacy `variant` → `variant` + `intent` pair (`primary` → `solid`, `destructive` → `solid` + `danger`, …); `accent`, `dashed`, dynamic → report |
117
- | CM-06 | R | `tone` → `intent` on StatusDot, IconTile, Spinner, SegmentedProgress, SuiteProgress (`pro` → `brand`, listed for review); product hues → report |
118
- | CM-19 | R | ProgressBar/ProgressRing: `variant` → `intent`, and the value → colour rule written down as an explicit `intent` where the value is a literal; dynamic values → report |
119
- | CM-12 | R | Button `type="submit"` where the intent is evident (inside `<form>` in the same file, no `onClick`); everything else untyped → report |
120
- | CM-10 | R | `DatePicker onChange={e => f(e.target.value)}` → `onValueChange={value => f(value)}` for the recognisable arrow shapes; handlers by reference, other shapes → report |
121
- | CM-08 | R | `SearchSelect` → `Combobox`: single-mode call sites rewritten (tag, import, `{id,label}` accessors, placeholder → `aria-label`); multi API, extras and unnamed sites → report |
127
+ | Id | Class | What it does |
128
+ | ----- | ----- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
129
+ | CM-01 | R | Root imports of suite, legacy and product-owned names → `@assure-one/design-system/suite` and `/legacy` (same references, pure path change); `import * as DS` → report |
130
+ | CM-05 | A | Button family `iconLeft` / `iconRight` → `iconStart` / `iconEnd` (pure rename; both names of one slot, spreads → "could not be transformed") |
131
+ | CM-13 | A | `Tooltip delayMs` → `delayDuration` (pure rename, literal or dynamic value; both names, spreads → "could not be transformed") |
132
+ | CM-07 | A | `inputSize` → `size` on `Input`, `Textarea`, `SearchInput` (pure rename, literal or dynamic value; both names, spreads → "could not be transformed") |
133
+ | CM-02 | A | Button explicit default size: `size="md"` on every `Button`, `SubmitButton` and `LinkButton` that passes no `size` (pixel-neutral) |
134
+ | CM-04 | R | Button family legacy `variant` → `variant` + `intent` pair (`primary` → `solid`, `destructive` → `solid` + `danger`, …); `accent`, `dashed`, dynamic → report |
135
+ | CM-06 | R | `tone` → `intent` on StatusDot, IconTile, Spinner, SegmentedProgress, SuiteProgress (`pro` → `brand`, listed for review); product hues → report |
136
+ | CM-19 | R | ProgressBar/ProgressRing: `variant` → `intent`, and the value → colour rule written down as an explicit `intent` where the value is a literal; dynamic values → report |
137
+ | CM-12 | R | Button `type="submit"` where the intent is evident (inside `<form>` in the same file, no `onClick`); everything else untyped → report |
138
+ | CM-10 | R | `DatePicker onChange={e => f(e.target.value)}` → `onValueChange={value => f(value)}` for the recognisable arrow shapes; handlers by reference, other shapes → report |
139
+ | CM-08 | R | `SearchSelect` → `Combobox`: single-mode call sites rewritten (tag, import, `{id,label}` accessors, placeholder → `aria-label`); multi API, extras and unnamed sites → report |
122
140
  | CM-09 | R | `SideDrawer` → `Sheet`: drawers with a `SideDrawer.Header` rewritten (root → `Sheet` + `SheetContent side size`, `onClose` → `onOpenChange`, header → `SheetHeader`/`SheetTitle`/`SheetDescription`, Body/Footer → `SheetBody`/`SheetFooter`, import); no header, dynamic width, spreads → report |
123
- | CM-18 | A | `DataTable*` presentational parts → `Table*` (`DataTableHead` → `TableHeader`, `Body`, `Row`, `Cell`, `DataTableHeader` → `TableHead`) where the mapping is 1:1; uncontrolled sorting, a dynamic `sortable` and spreads → "could not be transformed" |
124
- | CM-14 | X | hidden-input mirror finder: hidden `<input name>` a consumer added because a design-system control posts nothing |
125
- | CM-15 | X | DOM-selector finder: consumer code that depends on the internal DOM of design-system components, mapped to registry `C-DOM-*` ids |
126
- | CM-16 | X | `globals.css` analyser: `@source` into the package, duplicate preflight, colliding `@theme` keys, unlayered globals, legacy `var()` |
127
- | CM-20 | X | Select sentinel finder: option values standing in for "no value", and the line where each is converted back |
141
+ | CM-18 | A | `DataTable*` presentational parts → `Table*` (`DataTableHead` → `TableHeader`, `Body`, `Row`, `Cell`, `DataTableHeader` → `TableHead`) where the mapping is 1:1; uncontrolled sorting, a dynamic `sortable` and spreads → "could not be transformed" |
142
+ | CM-14 | X | hidden-input mirror finder: hidden `<input name>` a consumer added because a design-system control posts nothing |
143
+ | CM-15 | X | DOM-selector finder: consumer code that depends on the internal DOM of design-system components, mapped to registry `C-DOM-*` ids |
144
+ | CM-16 | X | `globals.css` analyser: `@source` into the package, duplicate preflight, colliding `@theme` keys, unlayered globals, legacy `var()` |
145
+ | CM-20 | X | Select sentinel finder: option values standing in for "no value", and the line where each is converted back |
128
146
 
129
147
  The remaining ids of plan §29 land with the waves that ship their replacement
130
148
  APIs.
131
149
 
150
+ ### CM-01 — root imports → `/suite` and `/legacy`
151
+
152
+ Class R. W8-02 gave the shared Assure patterns the `/suite` entry and the
153
+ frozen and product-owned modules `/legacy`. Both are re-export barrels over the
154
+ same module instances the root exports, so moving an import is a pure path
155
+ change: no duplicated React context, no behaviour difference. The root keeps
156
+ every name through 1.39 (registry `C-ROOT-SUITE`) and drops them in 1.40, so
157
+ running this codemod early costs nothing and running it late is a 1.40 blocker.
158
+
159
+ ```tsx
160
+ import { Button, AgreementViewer, TimeLogger } from "@assure-one/design-system";
161
+ // becomes
162
+ import { Button } from "@assure-one/design-system";
163
+ import { AgreementViewer } from "@assure-one/design-system/suite";
164
+ import { TimeLogger } from "@assure-one/design-system/legacy";
165
+ ```
166
+
167
+ A declaration whose names all move keeps its shape and only its module
168
+ specifier changes. `import type`, per-specifier `type` prefixes, aliases,
169
+ quote style and a default import are preserved; the default import stays on the
170
+ root.
171
+
172
+ | rule | action | severity | meaning |
173
+ | ------------------ | ------- | -------- | --------------------------------------------------------------------------------- |
174
+ | `moved-to-suite` | applied | low | shared Assure patterns now import from `/suite` |
175
+ | `moved-to-legacy` | applied | low | frozen modules with no known consumer now import from `/legacy` |
176
+ | `product-owned` | applied | medium | the import moved to `/legacy`, but the module is leaving for a product repository |
177
+ | `namespace-import` | review | high | `import * as DS` cannot be split; import the moved members by name first |
178
+
179
+ Which entry owns which name comes from `codemods/lib/entry-map.mjs`, generated
180
+ from `architecture/entry-map.json` by `pnpm entry-map`, so an installed copy of
181
+ the codemod always carries the map of its own design-system version.
182
+
132
183
  ### CM-05 — Button family `iconLeft` / `iconRight` → `iconStart` / `iconEnd`
133
184
 
134
185
  Class A. W3-07 named the two icon slots of `Button`, `LinkButton` and
@@ -272,7 +323,7 @@ components with the same names, test files.
272
323
 
273
324
  Class R. `ProgressBar` and `ProgressRing` colour themselves **by value** when
274
325
  no colour is passed (`< 50%` brand, `≥ 50%` warning, `≥ 80%` success) — a
275
- business mapping the design system should not own, which 2.0 switches off
326
+ business mapping the design system should not own, which 1.40 switches off
276
327
  (W9-10, contract C-PROGRESS). W3-21 added `intent`; passing it disables the
277
328
  rule. CM-19 makes every call site say what it renders today, so the flip
278
329
  changes nothing a consumer did not write down: `variant="<legacy word>"`
@@ -304,7 +355,7 @@ gets `size="md"` — the value the component resolves today
304
355
  (`defaultVariants.size`, 40px), so nothing moves on screen. It exists because
305
356
  a size _meaning_ can only change once no call site depends on the default:
306
357
  after CM-02, the D5 size flip (CM-03 phase 2, W9-06) touches nothing a
307
- consumer did not write down, and 2.0 gate G6 counts exactly this.
358
+ consumer did not write down, and gate G6 counts exactly this.
308
359
 
309
360
  The attribute goes after `variant` when there is one (the order the
310
361
  applications use) and first otherwise, on its own line when the element's
@@ -323,7 +374,7 @@ scanner that measures G6 counts production files only).
323
374
  ### CM-12 — Button `type="submit"` where evident
324
375
 
325
376
  Class R. An untyped `Button` renders `<button>` without a `type`, which the
326
- browser treats as `submit`; 2.0 flips the default to `"button"` (W9-05,
377
+ browser treats as `submit`; 1.40 flips the default to `"button"` (W9-05,
327
378
  C-BTN-TYPE, gate G4). CM-12 writes down, before the flip, which Buttons submit
328
379
  on purpose — and only where the file itself makes that evident:
329
380
 
@@ -515,9 +566,9 @@ sorted). What changes in the DOM is the `data-slot` value (`table-*` instead of
515
566
  column header already. Classes and pixels are the same, because since W6-03 the
516
567
  `DataTable*` parts render the `Table*` parts.
517
568
 
518
- | rule | Contract | What happens |
519
- | --------------- | ---------- | ------------------------------------------------------------------- |
520
- | `part-renamed` | C-DT-PARTS | tag, closing tag and the named import rewritten (applied, low) |
569
+ | rule | Contract | What happens |
570
+ | -------------- | ---------- | -------------------------------------------------------------- |
571
+ | `part-renamed` | C-DT-PARTS | tag, closing tag and the named import rewritten (applied, low) |
521
572
 
522
573
  Reported under "could not be transformed": `DataTableHeader sortable` with no
523
574
  controlled `sort`, or with `defaultSort` (`uncontrolled-sort` — `TableHead` has
@@ -564,8 +615,8 @@ yet — those are the candidates for new registry entries. `confidence` is `high
564
615
  for a token on the component itself, `medium` for a wrapper or a heuristic,
565
616
  `low` for an unmapped wrapper.
566
617
 
567
- CM-15 feeds 2.0 gate G7 (`consumerSelectors = 0` for the freezes with removal
568
- target 2.0). Use `--fail-on-findings` to gate on it. The committed findings for
618
+ CM-15 feeds gate G7 (`consumerSelectors = 0` for the freezes with registry
619
+ removal target 2.0, which 1.40 lifts). Use `--fail-on-findings` to gate on it. The committed findings for
569
620
  the four consumer apps are in `docs/codemods/`.
570
621
 
571
622
  ### CM-16 — `globals.css` analyser
@@ -0,0 +1,315 @@
1
+ /**
2
+ * GENERATED by scripts/architecture/entry-map.mjs from architecture/entry-map.json
3
+ * — do not edit. `pnpm entry-map` rewrites it; `pnpm entry-map:check` fails
4
+ * when it is stale.
5
+ *
6
+ * The half of the entry map CM-01 needs, published inside the package so a
7
+ * consumer runs the codemod that matches its design-system version (W8-01/02).
8
+ */
9
+ export const ENTRY_SPECIFIER = {
10
+ suite: "@assure-one/design-system/suite",
11
+ legacy: "@assure-one/design-system/legacy",
12
+ };
13
+
14
+ /** Public root export → the entry that owns it. Root-owned names are absent. */
15
+ export const ENTRY_BY_SYMBOL = {
16
+ AgreementFirm: "suite",
17
+ AgreementPaneHeading: "suite",
18
+ AgreementPaneHeadingProps: "suite",
19
+ AgreementStatus: "suite",
20
+ AgreementStep: "suite",
21
+ AgreementViewer: "suite",
22
+ AgreementViewerProps: "suite",
23
+ ProposalAddOn: "suite",
24
+ ProposalAddOnProps: "suite",
25
+ ProposalBillingMode: "suite",
26
+ ProposalBillingRow: "suite",
27
+ ProposalBillingTerms: "suite",
28
+ ProposalBillingTermsProps: "suite",
29
+ ProposalConsentGate: "suite",
30
+ ProposalConsentGateProps: "suite",
31
+ ProposalCustomPage: "suite",
32
+ ProposalCustomPageKind: "suite",
33
+ ProposalCustomPageProps: "suite",
34
+ ProposalNote: "suite",
35
+ ProposalNoteProps: "suite",
36
+ ProposalPackageCard: "suite",
37
+ ProposalPackageCardProps: "suite",
38
+ ProposalPackageMode: "suite",
39
+ ProposalPaymentCapture: "suite",
40
+ ProposalPaymentCaptureProps: "suite",
41
+ ProposalPricingSummary: "suite",
42
+ ProposalPricingSummaryProps: "suite",
43
+ ProposalServiceRow: "suite",
44
+ ProposalServiceRowProps: "suite",
45
+ ProposalSignatureBlock: "suite",
46
+ ProposalSignatureBlockProps: "suite",
47
+ ProposalSigner: "suite",
48
+ ProposalSignerList: "suite",
49
+ ProposalSignerListProps: "suite",
50
+ ProposalSignerStatus: "suite",
51
+ Grid: "suite",
52
+ GridColumn: "suite",
53
+ GridInputType: "suite",
54
+ GridProps: "suite",
55
+ GridRow: "suite",
56
+ GridValue: "suite",
57
+ QUESTION_TYPES: "suite",
58
+ QUESTION_TYPE_CONTRACT_VERSION: "suite",
59
+ QuestionAddressValue: "suite",
60
+ QuestionFileValue: "suite",
61
+ QuestionHelp: "suite",
62
+ QuestionLabeledColumn: "suite",
63
+ QuestionLabeledRow: "suite",
64
+ QuestionLabeledValue: "suite",
65
+ QuestionNameValue: "suite",
66
+ QuestionOption: "suite",
67
+ QuestionTableColumn: "suite",
68
+ QuestionTableRow: "suite",
69
+ QuestionType: "suite",
70
+ Questions: "suite",
71
+ QuestionsProps: "suite",
72
+ DocumentDetailActions: "suite",
73
+ DocumentDetailActionsProps: "suite",
74
+ DocumentDetailBody: "suite",
75
+ DocumentDetailBodyProps: "suite",
76
+ DocumentDetailHeader: "suite",
77
+ DocumentDetailHeaderProps: "suite",
78
+ DocumentDetailMetaRow: "suite",
79
+ DocumentDetailMetaRowProps: "suite",
80
+ DocumentDetailPanel: "suite",
81
+ DocumentDetailPanelProps: "suite",
82
+ DocumentDetailRequester: "suite",
83
+ DocumentDetailRequesterProps: "suite",
84
+ DocumentDetailTitle: "suite",
85
+ DocumentDetailTitleProps: "suite",
86
+ DocumentList: "suite",
87
+ DocumentListProps: "suite",
88
+ DocumentListSection: "suite",
89
+ DocumentListSectionProps: "suite",
90
+ DocumentRow: "suite",
91
+ DocumentRowProps: "suite",
92
+ ClientSelect: "suite",
93
+ ClientSelectOption: "suite",
94
+ AssureAuditBrandIcon: "suite",
95
+ AssureBooksBrandIcon: "suite",
96
+ AssureProBrandIcon: "suite",
97
+ AssureTaxBrandIcon: "suite",
98
+ BRAND_PRODUCTS: "suite",
99
+ BrandIconProps: "suite",
100
+ BrandProduct: "suite",
101
+ Logo: "suite",
102
+ SidebarBrandSwitcher: "suite",
103
+ SidebarBrandSwitcherExtra: "suite",
104
+ SidebarBrandSwitcherItem: "suite",
105
+ SidebarBrandSwitcherProps: "suite",
106
+ SidebarBrandSwitcherTile: "suite",
107
+ brandLabel: "suite",
108
+ ComingSoon: "suite",
109
+ ComingSoonProps: "suite",
110
+ TimeLogger: "legacy",
111
+ TimeLoggerActions: "legacy",
112
+ TimeLoggerActionsProps: "legacy",
113
+ TimeLoggerBillable: "legacy",
114
+ TimeLoggerBillableProps: "legacy",
115
+ TimeLoggerContextRow: "legacy",
116
+ TimeLoggerContextRowProps: "legacy",
117
+ TimeLoggerEntry: "legacy",
118
+ TimeLoggerEntryList: "legacy",
119
+ TimeLoggerEntryListProps: "legacy",
120
+ TimeLoggerEntryProps: "legacy",
121
+ TimeLoggerField: "legacy",
122
+ TimeLoggerFieldProps: "legacy",
123
+ TimeLoggerFooter: "legacy",
124
+ TimeLoggerFooterProps: "legacy",
125
+ TimeLoggerHeader: "legacy",
126
+ TimeLoggerHeaderProps: "legacy",
127
+ TimeLoggerNotes: "legacy",
128
+ TimeLoggerNotesProps: "legacy",
129
+ TimeLoggerPhase: "legacy",
130
+ TimeLoggerProps: "legacy",
131
+ TimeLoggerTier: "legacy",
132
+ TimeLoggerTimer: "legacy",
133
+ TimeLoggerTimerProps: "legacy",
134
+ UseStopwatchReturn: "legacy",
135
+ formatClock: "legacy",
136
+ formatCurrency: "legacy",
137
+ formatDuration: "legacy",
138
+ parseDuration: "legacy",
139
+ useStopwatch: "legacy",
140
+ ClientRailGroupHeader: "legacy",
141
+ ClientRailGroupHeaderProps: "legacy",
142
+ ClientRailItem: "legacy",
143
+ ClientRailItemProps: "legacy",
144
+ DocumentFileCard: "legacy",
145
+ DocumentFileCardProps: "legacy",
146
+ DocumentFileLine: "legacy",
147
+ DocumentFileLineProps: "legacy",
148
+ DocumentFileRow: "legacy",
149
+ DocumentFileRowProps: "legacy",
150
+ DocumentRequestActivityKind: "legacy",
151
+ DocumentRequestAssigneeOption: "legacy",
152
+ DocumentRequestCard: "legacy",
153
+ DocumentRequestCardProps: "legacy",
154
+ DocumentRequestDetail: "legacy",
155
+ DocumentRequestDetailActivityEvent: "legacy",
156
+ DocumentRequestDetailComment: "legacy",
157
+ DocumentRequestDetailDoc: "legacy",
158
+ DocumentRequestDetailProps: "legacy",
159
+ DocumentRequestDetailTab: "legacy",
160
+ DocumentRequestItemSummary: "legacy",
161
+ DocumentRequestRequestedItem: "legacy",
162
+ DocumentRequestReviewStatusOption: "legacy",
163
+ DocumentRequestTone: "legacy",
164
+ Blockquote: "legacy",
165
+ Section: "legacy",
166
+ SectionHead: "legacy",
167
+ SectionHeader: "legacy",
168
+ Stat: "legacy",
169
+ PillStatus: "legacy",
170
+ StatusPill: "legacy",
171
+ StatusPillProps: "legacy",
172
+ Assignee: "legacy",
173
+ Dash: "legacy",
174
+ MoneyCell: "legacy",
175
+ StagePill: "legacy",
176
+ TagsCell: "legacy",
177
+ AIReceiptPanel: "legacy",
178
+ AIReceiptPanelProps: "legacy",
179
+ AIReceiptResult: "legacy",
180
+ AiDraftCard: "legacy",
181
+ AiDraftCardProps: "legacy",
182
+ AiDraftState: "legacy",
183
+ AttentionItem: "legacy",
184
+ AttentionItemProps: "legacy",
185
+ AttentionUrgency: "legacy",
186
+ BottomNav: "legacy",
187
+ BottomNavProps: "legacy",
188
+ BottomNavTab: "legacy",
189
+ CategoryDivider: "legacy",
190
+ CategoryDividerProps: "legacy",
191
+ CategoryTag: "legacy",
192
+ CategoryTagProps: "legacy",
193
+ CategoryTone: "legacy",
194
+ ChannelTabItem: "legacy",
195
+ ChannelTabs: "legacy",
196
+ ChannelTabsProps: "legacy",
197
+ ChannelTone: "legacy",
198
+ DashGrid: "legacy",
199
+ DashGridProps: "legacy",
200
+ DashWidget: "legacy",
201
+ DocumentChecklist: "legacy",
202
+ DocumentChecklistFile: "legacy",
203
+ DocumentChecklistItem: "legacy",
204
+ DocumentChecklistProps: "legacy",
205
+ DocumentChecklistStatus: "legacy",
206
+ DocumentItemState: "legacy",
207
+ DocumentRequestField: "legacy",
208
+ DocumentRequestFieldProps: "legacy",
209
+ DocumentRequestUpload: "legacy",
210
+ DocumentRequestUploadFile: "legacy",
211
+ DocumentRequestUploadProps: "legacy",
212
+ DocumentSource: "legacy",
213
+ DocumentSourceFilter: "legacy",
214
+ DocumentSourceFilterProps: "legacy",
215
+ DocumentSourceFilterValue: "legacy",
216
+ DocumentSourceTag: "legacy",
217
+ DocumentSourceTagProps: "legacy",
218
+ DocumentsWorkspaceLayout: "legacy",
219
+ DocumentsWorkspaceLayoutProps: "legacy",
220
+ EmailMessageCard: "legacy",
221
+ EmailMessageCardProps: "legacy",
222
+ EngagementCard: "legacy",
223
+ EngagementCardProps: "legacy",
224
+ EngagementTimeline: "legacy",
225
+ EngagementTimelineProps: "legacy",
226
+ EngagementTimelineStep: "legacy",
227
+ EngagementTimelineStepProps: "legacy",
228
+ IntentBadge: "legacy",
229
+ IntentBadgeProps: "legacy",
230
+ IntentTone: "legacy",
231
+ MissingDocumentItem: "legacy",
232
+ MissingDocumentsPanel: "legacy",
233
+ MissingDocumentsPanelProps: "legacy",
234
+ NewMenu: "legacy",
235
+ NewMenuAction: "legacy",
236
+ NewMenuGroup: "legacy",
237
+ NewMenuProps: "legacy",
238
+ SignatureEditor: "legacy",
239
+ SignatureEditorProps: "legacy",
240
+ SuggestionPills: "legacy",
241
+ SuggestionPillsProps: "legacy",
242
+ TeamMemberSelect: "legacy",
243
+ TimelineState: "legacy",
244
+ };
245
+
246
+ /** Product-owned names → the repository they are moving to (reported, never written). */
247
+ export const PRODUCT_TARGET = {
248
+ TimeLogger: "assure-pro/frontend/src/components/billing/time-logger/*",
249
+ TimeLoggerActions: "assure-pro/frontend/src/components/billing/time-logger/*",
250
+ TimeLoggerActionsProps: "assure-pro/frontend/src/components/billing/time-logger/*",
251
+ TimeLoggerBillable: "assure-pro/frontend/src/components/billing/time-logger/*",
252
+ TimeLoggerBillableProps: "assure-pro/frontend/src/components/billing/time-logger/*",
253
+ TimeLoggerContextRow: "assure-pro/frontend/src/components/billing/time-logger/*",
254
+ TimeLoggerContextRowProps: "assure-pro/frontend/src/components/billing/time-logger/*",
255
+ TimeLoggerEntry: "assure-pro/frontend/src/components/billing/time-logger/*",
256
+ TimeLoggerEntryList: "assure-pro/frontend/src/components/billing/time-logger/*",
257
+ TimeLoggerEntryListProps: "assure-pro/frontend/src/components/billing/time-logger/*",
258
+ TimeLoggerEntryProps: "assure-pro/frontend/src/components/billing/time-logger/*",
259
+ TimeLoggerField: "assure-pro/frontend/src/components/billing/time-logger/*",
260
+ TimeLoggerFieldProps: "assure-pro/frontend/src/components/billing/time-logger/*",
261
+ TimeLoggerFooter: "assure-pro/frontend/src/components/billing/time-logger/*",
262
+ TimeLoggerFooterProps: "assure-pro/frontend/src/components/billing/time-logger/*",
263
+ TimeLoggerHeader: "assure-pro/frontend/src/components/billing/time-logger/*",
264
+ TimeLoggerHeaderProps: "assure-pro/frontend/src/components/billing/time-logger/*",
265
+ TimeLoggerNotes: "assure-pro/frontend/src/components/billing/time-logger/*",
266
+ TimeLoggerNotesProps: "assure-pro/frontend/src/components/billing/time-logger/*",
267
+ TimeLoggerPhase: "assure-pro/frontend/src/components/billing/time-logger/*",
268
+ TimeLoggerProps: "assure-pro/frontend/src/components/billing/time-logger/*",
269
+ TimeLoggerTier: "assure-pro/frontend/src/components/billing/time-logger/*",
270
+ TimeLoggerTimer: "assure-pro/frontend/src/components/billing/time-logger/*",
271
+ TimeLoggerTimerProps: "assure-pro/frontend/src/components/billing/time-logger/*",
272
+ UseStopwatchReturn: "assure-pro/frontend/src/components/billing/time-logger/*",
273
+ formatClock: "assure-pro/frontend/src/components/billing/time-logger/*",
274
+ formatCurrency: "assure-pro/frontend/src/components/billing/time-logger/*",
275
+ formatDuration: "assure-pro/frontend/src/components/billing/time-logger/*",
276
+ parseDuration: "assure-pro/frontend/src/components/billing/time-logger/*",
277
+ useStopwatch: "assure-pro/frontend/src/components/billing/time-logger/*",
278
+ ClientRailGroupHeader: "assure-pro (documents feature)",
279
+ ClientRailGroupHeaderProps: "assure-pro (documents feature)",
280
+ ClientRailItem: "assure-pro (documents feature)",
281
+ ClientRailItemProps: "assure-pro (documents feature)",
282
+ DocumentFileCard: "assure-pro (documents feature)",
283
+ DocumentFileCardProps: "assure-pro (documents feature)",
284
+ DocumentFileLine: "assure-pro (documents feature)",
285
+ DocumentFileLineProps: "assure-pro (documents feature)",
286
+ DocumentFileRow: "assure-pro (documents feature)",
287
+ DocumentFileRowProps: "assure-pro (documents feature)",
288
+ DocumentRequestActivityKind: "assure-pro (documents feature)",
289
+ DocumentRequestAssigneeOption: "assure-pro (documents feature)",
290
+ DocumentRequestCard: "assure-pro (documents feature)",
291
+ DocumentRequestCardProps: "assure-pro (documents feature)",
292
+ DocumentRequestDetail: "assure-pro (documents feature)",
293
+ DocumentRequestDetailActivityEvent: "assure-pro (documents feature)",
294
+ DocumentRequestDetailComment: "assure-pro (documents feature)",
295
+ DocumentRequestDetailDoc: "assure-pro (documents feature)",
296
+ DocumentRequestDetailProps: "assure-pro (documents feature)",
297
+ DocumentRequestDetailTab: "assure-pro (documents feature)",
298
+ DocumentRequestItemSummary: "assure-pro (documents feature)",
299
+ DocumentRequestRequestedItem: "assure-pro (documents feature)",
300
+ DocumentRequestReviewStatusOption: "assure-pro (documents feature)",
301
+ DocumentRequestTone: "assure-pro (documents feature)",
302
+ Blockquote: "assure-pro (landing pages)",
303
+ Section: "assure-pro (landing pages)",
304
+ SectionHead: "assure-pro (landing pages)",
305
+ SectionHeader: "assure-pro (landing pages)",
306
+ Stat: "assure-pro (landing pages)",
307
+ PillStatus: "assure-pro status map over core `StatusBadge`",
308
+ StatusPill: "assure-pro status map over core `StatusBadge`",
309
+ StatusPillProps: "assure-pro status map over core `StatusBadge`",
310
+ Assignee: "assure-tax `table-cells.tsx`",
311
+ Dash: "assure-tax `table-cells.tsx`",
312
+ MoneyCell: "assure-tax `table-cells.tsx`",
313
+ StagePill: "assure-tax `table-cells.tsx`",
314
+ TagsCell: "assure-tax `table-cells.tsx`",
315
+ };