-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Refactor: Bring Inter
and IBM Plex Mono
Fonts to Prod / Update Implementation
#10131
Refactor: Bring Inter
and IBM Plex Mono
Fonts to Prod / Update Implementation
#10131
Conversation
❌ ethereum-org-website-dev deploy preview failedYour build failed. View the build logs. |
✅ ethereum-org-website-dev deploy preview ready
|
a9518df
to
cc66785
Compare
As far as I could text, the new Inter font works really well!!! It improves a lot the readability. One question: We could keep the same monospace font family to avoid loading another font. @TylerAPfledderer @pettinarip , what do you think? |
Indeed I removed the stack for mono by mistake. I will gladly add it back in. Here is it's original location Also, I found this twitter post from the author of Inter with pairing suggestions with a mono typeface. At the very least, based on this I could put Roboto Mono to the top of the stack? |
But adding a new font will add to the load time? That was the main reason not to add a monospace font to the Design system. Do you think a new font, like IBM Plex, can be negligible on the total load time? (I prefer IBM plex to Roboto on pairing with inter) |
@nloureiro correct, we would want to ensure a font is available in the project here for build. If I'm not mistaken @pettinarip adding a font file locally should only add somewhere less than a kilobyte? If not way less! |
Not sure if I follow you on that. It will depend on how many fonts we want to add and the size of each one of them. https://github.com/IBM/plex/releases/tag/v6.3.0 this is the font we want to add, right? https://www.ibm.com/plex/ Questions @nloureiro:
If we are only going to support
Note: not sure the difference between 1, 2, and 3. Perhaps we could just use the |
Just Regular is fine. We don´t use any other weight on monospace. |
Cool! so, lets wait for @nloureiro's confirmation on what font we need to load and we can add them @TylerAPfledderer |
on my side I did some research on monospace fonts and I my take is to go with IBM plex mono regular. we just need regular and the .woff it's 39kb and it's acceptable for the overall loadtime It's going to be used mostly on code snippets so we can use only the Latin set. on the IBM plex github they recommend this I think we can just go with should be good for us and less code. my question: are there more places? that I did not found... |
Sounds good @nloureiro! Other parts where we are using the font are:
|
Interesting, all these sections that now have the monospace font, I already changed on the Design system. that being said, I don´t see any change in these examples on the deploy preview, I assume we are using other Font family calls for these examples Can you check where we are using it? |
@nloureiro hmm on the preview deploy for this PR, I don't see the old font definitions, I see this: Can you double-check that you are using the correct preview deploy link? |
yes, it's on the preview deploy. this is the lines that are supposed to be removed. That's why I think we declare the monospace font in other files |
@pettinarip @nloureiro can never forget that there is the old theme file that also contains the stack, and might (I guess only sometimes) rear its head! 😅 |
Right! That might be it!!!! In this case, I would say that we can move forward in adding the IBM Plex mono as a monospace font. I've added to the design system typography section @pettinarip do you think it's better to do it on this PR? or create a new one on top of this one? My take it's that once re touch the monospace family here, we might as well use this to add this font and QA all at the same time |
@nloureiro @pettinarip I'll at least push a commit to revert the original stack back into the Chakra config |
"system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif", | ||
body: "system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif", | ||
monospace: | ||
"SFMono-Regular, Consolas, 'Roboto Mono', 'Droid Sans Mono', 'Liberation Mono', Menlo, Courier, monospace", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should keep the monospace font family
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, agree
Thank you
Agree. Lets add it now and test all the font changes in this PR. @TylerAPfledderer how do you see doing this? |
@pettinarip I would include the new font the same as with Inter, having a CSS file in the Are you asking about testing as well? |
I think he is referring to add the new font to this PR, and I will Re-test all the pages to see if all is good. right? |
Correct @nloureiro and @TylerAPfledderer. Lets add the IBM font in this PR and then, Nuno and I, re-test everything again with the two fonts.
I think it will be best to have it in its own file, |
@pettinarip on it! |
Inter
Font to Prod / Update ImplementationInter
and IBM Plex Mono
Fonts to Prod / Update Implementation
@nloureiro @pettinarip this should be good to check with the new font! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've checked a lot of pages in various OSs and all looks good!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wohooo! lgtm thanks @TylerAPfledderer
cc @nloureiro merging this
Description
This PR does the following for the
Inter
font:Fonts
component in favor of a static CSS file of the font facesfonts
folderstatic
directory in Storybook to allow visibility of the Inter fontAlso adds the
IBM Plex Mono
font in regular weight for themonospace
font family stack