Repository navigation
Commit 9a5156e
committed
fix(tui): roll over compact counts to M at 999,950
Locale.number() formats the thousands value with toFixed(1), so counts
from 999,950 to 999,999 rounded to 1000.0 and rendered as "1000.0K". The
>= 1000000 branch could not promote them because the count itself is
still below a million. It shows up in the TUI context indicator on ~1M
context models as "1000.0K (100%)".
Roll over at 999,950 instead, the point where one-decimal rounding first
reaches 1000.0K, so those counts render as "1.0M".
Closes anomalyco#339471 parent 8e0f1c2 commit 9a5156e
2 files changed
Lines changed: 27 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
0 commit comments