From 13ea43387f4eb009a58418501b3c966b2a3c062f Mon Sep 17 00:00:00 2001 From: mheggelund Date: Thu, 29 Feb 2024 13:20:16 +0100 Subject: [PATCH] fix: Responsive scaling of add/edit model dialog on viewport zoom. --- .../AddModel/AddModelDialog/AddModelDialog.styled.ts | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/features/AddModel/AddModelDialog/AddModelDialog.styled.ts b/src/features/AddModel/AddModelDialog/AddModelDialog.styled.ts index 09bd1ca4..dce60ded 100644 --- a/src/features/AddModel/AddModelDialog/AddModelDialog.styled.ts +++ b/src/features/AddModel/AddModelDialog/AddModelDialog.styled.ts @@ -3,8 +3,17 @@ import styled from 'styled-components'; import { spacings } from '../../../tokens/spacings'; const StyledDialog = styled(Dialog)` - min-width: 600px; overflow-y: scroll; + width: fit-content; + max-width: 90vw; + max-height: 90vh; + + @media (min-width: 650px) { + min-width: 600px; + + max-height: 90vh; + overflow-x: scroll; + } `; const StyledDialogCustomContent = styled(Dialog.CustomContent)`