Minor Changes
-
#1192
065fe69Thanks @rezrah! - Improved typographic defaults for allTextandHeadinginstances.[!WARNING]
This release contains various breaking changes.
Review these notes carefully and validate the updated typography in your project before upgrading.-
TextandHeadingcomponents now apply a defaultfont-weightrange between410and525. This leads to an overall lighter typographic style in practice. -
All
Headingsizes above700are now smaller on the widest viewports. E.g.displaysize is now64pxinstead of96px. -
No sizes were removed in this update.
weightprop will continue to allow overriding as before. -
All
Headinginstances now usetext-wrap: balanceby default. This can be disabled using the newtextWrapprop. E.g.textWrap="none" -
Replaced
monospacesystem font with our proprietary Mona Sans Mono typeface for a consistent fixed width character set across OS's -
⚠️ Mona Sans font file location has been updated. The typeface has also been updated to the latest pre-release version and includes a newopszaxes for built-in optically-sized glyphs.If you were previously importing the font file directly from the package, please note its new location:
- @primer/react-brand/fonts/MonaSans.woff2 + @primer/react-brand/fonts/MonaSansVF[wdth,wght,opsz].woff2
-
A stylesheet for typography design tokens has been removed from the package. A replacement stylesheet with responsive values is available as a replacement.
- @primer/react-brand/lib/design-tokens/css/tokens/functional/typography/typography.cssPrefer:
+ @primer/react-brand/lib/design-tokens/css/tokens/functional/typography/typography-responsive.css
Additional components affected by changes to font weights:
ButtonComparisonTableEyebrowBannerFAQFormControlIDELabelLinkSectionIntroStackedSubNavSubdomainNavBarTabsTestimonialRiverRiverBreakout
-