@zambon-dev/ui 1.8.0 → 1.9.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
@@ -27,6 +27,30 @@ packages are listed under [Package history](#package-history) at the end.
27
27
 
28
28
  ### ⚠ Breaking Changes / Migration
29
29
 
30
+ ## [1.9.0] - 2026-12-05
31
+
32
+ ### Added
33
+
34
+ - `lib-data-grid` follows the WAI-ARIA grid pattern, at row level. The header and rows have the `grid`, `row`, `columnheader` and `gridcell` roles, with `aria-rowindex`, `aria-rowcount` (from `totalRows` when the load returns it), `aria-selected` and, in a multi-select grid, `aria-multiselectable`. The new `gridLabel` setting names the grid for screen readers, as a translation key or plain text; it has no default.
35
+ - `lib-data-grid` works from the keyboard. The grid is one Tab stop: the focused row, or the first row. Arrow Up and Down, Home, End, Page Up and Page Down move between rows and make the row the dataset's focused row; a single-select grid selects it, as a click does. A row outside the rendered rows is scrolled into view and focused, and moving near the end loads the next block. Space selects or clears the row in a multi-select grid. Enter emits `rowActivated`, so the framework's Open button opens the record on Enter as it does on a double click. A disabled grid ignores the keys. The focused row shows a `--color-focus-ring` outline.
36
+ - `DataGridDataset.moveFocusedRow(key)` focuses a row the way the arrow keys do: it selects only in a single-select grid.
37
+ - Screen readers hear the grid's loading, lazy-load, empty and failure messages through a polite status region.
38
+ - Users can hide and show `lib-data-grid` columns. The new `columnChooser` grid setting adds a button at the end of the header that opens a list of the columns with a checkbox each, and a Reset columns button. The last visible data column cannot be hidden. New column props: `hidden` starts a column hidden, and `hideable: false` keeps one always visible; `actions` columns are not hideable unless they say so. The button and the reset have the new `columnChooserText` and `resetColumnsText` settings ("Choose columns" and "Reset columns", or the framework keys `Grid-Columns` and `Grid-ResetColumns`).
39
+ - Users can resize `lib-data-grid` columns. The new `resizableColumns` grid setting adds a handle at the end of each header cell, except on the selection and `actions` columns. Drag it, or focus it and press Arrow Left or Arrow Right to change the width by 16px; a double click gives the column its declared `size` back. Columns are at least 48px wide. The handle is a `separator` named by the new `resizeColumnText` setting ("Resize {{ column }}", or the framework key `Grid-ResizeColumn`).
40
+ - The new `columnsStateKey` grid setting keeps the hidden columns and the widths in `localStorage` under `zambon-dev.grid.{key}`, as `{ hidden, widths }` by column `field`, and restores them when the grid starts. Reset columns clears it.
41
+ - `DataGridDataset` has `visibleColumns`, `isColumnHidden`, `isColumnHideable`, `canHideColumn`, `setColumnHidden`, `getColumnWidth`, `setColumnWidth`, `resetColumns`, `restoreColumnsState` and `saveColumnsState`, to read and change the columns from code. `IGridColumnsState` and `MIN_GRID_COLUMN_WIDTH` are exported.
42
+
43
+ ### Changed
44
+
45
+ - The row checkbox of `lib-data-grid` is no longer a Tab stop (`tabindex="-1"`); keyboard users select with Space and open with Enter on the row. Row action buttons are Tab stops only in the grid's tabbable row, so Tab goes from that row to its actions, then out of the grid. The select-all checkbox stays a Tab stop.
46
+ - The selection cell of a `lib-data-grid` row is now a `div` with a `label` inside, instead of a `label`. Styles that targeted `label.cell.selection` need `.cell.selection` instead.
47
+ - The header and rows of `lib-data-grid` sit in a new wrapper with the `grid` class, inside a `grid-frame` wrapper, between the toolbar and the total. Each heading's text is in a `header-text` span. Styles that relied on `.header` or `.body` being direct children of the host need updating.
48
+
49
+ ### Fixed
50
+
51
+ - The focused `lib-data-grid` row now gets the `focused` class and its stronger border. The class never applied.
52
+ - A click on the edge of a row's selection cell, next to the checkbox, selects or clears the row once. It used to toggle it twice, so the row stayed as it was; with `selectOnClick: false` the checkbox showed ticked anyway.
53
+
30
54
  ## [1.8.0] - 2026-12-05
31
55
 
32
56
  ### Added
@@ -2794,7 +2818,8 @@ URL) in `AppConfig`, and implement a hub that pushes the notification list to cl
2794
2818
  available via [GitHub Releases](https://github.com/RicardoZambon/ZLibraries/releases) and the
2795
2819
  `shared-v*` tags.
2796
2820
 
2797
- [Unreleased]: https://github.com/RicardoZambon/ZLibraries/compare/ui-v1.8.0...HEAD
2821
+ [Unreleased]: https://github.com/RicardoZambon/ZLibraries/compare/ui-v1.9.0...HEAD
2822
+ [1.9.0]: https://github.com/RicardoZambon/ZLibraries/releases/tag/ui-v1.9.0
2798
2823
  [1.8.0]: https://github.com/RicardoZambon/ZLibraries/releases/tag/ui-v1.8.0
2799
2824
  [1.7.0]: https://github.com/RicardoZambon/ZLibraries/releases/tag/ui-v1.7.0
2800
2825
  [1.6.1]: https://github.com/RicardoZambon/ZLibraries/releases/tag/ui-v1.6.1
@@ -5657,7 +5657,10 @@ var FrameworkGridConfigsProvider = class FrameworkGridConfigsProvider extends Da
5657
5657
  totalRowsText: "Grid-TotalRows",
5658
5658
  totalRowText: "Grid-TotalRow",
5659
5659
  booleanTrueText: "Grid-Yes",
5660
- booleanFalseText: "Grid-No"
5660
+ booleanFalseText: "Grid-No",
5661
+ columnChooserText: "Grid-Columns",
5662
+ resetColumnsText: "Grid-ResetColumns",
5663
+ resizeColumnText: "Grid-ResizeColumn"
5661
5664
  });
5662
5665
  }
5663
5666
  static ɵfac = i0.ɵɵngDeclareFactory({