website refactor

This commit is contained in:
2026-01-21 17:50:02 +01:00
parent 4b54c3603b
commit 02987f60c8
29 changed files with 1673 additions and 35 deletions

View File

@@ -21,11 +21,29 @@ export default async function LeagueSchedulePage({ params }: Props) {
notFound();
}
// For serverError, show the template with empty data
return <LeagueScheduleTemplate viewData={{
leagueId,
races: [],
}} />;
return <LeagueScheduleTemplate
viewData={{
leagueId,
races: [],
currentDriverId: undefined,
isAdmin: false,
}}
onRegister={async () => {}}
onWithdraw={async () => {}}
onEdit={() => {}}
onReschedule={() => {}}
onResultsClick={() => {}}
/>;
}
return <LeagueScheduleTemplate viewData={result.unwrap()} />;
const viewData = result.unwrap();
return <LeagueScheduleTemplate
viewData={viewData}
onRegister={async () => {}}
onWithdraw={async () => {}}
onEdit={() => {}}
onReschedule={() => {}}
onResultsClick={() => {}}
/>;
}