mirror of
https://github.com/alexmickelson/canvasManagement.git
synced 2026-03-26 07:38:33 -06:00
deduplicate days
This commit is contained in:
@@ -20,15 +20,15 @@ export const CalendarMonth = ({ month }: { month: CalendarMonthModel }) => {
|
||||
return (
|
||||
<>
|
||||
<h3 className="text-center text-2xl">
|
||||
<button
|
||||
{/* <button
|
||||
type="button"
|
||||
className="btn btn-link"
|
||||
onClick={toggleCollapse}
|
||||
aria-expanded={!isCollapsed}
|
||||
aria-controls={monthName}
|
||||
>
|
||||
> */}
|
||||
{monthName}
|
||||
</button>
|
||||
{/* </button> */}
|
||||
</h3>
|
||||
|
||||
<div id={monthName}>
|
||||
|
||||
@@ -10,20 +10,21 @@ export default function Day({ day, month }: { day: Date; month: number }) {
|
||||
const backgroundClass = isInSameMonth ? "" : "bg-slate-900";
|
||||
|
||||
return (
|
||||
<>
|
||||
<div
|
||||
className={
|
||||
"border border-slate-600 rounded-lg p-2 pb-4 m-1 " + backgroundClass
|
||||
}
|
||||
>
|
||||
{day.getDate()}
|
||||
{moduleNames.map((moduleName) => (
|
||||
<div
|
||||
key={"" + day + month + moduleName}
|
||||
className={
|
||||
"border border-slate-600 rounded-lg p-2 pb-4 m-1 " + backgroundClass
|
||||
}
|
||||
onDrop={() => itemDrop(day)}
|
||||
onDragOver={(e) => e.preventDefault()}
|
||||
>
|
||||
{day.getDate()}
|
||||
<DayItemsInModule day={day} moduleName={moduleName} />
|
||||
</div>
|
||||
))}
|
||||
</>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ export default async function CourseLayout({
|
||||
await hydrateCourse(queryClient, courseName);
|
||||
const dehydratedState = dehydrate(queryClient);
|
||||
|
||||
console.log("hydrated course state", courseName, dehydratedState);
|
||||
// console.log("hydrated course state", courseName, dehydratedState);
|
||||
return (
|
||||
<HydrationBoundary state={dehydratedState}>{children}</HydrationBoundary>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user