opensearch-project / oui

OpenSearch UI Framework
Apache License 2.0
31 stars 65 forks source link

[OuiDataGrid][Proposal] Understand and Allow Auto fit and Customized Row Heights #1215

Open ananzh opened 5 months ago

ananzh commented 5 months ago

rowHeightsOptions implementation provides flexibility for handling various content types in the data grid, especially when dealing with varying amounts of data in cells, such as multiline text. We need to first understand current workflow.

OuiDataGrid component should be able to implement auto-fit row heights based on cell content, which is particularly useful for handling multiline or variable-sized content (#5227, #4859, #5404). To auto-fit rows based on content, the grid needs a way to measure the content of each cell. Once the content height is measured, the grid can adjust the row's height to fit the content.

We should also allow customers to customize row heights in a data grid through a toolbar interface (ex: row height), integrate with density. Then capture customer row height input and update Grid state.