-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Tooltips crashing Chrome #2695
Comments
I noticed this as well. I run in to it daily. |
OK I think this might be isolated to Amazon Linux as I have tested on all these OS and browser combinations...
|
@Vampiro are you running Amazon Linux either on premises using virtualization, or in the AWS cloud, connecting through rdp. Just trying to figure out if it is the virtualization causing the issue? |
@melloware I'm running on Amazon Linux 2 with the MATE desktop environment in the AWS Cloud and connect to it via the Amazon Workspaces Client. I don't recall seeing any console errors while this was happening. Can't today, but tomorrow I can try to get a breakpoint in somewhere that would perhaps indicate what might be going on. |
Ahhh this is starting to make a lot more sense. Also what host OS are you using(Windows, Linux, Android, IOS), in case that matters? |
I am not sure what Amazon Workspaces uses to host the VMs from. I'm using Windows to launch the AWS client. |
Tested a bit more today.
tooltips-on-windows.mp4 |
I think I was leaning towards it's something to do with the virtualization using Amazon and the communication is somehow off notifying the window events or delayed slightly enough to cause the infinite loop. It seems on native OS and hardware it's impossible to reproduce. |
I think this is related to the issue that I see on non-virtualized Windows. That video from my last comment showed that if you hover over the border of the button on the side that the tooltip was on, it would cause a loop between mouseenter and mouseleave that would make the tooltip show/hide in rapid succession. I tested a bit more and this does not occur on any side that does not have the tooltip. Put the toolitp on the left and then the left border has this problem. I then took this information into the Amazon Linux virtualized environment and found that I can move over the button all day long without issue, but when I cross the border that has the tooltip on its side, there's a very real chance I get caught in the loop and crash. It might be because of the Linux/MATE gui environment, the hardware speed within that environment, or virtualization. The non-virtualized environment just seems to handle being on that border with a loop between mouseenter and mouseleave a little more gracefully (still spazzes, but doesn't crash). I think there's a good chance that if the issue that presents in non-virtualized Windows was fixed, this issue may be as well. |
Think this may perhaps be an issue with the tooltip slightly overlapping the button in some way. Tooltip comes up, mouse is over the tooltip instead, causing a Setting the following fixes the issue in non-virtualized Chrome for me as well as in the Amazon Linux 2 virtualized environment. .p-tooltip {
pointer-events: none;
} Edit: Don't know if that's the fix you want or if you want to offset the tooltip to be farther off the elements. In some tooltip examples, you have tooltips that you want to hover over/interact with and blanket setting |
OK but the problem I think with that solution of let me see if I can do something clever by only applying pointer-events:none in non-AutoHide scenario. |
OK @Vampiro check out my PR! |
@melloware Your PR fixed the issue in both the virtualized Amazon Linux 2 and non-virtualized Windows environments. Nice work! |
I'm submitting a ... (check one with "x")
Codesandbox Case (Bug Reports)
This is the standard issue template CodeSandbox with the tooltip prop added into the button.
https://codesandbox.io/s/primereact-test-forked-8619ry?file=/src/index.js
Current behavior
Tooltips will randomly cause an infinite loop and crash the browser.
Expected behavior
Browser doesn’t crash when tooltips appear.
Minimal reproduction of the problem with instructions
Move your mouse over an element with a tooltip several times.
primereact-tooltip-bug.mp4
Please tell us about your environment:
OS: Amazon Linux 2 (happens to multiple users). Note: Could not reproduce on Windows box.
React version:
16.8.0 (React version in PrimeReact issue template) and in 17 as well.
PrimeReact version:
7.2.0 (Happening on main PrimeReact webpage). Also happening in the CodeSandbox which appears to be on PrimeReact version 6.0.1.
Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
Google Chrome 99.0.4844.82 (64-bit). Has happened with lower versions of Chrome as well.
Could not reproduce in Firefox 89.
Language: [all | TypeScript X.X | ES6/7 | ES5]
All
The text was updated successfully, but these errors were encountered: