From 0a4622ed8a7f7c82e2a1ed3904a797336dc9a2ff Mon Sep 17 00:00:00 2001 From: yiling Date: Sun, 12 Jul 2026 10:02:52 +0800 Subject: [PATCH] syle minor fix --- packages/webui/components/chatbot-sidebar.tsx | 29 ++++++++++++------- .../webui/components/file-system-manager.tsx | 14 ++++----- .../$projectId/files/$fileId.lazy.tsx | 18 ++++++------ 3 files changed, 34 insertions(+), 27 deletions(-) diff --git a/packages/webui/components/chatbot-sidebar.tsx b/packages/webui/components/chatbot-sidebar.tsx index 705a2618..7a78c01e 100644 --- a/packages/webui/components/chatbot-sidebar.tsx +++ b/packages/webui/components/chatbot-sidebar.tsx @@ -7,6 +7,7 @@ import type { ChatMessage } from '@shumai/dtos' import { ArrowLeft, ArrowUp, Bot, History, Loader2, Plus, Trash2 } from 'lucide-react' import { useEffect, useRef, useState } from 'react' import Markdown from 'react-markdown' +import { formatTimeAgo } from '../lib/time' interface ChatbotSidebarProps { projectId: string @@ -135,7 +136,19 @@ export function ChatbotSidebar({ projectId, contextAssetId }: ChatbotSidebarProp return (
- {preprocessMarkdown(getMessageText(msg.content))} + tag + pre: ({ node, ...props }) => ( +
+                ),
+              }}
+            >
+              {preprocessMarkdown(getMessageText(msg.content))}
+            
           
{m.created_by_agent()} @@ -176,7 +189,7 @@ export function ChatbotSidebar({ projectId, contextAssetId }: ChatbotSidebarProp
{isOver && ( @@ -191,11 +204,10 @@ export function ChatbotSidebar({ projectId, contextAssetId }: ChatbotSidebarProp )} {/* Header section */} -
+
{isHistoryMode ? ( <>
- {m.history()}