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:
1 parent
51fd3db608
commit
6131225288
16 files changed
+404
-94
No files matched your search
@@ -8,8 +8,10 @@ import {
|
||||
editorActor,
|
||||
geometryField,
|
||||
openEditor,
|
||||
pickAnnotation,
|
||||
saveDraft,
|
||||
seedDraft,
|
||||
selectionTag,
|
||||
selectTab,
|
||||
serverDocument,
|
||||
standardShape,
|
||||
@@ -92,7 +94,7 @@ test.describe('editor annotations (A3)', () => {
|
||||
.getByLabel(dict['editor.annotations.zone'])
|
||||
.selectOption('zone-a')
|
||||
await createFromPanel(page)
|
||||
await expect(list(page).getByText('Point un')).toBeVisible()
|
||||
await expect(selectionTag(page)).toContainText('Point un')
|
||||
await expect(properties(page)).toBeVisible()
|
||||
const placed = await geometryField(page, dict, 'cx').inputValue()
|
||||
expect(Math.abs(Number(placed) - 300)).toBeLessThan(1)
|
||||
@@ -110,7 +112,7 @@ test.describe('editor annotations (A3)', () => {
|
||||
.click()
|
||||
await fillCreation(page, { fr: 'Zone une', en: 'Zone one' })
|
||||
await createFromPanel(page)
|
||||
await expect(list(page).getByText('Zone une')).toBeVisible()
|
||||
await expect(selectionTag(page)).toContainText('Zone une')
|
||||
|
||||
// A link to the detail view: the same tracing, the opened view chosen.
|
||||
await tool(page, 'link').click()
|
||||
@@ -125,7 +127,7 @@ test.describe('editor annotations (A3)', () => {
|
||||
.click()
|
||||
await fillCreation(page, { fr: 'Accès un', en: 'Access one' }, 'detail-a')
|
||||
await createFromPanel(page)
|
||||
await expect(list(page).getByText('Accès un')).toBeVisible()
|
||||
await expect(selectionTag(page)).toContainText('Accès un')
|
||||
await expect(
|
||||
page.getByRole('button', {
|
||||
name: dict['editor.annotations.undo'],
|
||||
@@ -134,9 +136,7 @@ test.describe('editor annotations (A3)', () => {
|
||||
).toBeEnabled()
|
||||
|
||||
// A numeric edit of the point, then undo and redo.
|
||||
await list(page)
|
||||
.getByRole('button', { name: /Point un/ })
|
||||
.click()
|
||||
await pickAnnotation(page, dict, /Point un/)
|
||||
const cx = geometryField(page, dict, 'cx')
|
||||
await cx.fill('420')
|
||||
await cx.press('Enter')
|
||||
@@ -234,7 +234,7 @@ test.describe('editor annotations (A3)', () => {
|
||||
.focus()
|
||||
await page.keyboard.press('Enter')
|
||||
await expect(creation(page)).toHaveCount(0)
|
||||
await expect(list(page).getByText('Clavier')).toBeVisible()
|
||||
await expect(selectionTag(page)).toContainText('Clavier')
|
||||
await expect(geometryField(page, dict, 'cx')).toHaveValue('250')
|
||||
|
||||
const cy = geometryField(page, dict, 'cy')
|
||||
@@ -252,7 +252,7 @@ test.describe('editor annotations (A3)', () => {
|
||||
.getByRole('button', { name: dict['editor.annotations.create'] })
|
||||
.focus()
|
||||
await page.keyboard.press('Enter')
|
||||
await expect(list(page).getByText('Zone clavier')).toBeVisible()
|
||||
await expect(selectionTag(page)).toContainText('Zone clavier')
|
||||
const vertexX = page.getByLabel(
|
||||
dict['editor.annotations.geometry.vertex_x'].replace('{n}', '1'),
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user