Package com.vaadin.flow.component.grid
Class GridI18n
java.lang.Object
com.vaadin.flow.component.grid.GridI18n
- All Implemented Interfaces:
Serializable
The internationalization properties for
Grid. This can be used to
customize and translate the accessible names used by the grid.- Since:
- 25.3
- Author:
- Vaadin Ltd.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the accessible name (aria-label) for the select all checkbox in the selection column header cell.Gets the accessible name announced for the selection column header cell when the select all checkbox is hidden (e.g. a data provider is used or conditional selection is enabled), rendered as a screen-reader-only label in the cell.Gets the accessible name (aria-label) template for the select row checkbox in each selection column body cell.Gets the accessible name (aria-label) template for the grid sorters.setSelectAll(String selectAll) Sets the accessible name (aria-label) for the select all checkbox in the selection column header cell.setSelectAllUnavailable(String selectAllUnavailable) Sets the accessible name announced for the selection column header cell when the select all checkbox is hidden (e.g. a data provider is used or conditional selection is enabled), rendered as a screen-reader-only label in the cell.setSelectRow(String selectRow) Sets the accessible name (aria-label) template for the select row checkbox in each selection column body cell.Sets the accessible name (aria-label) template for the grid sorters.
-
Constructor Details
-
GridI18n
public GridI18n()
-
-
Method Details
-
getSelectAll
Gets the accessible name (aria-label) for the select all checkbox in the selection column header cell.- Returns:
- the accessible name for the select all checkbox
-
setSelectAll
Sets the accessible name (aria-label) for the select all checkbox in the selection column header cell.- Parameters:
selectAll- the accessible name for the select all checkbox- Returns:
- this instance for method chaining
-
getSelectRow
Gets the accessible name (aria-label) template for the select row checkbox in each selection column body cell.- Returns:
- the accessible name template for the select row checkbox
-
setSelectRow
Sets the accessible name (aria-label) template for the select row checkbox in each selection column body cell. The{rowHeader}placeholder is replaced with the text content of the row's row-header cell (seeGrid.Column.setRowHeader(boolean)), or the 1-based row index when there is no row-header column.- Parameters:
selectRow- the accessible name template for the select row checkbox- Returns:
- this instance for method chaining
-
getSorter
Gets the accessible name (aria-label) template for the grid sorters.- Returns:
- the accessible name template for the sorters
-
setSorter
Sets the accessible name (aria-label) template for the grid sorters. The{column}placeholder is replaced with the column header text.- Parameters:
sorter- the accessible name template for the sorters- Returns:
- this instance for method chaining
-