feat(editor): board 01 annotation card, side column from 1 024 px

Annotations of the view move from under the drawing to the overview card
(grouped by category, name filter, all rows); side column from lg.
Properties panel gains « Toutes les annotations ».

E2E mapping (R-24): after a creation the card is hidden (the new annotation is
selected), so list(...).getByText(name) became selectionTag toContainText
(annotations, geometry, journey); row clicks go through pickAnnotation
(annotations, geometry, journey, structures); geometry's list count 0 while a
creation is pending became selectionTag count 0.
This commit is contained in:
bchanot committed 2026-11-06 21:40:25 +01:00
1 parent 51fd3db608
commit 6131225288
16 files changed
+404 -94

No files matched your search

+9 -13
View File
@@ -10,9 +10,11 @@ import {
geometryField,
openEditor,
openSection,
pickAnnotation,
pointOf,
saveDraft,
seedDraft,
selectionTag,
selectTab,
serverDocument,
shapeWith,
@@ -30,8 +32,6 @@ const dict = fr
const isPhone = (info: TestInfo) => info.project.name === 'chromium-375'
const creation = (page: Page) => page.getByTestId('annotation-creation')
const notice = (page: Page) => page.getByTestId('correction-notice')
const list = (page: Page) =>
page.getByRole('list', { name: dict['editor.annotations.list'] })
const tool = (page: Page, id: string) =>
page.getByRole('button', {
@@ -93,7 +93,7 @@ test.describe('editor geometry (adversarial)', () => {
await expect(notice(page)).toBeVisible()
await expect(page.getByTestId('overlay-click-cross')).toBeAttached()
const shown = await proposed(page)
await expect(list(page)).toHaveCount(0)
await expect(selectionTag(page)).toHaveCount(0) // an insertion selects it
// Cancelled: the notice goes, nothing was inserted.
await notice(page)
@@ -102,7 +102,7 @@ test.describe('editor geometry (adversarial)', () => {
})
.click()
await expect(notice(page)).toHaveCount(0)
await expect(list(page)).toHaveCount(0)
await expect(selectionTag(page)).toHaveCount(0) // an insertion selects it
// Confirmed: the same attempt again, the corrected position inserted.
await creation(page)
@@ -114,7 +114,7 @@ test.describe('editor geometry (adversarial)', () => {
.getByRole('button', { name: dict['editor.annotations.correction_use'] })
.click()
await expect(creation(page)).toHaveCount(0)
await expect(list(page).getByText('Bord')).toBeVisible()
await expect(selectionTag(page)).toContainText('Bord')
await expect(geometryField(page, dict, 'cx')).toHaveValue(shown.x)
await expect(geometryField(page, dict, 'cy')).toHaveValue(shown.y)
})
@@ -143,7 +143,7 @@ test.describe('editor geometry (adversarial)', () => {
})
.click()
await expect(notice(page)).toHaveCount(0)
await expect(list(page)).toHaveCount(0)
await expect(selectionTag(page)).toHaveCount(0) // an insertion selects it
// Then confirmed: the same attempt again inserts the corrected position.
await creation(page)
.getByRole('button', { name: dict['editor.annotations.create'] })
@@ -152,7 +152,7 @@ test.describe('editor geometry (adversarial)', () => {
await notice(page)
.getByRole('button', { name: dict['editor.annotations.correction_use'] })
.click()
await expect(list(page).getByText('Bord détail')).toBeVisible()
await expect(selectionTag(page)).toContainText('Bord détail')
})
test('a point inherited out of its frame is repaired through the geometry group', async ({
@@ -165,9 +165,7 @@ test.describe('editor geometry (adversarial)', () => {
)
requests.forbid(actor.account.email, actor.account.password)
await viewChip(page, 'Détail A').click()
await list(page)
.getByRole('button', { name: /Hors cadre/ })
.click()
await pickAnnotation(page, dict, /Hors cadre/)
const issues = page.getByTestId('annotation-geometry-issues')
await expect(issues).toBeVisible()
const verification = page.getByRole('tab', {
@@ -454,9 +452,7 @@ test.describe('editor touch path (real browser)', () => {
// A movable selection needs the touch itself: the browser reads touch-action at
// touchstart, so a drag of the selected marker must not be left to the pan.
await list(page)
.getByRole('button', { name: /Tactile/ })
.click()
await pickAnnotation(page, dict, /Tactile/)
await expect.poll(touchAction).toBe('none')
const cx = geometryField(page, dict, 'cx')
await expect(cx).toHaveValue('500')