jquery-resizable icon indicating copy to clipboard operation
jquery-resizable copied to clipboard

`destroy()` should also reset `width` and `height`

Open av01d opened this issue 1 year ago • 0 comments

When calling destroy on an instance, the css width and height values remain. They should be removed. Fix is this: change

$handle = getHandle(opt.handleSelector, $el);
$handle.off("mousedown." + opt.instanceId + " touchstart." + opt.instanceId);
if (opt.touchActionNone)
   $handle.css("touch-action", "");
$el.removeClass("resizable");
return;

to this

$handle = getHandle(opt.handleSelector, $el);
$handle.off("mousedown." + opt.instanceId + " touchstart." + opt.instanceId);
if (opt.touchActionNone)
   $handle.css("touch-action", "");
$el.removeClass("resizable");
$el.css({width:'', height:''});
return;

av01d avatar May 28 '24 12:05 av01d