Merge pull request #17744 from luchillo17/fix/BCKSTG-153-screen-readers---home---compo

fix(catalog): Add Screen Reader notice Edit Metadata Link opens in new tab
This commit is contained in:
Fredrik Adelöw
2023-05-11 13:56:25 +02:00
committed by GitHub
2 changed files with 8 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/core-components': patch
---
Fix accessibility issue with Edit Metadata Link on screen readers missing notice about opening in a new tab.
@@ -188,6 +188,9 @@ export const Link = React.forwardRef<any, LinkProps>(
<MaterialLink
{...(newWindow ? { target: '_blank', rel: 'noopener' } : {})}
{...props}
{...(props['aria-label']
? { 'aria-label': `${props['aria-label']}, Opens in a new window` }
: {})}
ref={ref}
href={to}
onClick={handleClick}