💄(frontend) add margins to Dialog

On very small screens, Dialog were touching the screen borders.
Add a minimum margin to improve its visual appearance and ensure
better spacing.
This commit is contained in:
lebaudantoine
2024-08-14 14:03:56 +02:00
committed by aleb_the_flash
parent e3b7a1f77b
commit ccc23ff46a

View File

@@ -91,12 +91,8 @@ export const Dialog = ({
<StyledRACDialog {...dialogProps}> <StyledRACDialog {...dialogProps}>
{({ close }) => ( {({ close }) => (
<VerticallyOffCenter> <VerticallyOffCenter>
<Div <Div margin="auto" width="fit-content" maxWidth="full">
width="fit-content" <Div margin="1rem" pointerEvents="auto">
maxWidth="full"
margin="auto"
pointerEvents="auto"
>
<Box size="sm" type={boxType}> <Box size="sm" type={boxType}>
{!!title && ( {!!title && (
<Heading <Heading
@@ -124,6 +120,7 @@ export const Dialog = ({
)} )}
</Box> </Box>
</Div> </Div>
</Div>
</VerticallyOffCenter> </VerticallyOffCenter>
)} )}
</StyledRACDialog> </StyledRACDialog>