@@ -11,12 +11,14 @@ import { PhoneNumberField } from '~/common/phone-number-field';
1111import { PhoneNumberOrUsernameField } from '~/common/phone-number-or-username-field' ;
1212import { UsernameField } from '~/common/username-field' ;
1313import { LOCALIZATION_NEEDED } from '~/constants/localizations' ;
14+ import { SIGN_UP_MODES } from '~/constants/user-settings' ;
1415import { useAppearance } from '~/contexts' ;
1516import { useAttributes } from '~/hooks/use-attributes' ;
1617import { useCard } from '~/hooks/use-card' ;
1718import { useDevModeWarning } from '~/hooks/use-dev-mode-warning' ;
1819import { useDisplayConfig } from '~/hooks/use-display-config' ;
1920import { useEnabledConnections } from '~/hooks/use-enabled-connections' ;
21+ import { useEnvironment } from '~/hooks/use-environment' ;
2022import { useLocalizations } from '~/hooks/use-localizations' ;
2123import { Button } from '~/primitives/button' ;
2224import * as Card from '~/primitives/card' ;
@@ -27,6 +29,7 @@ import { Separator } from '~/primitives/separator';
2729export function SignInStart ( ) {
2830 const enabledConnections = useEnabledConnections ( ) ;
2931 const { t } = useLocalizations ( ) ;
32+ const { userSettings } = useEnvironment ( ) ;
3033 const { enabled : usernameEnabled } = useAttributes ( 'username' ) ;
3134 const { enabled : phoneNumberEnabled } = useAttributes ( 'phone_number' ) ;
3235 const { enabled : emailAddressEnabled } = useAttributes ( 'email_address' ) ;
@@ -184,12 +187,14 @@ export function SignInStart() {
184187 </ Card . Content >
185188
186189 < Card . Footer { ...footerProps } >
187- < Card . FooterAction >
188- < Card . FooterActionText >
189- { t ( 'signIn.start.actionText' ) } { ' ' }
190- < Card . FooterActionLink href = '/sign-up' > { t ( 'signIn.start.actionLink' ) } </ Card . FooterActionLink >
191- </ Card . FooterActionText >
192- </ Card . FooterAction >
190+ { userSettings . signUp . mode === SIGN_UP_MODES . PUBLIC ? (
191+ < Card . FooterAction >
192+ < Card . FooterActionText >
193+ { t ( 'signIn.start.actionText' ) } { ' ' }
194+ < Card . FooterActionLink href = '/sign-up' > { t ( 'signIn.start.actionLink' ) } </ Card . FooterActionLink >
195+ </ Card . FooterActionText >
196+ </ Card . FooterAction >
197+ ) : null }
193198 </ Card . Footer >
194199 </ Card . Root >
195200 </ SignIn . Step >
0 commit comments