-
Notifications
You must be signed in to change notification settings - Fork 844
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
[EuiComboBox] add support for option tooltips #7700
[EuiComboBox] add support for option tooltips #7700
Conversation
src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx
Show resolved
Hide resolved
623e956
to
c580005
Compare
@mgadewoll Thanks so much with your patience waiting for my review on this, and for your amazing work with granular commits that made it super easy to follow!! My largest comments I'd like to see resolved are:
Everything other comment is just nice to have. I'll skip reviewing the EuiSelectable version of this PR as well (assuming it has similar-ish comments to the above) until this PR is settled and merged in if that's cool! |
759f203
to
685209d
Compare
ℹ️ I added baseline VRT references for |
Yasss that would be amazing! I reiterate that you are the best! |
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.
🚢 🎉 Thanks again for your awesome work on this Lene!!! My comments below are very optional lint type nits, feel free to ignore them and merge without, up to you
…/hide instead for options - dry out prop types - update tests
+ clean up comments + remove now-unnecessary setTimeout workaround, this one is stronker
-use const as type - revert newline changes
0b7cb47
to
9929c3e
Compare
Preview staging links for this PR:
|
💚 Build Succeeded
History
|
`v94.2.1-backport.0` ⏩ `v94.3.0` _[Questions? Please see our Kibana upgrade FAQ.](https://github.com/elastic/eui/blob/main/wiki/eui-team-processes/upgrading-kibana.md#faq-for-kibana-teams)_ --- ## [`v94.3.0`](https://github.com/elastic/eui/releases/v94.3.0) - Updated `launch` glyph for `EuiIcon` ([#7670](elastic/eui#7670)) - Updated `EuiComboBox`'s `options` to support including tooltip details for selectable options. Use `toolTipContent` to render tooltip information, and `toolTipProps` to optionally customize the tooltip rendering behavior ([#7700](elastic/eui#7700)) - Updated the following existing glyphs in `EuiIcon`: ([#7727](elastic/eui#7727)) - `error` (now an outlined version instead of filled) - `tokenMetricCounter` - `tokenMetricGauge` - Added the following new glyphs to `EuiIcon`: ([#7727](elastic/eui#7727)) - `tokenDimension` - `clickLeft` - `clickRight` - `clockCounter` - `errorFilled` (the previous `error` glyph design) - `warningFilled` **Bug fixes** - Fixed a visual layout bug for `EuiComboBox` with `isLoading` in mobile views ([#7700](elastic/eui#7700)) - Fixed missing styles on header cells of `EuiDataGrid` that prevented content text alignment styles to apply ([#7720](elastic/eui#7720)) - Fixed `EuiFlexGroup` and `EuiFlexItem` `ref` prop typing to support refs of the same type as the passed `component` type and allow `displayName` to be defined for easy component naming when using component wrappers like `styled()` ([#7724](elastic/eui#7724)) --- Most of the code changes you'll see in this PR are caused by the recent EuiFlex* changes making it generic. This, unfortunately, is something that `styled()` doesn't always like. I replaced the failing usages of `styled(EuiFlexGroup)` and `styled(EuiFlexItem)` to use `component` and other native EuiFlex* props, resulting in the same output but being better typed. We plan to add more props to EuiFlex* components giving developers control over properties like `flex-grow` and `flex-shring`, and reducing the need for writing any custom CSS when using these components. This should reduce the number of `styled()` wrappers needed even further --------- Co-authored-by: kibanamachine <[email protected]>
Summary
This PR is the first part of updates for #7690
This PR updates
EuiComboBox
to support the two propstoolTipContent
andtoolTipProps
to be passed to combobox options to display a tooltip on hover/focus.To ensure the tooltip can be opened on focus, the
EuiToolTip
was updated to a support controlled behavior viaisOpen
.QA
EuiComboBox
in storybook and docs and/or checkout this PR locally viagh pr checkout 7700
General checklist
@default
if default values are missing) and playground togglesChecked Code Sandbox works for any docs examplesIf applicable, added the breaking change issue label (and filled out the breaking change checklist)