diff --git a/web/src/components/landing/HeroSection.tsx b/web/src/components/landing/HeroSection.tsx index ecc93f0a..fda8ff8c 100644 --- a/web/src/components/landing/HeroSection.tsx +++ b/web/src/components/landing/HeroSection.tsx @@ -22,6 +22,9 @@ export default function HeroSection({ language }: HeroSectionProps) { duration: 2000, }) + // 格式化 stars 显示 + const formattedStars = (animatedStars / 1000).toFixed(1) + const fadeInUp = { initial: { opacity: 0, y: 60 }, animate: { opacity: 1, y: 0 }, @@ -48,12 +51,12 @@ export default function HeroSection({ language }: HeroSectionProps) { ) : language === 'zh' ? ( <> {daysOld} 天内{' '} - {(animatedStars / 1000).toFixed(1)} + {formattedStars} K+ GitHub Stars ) : ( <> - {(animatedStars / 1000).toFixed(1)} + {formattedStars} K+ GitHub Stars in {daysOld} days )}