Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EuiDataGrid] Grids wrapped in a container with no set height & defaultHeight: 'auto' will render with 0 height in webkit browsers #8008

Open
cee-chen opened this issue Sep 6, 2024 · 0 comments

Comments

@cee-chen
Copy link
Member

cee-chen commented Sep 6, 2024

To Reproduce

  1. Open data_grid_row_heights.stories.tsx, and delete the following line:
    height={419} // Required by webkit browsers to not render with 0 height. TODO: Investigate why, this is likely a bug
  2. yarn storybook
  3. Go to http://localhost:6006/?path=/story/tabular-content-euidatagrid-rowheightsoptions-prop--auto in a non-Firefox browser
  4. The datagrid will render with a 0 body height:
    Image
  5. Compare to Firefox, where the datagrid renders as expected:
    Image

Expected behavior
The datagrid should be able to render with an auto/self-set height without needing a height specified or its parent container to have a specified height.

Minimum reproducible sandbox
Use our Storybook instead for easier repro

Additional context
There are several issues around EuiDataGrid and how it tries to "adapt" its height from its parent container. See also:

@cee-chen cee-chen changed the title [EuiDataGrid] Grids wrapped in a container with no set height with defaultHeight set to auto will render with 0 height in webkit browsers [EuiDataGrid] Grids wrapped in a container with no set height & defaultHeight: auto will render with 0 height in webkit browsers Sep 6, 2024
@cee-chen cee-chen changed the title [EuiDataGrid] Grids wrapped in a container with no set height & defaultHeight: auto will render with 0 height in webkit browsers [EuiDataGrid] Grids wrapped in a container with no set height & defaultHeight: 'auto' will render with 0 height in webkit browsers Sep 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant