sign-in-sso.tsx46 lines · main
| 1 | import { SignInSSOForm } from '@/components/interfaces/SignIn/SignInSSOForm' |
| 2 | import SignInLayout from '@/components/layouts/SignInLayout/SignInLayout' |
| 3 | import { UnknownInterface } from '@/components/ui/UnknownInterface' |
| 4 | import { useIsFeatureEnabled } from '@/hooks/misc/useIsFeatureEnabled' |
| 5 | import type { NextPageWithLayout } from '@/types' |
| 6 | |
| 7 | const SignInSSOPage: NextPageWithLayout = () => { |
| 8 | const signInWithSSOEnabled = useIsFeatureEnabled('dashboard_auth:sign_in_with_sso') |
| 9 | |
| 10 | if (!signInWithSSOEnabled) { |
| 11 | return <UnknownInterface fullHeight={false} urlBack="/sign-in" /> |
| 12 | } |
| 13 | |
| 14 | return ( |
| 15 | <> |
| 16 | <div className="flex flex-col gap-5"> |
| 17 | <SignInSSOForm /> |
| 18 | </div> |
| 19 | |
| 20 | <div className="my-8 self-center text-sm"> |
| 21 | <div> |
| 22 | <span className="text-foreground-light">Interested in SSO?</span>{' '} |
| 23 | <a |
| 24 | href="https://supabase.com/contact/enterprise" |
| 25 | rel="noopener noreferrer" |
| 26 | className="underline text-foreground hover:text-foreground-light transition" |
| 27 | > |
| 28 | Let us know |
| 29 | </a> |
| 30 | </div> |
| 31 | </div> |
| 32 | </> |
| 33 | ) |
| 34 | } |
| 35 | |
| 36 | SignInSSOPage.getLayout = (page) => ( |
| 37 | <SignInLayout |
| 38 | heading="Welcome back" |
| 39 | subheading="Sign in to your enterprise account" |
| 40 | logoLinkToMarketingSite={true} |
| 41 | > |
| 42 | {page} |
| 43 | </SignInLayout> |
| 44 | ) |
| 45 | |
| 46 | export default SignInSSOPage |