Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@ export interface AlertActionCloseButtonProps extends ButtonProps {
}

export const AlertActionCloseButton: React.FunctionComponent<AlertActionCloseButtonProps> = ({
// eslint-disable-next-line @typescript-eslint/no-unused-vars
className = '',
className,
onClose = () => undefined as any,
'aria-label': ariaLabel = '',
variantLabel,
Expand All @@ -28,6 +27,7 @@ export const AlertActionCloseButton: React.FunctionComponent<AlertActionCloseBut
variant={ButtonVariant.plain}
onClick={onClose}
aria-label={ariaLabel === '' ? `Close ${variantLabel || alertVariantLabel} alert: ${title}` : ariaLabel}
className={className}
{...props}
>
<TimesIcon />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ export interface AlertToggleExpandButtonProps extends ButtonProps {
}

export const AlertToggleExpandButton: React.FunctionComponent<AlertToggleExpandButtonProps> = ({
'aria-label': ariaLabel,
'aria-label': ariaLabel = '',
variantLabel,
onToggleExpand,
isExpanded,
isExpanded = false,
...props
}: AlertToggleExpandButtonProps) => {
const { title, variantLabel: alertVariantLabel } = React.useContext(AlertContext);
Expand Down
Loading