File tree Expand file tree Collapse file tree
pages/SettingsPage/UserScheduleSettings/Availability Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ interface TimeSlotProps {
1313 onMouseOver ?: ( ) => void ;
1414 onClick ?: ( ) => void ;
1515 heightOverride ?: string ;
16+ widthOverride ?: string ;
1617 selected ?: boolean ;
1718}
1819
@@ -28,13 +29,14 @@ const TimeSlot: React.FC<TimeSlotProps> = ({
2829 onMouseOver,
2930 onClick,
3031 heightOverride = undefined ,
32+ widthOverride = undefined ,
3133 selected = false
3234} ) => {
3335 return (
3436 < Box
3537 sx = { {
3638 height : heightOverride ? heightOverride : small ? '25px' : '4.7vh' ,
37- width : small ? '81px' : '12.2%' ,
39+ width : widthOverride ? widthOverride : small ? '81px' : '12.2%' ,
3840 backgroundColor,
3941 cursor : onMouseEnter ? 'pointer' : undefined ,
4042 borderStyle : 'solid' ,
Original file line number Diff line number Diff line change @@ -38,7 +38,7 @@ const AvailabilityEditModal: React.FC<DRCEditModalProps> = ({
3838 title = { header }
3939 onSubmit = { onSubmit }
4040 submitText = "Save"
41- paperProps = { { maxWidth : '800px ' } }
41+ paperProps = { { maxWidth : '900px' , maxHeight : '680px ' } }
4242 >
4343 < EditAvailability
4444 editedAvailabilities = { confirmedAvailabilities }
Original file line number Diff line number Diff line change @@ -129,27 +129,34 @@ const EditAvailability: React.FC<EditAvailabilityProps> = ({
129129 Invert Availability
130130 </ NERButton >
131131 </ Grid >
132- < TimeSlot backgroundColor = { HeatmapColors [ 0 ] } small = { true } heightOverride = "40px " />
132+ < TimeSlot backgroundColor = { HeatmapColors [ 0 ] } widthOverride = "102px" heightOverride = "45px " />
133133 { currentlyDisplayedAvailabilities . map ( ( availability ) => (
134134 < TimeSlot
135135 key = { availability . dateSet . getTime ( ) }
136136 backgroundColor = { HeatmapColors [ 0 ] }
137- small = { true }
138- heightOverride = "40px "
137+ widthOverride = "102px"
138+ heightOverride = "45px "
139139 text = { getDayOfWeek ( availability . dateSet ) + ' ' + datePipe ( availability . dateSet ) }
140140 fontSize = { '12px' }
141141 />
142142 ) ) }
143143 { enumToArray ( REVIEW_TIMES ) . map ( ( time , timeIndex ) => (
144144 < Grid container item >
145- < TimeSlot backgroundColor = { HeatmapColors [ 0 ] } small = { true } text = { time } fontSize = { '13px' } />
145+ < TimeSlot
146+ backgroundColor = { HeatmapColors [ 0 ] }
147+ widthOverride = "102px"
148+ heightOverride = "32px"
149+ text = { time }
150+ fontSize = { '13px' }
151+ />
146152 { currentlyDisplayedAvailabilities . map ( ( availability , dayIndex ) => {
147153 const backgroundColor = availability . availability . includes ( timeIndex ) ? HeatmapColors [ 3 ] : HeatmapColors [ 0 ] ;
148154 return (
149155 < TimeSlot
150156 key = { timeIndex * enumToArray ( REVIEW_TIMES ) . length + dayIndex }
151157 backgroundColor = { backgroundColor }
152- small = { true }
158+ widthOverride = "102px"
159+ heightOverride = "32px"
153160 onMouseDown = { ( e ) => handleMouseDown ( e , availability , timeIndex ) }
154161 onMouseEnter = { ( e ) => handleMouseEnter ( e , availability , timeIndex ) }
155162 onMouseUp = { handleMouseUp }
You can’t perform that action at this time.
0 commit comments