From 4f3e9c0f35bf64032149878c4b26d1873d851132 Mon Sep 17 00:00:00 2001 From: hsiegeln <37154749+hsiegeln@users.noreply.github.com> Date: Thu, 19 Mar 2026 12:25:01 +0100 Subject: [PATCH] feat: add RouteFlow component and replace tabbed exchange detail with stacked layout Replace the 4-tab DetailPanel (Overview/Processors/Exchange/Error) with a single scrollable view: overview, errors (limited to 1 with +N indicator), route flow diagram, and processor timeline. DetailPanel now supports children as an alternative to tabs. Co-Authored-By: Claude Opus 4.6 (1M context) --- .../composites/DetailPanel/DetailPanel.tsx | 13 +- .../composites/RouteFlow/RouteFlow.module.css | 192 +++++++++++++++++ .../composites/RouteFlow/RouteFlow.tsx | 108 ++++++++++ src/design-system/composites/index.ts | 2 + src/pages/Dashboard/Dashboard.module.css | 83 ++++---- src/pages/Dashboard/Dashboard.tsx | 196 ++++++++++-------- src/pages/Inventory/Inventory.tsx | 1 + .../Inventory/sections/CompositesSection.tsx | 23 ++ 8 files changed, 478 insertions(+), 140 deletions(-) create mode 100644 src/design-system/composites/RouteFlow/RouteFlow.module.css create mode 100644 src/design-system/composites/RouteFlow/RouteFlow.tsx diff --git a/src/design-system/composites/DetailPanel/DetailPanel.tsx b/src/design-system/composites/DetailPanel/DetailPanel.tsx index cd7f3ae..0b0ecef 100644 --- a/src/design-system/composites/DetailPanel/DetailPanel.tsx +++ b/src/design-system/composites/DetailPanel/DetailPanel.tsx @@ -11,15 +11,16 @@ interface DetailPanelProps { open: boolean onClose: () => void title: string - tabs: Tab[] + tabs?: Tab[] + children?: ReactNode actions?: ReactNode className?: string } -export function DetailPanel({ open, onClose, title, tabs, actions, className }: DetailPanelProps) { - const [activeTab, setActiveTab] = useState(tabs[0]?.value ?? '') +export function DetailPanel({ open, onClose, title, tabs, children, actions, className }: DetailPanelProps) { + const [activeTab, setActiveTab] = useState(tabs?.[0]?.value ?? '') - const activeContent = tabs.find((t) => t.value === activeTab)?.content + const activeContent = tabs?.find((t) => t.value === activeTab)?.content return (