feat: add numbers to RaceChart
This commit is contained in:
parent
406ea9ffdd
commit
70a4ece5bc
@ -64,13 +64,13 @@ const RaceChart: FC<RaceChartProps> = ({ players, std }) => {
|
|||||||
paintOrder={"stroke fill"}
|
paintOrder={"stroke fill"}
|
||||||
fontFamily="monospace"
|
fontFamily="monospace"
|
||||||
>
|
>
|
||||||
{player.name}
|
{index + 1}. {player.name}
|
||||||
</text>
|
</text>
|
||||||
<text
|
<text
|
||||||
key={index}
|
key={index}
|
||||||
x={
|
x={
|
||||||
4 +
|
4 +
|
||||||
Math.max(...players.map((p, _) => p.name.length)) *
|
(4 + Math.max(...players.map((p, _) => p.name.length))) *
|
||||||
(barHeight - 1.5 * gap) *
|
(barHeight - 1.5 * gap) *
|
||||||
0.66
|
0.66
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user