@@ -5,7 +5,6 @@ import { unstable_cache } from "next/cache";
55import { findCategoryByPath } from "@/lib/server/category-utils" ;
66import { getRawConfig } from "@/lib/server/config-cache" ;
77import prisma from "@/lib/server/prisma" ;
8- import { normalizeSiteColorConfig } from "@/lib/shared/site-color" ;
98
109// 基础静态配置(不依赖数据库的固定值)
1110const STATIC_METADATA = {
@@ -79,7 +78,6 @@ const seoConfigMap = {
7978 applicationName : "site.title" ,
8079 keywords : "seo.keywords" ,
8180 author : "author.name" ,
82- themeColor : "site.color" ,
8381 twitterSite : "seo.twitter_site" ,
8482 twitterCreator : "seo.twitter_creator" ,
8583 googleVerification : "seo.google_verification" ,
@@ -434,9 +432,6 @@ export async function generateMetadata(
434432 true ,
435433 ) ;
436434
437- const siteColor = normalizeSiteColorConfig (
438- configValues [ seoConfigMap . themeColor ] ?. default ,
439- ) ;
440435 const metadataBase = parseMetadataBase ( url ) ;
441436 const normalizedPathname = normalizePathname ( options ?. pathname ) ;
442437 const openGraphUrl = buildOpenGraphUrl ( metadataBase , normalizedPathname ) ;
@@ -517,16 +512,6 @@ export async function generateMetadata(
517512 description : description || undefined ,
518513 applicationName : appName || title || undefined ,
519514 ...STATIC_METADATA ,
520- themeColor : [
521- {
522- media : "(prefers-color-scheme: light)" ,
523- color : siteColor . light . primary ,
524- } ,
525- {
526- media : "(prefers-color-scheme: dark)" ,
527- color : siteColor . dark . primary ,
528- } ,
529- ] ,
530515 authors : author ? [ { name : author } ] : undefined ,
531516 creator : author || undefined ,
532517 publisher : author || undefined ,
0 commit comments