toast 메세지 통합을 위한 i18n 추가
This commit is contained in:
+18
-3
@@ -3,23 +3,38 @@ import { BaseLayout } from "@common/components";
|
||||
import "./globals.css";
|
||||
import { StoreProvider } from "./store";
|
||||
import { MainDiv } from "@common/business_components";
|
||||
import koBase from '../public/locales/ko/message.json';
|
||||
import i18next from "i18next";
|
||||
import { I18nextProvider } from "react-i18next";
|
||||
|
||||
export default function RootLayout({
|
||||
children,
|
||||
}: Readonly<{
|
||||
children: React.ReactNode;
|
||||
}>) {
|
||||
i18next.init({
|
||||
lng: 'ko',
|
||||
fallbackLng: 'ko',
|
||||
resources: {
|
||||
ko: {
|
||||
base: koBase,
|
||||
},
|
||||
}
|
||||
});
|
||||
|
||||
return (
|
||||
<html lang="en">
|
||||
<body>
|
||||
<I18nextProvider i18n={i18next}>
|
||||
<StoreProvider>
|
||||
<BaseLayout>
|
||||
<MainDiv>
|
||||
<MainDiv>
|
||||
{children}
|
||||
</MainDiv>
|
||||
</MainDiv>
|
||||
</BaseLayout>
|
||||
</StoreProvider>
|
||||
</I18nextProvider>
|
||||
</body>
|
||||
</html>
|
||||
</html >
|
||||
);
|
||||
}
|
||||
|
||||
@@ -16,11 +16,13 @@
|
||||
"@tanstack/react-table": "^8.21.2",
|
||||
"class-variance-authority": "^0.7.1",
|
||||
"clsx": "^2.1.1",
|
||||
"i18next": "^25.3.2",
|
||||
"lucide-react": "^0.474.0",
|
||||
"moment": "^2.30.1",
|
||||
"next": "15.1.7",
|
||||
"react-hook-form": "^7.54.2",
|
||||
"react-hot-toast": "^2.5.2",
|
||||
"react-i18next": "^15.6.0",
|
||||
"tailwind-merge": "^3.0.1",
|
||||
"tailwindcss-animate": "^1.0.7",
|
||||
"tus-js-client": "^4.3.1",
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"deleteMsg" : "{{name}}가 삭제되었습니다.",
|
||||
"insertMsg": "{{name}}가 저장되었습니다.",
|
||||
"updateMsg": "{{name}}가 수정되었습니다.",
|
||||
"errorMsg": "{{name}} 중 오류가 발생했습니다.",
|
||||
"fileErrMsg": "빈 파일 또는 파일 오류입니다.",
|
||||
"selectErrMsg": "{{name}}을(를) 선택해주세요.",
|
||||
"noChangedErrMsg": "변경사항이 없습니다.",
|
||||
"dateErrMsg": "시작년도를 종료년도 이후로 설정할 수 없습니다.",
|
||||
"fileDateErrMsg": "파일업로드 이전에 등록년도를 작성해주세요.",
|
||||
|
||||
"alreadyInsertedErrMsg": "사업자번호 {{num}}(은)는 이미 등록되었습니다. 다시 등록해주세요.",
|
||||
"saveRowErrMsg": "수정을 원하는 행을 선택하고 저장버튼을 눌러주세요.",
|
||||
"costCalcErrMsg":"공사비 계산 진행 후 저장을 눌러주세요",
|
||||
"maxYearErrMsg": "최대 {{year}}년까지 선택가능합니다.",
|
||||
"checkQtyMsg": "요구수량(M3/d)을 확인해주세요 계산할수 없습니다."
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user