Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions packages/core/constants/supported-games.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/**
* Games listed on /games as supported at checkout via Paymenter's product
* config option — there's no API to read this list live (the admin API's
* `include` allowlist has no config-options relationship), so it's
* maintained by hand here. Keep in sync with the checkout dropdown.
*/
export const SUPPORTED_GAMES = [
"Minecraft",
"Rust",
"Hytale",
] as const
11 changes: 11 additions & 0 deletions packages/ui/components/Layouts/Games/game-hub.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ import Link from "next/link"
import { cn } from "@/lib/utils"
import type { GamePlanSpec } from "@/packages/core/types/servers/game"
import { Price } from "@/packages/ui/components/ui/price"
import { SUPPORTED_GAMES } from "@/packages/core/constants/supported-games"

type SortKey = "default" | "asc" | "desc"

Expand Down Expand Up @@ -224,6 +225,16 @@ export function GameHub({ plans }: GameHubProps) {
<p className="text-lg text-muted-foreground">
One set of plans for every game we support. Pick a tier below, then choose which game to deploy at checkout.
</p>
<div className="flex flex-wrap items-center justify-center gap-2 pt-2">
{SUPPORTED_GAMES.map((game) => (
<span
key={game}
className="inline-flex items-center px-3 py-1 rounded-full text-xs font-medium border border-border/50 bg-muted/30 text-muted-foreground"
>
{game}
</span>
))}
</div>
</div>

{/* ── Filter bar ───────────────────────────────────────────────────── */}
Expand Down