Skip to content

Commit

Permalink
refactor: adjust defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
cf-remylenoir committed Dec 17, 2024
1 parent a4af0a8 commit 73d03fd
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/components/modal/src/ModalHeader/ModalHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ export const ModalHeader = ({
testId = 'cf-ui-modal-header',
className,
children,
aria,
aria = {
closeIconLabel: 'Close',
},
...otherProps
}: ModalHeaderProps): React.ReactElement => {
const styles = getModalHeaderStyles();
Expand All @@ -59,7 +61,7 @@ export const ModalHeader = ({
<Flex alignItems="center" className={styles.buttonContainer}>
<IconButton
variant="transparent"
aria-label={aria?.closeIconLabel || 'Close'}
aria-label={aria.closeIconLabel}
size="small"
icon={<CloseIcon size="small" />}
onClick={() => {
Expand Down

0 comments on commit 73d03fd

Please sign in to comment.