Skip to content

Commit c415172

Browse files
authored
Remove duplicate font-weight fallbacks from utilities (#2430)
* remove double fallbacks * Create wicked-bananas-hammer.md
1 parent 713d9a5 commit c415172

File tree

2 files changed

+13
-8
lines changed

2 files changed

+13
-8
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@primer/css": patch
3+
---
4+
5+
Remove duplicate `font-weight` fallbacks from utilities

src/utilities/typography.scss

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
.h4,
6767
.h5,
6868
.h6 {
69-
font-weight: var(--base-text-weight-semibold, $font-weight-bold) !important;
69+
font-weight: $font-weight-bold !important;
7070
}
7171

7272
// Type utilities that match type sale
@@ -120,7 +120,7 @@
120120
/* Set the font size to 40px and weight to light */
121121
.f00-light {
122122
font-size: var(--h00-size-mobile, $h00-size-mobile) !important;
123-
font-weight: var(--base-text-weight-light, $font-weight-light) !important;
123+
font-weight: $font-weight-light !important;
124124

125125
@include breakpoint(md) {
126126
font-size: var(--h00-size, $h00-size) !important;
@@ -130,7 +130,7 @@
130130
/* Set the font size to 32px and weight to light */
131131
.f0-light {
132132
font-size: var(--h0-size-mobile, $h0-size-mobile) !important;
133-
font-weight: var(--base-text-weight-light, $font-weight-light) !important;
133+
font-weight: $font-weight-light !important;
134134

135135
@include breakpoint(md) {
136136
font-size: var(--h0-size, $h0-size) !important;
@@ -140,7 +140,7 @@
140140
/* Set the font size to 26px and weight to light */
141141
.f1-light {
142142
font-size: var(--h1-size-mobile, $h1-size-mobile) !important;
143-
font-weight: var(--base-text-weight-light, $font-weight-light) !important;
143+
font-weight: $font-weight-light !important;
144144

145145
@include breakpoint(md) {
146146
font-size: var(--h1-size, $h1-size) !important;
@@ -150,7 +150,7 @@
150150
/* Set the font size to 22px and weight to light */
151151
.f2-light {
152152
font-size: var(--h2-size-mobile, $h2-size-mobile) !important;
153-
font-weight: var(--base-text-weight-light, $font-weight-light) !important;
153+
font-weight: $font-weight-light !important;
154154

155155
@include breakpoint(md) {
156156
font-size: var(--h2-size, $h2-size) !important;
@@ -161,7 +161,7 @@
161161
/* Set the font size to 18px and weight to light */
162162
.f3-light {
163163
font-size: var(--h3-size-mobile, $h3-size-mobile) !important;
164-
font-weight: var(--base-text-weight-light, $font-weight-light) !important;
164+
font-weight: $font-weight-light !important;
165165

166166
@include breakpoint(md) {
167167
font-size: var(--h3-size, $h3-size) !important;
@@ -181,7 +181,7 @@
181181
// stylelint-disable-next-line primer/spacing
182182
margin-bottom: 30px;
183183
font-size: var(--h3-size, $h3-size);
184-
font-weight: var(--base-text-weight-light, $font-weight-light);
184+
font-weight: $font-weight-light;
185185
}
186186

187187
// Line-height variations
@@ -308,7 +308,7 @@
308308
}
309309

310310
.text-emphasized {
311-
font-weight: var(--base-text-weight-semibold, $font-weight-bold);
311+
font-weight: $font-weight-bold;
312312
}
313313

314314
// List styles

0 commit comments

Comments
 (0)