From 5d14a0780c1af92a0b0d95a792093534139fedd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E7=BF=94?= Date: Mon, 27 Apr 2026 21:56:30 +0800 Subject: [PATCH] =?UTF-8?q?fix(fonts):=20=E4=BC=98=E5=8C=96AoyagiReisho?= =?UTF-8?q?=E5=AD=97=E4=BD=93=E5=9B=9E=E9=80=80=E9=93=BE=EF=BC=8C=E7=A7=BB?= =?UTF-8?q?=E9=99=A4=E6=AD=A7=E4=B9=89=E7=B3=BB=E7=BB=9F=E5=AD=97=E4=BD=93?= =?UTF-8?q?=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修复字体显示问题:移除可能导致歧义的'Aoyagi Reisho'系统字体名称 - 优化字体回退链:var(--font-aoyagi-reisho) → 'Ma Shan Zheng' → 'ZCOOL XiaoWei' → ... - 统一修复3个相关文件中的字体配置 - 增强部署脚本对Next.js静态导出的处理逻辑 --- deploy-dist.sh | 14 +++++++++++++- src/app/globals.css | 2 +- src/components/sections/about-section.tsx | 2 +- src/components/sections/hero-section-atoms.tsx | 2 +- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/deploy-dist.sh b/deploy-dist.sh index 8d0053e..7b83f97 100755 --- a/deploy-dist.sh +++ b/deploy-dist.sh @@ -78,7 +78,19 @@ ssh "$SERVER_USER@$SERVER_IP" " echo "" echo "📋 步骤4: 上传 dist 目录..." ssh "$SERVER_USER@$SERVER_IP" "mkdir -p '$DEPLOY_ROOT/$STATIC_DIR'" -rsync -avz --delete "$DIST_DIR/" "$SERVER_USER@$SERVER_IP:$DEPLOY_ROOT/$STATIC_DIR/" + +# 检查dist目录结构并正确处理Next.js静态文件 +if [ -d "$DIST_DIR/server/app" ]; then + echo "🔧 检测到Next.js静态导出结构,正在处理HTML文件..." + # 复制HTML文件到根目录 + rsync -avz --delete "$DIST_DIR/server/app/" "$SERVER_USER@$SERVER_IP:$DEPLOY_ROOT/$STATIC_DIR/" + # 复制其他静态资源 + rsync -avz --delete --exclude='server/app' "$DIST_DIR/" "$SERVER_USER@$SERVER_IP:$DEPLOY_ROOT/$STATIC_DIR/" +else + # 标准静态文件结构 + rsync -avz --delete "$DIST_DIR/" "$SERVER_USER@$SERVER_IP:$DEPLOY_ROOT/$STATIC_DIR/" +fi + echo "✅ dist 目录已上传" echo "" diff --git a/src/app/globals.css b/src/app/globals.css index 825d397..b5e847c 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -234,7 +234,7 @@ /* 青柳隷書 - 仅用于品牌标题"睿新致远" */ @utility font-brand { - font-family: var(--font-aoyagi-reisho), 'Aoyagi Reisho', 'Ma Shan Zheng', 'ZCOOL XiaoWei', 'STKaiti', 'KaiTi', serif !important; + font-family: var(--font-aoyagi-reisho), 'Ma Shan Zheng', 'ZCOOL XiaoWei', 'STKaiti', 'KaiTi', serif !important; font-weight: normal; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; diff --git a/src/components/sections/about-section.tsx b/src/components/sections/about-section.tsx index c3aecc5..1f34add 100644 --- a/src/components/sections/about-section.tsx +++ b/src/components/sections/about-section.tsx @@ -36,7 +36,7 @@ export function AboutSection() {

- 关于 {COMPANY_INFO.shortName} + 关于 {COMPANY_INFO.shortName}

{COMPANY_INFO.slogan} diff --git a/src/components/sections/hero-section-atoms.tsx b/src/components/sections/hero-section-atoms.tsx index 67c76b2..1046621 100644 --- a/src/components/sections/hero-section-atoms.tsx +++ b/src/components/sections/hero-section-atoms.tsx @@ -61,7 +61,7 @@ export function HeroTitle(_props: HeroContentProps) { id="hero-heading" className="text-5xl sm:text-6xl lg:text-7xl tracking-tight mb-6" style={{ - fontFamily: "var(--font-aoyagi-reisho), 'Aoyagi Reisho', 'Ma Shan Zheng', 'ZCOOL XiaoWei', 'STKaiti', 'KaiTi', serif", + fontFamily: "var(--font-aoyagi-reisho), 'Ma Shan Zheng', 'ZCOOL XiaoWei', 'STKaiti', 'KaiTi', serif", fontWeight: 'normal', WebkitFontSmoothing: 'antialiased', MozOsxFontSmoothing: 'grayscale',