Changed the MiniCal component to gray out weekends and holidays #513
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Weekends and Holidays are now grayed out in MiniCal component. You can add new holidays by adding new Holiday objects to the holidays list.
I also changed some css styling to make it clear which day is currently selected and made it so that when you increase or decrease the month, the selected date stays the same while the highlighted date still changes. This was changed because if selected dates are automatically set by increasing or decreasing the month then it would land on disabled days like weekends or holidays.
Here, 1st of May is selected
Now, if we decrease the month to April, the selected date stays the same and the highlighted date is grayish. This was done because there might be holidays (in this case spring break) when we increase or decrease the month so I wouldn't want these dates to be selectable. Here, you can't click on 1st of April because it's in spring break.
Go back to March
This pull request is the first step towards integrating the MiniCal component into date inputs site wide.
I have not yet integrated this changed MiniCal into a modal to replace the Input component with input = "date".
Test Plan
I plan to integrate MiniCal into one of the modals and check if the forms are submitted correctly.