refacto(auth): Simplify workspace lookup and cleanup UI logic (#9160)

Streamlined workspace selection by defaulting to the first available
workspace. Adjusted conditional rendering for a separator between
authentication providers, improving clarity and reducing redundancy.
Minor formatting changes were also applied for consistency.

Close #9094
This commit is contained in:
Antoine Moreaux
2024-12-23 13:17:00 +01:00
committed by GitHub
parent 164f010501
commit ee0282bcc8

View File

@ -107,9 +107,10 @@ export const SignInUpGlobalScopeForm = () => {
<>
<StyledContentContainer>
{authProviders.google && <SignInUpWithGoogle />}
{authProviders.microsoft && <SignInUpWithMicrosoft />}
<HorizontalSeparator visible />
{(authProviders.google || authProviders.microsoft) && (
<HorizontalSeparator visible />
)}
{/* eslint-disable-next-line react/jsx-props-no-spreading */}
<FormProvider {...form}>
<StyledForm onSubmit={form.handleSubmit(handleSubmit)}>