diff --git a/groups/new-homepage-3/homepage3-js-css.html b/groups/new-homepage-3/homepage3-js-css.html index 24d05bd..1bb1d6d 100644 --- a/groups/new-homepage-3/homepage3-js-css.html +++ b/groups/new-homepage-3/homepage3-js-css.html @@ -84,12 +84,14 @@ img { outline: 0; } -/* style the hours div */ -.hours-div { - background-color: #bbb; - height: 150px; - text-align: center; - padding-top: 35px; +/* style the hours */ +.hours { + text-align:right; + border-top: solid white 0px !important; +} + +.date { + border-top: solid white 0px !important; } /* style the yamm menu */ @@ -132,17 +134,16 @@ window.onload = function () { const h = JSON.parse(hours) const options = { weekday: 'long', year: 'numeric', month: 'long', day: 'numeric' }; for (var i = 0; i < h.length; i++) { - var targetDate = new Date(h[i]["Date"] + "T00:00:00.000-05:00"); - var today = new Date(); + let targetDate = new Date(h[i]["Date"] + "T00:00:00.000-05:00"); + let today = new Date(); if (targetDate.getFullYear() === today.getFullYear() && targetDate.getMonth() === today.getMonth() && targetDate.getDate() === today.getDate()) { - document.getElementById('hours0').innerHTML = targetDate.toLocaleDateString("en-US", options) + " - " + h[i]["Hours"] - start = true; - count = 1; - }; - if (start === true && count < 4) { - document.getElementById('hours' + count).innerHTML = targetDate.toLocaleDateString("en-US", options) + " - " + h[i]["Hours"] + document.getElementById('hours0').innerHTML = "