Skip to content

Conversation

@sunyatasattva
Copy link
Contributor

@sunyatasattva sunyatasattva commented Aug 8, 2025

Default original price when a product is on sale (in del tag) was set to have an opacity of .5, which was resulting in low contrast and deemed inaccessible by even AA standards.

Bumping it to .65 ensures AAA-compliance.

Fixes woocommerce/woocommerce#59748

Screenshots

Screenshot 2025-08-08 at 16 12 13 Screenshot 2025-08-08 at 16 12 32

How to test the changes in this Pull Request:

  1. Activate the Storefront theme.
  2. Make sure you have at least one product on sale.
  3. Go to the shop page and notice the original price on the on sale product. Run an accessibility contrast test on the default colors and ensure AAA compliance.

Changelog

Fix – Ensures an AAA-compliant contrast ratio for original price when products are on sale.

This number ensures a contrast ratio of 7:1 with black text on white
background, ensuring AAA-compliance.
Copy link
Member

@dinhtungdu dinhtungdu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@github-actions github-actions bot added the status: ready to merge Automatically applied to a pull when a pull is approved. Indicates ready for merging. label Aug 11, 2025
@sunyatasattva sunyatasattva merged commit 44f4be8 into trunk Aug 11, 2025
7 checks passed
@sunyatasattva sunyatasattva deleted the wooplug-5069-accessibility-insufficient-color-contrast-on-del-tag branch August 11, 2025 19:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: accessibility The issue/PR is related to accessibility. status: ready to merge Automatically applied to a pull when a pull is approved. Indicates ready for merging.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Accessibility] Insufficient color contrast on <del> tag

3 participants