Unquote the font-family var() references so the theme fonts apply (#714) - #718
Merged
prototypa merged 1 commit intoJul 23, 2026
Merged
Conversation
The quotes made each var() a literal family name, so the browser searched for a font called "var(--aw-font-sans, ui-sans-serif)", never found one, and fell through to the next family in the list. Inter never applied on any AstroWind site; the bug is easy to miss because the fallback is a plausible system sans. Fixes arthelokyo#714
This comment was marked as spam.
This comment was marked as spam.
prototypa
added a commit
that referenced
this pull request
Aug 4, 2026
Unquote the font-family var() references so the theme fonts apply (#714)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #714.
The bug
In
src/assets/styles/tailwind.cssthe three font tokens wrap theirvar()calls in quotes:A quoted string in
font-familyis a literal family name, not a substitution. The browser looks for a font actually namedvar(--aw-font-sans, ui-sans-serif), fails to find one, and falls through to the next family in the list — so--aw-font-sans(and its serif/heading siblings) never take effect, and the Inter set inCustomStyles.astronever renders. It goes unnoticed because the fallback is a reasonable system sans.The quoting belongs on the value —
CustomStyles.astroalready correctly declares--aw-font-sans: 'Inter Variable'— not on thevar()call.The fix
Remove the quotes around the three
var()references. One-line change each; no other behaviour is affected.Verification
Confirmed on a build of this template with a custom font in
CustomStyles.astro, using Chrome DevTools ProtocolCSS.getPlatformFontsForNodeto read the font the browser actually painted with (rather than the computedfont-familystring, which does not reveal the failed lookup):Segoe UI(fallback)Nunito Variable(the configured font)document.fonts.check('700 60px "Nunito Variable"')falsetrueThe variable-weight axis also renders correctly after the fix (rendered text width grows monotonically from weight 200 → 900), confirming the face is genuinely in use and not merely loaded.
Created by Claude Code