Skip to content

Commit 9c56ca0

Browse files
committed
♻️ refactor : Edit text in code to Japanese
Changed Korean text in the code to Japanese Related issue: YJU-OKURA#171
1 parent edf9fd2 commit 9c56ca0

27 files changed

+167
-154
lines changed

src/app/classes/[cId]/[mId]/components/CalendarModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ const CalendarModal = ({
4343
>
4444
<Calendar onChange={onChange} value={value} />
4545
<div className="flex justify-center items-center py-2">
46-
<span className="font-semibold">마감일시 :</span>
46+
<span className="font-semibold">締切日時 :</span>
4747
<TimePicker onChange={handleTimeSet} value={time} />
4848
</div>
4949
<div className="flex justify-center py-1">

src/app/classes/[cId]/[mId]/components/QuizFeedback.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,9 @@ const QuizFeedback = ({
5454
id="modal-container"
5555
>
5656
<div>
57-
<div className="text-xl font-semibold">ㅇㅇ님이 제출한 퀴즈</div>
57+
<div className="text-xl font-semibold">OOさんが投稿したクイズ</div>
5858
<div className="py-3">
59-
<p className="pb-2">ㅇㅇ님에 대한 피드백</p>
59+
<p className="pb-2">OOさんへのフィードバック</p>
6060
{isWrite ? (
6161
<div>{feedback}</div>
6262
) : (
@@ -71,14 +71,14 @@ const QuizFeedback = ({
7171
className="bg-blue-500 text-white px-4 py-2 rounded-lg font-semibold"
7272
onClick={handleCreateFeedback}
7373
>
74-
작성
74+
作成
7575
</button>
7676
</div>
7777
)}
7878
</div>
7979
<div className="h-[280px] overflow-scroll">
8080
<div className="font-bold py-2">
81-
정답률 :{' '}
81+
正解率 :{' '}
8282
<span
8383
className={
8484
collectRate >= 50 ? 'text-green-500' : 'text-red-500'
@@ -110,7 +110,7 @@ const QuizFeedback = ({
110110
className="p-2 border border-gray-500 rounded-lg"
111111
onClick={() => setIsOpen(false)}
112112
>
113-
닫기
113+
閉じる
114114
</button>
115115
</div>
116116
</div>

src/app/classes/[cId]/[mId]/components/chatComponents/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ const ShowMain = () => {
106106
<div className="w-full h-full mt-2">
107107
<div className="border-4 rounded-lg border-gray-500 p-2 h-full overflow-auto">
108108
<p className="text-center inline-block px-4 py-2 text-sm text-white bg-violet-300 rounded-lg w-full">
109-
최상단 채팅 내용입니다
109+
一番上のチャット内容です
110110
</p>
111111
{messages.map((msg, index) => {
112112
const [id, message] = msg.split(': ');

src/app/classes/[cId]/[mId]/quizForm/components/QuizForm.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ const QuizForm = (props: {
101101
<div className="text-lg font-medium p-1">Question</div>
102102
<input
103103
className="w-full border-2 p-3 rounded-lg leading-8"
104-
placeholder="문제를 입력해주세요"
104+
placeholder="問題を入力してください"
105105
onChange={handleInputQuestion}
106106
value={question}
107107
/>
@@ -117,7 +117,7 @@ const QuizForm = (props: {
117117
<input
118118
name="a"
119119
className="w-[calc(100%-25px)] outline-none"
120-
placeholder="답변을 입력해주세요"
120+
placeholder="回答を入力してください"
121121
onChange={handleInputAnswer}
122122
value={answer?.a}
123123
/>
@@ -129,7 +129,7 @@ const QuizForm = (props: {
129129
<input
130130
name="b"
131131
className="w-[calc(100%-25px)] outline-none"
132-
placeholder="답변을 입력해주세요"
132+
placeholder="回答を入力してください"
133133
onChange={handleInputAnswer}
134134
value={answer?.b}
135135
/>
@@ -141,7 +141,7 @@ const QuizForm = (props: {
141141
<input
142142
name="c"
143143
className="w-[calc(100%-25px)] outline-none"
144-
placeholder="답변을 입력해주세요"
144+
placeholder="回答を入力してください"
145145
onChange={handleInputAnswer}
146146
value={answer?.c}
147147
/>
@@ -153,7 +153,7 @@ const QuizForm = (props: {
153153
<input
154154
name="d"
155155
className="w-[calc(100%-25px)] outline-none"
156-
placeholder="답변을 입력해주세요"
156+
placeholder="回答を入力してください"
157157
onChange={handleInputAnswer}
158158
value={answer?.d}
159159
/>
@@ -183,7 +183,7 @@ const QuizForm = (props: {
183183
</div>
184184
<textarea
185185
className="font-medium bg-gray-100 pt-1 w-full outline-none resize-none"
186-
placeholder="해설을 입력해주세요"
186+
placeholder="解説を入力してください"
187187
rows={5}
188188
onChange={handleInputCommentary}
189189
value={commentary?.content}

src/app/classes/[cId]/components/card/MemberCard.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ const MemberCard = ({
112112
</option>
113113
</select>
114114
<button className="bg-white font-semibold text-black py-1 px-2 rounded hover:bg-gray-200 ml-2">
115-
권한 변경
115+
権限の変更
116116
</button>
117117
</div>
118118
)}

src/app/classes/[cId]/components/card/PostCard.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ const PostCard = ({
1717
}) => {
1818
const dropdownItems = [
1919
{
20-
modalId: '게시글 수정',
20+
modalId: '投稿の修正',
2121
icon: icons.edit,
2222
alt: 'Edit Icon',
23-
text: '수정',
23+
text: '修正',
2424
},
2525
{
26-
modalId: '게시글 삭제',
26+
modalId: '投稿の削除',
2727
icon: icons.delete,
2828
alt: 'Delete Icon',
29-
text: '삭제',
29+
text: '削除',
3030
},
3131
];
3232
const [isModalOpen, setIsModalOpen] = useState(false);
@@ -35,7 +35,7 @@ const PostCard = ({
3535
const setActiveModalId = (modalId: string) => {
3636
setSelectedModalId(modalId);
3737
setIsModalOpen(true);
38-
if (modalId === '게시글 삭제') {
38+
if (modalId === '投稿の削除') {
3939
deletePost(postId);
4040
}
4141
};
@@ -80,7 +80,7 @@ const PostCard = ({
8080
)}
8181
</div>
8282
</div>
83-
{isModalOpen && selectedModalId === '게시글 수정' && <ClassEditPost />}
83+
{isModalOpen && selectedModalId === '投稿の修正' && <ClassEditPost />}
8484
</div>
8585
);
8686
};

src/app/classes/[cId]/components/card/ScheduleCard.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,16 @@ const ScheduleCard = ({
2020
}) => {
2121
const dropdownItems = [
2222
{
23-
modalId: '일정 수정',
23+
modalId: 'スケジュール修正',
2424
icon: icons.edit,
2525
alt: 'Edit Icon',
26-
text: '수정',
26+
text: '修正',
2727
},
2828
{
29-
modalId: '일정 삭제',
29+
modalId: 'スケジュール削除',
3030
icon: icons.delete,
3131
alt: 'Delete Icon',
32-
text: '삭제',
32+
text: '削除',
3333
},
3434
];
3535
const [isModalOpen, setIsModalOpen] = useState(false);
@@ -38,7 +38,7 @@ const ScheduleCard = ({
3838
const setActiveModalId = (modalId: string) => {
3939
setSelectedModalId(modalId);
4040
setIsModalOpen(true);
41-
if (modalId === '일정 삭제') {
41+
if (modalId === 'スケジュール削除') {
4242
deleteSchedule(scheduleId);
4343
}
4444
};
@@ -70,7 +70,7 @@ const ScheduleCard = ({
7070
</div>
7171
</div>
7272
<div className="my-2">
73-
<p className="font-bold text-lg mb-2">날짜</p>
73+
<p className="font-bold text-lg mb-2">日付</p>
7474
<p className="ms-2 text-md mb-1">{startTime}</p>
7575
<p className="ms-2 text-md">{endTime}</p>
7676
</div>

src/app/classes/[cId]/components/main/Main.tsx

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ import icons from '@/public/svgs/_class';
1212

1313
const Main = ({managerRole, classId, userInfo}: RoleProps) => {
1414
const [showDropdown, setShowDropdown] = useState<Record<string, boolean>>({
15-
공지사항: true,
16-
일정: true,
17-
게시글: true,
15+
お知らせ: true,
16+
スケジュール: true,
17+
投稿: true,
1818
});
1919
const [modalState, setModalState] = useState({
2020
schedule: false,
@@ -54,18 +54,23 @@ const Main = ({managerRole, classId, userInfo}: RoleProps) => {
5454

5555
const mainSections: MainSectionProps[] = [
5656
{
57-
title: '공지사항',
57+
title: 'お知らせ',
5858
component: (
5959
<Notice
6060
managerRole={managerRole}
6161
classId={classId}
6262
userInfo={userInfo}
63-
isOpen={showDropdown['공지사항']}
63+
isOpen={showDropdown['お知らせ']}
6464
/>
6565
),
6666
},
67-
createSection('일정', Schedule, ClassCreateSchedule, 'schedule'),
68-
createSection('게시글', Post, ClassCreatePost, 'post'),
67+
createSection(
68+
'スケジュール',
69+
Schedule,
70+
ClassCreateSchedule,
71+
'スケジュール'
72+
),
73+
createSection('投稿', Post, ClassCreatePost, '投稿'),
6974
];
7075

7176
return (
@@ -96,7 +101,8 @@ const Main = ({managerRole, classId, userInfo}: RoleProps) => {
96101
{section.title}
97102
</h3>
98103
{managerRole &&
99-
(section.title === '일정' || section.title === '게시글') && (
104+
(section.title === 'スケジュール' ||
105+
section.title === '投稿') && (
100106
<div onClick={section.openModal}>
101107
<Image
102108
src={icons.addButton}

src/app/classes/[cId]/components/main/Notice.tsx

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ const Notice = ({
1717
}: RoleProps & {isOpen: boolean}) => {
1818
const dropdownItems = [
1919
{
20-
modalId: '공지사항 수정',
20+
modalId: 'お知らせの修正',
2121
icon: icons.edit,
2222
alt: 'Edit Icon',
23-
text: '수정',
23+
text: '修正',
2424
},
2525
{
26-
modalId: '공지사항 삭제',
26+
modalId: 'お知らせの削除',
2727
icon: icons.delete,
2828
alt: 'Delete Icon',
29-
text: '삭제',
29+
text: '削除',
3030
},
3131
];
3232
const [classAnnounced, setClassAnnounced] = useState<
@@ -38,7 +38,7 @@ const Notice = ({
3838
const deleteNotice = async (postId: number) => {
3939
if (classId !== undefined && userInfo) {
4040
try {
41-
if (confirm('정말로 공지사항을 삭제하시겠습니까?')) {
41+
if (confirm('本当にお知らせを削除しますか?')) {
4242
await DeleteClassBoard(postId, classId, userInfo.id);
4343
alert('Notice deleted successfully!');
4444
}
@@ -60,7 +60,7 @@ const Notice = ({
6060
const setActiveModalId = (modalId: string) => {
6161
setSelectedModalId(modalId);
6262
setIsModalOpen(true);
63-
if (modalId === '공지사항 삭제') {
63+
if (modalId === 'お知らせの削除') {
6464
deleteNotice(classAnnounced[0].ID);
6565
}
6666
};
@@ -101,10 +101,12 @@ const Notice = ({
101101
</>
102102
)}
103103
</div>
104-
{isModalOpen && selectedModalId === 'noticeEdit' && <ClassEditPost />}
104+
{isModalOpen && selectedModalId === 'お知らせの修正' && (
105+
<ClassEditPost />
106+
)}
105107
</>
106108
) : (
107-
<p className="ms-2 text-xl font-bold">현재 공지사항이 없습니다...</p>
109+
<p className="ms-2 text-xl font-bold">現在、お知らせはありません...</p>
108110
)}
109111
</div>
110112
);

src/app/classes/[cId]/components/main/Post.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ const Post = ({
4747
const deletePost = async (postId: number) => {
4848
if (classId !== undefined && userInfo) {
4949
try {
50-
if (confirm('정말로 게시글을 삭제하시겠습니까?')) {
50+
if (confirm('本当に投稿を削除しますか?')) {
5151
await classBoardAPI.deleteClassBoard(postId, classId, userInfo.id);
52-
alert('Post deleted successfully!');
52+
alert('投稿は正常に削除されました!');
5353
const posts = await classBoardAPI.getClassBoardList(
5454
classId,
5555
pageNum,
@@ -63,10 +63,10 @@ const Post = ({
6363
}
6464
} catch (error) {
6565
console.error(error);
66-
alert('Failed to delete post');
66+
alert('投稿の削除に失敗しました');
6767
}
6868
} else {
69-
alert('Failed to delete post');
69+
alert('投稿の削除に失敗しました');
7070
}
7171
};
7272

@@ -100,7 +100,7 @@ const Post = ({
100100
<div className="flex justify-center mt-2 w-full">
101101
<div className="flex w-1/2 border-4 justify-center items-center h-20">
102102
<h1 className="text-3xl font-semibold">
103-
현재 게시글이 존재하지 않습니다...
103+
現在、投稿が存在しません...
104104
</h1>
105105
</div>
106106
</div>
@@ -147,7 +147,7 @@ const Post = ({
147147
<>
148148
{renderPosts()}
149149
<div className="flex justify-center mt-10">
150-
{renderPageButton('이전', () => handlePageChange(-1))}
150+
{renderPageButton('前へ', () => handlePageChange(-1))}
151151
{pages.map(page => (
152152
<button
153153
className={`border w-12 h-10 rounded-full me-2 ${
@@ -159,7 +159,7 @@ const Post = ({
159159
{page}
160160
</button>
161161
))}
162-
{renderPageButton('다음', () => handlePageChange(1))}
162+
{renderPageButton('次へ', () => handlePageChange(1))}
163163
</div>
164164
</>
165165
);

src/app/classes/[cId]/components/main/Schedule.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ const Schedule = ({
1818
const deleteSchedule = async (scheduleId: number) => {
1919
if (classId !== undefined) {
2020
try {
21-
if (confirm('정말로 일정을 삭제하시겠습니까?')) {
21+
if (confirm('本当にスケジュールを削除しますか?')) {
2222
await classScheduleAPI.deleteClassSchedule(
2323
scheduleId,
2424
classId,
2525
user.id
2626
);
27-
alert('Schedule deleted successfully!');
27+
alert('スケジュールは正常に削除されました!');
2828
const schedules =
2929
await classScheduleAPI.getClassScheduleList(classId);
3030
if (Array.isArray(schedules.data)) {
@@ -35,10 +35,10 @@ const Schedule = ({
3535
}
3636
} catch (error) {
3737
console.error(error);
38-
alert('Failed to delete schedule');
38+
alert('スケジュールの削除に失敗しました');
3939
}
4040
} else {
41-
alert('Failed to delete schedule');
41+
alert('スケジュールの削除に失敗しました');
4242
}
4343
};
4444
const toKST = (date: string) => {
@@ -89,7 +89,7 @@ const Schedule = ({
8989
<div className="flex justify-center mt-2 w-full">
9090
<div className="flex w-1/2 border-4 justify-center items-center h-20">
9191
<h1 className="text-3xl font-semibold">
92-
현재 일정이 존재하지 않습니다...
92+
現在スケジュールが存在しません...
9393
</h1>
9494
</div>
9595
</div>

0 commit comments

Comments
 (0)