diff --git a/packages/react/src/auth/forms/sign-in-auth-form.test.tsx b/packages/react/src/auth/forms/sign-in-auth-form.test.tsx
index 1f23e98a4..d2cf05ce5 100644
--- a/packages/react/src/auth/forms/sign-in-auth-form.test.tsx
+++ b/packages/react/src/auth/forms/sign-in-auth-form.test.tsx
@@ -229,7 +229,7 @@ describe("", () => {
expect(onForgotPasswordClickMock).toHaveBeenCalled();
});
- it("should render the register button callback when onRegisterClick is provided", () => {
+ it("should render the register button callback when onSignUpClick is provided", () => {
const mockUI = createMockUI({
locale: registerLocale("test", {
prompts: {
@@ -241,11 +241,11 @@ describe("", () => {
}),
});
- const onRegisterClickMock = vi.fn();
+ const onSignUpClick = vi.fn();
render(
-
+
);
@@ -259,7 +259,7 @@ describe("", () => {
expect(registerButton).toHaveAttribute("type", "button");
fireEvent.click(registerButton);
- expect(onRegisterClickMock).toHaveBeenCalled();
+ expect(onSignUpClick).toHaveBeenCalled();
});
it("should trigger validation errors when the form is blurred", () => {
diff --git a/packages/react/src/auth/forms/sign-in-auth-form.tsx b/packages/react/src/auth/forms/sign-in-auth-form.tsx
index 684a8d8f6..17275b51a 100644
--- a/packages/react/src/auth/forms/sign-in-auth-form.tsx
+++ b/packages/react/src/auth/forms/sign-in-auth-form.tsx
@@ -26,7 +26,7 @@ import { useCallback } from "react";
export type SignInAuthFormProps = {
onSignIn?: (credential: UserCredential) => void;
onForgotPasswordClick?: () => void;
- onRegisterClick?: () => void;
+ onSignUpClick?: () => void;
};
export function useSignInAuthFormAction() {
@@ -73,7 +73,7 @@ export function useSignInAuthForm(onSuccess?: SignInAuthFormProps["onSignIn"]) {
});
}
-export function SignInAuthForm({ onSignIn, onForgotPasswordClick, onRegisterClick }: SignInAuthFormProps) {
+export function SignInAuthForm({ onSignIn, onForgotPasswordClick, onSignUpClick }: SignInAuthFormProps) {
const ui = useUI();
const form = useSignInAuthForm(onSignIn);
@@ -110,8 +110,8 @@ export function SignInAuthForm({ onSignIn, onForgotPasswordClick, onRegisterClic
{getTranslation(ui, "labels", "signIn")}
- {onRegisterClick ? (
-
+ {onSignUpClick ? (
+
{getTranslation(ui, "prompts", "noAccount")} {getTranslation(ui, "labels", "signUp")}
) : null}
diff --git a/packages/shadcn/src/registry/sign-in-auth-form.test.tsx b/packages/shadcn/src/registry/sign-in-auth-form.test.tsx
index 29aa0db43..634c21116 100644
--- a/packages/shadcn/src/registry/sign-in-auth-form.test.tsx
+++ b/packages/shadcn/src/registry/sign-in-auth-form.test.tsx
@@ -96,8 +96,8 @@ describe("", () => {
expect(onForgotPasswordClickMock).toHaveBeenCalled();
});
- it("should render with register callback", () => {
- const onRegisterClickMock = vi.fn();
+ it("should render with onSignUp callback", () => {
+ const onSignUpClickMock = vi.fn();
const mockUI = createMockUI({
locale: registerLocale("test", {
prompts: {
@@ -111,7 +111,7 @@ describe("", () => {
const { container } = render(
-
+
);
@@ -123,7 +123,7 @@ describe("", () => {
fireEvent.click(button!);
});
- expect(onRegisterClickMock).toHaveBeenCalled();
+ expect(onSignUpClickMock).toHaveBeenCalled();
});
it("should call the onSignIn callback when the form is submitted", async () => {
diff --git a/packages/shadcn/src/registry/sign-in-auth-form.tsx b/packages/shadcn/src/registry/sign-in-auth-form.tsx
index 907d63123..6950c8f1a 100644
--- a/packages/shadcn/src/registry/sign-in-auth-form.tsx
+++ b/packages/shadcn/src/registry/sign-in-auth-form.tsx
@@ -77,9 +77,9 @@ export function SignInAuthForm(props: SignInAuthFormProps) {
{getTranslation(ui, "labels", "signIn")}
{form.formState.errors.root && {form.formState.errors.root.message}}
- {props.onRegisterClick ? (
+ {props.onSignUpClick ? (
<>
-