Skip to content

Commit

Permalink
Update CopyBlock.tsx
Browse files Browse the repository at this point in the history
Added aria-label to button for better accessibility.
  • Loading branch information
tahoedesigner authored Sep 5, 2023
1 parent 8523011 commit bb05baa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/react-code-blocks/src/components/CopyBlock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export default function CopyBlock({
// @ts-ignore
<Code text={text} theme={theme} {...rest} />
)}
<Button type="button" onClick={handler} {...{ theme, copied }}>
<Button aria-label="Copy Code" type="button" onClick={handler} {...{ theme, copied }}>
<Copy
color={copied ? theme.stringColor : theme.textColor}
copied={copied}
Expand Down

0 comments on commit bb05baa

Please sign in to comment.