motion-dom 11.16.1 → 11.16.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/index.js CHANGED
@@ -363,7 +363,7 @@ function hover(elementOrSelector, onHoverStart, options = {}) {
363
363
  const onPointerEnter = filterEvents$1((enterEvent) => {
364
364
  const { target } = enterEvent;
365
365
  const onHoverEnd = onHoverStart(enterEvent);
366
- if (!onHoverEnd || !target)
366
+ if (typeof onHoverEnd !== "function" || !target)
367
367
  return;
368
368
  const onPointerLeave = filterEvents$1((leaveEvent) => {
369
369
  onHoverEnd(leaveEvent);
@@ -502,7 +502,7 @@ function press(elementOrSelector, onPressStart, options = {}) {
502
502
  return;
503
503
  }
504
504
  isPressing.delete(element);
505
- if (onPressEnd) {
505
+ if (typeof onPressEnd === "function") {
506
506
  onPressEnd(endEvent, { success });
507
507
  }
508
508
  };
@@ -24,7 +24,7 @@ function hover(elementOrSelector, onHoverStart, options = {}) {
24
24
  const onPointerEnter = filterEvents((enterEvent) => {
25
25
  const { target } = enterEvent;
26
26
  const onHoverEnd = onHoverStart(enterEvent);
27
- if (!onHoverEnd || !target)
27
+ if (typeof onHoverEnd !== "function" || !target)
28
28
  return;
29
29
  const onPointerLeave = filterEvents((leaveEvent) => {
30
30
  onHoverEnd(leaveEvent);
@@ -47,7 +47,7 @@ function press(elementOrSelector, onPressStart, options = {}) {
47
47
  return;
48
48
  }
49
49
  isPressing.delete(element);
50
- if (onPressEnd) {
50
+ if (typeof onPressEnd === "function") {
51
51
  onPressEnd(endEvent, { success });
52
52
  }
53
53
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "motion-dom",
3
- "version": "11.16.1",
3
+ "version": "11.16.3",
4
4
  "author": "Matt Perry",
5
5
  "license": "MIT",
6
6
  "repository": "https://github.com/motiondivision/motion",
@@ -23,5 +23,5 @@
23
23
  "build": "yarn clean && tsc -p . && rollup -c",
24
24
  "dev": "concurrently -c blue,red -n tsc,rollup --kill-others \"tsc --watch -p . --preserveWatchOutput\" \"rollup --config --watch --no-watch.clearScreen\""
25
25
  },
26
- "gitHead": "d0d281ab97fe3ceef4d582d8da622faab907998d"
26
+ "gitHead": "e8c2bdf87d22ae5f036caefc19acc6c1ac192549"
27
27
  }