Skip to content

Commit

Permalink
fix(login,signup): set default successMessage to false
Browse files Browse the repository at this point in the history
  • Loading branch information
unleashit committed Dec 27, 2023
1 parent 09a9aea commit cae5209
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion demos/frontend/src/components/login/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,6 @@ const LoginDemo = () => {
linkComponent={Link}
linkComponentHrefAttr="to"
cssModule={css}
successMessage="you gotta be kidding!"
>
<TwitterLoginButton onClick={() => alert('Hello')} style={btnStyle} />
<GithubLoginButton onClick={() => alert('Hello')} style={btnStyle} />
Expand Down
2 changes: 1 addition & 1 deletion packages/login/src/login.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export const Login = ({
customSchema: schema = defaultLoginSchema,
toast,
failMsg,
successMessage = 'You are now logged in.',
successMessage = false,
cssModule = {},
children,
}: LoginProps) => {
Expand Down
4 changes: 2 additions & 2 deletions packages/signup/src/signup.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export const Signup = ({
customSchema: schema = defaultSignupSchema,
toast,
failMsg,
successMessage = 'Signup was successful. Welcome!',
successMessage = false,
cssModule = {},
children,
}: SignupProps) => {
Expand All @@ -64,7 +64,7 @@ export const Signup = ({
defaultValues: getDefaultsFromZodObject<typeof schema>(schema),
});

// set focus on the first (if any) field with a focus prop
// set focus on the first field with a focus prop, if any
useSetFocus(customFields, setFocus);

// Submit handler
Expand Down

0 comments on commit cae5209

Please sign in to comment.