code quality
Some checks failed
CI / lint-typecheck (pull_request) Failing after 10s
CI / tests (pull_request) Has been skipped
CI / contract-tests (pull_request) Has been skipped
CI / e2e-tests (pull_request) Has been skipped
CI / comment-pr (pull_request) Has been skipped
CI / commit-types (pull_request) Has been skipped
Some checks failed
CI / lint-typecheck (pull_request) Failing after 10s
CI / tests (pull_request) Has been skipped
CI / contract-tests (pull_request) Has been skipped
CI / e2e-tests (pull_request) Has been skipped
CI / comment-pr (pull_request) Has been skipped
CI / commit-types (pull_request) Has been skipped
This commit is contained in:
@@ -4,6 +4,8 @@ import { DashboardKpiRow } from '@/components/dashboard/DashboardKpiRow';
|
||||
import { RecentActivityTable, type ActivityItem } from '@/components/dashboard/RecentActivityTable';
|
||||
import { TelemetryPanel } from '@/components/dashboard/TelemetryPanel';
|
||||
import type { DashboardViewData } from '@/lib/view-data/DashboardViewData';
|
||||
import { routes } from '@/lib/routing/RouteConfig';
|
||||
import { useRouter } from 'next/navigation';
|
||||
import { Box } from '@/ui/Box';
|
||||
import { Button } from '@/ui/Button';
|
||||
import { Grid } from '@/ui/Grid';
|
||||
@@ -26,6 +28,7 @@ export function DashboardTemplate({
|
||||
viewData,
|
||||
onNavigateToRaces,
|
||||
}: DashboardTemplateProps) {
|
||||
const router = useRouter();
|
||||
const {
|
||||
currentDriver,
|
||||
nextRace,
|
||||
@@ -109,6 +112,7 @@ export function DashboardTemplate({
|
||||
pb={2}
|
||||
data-testid={`league-standing-${standing.leagueId}`}
|
||||
cursor="pointer"
|
||||
onClick={() => router.push(routes.league.detail(standing.leagueId))}
|
||||
>
|
||||
<Box data-testid="league-standing-link">
|
||||
<Text size="xs" weight="bold" truncate block maxWidth="180px">{standing.leagueName}</Text>
|
||||
@@ -129,7 +133,12 @@ export function DashboardTemplate({
|
||||
<Stack direction="col" gap={4}>
|
||||
{upcomingRaces.length > 0 ? (
|
||||
upcomingRaces.slice(0, 3).map((race) => (
|
||||
<Box key={race.id} cursor="pointer" data-testid={`upcoming-race-${race.id}`}>
|
||||
<Box
|
||||
key={race.id}
|
||||
cursor="pointer"
|
||||
data-testid={`upcoming-race-${race.id}`}
|
||||
onClick={() => router.push(routes.race.detail(race.id))}
|
||||
>
|
||||
<Box display="flex" justifyContent="between" alignItems="start" mb={1} data-testid="upcoming-race-link">
|
||||
<Text size="xs" weight="bold">{race.track}</Text>
|
||||
<Text size="xs" font="mono" variant="low">{race.timeUntil}</Text>
|
||||
|
||||
Reference in New Issue
Block a user