react-bootstrap-table2/docs/basic-row-select.md
2018-01-12 20:54:21 +08:00

1.8 KiB

id title sidebar_label
basic-row-select Row Selection Row Selection

For the table row selection functionality, the usage is almost same as react-bootstrap-table. If you are a user from legacy react-bootstrap-table, you can consider to skip this part.

Live Demo For Row Selection


Selection Mode

We support the single and multiple selection on table, config the selectRow.mode on BootstrapTable will enable the selection on the table.

By default behavior, user need to click on the selection column or the checkbox/radio to select/unselect a row, for a user experience perspective, we have selectoRow.clickToSelect to allow user to select/unselect row by clicking on the row.

Customization

Style/Class

Like column, we support to custom the style, class on the selecting row easily via following selectRow props:

Selection Column

react-bootstrap-table2 offer a selectRow.hideSelectColumn to let you hide the selection column. But for the customization on selection column or checkbox/radio button, we will support it ine next couple release. Coming Soon!

Event Listening

selectRow.onSelect allow you to listen a row is select or unselect. For the multiple selection, we also have selectRow.onSelectAll to listen the select/unselect all event.