feat: 灵犀 Studio Web UI 定制版
Build / build (push) Has been cancelled
NPM Lockfile Check / npm ci --ignore-scripts (push) Has been cancelled
Playwright / e2e (push) Has been cancelled

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
yi
2026-06-05 11:29:11 +08:00
commit 7d10320a82
643 changed files with 164406 additions and 0 deletions
+37
View File
@@ -0,0 +1,37 @@
import { expect, test } from '@playwright/test'
import { authenticate, mockHermesApi, TEST_ACCESS_KEY } from './fixtures'
const sampleSession = {
id: 'session-native-1',
title: 'Native Link Session',
source: 'cli',
model: 'test-model',
provider: 'test-provider',
profile: 'research',
started_at: 1_700_000_000,
ended_at: null,
last_active: 1_700_000_100,
message_count: 2,
}
test('sidebar navigation exposes native links', async ({ page }) => {
await authenticate(page, TEST_ACCESS_KEY, 'research')
await mockHermesApi(page)
await page.goto('/#/hermes/chat')
const models = page.locator('aside.sidebar').getByRole('link', { name: /^Models$/ })
await expect(models).toHaveAttribute('href', '#/hermes/models')
const history = page.locator('aside.sidebar').getByRole('link', { name: /^History$/ })
await expect(history).toHaveAttribute('href', '#/hermes/history')
})
test('session rows expose native session links', async ({ page }) => {
await authenticate(page, TEST_ACCESS_KEY, 'research')
await mockHermesApi(page, { sessions: [sampleSession] })
await page.goto('/#/hermes/chat')
const sessionLink = page.locator('.session-items a.session-item').first()
await expect(sessionLink).toHaveAttribute('href', '#/hermes/session/session-native-1')
await expect(sessionLink).toContainText('Native Link Session')
})