-
Notifications
You must be signed in to change notification settings - Fork 95
Open
Labels
Description
Description:
Create a StatusBadge component that renders a color-coded pill showing the shipment's current status. Each status has a distinct color that works in both light and dark mode.
Create frontend/components/shipment/status-badge.tsx.
Acceptance Criteria:
-
'use client'directive - Accepts
status: ShipmentStatusand optionalclassNameprops - Color mapping (must work in dark mode too):
pending→ yellowaccepted→ bluein_transit→ indigodelivered→ tealcompleted→ greencancelled→ graydisputed→ red
- Human-readable labels:
in_transit→ "In Transit", etc. - Pill shape:
rounded-full px-2.5 py-0.5 text-xs font-medium - Uses
cn()for class merging - Gracefully handles unknown status values
Reactions are currently unavailable