-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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
Text in Tooltip component is blurry on secondary Retina Screen #12056
Comments
@Discordius As far as I know, we can do very little about how browsers render fonts. Any tips? |
Yeah, I am really not sure either. I looked into it for a few hours, didn't really find any fixes except deactivating hardware-accelerated rendering, and then decided I will probably just leave it as is since only a relatively small number of users will be affected. I then figured I would open an issue to let you know that I ran into the problem so you can keep track of it, but don't think it's super imperative to fix it. I increased the font-size on the affected font, which made the text at least readable on my device. |
@oliviertassinari This can be fixed by applying A lot of elements in Material UI suffer from the same issue in current master. |
@joarwilk I think that so far, we have decided to ignore the problem. Be careful with |
I'm still having this issue in Chrome, but weirdly only when I try to apply a Here's a workaround: .my-tooltip-class::after {
content: '';
filter: var(--my-drop-shadow);
display: block;
position: absolute;
inset: 0;
background: inherit;
border-radius: inherit;
z-index: -1;
}
.my-tooltip-class:not(.class-if-tooltip-has-arrow)::after {
margin: inherit;
} |
Expected Behavior
When using a tooltip component, on my secondary Retina screen, I expect the tooltip text to be sharp.
Current Behavior
Instead, when I use a Tooltip component and move the window to my second screen, the tooltip text turns out to be blurry. Here is a comparison (the second one is blurry):
Steps to Reproduce (for bugs)
Here is a minimal reproduction, in which the blurriness is less pronounced than in my production use-case, but still noticeable: https://codesandbox.io/s/wn9kjp753k
This is all probably related to this problem: https://keithclark.co.uk/articles/gpu-text-rendering-in-webkit/ Though I am unsure why this problem happens, since we are only translating in integer increments. There is some chance this happens because of the scale animation or something in that space, though I haven't been able to fix it.
Context
I've tried to use Tooltips on my site, but on my secondary screens they were basically unreadable at small text sizes. Here is an example:
Your Environment
The text was updated successfully, but these errors were encountered: