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

feat: Add ResizeObserver to Grid and Chart #1626

Merged
merged 3 commits into from
Nov 7, 2023

Conversation

mofojed
Copy link
Member

@mofojed mofojed commented Nov 6, 2023

  • ResizeObserver is now widely available in all browsers, so use it to listen for resizing of our grid and plot elements
  • Pull grid-wrapper from IrisGrid and put it directly in Grid
    • Now Grid doesn't have to listen to the "parent" element, which was kind of strange in the first place.
  • Tested by opening up some tables and charts, resizing the panels and ensuring they updated correctly.

- ResizeObserver is now widely available in all browsers, so use it to listen for resizing of our grid and plot elements
- Pull `grid-wrapper` from `IrisGrid` and put it directly in `Grid`
  - Now `Grid` doesn't have to listen to the "parent" element, which was kind of strange in the first place.
- Tested by opening up some tables and charts, resizing the panels and ensuring they updated correctly.
Copy link

codecov bot commented Nov 6, 2023

Codecov Report

Attention: 18 lines in your changes are missing coverage. Please review.

Comparison is base (61d1a53) 46.71% compared to head (5570224) 46.70%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1626      +/-   ##
==========================================
- Coverage   46.71%   46.70%   -0.02%     
==========================================
  Files         583      584       +1     
  Lines       36308    36317       +9     
  Branches     9094     9098       +4     
==========================================
  Hits        16961    16961              
- Misses      19295    19304       +9     
  Partials       52       52              
Flag Coverage Δ
unit 46.70% <41.93%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
...s/dashboard-core-plugins/src/panels/ChartPanel.tsx 61.72% <ø> (+0.62%) ⬆️
...ashboard-core-plugins/src/panels/IrisGridPanel.tsx 43.05% <ø> (+0.07%) ⬆️
packages/iris-grid/src/IrisGrid.tsx 26.95% <100.00%> (-0.05%) ⬇️
packages/grid/src/Grid.tsx 64.67% <88.88%> (+0.16%) ⬆️
packages/chart/src/Chart.tsx 0.00% <0.00%> (ø)
packages/react-hooks/src/useResizeObserver.ts 0.00% <0.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mofojed
Copy link
Member Author

mofojed commented Nov 7, 2023

@mattrunyon updated so you can see the full error message from the UI:
image

@mattrunyon
Copy link
Collaborator

@mofojed Did you mean to comment that on #1614?

@mofojed
Copy link
Member Author

mofojed commented Nov 7, 2023

Right you are - updated the other PR.

@mofojed mofojed merged commit 35311c8 into deephaven:main Nov 7, 2023
6 checks passed
@mofojed mofojed deleted the resize-observer branch November 7, 2023 21:09
@github-actions github-actions bot locked and limited conversation to collaborators Nov 7, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants