feat: add Steam review score badge to game details hero section

This commit is contained in:
2026-04-30 22:11:13 +08:00
parent 9df2677fd5
commit 99766d3b4b
+13
View File
@@ -516,6 +516,19 @@ export function GamePageClient({
}
/>
)}
{/* Steam review score */}
{game.steamReviewScore != null && (
<span className="inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-blue-500/15 text-blue-400 border border-blue-500/30 text-xs font-medium">
<svg className="h-3 w-3" viewBox="0 0 24 24" fill="currentColor">
<path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z" />
</svg>
{game.steamReviewScore}% Positive
{game.steamReviewSentiment && (
<span className="text-blue-300/70">({game.steamReviewSentiment.replace(/_/g, ' ')})</span>
)}
</span>
)}
</div>
{/* Subtitle */}