Skip to content

Commit

Permalink
💄 style: Update Modal props
Browse files Browse the repository at this point in the history
  • Loading branch information
canisminor1990 committed Nov 26, 2024
1 parent a73f0ca commit 8f88fed
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Modal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { Maximize2, Minimize2, X } from 'lucide-react';
import { lighten } from 'polished';
import { ReactNode, memo, useState } from 'react';

import ActionIcon from '@/ActionIcon';
import ActionIcon, { type ActionIconProps } from '@/ActionIcon';
import Icon from '@/Icon';

const HEADER_HEIGHT = 56;
Expand Down Expand Up @@ -77,6 +77,7 @@ const useStyles = createStyles(

export type ModalProps = AntModalProps & {
allowFullscreen?: boolean;
closeIconProps?: ActionIconProps;
enableResponsive?: boolean;
maxHeight?: string | number | false;
paddings?: {
Expand All @@ -99,6 +100,7 @@ const Modal = memo<ModalProps>(
paddings,
maxHeight = '75dvh',
enableResponsive = true,
closeIconProps,
footer,
styles: stylesProps = {},
...rest
Expand All @@ -117,7 +119,7 @@ const Modal = memo<ModalProps>(
return (
<Drawer
className={cx(styles.drawerContent, className)}
closeIcon={<ActionIcon icon={X} />}
closeIcon={<ActionIcon icon={X} {...closeIconProps} />}
destroyOnClose={destroyOnClose}
extra={
allowFullscreen && (
Expand Down

0 comments on commit 8f88fed

Please sign in to comment.