Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Design QA: Liquid Labware Modal / Generalize Modal Component #11142

Closed
14 tasks done
smb2268 opened this issue Jul 14, 2022 · 3 comments · Fixed by #11216
Closed
14 tasks done

Design QA: Liquid Labware Modal / Generalize Modal Component #11142

smb2268 opened this issue Jul 14, 2022 · 3 comments · Fixed by #11216
Assignees

Comments

@smb2268
Copy link
Contributor

smb2268 commented Jul 14, 2022

We want to move away from using BaseModal in the Modal organism. To generalize and streamline modals going forward, we're going to make the following components:

ModalShell component which

  • 1. Has an overlay
  • 2. Is centered in the viewport but this position can be overridden
  • 3. Has 1.5rem margin outside the modal when the screen size is small
  • 4. Has an optional closeOnOutsideClick function prop which will be called when the overlay is clicked
  • 5. Has optional header and footer props that will have fixed sticky positions with relevant styling
  • 6. Children will be displayed in between header and footer and have NO default padding/margin
  • 7. Has border radius, box shadow, and white background by default

ModalTitle component which will be used as the header in most cases with

  • 1. Required title prop
  • 2. An optional icon prop
  • 3. An optional exit button prop (default if this prop isn't passed in is the X icon)

This ticket will:

  • Add the above two components
  • Change modal organism to use these components when liquid FF is on, with extra styling for backwards compatibility
  • Use these components for labware liquid modal
  • Change padding to 1rem and background color to light grey for liquid labware modal

See this loom: https://www.loom.com/share/5b4c97dae1784ebabc6dc0c4199f61b6

@smb2268
Copy link
Contributor Author

smb2268 commented Jul 14, 2022

@smb2268
Copy link
Contributor Author

smb2268 commented Jul 14, 2022

@mmencarelli This modal is currently centered within the entire window, including the left nav bar. Do you want it centered on the screen excluding the nav bar?

@mmencarelli
Copy link

@smb2268 Let's have it centered within the viewport (entire window - navbar). As the user slowly starts to shrink screen size it'll overlap the navbar like we see below at 800px wide.

Screen Shot 2022-07-15 at 9 32 07 AM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants