-
Notifications
You must be signed in to change notification settings - Fork 144
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix: a11y - Improve accessibility readout for strike through shipping price @W-12627112@ #1892
Merged
Conversation
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
joeluong-sfcc
commented
Jul 11, 2024
@@ -210,6 +232,7 @@ export default function ShippingOptions() { | |||
textDecoration="line-through" | |||
color="gray.600" | |||
marginLeft={1} | |||
aria-hidden="true" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set aria-hidden="true"
so that the screen reader doesn't repeat the price as it would add confusion
Signed-off-by: Joel Uong <[email protected]>
Signed-off-by: Joel Uong <[email protected]>
shethj
previously approved these changes
Jul 15, 2024
adamraya
reviewed
Jul 16, 2024
packages/template-retail-react-app/app/pages/checkout/partials/shipping-options.jsx
Outdated
Show resolved
Hide resolved
adamraya
previously approved these changes
Jul 16, 2024
…/shipping-options.jsx Co-authored-by: Adam Raya <[email protected]> Signed-off-by: Joel Uong <[email protected]>
adamraya
approved these changes
Jul 16, 2024
shethj
approved these changes
Jul 16, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR improves the readout of the shipping options when there is a strikethrough price in the shipping options section on the checkout page. Previously there was no indication that there was a strike through price, so the screen reader would read both the current price and the strikethrough price.
Example: 'Free 1.99'
Now the screenreader explicitly states the original and current price:
Example: 'Originally 1.99, now Free'
Types of Changes
Changes
How to Test-Drive This PR
git checkout ju/a11y-shipping-options
Shipping Options
header making sure its in preview modecommand + option + shift + down arrow
and thenoption + control + a
in order to get the screen reader to start reading off the textOriginally ____, now _____
Checklists
General
Accessibility Compliance
You must check off all items in one of the follow two lists:
or...
Localization