"use client"; import { useLocalCoursesSettingsQuery } from "@/hooks/localCourse/localCoursesHooks"; import { getDateKey, getTermName, groupByStartDate } from "@/models/local/utils/timeUtils"; import { getCourseUrl } from "@/services/urlUtils"; import Link from "next/link"; export default function CourseList() { const { data: allSettings } = useLocalCoursesSettingsQuery(); const coursesByStartDate = groupByStartDate(allSettings); const sortedDates = Object.keys(coursesByStartDate).sort(); return (