File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
components/content-picker Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ import styled from '@emotion/styled';
22import { select } from '@wordpress/data' ;
33import { useMemo } from '@wordpress/element' ;
44import { __ } from '@wordpress/i18n' ;
5+ import { VisuallyHidden } from '@wordpress/components' ;
56import { v4 as uuidv4 } from 'uuid' ;
67import { ContentSearch } from '../content-search' ;
78import SortableList from './SortableList' ;
@@ -158,15 +159,18 @@ export const ContentPicker: React.FC<ContentPickerProps> = ({
158159 options = { searchOptions }
159160 />
160161 ) : (
161- label && (
162+ label &&
163+ ( hideLabelFromVision ? (
164+ < VisuallyHidden > { label } </ VisuallyHidden >
165+ ) : (
162166 < div
163167 style = { {
164168 marginBottom : '8px' ,
165169 } }
166170 >
167171 { label }
168172 </ div >
169- )
173+ ) )
170174 ) }
171175
172176 { Boolean ( content ?. length ) && (
You can’t perform that action at this time.
0 commit comments