Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ When this event is processed, the target's border is set to `dashed` to provide

```js
function pointermoveHandler(ev) {
// This function implements a 2-pointer horizontal pinch/zoom gesture.
// This function implements a 2-pointer pinch/zoom gesture.
//
// If the distance between the two pointers has increased (zoom in),
// the target element's background is changed to "pink" and if the
Expand All @@ -100,7 +100,10 @@ function pointermoveHandler(ev) {
// If two pointers are down, check for pinch gestures
if (evCache.length === 2) {
// Calculate the distance between the two pointers
const curDiff = Math.abs(evCache[0].clientX - evCache[1].clientX);
const curDiff = Math.hypot(
evCache[0].clientX - evCache[1].clientX,
evCache[0].clientY - evCache[1].clientY,
);

if (prevDiff > 0) {
if (curDiff > prevDiff) {
Expand Down
1 change: 0 additions & 1 deletion files/en-us/web/css/reference/values/named-color/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -882,7 +882,6 @@ In addition to these 16 colors, about 150 other colors have a keyword associated
<td><code>#9acd32</code></td>
<td style="background: yellowgreen"></td>
</tr>
<tr>
</tbody>
</table>

Expand Down