diff --git a/frontend/src/assets/CGW453.PNG b/frontend/src/assets/CGW453.PNG new file mode 100644 index 0000000..d559cd4 Binary files /dev/null and b/frontend/src/assets/CGW453.PNG differ diff --git a/frontend/src/assets/hero.png b/frontend/src/assets/hero.png deleted file mode 100644 index 02251f4..0000000 Binary files a/frontend/src/assets/hero.png and /dev/null differ diff --git a/frontend/src/assets/react.svg b/frontend/src/assets/react.svg deleted file mode 100644 index 6c87de9..0000000 --- a/frontend/src/assets/react.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/frontend/src/assets/vite.svg b/frontend/src/assets/vite.svg deleted file mode 100644 index 5101b67..0000000 --- a/frontend/src/assets/vite.svg +++ /dev/null @@ -1 +0,0 @@ -Vite diff --git a/frontend/src/components/Calendar.jsx b/frontend/src/components/Calendar.jsx index 8a7f8d0..a09df90 100644 --- a/frontend/src/components/Calendar.jsx +++ b/frontend/src/components/Calendar.jsx @@ -141,10 +141,16 @@ export default function Calendar({ const shifts = scheduleData[key] ?? { shift1: [], shift2: [], shift3: [] } const isToday = date.getTime() === today.getTime() const isWeekend = date.getDay() === 0 || date.getDay() === 6 + // Get next day's shift1 for display + const nextDate = addDays(date, 1) + const nextKey = toDateKey(nextDate) + const nextDayShift1 = scheduleData[nextKey]?.shift1 ?? [] // Which shifts on this date are part of the active test window? const activeShifts = new Set() if (key === activeWindow.shift3Date) activeShifts.add(3) if (key === activeWindow.shift1Date) activeShifts.add(1) + // Check if next day's shift1 is active + const nextDayShift1Active = nextKey === activeWindow.shift1Date return ( - + ) diff --git a/frontend/src/components/RightPanel.jsx b/frontend/src/components/RightPanel.jsx index c8cb8db..c3c22e5 100644 --- a/frontend/src/components/RightPanel.jsx +++ b/frontend/src/components/RightPanel.jsx @@ -1,3 +1,5 @@ +import cgw453Image from '../assets/CGW453.PNG' + function formatCompletionDate(value) { if (!value) return null @@ -28,6 +30,11 @@ export default function RightPanel({ return ( ) } diff --git a/frontend/src/components/TestWindowDetailsPanel.jsx b/frontend/src/components/TestWindowDetailsPanel.jsx index 2e650f2..fefe262 100644 --- a/frontend/src/components/TestWindowDetailsPanel.jsx +++ b/frontend/src/components/TestWindowDetailsPanel.jsx @@ -1,4 +1,10 @@ import { useEffect, useMemo, useState } from 'react' +import { getDeviceAccentClass } from './TestCard' + +const CONFIG_MAP_IMAGE_MODULES = import.meta.glob('../assets/TC*_map/*.png', { + eager: true, + import: 'default', +}) const STATUS_STYLES = { pending: 'bg-gray-700 text-gray-200 border-gray-600', @@ -90,6 +96,16 @@ function formatConfigEntries(config) { .filter(Boolean) } +function getConfigMapImages(configKey) { + if (!configKey) return [] + + const folderToken = `/${configKey.toUpperCase()}_map/` + return Object.entries(CONFIG_MAP_IMAGE_MODULES) + .filter(([path]) => path.includes(folderToken)) + .sort(([pathA], [pathB]) => pathA.localeCompare(pathB, undefined, { numeric: true })) + .map(([, assetUrl]) => assetUrl) +} + function TestRow({ test }) { const [expanded, setExpanded] = useState(false) const statusStyle = STATUS_STYLES[test.status] ?? STATUS_STYLES.pending @@ -103,15 +119,18 @@ function TestRow({ test }) { className="w-full px-4 py-3 text-left hover:bg-gray-800/80 transition-colors" >
-
-

{test.test_id}

-

{test.device ?? '—'} · {formatShiftLabel(test)}

+
+
{test.status ?? 'pending'} - {formatHours(test.estimated_minutes)} + {Number.isFinite(test.estimated_minutes) && test.estimated_minutes > 0 ? `${test.estimated_minutes} min` : '—'}
@@ -127,14 +146,6 @@ function TestRow({ test }) {

Rotation

{test.rotation ?? '—'}

-
-

Priority

-

{test.priority ?? '—'}

-
-
-

Sequence

-

{test.sequence_in_shift ?? '—'}

-
@@ -171,7 +182,15 @@ function TestRow({ test }) { } export default function TestWindowDetailsPanel({ isOpen, windowDetails, onClose }) { + const [showConfigMap, setShowConfigMap] = useState(false) const windowTestConfig = useMemo(() => getWindowTestConfig(windowDetails), [windowDetails]) + const windowConfigMapKey = useMemo( + () => (windowTestConfig.length > 0 ? String(windowTestConfig[0]).toUpperCase() : null), + [windowTestConfig], + ) + const configMapImages = useMemo(() => getConfigMapImages(windowConfigMapKey), [windowConfigMapKey]) + const hasConfigMapImages = configMapImages.length > 0 + const showMapPane = showConfigMap && hasConfigMapImages useEffect(() => { if (!isOpen) return undefined @@ -201,11 +220,13 @@ export default function TestWindowDetailsPanel({ isOpen, windowDetails, onClose />