From 49f78ef6b0916f375ab1db89ee9ce778d128ee86 Mon Sep 17 00:00:00 2001 From: fightme-cmd <80396935+fightme-cmd@users.noreply.github.com> Date: Sun, 5 Jul 2026 10:28:11 +0200 Subject: [PATCH] Add premium paywall and core German drills --- .env.example | 3 + README.md | 32 +++++ index.html | 1 + public/favicon.svg | 4 + src/App.jsx | 293 +++++++++++++++++++++++++++++++++++++++------ 5 files changed, 296 insertions(+), 37 deletions(-) create mode 100644 .env.example create mode 100644 public/favicon.svg diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..b3cb9bc --- /dev/null +++ b/.env.example @@ -0,0 +1,3 @@ +VITE_STRIPE_YEARLY_URL= +VITE_STRIPE_LIFETIME_URL= +VITE_STRIPE_WEEKLY_URL= diff --git a/README.md b/README.md index 668e596..0e813e6 100644 --- a/README.md +++ b/README.md @@ -36,3 +36,35 @@ Open the URL in Safari, tap Share → **Add to Home Screen**. It opens fullscree The app tries `window.storage` first (Claude artifact environment), then falls back to `localStorage`. When self-hosted, only localStorage runs, which iOS Safari persists reliably. To wipe progress: open browser devtools → Application → Local Storage → delete the `gd-v10` key. Or on iPhone: Settings → Safari → Advanced → Website Data → search your domain → delete. + +## Stripe checkout + +Beug uses public Stripe Checkout or Payment Link URLs, supplied through environment variables. Do not put Stripe secret keys in this Vite app. + +Create one product in Stripe, for example `Beug Premium`, with three prices: + +- Weekly subscription: `$2.99` every week +- Yearly subscription: `$9.99` every year +- Lifetime access: `$19.99` one-time payment + +Create a Payment Link or Checkout link for each price. Set the success redirect URL to: + +```text +https://beug.george1.dev/?checkout=success +``` + +Set the cancel URL to: + +```text +https://beug.george1.dev/ +``` + +Then add these public URLs in the deployment environment: + +```bash +VITE_STRIPE_YEARLY_URL=https://buy.stripe.com/... +VITE_STRIPE_LIFETIME_URL=https://buy.stripe.com/... +VITE_STRIPE_WEEKLY_URL=https://buy.stripe.com/... +``` + +The current v1 unlock is intentionally simple: after Stripe redirects back with `?checkout=success`, Beug stores the unlock in this browser's localStorage. This avoids accounts for the tiny-app version, but it is a soft paywall. A stricter version needs a small backend, Stripe webhooks, and account or email-based entitlement lookup. diff --git a/index.html b/index.html index 2ce6aea..92e657c 100644 --- a/index.html +++ b/index.html @@ -7,6 +7,7 @@ +
+ No mascot. No scenic route. Drill the prepositions, articles, possessives, and pronouns that keep slowing you down, then get back to actual German. +
+| + {genders.map(g => | {g.slice(0,4)} | )} +
|---|---|
| {CL[c]} | + {genders.map(g =>{DEF[g][c]} | )} +
+ Possessives, pronouns, contractions, genitive articles, and mixed rounds. Built for people who want the case system handled, fast. +
+