From 833b834859e351904e0793451439555f4016e6f1 Mon Sep 17 00:00:00 2001 From: lee-hyeon-cheol Date: Mon, 21 Sep 2026 15:34:07 +0900 Subject: [PATCH] =?UTF-8?q?style(frontend):=20'=EC=83=9D=EA=B0=81=ED=95=98?= =?UTF-8?q?=EB=8A=94=20=EC=A4=91'=20=EC=9E=90=EB=A6=AC=EB=A5=BC=20?= =?UTF-8?q?=EB=8B=B5=EB=B3=80=20=EB=A7=90=ED=92=8D=EC=84=A0=EA=B3=BC=20?= =?UTF-8?q?=EA=B0=99=EC=9D=80=20=EB=AA=A8=EC=96=91=EC=9C=BC=EB=A1=9C=20?= =?UTF-8?q?=E2=80=94=20ThinkingBubble?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 세 군데(새 대화 세션 생성 중 / 스트리밍 첫 토큰 전 / 재진입 대기)가 각자 손으로 그린 테두리 카드라 실제 답변(Message: AI 배지 + CODEASSIST + 상자 없는 본문)과 달랐음. 컴포넌트 하나로 통일. Co-Authored-By: Claude Fable 5.1 --- .../snap/components/ThinkingBubble.tsx | 21 +++++++++++++++++++ .../src/features/snap/pages/NewChatPage.tsx | 10 ++------- .../features/snap/pages/SessionChatPage.tsx | 21 +++++-------------- 2_frontend/tsconfig.tsbuildinfo | 2 +- z-my-docs/work-log/2026-09/2026-09-21.md | 1 + 5 files changed, 30 insertions(+), 25 deletions(-) create mode 100644 2_frontend/src/features/snap/components/ThinkingBubble.tsx diff --git a/2_frontend/src/features/snap/components/ThinkingBubble.tsx b/2_frontend/src/features/snap/components/ThinkingBubble.tsx new file mode 100644 index 0000000..5f86559 --- /dev/null +++ b/2_frontend/src/features/snap/components/ThinkingBubble.tsx @@ -0,0 +1,21 @@ +import type { ReactNode } from "react" + +/** 답변 자리(첫 토큰 전·재진입 대기·세션 생성 중). Message 의 assistant 모양과 똑같이 — + * AI 배지 + CODEASSIST 라벨, 본문은 상자 없이. 안에 시머 텍스트나 스트리밍 본문을 넣는다. */ +export function ThinkingBubble({ children }: { children?: ReactNode }) { + return ( +
+
+ + AI + + + CODEASSIST + +
+
+ {children ?? 생각하는 중…} +
+
+ ) +} diff --git a/2_frontend/src/features/snap/pages/NewChatPage.tsx b/2_frontend/src/features/snap/pages/NewChatPage.tsx index fe270a9..e2e9368 100644 --- a/2_frontend/src/features/snap/pages/NewChatPage.tsx +++ b/2_frontend/src/features/snap/pages/NewChatPage.tsx @@ -8,6 +8,7 @@ import { useCreateSession } from "../api/snap.api" import { Hero } from "../components/Hero" import { Composer } from "../components/Composer" import { Message } from "../components/Message" +import { ThinkingBubble } from "../components/ThinkingBubble" import { useEscapeKey } from "../hooks/useEscapeKey" import type { SnapImageInput } from "../contract/types" @@ -58,14 +59,7 @@ export default function NewChatPage() { // 세션 만드는 동안 — SessionChatPage 첫 화면과 같은 모양(내 말풍선 + 생각 중)
-
- - CODEASSIST - -
- 생각하는 중… -
-
+
)} - - CODEASSIST - -
+
+ {m.content === "" ? ( // 첫 토큰 오기 전 빈 시간 메움 — 시머 텍스트로 "생각 중" 신호 생각하는 중… @@ -180,7 +178,7 @@ export default function SessionChatPage() { onRevealEnd={() => useSnapChatStore.getState().setRevealing(false)} /> )} -
+
) } @@ -207,16 +205,7 @@ export default function SessionChatPage() { /> ) })} - {generatingRemotely && ( -
- - CODEASSIST - -
- 생각하는 중… -
-
- )} + {generatingRemotely && }