-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Use crispEdges rendering for octicon-internal-repo #11801
Conversation
CI failure unrelated |
So your theory is that this brower bug only triggers on odd widths only? |
Most likely with combination of font size/line height or specific positioning and size; for example I can not reproduce the issue on 32px for example. It's less visible on 24px but still can be noticed if two were stacked near each other. |
Interestingly can reproduce it on 30px but it's crisp on 32px (which is exactly double of 16px which is also broken) Might have to do something with this particular SVG, I don't know. This icon was added late in octicon lifecycle and looking at some issues on GitHub they might not even have original files for it. It's very possible that like in original Firefox issue, it's not about odd width but sub-pixel anti-aliasing and it just so happens that this icon is made in some unique way that causes it to manifest on certain resolutions. |
Just noticed that it's blurry on 32px but only when zoomed; except for multipliers of 100% such as 200% or 300% - on those it's crisp. |
Any drawback to using |
In the end adding this CSS rule for this icon only seems like a good compromise to me; it works in all cases I tested and doesn't affect anything else. We'll be able to remove it whenever we switch to new octicons (once they're out officially) or when we get to parsing octicon JSON (whichever is first I suppose). |
Oh, and does |
No, but I believe disabling anti-aliasing is what actually fixes it for this icon and it doesn't has any large rounded shapes so it's fine either way. |
* Use crispEdges rendering for octicon-internal-repo * Update _svg.less Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Came up in #11771 (comment)
Applied only to this specific octicon so that it doesn't interfere with others - that octicon is kinda special in a way that it's 13px, unlike others that are 10px, 12px or 14px.