Skip to content

Commit

Permalink
[core] fix: add aria-label to some buttons (#4836)
Browse files Browse the repository at this point in the history
  • Loading branch information
evansjohnson authored Aug 10, 2021
1 parent 9c93f56 commit 0800e01
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 1 deletion.
2 changes: 2 additions & 0 deletions packages/core/src/components/forms/numericInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -431,12 +431,14 @@ export class NumericInput extends AbstractPureComponent2<HTMLInputProps & Numeri
return (
<ButtonGroup className={Classes.FIXED} key="button-group" vertical={true}>
<Button
aria-label="increment"
disabled={disabled || isIncrementDisabled}
icon="chevron-up"
intent={intent}
{...this.incrementButtonHandlers}
/>
<Button
aria-label="decrement"
disabled={disabled || isDecrementDisabled}
icon="chevron-down"
intent={intent}
Expand Down
1 change: 1 addition & 0 deletions packages/core/src/components/panel-stack/panelView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ export class PanelView extends AbstractPureComponent2<IPanelViewProps> {
}
return (
<Button
aria-label="Back"
className={Classes.PANEL_STACK_HEADER_BACK}
icon="chevron-left"
minimal={true}
Expand Down
1 change: 1 addition & 0 deletions packages/core/src/components/panel-stack2/panelView2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ export const PanelView2: PanelView2Component = <T extends Panel<object>>(props:
const maybeBackButton =
props.previousPanel === undefined ? null : (
<Button
aria-label="Back"
className={Classes.PANEL_STACK_HEADER_BACK}
icon="chevron-left"
minimal={true}
Expand Down
1 change: 1 addition & 0 deletions packages/core/src/components/tag/tag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ export class Tag extends AbstractPureComponent2<TagProps> {
const isLarge = large || tagClasses.indexOf(Classes.LARGE) >= 0;
const removeButton = isRemovable ? (
<button
aria-label="Remove"
type="button"
className={Classes.TAG_REMOVE}
onClick={this.onRemoveClick}
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/components/toast/toast.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export class Toast extends AbstractPureComponent2<IToastProps> {
<span className={Classes.TOAST_MESSAGE}>{message}</span>
<ButtonGroup minimal={true}>
{this.maybeRenderActionButton()}
<Button icon="cross" onClick={this.handleCloseClick} />
<Button aria-label="Close" icon="cross" onClick={this.handleCloseClick} />
</ButtonGroup>
</div>
);
Expand Down

1 comment on commit 0800e01

@blueprint-bot
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[core] fix: add aria-label to some buttons (#4836)

Previews: documentation | landing | table

Please sign in to comment.