feat: add share and edit links to preset modal, sync URL preset param

This commit is contained in:
2026-04-28 09:32:18 +08:00
parent f502d120a7
commit a2ff39c1b0
3 changed files with 78 additions and 14 deletions
+14 -11
View File
@@ -1,4 +1,5 @@
import type { Metadata } from "next"
import { Suspense } from "react"
import { notFound } from "next/navigation"
import { after } from "next/server"
import { db } from "@/lib/db/index"
@@ -326,17 +327,19 @@ export default async function GamePage({
}),
}}
/>
<GamePageClient
game={serializedGame}
counts={{
benchmarks: benchmarkCount,
presets: presetCount,
comments: commentCount,
}}
platformSupport={platformSupport}
presets={serializedPresets}
gameId={game.id}
/>
<Suspense fallback={<div className="min-h-screen" />}>
<GamePageClient
game={serializedGame}
counts={{
benchmarks: benchmarkCount,
presets: presetCount,
comments: commentCount,
}}
platformSupport={platformSupport}
presets={serializedPresets}
gameId={game.id}
/>
</Suspense>
</>
)
}