import { Card as Card_Type, Rank } from '../game/types' import { Card } from './Card' interface Table_Props { cards: Card_Type[] level: Rank combo_type: string last_play_seat?: number | null } export function Table({ cards, level, combo_type, last_play_seat }: Table_Props) { const card_width = 70 const overlap = 40 const show_highlight = last_play_seat !== null && last_play_seat !== undefined && cards.length > 0 return (
0 ? card_width + (cards.length - 1) * overlap : 100, height: 100, justifyContent: 'center', }} > {cards.length > 0 ? ( cards.map((card, index) => (
{}} />
)) ) : (
No cards played
)}
{combo_type && (
{combo_type}
)}
) }