Skip to content

Commit b04f48b

Browse files
committed
changed width/height override to optional props, made days of the week typography elements
1 parent 05fb584 commit b04f48b

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

src/frontend/src/components/TimeSlot.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,15 @@ const TimeSlot: React.FC<TimeSlotProps> = ({
2828
onMouseUp,
2929
onMouseOver,
3030
onClick,
31-
heightOverride = undefined,
32-
widthOverride = undefined,
31+
heightOverride,
32+
widthOverride,
3333
selected = false
3434
}) => {
3535
return (
3636
<Box
3737
sx={{
38-
height: heightOverride ? heightOverride : small ? '25px' : '4.7vh',
39-
width: widthOverride ? widthOverride : small ? '81px' : '12.2%',
38+
height: (heightOverride ?? small) ? '25px' : '4.7vh',
39+
width: (widthOverride ?? small) ? '81px' : '12.2%',
4040
backgroundColor,
4141
cursor: onMouseEnter ? 'pointer' : undefined,
4242
borderStyle: 'solid',

src/frontend/src/pages/SettingsPage/UserScheduleSettings/Availability/EditAvailability.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,9 +137,9 @@ const EditAvailability: React.FC<EditAvailabilityProps> = ({
137137
widthOverride="106px"
138138
heightOverride="40px"
139139
text={
140-
<>
140+
<Typography>
141141
{getDayOfWeek(availability.dateSet)} <br /> {datePipe(availability.dateSet)}
142-
</>
142+
</Typography>
143143
}
144144
fontSize={'12px'}
145145
/>

0 commit comments

Comments
 (0)