mirror of
https://github.com/hamster1963/nezha-dash.git
synced 2025-04-24 21:10:45 +08:00
Merge branch 'main' into cloudflare
This commit is contained in:
commit
d17c7bb3e2
@ -14,4 +14,5 @@ NEXT_PUBLIC_CustomTitle=NezhaDash
|
|||||||
NEXT_PUBLIC_CustomDescription=NezhaDash is a dashboard for Nezha.
|
NEXT_PUBLIC_CustomDescription=NezhaDash is a dashboard for Nezha.
|
||||||
NEXT_PUBLIC_Links=[{"link":"https://baidu.com","name":"Baidu"},{"link":"https://google.com","name":"Google"}]
|
NEXT_PUBLIC_Links=[{"link":"https://baidu.com","name":"Baidu"},{"link":"https://google.com","name":"Google"}]
|
||||||
NEXT_PUBLIC_DisableIndex=false
|
NEXT_PUBLIC_DisableIndex=false
|
||||||
NEXT_PUBLIC_BASE_PATH=/dash
|
NEXT_PUBLIC_BASE_PATH=/
|
||||||
|
NEXT_PUBLIC_ShowTagCount=false
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
"use client";
|
"use client";
|
||||||
|
|
||||||
|
import getEnv from "@/lib/env-entry";
|
||||||
import { cn } from "@/lib/utils";
|
import { cn } from "@/lib/utils";
|
||||||
import { m } from "framer-motion";
|
import { m } from "framer-motion";
|
||||||
import { useTranslations } from "next-intl";
|
import { useTranslations } from "next-intl";
|
||||||
@ -88,11 +89,12 @@ export default function Switch({
|
|||||||
<div className="relative z-20 flex items-center gap-1">
|
<div className="relative z-20 flex items-center gap-1">
|
||||||
<div className="whitespace-nowrap flex items-center gap-2">
|
<div className="whitespace-nowrap flex items-center gap-2">
|
||||||
{tag === "defaultTag" ? t("defaultTag") : tag}{" "}
|
{tag === "defaultTag" ? t("defaultTag") : tag}{" "}
|
||||||
{tag !== "defaultTag" && (
|
{getEnv("NEXT_PUBLIC_ShowTagCount") === "true" &&
|
||||||
<div className="w-fit px-1.5 rounded-full bg-muted">
|
tag !== "defaultTag" && (
|
||||||
{tagCountMap[tag]}
|
<div className="w-fit px-1.5 rounded-full bg-muted">
|
||||||
</div>
|
{tagCountMap[tag]}
|
||||||
)}
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -12,4 +12,5 @@ NEXT_PUBLIC_FixedTopServerName=false
|
|||||||
NEXT_PUBLIC_CustomLogo=https://nezha-cf.buycoffee.top/apple-touch-icon.png
|
NEXT_PUBLIC_CustomLogo=https://nezha-cf.buycoffee.top/apple-touch-icon.png
|
||||||
NEXT_PUBLIC_CustomTitle=NezhaDash
|
NEXT_PUBLIC_CustomTitle=NezhaDash
|
||||||
NEXT_PUBLIC_CustomDescription=NezhaDash is a dashboard for Nezha.
|
NEXT_PUBLIC_CustomDescription=NezhaDash is a dashboard for Nezha.
|
||||||
NEXT_PUBLIC_DisableIndex=false
|
NEXT_PUBLIC_DisableIndex=false
|
||||||
|
NEXT_PUBLIC_ShowTagCount=false
|
@ -3,7 +3,6 @@ import withBundleAnalyzer from "@next/bundle-analyzer";
|
|||||||
import createNextIntlPlugin from "next-intl/plugin";
|
import createNextIntlPlugin from "next-intl/plugin";
|
||||||
import { env } from "next-runtime-env";
|
import { env } from "next-runtime-env";
|
||||||
|
|
||||||
|
|
||||||
const bundleAnalyzer = withBundleAnalyzer({
|
const bundleAnalyzer = withBundleAnalyzer({
|
||||||
enabled: process.env.ANALYZE === "true",
|
enabled: process.env.ANALYZE === "true",
|
||||||
});
|
});
|
||||||
@ -24,7 +23,7 @@ const withPWA = withPWAInit({
|
|||||||
/** @type {import('next').NextConfig} */
|
/** @type {import('next').NextConfig} */
|
||||||
const nextConfig = {
|
const nextConfig = {
|
||||||
output: "standalone",
|
output: "standalone",
|
||||||
basePath: env("NEXT_PUBLIC_BASE_PATH") || "",
|
basePath: env("NEXT_PUBLIC_BASE_PATH") || "",
|
||||||
logging: {
|
logging: {
|
||||||
fetches: {
|
fetches: {
|
||||||
fullUrl: true,
|
fullUrl: true,
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "nezha-dash",
|
"name": "nezha-dash",
|
||||||
"version": "1.3.0",
|
"version": "1.3.1",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "next dev -p 3020",
|
"dev": "next dev -p 3020",
|
||||||
|
Loading…
Reference in New Issue
Block a user