diff --git a/src/app/events/[event_key]/EventKeyClient.tsx b/src/app/events/[event_key]/EventKeyClient.tsx
index 091c547..5cd07aa 100644
--- a/src/app/events/[event_key]/EventKeyClient.tsx
+++ b/src/app/events/[event_key]/EventKeyClient.tsx
@@ -19,7 +19,7 @@
import Link from "next/link";
import { ArrowRight, ClipboardList } from "lucide-react";
import EventHeader from "@/components/events/event/EventHeader";
-import { EventFull, EventRankingRow, EventTab, EventTeamSummary, EventWebcastType, WebcastUrl} from "@/types/events";
+import { EventAward, EventFull, EventRankingRow, EventTab, EventTeamSummary, EventWebcastType, WebcastUrl} from "@/types/events";
import EventOverview from "./EventOverviewTab";
import EventMatchesTab from "./EventMatchesTab";
import EventTeamsTab from "./EventTeamsTab";
@@ -29,44 +29,16 @@ import { EventInfoProps } from "@/components/events/event/EventInfo";
import { getTeamSummary } from "@/lib/api/teams";
-export const mockInformation: EventInfoProps = {
- location: "São Paulo",
- venue: "SESI Vila Leopoldina",
- date: "Mar 12–15",
- country: "Brazil",
- week: "Week 2",
-};
-
-export const mockWebcasts: WebcastUrl[] = [
- {
- type: EventWebcastType.YouTube,
- channel: "Official FIRST Broadcast",
- date: "Mar 12",
- url: "https://youtube.com",
- },
- {
- type: EventWebcastType.YouTube,
- channel: "Official FIRST Broadcast",
- date: "Mar 13",
- url: "https://youtube.com",
- },
- {
- type: EventWebcastType.Twitch,
- channel: "FIRSTinspires",
- date: "Mar 14",
- url: "https://twitch.tv/firstinspires",
- },
-];
-
interface EventKeyProps {
eventKey: string;
tab: EventTab;
event: EventFull;
teams: EventTeamSummary[] | null;
rankings: EventRankingRow[] | null;
+ awards: EventAward[] | null;
}
-async function EventTabContent({ eventKey, tab, event, teams, rankings }: EventKeyProps) {
+async function EventTabContent({ eventKey, tab, event, teams, rankings, awards }: EventKeyProps) {
switch (tab) {
case EventTab.Overview:
return
- {award.recipientName ?? award.awardee ?? "Recipient TBD"} + {award.recipientName ?? award.awardee ?? award.recipientTeamKey?.replace("frc", "") ?? "Unknown recipient"}
diff --git a/src/lib/api/events.ts b/src/lib/api/events.ts index 80cc944..3acbb2f 100644 --- a/src/lib/api/events.ts +++ b/src/lib/api/events.ts @@ -1,6 +1,6 @@ import * as tba from "@/lib/api/tba"; import { DashboardDataEvent } from "@/types/dashboard"; -import { EventFull, EventListItem, EventOption, EventRankingRow, EventWebcastType, WebcastUrl, } from "@/types/events"; +import { EventAward, EventFull, EventListItem, EventOption, EventRankingRow, EventWebcastType, WebcastUrl, } from "@/types/events"; import { TBAEvent } from "@/types/tba/event"; /** @@ -263,7 +263,42 @@ export async function getEventRankings(event_key: string): Promise