-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Description
Reproducer:
//! <div class="warning"></div>
Current output (FF 140.0.2, Linux, rustdoc 1.90.0 nightly 2025-07-30 3048886):

Expected output (copied over from #106561, only consider the icon not the rest):

I think this is a regression (on my machine) but I can't retroactively find a "good version". I've tried 1.74 (first stable version to include this feature) and 1.75 to no avail (it's not a circle). Maybe it's always been that way on my machine, I don't remember. I did remove the doc/
folder before trying a different version and I did hard-refresh.
The "i" is ⓘ, U+24D8 Circled Latin Small Letter I and I believe it's rendered with font Fire Sans, however I don't know how to confirm that using the FF dev-tools since I can't seem to inspect the computed style of pseudo elements. We do serve a local copy of Fira Sans if not available:
rust/src/librustdoc/html/static/css/rustdoc.css
Lines 73 to 80 in e3ee7f7
@font-face { | |
font-family: 'Fira Sans'; | |
font-style: normal; | |
font-weight: 400; | |
src: local('Fira Sans'), | |
url("FiraSans-Regular-0fe48ade.woff2") format("woff2"); | |
font-display: swap; | |
} |
And for me it should serve that copy since I don't have Fira Sans installed (fc-list | rg Fira
has empty output). Now, the font-face rule I've linked above declares the weight to be 400 which seems to check out with what I'm seeing. Then, I've checked how ⓘ (U+24D8) gets rendered per Fira Sans weight (https://fonts.google.com/specimen/Fira+Sans?preview.text=%E2%93%98) and that's what I'm seeing in my browser (image is edited to compact the data):

So whether the i is circled or surrounded by a squircle seems to depend on the weight (for everyone?) and since we pick a weight of 400, it's not a circle (for me). If we picked 300 or 600, it should render as circle.
I'm wondering tho, is it only me who has this issue? Since it renders like a squircle for me even on the introductory version 1.74 I feel like my setup is busted. What?