web-components icon indicating copy to clipboard operation
web-components copied to clipboard

[grid] Optional radio button column for single-select mode

Open rolfsmeds opened this issue 4 years ago • 2 comments

A static radio-button column, corresponding to the checkbox column for multi-select, would be beneficial for single-select Grids in three ways:

  1. Visually indicates to the user that rows are (single) selectable in a way that is consistent with multi-select.
  2. Selection by clicking regular cells could be optionally disabled to prevent usability conflicts with interactive cell contents (e.g. buttons)
  3. Solves current issue with editable cells not usable for seletion in vaadin-grid-pro by providing a dedicated selection element.

rolfsmeds avatar Aug 06 '20 08:08 rolfsmeds

There is an example how to do this yourself here https://github.com/TatuLund/devday-demo-flow/blob/master/src/main/java/com/vaadin/devday/demo/views/GridView.java#L197 In addition to component column you need also extended radio button https://github.com/TatuLund/devday-demo-flow/blob/master/src/main/java/com/vaadin/devday/demo/views/GridView.java#L404

TatuLund avatar Oct 12 '20 05:10 TatuLund

This is a good suggestion for accessibility when a vaadin-grid only has editable component columns, e.g. TextFields.

andersforsell avatar Dec 17 '23 13:12 andersforsell