mirror of
https://github.com/woodchen-ink/nezha-dash-v1.git
synced 2025-07-18 17:41:56 +08:00
style: network display
This commit is contained in:
parent
79e40144b5
commit
1cb56973aa
@ -52,7 +52,7 @@ function Header() {
|
||||
(handlers[element.tagName] || handlers.DEFAULT)(element);
|
||||
} else if (node.nodeType === Node.TEXT_NODE) {
|
||||
document.body.appendChild(
|
||||
document.createTextNode(node.textContent || "")
|
||||
document.createTextNode(node.textContent || ""),
|
||||
);
|
||||
}
|
||||
});
|
||||
@ -155,7 +155,7 @@ function Overview() {
|
||||
const timeOption = DateTime.TIME_SIMPLE;
|
||||
timeOption.hour12 = true;
|
||||
const [timeString, setTimeString] = useState(
|
||||
DateTime.now().setLocale("en-US").toLocaleString(timeOption)
|
||||
DateTime.now().setLocale("en-US").toLocaleString(timeOption),
|
||||
);
|
||||
useInterval(() => {
|
||||
setTimeString(DateTime.now().setLocale("en-US").toLocaleString(timeOption));
|
||||
|
@ -98,7 +98,8 @@ export default function ServerOverview({
|
||||
<p className="text-sm font-medium md:text-base">
|
||||
{t("serverOverview.network")}
|
||||
</p>
|
||||
<section className="flex flex-row z-[999] sm:items-center items-start pr-2 sm:pr-0 gap-1 ml-auto">
|
||||
</div>
|
||||
<section className="flex items-start flex-row z-[999] pr-2 sm:pr-0 gap-1">
|
||||
<p className="sm:text-[12px] text-[10px] text-blue-800 dark:text-blue-400 text-nowrap font-medium">
|
||||
↑{formatBytes(up)}
|
||||
</p>
|
||||
@ -106,13 +107,12 @@ export default function ServerOverview({
|
||||
↓{formatBytes(down)}
|
||||
</p>
|
||||
</section>
|
||||
</div>
|
||||
<section className="flex flex-row mt-1.5 -mr-1 sm:items-center items-start gap-1">
|
||||
<p className="sm:text-[12px] flex items-center text-[10px] text-nowrap font-semibold">
|
||||
<section className="flex flex-col sm:flex-row -mr-1 sm:items-center items-start gap-1">
|
||||
<p className="text-[11px] flex items-center text-nowrap font-semibold">
|
||||
<ArrowUpCircleIcon className="size-3 mr-0.5 sm:mb-[1px]" />
|
||||
{formatBytes(upSpeed)}/s
|
||||
</p>
|
||||
<p className="sm:text-[12px] flex items-center text-[10px] text-nowrap font-semibold">
|
||||
<p className="text-[11px] flex items-center text-nowrap font-semibold">
|
||||
<ArrowDownCircleIcon className="size-3 mr-0.5" />
|
||||
{formatBytes(downSpeed)}/s
|
||||
</p>
|
||||
|
Loading…
x
Reference in New Issue
Block a user