daybrush / moveable

Moveable! Draggable! Resizable! Scalable! Rotatable! Warpable! Pinchable! Groupable! Snappable!
https://daybrush.com/moveable/
MIT License
10.08k stars 618 forks source link

Can't resize an element that had `min-height`. #256

Closed idanen closed 4 years ago

idanen commented 4 years ago

Environments

Description

When an element initially has min-height set, the resize event won't fire even when removing the min-height in the resizeStart event. This worked in versions prior to 0.17.0

daybrush commented 4 years ago

@idanen This happens because minSize and maxSize are checked just before resizeStart.

I'll consider adding this feature.

idanen commented 4 years ago

Can it be checked after? And only once probably? This check didn't exist in previous versions, right?

daybrush commented 4 years ago

@idanen

There is no way yet. I started checking at 0.17.5. https://github.com/daybrush/moveable/releases/tag/0.17.5

daybrush commented 4 years ago

@idanen

moveable's new version is released.

https://daybrush.com/moveable/release/latest/doc/Moveable.Resizable.html#.OnResizeStart

you can use setMin, setMax.

idanen commented 4 years ago

Awesome! Thanks