commit 2683d4dc87c57454d1aea40026388de270dbb5e2 parent 1fda6ba1279b27f61141fb24b422ca82650336df Author: Damian Myrda <damian@prime8.dev> Date: Fri, 20 Sep 2024 21:56:01 -0500 feat(web): show total wakatime 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; }