diff --git a/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.module.scss b/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.module.scss index 881700c..26758cd 100644 --- a/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.module.scss +++ b/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.module.scss @@ -9,18 +9,12 @@ justify-content: center; background: rgb(0 0 0 / 40%); transition: visibility 0.2s ease-out; - visibility: hidden; - display: none; + display: flex; @include xs { align-items: flex-end; } - &.open { - visibility: visible; - display: flex; - } - .modalBox { color: color('gray09'); background-color: color('white'); diff --git a/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.tsx b/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.tsx index ec7e596..ba1c5ec 100644 --- a/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.tsx +++ b/apps/web/src/components/molecules/Modal/components/ModalContentsBase/index.tsx @@ -2,6 +2,7 @@ import { ReactElement, useRef } from 'react'; import { Button } from '@dnd-academy/ui'; import clsx from 'clsx'; +import { AnimatePresence, motion } from 'motion/react'; import { useOnClickOutside, useScrollLock } from 'usehooks-ts'; import GlobalPortal from '@/components/global/GlobalPortal'; @@ -25,26 +26,42 @@ function ModalContentsBase({ children: child, title, size = 'medium' } : Props) return ( - {open && ( -
-
+ {open && ( + -
-

{title}

-
- {child} -
-
- )} + +
+

{title}

+
+ {child} +
+ + )} +
); }