/** * High-quality vector SVGs for standard Chess pieces (Staunton design). * Provides clean, crisp rendering at all DPRs and sizes. */ export type PieceType = "k" | "q" | "r" | "b" | "n" | "p"; export type PieceColor = "w" | "b"; const PIECE_SVGS: Record = { k: { w: ` `, b: ` `, }, q: { w: ` `, b: ` `, }, r: { w: ` `, b: ` `, }, b: { w: ` `, b: ` `, }, n: { w: ` `, b: ` `, }, p: { w: ` `, b: ` `, }, }; export function getPieceSvg(type: PieceType | null, color: PieceColor | null): string { if (!type || !color) return ""; return PIECE_SVGS[type]?.[color] ?? ""; }