Thanks to visit codestin.com
Credit goes to github.com

Skip to content

chore(site): use variable font for inter #10903

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 27, 2023
Merged

Conversation

BrunoQuaresma
Copy link
Collaborator

Using variable fonts, we just need to import the font once to have access to all its weights making imports faster and flexibility to change the values at any time.

Copy link

@cdr-bot cdr-bot bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is a hotfix and has been automatically approved.

  • ✅ Base is main
  • ✅ Has hotfix label
  • ✅ Head is from coder/coder
  • ✅ Less than 100 lines

@@ -1,7 +1,7 @@
export const borderRadius = 8;
export const MONOSPACE_FONT_FAMILY =
"'IBM Plex Mono', 'Lucida Console', 'Lucida Sans Typewriter', 'Liberation Mono', 'Monaco', 'Courier New', Courier, monospace";
export const BODY_FONT_FAMILY = `"Inter", system-ui, sans-serif`;
export const BODY_FONT_FAMILY = `"Inter Variable", system-ui, sans-serif`;
Copy link
Member

@Parkreiner Parkreiner Nov 27, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to be on the safe side, I feel like it'd be good to include Inter as the second variable in the stack

We won't be serving it up, but if the user just happens to have it downloaded, they'll still get a pretty equivalent UI

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is too much to be honest since this font will be cached on the first load.

Copy link
Member

@Parkreiner Parkreiner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Just had a small suggestion for the font stack

@BrunoQuaresma BrunoQuaresma enabled auto-merge (squash) November 27, 2023 21:34
@BrunoQuaresma BrunoQuaresma merged commit 6808dae into main Nov 27, 2023
@BrunoQuaresma BrunoQuaresma deleted the bq/refactor-fonts branch November 27, 2023 21:35
@github-actions github-actions bot locked and limited conversation to collaborators Nov 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants