commit e2a9a18ec035d56a7a4664f682b106acc16a1e40 parent a83486e587d2b8baeec0ee65664d070c4de7e5e3 Author: Damian Myrda <damian@prime8.dev> Date: Fri, 20 Sep 2024 21:56:01 -0500 Show total activity Diffstat:
| M | web/static/js/wakatime.js | | | 4 | ++++ |
1 file changed, 4 insertions(+), 0 deletions(-)
diff --git a/web/static/js/wakatime.js b/web/static/js/wakatime.js @@ -31,6 +31,10 @@ function createChart(data) { table.forEach((row) => { chart += createRow(row, max_length, total_hours); }); + var total_minutes = total_hours % 1; + total_hours -= total_minutes; + total_minutes = Math.ceil(total_minutes * 60); + chart += `total: ${total_hours} hours and ${total_minutes} minutes`; return chart; }