Skip to content

Self-evolving Context Database for AI Agents. Unify Agent Memory, Knowledge RAG and Skills.

fix(web-studio): restore terminal history icon (#3735)

yufeng2a2a674dee3d
diff --git a/web-studio/src/routes/playground/-components/terminal-panel.test.tsx b/web-studio/src/routes/playground/-components/terminal-panel.test.tsx
new file mode 100644
index 000000000..7aae40a3e
--- /dev/null
+++ b/web-studio/src/routes/playground/-components/terminal-panel.test.tsx
@@ -0,0 +1,25 @@
+// @vitest-environment jsdom
+
+import { cleanup, render, screen } from '@testing-library/react'
+import { afterEach, describe, expect, it, vi } from 'vitest'
+
+import { TerminalHistoryItem } from './terminal-panel'
+
+afterEach(() => {
+ cleanup()
+})
+
+describe('TerminalHistoryItem', () => {
+ it('renders command entries with their terminal icon', () => {
+ const { container } = render(
+ <TerminalHistoryItem
+ entry={{ id: 'command-1', kind: 'command', title: '/ls' }}
+ onOpenResource={vi.fn()}
+ openingUri={null}
+ />,
+ )
+
+ expect(screen.getByText('/ls')).not.toBeNull()
+ expect(container.querySelector('svg')).not.toBeNull()
+ })
+})
diff --git a/web-studio/src/routes/playground/-components/terminal-panel.tsx b/web-studio/src/routes/playground/-components/terminal-panel.tsx
index 5badcaa23..8c6ab6048 100644
--- a/web-studio/src/routes/playground/-components/terminal-panel.tsx
+++ b/web-studio/src/routes/playground/-components/terminal-panel.tsx
@@ -8,6 +8,7 @@ import {
Loader2Icon,
SendIcon,
SparklesIcon,
+ TerminalIcon,
TrashIcon,
XCircleIcon,
} from 'lucide-react'