From a288eb240cf52e3b328f8447030d80b07b63bbc4 Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Wed, 25 Jan 2017 19:49:38 -0800 Subject: [PATCH 1/7] completed lesson 01 drum kit --- 01 - JavaScript Drum Kit/index-START.html | 40 +++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/01 - JavaScript Drum Kit/index-START.html b/01 - JavaScript Drum Kit/index-START.html index 4070d32767..77c758fd6a 100644 --- a/01 - JavaScript Drum Kit/index-START.html +++ b/01 - JavaScript Drum Kit/index-START.html @@ -58,7 +58,47 @@ From f08dffaf9d40ca705a48d469556483f6431fac3d Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Thu, 26 Jan 2017 12:16:44 -0800 Subject: [PATCH 2/7] fix typo --- 01 - JavaScript Drum Kit/index-START.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/01 - JavaScript Drum Kit/index-START.html b/01 - JavaScript Drum Kit/index-START.html index 77c758fd6a..c379aff462 100644 --- a/01 - JavaScript Drum Kit/index-START.html +++ b/01 - JavaScript Drum Kit/index-START.html @@ -91,7 +91,7 @@ - html5 media elements (audio) have a currentTime method as well as many other methods - Element.classList has an add, remove, and toggle method which looks just as easy to use as using jquery's addClass method - - transitions are events that I can listen for https://developer.mozilla.org/en-US/docs/Web/Events/transitionend. Similaryly, can also listen for animations using the animation end event. + - transitions are events that I can listen for https://developer.mozilla.org/en-US/docs/Web/Events/transitionend. Similarly, can also listen for animations using the animation end event. */ /* misc: From 64a927c1cbf0cc3602e9d7b79518fb2b7f40128e Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Thu, 26 Jan 2017 14:29:50 -0800 Subject: [PATCH 3/7] completed lesson 02 clock --- 02 - JS and CSS Clock/index-START.html | 36 ++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/02 - JS and CSS Clock/index-START.html b/02 - JS and CSS Clock/index-START.html index 2712384201..4739914821 100644 --- a/02 - JS and CSS Clock/index-START.html +++ b/02 - JS and CSS Clock/index-START.html @@ -61,13 +61,49 @@ background:black; position: absolute; top:50%; + transform-origin: 100%; + transform: rotate(90deg); + transition: all 0.05s; /* I like .5s if the hand is not moving as far each time */ + transition-timing-function: cubic-bezier(0.1, 2.7, 0.58, 1); /* There is a curve picker in Chrome dev tools. Sweet! */ } From 365125bbe28ce4c4964b7855bfa92e73214f2e25 Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Thu, 26 Jan 2017 15:30:59 -0800 Subject: [PATCH 4/7] fix bug where transition of hands rewind by removing and adding a transition class at the end of each minute or hour --- 02 - JS and CSS Clock/index-START.html | 30 ++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/02 - JS and CSS Clock/index-START.html b/02 - JS and CSS Clock/index-START.html index 4739914821..52d6d5394a 100644 --- a/02 - JS and CSS Clock/index-START.html +++ b/02 - JS and CSS Clock/index-START.html @@ -10,7 +10,7 @@
-
+
@@ -63,7 +63,10 @@ top:50%; transform-origin: 100%; transform: rotate(90deg); - transition: all 0.05s; /* I like .5s if the hand is not moving as far each time */ + } + + .hand-transition { + transition: all .05s; /* I like .5s if the hand is not moving as far each time */ transition-timing-function: cubic-bezier(0.1, 2.7, 0.58, 1); /* There is a curve picker in Chrome dev tools. Sweet! */ } @@ -71,8 +74,21 @@ From 76032bbef56f54c060ac4c5b426b042a14007330 Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Thu, 26 Jan 2017 15:40:37 -0800 Subject: [PATCH 5/7] update notes about what i learned --- 02 - JS and CSS Clock/index-START.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/02 - JS and CSS Clock/index-START.html b/02 - JS and CSS Clock/index-START.html index 52d6d5394a..341129595f 100644 --- a/02 - JS and CSS Clock/index-START.html +++ b/02 - JS and CSS Clock/index-START.html @@ -125,6 +125,8 @@ - Adding and removing the transition property is best done by creating a new class just for the transitions and adding/removing that class. When I tried to re-apply a transition duration, it did not kick back in. + https://blog.alexmaccaw.com/css-transitions + https://www.bennadel.com/blog/2461-understanding-css-transitions-and-class-timing.htm */ From 1d488bc0c005d335753e3affb7b39fbe1593c961 Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Fri, 27 Jan 2017 15:29:05 -0800 Subject: [PATCH 6/7] add comment to what I learned --- 01 - JavaScript Drum Kit/index-START.html | 1 + 1 file changed, 1 insertion(+) diff --git a/01 - JavaScript Drum Kit/index-START.html b/01 - JavaScript Drum Kit/index-START.html index c379aff462..d186f0c679 100644 --- a/01 - JavaScript Drum Kit/index-START.html +++ b/01 - JavaScript Drum Kit/index-START.html @@ -92,6 +92,7 @@ - Element.classList has an add, remove, and toggle method which looks just as easy to use as using jquery's addClass method - transitions are events that I can listen for https://developer.mozilla.org/en-US/docs/Web/Events/transitionend. Similarly, can also listen for animations using the animation end event. + - an example of when to use data attributes */ /* misc: From 0e39a8c78fe0ec96c476f5c04191e2d03ef834ec Mon Sep 17 00:00:00 2001 From: LindsayElia Date: Mon, 6 Feb 2017 19:53:13 -0800 Subject: [PATCH 7/7] add comment about string template literals --- 01 - JavaScript Drum Kit/index-START.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/01 - JavaScript Drum Kit/index-START.html b/01 - JavaScript Drum Kit/index-START.html index d186f0c679..ecc908525b 100644 --- a/01 - JavaScript Drum Kit/index-START.html +++ b/01 - JavaScript Drum Kit/index-START.html @@ -93,6 +93,8 @@ to use as using jquery's addClass method - transitions are events that I can listen for https://developer.mozilla.org/en-US/docs/Web/Events/transitionend. Similarly, can also listen for animations using the animation end event. - an example of when to use data attributes + - template literals, strings enclosed in backticks with ${} to insert variables + https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals */ /* misc: