Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions blocks/editable/format-toolbar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { isUndefined } from 'lodash';
*/
import { __ } from '@wordpress/i18n';
import { Component } from '@wordpress/element';
import { IconButton, Toolbar, withA11yMessages } from '@wordpress/components';
import { IconButton, Toolbar, withSpokenMessages } from '@wordpress/components';
import { keycodes } from '@wordpress/utils';

/**
Expand Down Expand Up @@ -193,4 +193,4 @@ class FormatToolbar extends Component {
}
}

export default withA11yMessages( FormatToolbar );
export default withSpokenMessages( FormatToolbar );
4 changes: 2 additions & 2 deletions blocks/url-input/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import scrollIntoView from 'dom-scroll-into-view';
import { __, sprintf, _n } from '@wordpress/i18n';
import { Component } from '@wordpress/element';
import { keycodes } from '@wordpress/utils';
import { Spinner, withInstanceId, withA11yMessages } from '@wordpress/components';
import { Spinner, withInstanceId, withSpokenMessages } from '@wordpress/components';

const { UP, DOWN, ENTER } = keycodes;

Expand Down Expand Up @@ -214,4 +214,4 @@ class UrlInput extends Component {
}
}

export default withA11yMessages( withInstanceId( UrlInput ) );
export default withSpokenMessages( withInstanceId( UrlInput ) );
4 changes: 2 additions & 2 deletions components/form-token-field/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import Token from './token';
import TokenInput from './token-input';
import SuggestionsList from './suggestions-list';
import withInstanceId from '../higher-order/with-instance-id';
import withA11yMessages from '../higher-order/with-a11y-messages';
import withSpokenMessages from '../higher-order/with-spoken-messages';

const initialState = {
incompleteTokenValue: '',
Expand Down Expand Up @@ -564,4 +564,4 @@ FormTokenField.defaultProps = {
},
};

export default withA11yMessages( withInstanceId( FormTokenField ) );
export default withSpokenMessages( withInstanceId( FormTokenField ) );
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { Component } from 'element';
*
* @return {Component} Component with an instanceId prop.
*/
function withA11yMessages( WrappedComponent ) {
function withSpokenMessages( WrappedComponent ) {
return class extends Component {
constructor() {
super( ...arguments );
Expand All @@ -41,4 +41,4 @@ function withA11yMessages( WrappedComponent ) {
};
}

export default withA11yMessages;
export default withSpokenMessages;
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ import { isFunction } from 'lodash';
/**
* Internal dependencies
*/
import withA11yMessages from '../';
import withSpokenMessages from '../';

describe( 'withA11yMessages', () => {
describe( 'withSpokenMessages', () => {
it( 'should generate speak and debouncedSpeak props', () => {
const testSpeak = jest.fn();
const testDebouncedSpeak = jest.fn();
const DumpComponent = withA11yMessages( ( { speak, debouncedSpeak } ) => {
const DumpComponent = withSpokenMessages( ( { speak, debouncedSpeak } ) => {
testSpeak( isFunction( speak ) );
testDebouncedSpeak( isFunction( debouncedSpeak ) );
return <div />;
Expand Down
2 changes: 1 addition & 1 deletion components/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ export { default as Popover } from './popover';
// Higher-Order Components
export { default as withFocusReturn } from './higher-order/with-focus-return';
export { default as withInstanceId } from './higher-order/with-instance-id';
export { default as withA11yMessages } from './higher-order/with-a11y-messages';
export { default as withSpokenMessages } from './higher-order/with-spoken-messages';
4 changes: 2 additions & 2 deletions editor/inserter/menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { connect } from 'react-redux';
*/
import { __, _n, sprintf } from '@wordpress/i18n';
import { Component } from '@wordpress/element';
import { Popover, withFocusReturn, withInstanceId, withA11yMessages } from '@wordpress/components';
import { Popover, withFocusReturn, withInstanceId, withSpokenMessages } from '@wordpress/components';
import { keycodes } from '@wordpress/utils';
import { getCategories, getBlockTypes, BlockIcon } from '@wordpress/blocks';

Expand Down Expand Up @@ -440,7 +440,7 @@ const connectComponent = connect(

export default flow(
withInstanceId,
withA11yMessages,
withSpokenMessages,
withFocusReturn,
connectComponent
)( InserterMenu );