From 1f7976bd32da311367945370efccd7d9c9b102a7 Mon Sep 17 00:00:00 2001 From: MOHAMMAD SARFRAZ ALAM Date: Thu, 25 Jul 2024 21:28:19 +0530 Subject: [PATCH] fix(core): useTranslate to import from @hooks in auth login page (#6184) Co-authored-by: Sarfraz Alam Co-authored-by: Batuhan Wilhelm --- .changeset/famous-donuts-bake.md | 5 +++++ .../src/components/pages/auth/components/login/index.tsx | 9 +++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 .changeset/famous-donuts-bake.md diff --git a/.changeset/famous-donuts-bake.md b/.changeset/famous-donuts-bake.md new file mode 100644 index 000000000000..920dad2fc93d --- /dev/null +++ b/.changeset/famous-donuts-bake.md @@ -0,0 +1,5 @@ +--- +"@refinedev/core": patch +--- + +AuthPage in Next.js generates code with i18n but the folder hooks is not created. imported useTranslate from @hooks to fix the issue diff --git a/packages/core/src/components/pages/auth/components/login/index.tsx b/packages/core/src/components/pages/auth/components/login/index.tsx index 90daab4e2bc4..2a50ad4ea8a4 100644 --- a/packages/core/src/components/pages/auth/components/login/index.tsx +++ b/packages/core/src/components/pages/auth/components/login/index.tsx @@ -1,8 +1,13 @@ import React, { useState } from "react"; import { useActiveAuthProvider } from "@definitions/helpers"; -import { useLink, useLogin, useRouterContext, useRouterType } from "@hooks"; -import { useTranslate } from "@hooks/i18n"; +import { + useLink, + useLogin, + useRouterContext, + useRouterType, + useTranslate, +} from "@hooks"; import type { DivPropsType, FormPropsType } from "../.."; import type { LoginFormTypes, LoginPageProps } from "../../types";