Fixed Upload Data Modal and Download Data Modal#331
Conversation
as title indicates, fixed the sizing glitches when the window is squished. Also slightly adjusted the download data modal so by default full window the box isnt surpassing the height of the window.
There was a problem hiding this comment.
Pull request overview
This pull request addresses sizing glitches in the Upload Data Modal and Download Data Modal when the browser window is resized or on smaller screens. The changes add comprehensive responsive styles using CSS media queries at consistent breakpoints (1400px, 1200px, 1000px, 850px) to ensure modals and their contents scale appropriately. Additionally, the default height of the download modal's table wrapper has been reduced from 35rem to 30rem to prevent it from exceeding the viewport height on full-screen windows.
Changes:
- Added responsive media queries to upload form component for adjusted sizing at smaller breakpoints
- Added responsive padding and width adjustments to base modal component
- Added comprehensive responsive styles to upload and download modals with progressive sizing reduction
- Reduced default table wrapper height in download modal from 35rem to 30rem
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| UploadForm.module.scss | Added responsive styles for upload form container, images, and content at 1200px, 1000px, and 850px breakpoints |
| BaseModal.module.scss | Added responsive padding and max-width adjustments for smaller screens at 1200px and 850px breakpoints |
| uploadModal.module.scss | Added comprehensive responsive styles for modal dimensions and spacing at 1200px, 1000px, and 850px breakpoints |
| downloadModal.module.scss | Reduced default table height and added responsive styles at 1400px, 1200px, 1000px, and 850px breakpoints |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| width: 60rem; | ||
|
|
||
| .tableWrapper { | ||
| height: 32rem; |
There was a problem hiding this comment.
The table wrapper height at the 1400px breakpoint (32rem) is larger than the default height (30rem). This creates an inconsistent responsive behavior where the table actually grows when moving from full window size to 1400px breakpoint, which contradicts typical responsive design patterns where content should shrink or maintain size at smaller breakpoints.
| height: 32rem; | |
| height: 30rem; |
There was a problem hiding this comment.
You've overlooked so much many things fool!
Extremely infinite major functional hugepick is the spacing under the upload/download button when I have it in split screen (see below)
I can't believe you would be so careless in your blumbering.... big buffoon I swear. Don't let it happen again.
Both are half my screen but the download one is without a doubt a TON more cramped below the red button, and the upload one has wayyy too much padding below it? Bakaaaa!!!
There was a problem hiding this comment.
You blithering fool! You absolutely definitively must implement this in the UI folder of components and do as much as you can in there lest it cascade in a catastrophically faulty manner. More work for you <3
Looks terrible as well. This is the antithesis of the correct end product. You have created something so diametrically opposite to what we expected that you absolutely need to start worrying.
Be concerned about mobile sizes whether you want to or not. It will be seamless to use on mobile without a ground up redesign.
| width: 35rem; | ||
| padding: 0 1.5rem; | ||
|
|
||
| .submitButton { |
There was a problem hiding this comment.
Can you put this styling directly into our button component? Might make it cascade to the whole codebase a bit better
| } | ||
|
|
||
| @media screen and (max-width: 1200px) { | ||
| .downloadModal { |
There was a problem hiding this comment.
This sorta stuff could also be done in baseModal maybe so itll affect this, the upload and the preset and every other modal down the line
pre approved by kai and salma for real
Some more tweaks on the home page, and made the preset card modal when clicked from the home screen responsive. Removed upload file option from preset card as per instructed
gr812b
left a comment
There was a problem hiding this comment.
The 1000 and 850 breakpoints feel a bit odd, last I believe there are standard ones like 1400+ for ultrawide, down to 1024 for normal, then down to 768 for handhelds and <768 for rest. Might wanna just change those. Might also be good to write a mixin in the @Styles folder to centralize these values
| max-width: 400px; | ||
| } | ||
|
|
||
| .stepImage { | ||
| max-width: 400px; | ||
| min-height: 250px; | ||
| height: 250px; |
| min-height: 250px; | ||
| height: 250px; |
| min-height: 200px; | ||
| height: 200px; |
There was a problem hiding this comment.
In the future, before committing just check what you have made changes to, I assume this was accidental. Useful to make sure you intended to make those changes. I'll fix tn!
There was a problem hiding this comment.
i forgot to review, sorry. I will fix that asap, thank you
| min-height: 16rem; | ||
| } | ||
|
|
||
| @media screen and (max-width: 850px) { |
There was a problem hiding this comment.
850 corresponds to what device?
| padding: 0 1rem; | ||
| max-width: 90rem; | ||
|
|
||
| .formWrapper { | ||
| display: flex; | ||
| gap: 2rem; | ||
|
|
||
| .uploadForm { | ||
| display: flex; | ||
| flex-direction: column; | ||
| align-items: center; | ||
| width: 50%; | ||
|
|
||
| .title { | ||
| all: unset; | ||
| @include fonts.title-large; | ||
| } | ||
| } |
There was a problem hiding this comment.
Seemingly lots of changes that would change normal screen size behaviour?
| <FileTable | ||
| files={getFolders(files || [])} | ||
| selectedFiles={selectedFiles} | ||
| setSelectedFiles={setSelectedFiles} |
There was a problem hiding this comment.
Looks like even on normal screen sizes these changes eliminate the upload functionality entirely from the preset files modal
There was a problem hiding this comment.
IIRC, I thought we agreed that the upload functionality wasnt necessary when clicking on the preset files in general?
There was a problem hiding this comment.
No, only on mobile sizes. Neccesary on desktop
| @@ -7,45 +7,58 @@ | |||
| background: var(--background); | |||
| gap: 1rem; | ||
| } | ||
| } | ||
| } No newline at end of file |
…different screen sizes. Added ultrawide/high resolution monitor compatibility
|
Wasnt entirely sure about the mixin thing so I would much appreciate a checkup on the recent commit |
gr812b
left a comment
There was a problem hiding this comment.
Just gonna review functionality first
No space between button and upload box. Also did you make the default one full screen smaller? Should remain at original size for full sized screens.
At 1000px and 1024px it changes size. Why at both so close? Just stick to one (1024)
This one is also smaller. Keep the original size for full-sized screens. Also button spacing wrong here too.
When shrinking the screen it can look like this, need reactivity for the table
For the select modal, the table shrinks properly. Strange that its diff here and on download. Also as stated elsewhere need that functionality
| import { showErrorToast, showSuccessToast } from '@components/ui/toastNotification/ToastNotification'; | ||
| import { rightArrowIcon } from '@assets/icons'; | ||
| import styles from './uploadModal.module.scss'; | ||
| import baseModalStyles from '@components/ui/baseModal/BaseModal.module.scss'; |
There was a problem hiding this comment.
Don't do this!
Styles are all co-located. If you have styles in baseModalStyles, they are meant to apply to parts in the baseModal. When I suggested doing styles in baseModal this was because you could just apply the styles to the root directly. You should never import a different style file
Mixins look perfect. Just make sure to use these everywhere throughout the codebase |
gr812b
left a comment
There was a problem hiding this comment.
Not gonna go through it all but you should use your defined variables and mixin at each of these spots
| .submitButton { | ||
| margin-top: 1.25rem; | ||
| /* Responsive styles for smaller desktop windows */ | ||
| @media screen and (max-width: 1400px) { |
| } | ||
| } | ||
|
|
||
| @media screen and (max-width: 1024px) { |
| } | ||
| } | ||
|
|
||
| @media screen and (max-width: 768px) { |






as title indicates, fixed the sizing glitches when the window is squished. Also slightly adjusted the download data modal so by default full window the box isnt surpassing the height of the window.

