fix(docker): make the site icon configurable at runtime

Add SITE_ICON_FILE and SITE_ICON_URL support for the Docker image, route the app shell and manifest through a runtime icon endpoint, document the new Docker branding flow, and bump the app version to 4.8.3.
This commit is contained in:
kuekhaoyang
2026-04-12 11:26:57 +08:00
parent e2d7549a70
commit 727fc2b0ed
9 changed files with 175 additions and 24 deletions
+3 -2
View File
@@ -5,7 +5,7 @@ import Link from 'next/link';
import Image from 'next/image';
import { ThemeSwitcher } from '@/components/ThemeSwitcher';
import { Icons } from '@/components/ui/Icon';
import { siteConfig } from '@/lib/config/site-config';
import { siteConfig, SITE_ICON_PATH } from '@/lib/config/site-config';
import { getSession, clearSession, hasPermission, type AuthSession } from '@/lib/store/auth-store';
import { useRuntimeFeatures } from '@/components/RuntimeFeaturesProvider';
import { LogOut } from 'lucide-react';
@@ -45,10 +45,11 @@ export function Navbar({ onReset, isPremiumMode = false }: NavbarProps) {
>
<div className="w-8 h-8 sm:w-10 sm:h-10 relative flex items-center justify-center flex-shrink-0">
<Image
src="/icon.png"
src={SITE_ICON_PATH}
alt={siteConfig.name}
width={40}
height={40}
unoptimized
className="object-contain"
/>
</div>
+3 -2
View File
@@ -4,7 +4,7 @@ import Image from 'next/image';
import { Button } from '@/components/ui/Button';
import { ThemeSwitcher } from '@/components/ThemeSwitcher';
import { Icons } from '@/components/ui/Icon';
import { siteConfig } from '@/lib/config/site-config';
import { siteConfig, SITE_ICON_PATH } from '@/lib/config/site-config';
export function PlayerNavbar({ isPremium }: { isPremium?: boolean }) {
const router = useRouter();
@@ -20,10 +20,11 @@ export function PlayerNavbar({ isPremium }: { isPremium?: boolean }) {
title={isPremium ? "返回高级主页" : "返回首页"}
>
<Image
src="/icon.png"
src={SITE_ICON_PATH}
alt={siteConfig.name}
width={40}
height={40}
unoptimized
className="object-contain"
/>
</button>