"use client"; import React, { useState } from "react"; import { CitySidebar } from "./Sidebar"; import { AnalyticsPanel } from "./AnalyticsPanel"; import { RefreshCw, LayoutGrid, Maximize2, Layers, Languages, Sun, Moon, } from "lucide-react"; import { Badge } from "@/components/ui/badge"; interface TerminalDashboardProps { cities: any[]; activeCity: string; onSelectCity: (name: string) => void; cityData: any; marketData: any; officialData: any; isLoading: boolean; refresh: () => void; lang: any; setLang: (lang: any) => void; theme: string; toggleTheme: () => void; t: any; children: React.ReactNode; // For the Map } function NavLink({ href, label, active = false, }: { href: string; label: string; active?: boolean; }) { return ( {label} ); } export function TerminalDashboard({ cities, activeCity, onSelectCity, cityData, marketData, officialData, isLoading, refresh, lang, setLang, theme, toggleTheme, t, children, }: TerminalDashboardProps) { const currentTemp = cityData?.current?.temp ?? null; const debPrediction = cityData?.deb?.prediction ?? null; const marketPrice = marketData?.markets?.[0]?.price ?? 0.62; // Placeholder const modelEntries = Object.entries(cityData?.multi_model ?? {}) .map(([label, value]) => ({ label, value: value as number })) .filter((e) => typeof e.value === "number"); return (
{/* Top Global Ticker / Nav */}
{t.node || "Node"}: CLOUD-ALPHA-01
NODE: CLOUD-ALPHA-01
{/* Main Container */}
{/* Left: Component List */} {/* Center: Interactive Map Area */}
{/* Map UI Overlay */}
Current Focus {activeCity}
{/* The Map */}
{children}
{/* Bottom Map Info Bar */}
Projection: Mercator · Layer: Dynamic Thermal Ensemble
STABLE VIBE
{/* Right: Intelligence Panel */}
{/* Footer Ticker */}
); }