(mb: number)
| 18 | } |
| 19 | |
| 20 | function fmtGpuMb(mb: number): string { |
| 21 | if (mb >= 1024) return `${(mb / 1024).toFixed(1)} GB`; |
| 22 | return `${mb} MB`; |
| 23 | } |
| 24 | |
| 25 | export default function TitleBar({ osVer, cpuPct, memPct, gpuName, gpuUsedMb, gpuTotalMb }: TitleBarProps) { |
| 26 | const [wide, setWide] = useState(window.innerWidth >= STATS_BREAKPOINT); |