import React from "react"; import "./css/lobby.css" import Colors from "./util/colors"; import deck from './img/deck.svg'; import { SiteState } from "./StateRouter"; export default function Lobby({ message, pickColor, deal }) { const { color, options, state: { code: state, args: { game_code, ...state_args } } } = message; const freeColors = (options && options.map((o) => o.color)) || []; const circle_args = { state, myColor: color, freeColors, pickColor }; return
{ state === SiteState.JOIN_OTHERS &&

Je kan meedoen door naar {window.location.host}/{game_code} te gaan

}{/*
*/}{ state !== SiteState.JOIN_OTHERS &&
}{ state === SiteState.FIRST_DEAL &&
kaartenstapel
Delen
}
} function Circle({ state, color, myColor, freeColors, pickColor }) { const isMine = color === myColor; const isSelectable = freeColors.includes(color) const isPicked = state === SiteState.PICK_COLOR && !isSelectable; return
isSelectable && pickColor(color)} />
}