src/examples/profile/WithUi.tsx

Every source

src/examples/profile/WithUi.tsx
'use client'

import { AccountManager } from '@synqauth/react'

// The profile with Synq's UI: their picture, names and username, saved to
// the brand's account API, which checks each field (a username taken at the
// brand, a picture that isn't one) and says why it refused. They upload a
// picture, use a linked account's, or remove it; without one, the app's own
// default avatar shows, drawn from their `avatar_seed`. This demo draws
// Synq's Monogram: pass your own art as `avatar={{ fallback: (seed) => … }}`,
// or once for the whole app on <SynqProvider avatar>.
export function ProfileWithUi() {
  return <AccountManager sections={['profile']} avatar={{ fallback: 'monogram' }} />
}