auth.sign-in.example.tsx.txt 681 B

123456789101112131415161718192021
  1. // Example sign-in page (paste into app/sign-in/page.tsx or similar)
  2. //
  3. // Option A — hosted Briven pages (fastest pilot):
  4. // 'use client';
  5. // import { auth } from '@/lib/auth';
  6. // export default function SignIn() {
  7. // return (
  8. // <button type="button" onClick={() => {
  9. // window.location.assign(auth.hostedPageURL('sign-in', '/dashboard'));
  10. // }}>
  11. // Sign in
  12. // </button>
  13. // );
  14. // }
  15. //
  16. // Option B — embedded panel:
  17. // 'use client';
  18. // import { BrivenSignIn } from '@briven/auth/react';
  19. // export default function SignIn() {
  20. // return <BrivenSignIn redirectTo="/dashboard" showEmailPassword showMagicLink />;
  21. // }