fix: adjust marginRight calculation in Chat component for improved layout

Updated the marginRight property in the Chat component to include the border width when the topic position is 'right' and topics are shown. This change enhances the layout by ensuring proper spacing in the UI.
This commit is contained in:
kangfenmao 2025-12-13 23:16:46 +08:00
parent ee7eee24da
commit a1e44a6827

View File

@ -180,7 +180,8 @@ const Chat: FC<Props> = (props) => {
<HStack>
<motion.div
animate={{
marginRight: topicPosition === 'right' && showTopics ? 'var(--assistants-width)' : 0
marginRight:
topicPosition === 'right' && showTopics ? 'calc(var(--assistants-width) + var(--border-width))' : 0
}}
transition={{ duration: 0.3, ease: 'easeInOut' }}
style={{ flex: 1, display: 'flex', minWidth: 0 }}>