diff --git a/src/app/components/StatusPage.tsx b/src/app/components/StatusPage.tsx index 1d18d05..428532f 100644 --- a/src/app/components/StatusPage.tsx +++ b/src/app/components/StatusPage.tsx @@ -1,7 +1,9 @@ import { useState } from 'react'; -import { HardDrive, Activity, Wifi, Signal, Clock } from 'lucide-react'; +import { HardDrive, Activity, Wifi, Signal, Clock, RefreshCw, FolderOpen, Map } from 'lucide-react'; import DeviceDetailOverlay from './DeviceDetailOverlay'; import { ImageWithFallback } from './figma/ImageWithFallback'; +import { Dialog, DialogContent, DialogTitle, DialogDescription } from './ui/dialog'; +import FileBrowser from './FileBrowser'; interface StatusPageProps { config: any; @@ -53,11 +55,33 @@ export default function StatusPage({ config, setConfig }: StatusPageProps) { // Mock image association (replace with real logic if available) const imageUrl = lastFile.endsWith('.d64') ? '/assets/floppy.png' : undefined; + // Dialog/modal state for reset actions + const [showResetModal, setShowResetModal] = useState(null); + const [resetStatus, setResetStatus] = useState('idle'); // 'idle' | 'in-progress' | 'done' + + // Overlay state for directory/disk map + const [showDirectory, setShowDirectory] = useState(false); + const [showDiskMap, setShowDiskMap] = useState(false); + return (

System Status

+
+ + +
Memory Utilization
@@ -118,8 +142,7 @@ export default function StatusPage({ config, setConfig }: StatusPageProps) {

Active Device

setShowDeviceOverlay(true)} + className="bg-white border border-neutral-200 rounded-lg p-4 relative" >
@@ -134,6 +157,22 @@ export default function StatusPage({ config, setConfig }: StatusPageProps) {
+ {/* Directory and Disk Map buttons */} +
+ + +
+ {/* New device info cards */}
@@ -232,6 +271,87 @@ export default function StatusPage({ config, setConfig }: StatusPageProps) { /> )} + {/* Directory Overlay */} + {showDirectory && ( +
+
setShowDirectory(false)} /> +
+
+

Directory

+ +
+
+ {}} onClose={() => setShowDirectory(false)} /> +
+
+
+ )} + + {/* Disk Map Overlay */} + {showDiskMap && ( +
+
setShowDiskMap(false)} /> +
+
+

Disk Map

+ +
+
+ Disk map visualization goes here. +
+
+
+ )} + {/* Reset Activity Modal */} + !open && setShowResetModal(null)}> + + {showResetModal === 'meatloaf' ? 'Reset Meatloaf' : 'Reset Host'} + + {resetStatus === 'idle' && ( + <> + Are you sure you want to reset {showResetModal === 'meatloaf' ? 'the Meatloaf device' : 'the Host'}? +
+ + +
+ + )} + {resetStatus === 'in-progress' && ( +
+ Resetting... +
+
+
+
+ )} + {resetStatus === 'done' && ( +
+ Reset complete! + +
+ )} + + +
+

Activity Log