-
Notifications
You must be signed in to change notification settings - Fork 16
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
Extended width of years with 3 quarters to full width #582
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I could have made this more clear, but one of the main things I wanted to tackle with #559 is that if there are 4 quarters, it should not wrap to two lines.

This does mean you'd need to adjust the class name using JS depending on how many quarters are shown. I am open to rediscussing this, but part of the objective with the previous style change was so that adding a summer quarter should not make the year be double the height. Let me know your thoughts.
Let me know what you think should happen at widths greater than 1990px.
The body wrapper should have a max width so the planner can't expand too much
I believe I fixed the code to do this, let me know what you think.
When you said it "should", does that mean it already has a max width, or I need to add a max width? Because my most recent commit still doesn't look great beyond ~1900px. |
you would need to add a max width |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just updated those changes that you requested. Regarding the max width, do you have any thoughts on how that should be implemented? I'm gonna try something and push some code for that soon, but if you have thoughts lmk. |
@charlieweinberger that should be fine. just check that when you |
… but all other years remain the same
…ar accordion content width
…use data attribute to properly size quarters
30fd159
to
98940b4
Compare
…s are the same width, which for the longest year is the full width
Just pushed code that I believe fixes this issue. Let me know what you think @Awesome-E . Also note that this code uses css variables, but I can also make it work with data attributes. The method with css variables looks messier in the react file, but much nicer in the css file. The data attribute method is the opposite - it looks cleaner in the react file, but much more bloated in the css file. I prefer the css variables method. |
@Awesome-E I present to you... infinite hard-coding. Explanation (which is also in the code, since I think for future reference an explanation is necessary):
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it works perfectly, but there's nothing you can really do once a screen size gets too big. This is definitely good enough for what it is though – and the comment explaining the behavior of the sizing looks good to me.
Yea, its definitely not perfect, but at that width, some other things start to break too, like the course search floating element on the right. At that point, a more substantial change is needed, like setting a max width for the overall roadmap. That maybe be helpful, but what I have right now is definitely better than the current implementation, and most likely to not cause issues for most users. I'll merge now, and then in the future maybe we can deal with screen widths larger than 2600px. |
Description
For larger screens (wider than 1648 pixels), years with 3 quarters in one row now take up the full width, instead of only taking up 3/4 of the width. Screens less wide than 1648px maintain their current functionality. Most times the breakpoint for this was 1658px, but a few times it was 1648px, and I'm not sure why it switched back and forth. I went with 1648px in the code to cover the edge case between those 10 pixels. Note that this pull request doesn't get completely rid of this problem - it just moves the breakpoint from 1648px to 1990px. This is definitely a lot better, and worth merging, but I'm not sure it's completely finished. Let me know what you think should happen at widths greater than 1990px.
Screenshots
Before:

After:

Test Plan
Issues
Closes #559