@dloizides/ui-tables 1.21.1 → 1.23.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.
package/CHANGELOG.md CHANGED
@@ -1,528 +1,547 @@
1
- # Changelog
2
-
3
- ## 1.21.0
4
-
5
- **New `StatusLedger` (JOBS-UX-1 "Jobs page: one clear, consistent view of every job and source").**
6
-
7
- A status-first ledger built on `DataTable` + `Filters`: one sortable, filterable table at or above
8
- the breakpoint (768 by default, from `useWindowDimensions`), and a "needs a look first" feed below
9
- it (bad then warn rows on top, then the rest). Filters: free text, status, group; sort by any column
10
- with a `sortValue`, plus a 44px direction toggle. Generic row shape through accessors; every string
11
- via `labels`/`statusLabel`; tone colours from the theme (`toneColors` overrides). Also exports
12
- `StatusPill`, `RelativeTime` (tap swaps to absolute), `formatRelativeTime` and the pure
13
- `filterLedgerRows` / `sortLedgerRows` / `splitNeedsLook` helpers. Additive, nothing existing changes.
14
-
15
- ## 1.20.0
16
-
17
- **The rows-per-page menu opens above an RN-web Modal (UI-ZINDEX-SCALE-1 "Shared overlay z-index scale").**
18
-
19
- react-native-web mounts `Modal` in a body-level layer at zIndex 9999. On web the `SizeDropdown`
20
- menu portals to the body, and at zIndex 1000 it painted under an open Modal, so clicks fell through
21
- to the dialog. The menu now uses `Z_INDEX.popover` (10000, below toasts) and the sticky header uses
22
- `Z_INDEX.sticky` (2, unchanged), both from `@dloizides/design-tokens` ^1.13.0, which is now a dependency.
23
-
24
- ## 1.19.2
25
-
26
- **The pager shrinks and wraps beside a title (TABLES-MOBILE-1 "Filter bar and pager overflow at 360").**
27
-
28
- Visual QA of aml-v2 `/app/cases` at 360 measured the pager, placed beside the "Cases" title in a
29
- wrapping row, at 328px inside a 255px slot: `flex-shrink: 0`, no width cap, so Next ran to x=373
30
- and an `overflow: hidden` ancestor clipped it. `pager` and `pagerNav` now carry `flexShrink: 1`,
31
- `minWidth: 0` and `maxWidth: '100%'`, so they fit their line and their existing `flexWrap` breaks
32
- the count / Rows / Prev / Next onto further lines. Desktop is unchanged where the row fits.
33
-
34
- ## 1.19.1
35
-
36
- **The `Filters` / `FilterBar` actions cluster wraps (TABLES-MOBILE-1 "Filter bar and pager overflow at 360").**
37
-
38
- Visual QA of aml-v2 `/app/leaders` at 360 measured the actions row (Reset, Export CSV/PDF, Apply)
39
- at 431px inside a 255px bar: a nowrap row is one unbreakable flex item, so Apply rendered at x=373,
40
- off-screen. `filtersActions` now has `flexWrap: 'wrap'`, `flexShrink: 1` and `maxWidth: '100%'`,
41
- so the cluster fits its line and its buttons break onto further lines. Desktop is unchanged: where
42
- the row fits, nothing wraps. The 44px Apply / pager hit boxes shipped in 1.19.0.
43
-
44
- ## 1.19.0
45
-
46
- **Every pressable renders a 44x44 hit box (SHOWCASE-1 "Publish the UI showcase at ui.dloizides.com").**
47
-
48
- Live QA on ui.dloizides.com/tables at 360x640 measured switches at 40x20, page-size buttons at
49
- 32-39x30 and pager buttons 31px tall. `hitSlop` is inert on react-native-web, so the rendered box
50
- is the target. Pager buttons, page-size pills, the dropdown trigger and its options, filter action
51
- buttons, the select checkbox (gutter now 44px wide) and the select-all banner action now carry
52
- `minHeight`/`minWidth` of `MIN_TARGET_PX` (44). The filter `Switch` keeps its 40x20 track inside a
53
- 44x44 `Pressable` (`-switch-hit` test id); the inner Switch keeps focus and the switch role.
54
- The inert `hitSlop` props were removed.
55
-
56
- ## 1.18.0
57
-
58
- **`DataTable` rows now fade in on load — the Ant-design-like list entrance — via `@dloizides/ui-motion`.**
59
-
60
- When a `DataTable` mounts its rows (first load, and whenever the row set changes — sort / filter /
61
- page), each row now fades in with a small upward translate, staggered across the first few rows. It
62
- is a subtle polish layer, gated hard so it never becomes jank on a large page, and **entirely
63
- opt-outable** — omit nothing and the table behaves exactly as before minus the fade.
64
-
65
- ### What changed
66
-
67
- | Area | Detail |
68
- |---|---|
69
- | **New optional prop** | `animateRows?: boolean` (default **`true`**). Each row (and its expanded detail panel, if any) is wrapped in `@dloizides/ui-motion`'s `<FadeIn>`, keyed by the row key. |
70
- | **Capped stagger** | Only the first `ROW_ENTRANCE_STAGGER_CAP` (10) rows stagger, `ROW_ENTRANCE_STAGGER_STEP_MS` (30 ms) apart; every row past the cap shares the capped delay. A 100- or 5,000-row page settles in a fixed ~300 ms, **never** row-by-row. |
71
- | **Reduced-motion** | Honoured: rows render instantly, with **no wrapper node and no delay** (`FadeIn` gates too, but the wrapper is skipped entirely so the reduced-motion DOM is identical to the un-animated table). |
72
- | **No re-fade on re-render** | Each row's `<FadeIn>` is keyed by its row key, so React keeps its identity across unrelated re-renders (hover, a re-fetch that resolves to the SAME keys) — the entrance plays once per key, not on every render. A genuine row-set change (new keys) re-fades, as intended. |
73
- | **New test id** | `rowFadeTestID(tableTestID, key)` → `${tableTestID}-fade-${key}` (present only while animating), exported alongside the other row test-id helpers. |
74
-
75
- ### Backward compatibility
76
-
77
- - **MINOR, additive.** The public API gains one optional prop and one test-id helper; nothing is
78
- renamed or removed.
79
- - All existing behaviour is preserved: zebra, sticky header, mobile card-stack, row/per-cell/head/
80
- detail-panel/select-checkbox test ids, `onRowPress`, bulk-select, keyboard navigation, the pager,
81
- and the refetch-does-not-blank-the-grid guard.
82
- - Pass `animateRows={false}` (or run under `prefers-reduced-motion`) and rows render with no
83
- wrapper node — DOM identical to before this release.
84
- - New peer of the kit: `@dloizides/ui-motion` (`^1.0.1`) is added as a dependency.
85
-
86
- ## 1.16.0
87
-
88
- **The responsive card-stack now reads as a proper mobile layout — and keeps every E2E hook.**
89
-
90
- `DataTable` has always collapsed to a label:value card-stack below a breakpoint (`stackBreakpoint`),
91
- but on a phone the multi-column tables it powers (e.g. the organizer Passes table) were still hard
92
- to read, and the card-stack silently dropped test hooks a wide-viewport E2E suite relies on. This
93
- release makes the card-stack the readable, self-explanatory mobile layout it was meant to be —
94
- **with no change to the desktop grid and no broken selectors.**
95
-
96
- ### What changed
97
-
98
- | Area | Before | Now |
99
- |---|---|---|
100
- | **Default breakpoint** | `640` | `768` — the kit-wide narrow-viewport threshold, aligned with `@dloizides/ui-layout`'s `MENU_BREAKPOINT` (already the collapse point for the nav menu and tabs). `CARD_STACK_BREAKPOINT` is re-exported at the new value. |
101
- | **Card line layout** | label LEFT, value RIGHT on one `space-between` row (cramped for long values / action buttons) | each column's header sits **ABOVE** its value, both left-aligned, so the value gets the full card width |
102
- | **Per-cell test id `${row}-${colKey}`** | resolved **only** on the desktop grid | resolves in **BOTH** layouts (the card line carries the same id the desktop cell does) |
103
- | **Head test id `ui-data-table-head`** | **absent** in card-stack mode | resolves in **BOTH** layouts via a hidden, a11y-inert carrier (`display: none`, `aria-hidden`) — E2E selectors survive at every width |
104
-
105
- ### Backward compatibility
106
-
107
- - **The desktop grid is byte-for-byte unchanged.** Opt out of the card-stack entirely, at every
108
- width, with `stackBreakpoint={0}` (unchanged).
109
- - A column's `render` node (badge, link, **action button**) renders identically in a card cell.
110
- - Row / per-cell / head / detail-panel / select-checkbox test ids are all preserved; the only
111
- net-new guarantee is that per-cell and head ids now ALSO resolve in the card-stack.
112
- - The one observable difference for an existing consumer is cosmetic: tables between 640px and
113
- 768px wide now show the card-stack (they showed the cramped desktop row before), and cards read
114
- vertically rather than as a `space-between` row. Both are strict readability improvements — which
115
- is what keeps this a MINOR bump.
116
-
117
- All 272 tests pass (6 added for the both-layouts test-hook contract + the vertical card layout).
118
-
119
- ## 1.15.0
120
-
121
- **A re-fetch no longer blanks the grid — the server-paged paging defect.**
122
-
123
- `DataTable` returned its full-bleed loading state whenever `loading` was true, unconditionally.
124
- On a server-paged grid that is not a cosmetic flicker, it is the paging bug: clicking **Next**
125
- replaced the table with "Loading…", so the grid visibly EMPTIED and only refilled once the next
126
- page arrived. To anyone watching — and to any assertion that samples the rows after the click —
127
- the grid appeared to page to nothing. The same applied to re-filtering and to any `reload()`.
128
-
129
- Evidence this was real and not theoretical: against the live AML v2 cases console, the API
130
- returned a correct, non-overlapping page at `skip=50`, yet the UI rendered **zero** rows after
131
- Next. The rows were being discarded by this component, not by the query.
132
-
133
- ### The rule now
134
-
135
- The state view is reserved for when there is genuinely nothing to show:
136
-
137
- | `loading` | `rows.length` | Renders |
138
- |---|---|---|
139
- | true | 0 | loading state (first load) |
140
- | false | 0 | empty state |
141
- | true | > 0 | **the existing rows** (stale for a moment), `aria-busy="true"` |
142
- | false | > 0 | the rows |
143
-
144
- Rows that already exist stay on screen and swap when the new page resolves. Because the content
145
- no longer vanishes, the in-flight fetch is announced explicitly via `aria-busy` on the table
146
- container rather than being implied by the table's destruction.
147
-
148
- **Behaviour is unchanged for every first load and every empty result**, which is what keeps this a
149
- MINOR bump. The only consumers that see a difference are those that were already passing `loading`
150
- alongside non-empty `rows` — i.e. exactly the ones that were silently blanking.
151
-
152
- All 266 pre-existing tests pass unmodified; 3 added for the retained-rows / busy / swap contract.
153
-
154
- ## 1.14.0
155
-
156
- **Campaign F2 — the private filter fields are now public, in `@dloizides/ui-forms`.**
157
-
158
- This package contained a complete, themed, a11y-wired set of form controls inside its `Filters`
159
- bar and exported NONE of them. Six portals could see them working and none could import them, so
160
- the fleet reimplemented them: **6 select implementations, 5 date fields, 2 typeaheads**. Same
161
- shape as `MultiTenancy.EntityFrameworkCore` shipping no EF Core. They now live in
162
- `@dloizides/ui-forms` 1.8.0 as `SelectControl` / `TypeaheadControl` / `DateRangeControl` /
163
- `AnchoredMenu` / `controlStyles`, and this package consumes them.
164
-
165
- **No behaviour changed. All 258 pre-existing tests pass UNMODIFIED** — including
166
- `Filters.test.tsx` (which drives every field kind through the bar), `selectAccessibleName.test.tsx`
167
- (the i18n path) and `suggest.test.ts` (now running against the moved implementation). That is the
168
- proof the move preserved behaviour rather than merely relocating it.
169
-
170
- ### What moved, and what deliberately did not
171
-
172
- The controls moved; the **schema** stayed. Each field was bound to this bar's `FilterField` types
173
- (`field: SelectFilterField`, `barTestID`, `fieldTestID`), so moving them verbatim would have
174
- dragged `FilterField`, `FilterFieldKind`, `FilterValues` and `FIELD_MIN_WIDTH` into `ui-forms` —
175
- i.e. `ui-forms` would have come to own "what a filter bar's field schema is". Wrong direction.
176
- The field files are now thin ADAPTERS mapping schema → plain props.
177
-
178
- `TextField` and `BooleanField` stayed. `ui-forms` already ships two text inputs (`ThemedTextInput`,
179
- `FormField`) and a switch row (`FormSwitch`); promoting a third of each would ADD duplicates to the
180
- package this campaign is de-duplicating. Converging onto the existing ones is right but VISIBLE
181
- (focus ring, hover border, `surfaceElevated` background, different switch-row metrics), so it
182
- belongs in the visual-QA-gated wave. Both now use the shared `controlStyles` boxes, so no metric
183
- is forked in the meantime.
184
-
185
- ### `FieldShell` is deleted
186
-
187
- The private label-wrapper fork existed only because `Field` hard-coded the 13/600 `field` label
188
- voice. `Field` 1.7.0 named both contract voices, so the bar now asks for `labelVariant="control"`
189
- — the 11/700/uppercase metrics `FieldShell` carried, verbatim. This ends the label-metric split
190
- between `Field` and `FieldShell` that caused several defects this campaign.
191
-
192
- The swap replaces the label implementation under six live portals, so it is guarded by a dedicated
193
- test (`fieldShellRetirement.test.tsx`) asserting the voice, the absence of `Field`'s 16px form
194
- rhythm, the per-kind reflow rules and the caller-override precedence. Removing `labelVariant`
195
- fails two of its five assertions — verified, not assumed.
196
-
197
- ### i18n manifests are untouched
198
-
199
- `FILTERS_I18N` and `TABLE_I18N` are unchanged, and every portal guard that binds to them keeps
200
- working. `ui-forms` never calls `t`, so the one field that resolved an i18n key —
201
- `SelectField`'s `FILTERS_I18N.selectTriggerLabel` accessible name — composes that string HERE, in
202
- the adapter, and passes the finished value down as `accessibilityLabel`. The i18n stayed with the
203
- package that owns the keys.
204
-
205
- ### Notes
206
-
207
- - New peer dependency: `@dloizides/ui-forms >= 1.8.0`, plus `@dloizides/ui-buttons >= 1.4.0`
208
- inherited through it (`ui-forms` bundles `FormActions`). All five portals consuming `ui-tables`
209
- already declare `ui-buttons ^1.4.0`, so this is a declaration of existing reality, not a new
210
- requirement.
211
- - `FilterOption` and `DateRangeValue` are now ALIASES of `ui-forms`' `ControlOption` /
212
- `DateRangeValue`. Public names unchanged; one definition instead of two structurally-identical
213
- twins free to drift.
214
- - `DEFAULT_TYPEAHEAD_MIN_CHARS` / `DEFAULT_TYPEAHEAD_MAX_SUGGESTIONS` and `suggestOptions` /
215
- `isUnmatched` are re-exported from `ui-forms`. Public API unchanged.
216
- - Inherits the `AnchoredMenu` WCAG fix from `ui-forms` 1.8.0: the selected option now carries
217
- `aria-selected`. `accessibilityState` is native-only and react-native-web ignores it, so on web
218
- the current option had been conveyed by colour and font-weight alone (WCAG 1.4.1).
219
- - `AnchoredMenu` remains one of three near-identical anchored-menu implementations, with
220
- `ui-layout`'s `InlineMenu` and this package's `SizeDropdown`. Collapsing them was out of scope.
221
- The move makes it EASIER: two of the three now sit in packages that may depend on `ui-forms`, so
222
- a future collapse has an obvious home rather than needing a new shared package first.
223
-
224
- ## 1.13.0
225
-
226
- De-fork wave W1.1: pagination logic promoted from the byte-identical `PaginatedList`
227
- twins in erevna-web and katalogos-web.
228
-
229
- ### Added
230
-
231
- - `usePagedRows(rows, { pageSize })` — client-side pagination state for an already
232
- in-memory array. Returns `pageRows`, `currentPage`, `totalPages`, `setPage`,
233
- `hasPages`, `pageSize`. No new translation keys; no action required.
234
-
235
- Promoted as a **hook, not a component**, deliberately: the app-side `PaginatedList`
236
- hard-bound a `FlatList` plus app-specific empty and loading states. Only the paging
237
- maths is genuinely shared, so only that moved — callers keep their own list renderer.
238
- For server-side paging keep using `DataTable`'s pager.
239
-
240
- ### Fixed (behaviour differs from the app-side original)
241
-
242
- - The original only clamped the page index when `totalPages > 0`, so emptying the list
243
- left a stale non-zero page behind and the next non-empty render started on the wrong
244
- page. `usePagedRows` clamps to 0 in that case.
245
- - A `pageSize` of 0 divided by zero (`Math.ceil(n / 0)` → `Infinity` pages). Now floored
246
- to 1.
247
- - `setPage` clamps out-of-range input; the original trusted the caller.
248
-
249
- ## 1.12.0
250
-
251
- Accessibility fix: controls that announced a **bare number** now say what they are. Confirmed in
252
- a real browser, the rows-per-page trigger rendered `aria-label="50"` — a screen-reader user heard
253
- the value and nothing about the control. Fixed across the whole package, plus two more instances
254
- of the same defect class found while auditing.
255
-
256
- ### ⚠️ ACTION REQUIRED — add three translation keys
257
-
258
- The new accessible names are user-facing strings, so they come from the host app's locale files.
259
- **Every consuming app must add these three keys:**
260
-
261
- | Key | Params | Suggested English |
262
- |---|---|---|
263
- | `uiTables.pager.rowsTriggerLabel` | `{{p1}}` = current page size | `Rows per page, currently {{p1}}` |
264
- | `uiTables.pager.rowsOptionLabel` | `{{p1}}` = that option's size | `Show {{p1}} rows per page` |
265
- | `uiTables.filters.selectTriggerLabel` | `{{p1}}` = field label, `{{p2}}` = selection | `{{p1}}: {{p2}}` |
266
-
267
- They are exported as `TABLE_I18N.pagerRowsTriggerLabel`, `TABLE_I18N.pagerRowsOptionLabel` and
268
- `FILTERS_I18N.selectTriggerLabel`, so an app that derives its required-key list from those maps
269
- (as zygos' guard test does) picks them up automatically.
270
-
271
- **Upgrading without adding them is safe.** Unlike the usual kit contract — where an undefined key
272
- renders as its literal dotted name, the failure that put 44 raw keys on screen in zygos — a
273
- newly-introduced ACCESSIBLE-NAME key degrades to the value it replaced (the bare number, the field
274
- label). An aria-label is invisible to sighted reviewers, so a raw key there would ship silently and
275
- hurt only screen-reader users. Until you add the keys you simply keep the old, worse names.
276
-
277
- ### Fixed
278
-
279
- - **`Pager` rows-per-page trigger** (`dropdown` variant) — was `aria-label="50"`, now
280
- "Rows per page, currently 50".
281
- - **`Pager` rows-per-page options** (`dropdown` variant) — was `aria-label="100"`, now
282
- "Show 100 rows per page".
283
- - **`Pager` rows-per-page pills** (the **DEFAULT** `pills` variant) — carried the identical
284
- bare-number defect and was NOT in the original report, so it affected more consumers than the
285
- dropdown did. Same fix, same key.
286
- - **`Filters` select trigger** — `accessibilityLabel` replaces the trigger's visible text for a
287
- screen reader, so labelling it `field.label` alone silently hid the current selection: sighted
288
- users saw "Closed", screen-reader users heard only "Status". Now "Status: Closed".
289
- - **`StatCard`** — its two translation keys were string literals inlined in the component rather
290
- than members of an exported map, so an app deriving its required-key list from `TABLE_I18N`
291
- could not see them and would render them raw. Now exported as `TABLE_I18N.statCardLabel` /
292
- `TABLE_I18N.statHint`. **The key strings are unchanged** (`analytics.statCardLabel`,
293
- `analytics.statHint`) — renaming them would have broken every app that already defines them.
294
-
295
- ### Added
296
-
297
- - **`accessibleName(translated, key, fallback)`** — the internal degradation guard described
298
- above. Not exported; the kit's fallback-free i18n contract is unchanged for visible copy.
299
-
300
- Additive and backward compatible for consumers — no public prop changed, so a MINOR bump.
301
- `SizeDropdown`'s props gained `triggerLabel` / `getOptionLabel`, but that component is internal
302
- (never exported from the package root).
303
-
304
- ## 1.11.0
305
-
306
- Additive: a **declarative `Filters` bar** + **Pager** enhancements. Every change is additive and
307
- backward compatible — existing `FilterBar` / `Pager` / `DataTable` consumers (aml-v2, agora,
308
- zygos, kefi, erevna, katalogos) are untouched and every new prop is optional, so a MINOR bump.
309
- No app is migrated by this release; adoption is a later wave (see `ADOPTION.md`).
310
-
311
- - **`Filters`** — the declarative, configurable filter bar built ON the existing `FilterBar`
312
- shell (reusing its live results count + WCAG live region + actions slot). A caller passes a
313
- `fields` schema — the SUPERSET harvested from every portal's hand-rolled filters — of kinds
314
- `select` / `text` / `number` / `dateRange` / `typeahead` / `boolean`, plus a value map and
315
- `onChange`. Two value models: **LIVE** (edits apply immediately — agora, zygos) and
316
- **DRAFT/APPLY** (edits accumulate in a draft, an Apply button + Enter-in-a-field commit it —
317
- aml, kefi audit), the latter driven by the new `useFilterDraft` hook. Customisation is style
318
- (theme) + slots only: every label/option/placeholder/error is a pre-localized string; no
319
- FM/router/store. Apps can inject `@dloizides/ui-layout`'s `ModalDropdown` for the `select`
320
- field via `renderSelect` (the in-tree dropdown is the dependency-free default).
321
- - **`useFilterDraft`** — the draft-vs-applied state engine (draft + committed + `apply` / `reset`
322
- / `setField` / `dirty`), with `onApply` / `onReset` callbacks the caller wires to `setPage(1)`
323
- (the universal reset-to-page-1-on-narrowing invariant, kept free of pagination coupling).
324
- - **`suggestOptions` / `isUnmatched`** — the ranked substring matcher behind the `typeahead`
325
- field (generalized from aml's `suggestCountries`), exported for reuse.
326
- - **`Pager`** — three additive props reconciling the variants across apps: `showFirstLast`
327
- (First/Last jump buttons, disabled at bounds — erevna's `PaginationControls`),
328
- `unitLabelSingular` (renders `1 result` when `total === 1` — the singularisation apps did in
329
- the FilterBar noun), and `responsive` + `stackBreakpoint` (collapse to a compact
330
- Prev/Next-only nav below the breakpoint — the mobile fallback, mirroring the DataTable
331
- card-stack). New pager test ids `ui-pager-first` / `ui-pager-last`.
332
-
333
- ## 1.10.0
334
-
335
- Additive: **bulk-select** + **keyboard navigation** on `DataTable` (ZY-08). Every new prop is
336
- optional and CONTROLLED — omit them all and the table renders exactly as it did on 1.9.2, so
337
- erevna / katalogos / kefi / agora are unaffected. Hence a MINOR bump.
338
-
339
- - **Bulk-select** — `selectedRowKeys` + `onSelectionChange` add a checkbox gutter to the
340
- header and every row. Controlled, following the `expandedRowKeys` precedent exactly: the
341
- table keeps no internal selection state, and `onSelectionChange` is the enabler (as
342
- `renderRowDetail` is for expansion). The header checkbox is genuinely tri-state
343
- (`accessibilityState.checked: 'mixed'` + `aria-checked="mixed"`), and only ever adds or
344
- removes keys belonging to the CURRENT page — off-page keys the caller holds are preserved,
345
- because the table must not drop a selection it cannot see.
346
- - **Select all matching the filter — a FLAG, never an id list.** `matchingCount` +
347
- `onSelectAllMatchingChange` add a banner once the page is fully selected and more rows
348
- match. It emits `true`/`false`; the table never enumerates the matching rows (they are on
349
- pages it never fetched, and the ZY-02 spike measured ~2–3 ms and ~16 DOM nodes per row, so
350
- materialising thousands of them is indistinguishable from an outage). Toggling a single row
351
- under the flag drops it — the operator is no longer acting on *the filter*.
352
- - **Keyboard navigation** — `keyboardNavigation` (default **off**, because giving rows a
353
- `tabIndex` changes a page's tab order) implements the ARIA grid **roving tabindex**: one tab
354
- stop for the whole grid, ↑/↓ to move (clamped, never wrapping), Home/End, Space to toggle
355
- selection, Enter to activate via the existing `onRowPress`. Keys the table does not handle
356
- are never `preventDefault`ed, so Tab and browser shortcuts keep working. When the page
357
- changes underneath it the tab stop re-homes onto the new first row rather than vanishing —
358
- without that guard the grid would become keyboard-unreachable the moment an operator paged.
359
- Web-only in effect (focus movement and key events are DOM concerns); inert on native, via
360
- the same deliberate split as the `position: 'sticky'` header.
361
- - **a11y** — `role="grid"` / `row` / `columnheader` / `cell` when navigable; `aria-selected`
362
- on rows when selectable; row checkboxes are labelled with the ROW's name, so they announce
363
- as "Instruction ABC, checkbox" rather than an anonymous "checkbox" repeated down the page.
364
- - **🔴 A selectable row's checkbox sits OUTSIDE its pressable area** — a sibling, never a
365
- descendant. A checkbox nested inside an interactive row's `Pressable` is precisely the shape
366
- the 1.9.2 fix identified as broken: the row's pointer responders CAPTURE the gesture and
367
- cancel the child's press, so the checkbox would pass a synthetic `element.click()` test and
368
- silently do nothing under a real mouse, touch or Playwright click. A selectable row is now a
369
- plain `<View>` frame holding the checkbox and a separate pressable content area.
370
- - New exports: `rowSelectTestID(tableTestID, key)`, `selectAllTestID(tableTestID)`, the
371
- `uiTables.select.*` keys on `TABLE_I18N`, and the `selectCell` / `selectBanner`
372
- `styleOverrides` slots. No existing export changed.
373
- - Internals split for clarity as the row grew three shapes: `DataTableRow`, `TableRow`,
374
- `TableHeader`, `RowCells`, plus pure `selection.ts` / `rowNav.ts` rule modules and the
375
- `useTableSelection` / `useRovingFocus` hooks. No behaviour change for existing consumers
376
- (the full 1.9.2 suite passes untouched).
377
-
378
- ## 1.9.2
379
-
380
- - **🔴 In-cell action buttons (Edit/Delete/Stop) now fire on a real pointer gesture, not just a bare
381
- synthetic click.** A NON-interactive row (no `onRowPress`) was still rendered as a `<Pressable>`.
382
- On react-native-web a `Pressable` installs pointer responders (pointerdown/up/cancel) on the row
383
- container that CAPTURE a real mouse/touch gesture and cancel the press of any interactive child in
384
- a cell — so a Delete/Stop/Edit button inside a static row looked clickable, fired on a bare
385
- `element.click()`, but silently did nothing on an actual click/tap (and on a Playwright `.click()`,
386
- which is why the AML v2 settings webhook-delete + stop-monitoring E2Es were red). A non-pressable
387
- row is now a plain `<View>` (new `RowContainer`), so its cell controls receive the full gesture.
388
- Interactive tables (`onRowPress`) are unchanged. Same class as the earlier `disabled`→
389
- `pointer-events:none` fix; this closes the remaining pointer-responder-capture path.
390
-
391
- ## 1.9.0
392
-
393
- - **`Pager` dropdown-variant rows menu now escapes ancestor stacking contexts (web).** The
394
- `rowsVariant="dropdown"` `SizeDropdown` menu opened but painted UNDER the results table on wide
395
- web: react-native-web renders every `View` as `position: relative; z-index: 0`, so the in-tree
396
- `position: absolute; zIndex: 1000` menu was trapped inside its anchor's stacking context and lost
397
- to later-painting siblings (the table / cards below).
398
- - On **web** the open menu now renders in a PORTAL to `document.body` with `position: fixed` at the
399
- trigger's measured viewport rect (right-aligned, recomputed on scroll/resize) and a high `zIndex`
400
- — clipped by nothing, above everything. Mirrors `@dloizides/ui-layout`'s InlineMenu fix.
401
- - On **native** the menu is unchanged (in-tree `position: absolute` + `elevation`). All web-only code
402
- (portal, `document`/`window` listeners, `position: fixed`) is guarded behind `Platform.OS === 'web'`.
403
- - Outside-click dismissal now consults BOTH the anchor and the portalled menu node.
404
- - `react-dom` is added as an **optional** peer dependency (only touched on web; every RN-web consumer
405
- already has it). No API change: the `rowsVariant="dropdown"` contract, all test ids, the compact v1
406
- look and a11y (role/aria/keyboard) are unchanged.
407
-
408
- ## 1.8.0
409
-
410
- - `Pager` gains an additive, **default-off** `rowsVariant?: 'pills' | 'dropdown'` prop.
411
- - `'pills'` (default) is unchanged — the RN-idiom row of pressable size pills. Every existing
412
- consumer (erevna / katalogos / kefi / coverage) renders byte-identically.
413
- - `'dropdown'` swaps the size pills for a compact `<select>`-like anchored dropdown matching
414
- the v1 console's "Rows" select: a bordered trigger (height-matched to the Prev/Next ghost
415
- buttons) showing the current size + a chevron, opening a popover of the `pageSizeOptions`
416
- that fires `onPageSizeChange` and closes on select / outside-click / Escape. The "Rows"
417
- caption is mixed-case (not uppercase) in this variant, matching v1's muted `.hint` label.
418
- - Self-contained: the anchored dropdown is implemented inside ui-tables (new `SizeDropdown`),
419
- reusing ui-layout's InlineMenu click-outside/Escape pattern WITHOUT taking a hard dependency
420
- on `@dloizides/ui-layout` — its ModalDropdown trigger has fixed chunky padding and no chevron,
421
- so it cannot match v1's compact select, and a low-level table primitive should not depend on
422
- a higher-level layout package. New option/trigger test ids: `${testID}-size-trigger`,
423
- `${testID}-size-menu`, and the existing `${testID}-size-${size}` per option.
424
-
425
- ## 1.7.0
426
-
427
- - **Accessibility (WCAG 2.1 AA) hardening — additive + backward-compatible.**
428
- - `FilterBar`: the results-count line is now a `role="status"` / `aria-live="polite"` live
429
- region, so a screen reader announces the new count when filters change the result set
430
- (WCAG 4.1.3).
431
- - `Pager`: the Prev/Next controls and the rows-per-page pills gain a vertical `hitSlop` so the
432
- touch target reaches ~44px WITHOUT changing the rendered size (adjacent pills never overlap).
433
-
434
- ## 1.6.0
435
-
436
- - `DataTable` gains a **web row-hover highlight** on clickable rows, matching the v1 console's
437
- `.ui-table tr.clickable:hover` rule. Only interactive rows (those with an `onRowPress`) tint
438
- on hover — static rows never light up. The tint is the theme's soft brand fill
439
- (`palette.primary['500']` at low alpha via the new `softBrandTint` helper), so it re-themes
440
- per tenant, falling back to a subtle surface tint when `primary` is not a plain `#rrggbb`.
441
- The hover tint wins over zebra/`rowTint` while hovered (mirroring v1's `:hover td { background }`).
442
- - **Native-safe + backward-compatible**: hover is driven by `Pressable`'s `onHoverIn`/`onHoverOut`,
443
- which are no-ops on iOS/Android, and the handlers are wired only for interactive tables — a
444
- non-interactive table renders byte-identically to before. Benefits every consumer
445
- (erevna/katalogos/kefi/aml-v2) with clickable rows.
446
-
447
- ## 1.5.0
448
-
449
- - `Pager` gains two additive, **default-off** props so a paged grid can read exactly like the
450
- v1 AML console's `.ui-pager__info` line:
451
- - `infoPrefix?: string` — an already-translated word prefixed to the count
452
- (e.g. `"Showing"` → `Showing 1–50 of 3,023 leadership terms`).
453
- - `boldNumbers?: boolean` — renders the three counts (from / to / total) in bold
454
- `colors.text`, matching v1's `.ui-pager__info b`.
455
- - **Backward-compatible**: with both props omitted the count line is byte-identical to before
456
- (the concatenated text is unchanged even with `boldNumbers` on — bold is styling only), so
457
- existing consumers (`/coverage`, aml-v2) are unaffected.
458
-
459
- ## Unreleased
460
-
461
- - **Pixel-perfect overrides** (additive, backward-compatible). The kit's defaults are
462
- opinionated but never mandatory — a consumer that must match an existing look can now
463
- do so without forking:
464
- - `DataTable` gains `styleOverrides?: DataTableStyleOverrides` (slots: `wrap`, `headRow`,
465
- `headCell`, `row`, `cell`, `numCell`, `state`, `stateText`, `rowDetail`, `card`,
466
- `cardLine`, `cardLabel`, `cardValue`).
467
- - `Pager` gains `styleOverrides?: PagerStyleOverrides` (slots: `pager`, `pagerInfo`,
468
- `pagerNav`, `pagerRowsLabel`, `sizeGroup`, `control`, `controlText`, `sizePill`,
469
- `sizePillText`).
470
- - `FilterBar` gains `styleOverrides?: FilterBarStyleOverrides` (slots: `filters`,
471
- `filtersSpacer`, `results`, `filtersActions`).
472
- - Each slot is merged **LAST** into its style array, so an override beats the base
473
- StyleSheet **and** the inline colour the component applies from `useUi().theme`
474
- (colours are never in the StyleSheet in this kit).
475
- - Documented: `stackBreakpoint={0}` disables the responsive card-stack (`width < 0` is
476
- never true), for surfaces that never had one.
477
- - Omit `styleOverrides` and every render is byte-identical to before (verified by test).
478
-
479
- - `DataTable` — **expandable rows** (additive, backward-compatible). Two new optional props:
480
- - `renderRowDetail?: (row: T) => React.ReactNode` — renders a full-width detail panel
481
- (spanning every column) directly beneath a row, between it and the next row. Works in
482
- the desktop grid *and* in the responsive card-stack.
483
- - `expandedRowKeys?: readonly string[]` — the `keyExtractor` keys of the rows currently
484
- expanded. Expansion is **controlled by the caller** (own the state, toggle from
485
- `onRowPress`); the table keeps no internal expand state and adds no chevron.
486
- - The panel gets a stable test id `${testID}-row-detail-${key}` (new helpers
487
- `rowDetailTestID(tableTestID, key)` / `rowTestID(tableTestID, key)`), is exposed to
488
- assistive tech as a labelled region (`accessibilityRole="summary"` +
489
- the new `uiTables.rowDetail` translation key), and the row it belongs to reports
490
- `aria-expanded` / `accessibilityState.expanded`.
491
- - Omit both props and the table renders exactly as before: no extra DOM node, no extra
492
- row props, no behaviour change for existing consumers.
493
- - Unblocks kefi-web's audit log (before/after JSON snapshot panel) adopting `DataTable`.
494
-
495
- ## 1.2.0
496
-
497
- - `Pager` — new optional `unitLabel?: string` prop. When supplied it appends an
498
- already-translated unit noun to the count line, e.g. `unitLabel="leadership terms"`
499
- renders `1–50 of 3,023 leadership terms` (v1 parity). Backward-compatible: when the
500
- prop is omitted (or empty) the count line stays the generic `from–to of N`,
501
- byte-identical to prior behaviour.
502
- - Test tooling — added `src/jest-dom.d.ts` so ts-jest picks up the
503
- `@testing-library/jest-dom` matcher types (`toBeDisabled`, …) when type-checking each
504
- test file (`jest.setup.ts` sits outside the `src/**` include). Fixes the `Pager` suite
505
- failing to compile under the isolated ts-jest type-check.
506
-
507
- ## 1.1.0
508
-
509
- - `DataTable` — promoted from the `/coverage` RN-web POC and hardened into the shared,
510
- tokenized grid (the `wwwroot/shared/GRID.md` contract):
511
- - per-row `testID` + `accessibilityLabel`/`accessibilityHint`, pressable rows (`onRowPress`);
512
- - all user-facing chrome routed through the UiProvider `t` (no literals) — falls back to
513
- caller-supplied `loadingLabel`/`emptyLabel`;
514
- - fixed the POC's double `col.render()` call in the desktop path (now rendered once per cell);
515
- - added the rest of the GRID.md contract: `FilterBar`, `Pager` (page-info + Prev/Next +
516
- rows-per-page), an optional `zebra` modifier, and a `stickyHeader`;
517
- - responsive label:value card-stack via `useWindowDimensions` below `stackBreakpoint`;
518
- - every colour from `@dloizides/design-tokens` via the `useUi()` theme — no hardcoded colours.
519
- - Component tests (`DataTable`, `FilterBar`, `Pager`) added.
520
-
521
- ## 1.0.0
522
-
523
- Initial release (Capability Wave C1, batch 3).
524
-
525
- - `StatCard` — extracted from the proven erevna ↔ katalogos duplication; shares the
526
- `@dloizides/ui-feedback` UI context (`useUi`).
527
- - `DataTable` / `StatGrid` intentionally NOT included yet — they exist only in kefi-web (n=1);
528
- they'll be added when a 2nd consumer appears.
1
+ # Changelog
2
+
3
+ ## 1.23.0
4
+
5
+ **A press anywhere on an interactive `DataTable` / `StatusLedger` row opens it, including on a time cell (JOBS-NOLOSS-1 "Restore everything the old Jobs page showed").**
6
+
7
+ `RelativeTime` is its own `Pressable`, so on react-native-web it claimed the press and the row's
8
+ `onRowPress` never fired: in the wide ledger only cells without a time opened the row detail. An
9
+ interactive row now publishes its press through a context; `RelativeTime` still swaps to the
10
+ absolute time and also presses its row. Outside an interactive row nothing changes.
11
+
12
+ ## 1.22.0
13
+
14
+ **`StatusLedger` opens a row's detail inline, under the row (JOBS-INLINE-1 "Ledger run history opens under its row").**
15
+
16
+ New optional `renderRowDetail(row)` + controlled `expandedRowKey` on `StatusLedger`, passed to the
17
+ `DataTable` in the wide table and in both narrow "needs a look" sections, so the detail sits
18
+ directly under the pressed row or card. The expanded row carries `aria-expanded`; the detail region
19
+ is named by `getRowAccessibilityLabel`. `DataTable` gains `getRowDetailAccessibilityLabel` (defaults
20
+ to the generic `uiTables.rowDetail`). Additive, nothing existing changes.
21
+
22
+ ## 1.21.0
23
+
24
+ **New `StatusLedger` (JOBS-UX-1 "Jobs page: one clear, consistent view of every job and source").**
25
+
26
+ A status-first ledger built on `DataTable` + `Filters`: one sortable, filterable table at or above
27
+ the breakpoint (768 by default, from `useWindowDimensions`), and a "needs a look first" feed below
28
+ it (bad then warn rows on top, then the rest). Filters: free text, status, group; sort by any column
29
+ with a `sortValue`, plus a 44px direction toggle. Generic row shape through accessors; every string
30
+ via `labels`/`statusLabel`; tone colours from the theme (`toneColors` overrides). Also exports
31
+ `StatusPill`, `RelativeTime` (tap swaps to absolute), `formatRelativeTime` and the pure
32
+ `filterLedgerRows` / `sortLedgerRows` / `splitNeedsLook` helpers. Additive, nothing existing changes.
33
+
34
+ ## 1.20.0
35
+
36
+ **The rows-per-page menu opens above an RN-web Modal (UI-ZINDEX-SCALE-1 "Shared overlay z-index scale").**
37
+
38
+ react-native-web mounts `Modal` in a body-level layer at zIndex 9999. On web the `SizeDropdown`
39
+ menu portals to the body, and at zIndex 1000 it painted under an open Modal, so clicks fell through
40
+ to the dialog. The menu now uses `Z_INDEX.popover` (10000, below toasts) and the sticky header uses
41
+ `Z_INDEX.sticky` (2, unchanged), both from `@dloizides/design-tokens` ^1.13.0, which is now a dependency.
42
+
43
+ ## 1.19.2
44
+
45
+ **The pager shrinks and wraps beside a title (TABLES-MOBILE-1 "Filter bar and pager overflow at 360").**
46
+
47
+ Visual QA of aml-v2 `/app/cases` at 360 measured the pager, placed beside the "Cases" title in a
48
+ wrapping row, at 328px inside a 255px slot: `flex-shrink: 0`, no width cap, so Next ran to x=373
49
+ and an `overflow: hidden` ancestor clipped it. `pager` and `pagerNav` now carry `flexShrink: 1`,
50
+ `minWidth: 0` and `maxWidth: '100%'`, so they fit their line and their existing `flexWrap` breaks
51
+ the count / Rows / Prev / Next onto further lines. Desktop is unchanged where the row fits.
52
+
53
+ ## 1.19.1
54
+
55
+ **The `Filters` / `FilterBar` actions cluster wraps (TABLES-MOBILE-1 "Filter bar and pager overflow at 360").**
56
+
57
+ Visual QA of aml-v2 `/app/leaders` at 360 measured the actions row (Reset, Export CSV/PDF, Apply)
58
+ at 431px inside a 255px bar: a nowrap row is one unbreakable flex item, so Apply rendered at x=373,
59
+ off-screen. `filtersActions` now has `flexWrap: 'wrap'`, `flexShrink: 1` and `maxWidth: '100%'`,
60
+ so the cluster fits its line and its buttons break onto further lines. Desktop is unchanged: where
61
+ the row fits, nothing wraps. The 44px Apply / pager hit boxes shipped in 1.19.0.
62
+
63
+ ## 1.19.0
64
+
65
+ **Every pressable renders a 44x44 hit box (SHOWCASE-1 "Publish the UI showcase at ui.dloizides.com").**
66
+
67
+ Live QA on ui.dloizides.com/tables at 360x640 measured switches at 40x20, page-size buttons at
68
+ 32-39x30 and pager buttons 31px tall. `hitSlop` is inert on react-native-web, so the rendered box
69
+ is the target. Pager buttons, page-size pills, the dropdown trigger and its options, filter action
70
+ buttons, the select checkbox (gutter now 44px wide) and the select-all banner action now carry
71
+ `minHeight`/`minWidth` of `MIN_TARGET_PX` (44). The filter `Switch` keeps its 40x20 track inside a
72
+ 44x44 `Pressable` (`-switch-hit` test id); the inner Switch keeps focus and the switch role.
73
+ The inert `hitSlop` props were removed.
74
+
75
+ ## 1.18.0
76
+
77
+ **`DataTable` rows now fade in on load — the Ant-design-like list entrance — via `@dloizides/ui-motion`.**
78
+
79
+ When a `DataTable` mounts its rows (first load, and whenever the row set changes — sort / filter /
80
+ page), each row now fades in with a small upward translate, staggered across the first few rows. It
81
+ is a subtle polish layer, gated hard so it never becomes jank on a large page, and **entirely
82
+ opt-outable** — omit nothing and the table behaves exactly as before minus the fade.
83
+
84
+ ### What changed
85
+
86
+ | Area | Detail |
87
+ |---|---|
88
+ | **New optional prop** | `animateRows?: boolean` (default **`true`**). Each row (and its expanded detail panel, if any) is wrapped in `@dloizides/ui-motion`'s `<FadeIn>`, keyed by the row key. |
89
+ | **Capped stagger** | Only the first `ROW_ENTRANCE_STAGGER_CAP` (10) rows stagger, `ROW_ENTRANCE_STAGGER_STEP_MS` (30 ms) apart; every row past the cap shares the capped delay. A 100- or 5,000-row page settles in a fixed ~300 ms, **never** row-by-row. |
90
+ | **Reduced-motion** | Honoured: rows render instantly, with **no wrapper node and no delay** (`FadeIn` gates too, but the wrapper is skipped entirely so the reduced-motion DOM is identical to the un-animated table). |
91
+ | **No re-fade on re-render** | Each row's `<FadeIn>` is keyed by its row key, so React keeps its identity across unrelated re-renders (hover, a re-fetch that resolves to the SAME keys) — the entrance plays once per key, not on every render. A genuine row-set change (new keys) re-fades, as intended. |
92
+ | **New test id** | `rowFadeTestID(tableTestID, key)` → `${tableTestID}-fade-${key}` (present only while animating), exported alongside the other row test-id helpers. |
93
+
94
+ ### Backward compatibility
95
+
96
+ - **MINOR, additive.** The public API gains one optional prop and one test-id helper; nothing is
97
+ renamed or removed.
98
+ - All existing behaviour is preserved: zebra, sticky header, mobile card-stack, row/per-cell/head/
99
+ detail-panel/select-checkbox test ids, `onRowPress`, bulk-select, keyboard navigation, the pager,
100
+ and the refetch-does-not-blank-the-grid guard.
101
+ - Pass `animateRows={false}` (or run under `prefers-reduced-motion`) and rows render with no
102
+ wrapper node — DOM identical to before this release.
103
+ - New peer of the kit: `@dloizides/ui-motion` (`^1.0.1`) is added as a dependency.
104
+
105
+ ## 1.16.0
106
+
107
+ **The responsive card-stack now reads as a proper mobile layout — and keeps every E2E hook.**
108
+
109
+ `DataTable` has always collapsed to a label:value card-stack below a breakpoint (`stackBreakpoint`),
110
+ but on a phone the multi-column tables it powers (e.g. the organizer Passes table) were still hard
111
+ to read, and the card-stack silently dropped test hooks a wide-viewport E2E suite relies on. This
112
+ release makes the card-stack the readable, self-explanatory mobile layout it was meant to be —
113
+ **with no change to the desktop grid and no broken selectors.**
114
+
115
+ ### What changed
116
+
117
+ | Area | Before | Now |
118
+ |---|---|---|
119
+ | **Default breakpoint** | `640` | `768` — the kit-wide narrow-viewport threshold, aligned with `@dloizides/ui-layout`'s `MENU_BREAKPOINT` (already the collapse point for the nav menu and tabs). `CARD_STACK_BREAKPOINT` is re-exported at the new value. |
120
+ | **Card line layout** | label LEFT, value RIGHT on one `space-between` row (cramped for long values / action buttons) | each column's header sits **ABOVE** its value, both left-aligned, so the value gets the full card width |
121
+ | **Per-cell test id `${row}-${colKey}`** | resolved **only** on the desktop grid | resolves in **BOTH** layouts (the card line carries the same id the desktop cell does) |
122
+ | **Head test id `ui-data-table-head`** | **absent** in card-stack mode | resolves in **BOTH** layouts via a hidden, a11y-inert carrier (`display: none`, `aria-hidden`) — E2E selectors survive at every width |
123
+
124
+ ### Backward compatibility
125
+
126
+ - **The desktop grid is byte-for-byte unchanged.** Opt out of the card-stack entirely, at every
127
+ width, with `stackBreakpoint={0}` (unchanged).
128
+ - A column's `render` node (badge, link, **action button**) renders identically in a card cell.
129
+ - Row / per-cell / head / detail-panel / select-checkbox test ids are all preserved; the only
130
+ net-new guarantee is that per-cell and head ids now ALSO resolve in the card-stack.
131
+ - The one observable difference for an existing consumer is cosmetic: tables between 640px and
132
+ 768px wide now show the card-stack (they showed the cramped desktop row before), and cards read
133
+ vertically rather than as a `space-between` row. Both are strict readability improvements — which
134
+ is what keeps this a MINOR bump.
135
+
136
+ All 272 tests pass (6 added for the both-layouts test-hook contract + the vertical card layout).
137
+
138
+ ## 1.15.0
139
+
140
+ **A re-fetch no longer blanks the grid — the server-paged paging defect.**
141
+
142
+ `DataTable` returned its full-bleed loading state whenever `loading` was true, unconditionally.
143
+ On a server-paged grid that is not a cosmetic flicker, it is the paging bug: clicking **Next**
144
+ replaced the table with "Loading…", so the grid visibly EMPTIED and only refilled once the next
145
+ page arrived. To anyone watching — and to any assertion that samples the rows after the click —
146
+ the grid appeared to page to nothing. The same applied to re-filtering and to any `reload()`.
147
+
148
+ Evidence this was real and not theoretical: against the live AML v2 cases console, the API
149
+ returned a correct, non-overlapping page at `skip=50`, yet the UI rendered **zero** rows after
150
+ Next. The rows were being discarded by this component, not by the query.
151
+
152
+ ### The rule now
153
+
154
+ The state view is reserved for when there is genuinely nothing to show:
155
+
156
+ | `loading` | `rows.length` | Renders |
157
+ |---|---|---|
158
+ | true | 0 | loading state (first load) |
159
+ | false | 0 | empty state |
160
+ | true | > 0 | **the existing rows** (stale for a moment), `aria-busy="true"` |
161
+ | false | > 0 | the rows |
162
+
163
+ Rows that already exist stay on screen and swap when the new page resolves. Because the content
164
+ no longer vanishes, the in-flight fetch is announced explicitly via `aria-busy` on the table
165
+ container rather than being implied by the table's destruction.
166
+
167
+ **Behaviour is unchanged for every first load and every empty result**, which is what keeps this a
168
+ MINOR bump. The only consumers that see a difference are those that were already passing `loading`
169
+ alongside non-empty `rows` — i.e. exactly the ones that were silently blanking.
170
+
171
+ All 266 pre-existing tests pass unmodified; 3 added for the retained-rows / busy / swap contract.
172
+
173
+ ## 1.14.0
174
+
175
+ **Campaign F2 — the private filter fields are now public, in `@dloizides/ui-forms`.**
176
+
177
+ This package contained a complete, themed, a11y-wired set of form controls inside its `Filters`
178
+ bar and exported NONE of them. Six portals could see them working and none could import them, so
179
+ the fleet reimplemented them: **6 select implementations, 5 date fields, 2 typeaheads**. Same
180
+ shape as `MultiTenancy.EntityFrameworkCore` shipping no EF Core. They now live in
181
+ `@dloizides/ui-forms` 1.8.0 as `SelectControl` / `TypeaheadControl` / `DateRangeControl` /
182
+ `AnchoredMenu` / `controlStyles`, and this package consumes them.
183
+
184
+ **No behaviour changed. All 258 pre-existing tests pass UNMODIFIED** — including
185
+ `Filters.test.tsx` (which drives every field kind through the bar), `selectAccessibleName.test.tsx`
186
+ (the i18n path) and `suggest.test.ts` (now running against the moved implementation). That is the
187
+ proof the move preserved behaviour rather than merely relocating it.
188
+
189
+ ### What moved, and what deliberately did not
190
+
191
+ The controls moved; the **schema** stayed. Each field was bound to this bar's `FilterField` types
192
+ (`field: SelectFilterField`, `barTestID`, `fieldTestID`), so moving them verbatim would have
193
+ dragged `FilterField`, `FilterFieldKind`, `FilterValues` and `FIELD_MIN_WIDTH` into `ui-forms` —
194
+ i.e. `ui-forms` would have come to own "what a filter bar's field schema is". Wrong direction.
195
+ The field files are now thin ADAPTERS mapping schema → plain props.
196
+
197
+ `TextField` and `BooleanField` stayed. `ui-forms` already ships two text inputs (`ThemedTextInput`,
198
+ `FormField`) and a switch row (`FormSwitch`); promoting a third of each would ADD duplicates to the
199
+ package this campaign is de-duplicating. Converging onto the existing ones is right but VISIBLE
200
+ (focus ring, hover border, `surfaceElevated` background, different switch-row metrics), so it
201
+ belongs in the visual-QA-gated wave. Both now use the shared `controlStyles` boxes, so no metric
202
+ is forked in the meantime.
203
+
204
+ ### `FieldShell` is deleted
205
+
206
+ The private label-wrapper fork existed only because `Field` hard-coded the 13/600 `field` label
207
+ voice. `Field` 1.7.0 named both contract voices, so the bar now asks for `labelVariant="control"`
208
+ — the 11/700/uppercase metrics `FieldShell` carried, verbatim. This ends the label-metric split
209
+ between `Field` and `FieldShell` that caused several defects this campaign.
210
+
211
+ The swap replaces the label implementation under six live portals, so it is guarded by a dedicated
212
+ test (`fieldShellRetirement.test.tsx`) asserting the voice, the absence of `Field`'s 16px form
213
+ rhythm, the per-kind reflow rules and the caller-override precedence. Removing `labelVariant`
214
+ fails two of its five assertions — verified, not assumed.
215
+
216
+ ### i18n manifests are untouched
217
+
218
+ `FILTERS_I18N` and `TABLE_I18N` are unchanged, and every portal guard that binds to them keeps
219
+ working. `ui-forms` never calls `t`, so the one field that resolved an i18n key —
220
+ `SelectField`'s `FILTERS_I18N.selectTriggerLabel` accessible name — composes that string HERE, in
221
+ the adapter, and passes the finished value down as `accessibilityLabel`. The i18n stayed with the
222
+ package that owns the keys.
223
+
224
+ ### Notes
225
+
226
+ - New peer dependency: `@dloizides/ui-forms >= 1.8.0`, plus `@dloizides/ui-buttons >= 1.4.0`
227
+ inherited through it (`ui-forms` bundles `FormActions`). All five portals consuming `ui-tables`
228
+ already declare `ui-buttons ^1.4.0`, so this is a declaration of existing reality, not a new
229
+ requirement.
230
+ - `FilterOption` and `DateRangeValue` are now ALIASES of `ui-forms`' `ControlOption` /
231
+ `DateRangeValue`. Public names unchanged; one definition instead of two structurally-identical
232
+ twins free to drift.
233
+ - `DEFAULT_TYPEAHEAD_MIN_CHARS` / `DEFAULT_TYPEAHEAD_MAX_SUGGESTIONS` and `suggestOptions` /
234
+ `isUnmatched` are re-exported from `ui-forms`. Public API unchanged.
235
+ - Inherits the `AnchoredMenu` WCAG fix from `ui-forms` 1.8.0: the selected option now carries
236
+ `aria-selected`. `accessibilityState` is native-only and react-native-web ignores it, so on web
237
+ the current option had been conveyed by colour and font-weight alone (WCAG 1.4.1).
238
+ - `AnchoredMenu` remains one of three near-identical anchored-menu implementations, with
239
+ `ui-layout`'s `InlineMenu` and this package's `SizeDropdown`. Collapsing them was out of scope.
240
+ The move makes it EASIER: two of the three now sit in packages that may depend on `ui-forms`, so
241
+ a future collapse has an obvious home rather than needing a new shared package first.
242
+
243
+ ## 1.13.0
244
+
245
+ De-fork wave W1.1: pagination logic promoted from the byte-identical `PaginatedList`
246
+ twins in erevna-web and katalogos-web.
247
+
248
+ ### Added
249
+
250
+ - `usePagedRows(rows, { pageSize })` — client-side pagination state for an already
251
+ in-memory array. Returns `pageRows`, `currentPage`, `totalPages`, `setPage`,
252
+ `hasPages`, `pageSize`. No new translation keys; no action required.
253
+
254
+ Promoted as a **hook, not a component**, deliberately: the app-side `PaginatedList`
255
+ hard-bound a `FlatList` plus app-specific empty and loading states. Only the paging
256
+ maths is genuinely shared, so only that moved — callers keep their own list renderer.
257
+ For server-side paging keep using `DataTable`'s pager.
258
+
259
+ ### Fixed (behaviour differs from the app-side original)
260
+
261
+ - The original only clamped the page index when `totalPages > 0`, so emptying the list
262
+ left a stale non-zero page behind and the next non-empty render started on the wrong
263
+ page. `usePagedRows` clamps to 0 in that case.
264
+ - A `pageSize` of 0 divided by zero (`Math.ceil(n / 0)` → `Infinity` pages). Now floored
265
+ to 1.
266
+ - `setPage` clamps out-of-range input; the original trusted the caller.
267
+
268
+ ## 1.12.0
269
+
270
+ Accessibility fix: controls that announced a **bare number** now say what they are. Confirmed in
271
+ a real browser, the rows-per-page trigger rendered `aria-label="50"` — a screen-reader user heard
272
+ the value and nothing about the control. Fixed across the whole package, plus two more instances
273
+ of the same defect class found while auditing.
274
+
275
+ ### ⚠️ ACTION REQUIRED — add three translation keys
276
+
277
+ The new accessible names are user-facing strings, so they come from the host app's locale files.
278
+ **Every consuming app must add these three keys:**
279
+
280
+ | Key | Params | Suggested English |
281
+ |---|---|---|
282
+ | `uiTables.pager.rowsTriggerLabel` | `{{p1}}` = current page size | `Rows per page, currently {{p1}}` |
283
+ | `uiTables.pager.rowsOptionLabel` | `{{p1}}` = that option's size | `Show {{p1}} rows per page` |
284
+ | `uiTables.filters.selectTriggerLabel` | `{{p1}}` = field label, `{{p2}}` = selection | `{{p1}}: {{p2}}` |
285
+
286
+ They are exported as `TABLE_I18N.pagerRowsTriggerLabel`, `TABLE_I18N.pagerRowsOptionLabel` and
287
+ `FILTERS_I18N.selectTriggerLabel`, so an app that derives its required-key list from those maps
288
+ (as zygos' guard test does) picks them up automatically.
289
+
290
+ **Upgrading without adding them is safe.** Unlike the usual kit contract — where an undefined key
291
+ renders as its literal dotted name, the failure that put 44 raw keys on screen in zygos — a
292
+ newly-introduced ACCESSIBLE-NAME key degrades to the value it replaced (the bare number, the field
293
+ label). An aria-label is invisible to sighted reviewers, so a raw key there would ship silently and
294
+ hurt only screen-reader users. Until you add the keys you simply keep the old, worse names.
295
+
296
+ ### Fixed
297
+
298
+ - **`Pager` rows-per-page trigger** (`dropdown` variant) — was `aria-label="50"`, now
299
+ "Rows per page, currently 50".
300
+ - **`Pager` rows-per-page options** (`dropdown` variant) — was `aria-label="100"`, now
301
+ "Show 100 rows per page".
302
+ - **`Pager` rows-per-page pills** (the **DEFAULT** `pills` variant) — carried the identical
303
+ bare-number defect and was NOT in the original report, so it affected more consumers than the
304
+ dropdown did. Same fix, same key.
305
+ - **`Filters` select trigger** — `accessibilityLabel` replaces the trigger's visible text for a
306
+ screen reader, so labelling it `field.label` alone silently hid the current selection: sighted
307
+ users saw "Closed", screen-reader users heard only "Status". Now "Status: Closed".
308
+ - **`StatCard`** — its two translation keys were string literals inlined in the component rather
309
+ than members of an exported map, so an app deriving its required-key list from `TABLE_I18N`
310
+ could not see them and would render them raw. Now exported as `TABLE_I18N.statCardLabel` /
311
+ `TABLE_I18N.statHint`. **The key strings are unchanged** (`analytics.statCardLabel`,
312
+ `analytics.statHint`) — renaming them would have broken every app that already defines them.
313
+
314
+ ### Added
315
+
316
+ - **`accessibleName(translated, key, fallback)`** — the internal degradation guard described
317
+ above. Not exported; the kit's fallback-free i18n contract is unchanged for visible copy.
318
+
319
+ Additive and backward compatible for consumers — no public prop changed, so a MINOR bump.
320
+ `SizeDropdown`'s props gained `triggerLabel` / `getOptionLabel`, but that component is internal
321
+ (never exported from the package root).
322
+
323
+ ## 1.11.0
324
+
325
+ Additive: a **declarative `Filters` bar** + **Pager** enhancements. Every change is additive and
326
+ backward compatible — existing `FilterBar` / `Pager` / `DataTable` consumers (aml-v2, agora,
327
+ zygos, kefi, erevna, katalogos) are untouched and every new prop is optional, so a MINOR bump.
328
+ No app is migrated by this release; adoption is a later wave (see `ADOPTION.md`).
329
+
330
+ - **`Filters`** — the declarative, configurable filter bar built ON the existing `FilterBar`
331
+ shell (reusing its live results count + WCAG live region + actions slot). A caller passes a
332
+ `fields` schema — the SUPERSET harvested from every portal's hand-rolled filters — of kinds
333
+ `select` / `text` / `number` / `dateRange` / `typeahead` / `boolean`, plus a value map and
334
+ `onChange`. Two value models: **LIVE** (edits apply immediately — agora, zygos) and
335
+ **DRAFT/APPLY** (edits accumulate in a draft, an Apply button + Enter-in-a-field commit it —
336
+ aml, kefi audit), the latter driven by the new `useFilterDraft` hook. Customisation is style
337
+ (theme) + slots only: every label/option/placeholder/error is a pre-localized string; no
338
+ FM/router/store. Apps can inject `@dloizides/ui-layout`'s `ModalDropdown` for the `select`
339
+ field via `renderSelect` (the in-tree dropdown is the dependency-free default).
340
+ - **`useFilterDraft`** — the draft-vs-applied state engine (draft + committed + `apply` / `reset`
341
+ / `setField` / `dirty`), with `onApply` / `onReset` callbacks the caller wires to `setPage(1)`
342
+ (the universal reset-to-page-1-on-narrowing invariant, kept free of pagination coupling).
343
+ - **`suggestOptions` / `isUnmatched`** — the ranked substring matcher behind the `typeahead`
344
+ field (generalized from aml's `suggestCountries`), exported for reuse.
345
+ - **`Pager`** — three additive props reconciling the variants across apps: `showFirstLast`
346
+ (First/Last jump buttons, disabled at bounds — erevna's `PaginationControls`),
347
+ `unitLabelSingular` (renders `1 result` when `total === 1` — the singularisation apps did in
348
+ the FilterBar noun), and `responsive` + `stackBreakpoint` (collapse to a compact
349
+ Prev/Next-only nav below the breakpoint — the mobile fallback, mirroring the DataTable
350
+ card-stack). New pager test ids `ui-pager-first` / `ui-pager-last`.
351
+
352
+ ## 1.10.0
353
+
354
+ Additive: **bulk-select** + **keyboard navigation** on `DataTable` (ZY-08). Every new prop is
355
+ optional and CONTROLLED — omit them all and the table renders exactly as it did on 1.9.2, so
356
+ erevna / katalogos / kefi / agora are unaffected. Hence a MINOR bump.
357
+
358
+ - **Bulk-select** — `selectedRowKeys` + `onSelectionChange` add a checkbox gutter to the
359
+ header and every row. Controlled, following the `expandedRowKeys` precedent exactly: the
360
+ table keeps no internal selection state, and `onSelectionChange` is the enabler (as
361
+ `renderRowDetail` is for expansion). The header checkbox is genuinely tri-state
362
+ (`accessibilityState.checked: 'mixed'` + `aria-checked="mixed"`), and only ever adds or
363
+ removes keys belonging to the CURRENT page — off-page keys the caller holds are preserved,
364
+ because the table must not drop a selection it cannot see.
365
+ - **Select all matching the filter — a FLAG, never an id list.** `matchingCount` +
366
+ `onSelectAllMatchingChange` add a banner once the page is fully selected and more rows
367
+ match. It emits `true`/`false`; the table never enumerates the matching rows (they are on
368
+ pages it never fetched, and the ZY-02 spike measured ~2–3 ms and ~16 DOM nodes per row, so
369
+ materialising thousands of them is indistinguishable from an outage). Toggling a single row
370
+ under the flag drops it — the operator is no longer acting on *the filter*.
371
+ - **Keyboard navigation** — `keyboardNavigation` (default **off**, because giving rows a
372
+ `tabIndex` changes a page's tab order) implements the ARIA grid **roving tabindex**: one tab
373
+ stop for the whole grid, ↑/↓ to move (clamped, never wrapping), Home/End, Space to toggle
374
+ selection, Enter to activate via the existing `onRowPress`. Keys the table does not handle
375
+ are never `preventDefault`ed, so Tab and browser shortcuts keep working. When the page
376
+ changes underneath it the tab stop re-homes onto the new first row rather than vanishing —
377
+ without that guard the grid would become keyboard-unreachable the moment an operator paged.
378
+ Web-only in effect (focus movement and key events are DOM concerns); inert on native, via
379
+ the same deliberate split as the `position: 'sticky'` header.
380
+ - **a11y** — `role="grid"` / `row` / `columnheader` / `cell` when navigable; `aria-selected`
381
+ on rows when selectable; row checkboxes are labelled with the ROW's name, so they announce
382
+ as "Instruction ABC, checkbox" rather than an anonymous "checkbox" repeated down the page.
383
+ - **🔴 A selectable row's checkbox sits OUTSIDE its pressable area** — a sibling, never a
384
+ descendant. A checkbox nested inside an interactive row's `Pressable` is precisely the shape
385
+ the 1.9.2 fix identified as broken: the row's pointer responders CAPTURE the gesture and
386
+ cancel the child's press, so the checkbox would pass a synthetic `element.click()` test and
387
+ silently do nothing under a real mouse, touch or Playwright click. A selectable row is now a
388
+ plain `<View>` frame holding the checkbox and a separate pressable content area.
389
+ - New exports: `rowSelectTestID(tableTestID, key)`, `selectAllTestID(tableTestID)`, the
390
+ `uiTables.select.*` keys on `TABLE_I18N`, and the `selectCell` / `selectBanner`
391
+ `styleOverrides` slots. No existing export changed.
392
+ - Internals split for clarity as the row grew three shapes: `DataTableRow`, `TableRow`,
393
+ `TableHeader`, `RowCells`, plus pure `selection.ts` / `rowNav.ts` rule modules and the
394
+ `useTableSelection` / `useRovingFocus` hooks. No behaviour change for existing consumers
395
+ (the full 1.9.2 suite passes untouched).
396
+
397
+ ## 1.9.2
398
+
399
+ - **🔴 In-cell action buttons (Edit/Delete/Stop) now fire on a real pointer gesture, not just a bare
400
+ synthetic click.** A NON-interactive row (no `onRowPress`) was still rendered as a `<Pressable>`.
401
+ On react-native-web a `Pressable` installs pointer responders (pointerdown/up/cancel) on the row
402
+ container that CAPTURE a real mouse/touch gesture and cancel the press of any interactive child in
403
+ a cell — so a Delete/Stop/Edit button inside a static row looked clickable, fired on a bare
404
+ `element.click()`, but silently did nothing on an actual click/tap (and on a Playwright `.click()`,
405
+ which is why the AML v2 settings webhook-delete + stop-monitoring E2Es were red). A non-pressable
406
+ row is now a plain `<View>` (new `RowContainer`), so its cell controls receive the full gesture.
407
+ Interactive tables (`onRowPress`) are unchanged. Same class as the earlier `disabled`→
408
+ `pointer-events:none` fix; this closes the remaining pointer-responder-capture path.
409
+
410
+ ## 1.9.0
411
+
412
+ - **`Pager` dropdown-variant rows menu now escapes ancestor stacking contexts (web).** The
413
+ `rowsVariant="dropdown"` `SizeDropdown` menu opened but painted UNDER the results table on wide
414
+ web: react-native-web renders every `View` as `position: relative; z-index: 0`, so the in-tree
415
+ `position: absolute; zIndex: 1000` menu was trapped inside its anchor's stacking context and lost
416
+ to later-painting siblings (the table / cards below).
417
+ - On **web** the open menu now renders in a PORTAL to `document.body` with `position: fixed` at the
418
+ trigger's measured viewport rect (right-aligned, recomputed on scroll/resize) and a high `zIndex`
419
+ — clipped by nothing, above everything. Mirrors `@dloizides/ui-layout`'s InlineMenu fix.
420
+ - On **native** the menu is unchanged (in-tree `position: absolute` + `elevation`). All web-only code
421
+ (portal, `document`/`window` listeners, `position: fixed`) is guarded behind `Platform.OS === 'web'`.
422
+ - Outside-click dismissal now consults BOTH the anchor and the portalled menu node.
423
+ - `react-dom` is added as an **optional** peer dependency (only touched on web; every RN-web consumer
424
+ already has it). No API change: the `rowsVariant="dropdown"` contract, all test ids, the compact v1
425
+ look and a11y (role/aria/keyboard) are unchanged.
426
+
427
+ ## 1.8.0
428
+
429
+ - `Pager` gains an additive, **default-off** `rowsVariant?: 'pills' | 'dropdown'` prop.
430
+ - `'pills'` (default) is unchanged — the RN-idiom row of pressable size pills. Every existing
431
+ consumer (erevna / katalogos / kefi / coverage) renders byte-identically.
432
+ - `'dropdown'` swaps the size pills for a compact `<select>`-like anchored dropdown matching
433
+ the v1 console's "Rows" select: a bordered trigger (height-matched to the Prev/Next ghost
434
+ buttons) showing the current size + a chevron, opening a popover of the `pageSizeOptions`
435
+ that fires `onPageSizeChange` and closes on select / outside-click / Escape. The "Rows"
436
+ caption is mixed-case (not uppercase) in this variant, matching v1's muted `.hint` label.
437
+ - Self-contained: the anchored dropdown is implemented inside ui-tables (new `SizeDropdown`),
438
+ reusing ui-layout's InlineMenu click-outside/Escape pattern WITHOUT taking a hard dependency
439
+ on `@dloizides/ui-layout` — its ModalDropdown trigger has fixed chunky padding and no chevron,
440
+ so it cannot match v1's compact select, and a low-level table primitive should not depend on
441
+ a higher-level layout package. New option/trigger test ids: `${testID}-size-trigger`,
442
+ `${testID}-size-menu`, and the existing `${testID}-size-${size}` per option.
443
+
444
+ ## 1.7.0
445
+
446
+ - **Accessibility (WCAG 2.1 AA) hardening — additive + backward-compatible.**
447
+ - `FilterBar`: the results-count line is now a `role="status"` / `aria-live="polite"` live
448
+ region, so a screen reader announces the new count when filters change the result set
449
+ (WCAG 4.1.3).
450
+ - `Pager`: the Prev/Next controls and the rows-per-page pills gain a vertical `hitSlop` so the
451
+ touch target reaches ~44px WITHOUT changing the rendered size (adjacent pills never overlap).
452
+
453
+ ## 1.6.0
454
+
455
+ - `DataTable` gains a **web row-hover highlight** on clickable rows, matching the v1 console's
456
+ `.ui-table tr.clickable:hover` rule. Only interactive rows (those with an `onRowPress`) tint
457
+ on hover — static rows never light up. The tint is the theme's soft brand fill
458
+ (`palette.primary['500']` at low alpha via the new `softBrandTint` helper), so it re-themes
459
+ per tenant, falling back to a subtle surface tint when `primary` is not a plain `#rrggbb`.
460
+ The hover tint wins over zebra/`rowTint` while hovered (mirroring v1's `:hover td { background }`).
461
+ - **Native-safe + backward-compatible**: hover is driven by `Pressable`'s `onHoverIn`/`onHoverOut`,
462
+ which are no-ops on iOS/Android, and the handlers are wired only for interactive tables — a
463
+ non-interactive table renders byte-identically to before. Benefits every consumer
464
+ (erevna/katalogos/kefi/aml-v2) with clickable rows.
465
+
466
+ ## 1.5.0
467
+
468
+ - `Pager` gains two additive, **default-off** props so a paged grid can read exactly like the
469
+ v1 AML console's `.ui-pager__info` line:
470
+ - `infoPrefix?: string` — an already-translated word prefixed to the count
471
+ (e.g. `"Showing"` → `Showing 1–50 of 3,023 leadership terms`).
472
+ - `boldNumbers?: boolean` — renders the three counts (from / to / total) in bold
473
+ `colors.text`, matching v1's `.ui-pager__info b`.
474
+ - **Backward-compatible**: with both props omitted the count line is byte-identical to before
475
+ (the concatenated text is unchanged even with `boldNumbers` on — bold is styling only), so
476
+ existing consumers (`/coverage`, aml-v2) are unaffected.
477
+
478
+ ## Unreleased
479
+
480
+ - **Pixel-perfect overrides** (additive, backward-compatible). The kit's defaults are
481
+ opinionated but never mandatory — a consumer that must match an existing look can now
482
+ do so without forking:
483
+ - `DataTable` gains `styleOverrides?: DataTableStyleOverrides` (slots: `wrap`, `headRow`,
484
+ `headCell`, `row`, `cell`, `numCell`, `state`, `stateText`, `rowDetail`, `card`,
485
+ `cardLine`, `cardLabel`, `cardValue`).
486
+ - `Pager` gains `styleOverrides?: PagerStyleOverrides` (slots: `pager`, `pagerInfo`,
487
+ `pagerNav`, `pagerRowsLabel`, `sizeGroup`, `control`, `controlText`, `sizePill`,
488
+ `sizePillText`).
489
+ - `FilterBar` gains `styleOverrides?: FilterBarStyleOverrides` (slots: `filters`,
490
+ `filtersSpacer`, `results`, `filtersActions`).
491
+ - Each slot is merged **LAST** into its style array, so an override beats the base
492
+ StyleSheet **and** the inline colour the component applies from `useUi().theme`
493
+ (colours are never in the StyleSheet in this kit).
494
+ - Documented: `stackBreakpoint={0}` disables the responsive card-stack (`width < 0` is
495
+ never true), for surfaces that never had one.
496
+ - Omit `styleOverrides` and every render is byte-identical to before (verified by test).
497
+
498
+ - `DataTable` — **expandable rows** (additive, backward-compatible). Two new optional props:
499
+ - `renderRowDetail?: (row: T) => React.ReactNode` — renders a full-width detail panel
500
+ (spanning every column) directly beneath a row, between it and the next row. Works in
501
+ the desktop grid *and* in the responsive card-stack.
502
+ - `expandedRowKeys?: readonly string[]` — the `keyExtractor` keys of the rows currently
503
+ expanded. Expansion is **controlled by the caller** (own the state, toggle from
504
+ `onRowPress`); the table keeps no internal expand state and adds no chevron.
505
+ - The panel gets a stable test id `${testID}-row-detail-${key}` (new helpers
506
+ `rowDetailTestID(tableTestID, key)` / `rowTestID(tableTestID, key)`), is exposed to
507
+ assistive tech as a labelled region (`accessibilityRole="summary"` +
508
+ the new `uiTables.rowDetail` translation key), and the row it belongs to reports
509
+ `aria-expanded` / `accessibilityState.expanded`.
510
+ - Omit both props and the table renders exactly as before: no extra DOM node, no extra
511
+ row props, no behaviour change for existing consumers.
512
+ - Unblocks kefi-web's audit log (before/after JSON snapshot panel) adopting `DataTable`.
513
+
514
+ ## 1.2.0
515
+
516
+ - `Pager` — new optional `unitLabel?: string` prop. When supplied it appends an
517
+ already-translated unit noun to the count line, e.g. `unitLabel="leadership terms"`
518
+ renders `1–50 of 3,023 leadership terms` (v1 parity). Backward-compatible: when the
519
+ prop is omitted (or empty) the count line stays the generic `from–to of N`,
520
+ byte-identical to prior behaviour.
521
+ - Test tooling — added `src/jest-dom.d.ts` so ts-jest picks up the
522
+ `@testing-library/jest-dom` matcher types (`toBeDisabled`, …) when type-checking each
523
+ test file (`jest.setup.ts` sits outside the `src/**` include). Fixes the `Pager` suite
524
+ failing to compile under the isolated ts-jest type-check.
525
+
526
+ ## 1.1.0
527
+
528
+ - `DataTable` — promoted from the `/coverage` RN-web POC and hardened into the shared,
529
+ tokenized grid (the `wwwroot/shared/GRID.md` contract):
530
+ - per-row `testID` + `accessibilityLabel`/`accessibilityHint`, pressable rows (`onRowPress`);
531
+ - all user-facing chrome routed through the UiProvider `t` (no literals) — falls back to
532
+ caller-supplied `loadingLabel`/`emptyLabel`;
533
+ - fixed the POC's double `col.render()` call in the desktop path (now rendered once per cell);
534
+ - added the rest of the GRID.md contract: `FilterBar`, `Pager` (page-info + Prev/Next +
535
+ rows-per-page), an optional `zebra` modifier, and a `stickyHeader`;
536
+ - responsive label:value card-stack via `useWindowDimensions` below `stackBreakpoint`;
537
+ - every colour from `@dloizides/design-tokens` via the `useUi()` theme — no hardcoded colours.
538
+ - Component tests (`DataTable`, `FilterBar`, `Pager`) added.
539
+
540
+ ## 1.0.0
541
+
542
+ Initial release (Capability Wave C1, batch 3).
543
+
544
+ - `StatCard` — extracted from the proven erevna ↔ katalogos duplication; shares the
545
+ `@dloizides/ui-feedback` UI context (`useUi`).
546
+ - `DataTable` / `StatGrid` intentionally NOT included yet — they exist only in kefi-web (n=1);
547
+ they'll be added when a 2nd consumer appears.