From 2d146b873f758d7445cb95fa25014b8298915395 Mon Sep 17 00:00:00 2001 From: Lisa Huang Date: Sun, 29 Apr 2018 19:06:22 +0100 Subject: [PATCH] Added notes and solution for Project 10 - Checking Multiple Checkboxes --- .../index-projectnotes.html | 34 +++++++++++++++++++ readme.md | 18 ++++++++++ 2 files changed, 52 insertions(+) diff --git a/10 - Hold Shift and Check Checkboxes/index-projectnotes.html b/10 - Hold Shift and Check Checkboxes/index-projectnotes.html index a02071ff00..f2d0c95273 100644 --- a/10 - Hold Shift and Check Checkboxes/index-projectnotes.html +++ b/10 - Hold Shift and Check Checkboxes/index-projectnotes.html @@ -99,6 +99,40 @@ diff --git a/readme.md b/readme.md index eb8f20f563..08d2c04073 100644 --- a/readme.md +++ b/readme.md @@ -601,4 +601,22 @@ The `performance.now()` method returns a `DOMHighResTimeStamp`, measured in mill `DOMHighResTimeStamp` type is a `double` and is used to store a time value. The value could be a discrete point in time or the difference in time between two discrete points in time. +## Project 10: Hold SHIFT to Check Multiple Checkboxes + +### [Event Interface](https://developer.mozilla.org/en-US/docs/Web/API/Event) + +The `Event` interface represents any event which takes place in the DOM; some are user-generated (such as mouse or keyboard events), while others are generated by APIs (such as events that indicate an animation has finished running, a video has been paused, and so forth). + +### [MouseEvent](https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent) + +The MouseEvent interface represents events that occur due to the user interacting with a pointing device (such as a mouse). Common events using this interface include `click, dblclick, mouseup, mousedown.` + +`MouseEvent` properties covered in this project: + +* `MouseEvent.shiftKey`: Returns true if the shift key was down when the mouse event was fired. + +Other related properties: +* `MouseEvent.ctrlKey `: Returns true if the control key was down when the mouse event was fired. +* `MouseEvent.clientX`: The X coordinate of the mouse pointer in local (DOM content) coordinates. +* `MouseEvent.clientY`: The Y coordinate of the mouse pointer in local (DOM content) coordinates.