Skip to content

Commit

Permalink
feat(detail): add gpu info
Browse files Browse the repository at this point in the history
  • Loading branch information
hamster1963 committed Dec 2, 2024
1 parent 14abc76 commit b4e6818
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
14 changes: 13 additions & 1 deletion app/(main)/ClientComponents/ServerDetailClient.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,19 @@ export default function ServerDetailClient({
<section className="flex flex-col items-start gap-0.5">
<p className="text-xs text-muted-foreground">{t("CPU")}</p>
{data?.host.CPU ? (
<div className="text-xs"> {data?.host.CPU}</div>
<div className="text-xs"> {data?.host.CPU.join(", ")}</div>
) : (
<div className="text-xs">Unknown</div>
)}
</section>
</CardContent>
</Card>
<Card className="rounded-[10px] bg-transparent border-none shadow-none">
<CardContent className="px-1.5 py-1">
<section className="flex flex-col items-start gap-0.5">
<p className="text-xs text-muted-foreground">{"GPU"}</p>
{data?.host.GPU ? (
<div className="text-xs"> {data?.host.GPU.join(", ")}</div>
) : (
<div className="text-xs">Unknown</div>
)}
Expand Down
2 changes: 1 addition & 1 deletion app/types/nezha-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export interface NezhaAPIHost {
BootTime: number;
CountryCode: string;
Version: string;
GPU: null;
GPU: string[];
}

export interface NezhaAPIStatus {
Expand Down

0 comments on commit b4e6818

Please sign in to comment.