Add missing aria labels (#42532)

This commit is contained in:
Piotr Jamróz 2021-12-01 10:16:09 +01:00 committed by GitHub
parent 143bc5c4ea
commit caf859f498
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 3 deletions

View File

@ -33,7 +33,7 @@ export function AddGraphiteFunction({ funcDefs }: Props) {
return (
<Segment
Component={<Button icon="plus" variant="secondary" className={cx(styles.button)} />}
Component={<Button icon="plus" variant="secondary" className={cx(styles.button)} aria-label="Add new function" />}
options={options}
onChange={setValue}
inputMinWidth={150}

View File

@ -50,6 +50,7 @@ function GraphiteQueryEditorContent() {
className={styles.toggleButton}
icon="pen"
variant="secondary"
aria-label="Toggle editor mode"
onClick={() => {
dispatch(actions.toggleEditorMode());
}}

View File

@ -8,5 +8,5 @@ export function PlayButton() {
const onClick = useCallback(() => {
dispatch(actions.unpause());
}, [dispatch]);
return <Button icon="play" onClick={onClick} type="button" variant="secondary" />;
return <Button icon="play" onClick={onClick} type="button" variant="secondary" aria-label="Unpause query" />;
}

View File

@ -52,7 +52,7 @@ export function TagsSection({ tags, state }: Props) {
}}
loadOptions={debouncedGetTagsAsSegments}
reloadOptionsOnChange={true}
Component={<Button icon="plus" variant="secondary" className={styles.button} />}
Component={<Button icon="plus" variant="secondary" className={styles.button} aria-label="Add new tag" />}
/>
)}
{state.paused && <PlayButton />}