Commit Graph
9 Commits
Author SHA1 Message Date
Alechron 75c921b466 fix(traffic): avoid scientific notation in traffic display near 1000 threshold (#7928)
* fix(traffic): avoid scientific notation in traffic display near 1000 threshold

When a traffic value in any unit (KB, MB, etc.) falls in the 999.5–1000
range, toPrecision(3) rounds it to 1000 but outputs scientific notation
"1.00e+3" instead of plain "1000". Check Math.round(dat) >= 1000 instead
of dat >= 1000 to catch this rounding boundary.

Signed-off-by: Alec <alechron@outlook.com>

* fix(traffic): avoid scientific notation in formatConnectionTraffic

Signed-off-by: Alec <alechron@outlook.com>

---------

Signed-off-by: Alec <alechron@outlook.com>
2026-09-15 05:17:35 +00:00
Slinetrac c672a6fef3 refactor: lint (#6511)
* refactor: lint

* chore: remove eslint-plugin/config-prettier
2026-03-15 07:40:11 +00:00
❤是纱雾酱哟~ ff0de29f17 Fixes traffic parsing for small values (#5737)
- Unified handler to IEC standard.
- Change handler to parse number in a unified style, even with number less than 1000.

Signed-off-by: Dragon1573 <49941141+Dragon1573@users.noreply.github.com>
2025-12-06 09:00:04 +08:00
GyDi 2ce944034d feat: supports show connection detail 2023-08-05 16:52:14 +08:00
GyDi 829361d767 fix: parse bytes precision, close #334 2023-01-11 14:05:49 +08:00
GyDi 3f36dd9a14 fix: parse bytes base 1024 2022-11-24 11:11:31 +08:00
GyDi 10dd9101cd fix: pretty bytes 2022-11-20 23:08:30 +08:00
GyDi 8d7ef0dc94 feat: remove sec field 2021-12-17 00:39:55 +08:00
GyDi a1e99e5303 feat: finish main layout 2021-12-08 23:36:34 +08:00