From 974722099b5267bc4e9e8cdbb179f0f4f81fffb2 Mon Sep 17 00:00:00 2001 From: sahil865gupta Date: Wed, 21 Dec 2016 20:33:59 +0530 Subject: [PATCH] Fixed angles for hour and min --- 02 - JS + CSS Clock/index-FINISHED.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/02 - JS + CSS Clock/index-FINISHED.html b/02 - JS + CSS Clock/index-FINISHED.html index db653a5..ac30c1e 100644 --- a/02 - JS + CSS Clock/index-FINISHED.html +++ b/02 - JS + CSS Clock/index-FINISHED.html @@ -81,11 +81,11 @@ secondHand.style.transform = `rotate(${secondsDegrees}deg)`; const mins = now.getMinutes(); - const minsDegrees = ((mins / 60) * 360) + 90; + const minsDegrees = ((mins / 60) * 360) + ((seconds/60)*6) + 90; minsHand.style.transform = `rotate(${minsDegrees}deg)`; const hour = now.getHours(); - const hourDegrees = ((hour / 12) * 360) + 90; + const hourDegrees = ((hour / 12) * 360) + ((mins/60)*30) + 90; hourHand.style.transform = `rotate(${hourDegrees}deg)`; } -- knotmirror 0.0.1