import React, { useState } from "react"; import { AnimatedCircularProgress } from "react-native-circular-progress"; import { InferResponseType } from "hono/client"; import api from "@/lib/api"; import Text from "@ui/Text"; import { HStack, VStack } from "@ui/Stack"; import Box from "@ui/Box"; import ProcessList from "./ProcessList"; import Divider from "@ui/Divider"; import Button from "@ui/Button"; import { Ionicons } from "@ui/Icons"; type Props = { data: InferResponseType; }; const Performance = ({ data: system }: Props) => { const [showProcess, setShowProcess] = useState(false); return ( <> Performance {() => ( {Math.round(system?.perf.cpu.load || 0)} % )} CPU {system ? ( {`${system.perf.cpu.speed.toFixed(1)} GHz / ${ system.perf.cpu.temp }°C`} ) : null} {() => ( {Math.round(system?.perf.mem.percent || 0)} % )} Mem {system?.perf.mem.used}