mirror of
https://github.com/vector-im/element-web.git
synced 2025-08-16 03:07:04 +02:00
Fix percentage calculation
This commit is contained in:
parent
ab51404421
commit
f06aa00240
@ -38,5 +38,5 @@ export function percentageWithin(pct: number, min: number, max: number): number
|
||||
}
|
||||
|
||||
export function percentageOf(val: number, min: number, max: number): number {
|
||||
return (val - min) / max;
|
||||
return (val - min) / (max - min);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user