From fb81fc6ed36ec296bd8452c48772713ce580dc50 Mon Sep 17 00:00:00 2001 From: yiling Date: Sun, 31 May 2026 23:21:29 +0800 Subject: [PATCH 1/3] refactor(ui): align message card avatar and thread lines via flexbox --- src/ui/components/chat/message-card.tsx | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/src/ui/components/chat/message-card.tsx b/src/ui/components/chat/message-card.tsx index 844a89e5..94e8e673 100644 --- a/src/ui/components/chat/message-card.tsx +++ b/src/ui/components/chat/message-card.tsx @@ -126,17 +126,19 @@ export const MessageCard: React.FC = ({ : 'border-transparent bg-foreground/2 dark:bg-foreground/10 hover:bg-foreground/4 dark:hover:bg-foreground/15' }`} > - {hasReplies && !isReply && ( -
- )} + {/* Left Column: Avatar & Thread Lines */} +
+ {/* Thread line above avatar (for replies) */} + {isReply && ( +
+ )} - {isReply && !isLastReply && ( -
- )} + {/* Thread line under avatar (for parent comments with replies, or intermediate replies) */} + {((hasReplies && !isReply) || (isReply && !isLastReply)) && ( +
+ )} - {/* Avatar */} -
- + {creator?.name?.[0]?.toUpperCase() || 'U'}
From 1ffa25803cb11dc34c1f5d8d4d3f4518f6fa024b Mon Sep 17 00:00:00 2001 From: yiling Date: Sun, 31 May 2026 23:25:17 +0800 Subject: [PATCH 2/3] refactor(ui): collapse spacing and merge corners for reply card stacks --- src/ui/components/chat/message-card.tsx | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/ui/components/chat/message-card.tsx b/src/ui/components/chat/message-card.tsx index 94e8e673..a2e3c99e 100644 --- a/src/ui/components/chat/message-card.tsx +++ b/src/ui/components/chat/message-card.tsx @@ -120,10 +120,18 @@ export const MessageCard: React.FC = ({ return (
{/* Left Column: Avatar & Thread Lines */} From 7bd808df0b51990e1ab9097a58417e5df2144f8e Mon Sep 17 00:00:00 2001 From: yiling Date: Sun, 31 May 2026 23:30:52 +0800 Subject: [PATCH 3/3] refactor(ui): redesign chat input replying to thread header card --- src/ui/components/chat/message-card.tsx | 14 ++++++++------ src/ui/components/chat/message-input.tsx | 11 +++++------ 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/src/ui/components/chat/message-card.tsx b/src/ui/components/chat/message-card.tsx index a2e3c99e..593b7c29 100644 --- a/src/ui/components/chat/message-card.tsx +++ b/src/ui/components/chat/message-card.tsx @@ -3,11 +3,11 @@ import type { UserInfo } from '@/dtos/team' import { client } from '@/ui/api/client' import { Button } from '@/ui/components/ui/button' import { - Dialog, - DialogContent, - DialogDescription, - DialogHeader, - DialogTitle, + Dialog, + DialogContent, + DialogDescription, + DialogHeader, + DialogTitle, } from '@/ui/components/ui/dialog' import { Separator } from '@/ui/components/ui/separator' import { formatTimeAgo } from '@/ui/lib/time' @@ -147,7 +147,9 @@ export const MessageCard: React.FC = ({ )} - {creator?.name?.[0]?.toUpperCase() || 'U'} + + {creator?.name?.[0]?.toUpperCase() || 'U'} +
diff --git a/src/ui/components/chat/message-input.tsx b/src/ui/components/chat/message-input.tsx index a57e7fdd..ce0f099b 100644 --- a/src/ui/components/chat/message-input.tsx +++ b/src/ui/components/chat/message-input.tsx @@ -529,16 +529,15 @@ export const ChatInput = React.forwardRef( {showUpperPart && (
{replyingTo && ( -
-
- Replying to thread - {replyingTo.message} +
+
+ reply to: {replyingTo.message}
)}