feat(webui): render select options in field creation mode and pick random option color

This commit is contained in:
yiling
2026-08-05 14:44:30 +08:00
parent bb9c53adad
commit b568eac77d
10 changed files with 129 additions and 34 deletions
@@ -2,10 +2,7 @@ import { expect, test } from '../../fixtures'
test.use({ fileOptions: { mediaType: 'audio' } })
test('upload an audio file, create a comment at a non-zero timestamp', async ({
file,
prisma,
}) => {
test('upload an audio file, create a comment at a non-zero timestamp', async ({ file, prisma }) => {
const { page, projectId, fileId } = file
const commentText = `Audio timestamp comment ${Date.now()}`
@@ -20,11 +20,11 @@ test('upload a txt file, create a comment with draw', async ({ file, prisma }) =
await page.goto(`/projects/${projectId}/files/${fileId}`)
// Verify PDF viewer container or page is loaded
await expect(
page.locator('.pdf-viewer, canvas, [data-testid="pdf-viewer"]').first(),
).toBeVisible({
timeout: 30_000,
})
await expect(page.locator('.pdf-viewer, canvas, [data-testid="pdf-viewer"]').first()).toBeVisible(
{
timeout: 30_000,
},
)
// Toggle drawing mode
const drawToggleBtn = page.getByTitle('Toggle Annotation')