-
Notifications
You must be signed in to change notification settings - Fork 355
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
DropdownItem tooltip
not shown when isDisabled
#6102
Comments
@elad661 found the cause:
Indeed, disabling that CSS rule in the browser makes the tooltip appear for all actions. |
EDIT: which is exactly what the code tries to do: patternfly-react/packages/react-core/src/components/Dropdown/InternalDropdownItem.tsx Lines 193 to 200 in 9866c1a
|
Oh, I should have searched before opening new issue.
|
Describe the issue. What is the expected and unexpected behavior?
Actions with
tooltip
prop only show it when the action is enabled. When bothisDisabled
andtooltip
props are given, no tooltip shows.(My use case is action objects returned from Table with
actionResolver
, but I see that's all passed to regularDropdown
containingDropdownItem
and it also reproduces there, so let's focus onDropdownItem
.)Please provide the steps to reproduce. Feel free to link CodeSandbox or another tool.
https://codesandbox.io/s/crimson-snowflake-k2snz
The 2 enabled actions show tooltips on hover, the 2 disabled ones ignore the
tooltip
prop.I'd expect them to show the tooltip in both cases.
Is this a bug or enhancement? If this issue is a bug, is this issue blocking you or is there a work-around?
Bug. I don't know sure if this worked before, but we had code setting tooltips for disabled actions for a long time — to explain to users why the action is not available — and this is preventing users from seeing the explanations.
What is your product and what release version are you targeting?
OpenShift Cluster Manager, code using this is already in production.
The text was updated successfully, but these errors were encountered: