Skip to content

NewsletterSignupCard — static card + feature flag swap-in#15728

Merged
georgerichmond merged 3 commits into
mainfrom
15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper
Apr 20, 2026
Merged

NewsletterSignupCard — static card + feature flag swap-in#15728
georgerichmond merged 3 commits into
mainfrom
15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper

Conversation

@georgerichmond
Copy link
Copy Markdown
Contributor

@georgerichmond georgerichmond commented Apr 20, 2026

NewsletterSignupCard — static card + feature flag swap-in

What does this change?

Introduces the new NewsletterSignupCard component and wires it into EmailSignUpWrapper behind a feature flag, while keeping the existing SecureSignup form inside.

  • NewsletterSignupCard — new presentational card shell with themed palette colours, a frequency tag with SvgNewsletterFilled, title, description, and an optional circular illustration (illustrationSquare)
  • NewsletterSignupCardContainer — a thin pass-through wrapper around the card, intentionally left minimal as an integration point for upcoming preview functionality
  • EmailSignUpWrapper — when the showNewNewsletterSignupCard switch is enabled, renders the new card design with the existing SecureSignup form inside; otherwise falls through to the existing EmailSignup behaviour unchanged
  • Palette tokens — four new --newsletter-card-* colour tokens supporting light and dark modes
  • Type + schema additionsillustrationSquare optional field added to the Newsletter type and all three JSON schemas
  • Stories — a NewsletterSignupCard.stories.tsx for visual review in Storybook

Why?

This is the first step in a phased rollout of a redesigned newsletter signup card. By landing the static shell and feature flag now, two parallel workstreams can merge cleanly on top:

  1. Preview functionality (colleague) — fills in NewsletterSignupCardContainer with preview modal, tracking, and the "Preview newsletter" button, without touching EmailSignUpWrapper
  2. New signup form (follow-up) — swaps SecureSignup for the new NewsletterSignupForm inside EmailSignUpWrapper

Screenshots

image

@georgerichmond georgerichmond linked an issue Apr 20, 2026 that may be closed by this pull request
4 tasks
@georgerichmond georgerichmond added the feature Departmental tracking: work on a new feature label Apr 20, 2026
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 20, 2026

@georgerichmond georgerichmond marked this pull request as ready for review April 20, 2026 11:28
@georgerichmond georgerichmond force-pushed the 15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper branch 4 times, most recently from e226189 to ec2856e Compare April 20, 2026 11:31
@georgerichmond georgerichmond changed the title Add NewsletterSignupCard with toggle switch. NewsletterSignupCard — static card + feature flag swap-in Apr 20, 2026
@georgerichmond georgerichmond force-pushed the 15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper branch from ec2856e to 466c8a6 Compare April 20, 2026 11:34
@georgerichmond georgerichmond requested a review from Copilot April 20, 2026 11:35
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR introduces a new presentational NewsletterSignupCard UI and wires it into the existing newsletter signup rendering path behind a showNewNewsletterSignupCard feature flag, while extending newsletter content to support an optional square illustration image.

Changes:

  • Add NewsletterSignupCard + NewsletterSignupCardContainer (and a Storybook story) to provide a new static card shell for newsletter signup.
  • Gate the new card shell behind switches.showNewNewsletterSignupCard in EmailSignUpWrapper, keeping the existing SecureSignup form inside.
  • Extend newsletter types + JSON schemas with illustrationSquare, and add new palette tokens for the card’s colours.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
dotcom-rendering/src/types/content.ts Adds optional illustrationSquare to the Newsletter type.
dotcom-rendering/src/paletteDeclarations.ts Adds --newsletter-card-* palette tokens for the new card styling.
dotcom-rendering/src/model/newsletter-page-schema.json Adds illustrationSquare to the newsletter page schema.
dotcom-rendering/src/model/block-schema.json Adds illustrationSquare to the block schema’s newsletter definition.
dotcom-rendering/src/frontend/schemas/feArticle.json Adds illustrationSquare to FE article schemas where newsletters appear.
dotcom-rendering/src/lib/renderElement.tsx Passes illustrationSquare + showNewNewsletterSignupCard into EmailSignUpWrapper.
dotcom-rendering/src/components/NewsletterSignupCardContainer.tsx Introduces a thin wrapper container for the new card component.
dotcom-rendering/src/components/NewsletterSignupCard.tsx Adds the new presentational newsletter signup card shell.
dotcom-rendering/src/components/NewsletterSignupCard.stories.tsx Adds a Storybook story for visual review of the new card.
dotcom-rendering/src/components/EmailSignUpWrapper.island.tsx Adds the feature-flagged rendering path for the new card shell.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread dotcom-rendering/src/components/EmailSignUpWrapper.island.tsx
Comment thread dotcom-rendering/src/components/EmailSignUpWrapper.island.tsx
NewsletterSignupCard — static presentational shell #15674
NewsletterSignupCard — feature flag + swap in EmailSignUpWrapper #15680
NewsletterSignupCard — static presentational shell #15674
NewsletterSignupCard — feature flag + swap in EmailSignUpWrapper #15680
@georgerichmond georgerichmond force-pushed the 15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper branch from 466c8a6 to abd2b24 Compare April 20, 2026 12:16
@georgerichmond georgerichmond added the run_chromatic Runs chromatic when label is applied label Apr 20, 2026
@github-actions github-actions Bot removed the run_chromatic Runs chromatic when label is applied label Apr 20, 2026
@georgerichmond georgerichmond force-pushed the 15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper branch from 8d81997 to 0c0dc11 Compare April 20, 2026 14:22
@georgerichmond georgerichmond force-pushed the 15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper branch from 0c0dc11 to c8d2c32 Compare April 20, 2026 14:25
@georgerichmond georgerichmond added the run_chromatic Runs chromatic when label is applied label Apr 20, 2026
@github-actions github-actions Bot removed the run_chromatic Runs chromatic when label is applied label Apr 20, 2026
@georgerichmond georgerichmond merged commit d8eab33 into main Apr 20, 2026
26 checks passed
@georgerichmond georgerichmond deleted the 15680-newslettersignupcard-feature-flag-swap-in-emailsignupwrapper branch April 20, 2026 14:49
@gu-prout
Copy link
Copy Markdown

gu-prout Bot commented Apr 20, 2026

Seen on PROD (merged by @georgerichmond 9 minutes and 6 seconds ago) Please check your changes!

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

Labels

feature Departmental tracking: work on a new feature Seen-on-PROD

Projects

None yet

Development

Successfully merging this pull request may close these issues.

NewsletterSignupCard — feature flag + swap in EmailSignUpWrapper

3 participants