Repository navigation
Commit 8d4a2e4
fix(md): keep the heading anchor clear of the heading text in every font
The `#` anchor floated at the heading's start with a fixed -0.87em
margin, so it stayed clear only while the glyph was at most 0.64em wide.
On fonts with a wider `#` (the Linux CI runner has one) it pushed the
heading text over by a few pixels, and the layout test from #811 failed
on main in both directions.
The anchor is now absolutely placed with its end edge on the heading's
start edge (`inset-inline-end: 100%`), so it never covers the text and
still mirrors on right-to-left pages. The layout test widens the `#`
with letter spacing, so it fails with the old rule on any machine.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>1 parent 13ca7fb commit 8d4a2e4
2 files changed
Lines changed: 7 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| 47 | + | |
47 | 48 | | |
48 | 49 | | |
49 | 50 | | |
| |||
162 | 163 | | |
163 | 164 | | |
164 | 165 | | |
| 166 | + | |
165 | 167 | | |
166 | | - | |
167 | | - | |
| 168 | + | |
| 169 | + | |
168 | 170 | | |
169 | 171 | | |
170 | 172 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
18 | 20 | | |
19 | 21 | | |
20 | 22 | | |
| |||
0 commit comments