carbon: Tooltip - unable to control using *open* props
Tooltip - unable to control using open props
What package(s) are you using?
Same happens also for version 6.x:
-
carbon-components
- [ x]
carbon-components-react
Detailed description
Unable to control visibility state of the Tooltip (open/close), using already existing open prop. It could be easy observed using provided codesandbox.
What offering/product do you work on? Any pressing ship or release dates we should be aware of? We need this functionality in IBM SPSS Statistics. Tooltips are the last components we are trying to migrate from ap-components-react to Carbon.
Steps to reproduce the issue
- Assign Tooltip open prop to state variable (e.g. showTooltip).
- Change value of state variable (true->false, false->true)
- Result: Tooltip doesn’t react on changes on open prop.
Expected: Tooltip will react on change for open prop
Please create a reduced test case in CodeSandbox https://codesandbox.io/embed/codesandbox-lo5ox
Issue exists on both carbon-components-react versions 6.x and 7.x. We are expecting a fix for version 6.x.
It’s a blocking issue for us.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 44 (25 by maintainers)
Commits related to this issue
- fix(tooltip): unable to control using open prop Fixes #2849 — committed to tomkdgun/carbon by deleted user 5 years ago
A workaround may be force-remount technique.