From 07bdb02ac7b6a9e7052525498b62fabebba54625 Mon Sep 17 00:00:00 2001 From: Marisol Lopez Date: Sat, 20 May 2017 21:45:45 -0700 Subject: [PATCH 1/2] added functinoality for changing hour from military time to regular time --- index.html | 1 + index.js | 15 ++++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index 191d3cc..fa68522 100644 --- a/index.html +++ b/index.html @@ -11,4 +11,5 @@ + diff --git a/index.js b/index.js index 877a3aa..8843f44 100644 --- a/index.js +++ b/index.js @@ -1 +1,14 @@ -// Your code here +$(document).ready(function() { + var intervalID = window.setInterval(myCallback, 1000); + function myCallback() { + var today = new Date(); + var currentTime = { + currentHour: (today.getHours() > 12 ? (today.getHours() - 12) : today.getHours()), + currentMinute: (today.getMinutes() < 10 ? '0':'') + today.getMinutes(), + currentSecond: (today.getSeconds() < 10 ? '0':'') + today.getSeconds(), + amOrPm: (today.getHours() > 12 ? "pm" : "am") + }; + var currentTime = "Current Time: " + currentTime.currentHour + ":" + currentTime.currentMinute + ":" + currentTime.currentSecond + currentTime.amOrPm; + $('#clock').html(currentTime); + }; +}); From abcdc5e6fbb80309cbb85f088532719be44c02ee Mon Sep 17 00:00:00 2001 From: Marisol Lopez Date: Sat, 20 May 2017 21:52:49 -0700 Subject: [PATCH 2/2] changed font --- index.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.css b/index.css index ec4a909..931ec59 100644 --- a/index.css +++ b/index.css @@ -9,7 +9,7 @@ body { position: absolute; top: 0; left: 0; bottom: 0; right: 0; padding-top: 70px; - font-family: courier, monospace; + font-family: 'Arimo', sans-serif; text-align: center; color: white; font-size: 100px;