Skip to content

Add ResponsiveImage to supporter revenue inline1 component - #17254

Draft
williammead wants to merge 4 commits into
mainfrom
wm/add-responsive-image-to-supporter-revenue-inline1
Draft

williammead wants to merge 4 commits into
mainfrom
wm/add-responsive-image-to-supporter-revenue-inline1

Conversation

@williammead

@williammead williammead commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

This PR refers to the Supporter Revenue component designed for the inline1 ad slot.

What does this change?

The Inline1SupporterRevenue component now uses the ResponsiveImage component to manage different images depending on media queries.

This component will choose different image urls depending on the width of the viewport, i.e. on a mobile you'll see one image whereas on a desktop you'll see another. Those images are configured in the Reader Revenue Control Panel.

The chosen image is then resized, so it does not need to already be the correct size.

Why?

The Reader Revenue Control Panel, where the Supporter Revenue ask is created, allows users to present different images for mobile, tablet and desktop breakpoints. Previously we were only using the desktop image and now we are using all of them at the various breakpoints.

@williammead williammead added the maintenance Departmental tracking: maintenance work, not a fix or a feature label Nov 13, 2026
@github-actions

github-actions Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

🚀 Image for dotcom-rendering pushed to AWS ECR

Image digest: sha256:14bff9dd6b83eb1f01be82fc78a164daf0a87d3aeb741ac6d7fd302d2d3cc949

🐛 Run the image locally

The following can be used to run the image locally:

# Refer to image using the immutable digest. Find alternatives below.
IMAGE_IDENTIFIER="@sha256:14bff9dd6b83eb1f01be82fc78a164daf0a87d3aeb741ac6d7fd302d2d3cc949"

# Refer to image using branch tag
# IMAGE_IDENTIFIER=":branch-wm-add-responsive-image-to-supporter-revenue-inline1"

# Refer to image using build tag
# IMAGE_IDENTIFIER=":build-34576"

# 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/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

From guardian/actions-ecr.

@github-actions

github-actions Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

@williammead williammead changed the title WIP add responsive image to supporter revenue inline1 Add responsive image to supporter revenue inline1 component Nov 17, 2026
@williammead williammead changed the title Add responsive image to supporter revenue inline1 component Add ResponsiveImage to supporter revenue inline1 component Nov 17, 2026
@williammead
williammead marked this pull request as ready for review November 17, 2026 16:07
@williammead
williammead requested a review from a team as a code owner November 17, 2026 16:07
@github-actions

Copy link
Copy Markdown

Hello 👋! When you're ready to run Chromatic, please apply the run_chromatic label to this PR.

You will need to reapply the label each time you want to run Chromatic.

Click here to see the Chromatic project.

@williammead williammead added the run_chromatic Runs chromatic when label is applied label Nov 17, 2026
@williammead
williammead marked this pull request as draft November 17, 2026 16:08
@github-actions github-actions Bot removed the run_chromatic Runs chromatic when label is applied label Nov 17, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Departmental tracking: maintenance work, not a fix or a feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant