mirror of
https://github.com/vernu/textbee.git
synced 2026-04-18 05:47:41 -04:00
Add polarCustomerPortalRequestUrl() pointing to /portal/request with a URL-encoded email query when available. Wire Manage Subscription links in account settings and subscription info; subscription info loads currentUser via whoAmI (shared React Query cache with account settings). Made-with: Cursor
20 lines
656 B
TypeScript
20 lines
656 B
TypeScript
const POLAR_CUSTOMER_PORTAL_REQUEST_BASE =
|
|
'https://polar.sh/textbee/portal/request'
|
|
|
|
export function polarCustomerPortalRequestUrl(
|
|
email?: string | null
|
|
): string {
|
|
const trimmed = email?.trim()
|
|
if (!trimmed) return POLAR_CUSTOMER_PORTAL_REQUEST_BASE
|
|
return `${POLAR_CUSTOMER_PORTAL_REQUEST_BASE}?email=${encodeURIComponent(trimmed)}`
|
|
}
|
|
|
|
export const ExternalLinks = {
|
|
patreon: 'https://patreon.com/vernu',
|
|
github: 'https://github.com/vernu/textbee',
|
|
discord: 'https://discord.gg/d7vyfBpWbQ',
|
|
polar: 'https://donate.textbee.dev',
|
|
twitter: 'https://x.com/textbeedotdev',
|
|
linkedin: 'https://www.linkedin.com/company/textbeedotdev',
|
|
}
|