From a8bbce726aa44f67a3c691584c0fc910826d2ded Mon Sep 17 00:00:00 2001 From: ATeals <125727432+ATeals@users.noreply.github.com> Date: Tue, 26 Nov 2024 10:13:58 +0900 Subject: [PATCH] =?UTF-8?q?Feature=20#145=20mutation=20=EA=B2=B0=EA=B3=BC?= =?UTF-8?q?=20toast=EB=A1=9C=20=EB=9D=84=EC=9A=B0=EA=B8=B0=20(#146)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix(#145): lotus update form 기본값 추가 * feat(#145): 코드 실행 버튼 mutation 결과 toast * feat(#145): lotus create form mutation 결과 toast * feat(#145): lotus delete mutation 결과 toast * feat(#145): lotus update mutation 결과 toast * feat(#145): user info form 결과 toast --- apps/frontend/src/feature/user/component.tsx | 7 ++++-- .../src/widget/lotusCodeRun/CodeRunButton.tsx | 22 ++++++++++++++++--- .../widget/lotusCreate/LotusCreateForm.tsx | 12 ++++++++++ .../frontend/src/widget/lotusDelete/index.tsx | 20 +++++++++++++---- .../widget/lotusUpdate/LotusUpdateButton.tsx | 18 ++++++++++++--- .../widget/lotusUpdate/LotusUpdateForm.tsx | 4 ++-- .../src/widget/user/SuspenseUserInfoBox.tsx | 13 +++++++++-- 7 files changed, 80 insertions(+), 16 deletions(-) diff --git a/apps/frontend/src/feature/user/component.tsx b/apps/frontend/src/feature/user/component.tsx index 3bb29163..7c1499ac 100644 --- a/apps/frontend/src/feature/user/component.tsx +++ b/apps/frontend/src/feature/user/component.tsx @@ -4,6 +4,7 @@ import { useForm } from 'react-hook-form'; import { z } from 'zod'; interface UserEditableInfoProps { + disabled?: boolean; value: string; onToggleIsEdit: () => void; onEditValue: (value: string) => void; @@ -13,7 +14,7 @@ const userInfoInputValue = z.object({ value: z.string().min(1, { message: '입력값이 존재하지 않습니다.' }) }); -export function UserInfoInputForm({ value, onToggleIsEdit, onEditValue }: UserEditableInfoProps) { +export function UserInfoInputForm({ value, onToggleIsEdit, onEditValue, disabled }: UserEditableInfoProps) { const { register, reset, @@ -37,7 +38,9 @@ export function UserInfoInputForm({ value, onToggleIsEdit, onEditValue }: UserEd return (