Allow passing props through to determine modal options

This commit is contained in:
Dane Everitt 2020-08-17 22:04:24 -07:00
parent c28cba92e2
commit e873c597bb
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
4 changed files with 39 additions and 26 deletions

View file

@ -86,12 +86,14 @@ const Modal: React.FC<ModalProps> = ({ visible, appear, dismissable, showSpinner
</div>
}
{showSpinnerOverlay &&
<div
css={tw`absolute w-full h-full rounded flex items-center justify-center`}
style={{ background: 'hsla(211, 10%, 53%, 0.25)' }}
>
<Spinner/>
</div>
<Fade timeout={150} appear in>
<div
css={tw`absolute w-full h-full rounded flex items-center justify-center`}
style={{ background: 'hsla(211, 10%, 53%, 0.25)' }}
>
<Spinner/>
</div>
</Fade>
}
<div css={tw`bg-neutral-800 p-6 rounded shadow-md overflow-y-scroll transition-all duration-150`}>
{children}