diff --git a/packages/components/src/modal/types.ts b/packages/components/src/modal/types.ts index 7e8295f39996b..6169e42a8a2d4 100644 --- a/packages/components/src/modal/types.ts +++ b/packages/components/src/modal/types.ts @@ -51,7 +51,7 @@ export type ModalProps = { /** * Label on the close button. * - * @default `__( 'Close dialog' )` + * @default `__( 'Close' )` */ closeButtonLabel?: string; /** diff --git a/test/e2e/specs/editor/various/a11y.spec.js b/test/e2e/specs/editor/various/a11y.spec.js index 60da01ef38986..c487656b4861e 100644 --- a/test/e2e/specs/editor/various/a11y.spec.js +++ b/test/e2e/specs/editor/various/a11y.spec.js @@ -130,7 +130,9 @@ test.describe( 'a11y (@firefox, @webkit)', () => { ); const preferencesModalContent = preferencesModal.locator( 'role=document' ); - const closeButton = page.locator( 'role=button[name="Close dialog"i]' ); + const closeButton = preferencesModal.locator( + 'role=button[name="Close"i]' + ); const generalTab = preferencesModal.locator( 'role=tab[name="General"i]' );