Skip to content

Commit

Permalink
Rename function a11ySpeak
Browse files Browse the repository at this point in the history
  • Loading branch information
sirreal committed Sep 17, 2024
1 parent 3d6f812 commit b4ae046
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/interactivity-router/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ export const { state, actions } = store( 'core/router', {
navigation.hasFinished = false;
}
if ( screenReaderAnnouncement ) {
a11yAnnounce( 'loading' );
a11ySpeak( 'loading' );
}
}, 400 );

Expand Down Expand Up @@ -317,7 +317,7 @@ export const { state, actions } = store( 'core/router', {
}

if ( screenReaderAnnouncement ) {
a11yAnnounce( 'loaded' );
a11ySpeak( 'loaded' );
}

// Scroll to the anchor if exits in the link.
Expand Down Expand Up @@ -366,7 +366,7 @@ export const { state, actions } = store( 'core/router', {
*
* @param messageKey The message to be announced by assistive technologies.
*/
function a11yAnnounce( messageKey: keyof typeof navigationTexts ) {
function a11ySpeak( messageKey: keyof typeof navigationTexts ) {
if ( ! hasLoadedNavigationTextsData ) {
hasLoadedNavigationTextsData = true;
const content = document.getElementById(
Expand Down

0 comments on commit b4ae046

Please sign in to comment.