From 7a0a1c53220c6ca2504c493beba2671628d4fcdb Mon Sep 17 00:00:00 2001 From: Danh Date: Thu, 21 Sep 2023 10:16:13 +0700 Subject: [PATCH] fix modal pc can not scroll --- src/components/Modal/index.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/components/Modal/index.tsx b/src/components/Modal/index.tsx index e873648bec..23609f8146 100644 --- a/src/components/Modal/index.tsx +++ b/src/components/Modal/index.tsx @@ -30,8 +30,6 @@ const StyledDialogContent = styled( ).attrs({ 'aria-label': 'dialog', })` - overflow-y: ${({ mobile }) => (mobile ? 'scroll' : 'hidden')}; - &[data-reach-dialog-content] { margin: ${({ margin }) => margin || '0 0 2rem 0'}; background-color: ${({ theme, bgColor }) => bgColor || theme.tableHeader}; @@ -39,7 +37,7 @@ const StyledDialogContent = styled( padding: 0; width: ${({ width }) => width || '50vw'}; height: ${({ height }) => height || 'auto'}; - overflow-y: ${({ mobile }) => (mobile ? 'scroll' : 'hidden')}; + overflow-y: scroll; overflow-x: hidden; align-self: ${({ mobile }) => (mobile ? 'flex-end' : 'center')}; max-width: ${({ maxWidth }) => (maxWidth && !isNaN(maxWidth) ? `${maxWidth}px` : maxWidth)};