From f40550d79b58cb203b467e27c54f26a30ff25c5d Mon Sep 17 00:00:00 2001 From: logikonline Date: Tue, 3 Feb 2026 10:01:53 -0500 Subject: [PATCH] feat(subscriptions): add subscription plan UI and localization Adds locale strings for subscription plan types (monthly/yearly/lifetime), pricing display, payment buttons, and success/empty states. Updates subscribe page title to include repository name for better context. --- options/locale/locale_en-US.json | 10 ++++++++++ templates/repo/subscribe.tmpl | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/options/locale/locale_en-US.json b/options/locale/locale_en-US.json index e42fb0397b..e4b6121f00 100644 --- a/options/locale/locale_en-US.json +++ b/options/locale/locale_en-US.json @@ -4297,6 +4297,16 @@ "repo.subscribe.payment_required": "A subscription is required to view this repository's source code.", "repo.subscribe.button": "Subscribe for Access", "repo.subscribe.active": "You have an active subscription", + "repo.subscribe.monthly": "Monthly", + "repo.subscribe.yearly": "Yearly", + "repo.subscribe.lifetime": "Lifetime", + "repo.subscribe.per_month": "month", + "repo.subscribe.per_year": "year", + "repo.subscribe.one_time": "one-time payment", + "repo.subscribe.choose": "Choose Plan", + "repo.subscribe.pay_with_stripe": "Pay with Card", + "repo.subscribe.no_products": "No subscription plans are currently available for this repository.", + "repo.subscribe.success": "Thank you! Your subscription is now active.", "repo.cross_promoted": "Also Check Out", "repo.settings.license": "License", "repo.settings.license_type": "License Type", diff --git a/templates/repo/subscribe.tmpl b/templates/repo/subscribe.tmpl index e94cb1a072..581f9b9041 100644 --- a/templates/repo/subscribe.tmpl +++ b/templates/repo/subscribe.tmpl @@ -3,7 +3,7 @@ {{template "repo/header" .}}
-

{{svg "octicon-lock" 24}} {{ctx.Locale.Tr "repo.subscribe.title"}}

+

{{svg "octicon-lock" 24}} {{ctx.Locale.Tr "repo.subscribe.title" .Repository.FullName}}

{{ctx.Locale.Tr "repo.subscribe.description"}}

{{if .Products}}