Skip to content

Commit e4c9fd3

Browse files
authored
Refactor Alert component to prevent nested interactive elements (#732)
1 parent 7b38ff3 commit e4c9fd3

File tree

1 file changed

+6
-9
lines changed
  • packages/pxweb2-ui/src/lib/components/Alert

1 file changed

+6
-9
lines changed

packages/pxweb2-ui/src/lib/components/Alert/Alert.tsx

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -220,15 +220,12 @@ export function Alert({
220220
</div>
221221
)}
222222
{clickable && (
223-
<div aria-live={ariaLive}>
224-
<button
225-
className={cl(classes['alert-arrow'])}
226-
aria-label={clickButtonAriaLabel}
227-
type="button"
228-
tabIndex={-1}
229-
>
230-
<Icon iconName={iconRight} />
231-
</button>
223+
<div
224+
aria-live={ariaLive}
225+
className={cl(classes['alert-arrow'])}
226+
aria-label={clickButtonAriaLabel}
227+
>
228+
<Icon iconName={iconRight} />
232229
</div>
233230
)}
234231
</div>

0 commit comments

Comments
 (0)