fix(CopyButton): add aria-label for screen reader accessibility
Set aria-label to the same value as title so icon-only button is properly announced by assistive technology.
This commit is contained in:
@@ -53,6 +53,7 @@ export const CopyButton: React.FC<CopyButtonProps> = ({
|
|||||||
type="button"
|
type="button"
|
||||||
onClick={handleCopy}
|
onClick={handleCopy}
|
||||||
title={tooltip ?? t('buttons.copy')}
|
title={tooltip ?? t('buttons.copy')}
|
||||||
|
aria-label={tooltip ?? t('buttons.copy')}
|
||||||
className={cn(
|
className={cn(
|
||||||
buttonVariants({ variant, size }),
|
buttonVariants({ variant, size }),
|
||||||
copied &&
|
copied &&
|
||||||
|
|||||||
Reference in New Issue
Block a user