This repository was archived by the owner on Sep 30, 2024. It is now read-only.
Svelte: use Inter font for --font-family-base#63221
Merged
Merged
Conversation
Contributor
|
Caution License checking failed, please read: how to deal with third parties licensing. |
1 similar comment
Contributor
|
Caution License checking failed, please read: how to deal with third parties licensing. |
081bcc8 to
fa116f5
Compare
camdencheek
commented
Jun 12, 2024
Comment on lines
+618
to
+623
| - - :permit | ||
| - OFL-1.1 | ||
| - :who: | ||
| :why: Safe open font license | ||
| :versions: [] | ||
| :when: 2024-06-12 01:39:30.854523000 Z |
Member
Author
There was a problem hiding this comment.
Added the OFL license to the list of allowed licenses. This is not a risky license, we are not modifying the font, and we are distributing the license with our list of OSS dependencies.
fkling
approved these changes
Jun 12, 2024
fkling
left a comment
Contributor
There was a problem hiding this comment.
I'm not super familiar with fonts, but these changes seem pretty straightforward.
Contributor
There was a problem hiding this comment.
Are we importing this anywhere?
Member
Author
There was a problem hiding this comment.
Oh whoops. Leftover from a different attempt.
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This adds
Interas the preferred for--font-family-basein the Svelte webapp. Previously, we were using system fonts for our base font, which meant our web app looked different depending on the OS+browser.Instead of depending on the Google Fonts CDN, this uses Fontsource, which let us easily self-host Google Fonts (and other OSS fonts) just by importing an NPM package. No committing font files to git, and no dependency or connection to a 3rd-party server. The font itself weighs ~40KB for the full, variable-weight font.
Contributes to SRCH-445
Test plan
pnpm devandsg start, inspect element to ensure that we were rendering the new font, and check the network tab to ensure we weren't hitting the CDN and that the font wasn't super large. The