Skip to content

Commit 8f26414

Browse files
committed
fix(clerk-js): Correctly hide divider when not needed
1 parent f922972 commit 8f26414

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

packages/clerk-js/src/v4/SignIn/SignInStart.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,8 @@ export function _SignInStart(): JSX.Element {
193193
>
194194
<SocialButtonsReversibleContainer>
195195
<SignInSocialButtons />
196-
{hasSocialOrWeb3Buttons && <Divider />}
197-
{standardFormAttributes.length && (
196+
{hasSocialOrWeb3Buttons && standardFormAttributes.length ? <Divider /> : null}
197+
{standardFormAttributes.length ? (
198198
<Form.Root onSubmit={handleFirstPartySubmit}>
199199
<Form.ControlRow>
200200
<Form.Control
@@ -205,7 +205,7 @@ export function _SignInStart(): JSX.Element {
205205
<InstantPasswordRow field={passwordBasedInstance ? instantPasswordField : undefined} />
206206
<Form.SubmitButton>Continue</Form.SubmitButton>
207207
</Form.Root>
208-
)}
208+
) : null}
209209
</SocialButtonsReversibleContainer>
210210
</Col>
211211
<Footer.Root>

packages/clerk-js/src/v4/SignUp/SignUpContinue.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ function _SignUpContinue() {
125125
>
126126
<SocialButtonsReversibleContainer>
127127
{showSocialButtons && <SignUpSocialButtons />}
128-
{showSocialButtons && <Divider />}
128+
{showSocialButtons && showFormFields(userSettings) && <Divider />}
129129
{showFormFields(userSettings) && (
130130
<SignUpForm
131131
handleSubmit={handleSubmit}

packages/clerk-js/src/v4/SignUp/SignUpStart.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ function _SignUpStart(): JSX.Element {
198198
>
199199
<SocialButtonsReversibleContainer>
200200
{(!hasTicket || missingRequirementsWithTicket) && <SignUpSocialButtons />}
201-
{hasSocialOrWeb3Buttons && <Divider />}
201+
{hasSocialOrWeb3Buttons && showFormFields(userSettings) && <Divider />}
202202
{showFormFields(userSettings) && (
203203
<SignUpForm
204204
handleSubmit={handleSubmit}

0 commit comments

Comments
 (0)