Skip to content
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

Update cookie set by Guardian Ad-Lite purchase to be persistent #6712

Merged
merged 2 commits into from
Jan 22, 2025
Merged

Conversation

tjmw
Copy link
Member

@tjmw tjmw commented Jan 21, 2025

What are you doing in this PR?

Update the cookie set by the checkout when a user makes a Guardian Ad-Lite purchase to be persistent. It should persist for 7 days. Previously it was a session cookie. This includes a refactoring to support persistent cookies on the checkout in a product specific way.

Trello Card

Why are you doing this?

This gives the user a 7 day grace period to sign in after purchasing.

How to test

Purchase Guardian Ad-Lite in CODE, see that the cookie is set correctly:

Screenshot 2025-01-21 at 12 47 36

For other products, cookies continue to be correctly set as session cookies:

Screenshot 2025-01-21 at 12 52 41

How can we measure success?

Have we considered potential risks?

Accessibility test checklist

Screenshots

This cookie has also been renamed. It should persist for 7 days.
Previously it was a session cookie.

This includes a refactoring to support persistent cookies on the
checkout in a product specific way.
Copy link
Contributor

github-actions bot commented Jan 21, 2025

Size Change: 0 B

Total Size: 2.37 MB

ℹ️ View Unchanged
Filename Size
./public/compiled-assets/javascripts/[countryGroupId]/events/router.js 90.5 kB
./public/compiled-assets/javascripts/[countryGroupId]/lazyRouter.js 93.2 kB
./public/compiled-assets/javascripts/[countryGroupId]/router.js 254 kB
./public/compiled-assets/javascripts/ausMomentMap.js 108 kB
./public/compiled-assets/javascripts/contributionsRedirectStyles.js 20 B
./public/compiled-assets/javascripts/digitalSubscriptionLandingPage.js 223 kB
./public/compiled-assets/javascripts/downForMaintenancePage.js 67.7 kB
./public/compiled-assets/javascripts/error404Page.js 67.6 kB
./public/compiled-assets/javascripts/error500Page.js 67.5 kB
./public/compiled-assets/javascripts/favicons.js 617 B
./public/compiled-assets/javascripts/paperSubscriptionCheckoutPage.js 164 kB
./public/compiled-assets/javascripts/paperSubscriptionLandingPage.js 87.9 kB
./public/compiled-assets/javascripts/payPalErrorPage.js 66.1 kB
./public/compiled-assets/javascripts/payPalErrorPageStyles.js 20 B
./public/compiled-assets/javascripts/promotionTerms.js 73.8 kB
./public/compiled-assets/javascripts/subscriptionsLandingPage.js 73.2 kB
./public/compiled-assets/javascripts/subscriptionsRedemptionPage.js 118 kB
./public/compiled-assets/javascripts/supporterPlusLandingPage.js 226 kB
./public/compiled-assets/javascripts/unsupportedBrowserStyles.js 20 B
./public/compiled-assets/javascripts/weeklySubscriptionCheckoutPage.js 160 kB
./public/compiled-assets/javascripts/weeklySubscriptionLandingPage.js 88 kB
./public/compiled-assets/webpack/136.js 2.17 kB
./public/compiled-assets/webpack/186.js 3.35 kB
./public/compiled-assets/webpack/187.js 21.7 kB
./public/compiled-assets/webpack/3.js 19.2 kB
./public/compiled-assets/webpack/311.js 40.1 kB
./public/compiled-assets/webpack/344.js 2.01 kB
./public/compiled-assets/webpack/397.js 10.2 kB
./public/compiled-assets/webpack/426.js 36.6 kB
./public/compiled-assets/webpack/643.js 22.4 kB
./public/compiled-assets/webpack/706.js 107 kB
./public/compiled-assets/webpack/754.js 9.96 kB
./public/compiled-assets/webpack/847.js 26 kB
./public/compiled-assets/webpack/checkout.js 14.3 kB
./public/compiled-assets/webpack/GuardianAdLiteLanding.js 9.05 kB
./public/compiled-assets/webpack/oneTimeCheckout.js 9.96 kB
./public/compiled-assets/webpack/ThankYou.js 1.08 kB

compressed-size-action

@tjmw tjmw marked this pull request as draft January 21, 2025 11:46
@tjmw tjmw marked this pull request as ready for review January 21, 2025 12:53
Copy link
Contributor

@andrewHEguardian andrewHEguardian left a comment

Choose a reason for hiding this comment

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

Looks good. Nice refactor and test 👍

@tjmw tjmw merged commit de60a81 into main Jan 22, 2025
19 checks passed
@tjmw tjmw deleted the tw/cookies branch January 22, 2025 10:19
@prout-bot
Copy link

Seen on PROD (merged by @tjmw 9 minutes ago)

Sentry Release: support-client-side, support

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

Successfully merging this pull request may close these issues.

3 participants