fix(v2): centre the md RSectionLabel icon on the capitals

Flex centres the icon on the text's line box, which keeps descender room
below the baseline that uppercase text never fills. At 12px that left the
icon about 1.25px below the caps; lifting it 1px brings every label icon
within a quarter pixel on average at 1x and 2x.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BYiFXo8o1n1wy9Zbd4AgYF
This commit is contained in:
Sam Dornan
2026-10-04 00:28:57 +00:00
committed by Claude
parent 1ea4e42541
commit b7fb3b820d

View File

@@ -63,8 +63,12 @@ withDefaults(defineProps<Props>(), {
color: var(--r-color-fg-secondary);
}
/* Whole-pixel glyph sizes keep the icon centred on the text. */
/* Whole-pixel glyph sizes keep the icon centred on the text. Flex centres
the icon on the line box, which reserves descender room the capitals
never use, so at md the icon lands about 1px below the caps. */
.r-section-label--md .r-section-label__icon {
position: relative;
top: -1px;
font-size: 14px;
}
.r-section-label--sm .r-section-label__icon {