diff --git a/content/reading-tracker.html b/content/reading-tracker.html
index 7f27368..2a77bb5 100644
--- a/content/reading-tracker.html
+++ b/content/reading-tracker.html
@@ -6,461 +6,503 @@
-
hours and minutes total
-
hours and minutes this week
+
+ hours and
+ minutes total
+
+
+
+
32% of
+ total goal
+
+
+
+ hours and
+ minutes this week
+
+
+
+
32% of
+ weekly goal
+
+
+
+ Weekly Reading
+
-Weekly Reading
-
-
Hours of the day
-
-
+
+
Days of the week
-
-
+
+
Minutes spent in each book
-
+
-
-
-
-
-
-
-
+
+
+
+
\ No newline at end of file
+ })
+ .catch((error) => console.log(error));
+
diff --git a/static/reading.js b/static/reading.js
index c55f603..15a91e3 100644
--- a/static/reading.js
+++ b/static/reading.js
@@ -1,4 +1,6 @@
const apiUrl = 'https://drive.carrollmedia.dev:3008';
+const WEEKLY_GOAL = 560;
+const TOTAL_GOAL = 1680;
let tally = 0;
function init() {
// enable active states for buttons in mobile safari
@@ -25,6 +27,12 @@ function updateTally(tallyType = 'reading') {
for(element of tallyDisplayMinutes) {
element.innerText = minutes;
}
+
+ const totalProgress = totalMinutes / TOTAL_GOAL * 100;
+ const totalProgressDisplay = document.getElementById('total-progress');
+ const totalProgressPercent = document.getElementById('total-progress-percent');
+ totalProgressDisplay.setAttribute('value', totalProgress);
+ totalProgressPercent.innerHTML = `${totalProgress.toFixed()}% `;
});
}