ui design for schedule

This commit is contained in:
Marshal
2026-06-09 23:25:52 +00:00
parent 5774d7db9d
commit 257428be18
19 changed files with 2088 additions and 408 deletions

View File

@@ -2,7 +2,7 @@ import { Badge, Card, Group, Progress, SimpleGrid, Stack, Text, ThemeIcon } from
import { Box, Package } from "lucide-react";
import type { TrainScheduleWagonAllocation, WagonPlanRow } from "@/types/trainScheduling";
type WagonSlot = WagonPlanRow | {
type WagonSlot = (WagonPlanRow & { physicalWagonNumber?: string | null }) | {
sequenceNo: number;
capacityTons: number;
assignedWeightTons: number;
@@ -107,14 +107,11 @@ export function WagonPlanGrid({
</ThemeIcon>
<Stack gap={0}>
<Text fw={600} size="sm">
Wagon #{seq}
{wagon.physicalWagonNumber ?? `Wagon #${seq}`}
</Text>
<Text size="xs" c="dimmed">
{[typeCode, `Pos ${seq}`].filter(Boolean).join(" · ")}
</Text>
{typeCode ? (
<Text size="xs" c="dimmed">
{typeCode}
{wagon.physicalWagonNumber ? ` · ${wagon.physicalWagonNumber}` : ""}
</Text>
) : null}
</Stack>
</Group>
<Badge variant="light" size="sm" color={loadTypeColor(label, freightType)}>