vue-draggable-resizable icon indicating copy to clipboard operation
vue-draggable-resizable copied to clipboard

float point element size

Open z4none opened this issue 6 years ago • 2 comments

version: 2.0.0-rc1

When element size (prop w and h) is float point number, update prop w and h won't change the size of element.

The calculation for RAW value was skipped by this mod

image

z4none avatar Jan 23 '19 12:01 z4none

I ran into this as well, are you using a custom grid size? If not it defaults to [1,1] (1 pixel) which means any non-integer pixel value is going to automatically fail that check. The solution I'm using at the moment is making sure I round values before passing them in.

baybars1223 avatar Jan 30 '19 16:01 baybars1223

I use default grid size, but the element I need to resize has a float point size, which is computed somewhere else. Currently my solution is using Math.round(delta) too.

z4none avatar Jan 31 '19 12:01 z4none