eui icon indicating copy to clipboard operation
eui copied to clipboard

[EuiBasicTable] Add option to render metadata + bulk actions in header

Open sebelga opened this issue 3 years ago • 3 comments

As part of the work the improve UX for the <TableListView /> in Kibana (the page rendering the list of dashboards, visualisations, maps) we want to render a "selection info" bar on top of the <EuiBasicTable /> with the following functionalities

  • Display how many items are being viewed (e.g. "Showing 1-10 of 45 Dashboards")
  • Once one or multiple items are selected
    • Render a context menu to process bulk actions on the items
    • Render a button to select all the visible items in the table
    • Render a button to clear the selection

Design

Screenshot 2022-06-27 at 15 58 00

Bulk actions

Screen Shot 2022-06-27 at 11 07 27 AM

sebelga avatar Jun 27 '22 15:06 sebelga

I don't know that this provides enough value to bake into EuiBasicTable. It's additive to the table, but doesn't appear specific enough to tables to be built into the component, feels more standalone. The selection logic also looks like it disagrees with our approach where selection should only apply to the rows currently rendered.

As a concept, we agree on adding a toolbar component to EUI, captured by #3500 but we could use your use case there!

chandlerprall avatar Jun 27 '22 16:06 chandlerprall

I don't know that this provides enough value to bake into EuiBasicTable.

I disagree. Every table instance could benefit from displaying (at least) the row/count totals and the added ability to quickly deselect rows (if selection is enabled).

For sure this is part of the idea behind the toolbar component, though, and it's probably best to start there as a generic and then allow the table components to have them turned on/off.

cchaos avatar Jun 27 '22 18:06 cchaos

I don't mind building this feature for our need and if you see the value bring it to EUI. I wouldn't want the UX work of the table list in Kibana to be delayed until we agree on a generic toolbar for multiple purposes.

Seeing the length https://github.com/elastic/eui/issues/4010 it seems that we might be better starting in Kibana.

sebelga avatar Jun 28 '22 11:06 sebelga

Closing in favour of https://github.com/elastic/kibana/issues/140185 (we'll implement it initially for the Table list view)

sebelga avatar Sep 07 '22 12:09 sebelga