You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Application-Web/front/components/editor/PlayerPiece.tsx

22 lines
472 B

import "../../style/player.css"
import { PlayerTeam } from "../../model/tactic/Player"
export interface PlayerPieceProps {
team: PlayerTeam
text: string
hasBall: boolean
}
export function PlayerPiece({ team, text, hasBall }: PlayerPieceProps) {
let className = `player-piece ${team}`
if (hasBall) {
className += ` player-piece-has-ball`
}
return (
<div className={className}>
<p>{text}</p>
</div>
)
}