From 33a683d4b08b2ae2e041be33aef7b4675e5f681f Mon Sep 17 00:00:00 2001 From: Bailey Pumfleet Date: Thu, 7 Oct 2021 23:49:53 +0100 Subject: [PATCH] Add fix for create event type modal (#878) Co-authored-by: Alex Johansson --- pages/availability/troubleshoot.tsx | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/pages/availability/troubleshoot.tsx b/pages/availability/troubleshoot.tsx index 47f8141f..64c6173d 100644 --- a/pages/availability/troubleshoot.tsx +++ b/pages/availability/troubleshoot.tsx @@ -15,7 +15,7 @@ dayjs.extend(utc); export default function Troubleshoot({ user }: inferSSRProps) { const [loading, setLoading] = useState(true); const [availability, setAvailability] = useState([]); - const [selectedDate] = useState(dayjs()); + const [selectedDate, setSelectedDate] = useState(dayjs()); function convertMinsToHrsMins(mins: number) { let h = Math.floor(mins / 60); @@ -55,9 +55,17 @@ export default function Troubleshoot({ user }: inferSSRProps -
+
- Here is an overview of your day on {selectedDate.format("D MMMM YYYY")}: + Here is an overview of your day on{" "} + { + setSelectedDate(dayjs(e.target.value)); + }} + /> Tip: Hover over the bold times for a full timestamp