histogram width divide by mode, not total
Divide by the value that occurs the most frequently, instead of the total games, so the histogram always uses the whole space available, rather than possibly getting smaller and smaller the more games are played.
This commit is contained in:
parent
51457ee8d4
commit
3f6d65fc68
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,7 @@ export const Histogram = ({ gameStats }: Props) => {
|
|||
<Progress
|
||||
key={i}
|
||||
index={i}
|
||||
size={95 * (value / totalGames)}
|
||||
size={95 * (value / Math.max(...winDistribution)}
|
||||
label={String(value)}
|
||||
/>
|
||||
))}
|
||||
|
|
Loading…
Add table
Reference in a new issue