Conversation
|
CI will be broken until the new tokens are available from protocol-tokens package |
1c22c80 to
1196cf9
Compare
| @supports (--css: variables) { | ||
| font-family: var(--title-font-family); | ||
| font-variant-ligatures: var(--title-font-ligatures); | ||
| font-weight: var(--title-font-weight); |
- [breaking] Zilla Slab font is removed for Mozilla rebrand fonts - [breaking] the font-mozilla mixin is removed in favor of more explicit font-mozilla-text and font-mozilla-headline
This approach ensures we have a common default (bold) across all themes that don't choose to set a custom font-weight
5289589 to
e993c57
Compare
|
This is ready for local code review and can be merged when updated with new tokens from Protocol Tokens PR: mozilla/protocol-tokens#114 DO NOT MERGE until tokens package is released and updated |
|
|
||
| @supports (--css: variables) { | ||
| font-family: var(--title-font-family); | ||
| font-variant-ligatures: var(--title-font-ligatures); |
There was a problem hiding this comment.
mozilla/bedrock#15790 (comment)
just noticed this comment on another PR, maybe best to use none as default here as well
| this font. | ||
| #### Mozilla Headline | ||
|
|
||
| * [Download from Github](https://github.com/mozilla/zilla-slab/releases/latest) |
There was a problem hiding this comment.
There's a repo https://github.com/mozilla/mozilla-type-family — however it still only houses pre-release versions.
Q: Is there any chance a prod-level asset will be provided at some point, perhaps adding more i18n support et al.?
There was a problem hiding this comment.
We are not expecting expanded character support 🙁
I will check and see if there is a more recent version.
There was a problem hiding this comment.
Updated with the final* versions.
- as much as anything on the web is ever final.
Co-authored-by: Jan Brasna <1784648+janbrasna@users.noreply.github.com>
|
@maureenlholland An update to the tokens package has been published. |
| } | ||
|
|
||
| @font-face { | ||
| font-family: text-fallback; |
| } | ||
|
|
||
| @font-face { | ||
| font-family: headline-fallback; |
There was a problem hiding this comment.
Helvetica Neue a tougher fallback font to adjust for. Defaults from https://highperformancewebfonts.com/tools/fafofal/ seemed equally off and manual adjustment on top of that hasn't been a huge improvement
There was a problem hiding this comment.
I don't think we need to stick with Helvetica Neue if we can get a better result with something else. Since this is a serif maybe Georgia? It seems to have good support across OSs.
@font-face {
font-family: fallback;
src: local("Georgia");
ascent-override: 90%;
descent-override: 25.5%;
line-gap-override: 0%;
size-adjust: 105.99%;
}
There was a problem hiding this comment.
Definitely worth a try!
There was a problem hiding this comment.
Suggested + Manual adjustments
font-family: headline-fallback;
src: local("Georgia");
ascent-override: 89.2%;
descent-override: 30.8%;
line-gap-override: 0%;
size-adjust: 99%;
This would mean our Headline stack becomes "'Mozilla Headline', 'Georgia', Arial, X-LocaleSpecific, sans-serif" in protocol-tokens package. I like the idea of having a serif fallback in this case, but I'm still on the fence about whether there's a meaningful improvement in fallback sizing compared to Helvetica Neue.
Slight preference is leaving Helvetica Neue for now, getting everything hooked into bedrock and doing a follow up refinement update if needed.
There was a problem hiding this comment.
👍
Okay, thanks for looking at it.
- Remove unused Bold MozillaHeadline
stephaniehobson
left a comment
There was a problem hiding this comment.
One thought after looking at the code: I'm curious for your thoughts on changing the fallback font for the headlines.
I'll test it on moz.org tomorrow.
| @supports (--css: variables) { | ||
| font-family: var(--title-font-family); | ||
| font-variant-ligatures: var(--title-font-ligatures); | ||
| font-weight: var(--title-font-weight, #{$default-font-weight}); |
| } | ||
|
|
||
| @font-face { | ||
| font-family: headline-fallback; |
There was a problem hiding this comment.
I don't think we need to stick with Helvetica Neue if we can get a better result with something else. Since this is a serif maybe Georgia? It seems to have good support across OSs.
@font-face {
font-family: fallback;
src: local("Georgia");
ascent-override: 90%;
descent-override: 25.5%;
line-gap-override: 0%;
size-adjust: 105.99%;
}
stephaniehobson
left a comment
There was a problem hiding this comment.
Spot checks in bedrock are good. Let's goooooooooo!
R+ 🖊️
| $font-stack-mozilla-text: "'Mozilla Text', Inter, 'Helvetica Neue', Arial, X-LocaleSpecific, sans-serif" | ||
| $font-stack-mozilla-headline: "'Mozilla Headline', Inter, 'Helvetica Neue', Arial, X-LocaleSpecific, sans-serif" |
There was a problem hiding this comment.
I missed this one:
| $font-stack-mozilla-text: "'Mozilla Text', Inter, 'Helvetica Neue', Arial, X-LocaleSpecific, sans-serif" | |
| $font-stack-mozilla-headline: "'Mozilla Headline', Inter, 'Helvetica Neue', Arial, X-LocaleSpecific, sans-serif" | |
| $font-stack-mozilla-text: "'Mozilla Text', 'Helvetica Neue', Arial, X-LocaleSpecific, sans-serif" | |
| $font-stack-mozilla-headline: "'Mozilla Headline', 'Helvetica Neue', Arial, X-LocaleSpecific, sans-serif" |
removed in protocol-tokens#116
(I'm preparing a tokens.config doc update and a changelog entry for tokens version bump so I'll include this fix with it…)








Description
This approach is the breaking change. It removes Zilla Slab token, font files, and mixin.
Fallback font adjustments used this tool: https://highperformancewebfonts.com/tools/fafofal/
Mozilla heading styles need
Mozilla body styles need
CHANGELOG.md.Related PR
Needs new Protocol Tokens package: mozilla/protocol-tokens#114 [WIP]
Issue
#1029
Testing
Run locally and check font updates in http://localhost:3000/docs/fundamentals/typography
Build package locally and update local package in Bedrock: mozilla/bedrock#16083
(After local install on Bedrock, I was manually moving the
mozilla-protocol/core/package/protocolfolder up to be directly insidecorefolder, there's probably a better way to do that)Check Mozilla branded pages have correct font styling
Check Firefox branded pages have correct font styling