-
-
Notifications
You must be signed in to change notification settings - Fork 533
Tooltips do not disappear when I move cursor away from input field #777
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
Comments
I had to change this: const root = ReactDOM.createRoot(document.getElementById("root"));
root.render(<StrictMode>
<BrowserRouter basename={process.env.PUBLIC_URL}>
<Switch>
<StyledEngineProvider injectFirst>
<Route path="*" component={App} />
</StyledEngineProvider>
</Switch>
</BrowserRouter>
</StrictMode> to this: const root = ReactDOM.createRoot(document.getElementById("root"));
root.render(
<BrowserRouter basename={process.env.PUBLIC_URL}>
<Switch>
<StyledEngineProvider injectFirst>
<Route path="*" component={App} />
</StyledEngineProvider>
</Switch>
</BrowserRouter> In other words to remove Strict mode. |
Umm, yea, that's not productive. If you have a suggestion for improving, make it. None of the current maintainers are actively working on this component. If you want a fix, contribute a PR. |
Thanks for mentioning it @m21tomas I have the same issue :( |
Yeah! facing the same issue. |
Same my
|
are your really shaming someone who made something for free and you're using? |
Hi, I had the similar problem and removing really did help. But what I find strange is that the strict mode did not really noticed any errors made by the tooltip so I wonder where could be the problem. |
yes I did. Sorry for that. I won't blame anymore. |
yes It's Working |
Same here, and can confirm: Removing the strict mode makes the tooltips work again. However its not advised to disable the strict mode just to make a npm package work. For debugging: I think its somehow related to the eventOff and globalEventOff in react-tooltip. As far as I understood it from looking at the implementation real quick: theres a global custom event thats being listened on to decide when to hide the tooltip. Apparently its not being fired (or fired too often) when strict mode is on and thus the tooltip behaves weirdly. I somehow can't console.log from within node_module so I can't confirm my suspicion just yet. Should definitely be related to React 18's new strict mode though as functional components, initializiers and updaters are being run twice. Somehow the event catching does seem to break here. |
None of the current "maintainers" are actively developing web apps or this component. We need a community submitted PR to solve this problem. |
It looks like a similar issue was already fixed and merged (#755), but the npm package is not up to date with those changes? Can the npm package be updated? |
Alternatively, I tried switching to the npm package provided by pdeszynski in #786, and it is working properly for me with strict mode enabled. |
That's an excellent new. Does it work completely the same like Tooltip from [wwayne] and [aronhelser], but also icluding Strict mode? Same syntax and commands? |
@m21tomas I haven't thoroughly tested it myself, but since it has been submitted as an update for the react-tooltip package, it should support all of the same syntax and commands. |
Try setting |
same issue, any updates ? |
Did that |
yes I tried, |
Hi guys, the release v4.3.0 enables support for React 18 and Next.js strict mode, thanks to @pdeszynski. |
I've tested it on v4.3.1. |
I'm writing forms and I need to check if input is valid.

But right now I'm testing how your Tooltips work in general. It doesn't work properly for me. Either I'm doing smth wrong or your tooltip is wrong.
I have this code:
What is wrong with it?
Why the tooltip doesn't disappear when I move mouse cursor away?
Why does it remain forever?
That really annoys.
The text was updated successfully, but these errors were encountered: