taye / interact.js

JavaScript drag and drop, resizing and multi-touch gestures with inertia and snapping for modern browsers (and also IE9+)

Home Page:http://interactjs.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Resize modifier - wrong types

brano-hozza opened this issue · comments

If you have questions about the API that aren't answered in the docs or FAQ, try asking in the Gitter chatroom or on Stackoverflow.

If you've found something that looks like a bug, include a link to a minimal demo on JSFilddle, Codepen with instructions to reproduce the bug with and roughly follow the following issue description format:

Expected behavior

In interact.modifiers.restrictSize RestrictSizeOptions properties min and max should also take Size type where I do not need to specify one of the properties, because I don't want to restrict them.

Actual behavior

Can't set this to null or undefined
image

System configuration

interact.js version: 1.10.26
Browser name and version: Chrome Version 120.0.6099.71 (Official Build) (64-bit)
Operating System: Windows 11

commented

You can use 0 or -Infinity for the min and Infinity for the max