| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Sorry, something went wrong.
📝 Walkthrough
WalkthroughThis pull request adds an experimental configuration flag to the Nuxt config file to disable local font fallbacks. The flag is inserted within the font configuration section and targets Firefox font rendering compatibility. ChangesFont configuration experimental flag
Possibly related PRs
Suggested reviewers
Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 error)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. ❤️ ShareComment @coderabbitai help to get the list of available commands and usage tips. |
Sorry, something went wrong.
|
Hello! Thank you for opening your first PR to npmx, @birkskyum! 🚀 Here’s what will happen next:
|
Sorry, something went wrong.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Sorry, something went wrong.
Sorry, something went wrong.
|
Previously, nuxt loaded fonts from the internet during build time, and in my PR, we changed it to use fonts stored in our repository. This PR changes what nuxt-fonts generates - it no longer uses fonts already installed on the user's system, but always loads them from our assets. On the one hand, we guarantee that the font will be exactly what we want, but on the other, it will depend only on our assets. Perhaps there's something else going on. In general, I think fontFallback is about a fallback font (like in nuxt/fontaine), not a priority font (as it is in nuxt/fonts). It seems like there might be an issue in the module itself. @danielroe wdyt? On Windows everything seems to work without problems Otherwise lgtm |
Sorry, something went wrong.
There was a problem hiding this comment.
Overall, it's lgtm, but I suggest waiting for another approval (see comment above)
Sorry, something went wrong.
Sorry, something went wrong.
There was a problem hiding this comment.
Is this just an issue with the 400 font weight? The tagline renders correctly in your screenshot, but the other text doesn't 🤔 This is also surely a bug in firefox? What version are you testing with?
Sorry, something went wrong.
|
Firefox version 151.0.3 (aarch64) for macOS |
Sorry, something went wrong.
There was a problem hiding this comment.
I couldn't find anything on this bug so this seems like the solution unfortunately
Sorry, something went wrong.
|
Thanks for your first contribution, @birkskyum! 💥 We'd love to welcome you to the npmx community. Come and say hi on Discord! And once you've joined, visit npmx.wamellow.com to claim the contributor role. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
🔗 Linked issue
resolves #2841
🧭 Context
Firefox on macOS renders the site's header text (logo, nav, "jump to..." button) noticeably thinner than Chrome. Reproducible on any machine with Geist or Geist Mono installed in ~/Library/Fonts/, which is pretty common since Vercel ships them with their dev tools.
The cause is the local() fallbacks in the auto-generated @font-face rules:
src: local("Geist Mono Regular"), local("Geist Mono"), url("/fonts/GeistMono-Regular.ttf") format(truetype);Chrome 86+ ignores local() for user-installed fonts as an anti-fingerprinting measure, so it falls through to the bundled TTF. Firefox honours it and picks up the local OTF. Same Geist family, but the OTF (CFF outlines) and TTF (TrueType outlines) rasterize differently in Firefox on macOS, and the OTF ends up lighter. Identical CSS, two different fonts actually rendered.
📚 Description
Sets fonts.experimental.disableLocalFallbacks: true in nuxt.config.ts. With it on, @nuxt/fonts stops emitting local(...) in the generated nuxt-fonts-global.css, so both browsers always load the bundled TTFs from public/fonts/.
Verified by checking the generated CSS no longer contains local(...) entries and that Firefox now matches Chrome after a hard reload.
Before ( macos w/ firefox ) - npmx.dev

After ( macos w/ firefox ) - localhost
