diff --git a/src/components/ServerCard.tsx b/src/components/ServerCard.tsx index 06e9add..c7fa6e6 100644 --- a/src/components/ServerCard.tsx +++ b/src/components/ServerCard.tsx @@ -445,7 +445,7 @@ export default function ServerCard({ now, serverInfo, cycleStats }: ServerCardPr {cpu_info[0].includes("Physical") ? "pCPU: " : "vCPU: "} - {cpu_info[0].match(/(\d+)\s+(?:Physical|Virtual)\s+Core/)?.[1] || "?"} + {cpu_info[0].match(/(\d+)\s+(?:Physical|Virtual)\s+Core/)?.[1] || "-"} @@ -456,16 +456,24 @@ export default function ServerCard({ now, serverInfo, cycleStats }: ServerCardPr )} {/* 内存大小 */} - {mem_total > 0 && ( + {mem_total > 0 ? ( - {t("serverCard.mem")}: {formatBytes(mem_total)} + RAM: {formatBytes(mem_total)} + + ) : ( + + RAM: - )} {/* 存储大小 */} - {disk_total > 0 && ( + {disk_total > 0 ? ( - {t("serverCard.stg")}: {formatBytes(disk_total)} + DISK: {formatBytes(disk_total)} + + ) : ( + + DISK: - )}