@interactjs/actions
Advanced tools
Comparing version 1.4.0-alpha.28 to 1.4.0-alpha.29
@@ -20,3 +20,3 @@ import Interactable from '@interactjs/core/Interactable'; | ||
*/ | ||
constructor(dropStatus: any, dragEvent: any, type: any); | ||
constructor(dropState: Interaction['dropState'], dragEvent: any, type: any); | ||
/** | ||
@@ -23,0 +23,0 @@ * If this is a `dropactivate` event, the dropzone element will be |
@@ -6,8 +6,8 @@ import * as arr from '@interactjs/utils/arr'; | ||
*/ | ||
constructor(dropStatus, dragEvent, type) { | ||
constructor(dropState, dragEvent, type) { | ||
this.propagationStopped = false; | ||
this.immediatePropagationStopped = false; | ||
const { element, dropzone } = type === 'dragleave' | ||
? dropStatus.prev | ||
: dropStatus.cur; | ||
? dropState.prev | ||
: dropState.cur; | ||
this.type = type; | ||
@@ -31,21 +31,21 @@ this.target = element; | ||
reject() { | ||
const { dropStatus } = this.interaction; | ||
const { dropState } = this.interaction; | ||
if ((this.type !== 'dropactivate') && (!this.dropzone || | ||
dropStatus.cur.dropzone !== this.dropzone || | ||
dropStatus.cur.element !== this.target)) { | ||
dropState.cur.dropzone !== this.dropzone || | ||
dropState.cur.element !== this.target)) { | ||
return; | ||
} | ||
dropStatus.prev.dropzone = this.dropzone; | ||
dropStatus.prev.element = this.target; | ||
dropStatus.rejected = true; | ||
dropStatus.events.enter = null; | ||
dropState.prev.dropzone = this.dropzone; | ||
dropState.prev.element = this.target; | ||
dropState.rejected = true; | ||
dropState.events.enter = null; | ||
this.stopImmediatePropagation(); | ||
if (this.type === 'dropactivate') { | ||
const activeDrops = dropStatus.activeDrops; | ||
const activeDrops = dropState.activeDrops; | ||
const index = arr.findIndex(activeDrops, ({ dropzone, element }) => dropzone === this.dropzone && element === this.target); | ||
dropStatus.activeDrops = [ | ||
dropState.activeDrops = [ | ||
...activeDrops.slice(0, index), | ||
...activeDrops.slice(index + 1), | ||
]; | ||
const deactivateEvent = new DropEvent(dropStatus, this.dragEvent, 'dropdeactivate'); | ||
const deactivateEvent = new DropEvent(dropState, this.dragEvent, 'dropdeactivate'); | ||
deactivateEvent.dropzone = this.dropzone; | ||
@@ -56,3 +56,3 @@ deactivateEvent.target = this.target; | ||
else { | ||
this.dropzone.fire(new DropEvent(dropStatus, this.dragEvent, 'dragleave')); | ||
this.dropzone.fire(new DropEvent(dropState, this.dragEvent, 'dragleave')); | ||
} | ||
@@ -69,2 +69,2 @@ } | ||
export default DropEvent; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiRHJvcEV2ZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiRHJvcEV2ZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUlBLE9BQU8sS0FBSyxHQUFHLE1BQU0sdUJBQXVCLENBQUE7QUFFNUMsTUFBTSxTQUFTO0lBYWI7O09BRUc7SUFDSCxZQUFhLFVBQVUsRUFBRSxTQUFTLEVBQUUsSUFBSTtRQU54Qyx1QkFBa0IsR0FBRyxLQUFLLENBQUE7UUFDMUIsZ0NBQTJCLEdBQUcsS0FBSyxDQUFBO1FBTWpDLE1BQU0sRUFBRSxPQUFPLEVBQUUsUUFBUSxFQUFFLEdBQUcsSUFBSSxLQUFLLFdBQVc7WUFDaEQsQ0FBQyxDQUFDLFVBQVUsQ0FBQyxJQUFJO1lBQ2pCLENBQUMsQ0FBQyxVQUFVLENBQUMsR0FBRyxDQUFBO1FBRWxCLElBQUksQ0FBQyxJQUFJLEdBQVksSUFBSSxDQUFBO1FBQ3pCLElBQUksQ0FBQyxNQUFNLEdBQVUsT0FBTyxDQUFBO1FBQzVCLElBQUksQ0FBQyxhQUFhLEdBQUcsT0FBTyxDQUFBO1FBQzVCLElBQUksQ0FBQyxRQUFRLEdBQVEsUUFBUSxDQUFBO1FBQzdCLElBQUksQ0FBQyxTQUFTLEdBQU8sU0FBUyxDQUFBO1FBQzlCLElBQUksQ0FBQyxhQUFhLEdBQUcsU0FBUyxDQUFDLE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09IHRoaXMuZHJvcHpvbmUgJiYgZWxlbWVudCA9PT0gdGhpcy50YXJnZXQpXG5cbiAgICAgIGRyb3BTdGF0ZS5hY3RpdmVEcm9wcyA9IFtcbiAgICAgICAgLi4uYWN0aXZlRHJvcHMuc2xpY2UoMCwgaW5kZXgpLFxuICAgICAgICAuLi5hY3RpdmVEcm9wcy5zbGljZShpbmRleCArIDEpLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBkZWFjdGl2YXRlRXZlbnQgPSBuZXcgRHJvcEV2ZW50KGRyb3BTdGF0ZSwgdGhpcy5kcmFnRXZlbnQsICdkcm9wZGVhY3RpdmF0ZScpXG5cbiAgICAgIGRlYWN0aXZhdGVFdmVudC5kcm9wem9uZSA9IHRoaXMuZHJvcHpvbmVcbiAgICAgIGRlYWN0aXZhdGVFdmVudC50YXJnZXQgPSB0aGlzLnRhcmdldFxuXG4gICAgICB0aGlzLmRyb3B6b25lLmZpcmUoZGVhY3RpdmF0ZUV2ZW50KVxuICAgIH1cbiAgICBlbHNlIHtcbiAgICAgIHRoaXMuZHJvcHpvbmUuZmlyZShuZXcgRHJvcEV2ZW50KGRyb3BTdGF0ZSwgdGhpcy5kcmFnRXZlbnQsICdkcmFnbGVhdmUnKSlcbiAgICB9XG4gIH1cblxuICBwcmV2ZW50RGVmYXVsdCAoKSB7fVxuXG4gIHN0b3BQcm9wYWdhdGlvbiAoKSB7XG4gICAgdGhpcy5wcm9wYWdhdGlvblN0b3BwZWQgPSB0cnVlXG4gIH1cblxuICBzdG9wSW1tZWRpYXRlUHJvcGFnYXRpb24gKCkge1xuICAgIHRoaXMuaW1tZWRpYXRlUHJvcGFnYXRpb25TdG9wcGVkID0gdGhpcy5wcm9wYWdhdGlvblN0b3BwZWQgPSB0cnVlXG4gIH1cbn1cblxuZXhwb3J0IGRlZmF1bHQgRHJvcEV2ZW50XG4iXX0= |
@@ -13,3 +13,3 @@ import Interactable from '@interactjs/core/Interactable'; | ||
interface Interaction { | ||
dropStatus?: { | ||
dropState?: { | ||
cur: { | ||
@@ -27,3 +27,3 @@ dropzone: Interactable; | ||
dropzone: Interactable; | ||
Element: Element; | ||
element: Element; | ||
rect: Interact.Rect; | ||
@@ -51,8 +51,8 @@ }>; | ||
declare function getActiveDrops(scope: Scope, dragElement: Element): any[]; | ||
declare function getDrop({ dropStatus, target: draggable, element: dragElement }: { | ||
dropStatus: any; | ||
target: any; | ||
element: any; | ||
}, dragEvent: any, pointerEvent: any): any; | ||
declare function getDropEvents(interaction: any, _pointerEvent: any, dragEvent: any): { | ||
declare function getDrop({ dropState, interactable: draggable, element: dragElement }: Partial<Interact.Interaction>, dragEvent: any, pointerEvent: any): { | ||
dropzone: Interactable; | ||
element: Element; | ||
rect: import("../../types/types").Rect; | ||
}; | ||
declare function getDropEvents(interaction: Interact.Interaction, _pointerEvent: any, dragEvent: any): { | ||
enter: any; | ||
@@ -65,3 +65,3 @@ leave: any; | ||
}; | ||
declare function fireDropEvents(interaction: any, events: any): void; | ||
declare function fireDropEvents(interaction: Interact.Interaction, events: any): void; | ||
declare const drop: { | ||
@@ -68,0 +68,0 @@ install: typeof install; |
@@ -10,7 +10,7 @@ import * as utils from '@interactjs/utils'; | ||
interactions, defaults, } = scope; | ||
interactions.signals.on('after-action-start', ({ interaction, event, iEvent: dragEvent }) => { | ||
interactions.signals.on('before-action-start', ({ interaction }) => { | ||
if (interaction.prepared.name !== 'drag') { | ||
return; | ||
} | ||
const dropStatus = interaction.dropStatus = interaction.dropStatus || { | ||
interaction.dropState = { | ||
cur: { | ||
@@ -28,12 +28,17 @@ dropzone: null, | ||
}; | ||
}); | ||
interactions.signals.on('after-action-start', ({ interaction, event, iEvent: dragEvent }) => { | ||
if (interaction.prepared.name !== 'drag') { | ||
return; | ||
} | ||
const { dropState } = interaction; | ||
// reset active dropzones | ||
dropStatus.activeDrops = null; | ||
dropStatus.events = null; | ||
// TODO: maybe Interaction<T: Window | Document | Element> { element: T } | ||
dropState.activeDrops = null; | ||
dropState.events = null; | ||
if (!scope.dynamicDrop) { | ||
dropStatus.activeDrops = getActiveDrops(scope, interaction.element); | ||
dropState.activeDrops = getActiveDrops(scope, interaction.element); | ||
} | ||
dropStatus.events = getDropEvents(interaction, event, dragEvent); | ||
if (dropStatus.events.activate) { | ||
fireActivationEvents(dropStatus.activeDrops, dropStatus.events.activate); | ||
dropState.events = getDropEvents(interaction, event, dragEvent); | ||
if (dropState.events.activate) { | ||
fireActivationEvents(dropState.activeDrops, dropState.events.activate); | ||
} | ||
@@ -48,18 +53,18 @@ }); | ||
} | ||
fireDropEvents(interaction, interaction.dropStatus.events); | ||
interaction.dropStatus.events = {}; | ||
fireDropEvents(interaction, interaction.dropState.events); | ||
interaction.dropState.events = {}; | ||
}); | ||
interactions.signals.on('after-action-end', ({ interaction }) => { | ||
if (interaction.prepared.name === 'drag') { | ||
fireDropEvents(interaction, interaction.dropStatus.events); | ||
fireDropEvents(interaction, interaction.dropState.events); | ||
} | ||
}); | ||
interactions.signals.on('stop', ({ interaction }) => { | ||
interaction.dropStatus.activeDrops = null; | ||
interaction.dropStatus.events = null; | ||
interaction.dropState.activeDrops = null; | ||
interaction.dropState.events = null; | ||
}); | ||
interactions.signals.on('stop', ({ interaction: { dropStatus } }) => { | ||
dropStatus.cur.dropzone = dropStatus.cur.element = | ||
dropStatus.prev.dropzone = dropStatus.prev.element = null; | ||
dropStatus.rejected = false; | ||
interactions.signals.on('stop', ({ interaction: { dropState } }) => { | ||
dropState.cur.dropzone = dropState.cur.element = | ||
dropState.prev.dropzone = dropState.prev.element = null; | ||
dropState.rejected = false; | ||
}); | ||
@@ -208,6 +213,6 @@ /** | ||
} | ||
function getDrop({ dropStatus, target: draggable, element: dragElement }, dragEvent, pointerEvent) { | ||
function getDrop({ dropState, interactable: draggable, element: dragElement }, dragEvent, pointerEvent) { | ||
const validDrops = []; | ||
// collect all dropzones and their elements which qualify for a drop | ||
for (const { dropzone, element: dropzoneElement, rect } of dropStatus.activeDrops) { | ||
for (const { dropzone, element: dropzoneElement, rect } of dropState.activeDrops) { | ||
validDrops.push(dropzone.dropCheck(dragEvent, pointerEvent, draggable, dragElement, dropzoneElement, rect) | ||
@@ -219,6 +224,6 @@ ? dropzoneElement | ||
const dropIndex = utils.dom.indexOfDeepestElement(validDrops); | ||
return dropStatus.activeDrops[dropIndex] || null; | ||
return dropState.activeDrops[dropIndex] || null; | ||
} | ||
function getDropEvents(interaction, _pointerEvent, dragEvent) { | ||
const { dropStatus } = interaction; | ||
const { dropState } = interaction; | ||
const dropEvents = { | ||
@@ -233,3 +238,3 @@ enter: null, | ||
if (dragEvent.type === 'dragstart') { | ||
dropEvents.activate = new DropEvent(dropStatus, dragEvent, 'dropactivate'); | ||
dropEvents.activate = new DropEvent(dropState, dragEvent, 'dropactivate'); | ||
dropEvents.activate.target = null; | ||
@@ -239,32 +244,32 @@ dropEvents.activate.dropzone = null; | ||
if (dragEvent.type === 'dragend') { | ||
dropEvents.deactivate = new DropEvent(dropStatus, dragEvent, 'dropdeactivate'); | ||
dropEvents.deactivate = new DropEvent(dropState, dragEvent, 'dropdeactivate'); | ||
dropEvents.deactivate.target = null; | ||
dropEvents.deactivate.dropzone = null; | ||
} | ||
if (dropStatus.rejected) { | ||
if (dropState.rejected) { | ||
return dropEvents; | ||
} | ||
if (dropStatus.cur.element !== dropStatus.prev.element) { | ||
if (dropState.cur.element !== dropState.prev.element) { | ||
// if there was a previous dropzone, create a dragleave event | ||
if (dropStatus.prev.dropzone) { | ||
dropEvents.leave = new DropEvent(dropStatus, dragEvent, 'dragleave'); | ||
dragEvent.dragLeave = dropEvents.leave.target = dropStatus.prev.element; | ||
dragEvent.prevDropzone = dropEvents.leave.dropzone = dropStatus.prev.dropzone; | ||
if (dropState.prev.dropzone) { | ||
dropEvents.leave = new DropEvent(dropState, dragEvent, 'dragleave'); | ||
dragEvent.dragLeave = dropEvents.leave.target = dropState.prev.element; | ||
dragEvent.prevDropzone = dropEvents.leave.dropzone = dropState.prev.dropzone; | ||
} | ||
// if dropzone is not null, create a dragenter event | ||
if (dropStatus.cur.dropzone) { | ||
dropEvents.enter = new DropEvent(dropStatus, dragEvent, 'dragenter'); | ||
dragEvent.dragEnter = dropStatus.cur.element; | ||
dragEvent.dropzone = dropStatus.cur.dropzone; | ||
if (dropState.cur.dropzone) { | ||
dropEvents.enter = new DropEvent(dropState, dragEvent, 'dragenter'); | ||
dragEvent.dragEnter = dropState.cur.element; | ||
dragEvent.dropzone = dropState.cur.dropzone; | ||
} | ||
} | ||
if (dragEvent.type === 'dragend' && dropStatus.cur.dropzone) { | ||
dropEvents.drop = new DropEvent(dropStatus, dragEvent, 'drop'); | ||
dragEvent.dropzone = dropStatus.cur.dropzone; | ||
dragEvent.relatedTarget = dropStatus.cur.element; | ||
if (dragEvent.type === 'dragend' && dropState.cur.dropzone) { | ||
dropEvents.drop = new DropEvent(dropState, dragEvent, 'drop'); | ||
dragEvent.dropzone = dropState.cur.dropzone; | ||
dragEvent.relatedTarget = dropState.cur.element; | ||
} | ||
if (dragEvent.type === 'dragmove' && dropStatus.cur.dropzone) { | ||
dropEvents.move = new DropEvent(dropStatus, dragEvent, 'dropmove'); | ||
if (dragEvent.type === 'dragmove' && dropState.cur.dropzone) { | ||
dropEvents.move = new DropEvent(dropState, dragEvent, 'dropmove'); | ||
dropEvents.move.dragmove = dragEvent; | ||
dragEvent.dropzone = dropStatus.cur.dropzone; | ||
dragEvent.dropzone = dropState.cur.dropzone; | ||
} | ||
@@ -274,4 +279,4 @@ return dropEvents; | ||
function fireDropEvents(interaction, events) { | ||
const { dropStatus } = interaction; | ||
const { activeDrops, cur, prev, } = dropStatus; | ||
const { dropState } = interaction; | ||
const { activeDrops, cur, prev, } = dropState; | ||
if (events.leave) { | ||
@@ -292,4 +297,4 @@ prev.dropzone.fire(events.leave); | ||
} | ||
dropStatus.prev.dropzone = cur.dropzone; | ||
dropStatus.prev.element = cur.element; | ||
dropState.prev.dropzone = cur.dropzone; | ||
dropState.prev.element = cur.element; | ||
} | ||
@@ -300,5 +305,5 @@ function onEventCreated({ interaction, iEvent, event }, scope) { | ||
} | ||
const { dropStatus } = interaction; | ||
const { dropState } = interaction; | ||
if (scope.dynamicDrop) { | ||
dropStatus.activeDrops = getActiveDrops(scope, interaction.element); | ||
dropState.activeDrops = getActiveDrops(scope, interaction.element); | ||
} | ||
@@ -308,9 +313,9 @@ const dragEvent = iEvent; | ||
// update rejected status | ||
dropStatus.rejected = dropStatus.rejected && | ||
dropState.rejected = dropState.rejected && | ||
!!dropResult && | ||
dropResult.dropzone === dropStatus.cur.dropzone && | ||
dropResult.element === dropStatus.cur.element; | ||
dropStatus.cur.dropzone = dropResult && dropResult.dropzone; | ||
dropStatus.cur.element = dropResult && dropResult.element; | ||
dropStatus.events = getDropEvents(interaction, event, dragEvent); | ||
dropResult.dropzone === dropState.cur.dropzone && | ||
dropResult.element === dropState.cur.element; | ||
dropState.cur.dropzone = dropResult && dropResult.dropzone; | ||
dropState.cur.element = dropResult && dropResult.element; | ||
dropState.events = getDropEvents(interaction, event, dragEvent); | ||
} | ||
@@ -423,2 +428,2 @@ function dropzoneMethod(interactable, options) { | ||
export default drop; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFHQSxPQUFPLEtBQUssS0FBSyxNQUFNLG1CQUFtQixDQUFBO0FBQzFDLE9BQU8sU0FBUyxNQUFNLGFBQWEsQ0FBQTtBQTBEbkMsU0FBUyxPQUFPLENBQUUsS0FBWTtJQUM1QixNQUFNLEVBQ0osT0FBTztJQUNQLDZCQUE2QjtJQUM3QixRQUFRO0lBQ1IsMEJBQTBCO0lBQzFCLFlBQVksRUFBRSxnQ0FBZ0M7SUFDOUMsWUFBWSxFQUNaLFFBQVEsR0FDVCxHQUFHLEtBQUssQ0FBQTtJQUVULFlBQVksQ0FBQyxPQU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vYmplY3QgfCBudWxsfSBbb3B0aW9uc10gVGhlIG5ldyBvcHRpb25zIHRvIGJlIHNldC5cbiAgICogQHJldHVybiB7Ym9vbGVhbiB8IEludGVyYWN0YWJsZX0gVGhlIGN1cnJlbnQgc2V0dGluZyBvciB0aGlzIEludGVyYWN0YWJsZVxuICAgKi9cbiAgSW50ZXJhY3RhYmxlLnByb3RvdHlwZS5kcm9wem9uZSA9IGZ1bmN0aW9uICh0aGlzOiBJbnRlcmFjdC5JbnRlcmFjdGFibGUsIG9wdGlvbnMpIHtcbiAgICByZXR1cm4gZHJvcHpvbmVNZXRob2QodGhpcywgb3B0aW9ucylcbiAgfVxuXG4gIC8qKlxuICAgKiBgYGBqc1xuICAgKiBpbnRlcmFjdCh0YXJnZXQpXG4gICAqIC5kcm9wQ2hlY2tlcihmdW5jdGlvbihkcmFnRXZlbnQsICAgICAgICAgLy8gcmVsYXRlZCBkcmFnbW92ZSBvciBkcmFnZW5kIGV2ZW50XG4gICAqICAgICAgICAgICAgICAgICAgICAgICBldmVudCwgICAgICAgICAgICAgLy8gVG91Y2hFdmVudC9Qb2ludGVyRXZlbnQvTW91c2VFdmVudFxuICAgKiAgICAgICAgICAgICAgICAgICAgICAgZHJvcHBlZCwgICAgICAgICAgIC8vIGJvb2wgcmVzdWx0IG9mIHRoZSBkZWZhdWx0IGNoZWNrZXJcbiAgICogICAgICAgICAgICAgICAgICAgICAgIGRyb3B6b25lLCAgICAgICAgICAvLyBkcm9wem9uZSBJbnRlcmFjdGFibGVcbiAgICogICAgICAgICAgICAgICAgICAgICAgIGRyb3BFbGVtZW50LCAgICAgICAvLyBkcm9wem9uZSBlbGVtbnRcbiAgICogICAgICAgICAgICAgICAgICAgICAgIGRyYWdnYWJsZSwgICAgICAgICAvLyBkcmFnZ2FibGUgSW50ZXJhY3RhYmxlXG4gICAqICAgICAgICAgICAgICAgICAgICAgICBkcmFnZ2FibGVFbGVtZW50KSB7Ly8gZHJhZ2dhYmxlIGVsZW1lbnRc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ZWQgPSBvdmVybGFwUmF0aW8gPj0gZHJvcE92ZXJsYXBcbiAgfVxuXG4gIGlmIChpbnRlcmFjdGFibGUub3B0aW9ucy5kcm9wLmNoZWNrZXIpIHtcbiAgICBkcm9wcGVkID0gaW50ZXJhY3RhYmxlLm9wdGlvbnMuZHJvcC5jaGVja2VyKGRyYWdFdmVudCwgZXZlbnQsIGRyb3BwZWQsIGludGVyYWN0YWJsZSwgZHJvcEVsZW1lbnQsIGRyYWdnYWJsZSwgZHJhZ2dhYmxlRWxlbWVudClcbiAgfVxuXG4gIHJldHVybiBkcm9wcGVkXG59XG5cbmNvbnN0IGRyb3AgPSB7XG4gIGluc3RhbGwsXG4gIGdldEFjdGl2ZURyb3BzLFxuICBnZXREcm9wLFxuICBnZXREcm9wRXZlbnRzLFxuICBmaXJlRHJvcEV2ZW50cyxcbiAgZGVmYXVsdHM6IHtcbiAgICBlbmFibGVkOiBmYWxzZSxcbiAgICBhY2NlcHQgOiBudWxsLFxuICAgIG92ZXJsYXA6ICdwb2ludGVyJyxcbiAgfSBhcyBJbnRlcmFjdC5Ecm9wem9uZU9wdGlvbnMsXG59XG5cbmV4cG9ydCBkZWZhdWx0IGRyb3BcbiJdfQ== |
@@ -6,7 +6,7 @@ import { ActionName, Scope } from '@interactjs/core/scope'; | ||
gesture?: { | ||
angle: number; | ||
distance: number; | ||
scale: number; | ||
startAngle: number; | ||
startDistance: number; | ||
prevScale: number; | ||
prevAngle: number; | ||
prevDistance: number; | ||
}; | ||
@@ -13,0 +13,0 @@ } |
@@ -46,13 +46,9 @@ import InteractEvent from '@interactjs/core/InteractEvent'; | ||
interactions.signals.on('action-end', updateGestureProps); | ||
interactions.signals.on('action-start', start); | ||
interactions.signals.on('action-move', move); | ||
interactions.signals.on('new', (interaction) => { | ||
interactions.signals.on('new', ({ interaction }) => { | ||
interaction.gesture = { | ||
start: { x: 0, y: 0 }, | ||
startDistance: 0, | ||
prevDistance: 0, | ||
angle: 0, | ||
distance: 0, | ||
scale: 1, | ||
startAngle: 0, | ||
prevAngle: 0, | ||
startDistance: 0, | ||
}; | ||
@@ -83,26 +79,2 @@ }); | ||
}; | ||
function start({ iEvent, interaction }) { | ||
if (interaction.prepared.name !== 'gesture') { | ||
return; | ||
} | ||
iEvent.ds = 0; | ||
interaction.gesture.startDistance = interaction.gesture.prevDistance = iEvent.distance; | ||
interaction.gesture.startAngle = interaction.gesture.prevAngle = iEvent.angle; | ||
interaction.gesture.scale = 1; | ||
} | ||
function move({ iEvent, interaction }) { | ||
if (interaction.prepared.name !== 'gesture') { | ||
return; | ||
} | ||
iEvent.ds = iEvent.scale - interaction.gesture.scale; | ||
interaction.target.fire(iEvent); | ||
interaction.gesture.prevAngle = iEvent.angle; | ||
interaction.gesture.prevDistance = iEvent.distance; | ||
if (iEvent.scale !== Infinity && | ||
iEvent.scale !== null && | ||
iEvent.scale !== undefined && | ||
!isNaN(iEvent.scale)) { | ||
interaction.gesture.scale = iEvent.scale; | ||
} | ||
} | ||
function updateGestureProps({ interaction, iEvent, event, phase }) { | ||
@@ -115,3 +87,3 @@ if (interaction.prepared.name !== 'gesture') { | ||
const ending = phase === 'end'; | ||
const deltaSource = interaction.target.options.deltaSource; | ||
const deltaSource = interaction.interactable.options.deltaSource; | ||
iEvent.touches = [pointers[0], pointers[1]]; | ||
@@ -125,2 +97,4 @@ if (starting) { | ||
iEvent.da = 0; | ||
interaction.gesture.startDistance = iEvent.distance; | ||
interaction.gesture.startAngle = iEvent.angle; | ||
} | ||
@@ -132,5 +106,5 @@ else if (ending || event instanceof InteractEvent) { | ||
iEvent.scale = prevEvent.scale; | ||
iEvent.ds = iEvent.scale - 1; | ||
iEvent.ds = 0; | ||
iEvent.angle = prevEvent.angle; | ||
iEvent.da = iEvent.angle - interaction.gesture.startAngle; | ||
iEvent.da = 0; | ||
} | ||
@@ -142,7 +116,15 @@ else { | ||
iEvent.angle = utils.pointer.touchAngle(pointers, deltaSource); | ||
iEvent.ds = iEvent.scale - interaction.gesture.prevScale; | ||
iEvent.da = iEvent.angle - interaction.gesture.prevAngle; | ||
iEvent.ds = iEvent.scale - interaction.gesture.scale; | ||
iEvent.da = iEvent.angle - interaction.gesture.angle; | ||
} | ||
interaction.gesture.distance = iEvent.distance; | ||
interaction.gesture.angle = iEvent.angle; | ||
interaction.gesture.scale = iEvent.scale; | ||
if (utils.is.number(iEvent.scale) && | ||
iEvent.scale !== Infinity && | ||
!isNaN(iEvent.scale)) { | ||
interaction.gesture.scale = iEvent.scale; | ||
} | ||
} | ||
export default gesture; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2VzdHVyZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImdlc3R1cmUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxhQUFhLE1BQU0sZ0NBQWdDLENBQUE7QUFDMUQsT0FBTyxFQUFFLFVBQVUsRUFBUyxNQUFNLHdCQUF3QixDQUFBO0FBQzFELE9BQU8sS0FBSyxLQUFLLE1BQU0sbUJBQW1CLENBQUE7QUF1Q3pDLFVBQWtCLENBQUMsT0FBTyxHQUFHLFNBQVMsQ0FBQTtBQWtCdkMsU0FBUyxPQUFPLENBQUUsS0FBWTtJQUM1QixNQUFNLEVBQ0osT0FBTyxFQUNQLFlBQVksRUFDWixZQUFZLEVBQ1osUUFBUSxHQUNULEdBQUcsS0FBSyxDQUFBO0lBRVQ7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7T0FzQkc7SUFDSCxZQUFZLENBQUMsU0FBUyxDQUFDLFVBQVUsR0FBRyxVQUF1QyxPQUE2QztRQUN0SCxJQUFJLEtBQUssQ0FBQyxFQUFFLENBQUMsTUFBTSxDQUFDLE9BQU8sQ0FBQyxFQUFFO1lBQzVCLElBQUksQ0FBQyxPQUFPLENBQUMsT0FBTyxDQUFDLE9BQU8sR0FBRyxPQUFPLENBQUMsT0FBTyxLQUFLLEtBQUss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scy5wb2ludGVyLnRvdWNoQW5nbGUocG9pbnRlcnMsIGRlbHRhU291cmNlKVxuXG4gICAgaUV2ZW50LmRzID0gaUV2ZW50LnNjYWxlIC0gaW50ZXJhY3Rpb24uZ2VzdHVyZS5zY2FsZVxuICAgIGlFdmVudC5kYSA9IGlFdmVudC5hbmdsZSAtIGludGVyYWN0aW9uLmdlc3R1cmUuYW5nbGVcbiAgfVxuXG4gIGludGVyYWN0aW9uLmdlc3R1cmUuZGlzdGFuY2UgPSBpRXZlbnQuZGlzdGFuY2VcbiAgaW50ZXJhY3Rpb24uZ2VzdHVyZS5hbmdsZSA9IGlFdmVudC5hbmdsZVxuICBpbnRlcmFjdGlvbi5nZXN0dXJlLnNjYWxlID0gaUV2ZW50LnNjYWxlXG5cbiAgaWYgKHV0aWxzLmlzLm51bWJlcihpRXZlbnQuc2NhbGUpICYmXG4gICAgICBpRXZlbnQuc2NhbGUgIT09IEluZmluaXR5ICYmXG4gICAgICAhaXNOYU4oaUV2ZW50LnNjYWxlKSkge1xuICAgIGludGVyYWN0aW9uLmdlc3R1cmUuc2NhbGUgPSBpRXZlbnQuc2NhbGVcbiAgfVxufVxuXG5leHBvcnQgZGVmYXVsdCBnZXN0dXJlXG4iXX0= |
{ | ||
"name": "@interactjs/actions", | ||
"version": "1.4.0-alpha.28+sha.e624c4d", | ||
"version": "1.4.0-alpha.29+sha.7c21d3d", | ||
"peerDependencies": { | ||
"@interactjs/core": "1.4.0-alpha.28+sha.e624c4d", | ||
"@interactjs/utils": "1.4.0-alpha.28+sha.e624c4d" | ||
"@interactjs/core": "1.4.0-alpha.29+sha.7c21d3d", | ||
"@interactjs/utils": "1.4.0-alpha.29+sha.7c21d3d" | ||
}, | ||
"devDependencies": { | ||
"@interactjs/_dev": "1.4.0-alpha.28+sha.e624c4d", | ||
"@interactjs/core": "1.4.0-alpha.28+sha.e624c4d", | ||
"@interactjs/utils": "1.4.0-alpha.28+sha.e624c4d" | ||
"@interactjs/_dev": "1.4.0-alpha.29+sha.7c21d3d", | ||
"@interactjs/core": "1.4.0-alpha.29+sha.7c21d3d", | ||
"@interactjs/utils": "1.4.0-alpha.29+sha.7c21d3d" | ||
}, | ||
@@ -13,0 +13,0 @@ "publishConfig": { |
@@ -261,4 +261,4 @@ import { ActionName } from '@interactjs/core/scope'; | ||
} | ||
const startRect = interaction.target.getRect(interaction.element); | ||
const resizeOptions = interaction.target.options.resize; | ||
const startRect = interaction.interactable.getRect(interaction.element); | ||
const resizeOptions = interaction.interactable.options.resize; | ||
/* | ||
@@ -306,3 +306,3 @@ * When using the `resizable.square` or `resizable.preserveAspectRatio` options, resizing from one edge | ||
} | ||
const resizeOptions = interaction.target.options.resize; | ||
const resizeOptions = interaction.interactable.options.resize; | ||
const invert = resizeOptions.invert; | ||
@@ -387,3 +387,3 @@ const invertible = invert === 'reposition' || invert === 'negate'; | ||
} | ||
const options = interaction.target.options; | ||
const options = interaction.interactable.options; | ||
if (options.resize.square) { | ||
@@ -409,2 +409,2 @@ if (interaction.resizeAxes === 'y') { | ||
export default resize; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzaXplLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsicmVzaXplLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUNBLE9BQU8sRUFBRSxVQUFVLEVBQVMsTUFBTSx3QkFBd0IsQ0FBQTtBQUMxRCxPQUFPLEtBQUssS0FBSyxNQUFNLG1CQUFtQixDQUFBO0FBK0N6QyxVQUFrQixDQUFDLE1BQU0sR0FBRyxRQUFRLENBQUE7QUFPckMsU0FBUyxPQUFPLENBQUUsS0FBWTtJQUM1QixNQUFNLEVBQ0osT0FBTyxFQUNQLE9BQU87SUFDUCwwQkFBMEI7SUFDMUIsWUFBWSxFQUFFLDJDQUEyQztJQUN6RCxZQUFZLEVBQ1osUUFBUSxHQUNULEdBQUcsS0FBSyxDQUFBO0lBRVQsa0NBQWtD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YWN0aW9uICE9PSAncmVzaXplJyB8fCAhaW50ZXJhY3Rpb24ucmVzaXplQXhlcykgeyByZXR1cm4gfVxuXG4gIGNvbnN0IG9wdGlvbnMgPSBpbnRlcmFjdGlvbi5pbnRlcmFjdGFibGUub3B0aW9uc1xuXG4gIGlmIChvcHRpb25zLnJlc2l6ZS5zcXVhcmUpIHtcbiAgICBpZiAoaW50ZXJhY3Rpb24ucmVzaXplQXhlcyA9PT0gJ3knKSB7XG4gICAgICBpRXZlbnQuZGVsdGEueCA9IGlFdmVudC5kZWx0YS55XG4gICAgfVxuICAgIGVsc2Uge1xuICAgICAgaUV2ZW50LmRlbHRhLnkgPSBpRXZlbnQuZGVsdGEueFxuICAgIH1cbiAgICBpRXZlbnQuYXhlcyA9ICd4eSdcbiAgfVxuICBlbHNlIHtcbiAgICBpRXZlbnQuYXhlcyA9IGludGVyYWN0aW9uLnJlc2l6ZUF4ZXNcblxuICAgIGlmIChpbnRlcmFjdGlvbi5yZXNpemVBeGVzID09PSAneCcpIHtcbiAgICAgIGlFdmVudC5kZWx0YS55ID0gMFxuICAgIH1cbiAgICBlbHNlIGlmIChpbnRlcmFjdGlvbi5yZXNpemVBeGVzID09PSAneScpIHtcbiAgICAgIGlFdmVudC5kZWx0YS54ID0gMFxuICAgIH1cbiAgfVxufVxuXG5leHBvcnQgZGVmYXVsdCByZXNpemVcbiJdfQ== |
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
234142
24
1703