Skip to content

Commit

Permalink
Changed radio instruction font from serif to sans serif (#604)
Browse files Browse the repository at this point in the history
## Summary:
Changed the style of the instructions in the base-radio component to be sans-serif
instead of serif.

Issue: LC-492

## Test plan:
- Ran `yarn storybook` and verified that the font is sans-serif
- Used npm image from PR as Perseus version in webapp and verified that the fonts work with a local frontend

<img src="https://github.com/Khan/perseus/assets/46005655/882d1de8-9571-4ecb-9f73-c1e523c99c33" alt="screenshot of a radio button exercise" width="500"/>

Author: eamspoker

Reviewers: nedredmond, jeremywiebe

Required Reviewers:

Approved By: nedredmond

Checks: ✅ finish_coverage, ✅ finish_coverage, ✅ Publish npm snapshot (ubuntu-latest, 16.x), ✅ Extract i18n strings (ubuntu-latest, 16.x), ✅ Lint, Typecheck, and Test (ubuntu-latest, 16.x), ✅ Cypress Coverage (ubuntu-latest, 16.x), ✅ Check builds for changes in size (ubuntu-latest, 16.x), ✅ Check for .changeset file (ubuntu-latest, 16.x), ✅ gerald, ✅ Jest Coverage (ubuntu-latest, 16.x), ✅ Publish npm snapshot (ubuntu-latest, 16.x), ✅ Lint, Typecheck, and Test (ubuntu-latest, 16.x), ✅ Extract i18n strings (ubuntu-latest, 16.x), ✅ Cypress Coverage (ubuntu-latest, 16.x), ✅ Jest Coverage (ubuntu-latest, 16.x), ✅ Check builds for changes in size (ubuntu-latest, 16.x), ✅ Check for .changeset file (ubuntu-latest, 16.x), ✅ gerald, ✅ finish_coverage, ✅ Extract i18n strings (ubuntu-latest, 16.x), ✅ Cypress Coverage (ubuntu-latest, 16.x), ✅ Publish npm snapshot (ubuntu-latest, 16.x), ✅ Lint, Typecheck, and Test (ubuntu-latest, 16.x), ✅ Check builds for changes in size (ubuntu-latest, 16.x), ✅ Jest Coverage (ubuntu-latest, 16.x), ✅ Check for .changeset file (ubuntu-latest, 16.x), ✅ gerald

Pull Request URL: #604
  • Loading branch information
eamspoker authored Jul 7, 2023
1 parent cc4bfe0 commit 9916bce
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 9 deletions.
5 changes: 5 additions & 0 deletions .changeset/ninety-rules-pretend.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@khanacademy/perseus": minor
---

Changed radio widget instruction font.
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ exports[`multi-item renderer should snapshot: initial render 1`] = `
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ exports[`group widget should snapshot: initial render 1`] = `
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ exports[`multi-choice question should snapshot the same when invalid: invalid st
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose all answers that apply:
</div>
Expand Down Expand Up @@ -612,7 +612,7 @@ exports[`single-choice question reviewMode: false should snapshot the same with
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down Expand Up @@ -1184,7 +1184,7 @@ exports[`single-choice question reviewMode: false should snapshot the same with
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down Expand Up @@ -1756,7 +1756,7 @@ exports[`single-choice question reviewMode: false should snapshot the same: firs
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down Expand Up @@ -2328,7 +2328,7 @@ exports[`single-choice question reviewMode: true should snapshot the same with c
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down Expand Up @@ -2900,7 +2900,7 @@ exports[`single-choice question reviewMode: true should snapshot the same with i
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down Expand Up @@ -3472,7 +3472,7 @@ exports[`single-choice question reviewMode: true should snapshot the same: first
</legend>
<div
aria-hidden="true"
class="instructions instructions_125m8j1"
class="instructions instructions_f9jkqj"
>
Choose 1 answer:
</div>
Expand Down
1 change: 1 addition & 0 deletions packages/perseus/src/widgets/radio/base-radio.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,7 @@ const styles: StyleDeclaration = StyleSheet.create({
color: styleConstants.gray17,
fontSize: 14,
lineHeight: 1.25,
fontFamily: "inherit",
fontStyle: "normal",
fontWeight: "bold",
marginBottom: 16,
Expand Down

0 comments on commit 9916bce

Please sign in to comment.