interact.js
interact.js copied to clipboard
Are inertia options available on the draggable() method?
Looking at the inertia docs here: https://interactjs.io/docs/inertia/
Was hoping I'd be able to customize the throw distance of the inertia feature but doing this doesn't seem to work:
interact(".draggable").draggable({
inertia: {
enabled: true,
resistance: 30,
minSpeed: 200,
endSpeed: 100
},
modifiers: [
interact.modifiers.restrictRect({
restriction: "parent",
endOnly: true,
}),
],
autoScroll: true,
listeners: {
move: dragMoveListener,
end(event) {},
},
});
It just breaks the inertia. Are the options only available for resizable
?
They're available for draggable
as well. Those values work for me. Can you make a demo on jsfiddle.net/?