mirror of
https://github.com/hamster1963/nezha-dash.git
synced 2025-04-24 21:10:45 +08:00
fix(header): logo path
This commit is contained in:
parent
cb278ec742
commit
0b061d805e
@ -7,13 +7,11 @@ import { Skeleton } from "@/components/ui/skeleton";
|
||||
import getEnv from "@/lib/env-entry";
|
||||
import { DateTime } from "luxon";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { useTheme } from "next-themes";
|
||||
import { useRouter } from "next/navigation";
|
||||
import React, { useEffect, useRef, useState } from "react";
|
||||
|
||||
function Header() {
|
||||
const t = useTranslations("Header");
|
||||
const { resolvedTheme } = useTheme();
|
||||
const customLogo = getEnv("NEXT_PUBLIC_CustomLogo");
|
||||
const customTitle = getEnv("NEXT_PUBLIC_CustomTitle");
|
||||
const customDescription = getEnv("NEXT_PUBLIC_CustomDescription");
|
||||
@ -35,14 +33,15 @@ function Header() {
|
||||
width={40}
|
||||
height={40}
|
||||
alt="apple-touch-icon"
|
||||
src={
|
||||
customLogo
|
||||
? customLogo
|
||||
: resolvedTheme === "light"
|
||||
? "/apple-touch-icon.png"
|
||||
: "/apple-touch-icon-dark.png"
|
||||
}
|
||||
className="relative m-0! border-2 border-transparent h-6 w-6 object-cover object-top p-0!"
|
||||
src={customLogo ? customLogo : "/apple-touch-icon.png"}
|
||||
className="relative m-0! border-2 border-transparent h-6 w-6 object-cover object-top p-0! dark:hidden"
|
||||
/>
|
||||
<img
|
||||
width={40}
|
||||
height={40}
|
||||
alt="apple-touch-icon"
|
||||
src={customLogo ? customLogo : "/apple-touch-icon-dark.png"}
|
||||
className="relative m-0! border-2 border-transparent h-6 w-6 object-cover object-top p-0! hidden dark:block"
|
||||
/>
|
||||
</div>
|
||||
{customTitle ? customTitle : "NezhaDash"}
|
||||
|
Loading…
Reference in New Issue
Block a user