diff --git a/apps/app/e2e/shell/editor-shell-journeys.spec.ts b/apps/app/e2e/shell/editor-shell-journeys.spec.ts index d40ed42d..357a0e48 100644 --- a/apps/app/e2e/shell/editor-shell-journeys.spec.ts +++ b/apps/app/e2e/shell/editor-shell-journeys.spec.ts @@ -149,7 +149,7 @@ test.describe('editor shell journeys (H)', () => { await selectTab(page, dict, 'general') const original = await nameField(page).inputValue() await nameField(page).fill('Saisi, jamais validé') - // « Annuler » is aria-disabled until the typed text is committed: press at its box. + // « Défaire » is aria-disabled until the typed text is committed: press at its box. await pressAtBox(page, historyButton(page, dict, 'undo')) await expect(nameField(page)).toHaveValue(original) await expect(saveLine(page)).not.toHaveText(UNSAVED_LINE) @@ -157,7 +157,7 @@ test.describe('editor shell journeys (H)', () => { await expect(nameField(page)).toHaveValue('Saisi, jamais validé') }) - test('a field left empty keeps its error: Tab to « Annuler », Enter, nothing undone, focus back', async ({ + test('a field left empty keeps its error: Tab to « Défaire », Enter, nothing undone, focus back', async ({ page, }) => { await open(page) diff --git a/apps/app/e2e/shell/editor-shell-layout.spec.ts b/apps/app/e2e/shell/editor-shell-layout.spec.ts index 8e373224..3274c506 100644 --- a/apps/app/e2e/shell/editor-shell-layout.spec.ts +++ b/apps/app/e2e/shell/editor-shell-layout.spec.ts @@ -268,7 +268,7 @@ test.describe('editor shell keyboard order (H)', () => { await dropLateReplays(context) }) - test('header, tab list, Annuler, Rétablir, then the tools, the canvas and the side column', async ({ + test('header, tab list, Défaire, Refaire, then the tools, the canvas and the side column', async ({ page, }) => { await open(page) @@ -290,7 +290,7 @@ test.describe('editor shell keyboard order (H)', () => { ]) }) - test('with the panel open: header, tab list, Annuler, Rétablir, the panel, then the page content', async ({ + test('with the panel open: header, tab list, Défaire, Refaire, the panel, then the page content', async ({ page, }) => { await open(page) diff --git a/apps/app/e2e/shell/editor-shell.spec.ts b/apps/app/e2e/shell/editor-shell.spec.ts index fc51a444..b37472e9 100644 --- a/apps/app/e2e/shell/editor-shell.spec.ts +++ b/apps/app/e2e/shell/editor-shell.spec.ts @@ -146,7 +146,7 @@ test.describe('editor shell, kept places (B2a)', () => { for (const scrolled of [false, true]) { await page.evaluate((y) => window.scrollTo(0, y), scrolled ? 400 : 0) for (const target of targets) await target.click({ trial: true }) - // « Annuler » / « Rétablir » may be aria-disabled (a trial click would wait). + // « Défaire » / « Refaire » may be aria-disabled (a trial click would wait). for (const kind of ['undo', 'redo'] as const) { const button = historyButton(page, dict, kind) await button.scrollIntoViewIfNeeded() diff --git a/apps/app/e2e/support/editor.ts b/apps/app/e2e/support/editor.ts index b9001960..046b4bba 100644 --- a/apps/app/e2e/support/editor.ts +++ b/apps/app/e2e/support/editor.ts @@ -437,7 +437,7 @@ export function savedLine(dict: Dict, revision: number): RegExp { ) } -/** The header « Annuler » / « Rétablir » button (enabled ones take a plain click). */ +/** The header « Défaire » / « Refaire » button (enabled ones take a plain click). */ export const historyButton = (page: Page, dict: Dict, kind: 'undo' | 'redo') => page.getByRole('button', { name: dict[`editor.history.${kind}_title`], diff --git a/apps/app/src/components/editor/EditorTabs.tsx b/apps/app/src/components/editor/EditorTabs.tsx index cf099ca5..33d736fe 100644 --- a/apps/app/src/components/editor/EditorTabs.tsx +++ b/apps/app/src/components/editor/EditorTabs.tsx @@ -144,7 +144,7 @@ interface EditorTabsProps { /** * The draft's tab row (boards 04 and 05): the four tabs from 640 px, Annotations and * Vérification below it with « Plus » opening a disclosure of the others (no measurement). - * « Annuler » and « Rétablir » sit at the right end of the row on every tab. + * « Défaire » and « Refaire » sit at the right end of the row on every tab. */ export default function EditorTabs({ active, diff --git a/apps/app/src/components/editor/HistoryButtons.tsx b/apps/app/src/components/editor/HistoryButtons.tsx index acf509ca..e84b2dc0 100644 --- a/apps/app/src/components/editor/HistoryButtons.tsx +++ b/apps/app/src/components/editor/HistoryButtons.tsx @@ -13,8 +13,8 @@ import EditorGlyph from './EditorGlyph' type Direction = 'undo' | 'redo' const SHORTCUT: Record = { - undo: 'Control+Z', - redo: 'Control+Shift+Z', + undo: 'Control+Z Meta+Z', + redo: 'Control+Shift+Z Meta+Shift+Z', } const BUTTON = @@ -38,7 +38,7 @@ function asField(element: Element | EventTarget | null): HTMLElement | null { * pointer-down, natural when Tab reaches the button), the click or key then reads the * store, so the typed text is the last change the undo reverts. A field whose commit was * refused keeps its error: the step is skipped and focus goes back to it. The field is - * remembered across the pair: from a field, « Annuler » is two Shift+Tab away. A touch + * remembered across the pair: from a field, « Défaire » is two Shift+Tab away. A touch * press fires pointer leave between its up and its click, so only a mouse leaving the * button forgets the field (a hovering pointer that left meant no press), or a cancel. */ @@ -50,7 +50,7 @@ function usePress( const forget = () => { left.current = null } - // Tab from « Rétablir » to « Annuler » (or back) is still the same press of the pair. + // Tab from « Refaire » to « Défaire » (or back) is still the same press of the pair. const onBlur = (event: FocusEvent) => { const pair = event.currentTarget.parentElement if (!pair?.contains(event.relatedTarget as Node | null)) forget() @@ -104,7 +104,7 @@ function HistoryButton({