Merge pull request #16 from hamster1963/viewport

[TSK1-481]fix: add viewport
This commit is contained in:
仓鼠 2024-09-19 11:46:36 +08:00 committed by GitHub
commit 64d110b88f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 50 additions and 46 deletions

View File

@ -14,7 +14,7 @@ export default function Footer() {
</p>
<section className="mt-1 flex items-center gap-2 text-[13px] font-light tracking-tight text-neutral-600/50 dark:text-neutral-300/50">
© 2020-{new Date().getFullYear()}{" "}
<a href={"https://github.com/hamster1963"}>@Hamster1963</a>
<a href={"https://buycoffee.top"}>@Hamster1963</a>
</section>
</section>
</footer>

View File

@ -4,7 +4,7 @@ import type { Metadata } from "next";
import { Inter as FontSans } from "next/font/google";
import { ThemeProvider } from "next-themes";
import React from "react";
import { Viewport } from "next";
import { cn } from "@/lib/utils";
const fontSans = FontSans({
@ -23,6 +23,13 @@ export const metadata: Metadata = {
},
};
export const viewport: Viewport = {
width: "device-width",
initialScale: 1,
maximumScale: 1,
userScalable: false,
};
interface RootLayoutProps {
children: React.ReactNode;
}

BIN
bun.lockb

Binary file not shown.

View File

@ -56,38 +56,35 @@ export default function ServerCard({
<section className={"grid grid-cols-5 items-center gap-3"}>
<div className={"flex flex-col"}>
<p className="text-xs text-muted-foreground">CPU</p>
<div className="text-xs font-semibold flex items-center">
{cpu.toFixed(2)}
%
<div className="flex items-center text-xs font-semibold">
{cpu.toFixed(2)}%
</div>
<ServerUsageBar value={cpu} />
</div>
<div className={"flex flex-col"}>
<p className="text-xs text-muted-foreground">Mem</p>
<div className="text-xs font-semibold flex items-center">
{mem.toFixed(2)}
%
<div className="flex items-center text-xs font-semibold">
{mem.toFixed(2)}%
</div>
<ServerUsageBar value={mem} />
</div>
<div className={"flex flex-col"}>
<p className="text-xs text-muted-foreground">STG</p>
<div className="text-xs font-semibold flex items-center">
{stg.toFixed(2)}
%
<div className="flex items-center text-xs font-semibold">
{stg.toFixed(2)}%
</div>
<ServerUsageBar value={stg} />
</div>
<div className={"flex flex-col"}>
<p className="text-xs text-muted-foreground">Upload</p>
<div className="text-xs font-semibold flex items-center">
<div className="flex items-center text-xs font-semibold">
{up.toFixed(2)}
Mb/s
</div>
</div>
<div className={"flex flex-col"}>
<p className="text-xs text-muted-foreground">Download</p>
<div className="text-xs font-semibold flex items-center">
<div className="flex items-center text-xs font-semibold">
{down.toFixed(2)}
Mb/s
</div>

View File

@ -9,49 +9,49 @@
"build": "next build && cp -r .next/static .next/standalone/.next/ && cp -r public .next/standalone/"
},
"dependencies": {
"@ducanh2912/next-pwa": "^10.2.6",
"@radix-ui/react-dialog": "^1.0.5",
"@radix-ui/react-dropdown-menu": "^2.0.6",
"@radix-ui/react-navigation-menu": "^1.1.4",
"@ducanh2912/next-pwa": "^10.2.9",
"@radix-ui/react-dialog": "^1.1.1",
"@radix-ui/react-dropdown-menu": "^2.1.1",
"@radix-ui/react-navigation-menu": "^1.2.0",
"@radix-ui/react-popover": "^1.1.1",
"@radix-ui/react-progress": "^1.0.3",
"@radix-ui/react-progress": "^1.1.0",
"@radix-ui/react-separator": "^1.1.0",
"@radix-ui/react-slot": "^1.0.2",
"@radix-ui/react-tooltip": "^1.0.7",
"@radix-ui/react-slot": "^1.1.0",
"@radix-ui/react-tooltip": "^1.1.2",
"@types/luxon": "^3.4.2",
"@typescript-eslint/eslint-plugin": "^7.5.0",
"@typescript-eslint/eslint-plugin": "^7.18.0",
"class-variance-authority": "^0.7.0",
"clsx": "^2.1.0",
"clsx": "^2.1.1",
"country-flag-icons": "^1.5.13",
"eslint-plugin-simple-import-sort": "^12.0.0",
"eslint-plugin-simple-import-sort": "^12.1.1",
"lucide-react": "^0.414.0",
"luxon": "^3.4.4",
"next": "^14.2.3",
"luxon": "^3.5.0",
"next": "^14.2.12",
"next-themes": "^0.3.0",
"react": "^18.2.0",
"react": "^18.3.1",
"react-device-detect": "^2.2.3",
"react-dom": "^18.2.0",
"react-intersection-observer": "^9.8.2",
"react-wrap-balancer": "^1.1.0",
"sharp": "^0.33.3",
"react-dom": "^18.3.1",
"react-intersection-observer": "^9.13.1",
"react-wrap-balancer": "^1.1.1",
"sharp": "^0.33.5",
"swr": "^2.2.6-beta.4",
"tailwind-merge": "^2.2.2",
"tailwind-merge": "^2.5.2",
"tailwindcss-animate": "^1.0.7"
},
"devDependencies": {
"eslint-plugin-turbo": "^2.0.3",
"eslint-plugin-unused-imports": "^4.0.0",
"@next/bundle-analyzer": "^14.1.4",
"@types/node": "^22.0.0",
"@types/react": "^18.2.74",
"@types/react-dom": "^18.2.24",
"autoprefixer": "^10.4.19",
"eslint": "^9.4.0",
"eslint-config-next": "^14.1.4",
"postcss": "^8.4.38",
"prettier": "^3.2.5",
"prettier-plugin-tailwindcss": "^0.6.3",
"tailwindcss": "^3.4.3",
"typescript": "^5.4.3"
"eslint-plugin-turbo": "^2.1.2",
"eslint-plugin-unused-imports": "^4.1.4",
"@next/bundle-analyzer": "^14.2.12",
"@types/node": "^22.5.5",
"@types/react": "^18.3.7",
"@types/react-dom": "^18.3.0",
"autoprefixer": "^10.4.20",
"eslint": "^9.10.0",
"eslint-config-next": "^14.2.12",
"postcss": "^8.4.47",
"prettier": "^3.3.3",
"prettier-plugin-tailwindcss": "^0.6.6",
"tailwindcss": "^3.4.12",
"typescript": "^5.6.2"
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB