-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
Resizable Pivot Table Data Columns #27725
Conversation
* move column widths to state * add drag resizing * only get initial header widths on row change * better column change handling * return if there are no valid rowIndexes * address review comments
fb78a2f
to
b369484
Compare
Notifying subscribers in CODENOTIFY files for diff 15ca786...836e91c.
|
Codecov ReportBase: 66.15% // Head: 66.12% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #27725 +/- ##
==========================================
- Coverage 66.15% 66.12% -0.04%
==========================================
Files 3249 3272 +23
Lines 94344 94806 +462
Branches 11975 12072 +97
==========================================
+ Hits 62413 62688 +275
- Misses 26963 27150 +187
Partials 4968 4968
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
# Conflicts: # frontend/src/metabase/visualizations/visualizations/PivotTable/PivotTable.tsx # frontend/src/metabase/visualizations/visualizations/PivotTable/PivotTableCell.tsx # frontend/src/metabase/visualizations/visualizations/PivotTable/types.ts # frontend/src/metabase/visualizations/visualizations/PivotTable/utils.ts
No failed tests 🎉 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wdyt about the feasibility of testing this? Such DnD things are harder to write tests for. It would not be valuable to have a barely maintainable test just to formally have it covered if it involves a poorly testable code while we don't have the capacity to refactor. Although, maybe we can mock cells here to trigger onResize
to verify updated widths? Or maybe a Cypress test would be more maintainable, what do you think?
column measurement in unit tests is pretty hacky, esp. since we don't have "real" pointer events. I added a good end-to end test that I think covers most of the cases here in the child branch: 9cb6f06fc7b47b9994416f974bb8d84dcb6511b1 |
resolves #27691
Description
Allow users to resize data/value columns manually. We do not even try to do any automated measuring of columns because there is a potentially enormous number of them.
Screenshots
Testing Steps
Open an enormous, gross pivot table like this one:
Remaining work to be done:
Persist column sizes: #27598