Skip to content

[EuiDataGrid] Add row height switcher to column #5080

@timroes

Description

@timroes

We discussed this briefly in our Discover sync yesterday and @snide suggested that it might make sense moving the row height toggle into EUI itself, since we might need this (in an aligned way) across different places in Kibana.

So we'd like to ask adding a row height switcher to the data grid, that looks similar to the following:

I think we need the following properties exposed on EUI to configure it from the outside:

  • initialRowHeight: 'auto' | 1 | 3 | 5 - to pass in which row height should be selected by default. I'd suggest we keep 1 as default if it's not passed in.
  • onRowHeightChanged(newVal: 'auto' | 1 | 3 | 5) - to get notified if the user changes the row height, since we'll be storing this in Discover with the saved search
  • (optional): maybe there are use-cases why the user would like to configure the available options, and would like to change the row heights options available, in which case we'd need to expose that too. Discover currently wouldn't have that requirement if we go with auto | 1 | 3 | 5.

cc @ryankeairns

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions