@interactjs/pointer-events
Advanced tools
Comparing version 1.4.0-alpha.16 to 1.4.0-alpha.17
@@ -144,3 +144,3 @@ import * as utils from '@interactjs/utils'; | ||
interactions.signals.on('update-pointer', function ({ down, pointerInfo }) { | ||
if (!down) { | ||
if (!down && pointerInfo.hold) { | ||
return; | ||
@@ -147,0 +147,0 @@ } |
{ | ||
"name": "@interactjs/pointer-events", | ||
"version": "1.4.0-alpha.16+sha.5b3c738", | ||
"version": "1.4.0-alpha.17+sha.793e5fa", | ||
"peerDependencies": { | ||
"@interactjs/core": "1.4.0-alpha.16+sha.5b3c738", | ||
"@interactjs/utils": "1.4.0-alpha.16+sha.5b3c738" | ||
"@interactjs/core": "1.4.0-alpha.17+sha.793e5fa", | ||
"@interactjs/utils": "1.4.0-alpha.17+sha.793e5fa" | ||
}, | ||
"devDependencies": { | ||
"@interactjs/_dev": "1.4.0-alpha.16+sha.5b3c738", | ||
"@interactjs/core": "1.4.0-alpha.16+sha.5b3c738", | ||
"@interactjs/utils": "1.4.0-alpha.16+sha.5b3c738" | ||
"@interactjs/_dev": "1.4.0-alpha.17+sha.793e5fa", | ||
"@interactjs/core": "1.4.0-alpha.17+sha.793e5fa", | ||
"@interactjs/utils": "1.4.0-alpha.17+sha.793e5fa" | ||
}, | ||
@@ -13,0 +13,0 @@ "publishConfig": { |
@@ -67,3 +67,3 @@ import test from '@interactjs/_dev/test/test'; | ||
interaction.updatePointer({}); | ||
interaction.updatePointer({}, {}); | ||
@@ -128,13 +128,15 @@ const tapEvent = Object.assign(new pointerEvents.PointerEvent('tap', {}, {}, null, interaction), { | ||
const interaction = scope.interactions.new({}); | ||
const initialTimer = { duration: Infinity, timeout: null }; | ||
const initialHold = { duration: Infinity, timeout: null }; | ||
const event = {}; | ||
interaction.updatePointer(helpers.newPointer(0), event, null, false); | ||
t.deepEqual(interaction.pointers.map(p => p.hold), [undefined]); | ||
t.deepEqual(interaction.pointers.map(p => p.hold), [initialHold], 'set hold info for move on new pointer'); | ||
interaction.removePointer(helpers.newPointer(0), event); | ||
interaction.updatePointer(helpers.newPointer(0), event, null, true); | ||
t.deepEqual(interaction.pointers.map(p => p.hold), [initialTimer]); | ||
t.deepEqual(interaction.pointers.map(p => p.hold), [initialHold]); | ||
interaction.updatePointer(helpers.newPointer(5), event, null, true); | ||
t.deepEqual(interaction.pointers.map(p => p.hold), [initialTimer, initialTimer]); | ||
t.deepEqual(interaction.pointers.map(p => p.hold), [initialHold, initialHold]); | ||
@@ -161,3 +163,3 @@ t.end(); | ||
for (const id of ids) { | ||
const index = interaction.updatePointer({ pointerId: id }, null, true); | ||
const index = interaction.updatePointer({ pointerId: id }, {}, true); | ||
// use the ids as the pointerInfo.hold value for this test | ||
@@ -164,0 +166,0 @@ interaction.pointers[index].hold = id; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
23652
641