feat: implemented a tooltip for table column headers#2349
feat: implemented a tooltip for table column headers#2349nivzx wants to merge 13 commits intoh2oai:mainfrom
Conversation
mturoci
left a comment
There was a problem hiding this comment.
Thanks @nivzx!
- The tooltip is too far away from the icon.
- Hovering over icon shouldn't bring up pointer cursor since clicking the info icon triggers no action.
- The table column styling should remain intact.
- Please add a unit tests to verify that the info button with tooltip is only rendered when
tooltipprop is specified on a col. Columns without the prop should not render the info icon.
|
Fixed the styling issues. Will update the tests. Meanwhile please let me know your thoughts.
|
…the columns where `tooltip` option is specified.
mturoci
left a comment
There was a problem hiding this comment.
The table styling should remain intact as mentioned previously.
You can use our visual regression testing tool:
- Checkout main
make build-uicd tools/showcase && make visual-regression- chekout your feature branch
make build-uicd tools/showcase && make visual-regressionmake test-result.
See Makefile in tools/showcase for more info.
The tooltip is not centered, the icon is way too small and the spacing between other column icons is uneven.
Also, the tooltip probably needs either a border or slightly different background so that it's easier to spot:
Maybe needed for the rest of the tooltips as well so prefer generic solution.
Got it! I'll try to refine this further. Thanks! |
cc: @mturoci |
|
@marek-mihok can you please review this PR and verify it works/didn't break anything once you have some time? Not urgent. |
marek-mihok
left a comment
There was a problem hiding this comment.
LGTM! One small thing - when column is sortable, there is a gap between column title and tooltip until user activates sorting. Maybe we could show sort arrow for sortable columns right away?





The PR fulfills these requirements: (check all the apply)
mainbranch.feat: Add a button #xxx, where "xxx" is the issue number).Closes #xxx, where "xxx" is the issue number.uifolder, unit tests (make test) still pass.Closes #1792
Added a optional
tooltipparameter totable_columnThe column header with

tooltipproperty is displayed with a tooltip icon and the tooltip content is displayed when it's hovered.cc @mturoci