What happens
TablePaginator's controls are icon-only, so their aria-label is their only accessible name, and the
defaults are English literals (dist/esm/DataTables/TablePaginator.js):
const labels = {
navigation: 'Pagination',
first: 'First page',
previous: 'Previous page',
next: 'Next page',
last: 'Last page',
...ariaLabels,
};
Evidence
@cratis/components 3.4.0. ariaLabels on TablePaginatorProps, surfaced as paginatorAriaLabels on the
table wrappers (DataTableForQuery, DataTableForObservableQuery), accepts overrides — and we now pass them
from our own localized strings on both admin tables.
So our present cost is zero, and we are saying so rather than dressing this up. It is recorded for
completeness, not as a blocker.
What it costs a consumer
A consumer that does not know the prop exists ships an English screen-reader experience by default, in every
locale, with nothing reporting it. The prop is the fix; the default is the trap.
Suggested fix — the seam
Default these from PrimeReactProps.locale when one is configured, keeping ariaLabels as the explicit
override. Same shape as the ask for the column filter overlay's chrome, which has no prop at all.
What is explicitly not being asked for
Not asking for translations to ship in this package, and not asking for the ariaLabels prop to change — it is
the right escape hatch. Only that the default not be a hardcoded language when the application has already told
PrimeReact which locale it is in.
What happens
TablePaginator's controls are icon-only, so theiraria-labelis their only accessible name, and thedefaults are English literals (
dist/esm/DataTables/TablePaginator.js):Evidence
@cratis/components3.4.0.ariaLabelsonTablePaginatorProps, surfaced aspaginatorAriaLabelson thetable wrappers (
DataTableForQuery,DataTableForObservableQuery), accepts overrides — and we now pass themfrom our own localized strings on both admin tables.
So our present cost is zero, and we are saying so rather than dressing this up. It is recorded for
completeness, not as a blocker.
What it costs a consumer
A consumer that does not know the prop exists ships an English screen-reader experience by default, in every
locale, with nothing reporting it. The prop is the fix; the default is the trap.
Suggested fix — the seam
Default these from
PrimeReactProps.localewhen one is configured, keepingariaLabelsas the explicitoverride. Same shape as the ask for the column filter overlay's chrome, which has no prop at all.
What is explicitly not being asked for
Not asking for translations to ship in this package, and not asking for the
ariaLabelsprop to change — it isthe right escape hatch. Only that the default not be a hardcoded language when the application has already told
PrimeReact which locale it is in.