najm-kit 2.11.12 → 2.11.14

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,5 +1,43 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.11.14 - 2026-09-04
4
+
5
+ - Added `defineNajmPreferences` to `najm-kit/server`: the language, theme, and
6
+ time-zone cookie contract every Najm application otherwise hand-writes across
7
+ three route handlers and a root layout. `handlers.language`, `handlers.theme`,
8
+ and `handlers.timeZone` export directly as Next.js `POST` handlers, and
9
+ `resolve(cookieStore, { languageFallback })` seeds the root layout. Pure Web
10
+ `Request`/`Response` and a structural cookie reader — no React, no Next import.
11
+ - Made it convention-first. A new application passes `{ i18n }` and nothing
12
+ else: `light` default theme, `light | dark` the only accepted modes, `UTC`
13
+ default zone, the canonical `TimeZoneInput` zones, `najm-ui-*` cookie names,
14
+ and `HttpOnly; SameSite=Lax; Path=/; Max-Age=31536000` cookies are all
15
+ defaults. Applications with published cookie names or another product default
16
+ override only those keys. No consumer-side theme guard or normalizer.
17
+ - Fixed the time-zone contract having two sources of truth. `TimeZoneInput`'s
18
+ values moved out of the component into `NAJM_TIME_ZONES`, a pure module now
19
+ read by the input, the resolver, and the POST handler alike, so a zone the
20
+ control offers can no longer be rejected by server validation. Applications
21
+ that pass custom `items` pass the same values as `timeZones`.
22
+ - Exported `NAJM_TIME_ZONES`, `NAJM_DEFAULT_TIME_ZONE`, `NajmTimeZone`, and
23
+ `NajmMode` from `najm-kit/server`, plus `NajmPreferenceLanguage<T>` and
24
+ `NajmPreferenceTimeZone<T>` inferred from a configured definition, so
25
+ consumers declare no language, theme, or time-zone alias of their own.
26
+ - Validated before normalizing in every handler: an unsupported value is a
27
+ `400` with a generic message and no `Set-Cookie`, never the default silently
28
+ written into a cookie. Malformed JSON, a non-object body, and a missing field
29
+ answer the same way, and no request content reaches the response.
30
+
31
+ ## 2.11.13 - 2026-09-04
32
+
33
+ - Fixed the documented `common.feedback.<field>` convention so all shared
34
+ loading, empty, error, forbidden, and not-found states resolve localized
35
+ labels without an application-owned `feedbackDefaults` key map. Missing
36
+ convention keys still fall back to the packaged English labels.
37
+ - Forwarded Najm i18n's missing-key fallback and language-direction resolver
38
+ through `NajmAppProvider`, keeping language changes reactive for partial
39
+ catalogs and non-Arabic RTL languages.
40
+
3
41
  ## 2.11.10 - 2026-09-03
4
42
 
5
43
  - Fixed the selected numbered `NTable` pagination button inheriting the regular
@@ -14,353 +52,353 @@
14
52
  correctly in both LTR and RTL layouts.
15
53
 
16
54
  ## 2.11.9 - 2026-08-30
17
-
18
- - Fixed card grids that paginate client-side rendering their entire dataset on
19
- one page. `useTable` pinned an uncontrolled paged card list to `data.length`,
20
- a branch that predates the container measurement added in 2.2.0 and was never
21
- reconciled with it: `calculatedCardPageSize` was measured and published, but
22
- only ever applied to a server-paginated grid. A 500-row list rendered 500
23
- cards on page one, reported a single page, and showed 500 as the current
24
- Rows/page value. The measured size is now applied to an uncontrolled card grid
25
- too, through the guards that already keep a server-paginated one stable —
26
- geometry bucketing, the per-container report budget, and the deferral until
27
- real cards have been measured. That loop is a property of the measurement
28
- rather than of fetching: page size decides which cards render, and rendered
29
- cards are what card height is measured from. Rendering every supplied row
30
- stays the behavior wherever there is nothing to measure against, so
31
- `dynamicHeight={false}` and a container that has not yet reported a layout are
32
- unchanged, and a controlled `pagination` prop or an explicit Rows/page choice
33
- still wins.
34
-
35
- ## 2.11.8 - 2026-08-28
36
-
37
- - Fixed `NContextMenu` leaving keyboard focus on its opener after the menu
38
- appeared. The first enabled action now receives focus, disabled actions are
39
- skipped, Arrow Up/Down wrap, Home/End jump to the bounds, Tab dismisses the
40
- menu, and Escape restores focus to the opener. Focused actions also receive
41
- the same visual treatment as hovered actions.
42
-
43
- ## 2.11.7 - 2026-08-17
44
-
45
- - Fixed date, combobox, and multiselect `FormInput` controls reaching the
46
- accessibility tree with no accessible name. These types render their trigger
47
- as a styled `div`, so the `<label for>` that `FormControl` wires up pointed at
48
- a non-labelable element and named nothing: screen readers announced an unnamed
49
- control, and `getByRole(..., { name })` could not resolve one. The form label
50
- now becomes the trigger's `aria-label`, and `DateInput` and `ComboboxInput`
51
- accept an explicit `ariaLabel` to override it. `select` keeps naming itself
52
- from `ariaLabel || placeholder`; renaming it would break consumers that select
53
- it by placeholder today.
54
- - Fixed `DateInput` rendering its popover trigger as a `div`. Radix only merges
55
- trigger props onto the child, so the control had no role, no tab stop, and no
56
- keyboard activation — it was unreachable without a mouse. It is now a real
57
- `<button type="button">`, which also keeps it from submitting the surrounding
58
- form when the calendar opens.
59
-
60
- ## 2.11.6 - 2026-08-15
61
-
62
- - Fixed `FormInput` dropping React Hook Form's native field binding for text,
63
- number, password, textarea, and time controls. These controls now forward
64
- their field name, composed blur handler, and focus ref to the actual native
65
- element, preserving browser form semantics, touched-state tracking, and
66
- programmatic focus without changing composite-control contracts.
67
-
68
- ## 2.11.5 - 2026-08-14
69
-
70
- - Fixed numbered lists staying on an invalid final page after a deletion or
71
- another mutation reduced the server total. Paged lists now clamp before
72
- slicing their row buffer, render the previous valid page immediately, and
73
- reconcile the controlled pagination state without showing a false empty
74
- state. A genuinely empty result still remains on page one.
75
- - Fixed panel feedback states stretching their icon, copy, and action across
76
- separate grid rows in tall table and dialog bodies. Panel content now stays
77
- together in one centered vertical stack with consistent spacing.
78
-
79
- ## 2.11.4 - 2026-08-12
80
-
81
- - Fixed server-paginated card grids briefly rendering at a placeholder-derived
82
- page size before correcting to the real card height. Card mode now waits for
83
- real rows and publishes the measured fit before their first paint; fixed-row
84
- table sizing remains immediate during loading.
85
-
86
- ## 2.11.3 - 2026-08-12
87
-
88
- - Fixed `NTable` replacing or clipping an explicit Rows/page choice when
89
- `dynamicHeight` was enabled. Automatic fit sizing still owns the initial page
90
- size; after the reader chooses a value, the table preserves it and scrolls
91
- its bounded body when the requested rows exceed the measured fit.
92
-
93
- ## 2.11.2 - 2026-08-11
94
-
95
- - Fixed `PasswordInput` forwarding native input attributes such as generated
96
- form IDs and ARIA metadata to the actual `<input>`, restoring programmatic
97
- label association for assistive technology and browser automation.
98
-
99
- ## 2.11.1 - 2026-08-11
100
-
101
- - Fixed `NajmThemeProvider` precedence so an explicit runtime `mode` overrides
102
- a preset stored in the design config. An explicit `preset` prop still wins,
103
- allowing deliberately fixed-preset subtrees without producing mixed light
104
- and dark application surfaces.
105
-
106
- ## 2.11.0 - 2026-08-10
107
-
108
- - Gave every keyboard-focusable primitive a visible focus ring, from one shared
109
- source: `focusRingClasses` and `focusRingWithinClasses`, exported from the
110
- root barrel so consumers stop hand-rolling app-level focus CSS. `TabsContent`
111
- is keyboard-focusable (Radix sets `tabIndex={0}`) and previously showed no
112
- indicator at all; `CollapsibleTrigger` now carries its own ring rather than
113
- relying on whatever it wraps. `BaseInput` paints the ring on the wrapper via
114
- `has-[:focus-visible]:`, which is what finally gives `NumberInput` and the
115
- multi-select trigger an indicator — both suppress the inner control's ring,
116
- so focusing the child element used to change only the border colour.
117
- - Fixed `Dialog` focus restoration. The opener is captured in
118
- `onOpenAutoFocus` and refocused on close when focus would otherwise land on
119
- `<body>`, so dismissing a dialog with Escape returns the keyboard to the
120
- control that opened it (WCAG 2.4.3) instead of stranding it at the top of
121
- the document. A caller that calls `preventDefault()` on the close event still
122
- owns focus entirely.
123
- - Added `NCredentialsCard`, a one-time handover surface for freshly generated
124
- secrets. Renders a description list of fields with monospaced, break-all
125
- values, an optional header icon that defaults to a check mark, an optional
126
- consumer `actions` slot, and a built-in Copy button. The Copy action resolves
127
- text through `copyText` when supplied or joins `${label}: ${value}` with
128
- `\n` in field order otherwise. The button is disabled while a clipboard
129
- write is pending; on success it swaps to a check icon and `copiedLabel`,
130
- on failure to a warning icon and `copyErrorLabel`, and either state reverts
131
- to idle after roughly two seconds. Header and field icons are marked
132
- decorative, status is announced through a polite `aria-live` region, and
133
- the Copy button renders before consumer actions so a Done-style dismiss
134
- stays the last tab stop. The component never rethrows: a missing
135
- `navigator.clipboard`, a rejected or synchronously thrown `writeText`, and
136
- a synchronously thrown `copyText` all land in the error state with
137
- `onCopyError` invoked. State updates and revert timers are guarded so
138
- unmounting during a pending copy, or starting a second copy while the
139
- first success state is still showing, never fire stale setters. Logical
140
- spacing properties keep the layout correct under `dir="rtl"` without a
141
- consumer override, and each value carries `dir="auto"` so it resolves its own
142
- text direction: credentials are weak-directionality strings, and inheriting an
143
- ambient `rtl` paints `+1 555 0100` as `0100 555 1+` and `p@ssw0rd!` as
144
- `!p@ssw0rd` while the DOM and the copied text stay correct. A genuinely Arabic
145
- value still renders right-to-left. Packaged English fallbacks ship for the three action
146
- labels only; every field label, title, and description is the consumer's
147
- text. Exported as `NCredentialsCard`, `NCredentialField`,
148
- `NCredentialsCardProps`, and `NCredentialsCardClassNames` from the root
149
- barrel and from `packages/najm-kit/src/components/data-display`.
150
- - Added a shared `surface` contract across `NLoadingState`, `NErrorState`, and
151
- `NEmptyState`. `inline` (default) preserves existing behavior; `panel` adds a
152
- centered minimum-height frame for table, card, dialog, and sheet bodies
153
- without a page gutter or a landmark; `page` uses the configured page
154
- spacing through `NPageLayout as="div"` so it never introduces a nested
155
- `<main>`. `NLoadingState.fullScreen` keeps precedence over `surface`.
156
- - Added `NForbiddenState` and `NNotFoundState` as first-class generic Kit
157
- components. Both default to the page surface, ship token-backed default
158
- icons (`ShieldOff`, `Compass`), and resolve title and description through
159
- the new provider defaults. Neither knows the dashboard URL, renders a Next
160
- `Link`, redirects, or writes route metadata.
161
- - Added `feedbackDefaults` to `NajmUIProvider`. It is inherited by
162
- `NajmNextUIProvider` and `NajmAppProvider` through TypeScript — no second
163
- adapter prop or translation source. Labels resolve through the existing
164
- structural `t` (most specific: explicit prop > literal default > translated
165
- key > packaged English). Generic error body copy and empty description
166
- deliberately have no packaged fallback so the no-provider render is
167
- unchanged.
168
- - Exported the new feedback components and props (`NLoadingStateProps`,
169
- `NErrorStateProps`, `NEmptyStateProps`, `NForbiddenStateProps`,
170
- `NNotFoundStateProps`, `NFeedbackSurface`, `NFeedbackDefaults`,
171
- `NFeedbackLabels`, `NFeedbackLabelKeys`, `NFeedbackIconSize`) from the root
172
- barrel and re-exported them directly from `najm-kit/app` so a Next Server
173
- Component route can render them without authoring a local `"use client"`
174
- wrapper. The root entry stays free of `"use client"` and continues to
175
- share a single `NFeedbackDefaultsContext` across `index` and the adapters.
176
-
177
- ## 2.10.0 - 2026-08-10
178
-
179
- - Added a shared, failure-aware media source chain for `NAvatar`, `NImage`, and
180
- the new Next-only `NNextImage` export. Sources reset cleanly when inputs or
181
- cache versions change, duplicate candidates are tried once, consumer event
182
- handlers are preserved, and failed avatars return to initials without a
183
- broken-image glyph.
184
- - `NAvatar` now uses a native lazy-loaded image so loading and error events are
185
- observable, keeps initials visible until the image paints, supports native
186
- `imageProps`, and actually tries `fallbackSrc` after a primary failure.
187
- - Added provider-level status badge defaults and the public
188
- `normalizeStatusToken` helper. Applications can configure translated status
189
- labels, colors, icons, look, shape, and size once while explicit badge props
190
- retain precedence.
191
- - Added `NNextImage` and `NNextImageProps` to `najm-kit/next` only, preserving
192
- Next Image `fill`, `sizes`, optimizer, and `unoptimized` controls without
193
- adding Next.js to the root runtime graph.
194
-
195
- ## 2.9.0 - 2026-08-09
196
-
197
- - Added `najm-kit/server`, a pure UI bootstrap loader. `createUiBootstrapLoader()`
198
- takes the application's own fetcher, endpoint paths, payload parsers, and
199
- factory values, then runs the resources concurrently, unwraps the `{ data }`
200
- envelope (or one the application selects), and falls back per resource so a
201
- branding outage never discards a valid appearance. Failures are reported
202
- through an optional structured `onDiagnostic` callback carrying resource,
203
- reason, path, and status — never a response body, header, cookie, or raw
204
- thrown value. A `fallback()` that throws stays a visible error. The entry
205
- imports no React, no Next.js, and no Node built-in, and re-exports
206
- `parseNajmDesignConfig` so an appearance payload can be parsed without
207
- reaching the root barrel.
208
- - Added `najm-kit/server/react`, the React Server Component adapter.
209
- `createReactServerUiBootstrap()` memoizes one bootstrap per request with
210
- React's `cache()` and derives the per-resource accessors from it, so a root
211
- layout, a nested layout, and a page share one resolution and one stable
212
- snapshot for the whole render. Resolution is request-scoped only: separate
213
- requests share no snapshot, failure, or diagnostic, and a transient outage is
214
- retried on the next request. The `browser` export condition resolves to a
215
- module that throws, so importing the adapter from a Client Component fails at
216
- build time instead of shipping the application's fetcher and factory values
217
- into a browser bundle.
218
- - The root `najm-kit`, `najm-kit/next`, and `najm-kit/app` entries are unchanged
219
- and do not reach either server entry.
220
-
221
- ## 2.8.2 - 2026-08-08
222
-
223
- - Added the framework-neutral `najm-kit/person-images` subpath. It ships a
224
- built-in resolver for `child`, `adult`, `parent`, and `family` roles with
225
- the seven WebP illustrations embedded as base64 data URLs, plus
226
- `createPersonImageResolver` so an application can declare its own role
227
- names (`teacher`, `student`, `doctor`, `driver`, …) and TypeScript catches
228
- unknown role strings at the call site. The root `najm-kit` entry stays
229
- unchanged and does not pull in the person images.
230
-
231
- ## 2.8.1 - 2026-08-08
232
-
233
- - Added schema-driven form development tools to `NajmAppProvider`. Passing
234
- `formDevTools` enables F8 filling for every `NForm` and `WizardForm` without
235
- an application helper or additional provider.
236
- - Added built-in Zod 4 form-value generation with per-form overrides for
237
- relation fields and other application-owned values. Existing explicit
238
- `devTools.enabled` and `devTools.fill` usage remains supported.
239
-
240
- ## 2.8.0 - 2026-08-08
241
-
242
- - Added server-safe `najm-kit/format` helpers for currency minor units,
243
- numbers, percentages, dates, times, relative time, tokens, local date inputs,
244
- and slugs. Client applications can use the same contract reactively through
245
- `NajmFormatProvider` and `useNajmFormat`.
246
- - Added the server-safe `najm-kit/pagination` offset protocol, including bounded
247
- page creation, total-aware continuation, probe-row continuation for APIs
248
- without totals, and query cleanup that preserves meaningful `false` and `0`.
249
- - Added the optional-peer `najm-kit/query` entry with offset infinite-query and
250
- responsive paged/card-list hooks, plus shared card-pagination adapters and
251
- localized continuation labels.
252
- - Extended `NajmAppProvider` with formatting locale, currency, and placeholder
253
- configuration so applications can bind language, time zone, and formatting
254
- without another host bridge provider.
255
- - Added shared media-query/card-viewport helpers and avatar-source utilities.
256
-
257
- ## 2.6.2
258
-
259
- - Added `NSidebarProvider` and `useNSidebar`, so sidebar state can be read from a distance. `NSidebar` renders beside the page content rather than around it, which left applications hand-rolling a context to hand `setMobileOpen` down to a page header — a wrapper component plus an aliased import at every call site. Wrap the shell in `NSidebarProvider` and `NPageHeader` now resolves both `onSidebarOpen` and `mobileBreakpoint` from it, so a header nested anywhere below renders a working mobile trigger with no props threaded to it. Also exports the `NSidebarContextValue` type.
260
- - `NSidebar` resolves its open and collapsed state as explicit prop → surrounding provider → internal state. Passing `collapsed`, `mobileOpen`, `onCollapsedChange`, or `onMobileOpenChange` keeps behaving exactly as before, and a sidebar with no provider around it still owns its own state, so this is additive for every existing consumer.
261
- - `logo` accepts a render prop, `({ collapsed, isMobile }) => ReactNode`, alongside the existing node. It receives the state the sidebar actually resolved — including whatever `autoCollapseAt` decided — which consumers previously had to approximate with their own responsive classes, guessing at a breakpoint the sidebar had already computed. The mobile drawer always reports `collapsed: false`, matching how it renders. Exported as `SidebarLogoRender`.
262
-
263
- ## 2.6.1
264
-
265
- - Fixed the non-card `NPageHeader` bleed never taking effect. 2.6.0 cancelled the page padding with the Tailwind utilities `-mt-[var(--najm-section-gap,0px)]` and `-mx-[var(--najm-page-gutter,0px)]`, which only work if the consuming app's Tailwind build happens to emit those arbitrary classes — they exist nowhere but inside this package's bundle, so a consumer could load a stylesheet without them and the header stayed exactly where it was. The offsets are inline styles now and no longer depend on the consumer's CSS pipeline.
266
-
267
- ## 2.6.0
268
-
269
- - Added `NThemePresets`, and wired it into `NThemeCustomizer` through `presets`, `selectedPresetId`, `presetsStatus`, `savedDesign`, `onPresetSelect`, `onPresetSave`, `onPresetDelete`, and `presetLabels`. The picker renders only when a host supplies both `presets` and `onPresetSelect`. It is presentational: the host owns where presets live and what saving one means, and selecting a row hands the design back so it can be previewed before anything is stored. Each row draws a swatch strip from the design's own `sidebar`, `primary`, `secondary`, `accent`, and `background` tokens; the selected row's check sits left in the success colour and per-row delete sits right. Omit `onPresetSave` or `onPresetDelete` to hide those controls. Deleting is pointer-only — Radix owns roving focus inside the listbox.
270
- - **`NPageHeader` in non-card mode is now flush.** It rendered as a full-bleed bar (`border-b`, no radius) but still sat inside the padding `NPageLayout` applies, so it floated below and inside the page gutter and its bottom rule never met the sidebar header's. It now cancels that padding, and its base height goes `min-h-12` → `min-h-14` to match `NSidebarHeader`. **Non-card page headers move up and out to the page edges, and grow 8px below `sm`.** Card mode is unchanged.
271
- - `NPageLayout` publishes its resolved spacing as `--najm-page-gutter` and `--najm-section-gap`. Descendants could not previously cancel the page padding: a design config resolves the gutter to a literal, so the pre-existing `--page-gutter` / `--section-gap` variables only ever held the fallbacks. Full-bleed children should negate these, with `0px` fallbacks so they stay inert outside `NPageLayout`.
272
- - Fixed `SelectInput` discarding `SelectItemType.icon`. The prop was declared but `renderItems` rendered the label alone, so every per-item icon was silently dropped. Items with an icon now render it before a truncating label; items without one are unchanged.
273
-
274
- ## 2.5.0
275
-
276
- - Added `NTableDefaultsProvider`, so an application supplies `paginationLabels` once instead of at every table. Labels merge per key, most specific first: a table's own `paginationLabels` override the provider's for the keys it sets, the provider covers the rest, and anything neither supplies falls back to the packaged English. Also exports `useNTableDefaults` and the `NTableDefaults` type.
277
- - `value` is passed through the provider unmemoized; memoize it in the caller, or every table below re-renders with the shell.
278
-
279
- ## 2.4.0
280
-
281
- - `NTablePagination` renders numbered page buttons instead of `Page X of Y`. The window shows the first and last page, the current page, and one page either side, collapsing the rest into at most two gaps. The slot count is constant for any result longer than the window, so the bar does not change width as the reader pages through it, and a gap never stands in for a single page — that slot goes to the page instead.
282
- - Added `paginationVariant`, defaulting to `"numbered"`. Pass `"compact"` to keep the previous position text with first/previous/next/last controls. **This changes the default appearance of every paginated `NTable`.**
283
- - The numbered variant drops the first/last double chevrons, because page 1 and page N are now single-click targets of their own. Previous and next remain. The compact variant is unchanged.
284
- - Numbered pages fall back to compact on their own when the page count is not trustworthy — that is, under `manualPagination` with no `pageCount` supplied, where TanStack infers a count from the rows it happens to hold rather than from a result total. Numbering that would invite clicks on pages that may not exist is not rendered.
285
- - Below the `sm` breakpoint the numbers give way to the position text; seven page buttons plus the rows-per-page select do not fit a phone.
286
- - Added `paginationLabels` so the bar can be localized: `rowsPerPage`, `pagination`, `goToPage`, `currentPage`, `firstPage`, `previousPage`, `nextPage`, `lastPage`, `pageOf`, and `rowsSelected`. All optional, all falling back to the previous English strings.
287
- - Pagination chevrons now mirror under `dir="rtl"`. They previously pointed against the reading direction in right-to-left layouts.
288
- - The page controls are wrapped in a labelled `nav`, and the current page carries `aria-current="page"`.
289
- - Exported `buildPageItems` and `NTablePageItem` for consumers that need the same windowing outside the table.
290
-
291
- ## 2.2.1
292
-
293
- - Fixed a regression in 2.2.0: the dynamic page size reported under `manualPagination` could oscillate. Card row height is measured from rendered cards, so it grows as images decode; feeding that back into the page size refetched, re-rendered, re-measured, and refetched again. A list visibly settled from one page size to another with the loading skeleton flashing twice. The report is now allowed once per container geometry, which does not depend on the rows inside it, so it terminates. A resize still re-arms it, and the debounce still waits for the measurement to settle before reporting.
294
-
295
- ## 2.2.0
296
-
297
- - Added `cardPagination` mode `infinite`: card lists continue on scroll instead of behind a button. No control and no end-of-list element render while the list is healthy. The continuation button appears only after an append failure, as the retry target.
298
- - Infinite continuation is owned by `NTableCards`, so the sentinel lives inside the card list's own `NajmScroll` viewport and uses it as the observer root. An appending page renders shaped card placeholders at the grid tail rather than a spinner in a fixed strip, and the polite `aria-live` announcement of appended row counts is preserved.
299
- - `cardPagination: { mode: "all" }` is now honored in table mode as well as cards: every supplied row renders and no pagination controls are shown.
300
- - `dynamicHeight` now takes effect under `manualPagination`. The measured page size is reported through the ordinary `onPaginationChange` callback, debounced, so server-paginated tables fill their container while the consumer keeps ownership of fetching. `maxHeight` stays caller-owned under manual pagination, and no page size is reported before the first measurement.
301
- - Added `calculateCardPageSize`, floored to whole card rows, published as `calculatedCardPageSize`. A card grid page no longer ends in a ragged partial row. This deliberately differs from `calculateCardSkeletonCount`, which ceils because overfilling placeholders is harmless.
302
- - Removed the deprecated `baseUrl` compiler option from the package tsconfig; `paths` resolves relative to the config file.
303
-
304
- ## 2.1.56
305
-
306
- - Honor `showIcon` on NTable `select` and `combobox` filters. The leading filter icon is still shown by default; pass `showIcon: false` on a filter to hide it.
307
-
308
- ## 2.1.55
309
-
310
- - Added controlled remote-search and loading-state props to `ComboboxInput` and `FormInput type="combobox"` while preserving client filtering by default.
311
-
312
- ## 2.1.53 - 2026-08-05
313
-
314
- - Add typed `NBarChart`, `NLineChart`, `NPieChart`, and `NStatusBreakdown`
315
- components with caller-formatted generic data, accessible summaries, empty
316
- states, responsive RTL-safe layouts, and shape-matched loading skeletons.
317
- - Default chart colors to the live `--chart-1` through `--chart-5` theme
318
- variables, cycle deterministically after five items, and retain explicit
319
- per-series/item color overrides.
320
- - Add preset and numeric chart diameter contracts to `NPieChart` and
321
- `NDonutCard`, including narrow-container shrinking without clipped legends.
322
- - Make `NDonutCard` item colors optional and add accessible loading states to
323
- `NDonutCard` and `NStatCard`.
324
- - Add public API tests, component tests, README guidance, and playground
325
- examples for the chart and loading contracts.
326
-
327
- ## 2.1.49 - 2026-08-04
328
-
329
- ### ImageInput and AvatarInput
330
-
331
- - Add `previewAlt`, `fallbackImage`, `fallbackAlt`, `unavailableContent`,
332
- `imageClassName`, `onPreviewError`, `replaceAriaLabel`, and `clearAriaLabel`
333
- to `ImageInputProps`. `AvatarInput` forwards every new prop unchanged.
334
- - Preview sources resolve in this priority order: `value`, `fallbackImage`,
335
- `defaultImage`. Candidate URLs are deduplicated so a failing primary URL is
336
- never retried through multiple stages. When every candidate fails, the
337
- broken `<img>` is unmounted and `unavailableContent` (or a neutral default)
338
- is rendered in its place.
339
- - `imageVersion` is appended safely to relative, absolute, queried, and
340
- fragmented URLs. `data:`, `blob:`, `javascript:`, and `file:` URLs are
341
- left unchanged.
342
- - Expose `data-image-input-state="empty" | "preview" | "fallback" | "unavailable"`
343
- on the preview container for styling, testing, and consumer diagnostics.
344
- - File selection is race-safe: stale `FileReader` completions cannot replace
345
- a newer value. Object URLs created by the component are tracked so
346
- consumer-owned blob URLs are never revoked.
347
- - Replace and clear controls are real `<button>` elements, are reachable
348
- with the keyboard, and stay visible on touch and coarse-pointer devices.
349
- Only on `(hover: hover) and (pointer: fine)` desktops do the controls fall
350
- back to a hover/focus reveal. `focus-visible` always restores visibility.
351
- - Use logical positioning (`end-*`) so the clear button works correctly in
352
- RTL layouts.
353
- - Re-export `ImageInputPreviewSource` and `ImageInputPreviewError` from
354
- `najm-kit/components/inputs` and the package root.
355
-
356
- ## 2.1.48 - 2026-08-04
357
-
358
- - Keep responsive card row actions visible on phone, tablet, and touch input,
359
- while retaining hover and keyboard-focus reveal on fine-pointer desktops.
360
- - Size table and card loading skeletons from the measured body and active grid,
361
- and keep loading borders, radius, color, and shadow aligned with loaded
362
- surfaces.
363
- - Add the exported `NTableCardPagination` and `NTableLoadMorePagination`
364
- contracts for paged, complete supplied-data, and explicit server-backed Load
365
- more card presentation, including guarded append/retry behavior and accessible
366
- loading, result, error, and terminal feedback.
55
+
56
+ - Fixed card grids that paginate client-side rendering their entire dataset on
57
+ one page. `useTable` pinned an uncontrolled paged card list to `data.length`,
58
+ a branch that predates the container measurement added in 2.2.0 and was never
59
+ reconciled with it: `calculatedCardPageSize` was measured and published, but
60
+ only ever applied to a server-paginated grid. A 500-row list rendered 500
61
+ cards on page one, reported a single page, and showed 500 as the current
62
+ Rows/page value. The measured size is now applied to an uncontrolled card grid
63
+ too, through the guards that already keep a server-paginated one stable —
64
+ geometry bucketing, the per-container report budget, and the deferral until
65
+ real cards have been measured. That loop is a property of the measurement
66
+ rather than of fetching: page size decides which cards render, and rendered
67
+ cards are what card height is measured from. Rendering every supplied row
68
+ stays the behavior wherever there is nothing to measure against, so
69
+ `dynamicHeight={false}` and a container that has not yet reported a layout are
70
+ unchanged, and a controlled `pagination` prop or an explicit Rows/page choice
71
+ still wins.
72
+
73
+ ## 2.11.8 - 2026-08-28
74
+
75
+ - Fixed `NContextMenu` leaving keyboard focus on its opener after the menu
76
+ appeared. The first enabled action now receives focus, disabled actions are
77
+ skipped, Arrow Up/Down wrap, Home/End jump to the bounds, Tab dismisses the
78
+ menu, and Escape restores focus to the opener. Focused actions also receive
79
+ the same visual treatment as hovered actions.
80
+
81
+ ## 2.11.7 - 2026-08-17
82
+
83
+ - Fixed date, combobox, and multiselect `FormInput` controls reaching the
84
+ accessibility tree with no accessible name. These types render their trigger
85
+ as a styled `div`, so the `<label for>` that `FormControl` wires up pointed at
86
+ a non-labelable element and named nothing: screen readers announced an unnamed
87
+ control, and `getByRole(..., { name })` could not resolve one. The form label
88
+ now becomes the trigger's `aria-label`, and `DateInput` and `ComboboxInput`
89
+ accept an explicit `ariaLabel` to override it. `select` keeps naming itself
90
+ from `ariaLabel || placeholder`; renaming it would break consumers that select
91
+ it by placeholder today.
92
+ - Fixed `DateInput` rendering its popover trigger as a `div`. Radix only merges
93
+ trigger props onto the child, so the control had no role, no tab stop, and no
94
+ keyboard activation — it was unreachable without a mouse. It is now a real
95
+ `<button type="button">`, which also keeps it from submitting the surrounding
96
+ form when the calendar opens.
97
+
98
+ ## 2.11.6 - 2026-08-15
99
+
100
+ - Fixed `FormInput` dropping React Hook Form's native field binding for text,
101
+ number, password, textarea, and time controls. These controls now forward
102
+ their field name, composed blur handler, and focus ref to the actual native
103
+ element, preserving browser form semantics, touched-state tracking, and
104
+ programmatic focus without changing composite-control contracts.
105
+
106
+ ## 2.11.5 - 2026-08-14
107
+
108
+ - Fixed numbered lists staying on an invalid final page after a deletion or
109
+ another mutation reduced the server total. Paged lists now clamp before
110
+ slicing their row buffer, render the previous valid page immediately, and
111
+ reconcile the controlled pagination state without showing a false empty
112
+ state. A genuinely empty result still remains on page one.
113
+ - Fixed panel feedback states stretching their icon, copy, and action across
114
+ separate grid rows in tall table and dialog bodies. Panel content now stays
115
+ together in one centered vertical stack with consistent spacing.
116
+
117
+ ## 2.11.4 - 2026-08-12
118
+
119
+ - Fixed server-paginated card grids briefly rendering at a placeholder-derived
120
+ page size before correcting to the real card height. Card mode now waits for
121
+ real rows and publishes the measured fit before their first paint; fixed-row
122
+ table sizing remains immediate during loading.
123
+
124
+ ## 2.11.3 - 2026-08-12
125
+
126
+ - Fixed `NTable` replacing or clipping an explicit Rows/page choice when
127
+ `dynamicHeight` was enabled. Automatic fit sizing still owns the initial page
128
+ size; after the reader chooses a value, the table preserves it and scrolls
129
+ its bounded body when the requested rows exceed the measured fit.
130
+
131
+ ## 2.11.2 - 2026-08-11
132
+
133
+ - Fixed `PasswordInput` forwarding native input attributes such as generated
134
+ form IDs and ARIA metadata to the actual `<input>`, restoring programmatic
135
+ label association for assistive technology and browser automation.
136
+
137
+ ## 2.11.1 - 2026-08-11
138
+
139
+ - Fixed `NajmThemeProvider` precedence so an explicit runtime `mode` overrides
140
+ a preset stored in the design config. An explicit `preset` prop still wins,
141
+ allowing deliberately fixed-preset subtrees without producing mixed light
142
+ and dark application surfaces.
143
+
144
+ ## 2.11.0 - 2026-08-10
145
+
146
+ - Gave every keyboard-focusable primitive a visible focus ring, from one shared
147
+ source: `focusRingClasses` and `focusRingWithinClasses`, exported from the
148
+ root barrel so consumers stop hand-rolling app-level focus CSS. `TabsContent`
149
+ is keyboard-focusable (Radix sets `tabIndex={0}`) and previously showed no
150
+ indicator at all; `CollapsibleTrigger` now carries its own ring rather than
151
+ relying on whatever it wraps. `BaseInput` paints the ring on the wrapper via
152
+ `has-[:focus-visible]:`, which is what finally gives `NumberInput` and the
153
+ multi-select trigger an indicator — both suppress the inner control's ring,
154
+ so focusing the child element used to change only the border colour.
155
+ - Fixed `Dialog` focus restoration. The opener is captured in
156
+ `onOpenAutoFocus` and refocused on close when focus would otherwise land on
157
+ `<body>`, so dismissing a dialog with Escape returns the keyboard to the
158
+ control that opened it (WCAG 2.4.3) instead of stranding it at the top of
159
+ the document. A caller that calls `preventDefault()` on the close event still
160
+ owns focus entirely.
161
+ - Added `NCredentialsCard`, a one-time handover surface for freshly generated
162
+ secrets. Renders a description list of fields with monospaced, break-all
163
+ values, an optional header icon that defaults to a check mark, an optional
164
+ consumer `actions` slot, and a built-in Copy button. The Copy action resolves
165
+ text through `copyText` when supplied or joins `${label}: ${value}` with
166
+ `\n` in field order otherwise. The button is disabled while a clipboard
167
+ write is pending; on success it swaps to a check icon and `copiedLabel`,
168
+ on failure to a warning icon and `copyErrorLabel`, and either state reverts
169
+ to idle after roughly two seconds. Header and field icons are marked
170
+ decorative, status is announced through a polite `aria-live` region, and
171
+ the Copy button renders before consumer actions so a Done-style dismiss
172
+ stays the last tab stop. The component never rethrows: a missing
173
+ `navigator.clipboard`, a rejected or synchronously thrown `writeText`, and
174
+ a synchronously thrown `copyText` all land in the error state with
175
+ `onCopyError` invoked. State updates and revert timers are guarded so
176
+ unmounting during a pending copy, or starting a second copy while the
177
+ first success state is still showing, never fire stale setters. Logical
178
+ spacing properties keep the layout correct under `dir="rtl"` without a
179
+ consumer override, and each value carries `dir="auto"` so it resolves its own
180
+ text direction: credentials are weak-directionality strings, and inheriting an
181
+ ambient `rtl` paints `+1 555 0100` as `0100 555 1+` and `p@ssw0rd!` as
182
+ `!p@ssw0rd` while the DOM and the copied text stay correct. A genuinely Arabic
183
+ value still renders right-to-left. Packaged English fallbacks ship for the three action
184
+ labels only; every field label, title, and description is the consumer's
185
+ text. Exported as `NCredentialsCard`, `NCredentialField`,
186
+ `NCredentialsCardProps`, and `NCredentialsCardClassNames` from the root
187
+ barrel and from `packages/najm-kit/src/components/data-display`.
188
+ - Added a shared `surface` contract across `NLoadingState`, `NErrorState`, and
189
+ `NEmptyState`. `inline` (default) preserves existing behavior; `panel` adds a
190
+ centered minimum-height frame for table, card, dialog, and sheet bodies
191
+ without a page gutter or a landmark; `page` uses the configured page
192
+ spacing through `NPageLayout as="div"` so it never introduces a nested
193
+ `<main>`. `NLoadingState.fullScreen` keeps precedence over `surface`.
194
+ - Added `NForbiddenState` and `NNotFoundState` as first-class generic Kit
195
+ components. Both default to the page surface, ship token-backed default
196
+ icons (`ShieldOff`, `Compass`), and resolve title and description through
197
+ the new provider defaults. Neither knows the dashboard URL, renders a Next
198
+ `Link`, redirects, or writes route metadata.
199
+ - Added `feedbackDefaults` to `NajmUIProvider`. It is inherited by
200
+ `NajmNextUIProvider` and `NajmAppProvider` through TypeScript — no second
201
+ adapter prop or translation source. Labels resolve through the existing
202
+ structural `t` (most specific: explicit prop > literal default > translated
203
+ key > packaged English). Generic error body copy and empty description
204
+ deliberately have no packaged fallback so the no-provider render is
205
+ unchanged.
206
+ - Exported the new feedback components and props (`NLoadingStateProps`,
207
+ `NErrorStateProps`, `NEmptyStateProps`, `NForbiddenStateProps`,
208
+ `NNotFoundStateProps`, `NFeedbackSurface`, `NFeedbackDefaults`,
209
+ `NFeedbackLabels`, `NFeedbackLabelKeys`, `NFeedbackIconSize`) from the root
210
+ barrel and re-exported them directly from `najm-kit/app` so a Next Server
211
+ Component route can render them without authoring a local `"use client"`
212
+ wrapper. The root entry stays free of `"use client"` and continues to
213
+ share a single `NFeedbackDefaultsContext` across `index` and the adapters.
214
+
215
+ ## 2.10.0 - 2026-08-10
216
+
217
+ - Added a shared, failure-aware media source chain for `NAvatar`, `NImage`, and
218
+ the new Next-only `NNextImage` export. Sources reset cleanly when inputs or
219
+ cache versions change, duplicate candidates are tried once, consumer event
220
+ handlers are preserved, and failed avatars return to initials without a
221
+ broken-image glyph.
222
+ - `NAvatar` now uses a native lazy-loaded image so loading and error events are
223
+ observable, keeps initials visible until the image paints, supports native
224
+ `imageProps`, and actually tries `fallbackSrc` after a primary failure.
225
+ - Added provider-level status badge defaults and the public
226
+ `normalizeStatusToken` helper. Applications can configure translated status
227
+ labels, colors, icons, look, shape, and size once while explicit badge props
228
+ retain precedence.
229
+ - Added `NNextImage` and `NNextImageProps` to `najm-kit/next` only, preserving
230
+ Next Image `fill`, `sizes`, optimizer, and `unoptimized` controls without
231
+ adding Next.js to the root runtime graph.
232
+
233
+ ## 2.9.0 - 2026-08-09
234
+
235
+ - Added `najm-kit/server`, a pure UI bootstrap loader. `createUiBootstrapLoader()`
236
+ takes the application's own fetcher, endpoint paths, payload parsers, and
237
+ factory values, then runs the resources concurrently, unwraps the `{ data }`
238
+ envelope (or one the application selects), and falls back per resource so a
239
+ branding outage never discards a valid appearance. Failures are reported
240
+ through an optional structured `onDiagnostic` callback carrying resource,
241
+ reason, path, and status — never a response body, header, cookie, or raw
242
+ thrown value. A `fallback()` that throws stays a visible error. The entry
243
+ imports no React, no Next.js, and no Node built-in, and re-exports
244
+ `parseNajmDesignConfig` so an appearance payload can be parsed without
245
+ reaching the root barrel.
246
+ - Added `najm-kit/server/react`, the React Server Component adapter.
247
+ `createReactServerUiBootstrap()` memoizes one bootstrap per request with
248
+ React's `cache()` and derives the per-resource accessors from it, so a root
249
+ layout, a nested layout, and a page share one resolution and one stable
250
+ snapshot for the whole render. Resolution is request-scoped only: separate
251
+ requests share no snapshot, failure, or diagnostic, and a transient outage is
252
+ retried on the next request. The `browser` export condition resolves to a
253
+ module that throws, so importing the adapter from a Client Component fails at
254
+ build time instead of shipping the application's fetcher and factory values
255
+ into a browser bundle.
256
+ - The root `najm-kit`, `najm-kit/next`, and `najm-kit/app` entries are unchanged
257
+ and do not reach either server entry.
258
+
259
+ ## 2.8.2 - 2026-08-08
260
+
261
+ - Added the framework-neutral `najm-kit/person-images` subpath. It ships a
262
+ built-in resolver for `child`, `adult`, `parent`, and `family` roles with
263
+ the seven WebP illustrations embedded as base64 data URLs, plus
264
+ `createPersonImageResolver` so an application can declare its own role
265
+ names (`teacher`, `student`, `doctor`, `driver`, …) and TypeScript catches
266
+ unknown role strings at the call site. The root `najm-kit` entry stays
267
+ unchanged and does not pull in the person images.
268
+
269
+ ## 2.8.1 - 2026-08-08
270
+
271
+ - Added schema-driven form development tools to `NajmAppProvider`. Passing
272
+ `formDevTools` enables F8 filling for every `NForm` and `WizardForm` without
273
+ an application helper or additional provider.
274
+ - Added built-in Zod 4 form-value generation with per-form overrides for
275
+ relation fields and other application-owned values. Existing explicit
276
+ `devTools.enabled` and `devTools.fill` usage remains supported.
277
+
278
+ ## 2.8.0 - 2026-08-08
279
+
280
+ - Added server-safe `najm-kit/format` helpers for currency minor units,
281
+ numbers, percentages, dates, times, relative time, tokens, local date inputs,
282
+ and slugs. Client applications can use the same contract reactively through
283
+ `NajmFormatProvider` and `useNajmFormat`.
284
+ - Added the server-safe `najm-kit/pagination` offset protocol, including bounded
285
+ page creation, total-aware continuation, probe-row continuation for APIs
286
+ without totals, and query cleanup that preserves meaningful `false` and `0`.
287
+ - Added the optional-peer `najm-kit/query` entry with offset infinite-query and
288
+ responsive paged/card-list hooks, plus shared card-pagination adapters and
289
+ localized continuation labels.
290
+ - Extended `NajmAppProvider` with formatting locale, currency, and placeholder
291
+ configuration so applications can bind language, time zone, and formatting
292
+ without another host bridge provider.
293
+ - Added shared media-query/card-viewport helpers and avatar-source utilities.
294
+
295
+ ## 2.6.2
296
+
297
+ - Added `NSidebarProvider` and `useNSidebar`, so sidebar state can be read from a distance. `NSidebar` renders beside the page content rather than around it, which left applications hand-rolling a context to hand `setMobileOpen` down to a page header — a wrapper component plus an aliased import at every call site. Wrap the shell in `NSidebarProvider` and `NPageHeader` now resolves both `onSidebarOpen` and `mobileBreakpoint` from it, so a header nested anywhere below renders a working mobile trigger with no props threaded to it. Also exports the `NSidebarContextValue` type.
298
+ - `NSidebar` resolves its open and collapsed state as explicit prop → surrounding provider → internal state. Passing `collapsed`, `mobileOpen`, `onCollapsedChange`, or `onMobileOpenChange` keeps behaving exactly as before, and a sidebar with no provider around it still owns its own state, so this is additive for every existing consumer.
299
+ - `logo` accepts a render prop, `({ collapsed, isMobile }) => ReactNode`, alongside the existing node. It receives the state the sidebar actually resolved — including whatever `autoCollapseAt` decided — which consumers previously had to approximate with their own responsive classes, guessing at a breakpoint the sidebar had already computed. The mobile drawer always reports `collapsed: false`, matching how it renders. Exported as `SidebarLogoRender`.
300
+
301
+ ## 2.6.1
302
+
303
+ - Fixed the non-card `NPageHeader` bleed never taking effect. 2.6.0 cancelled the page padding with the Tailwind utilities `-mt-[var(--najm-section-gap,0px)]` and `-mx-[var(--najm-page-gutter,0px)]`, which only work if the consuming app's Tailwind build happens to emit those arbitrary classes — they exist nowhere but inside this package's bundle, so a consumer could load a stylesheet without them and the header stayed exactly where it was. The offsets are inline styles now and no longer depend on the consumer's CSS pipeline.
304
+
305
+ ## 2.6.0
306
+
307
+ - Added `NThemePresets`, and wired it into `NThemeCustomizer` through `presets`, `selectedPresetId`, `presetsStatus`, `savedDesign`, `onPresetSelect`, `onPresetSave`, `onPresetDelete`, and `presetLabels`. The picker renders only when a host supplies both `presets` and `onPresetSelect`. It is presentational: the host owns where presets live and what saving one means, and selecting a row hands the design back so it can be previewed before anything is stored. Each row draws a swatch strip from the design's own `sidebar`, `primary`, `secondary`, `accent`, and `background` tokens; the selected row's check sits left in the success colour and per-row delete sits right. Omit `onPresetSave` or `onPresetDelete` to hide those controls. Deleting is pointer-only — Radix owns roving focus inside the listbox.
308
+ - **`NPageHeader` in non-card mode is now flush.** It rendered as a full-bleed bar (`border-b`, no radius) but still sat inside the padding `NPageLayout` applies, so it floated below and inside the page gutter and its bottom rule never met the sidebar header's. It now cancels that padding, and its base height goes `min-h-12` → `min-h-14` to match `NSidebarHeader`. **Non-card page headers move up and out to the page edges, and grow 8px below `sm`.** Card mode is unchanged.
309
+ - `NPageLayout` publishes its resolved spacing as `--najm-page-gutter` and `--najm-section-gap`. Descendants could not previously cancel the page padding: a design config resolves the gutter to a literal, so the pre-existing `--page-gutter` / `--section-gap` variables only ever held the fallbacks. Full-bleed children should negate these, with `0px` fallbacks so they stay inert outside `NPageLayout`.
310
+ - Fixed `SelectInput` discarding `SelectItemType.icon`. The prop was declared but `renderItems` rendered the label alone, so every per-item icon was silently dropped. Items with an icon now render it before a truncating label; items without one are unchanged.
311
+
312
+ ## 2.5.0
313
+
314
+ - Added `NTableDefaultsProvider`, so an application supplies `paginationLabels` once instead of at every table. Labels merge per key, most specific first: a table's own `paginationLabels` override the provider's for the keys it sets, the provider covers the rest, and anything neither supplies falls back to the packaged English. Also exports `useNTableDefaults` and the `NTableDefaults` type.
315
+ - `value` is passed through the provider unmemoized; memoize it in the caller, or every table below re-renders with the shell.
316
+
317
+ ## 2.4.0
318
+
319
+ - `NTablePagination` renders numbered page buttons instead of `Page X of Y`. The window shows the first and last page, the current page, and one page either side, collapsing the rest into at most two gaps. The slot count is constant for any result longer than the window, so the bar does not change width as the reader pages through it, and a gap never stands in for a single page — that slot goes to the page instead.
320
+ - Added `paginationVariant`, defaulting to `"numbered"`. Pass `"compact"` to keep the previous position text with first/previous/next/last controls. **This changes the default appearance of every paginated `NTable`.**
321
+ - The numbered variant drops the first/last double chevrons, because page 1 and page N are now single-click targets of their own. Previous and next remain. The compact variant is unchanged.
322
+ - Numbered pages fall back to compact on their own when the page count is not trustworthy — that is, under `manualPagination` with no `pageCount` supplied, where TanStack infers a count from the rows it happens to hold rather than from a result total. Numbering that would invite clicks on pages that may not exist is not rendered.
323
+ - Below the `sm` breakpoint the numbers give way to the position text; seven page buttons plus the rows-per-page select do not fit a phone.
324
+ - Added `paginationLabels` so the bar can be localized: `rowsPerPage`, `pagination`, `goToPage`, `currentPage`, `firstPage`, `previousPage`, `nextPage`, `lastPage`, `pageOf`, and `rowsSelected`. All optional, all falling back to the previous English strings.
325
+ - Pagination chevrons now mirror under `dir="rtl"`. They previously pointed against the reading direction in right-to-left layouts.
326
+ - The page controls are wrapped in a labelled `nav`, and the current page carries `aria-current="page"`.
327
+ - Exported `buildPageItems` and `NTablePageItem` for consumers that need the same windowing outside the table.
328
+
329
+ ## 2.2.1
330
+
331
+ - Fixed a regression in 2.2.0: the dynamic page size reported under `manualPagination` could oscillate. Card row height is measured from rendered cards, so it grows as images decode; feeding that back into the page size refetched, re-rendered, re-measured, and refetched again. A list visibly settled from one page size to another with the loading skeleton flashing twice. The report is now allowed once per container geometry, which does not depend on the rows inside it, so it terminates. A resize still re-arms it, and the debounce still waits for the measurement to settle before reporting.
332
+
333
+ ## 2.2.0
334
+
335
+ - Added `cardPagination` mode `infinite`: card lists continue on scroll instead of behind a button. No control and no end-of-list element render while the list is healthy. The continuation button appears only after an append failure, as the retry target.
336
+ - Infinite continuation is owned by `NTableCards`, so the sentinel lives inside the card list's own `NajmScroll` viewport and uses it as the observer root. An appending page renders shaped card placeholders at the grid tail rather than a spinner in a fixed strip, and the polite `aria-live` announcement of appended row counts is preserved.
337
+ - `cardPagination: { mode: "all" }` is now honored in table mode as well as cards: every supplied row renders and no pagination controls are shown.
338
+ - `dynamicHeight` now takes effect under `manualPagination`. The measured page size is reported through the ordinary `onPaginationChange` callback, debounced, so server-paginated tables fill their container while the consumer keeps ownership of fetching. `maxHeight` stays caller-owned under manual pagination, and no page size is reported before the first measurement.
339
+ - Added `calculateCardPageSize`, floored to whole card rows, published as `calculatedCardPageSize`. A card grid page no longer ends in a ragged partial row. This deliberately differs from `calculateCardSkeletonCount`, which ceils because overfilling placeholders is harmless.
340
+ - Removed the deprecated `baseUrl` compiler option from the package tsconfig; `paths` resolves relative to the config file.
341
+
342
+ ## 2.1.56
343
+
344
+ - Honor `showIcon` on NTable `select` and `combobox` filters. The leading filter icon is still shown by default; pass `showIcon: false` on a filter to hide it.
345
+
346
+ ## 2.1.55
347
+
348
+ - Added controlled remote-search and loading-state props to `ComboboxInput` and `FormInput type="combobox"` while preserving client filtering by default.
349
+
350
+ ## 2.1.53 - 2026-08-05
351
+
352
+ - Add typed `NBarChart`, `NLineChart`, `NPieChart`, and `NStatusBreakdown`
353
+ components with caller-formatted generic data, accessible summaries, empty
354
+ states, responsive RTL-safe layouts, and shape-matched loading skeletons.
355
+ - Default chart colors to the live `--chart-1` through `--chart-5` theme
356
+ variables, cycle deterministically after five items, and retain explicit
357
+ per-series/item color overrides.
358
+ - Add preset and numeric chart diameter contracts to `NPieChart` and
359
+ `NDonutCard`, including narrow-container shrinking without clipped legends.
360
+ - Make `NDonutCard` item colors optional and add accessible loading states to
361
+ `NDonutCard` and `NStatCard`.
362
+ - Add public API tests, component tests, README guidance, and playground
363
+ examples for the chart and loading contracts.
364
+
365
+ ## 2.1.49 - 2026-08-04
366
+
367
+ ### ImageInput and AvatarInput
368
+
369
+ - Add `previewAlt`, `fallbackImage`, `fallbackAlt`, `unavailableContent`,
370
+ `imageClassName`, `onPreviewError`, `replaceAriaLabel`, and `clearAriaLabel`
371
+ to `ImageInputProps`. `AvatarInput` forwards every new prop unchanged.
372
+ - Preview sources resolve in this priority order: `value`, `fallbackImage`,
373
+ `defaultImage`. Candidate URLs are deduplicated so a failing primary URL is
374
+ never retried through multiple stages. When every candidate fails, the
375
+ broken `<img>` is unmounted and `unavailableContent` (or a neutral default)
376
+ is rendered in its place.
377
+ - `imageVersion` is appended safely to relative, absolute, queried, and
378
+ fragmented URLs. `data:`, `blob:`, `javascript:`, and `file:` URLs are
379
+ left unchanged.
380
+ - Expose `data-image-input-state="empty" | "preview" | "fallback" | "unavailable"`
381
+ on the preview container for styling, testing, and consumer diagnostics.
382
+ - File selection is race-safe: stale `FileReader` completions cannot replace
383
+ a newer value. Object URLs created by the component are tracked so
384
+ consumer-owned blob URLs are never revoked.
385
+ - Replace and clear controls are real `<button>` elements, are reachable
386
+ with the keyboard, and stay visible on touch and coarse-pointer devices.
387
+ Only on `(hover: hover) and (pointer: fine)` desktops do the controls fall
388
+ back to a hover/focus reveal. `focus-visible` always restores visibility.
389
+ - Use logical positioning (`end-*`) so the clear button works correctly in
390
+ RTL layouts.
391
+ - Re-export `ImageInputPreviewSource` and `ImageInputPreviewError` from
392
+ `najm-kit/components/inputs` and the package root.
393
+
394
+ ## 2.1.48 - 2026-08-04
395
+
396
+ - Keep responsive card row actions visible on phone, tablet, and touch input,
397
+ while retaining hover and keyboard-focus reveal on fine-pointer desktops.
398
+ - Size table and card loading skeletons from the measured body and active grid,
399
+ and keep loading borders, radius, color, and shadow aligned with loaded
400
+ surfaces.
401
+ - Add the exported `NTableCardPagination` and `NTableLoadMorePagination`
402
+ contracts for paged, complete supplied-data, and explicit server-backed Load
403
+ more card presentation, including guarded append/retry behavior and accessible
404
+ loading, result, error, and terminal feedback.