Skip to content

Drop system-ui from the default body font stack - #42780

Merged
mdo merged 1 commit into
v6-devfrom
mdo/body-font-stack-no-system-ui
Aug 1, 2026
Merged

Drop system-ui from the default body font stack#42780
mdo merged 1 commit into
v6-devfrom
mdo/body-font-stack-no-system-ui

Conversation

@mdo

@mdo mdo commented Aug 1, 2026

Copy link
Copy Markdown
Member
  • Replace the --body-font-family value of system-ui with the full native font stack, minus system-ui: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif plus the four emoji fonts.
  • system-ui resolves to the user interface font of the locale, not to a neutral font. On Japanese Windows it becomes Yu Gothic UI, which draws bold Greek (Ω as и) and Simplified Chinese glyphs incorrectly, and which is too condensed for body text. The CSS Fonts 4 draft says the keyword is for application UI, not for articles.
  • Tailwind (#20318), Starlight (#3729), and VitePress (#4988) shipped the same change. Our stack now matches theirs, including the emoji fonts and the order that keeps Noto Sans ahead of Arial. Starlight's Linux tests showed that fontconfig aliases Arial to Liberation Sans and hijacks the match otherwise.
  • Keep both -apple-system and BlinkMacSystemFont. Chromium ignores -apple-system, and WebKit and Gecko ignore BlinkMacSystemFont. Do not add ui-sans-serif: only Safari reads it, and a future mapping could bring the same problem back.
  • Close the root-body-variables scss-docs marker, which had no end marker, and use it in the Reboot docs. The "Native font stack" section showed the removed v5 $font-family-sans-serif variable.
  • Point scss/_datepicker.scss and the CSS variables example at --body-font-family. Both used --font-sans-serif, which no v6 file defines.
  • Remove the semicolon inside the --font-mono string, which made the build print --bs-font-mono: ...monospace;;.

Fixes #42703

system-ui resolves to the user interface font of the locale, not to a
neutral font. On Japanese Windows it becomes Yu Gothic UI, which draws
bold Greek and Simplified Chinese glyphs incorrectly, and which is too
condensed for long text. The keyword is made for application UI, not for
articles.

--body-font-family now uses the full v5 native font stack without
system-ui. Tailwind, Starlight, and VitePress made the same change.

Also point the datepicker and the CSS variables example at
--body-font-family. Both referenced --font-sans-serif, which no v6 file
defines. Remove the semicolon inside the --font-mono string, which made
the build print a duplicate semicolon.

Fixes #42703
@mdo mdo added the docs label Aug 1, 2026
@mdo
mdo requested a review from a team as a code owner August 1, 2026 04:09
@mdo mdo added this to v6.0.0 Aug 1, 2026
@github-project-automation github-project-automation Bot moved this to Inbox in v6.0.0 Aug 1, 2026
@mdo
mdo merged commit 7061a93 into v6-dev Aug 1, 2026
12 checks passed
@mdo
mdo deleted the mdo/body-font-stack-no-system-ui branch August 1, 2026 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Inbox

Development

Successfully merging this pull request may close these issues.

1 participant