Support strike through in product buttons - #16705
Merged
Merged
Conversation
andrewHEguardian
commented
Sep 9, 2026
| @@ -0,0 +1,37 @@ | |||
| import { render } from '@testing-library/react'; | |||
Contributor
Author
There was a problem hiding this comment.
Disclosure: copilot mostly wrote these tests
|
Hello 👋! When you're ready to run Chromatic, please apply the You will need to reapply the label each time you want to run Chromatic. |
🚀 Image pushed to AWS ECRImage digest: 🐛 Run the image locallyThe following can be used to run the image locally: # Refer to image using the immutable digest. Find alternatives below.
IMAGE_IDENTIFIER="@sha256:3e414a88dba9696aa4acf5d4ac8d9b1f7bf799731468d29169e2c31c1a32b6b6"
# Refer to image using branch tag
# IMAGE_IDENTIFIER=":branch-ahe-product-button-strike-through"
# Refer to image using build tag
# IMAGE_IDENTIFIER=":build-31112"
# Refer to image via the GitHub commit SHA tag
# IMAGE_IDENTIFIER=":sha-4729bfb7932b733a57539f6d6bb4eb5d706444b0"
# Set environment variables for the AWS CLI
AWS_PROFILE="<A_PROFILE_FROM_JANUS>"
AWS_DEFAULT_REGION="eu-west-1"
IMAGE_ACCOUNT_ID=$(aws ssm get-parameter --name /organisation/accounts/artifacts --query "Parameter.Value" --output text)
REGISTRY="${IMAGE_ACCOUNT_ID}.dkr.ecr.${AWS_DEFAULT_REGION}.amazonaws.com"
IMAGE="${REGISTRY}/guardian/dotcom-rendering${IMAGE_IDENTIFIER}"
# Login to AWS ECR https://docs.aws.amazon.com/AmazonECR/latest/userguide/registry_auth.html
aws ecr get-login-password | docker login --username AWS --password-stdin $REGISTRY
# Pull the image
docker pull $IMAGE
# Run the image. You'll likely need to set additional flags. See https://docs.docker.com/reference/cli/docker/container/run.
docker run $IMAGE |
SolomonTheGuardian
approved these changes
Sep 11, 2026
SolomonTheGuardian
left a comment
Contributor
There was a problem hiding this comment.
LGTM, 1 comment
Comment on lines
+32
to
+36
| it('describes the old and new prices accessibly', () => { | ||
| expect(createAccessibleProductLabel('~£10~ £5 at Shop')).toBe( | ||
| 'Was £10, now £5 at Shop', | ||
| ); | ||
| }); |
Contributor
There was a problem hiding this comment.
is "now £5" meant to have the double space?
Contributor
Author
There was a problem hiding this comment.
good spot, addressed in 306c1df.
This is what happens when you trust copilot
andrewHEguardian
enabled auto-merge
September 14, 2026 14:49
|
Seen on PROD (merged by @andrewHEguardian 9 minutes and 14 seconds ago) Please check your changes! |
This file contains hidden or 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
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.
What does this change?
Adds support for
strike throughin prices on product buttons, denoted by tildes ~ ~Why?
To enable editorial of The Filter to mark sale prices that have been reduced, either manually or later once we have live pricing providing information on discounts.
How has this change been tested?
Storybook examples added + unit tests
Screenshots
Product element product CTA

Product button element
