-
Notifications
You must be signed in to change notification settings - Fork 350
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conditionally switch decimal separator based on locale (#800)
## Summary: We were supposed to be switching between `,` and `.`, but we didn't see that through when updating how we're rendering icons for the v2 keypad. This updates that and adds some unit tests. <img width="386" alt="Screenshot 2023-11-14 at 10 21 29 AM" src="https://github.com/Khan/perseus/assets/16308368/0b70510d-7f5c-4735-8352-4ef1962f9774"> <img width="401" alt="Screenshot 2023-11-14 at 10 20 55 AM" src="https://github.com/Khan/perseus/assets/16308368/216d3787-24e9-49a5-9e4b-6f6ba8866803"> Issue: LC-1453 ## Test plan: - Use or simulate mobile web - Go to an exercise with a MathInput - Open the keypad by focusing the MathInput - Note a `.` as the decimal separator (if you're in the US) - Change your locale? - Use or simulate mobile web - Go to an exercise with a MathInput - Open the keypad by focusing the MathInput - Note a `,` as the decimal separator Author: handeyeco Reviewers: nedredmond, jeremywiebe, SonicScrewdriver Required Reviewers: Approved By: nedredmond Checks: ✅ codecov/project, ✅ codecov/patch, ✅ Upload Coverage, ✅ Publish npm snapshot (ubuntu-latest, 16.x), ✅ Lint, Typecheck, Format, and Test (ubuntu-latest, 16.x), ✅ Extract i18n strings (ubuntu-latest, 16.x), ✅ Cypress (ubuntu-latest, 16.x), ✅ Check for .changeset entries for all changed files (ubuntu-latest, 16.x), ✅ Publish Storybook to Chromatic (ubuntu-latest, 16.x), ✅ Check builds for changes in size (ubuntu-latest, 16.x), ✅ Jest Coverage (ubuntu-latest, 16.x), ✅ gerald Pull Request URL: #800
- Loading branch information
Showing
9 changed files
with
76 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@khanacademy/math-input": patch | ||
--- | ||
|
||
Bugfix: conditionally switch between period/comma for decimal separator |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters