portal to decorate players by ref instead of ID
This commit is contained in:
@@ -17,7 +17,9 @@ export default (props: { playerKey: string } & Stylable) => {
|
||||
|
||||
return (
|
||||
<div
|
||||
id={`player-${props.playerKey}`}
|
||||
ref={(e) => {
|
||||
if (table != null) table.playerRefs[props.playerKey] = e;
|
||||
}}
|
||||
style={{
|
||||
...props.style,
|
||||
"background-color": playerColor(props.playerKey),
|
||||
|
||||
Reference in New Issue
Block a user