Branded email template + footer pages: help center, token unsubscribe, settings deep links
release gate / check (push) Failing after 6m56s
release gate / check (push) Failing after 6m56s
Transactional mail now goes out as the Superbrain HTML design
(internal/mailer/template.html, embedded verbatim) with a plain-text
alternative: multipart/alternative (plain first per RFC 2046), random
boundary, CRLF normalization and SMTP dot-stuffing. Render() fills the
{{placeholders}} with HTML-escaped values and removes optional sections
(CTA + fallback link, note block, footer links, address) when empty;
anchor drift fails the unit tests and degrades to plain text at send
time, never blocking delivery. Password reset gets the headline,
first-name greeting, "Choose a new password" button (Outlook VML
fallback) and expiry/single-use note; notification and agent emails
render title-as-headline with body paragraphs.
The template's footer links are now real pages:
- /help: public help center (10 topic sections + FAQ accordion), linked
from the login page.
- /unsubscribe?token=...: public confirmation page; the HMAC-signed user
id (notify.UnsubscribeToken, domain-separated, stable, no stored row)
IS the credential. POST /api/notifications/unsubscribe accepts the
RFC 8058 one-click shape (token in query, form body ignored) and the
browser JSON shape; it disables the user's enabled email channels and
pauses enabled agent email tasks addressed to their own email
(idempotent, re-enableable, per-client rate limited, audit logged).
- Email preferences deep-links to /settings?tab=notifications; Settings
now honors ?tab=<section> (unknown values fall back to profile).
notify.FooterLinks is the single eligibility point: preferences + help
whenever NEXTAUTH_URL is set; unsubscribe ONLY when the recipient is the
owner's own account email — third-party channel addresses and agent
recipients never receive a link that changes someone else's settings,
and transactional mail (password reset) never carries unsubscribe.
Owner-addressed mail also carries List-Unsubscribe +
List-Unsubscribe-Post headers.
Verified: Go build/vet/unit green; new TestUnsubscribeFlow integration
test pins footer + headers, blast radius (slack channel and third-party
task survive), one-click + JSON paths, idempotence, tampered tokens and
the third-party/transactional exclusions; notifications, phase-2,
password-reset and agent suites green; web lint/SSR-lint/build 0 errors;
full browser regressions pass; live smoke of /help, /unsubscribe states,
the settings deep-link auth gate and bad-token 400 through the proxy.
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
import { useState, useEffect, useCallback, Fragment } from 'react'
|
||||
import { useSession } from 'next-auth/react'
|
||||
import { useSearchParams } from 'next/navigation'
|
||||
import { Button } from '@/components/ui/button'
|
||||
import { Input } from '@/components/ui/input'
|
||||
import { Tabs, TabsList, TabsTrigger, TabsContent } from '@/components/ui/tabs'
|
||||
@@ -50,17 +51,25 @@ const NAV_GROUPS = [
|
||||
|
||||
export function SettingsClient({ oidc, callbackUrl }: { oidc: OidcStatus; callbackUrl: string }) {
|
||||
const { data: session } = useSession()
|
||||
// ?tab=<value> deep links (email footer "Email preferences" lands on
|
||||
// notifications). Unknown values fall back to profile; the Radix tab
|
||||
// values stay the canonical section ids.
|
||||
const requestedTab = useSearchParams().get('tab') ?? ''
|
||||
const initialSection = NAV_GROUPS.some(g => g.items.some(i => i.value === requestedTab))
|
||||
? requestedTab
|
||||
: 'profile'
|
||||
const [imapConfig, setImapConfig] = useState({ host: '', port: 993, tls: true, username: '', password: '', folder: 'INBOX' })
|
||||
const [ncConfig, setNcConfig] = useState({ nextcloudUrl: '', cardDavPath: '', username: '', password: '' })
|
||||
const [savingImap, setSavingImap] = useState(false)
|
||||
const [testingImap, setTestingImap] = useState(false)
|
||||
const [syncingContacts, setSyncingContacts] = useState(false)
|
||||
const [section, setSection] = useState('profile')
|
||||
const [section, setSection] = useState(initialSection)
|
||||
// Below md the grouped nav becomes a list -> detail flow (same
|
||||
// master-detail pattern as collections/tags/contacts); at md+ the
|
||||
// nav and the selected panel sit side by side.
|
||||
// nav and the selected panel sit side by side. A deep link opens the
|
||||
// detail pane directly on narrow screens.
|
||||
const isNarrow = useMediaQuery('(max-width: 767px)')
|
||||
const [mobileDetail, setMobileDetail] = useState(false)
|
||||
const [mobileDetail, setMobileDetail] = useState(initialSection !== 'profile')
|
||||
|
||||
useEffect(() => {
|
||||
fetch('/api/settings/imap').then(r => r.json()).then(data => {
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { SettingsClient } from './client'
|
||||
import { getOidcStatus } from '@/lib/oidc-config'
|
||||
import { headers } from 'next/headers'
|
||||
import { Suspense } from 'react'
|
||||
|
||||
export const dynamic = 'force-dynamic'
|
||||
|
||||
@@ -20,5 +21,11 @@ export default async function SettingsPage() {
|
||||
const proto = h.get('x-forwarded-proto') ?? 'http'
|
||||
if (host) callbackUrl = `${proto}://${host}/api/auth/callback/authelia`
|
||||
}
|
||||
return <SettingsClient oidc={getOidcStatus()} callbackUrl={callbackUrl} />
|
||||
// useSearchParams in the client (?tab= deep links, e.g. from email
|
||||
// footers) needs a Suspense boundary for prerender.
|
||||
return (
|
||||
<Suspense>
|
||||
<SettingsClient oidc={getOidcStatus()} callbackUrl={callbackUrl} />
|
||||
</Suspense>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
'use client'
|
||||
|
||||
import { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from '@/components/ui/accordion'
|
||||
|
||||
const FAQ = [
|
||||
{
|
||||
q: 'How do I stop notification emails?',
|
||||
a: 'Use the unsubscribe link in any notification email — it turns off your email channels and any automations that email you, without signing in. You can also toggle channels and rules in Settings → Notifications. Password resets and other account emails are not affected by unsubscribing.',
|
||||
},
|
||||
{
|
||||
q: 'Why didn\u2019t my notification arrive?',
|
||||
a: 'Check Settings → Notifications: the channel and the rule must both be enabled, and your plan must include the channel kind. History lists every delivery attempt, including suppressed ones (for example a recipient without a channel of that kind, or a plan downgrade). Email delivery also needs the operator to have configured an SMTP relay.',
|
||||
},
|
||||
{
|
||||
q: 'Who can see a public bookmark link?',
|
||||
a: 'Anyone with the link. It publishes the title, description, notes, due date, tags and preview — and deliberately no owner attribution. Treat public links as published content; revoking the public toggle stops access immediately.',
|
||||
},
|
||||
{
|
||||
q: 'Can I use my own AI provider and key?',
|
||||
a: 'Yes. Settings → AI stores your own OpenAI-compatible, Anthropic or Gemini key (encrypted, write-only). Your key is used before any server key, and the server key itself depends on your plan. Without any AI configured, AI features point you to Settings instead of failing silently.',
|
||||
},
|
||||
{
|
||||
q: 'What happens when I delete a page or bookmark?',
|
||||
a: 'Deletions are recoverable from Trash. Deleting a parent page promotes its children instead of deleting them, and page revisions let you restore earlier content. Note that restoring from Trash does not restore access grants — re-share if needed.',
|
||||
},
|
||||
{
|
||||
q: 'How do I connect Nextcloud?',
|
||||
a: 'Settings → WebDAV, CalDAV or CardDAV. On Core deployments the forms offer a prefill for your account\u2019s Nextcloud URL. Each connected share, calendar or address book becomes its own collection, synced on a schedule; files, events and contacts appear as bookmarks.',
|
||||
},
|
||||
]
|
||||
|
||||
export function HelpFaq() {
|
||||
return (
|
||||
<Accordion type="single" collapsible className="mt-4">
|
||||
{FAQ.map((item, i) => (
|
||||
<AccordionItem key={i} value={`faq-${i}`}>
|
||||
<AccordionTrigger className="text-sm font-medium">{item.q}</AccordionTrigger>
|
||||
<AccordionContent className="text-sm leading-relaxed text-muted-foreground">
|
||||
{item.a}
|
||||
</AccordionContent>
|
||||
</AccordionItem>
|
||||
))}
|
||||
</Accordion>
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,190 @@
|
||||
import Link from 'next/link'
|
||||
import { Button } from '@/components/ui/button'
|
||||
import { Badge } from '@/components/ui/badge'
|
||||
import { HelpFaq } from './faq'
|
||||
import {
|
||||
Bookmark, FolderOpen, FileText, Kanban, Radar, Bell, Bot,
|
||||
FolderSync, KeyRound, ArrowRight,
|
||||
} from 'lucide-react'
|
||||
|
||||
export const dynamic = 'force-dynamic'
|
||||
|
||||
const SECTIONS = [
|
||||
{
|
||||
id: 'getting-started',
|
||||
icon: ArrowRight,
|
||||
title: 'Getting started',
|
||||
body: [
|
||||
'Sign in with your email and password, or with Authelia single sign-on if your deployment uses it. On first run, create your account from the sign-up page — then start by saving a bookmark, writing a page, or connecting a service in Settings.',
|
||||
'Forgot your password? Use the "Forgot password?" link on the sign-in page; a single-use reset link is emailed to you. On single-sign-on deployments, recovery is handled by your identity provider instead.',
|
||||
],
|
||||
where: 'Sign in → /login · Reset → /forgot-password',
|
||||
},
|
||||
{
|
||||
id: 'bookmarks',
|
||||
icon: Bookmark,
|
||||
title: 'Bookmarks & tags',
|
||||
body: [
|
||||
'Every URL you save becomes a bookmark with a title, description, notes, tags and an optional due date. Open a bookmark to edit its details, attach it to pages and collections, or place it on the board.',
|
||||
'Sharing a tag shares every bookmark under it with the recipients — group-wide, including bookmarks other recipients add later. A public bookmark link publishes the title, description, notes, due date, tags and preview to anyone with the link, and deliberately carries no owner attribution.',
|
||||
],
|
||||
where: 'Sidebar → Bookmarks · Tags',
|
||||
},
|
||||
{
|
||||
id: 'collections',
|
||||
icon: FolderOpen,
|
||||
title: 'Collections',
|
||||
body: [
|
||||
'Collections group bookmarks manually or by smart filters, and render as a table or a board grouped by any select property. Shared collections are read-only for recipients.',
|
||||
'Connected services materialize as collections automatically: each WebDAV share, CalDAV calendar and CardDAV address book becomes its own collection whose files, events or contacts are bookmarks. Syncing mirrors the server — removed items detach, and your own removals stay removed.',
|
||||
],
|
||||
where: 'Sidebar → Collections · Settings → WebDAV / CalDAV / CardDAV',
|
||||
},
|
||||
{
|
||||
id: 'pages',
|
||||
icon: FileText,
|
||||
title: 'Pages',
|
||||
body: [
|
||||
'Pages are WYSIWYG documents stored as Markdown. Every URL you add — via the Link button, the links popover, or a bare-URL paste — is also saved as a bookmark linked to the page, reusing an existing bookmark for the same URL instead of duplicating it.',
|
||||
'Pages can nest under a parent; deleting a parent promotes its children. Every save keeps a revision you can restore, and deleted pages are recoverable from Trash. Autosave pauses on a version conflict so you never clobber newer content.',
|
||||
],
|
||||
where: 'Sidebar → Pages · Trash',
|
||||
},
|
||||
{
|
||||
id: 'board',
|
||||
icon: Kanban,
|
||||
title: 'Kanban board',
|
||||
body: [
|
||||
'The board places bookmarks in columns you define. Drag cards between columns or reorder within a column; moves are saved immediately. Shared cards are read-only.',
|
||||
],
|
||||
where: 'Sidebar → Board',
|
||||
},
|
||||
{
|
||||
id: 'signals',
|
||||
icon: Radar,
|
||||
title: 'Signals & mailbox watches',
|
||||
body: [
|
||||
'Signals are events attached to bookmarks — notes, arrivals, reminders. Connect an IMAP mailbox in Settings and add a watch from a bookmark\'s Signals panel: matching emails become signals on that bookmark.',
|
||||
],
|
||||
where: 'Settings → IMAP · Bookmark → Signals',
|
||||
},
|
||||
{
|
||||
id: 'notifications',
|
||||
icon: Bell,
|
||||
title: 'Notifications',
|
||||
body: [
|
||||
'Notification rules fire on signals created, bookmarks coming due, or shares received, and deliver through your channels: email, Slack, Matrix, Telegram or Signal. Rules can target other people in your organization; each recipient gets the delivery through their own channel. History shows every delivery, including suppressed ones.',
|
||||
'Email preferences live in Settings → Notifications. Every notification email also carries an unsubscribe link that turns off your email channels and any automations that email you — password resets and other account emails are not affected.',
|
||||
],
|
||||
where: 'Settings → Notifications',
|
||||
},
|
||||
{
|
||||
id: 'assistant',
|
||||
icon: Bot,
|
||||
title: 'Assistant & automations',
|
||||
body: [
|
||||
'The assistant answers questions about your data and can propose automations: stored tasks that periodically check a page and then notify you, send an email, or save a bookmark. Proposals are compiled into a validated spec and only run after you confirm them — the assistant never acts on its own.',
|
||||
'AI features use your own provider key (Settings → AI) or the server key when your plan includes it. Without any AI configured, the app tells you where to add one instead of failing silently.',
|
||||
],
|
||||
where: 'Assistant panel · Settings → AI / Automations',
|
||||
},
|
||||
{
|
||||
id: 'connections',
|
||||
icon: FolderSync,
|
||||
title: 'Connections',
|
||||
body: [
|
||||
'Settings connects Superbrain to your services: WebDAV shares, CalDAV calendars, CardDAV address books, Nextcloud contacts sync, and IMAP mailboxes. Credentials are stored encrypted and are write-only — the app never shows them back to you.',
|
||||
'On Core deployments with Nextcloud, the connection forms offer a one-click prefill for your account.',
|
||||
],
|
||||
where: 'Settings → Connections',
|
||||
},
|
||||
{
|
||||
id: 'developer',
|
||||
icon: KeyRound,
|
||||
title: 'API keys & MCP',
|
||||
body: [
|
||||
'Personal API keys (sb_…) authenticate machine clients against the Go API directly; the plaintext key is shown once at creation and stored hashed. The superbrain-mcp server exposes your data to MCP clients through the federated gateway.',
|
||||
'You can also register external MCP servers (Settings → MCP) for Superbrain to dial as a client.',
|
||||
],
|
||||
where: 'Settings → API Keys / MCP',
|
||||
},
|
||||
]
|
||||
|
||||
export default function HelpPage() {
|
||||
return (
|
||||
<div className="min-h-screen bg-background">
|
||||
<header className="border-b border-border">
|
||||
<div className="mx-auto flex max-w-4xl items-center justify-between px-6 py-4">
|
||||
<Link href="/login" className="font-display text-lg font-bold tracking-tight">
|
||||
superbrain
|
||||
</Link>
|
||||
<Button asChild size="sm">
|
||||
<Link href="/login">Open Superbrain</Link>
|
||||
</Button>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main className="mx-auto max-w-4xl px-6 pb-24">
|
||||
<div className="pt-16 pb-10">
|
||||
<Badge variant="secondary" className="mb-4">Help center</Badge>
|
||||
<h1 className="font-display text-4xl font-bold tracking-tight">
|
||||
How Superbrain works
|
||||
</h1>
|
||||
<p className="mt-3 max-w-2xl text-base text-muted-foreground">
|
||||
Bookmarks, pages, collections and automations — a quick guide to every
|
||||
surface of the app. Jump to a topic below, or browse the FAQ at the end.
|
||||
</p>
|
||||
<nav className="mt-6 flex flex-wrap gap-2">
|
||||
{SECTIONS.map(s => (
|
||||
<a
|
||||
key={s.id}
|
||||
href={`#${s.id}`}
|
||||
className="rounded-full border border-border px-3 py-1 text-xs text-muted-foreground transition-colors hover:bg-accent hover:text-accent-foreground"
|
||||
>
|
||||
{s.title}
|
||||
</a>
|
||||
))}
|
||||
<a
|
||||
href="#faq"
|
||||
className="rounded-full border border-border px-3 py-1 text-xs text-muted-foreground transition-colors hover:bg-accent hover:text-accent-foreground"
|
||||
>
|
||||
FAQ
|
||||
</a>
|
||||
</nav>
|
||||
</div>
|
||||
|
||||
<div className="space-y-12">
|
||||
{SECTIONS.map(s => (
|
||||
<section key={s.id} id={s.id} className="scroll-mt-8">
|
||||
<div className="flex items-center gap-3">
|
||||
<div className="flex h-9 w-9 items-center justify-center rounded-lg bg-primary/10 text-primary">
|
||||
<s.icon className="h-5 w-5" />
|
||||
</div>
|
||||
<h2 className="font-display text-2xl font-bold tracking-tight">{s.title}</h2>
|
||||
</div>
|
||||
<div className="mt-4 space-y-3 text-sm leading-relaxed text-foreground/90">
|
||||
{s.body.map((p, i) => <p key={i}>{p}</p>)}
|
||||
</div>
|
||||
<p className="mt-3 font-mono text-xs text-muted-foreground">{s.where}</p>
|
||||
</section>
|
||||
))}
|
||||
|
||||
<section id="faq" className="scroll-mt-8">
|
||||
<h2 className="font-display text-2xl font-bold tracking-tight">Frequently asked questions</h2>
|
||||
<HelpFaq />
|
||||
</section>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
<footer className="border-t border-border">
|
||||
<div className="mx-auto flex max-w-4xl flex-wrap items-center justify-between gap-2 px-6 py-6 text-xs text-muted-foreground">
|
||||
<span>Superbrain — your second brain, federated.</span>
|
||||
<span className="flex gap-4">
|
||||
<Link href="/login" className="hover:text-primary hover:underline">Sign in</Link>
|
||||
<Link href="/forgot-password" className="hover:text-primary hover:underline">Reset password</Link>
|
||||
</span>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -117,6 +117,9 @@ export function LoginClient({ oidcEnabled, passwordEnabled }: { oidcEnabled: boo
|
||||
</p>
|
||||
</>
|
||||
)}
|
||||
<p className="text-center text-xs text-muted-foreground">
|
||||
<Link href="/help" className="hover:text-primary hover:underline">Help center</Link>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,127 @@
|
||||
'use client'
|
||||
|
||||
import { useState } from 'react'
|
||||
import { useSearchParams } from 'next/navigation'
|
||||
import { Button } from '@/components/ui/button'
|
||||
import { BellOff, Check, Link2 } from 'lucide-react'
|
||||
import Link from 'next/link'
|
||||
import { toast } from 'sonner'
|
||||
|
||||
// The token in the link IS the credential (HMAC-signed user id, issued only
|
||||
// in mail to the owner's own address). The page never needs a session; the
|
||||
// Go endpoint validates the token and disables email notification channels
|
||||
// plus self-addressed agent email tasks. Transactional mail (password
|
||||
// resets) keeps flowing — the copy must say so.
|
||||
export function UnsubscribeClient() {
|
||||
const params = useSearchParams()
|
||||
const token = params.get('token') ?? ''
|
||||
const [loading, setLoading] = useState(false)
|
||||
const [done, setDone] = useState(false)
|
||||
const [invalid, setInvalid] = useState(false)
|
||||
|
||||
const handleUnsubscribe = async () => {
|
||||
setLoading(true)
|
||||
try {
|
||||
const res = await fetch('/api/notifications/unsubscribe', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ token }),
|
||||
})
|
||||
const data = await res.json().catch(() => null)
|
||||
if (res.ok && data?.ok) {
|
||||
setDone(true)
|
||||
} else if (res.status === 400) {
|
||||
setInvalid(true)
|
||||
} else {
|
||||
toast.error(data?.error ?? 'Could not unsubscribe right now')
|
||||
}
|
||||
} catch {
|
||||
toast.error('Could not unsubscribe right now')
|
||||
}
|
||||
setLoading(false)
|
||||
}
|
||||
|
||||
if (!token || invalid) {
|
||||
return (
|
||||
<div className="min-h-screen flex items-center justify-center bg-background p-4">
|
||||
<div className="w-full max-w-sm space-y-8 text-center">
|
||||
<div className="flex justify-center mb-4">
|
||||
<div className="flex h-14 w-14 items-center justify-center rounded-2xl bg-primary text-primary-foreground">
|
||||
<Link2 className="h-7 w-7" />
|
||||
</div>
|
||||
</div>
|
||||
<h1 className="font-display text-3xl font-bold tracking-tight">Invalid Link</h1>
|
||||
<p className="text-sm text-muted-foreground mt-2">
|
||||
This unsubscribe link is invalid or has expired. Open Settings → Notifications
|
||||
in the app to manage your email preferences directly.
|
||||
</p>
|
||||
<p className="text-center text-xs text-muted-foreground">
|
||||
<Link href="/settings?tab=notifications" className="text-primary hover:underline">Email preferences</Link>
|
||||
{' · '}
|
||||
<Link href="/help" className="text-primary hover:underline">Help center</Link>
|
||||
{' · '}
|
||||
<Link href="/login" className="text-primary hover:underline">Back to sign in</Link>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
if (done) {
|
||||
return (
|
||||
<div className="min-h-screen flex items-center justify-center bg-background p-4">
|
||||
<div className="w-full max-w-sm space-y-8 text-center">
|
||||
<div className="flex justify-center mb-4">
|
||||
<div className="flex h-14 w-14 items-center justify-center rounded-2xl bg-primary text-primary-foreground">
|
||||
<Check className="h-7 w-7" />
|
||||
</div>
|
||||
</div>
|
||||
<h1 className="font-display text-3xl font-bold tracking-tight">You're Unsubscribed</h1>
|
||||
<p className="text-sm text-muted-foreground mt-2">
|
||||
Notification emails and automations that email you have been turned off.
|
||||
You can re-enable them anytime in Settings → Notifications. Account emails
|
||||
such as password resets are not affected.
|
||||
</p>
|
||||
<p className="text-center text-xs text-muted-foreground">
|
||||
<Link href="/settings?tab=notifications" className="text-primary hover:underline">Email preferences</Link>
|
||||
{' · '}
|
||||
<Link href="/help" className="text-primary hover:underline">Help center</Link>
|
||||
{' · '}
|
||||
<Link href="/login" className="text-primary hover:underline">Back to sign in</Link>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="min-h-screen flex items-center justify-center bg-background p-4">
|
||||
<div className="w-full max-w-sm space-y-8">
|
||||
<div className="text-center">
|
||||
<div className="flex justify-center mb-4">
|
||||
<div className="flex h-14 w-14 items-center justify-center rounded-2xl bg-primary text-primary-foreground">
|
||||
<BellOff className="h-7 w-7" />
|
||||
</div>
|
||||
</div>
|
||||
<h1 className="font-display text-3xl font-bold tracking-tight">Unsubscribe</h1>
|
||||
<p className="text-sm text-muted-foreground mt-2">
|
||||
Stop notification emails and automations that email you. Password resets and
|
||||
other account emails keep working, and you can re-enable notifications anytime
|
||||
in Settings.
|
||||
</p>
|
||||
</div>
|
||||
<div className="space-y-3">
|
||||
<Button className="w-full" onClick={handleUnsubscribe} loading={loading}>
|
||||
Unsubscribe from notification emails
|
||||
</Button>
|
||||
<Button variant="outline" className="w-full" asChild>
|
||||
<Link href="/settings?tab=notifications">Keep my current preferences</Link>
|
||||
</Button>
|
||||
</div>
|
||||
<p className="text-center text-xs text-muted-foreground">
|
||||
<Link href="/help" className="text-primary hover:underline">Help center</Link>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
import { UnsubscribeClient } from './client'
|
||||
import { Suspense } from 'react'
|
||||
|
||||
export const dynamic = 'force-dynamic'
|
||||
|
||||
export default function UnsubscribePage() {
|
||||
// useSearchParams in the client needs a Suspense boundary for prerender.
|
||||
return (
|
||||
<Suspense>
|
||||
<UnsubscribeClient />
|
||||
</Suspense>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user