Repository navigation
0.8.0
Screen-reader pairings tested: none yet (issue #5).
Browsers: Chromium (the whole e2e suite, 1047 passed) and WebKit (Playwright's, not Safari:
516 passed, 10 skipped). Firefox: not run.
The pivot on the grid's level: titles and formats, a view and events, sorting, folding, choosing
the fields and filtering — each from the keyboard, each part of the view.
What breaks:
<opengrid-pivot>'s row-dimension headers — and its measure headers without a column
dimension — hold a sort button now, and a group's subtotal header a fold button; the direction
and fold marks arearia-hiddentext beside the names. A page that read a header's
textContentreads the mark too; read the button's firstspan, or what a reader hears.- Rust:
PivotQueryandValidatedPivotQueryhave new fields (sort;orders,sort), so a
struct literal needs them. The JSON form is unchanged for a pivot withoutsort.
Module sizes (brotli, just measure-modules): the elements 206.2 → 224.0 KiB, the engine
115.2 → 118.8 KiB; both bounds raised with their reasons in scripts/module-budget.txt.
Added
- Titles and formats in
<opengrid-pivot>(#104).
set_columnsgives a row dimension or a measure itstitle, andset_formatsformats
dimension values in the headers and measure cells, by field name or measure alias — as at the
grid and the table. NULL and the empty string keep their words in a header. Any option but
titleis reported in the status line.get_pivotstill exports raw names and values. - A view and events for
<opengrid-pivot>(#106).
get_view/set_viewread and write{ rows, columns, values }— the three attributes as one
value, set in one query — andopengrid-view-changereports every change of them.
opengrid-querynow fires after every pivot answer too.OpengridPivot'sview,
defaultViewandonViewChangeare typedPivotViewin React, Vue and Svelte;
get_view<PivotView>(pivot)in TypeScript.ViewChangeDetailandConnectiontake a type
parameter whose default is the grid's, so existing code compiles unchanged. - Sorting in
<opengrid-pivot>(#108).
Each level is ordered by its own values or by a measure over the whole row, ascending or
descending; subtotals stay after their group (new rule P9, with conformance cases on the local
engine, WebAssembly, PostgreSQL and the export). The pivot query takessort: [{ field, by?, direction }]— sent only when there is one — and the element asortattribute
that is part of its view. Row-dimension headers, and measure headers without a column
dimension, are sort buttons witharia-sort. On PostgreSQL a sorted pivot runs one query per
level instead of oneGROUPING SETSstatement. - Folding groups in
<opengrid-pivot>(#110).
With two row dimensions or more, a group's subtotal row header is a button with
aria-expandedthat folds the group's rows away and opens them again, without a new query.
The status line says it (groupCollapsed/groupExpanded); the folded groups are a
collapsedattribute, part of the view. New partsgroup-toggleandgroup-mark. - Choosing the fields of
<opengrid-pivot>(#112).
With thetoolbarattribute the reader chooses rows, the column and measures: per axis a
group of chips — move earlier/later, remove — and an add menu ("+ Row", "+ Column",
"+ Measure") offering what the page offers in the newfieldsandmeasuresattributes. No
dragging; the menu has the grid's keyboard. Each change is one view, one query. New parts
field-group,add-field,field-menu,chip-move, and twelve text keys (pivotToolbar,
addRow,fieldRemove, …). - Filtering
<opengrid-pivot>(#114).
Afilterattribute takes the wire's filter JSON and is part of the view; the filter acts on
the raw rows, before the pivot. Withtoolbarthe reader gets a "Filters" group: a field for an
expression in the grid's language (country = DE and qty ≥ 3) and a removable chip per clause,
plus "Remove all". The types come from a pivot the provider already answers (the pivot has no
schema of its own). Three new text keys:pivotFilters,pivotFilterLabel,pivotFilterHint.