#23

Hide production Google and Gmail CTAs

MergedstylesshOwnermerged intofrom

Summary

  • hide Google sign-in and Gmail connect/reconnect calls to action on redakt.app until production verification is approved
  • skip the unavailable provider chooser while preserving management for existing Gmail accounts
  • simplify the Google/Gmail UI copy and give onboarding provider cards Redakt's glass treatment

Validation

  • pnpm test (81 tests passed)
  • pnpm build
  • pnpm exec tsc --noEmit
  • focused ESLint across all changed source files
  • rendered desktop and mobile checks with production and staging configuration

Known baseline

  • repository-wide pnpm lint still reports the existing @typescript-eslint/no-require-imports errors in babel.config.js and postcss.config.js; changed-file lint passes

Activity

4
stylessh merged commit 6623d56 into main3mo ago
mikeyreviewed3mo ago
mikey3mo ago

Summary

Reviewed the diff hiding Google/Gmail CTAs on redakt.app production while awaiting OAuth verification, plus the onboarding provider-chooser skip and the glass-treatment restyle of the provider cards.

areGoogleCtasEnabled() (lib/env.ts) and its call sites in app/page.tsx, app/onboarding/page.tsx, and app/mail/settings/account/page.tsx are consistent, and the new lib/env.test.mjs coverage for the production/staging/local matrix looks correct — verified locally with node --test lib/env.test.mjs (3/3 passing).

Blocking

  • components/settings/mail-accounts-settings.tsx: hiding the Gmail reconnect button whenever googleEnabled is false breaks the reauthorize flow for accounts that already exist in production. See inline comment for the full trace (mail-account-shell.tsx → settings page → dead end). This contradicts the PR's stated goal of "preserving management for existing Gmail accounts" and needs the reconnect action to stay available independent of googleEnabled.

Non-blocking / follow-up

  • The disclosure copy previously shown to users about how Google/Gmail access works (login-screen.tsx's "How Google access works" section, onboarding.tsx's gmailDisclosure paragraph, and the settings page's "Google OAuth is not configured" fallback) was deleted rather than just hidden behind googleEnabled. That's fine for the currently-hidden CTAs, but note it also removes the last inline explanation of Gmail scope/data handling from the sign-in and onboarding flows for staging/local, where googleEnabled is still true and the Gmail button is shown without this context (the privacy-policy link is preserved on the account settings page but not on the login screen or onboarding provider step). Worth confirming that's intentional given app/privacy still carries the full explanation.

No issues found with the getAppUrl()/BETTER_AUTH_URL origin comparison itself, or with the onboarding step-skip logic (step = googleEnabled ? "provider" : "domain", back-navigation redirecting to / when Google is hidden).

Branch stylessh/hide-production-google-ctas has been merged.

Checking branch