Add the Sokko TCG collectible card mini-game

Add the server-backed card game: Discord login, recharging pack openings,
album, trades, gifts, stardust shop, campaign codes and its administration,
stored in SQLite and disabled in production until configured.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Shinuwa 2026-11-05 17:47:35 +01:00
parent 243465720f
commit 5ce35cd7ba
193 changed files with 12159 additions and 28 deletions

View file

@ -0,0 +1,21 @@
// Rôle : rend le dos visuel partagé d'une collection pour les paquets et cartes inconnues.
const SYMBOLS = {
star: <path d="M24 5 28 20 43 24 28 28 24 43 20 28 5 24 20 20Z" />,
rift: <><path d="M10 35C18 18 28 12 39 9" /><path d="M9 40C22 36 31 27 39 12" /></>,
orbit: <><ellipse cx="24" cy="24" rx="19" ry="9" /><path d="M24 12 27 21 36 24 27 27 24 36 21 27 12 24 21 21Z" /></>
};
export function CollectionCardBack({ collection }) {
const back = collection?.back || { primary: "#7c3aed", secondary: "#312e81", symbol: "star" };
return <span
className="nebula-collection-back"
data-back-symbol={back.symbol}
data-has-image={back.image ? "true" : undefined}
style={{ "--pack-primary": back.primary, "--pack-secondary": back.secondary }}
>
{back.image
? <img className="nebula-collection-back-image" src={back.image} alt="" aria-hidden="true" />
: <><span className="nebula-collection-back-rings" aria-hidden="true" /><svg viewBox="0 0 48 48" aria-hidden="true">{SYMBOLS[back.symbol] || SYMBOLS.star}</svg></>}
{collection?.name && <span className="nebula-collection-back-copy"><strong>{collection.name}</strong></span>}
</span>;
}