ducksboard / gridster.js

gridster.js is a jQuery plugin that makes building intuitive draggable layouts from elements spanning multiple columns
http://gridster.net/
MIT License
6.03k stars 1.2k forks source link

widget_resize widget which has no free space to his right, and grid width is constant #391

Open Kamilius opened 10 years ago

Kamilius commented 10 years ago

Hi. I have 4 column gridster grid with two elements - 2 columns width each. When I try to resize left widget with "widget_resize", it's resizing successfully and pushing right widget to next row, if it needs to occupy right widget's space when resizing. Assumed that right widget will also change it's row OR will occupy the space of left widget if needed to resize, but it's not doing either of those two variants. When I try to resize right widget to occupy bigger space(not two, but three or four columns), than it is occupying now, and there is no space to it's right (edge of grid) - simply nothing happens. But if there is one more free column it resizes to max of current width + this column (so if left column is 1 column, right will have max of 3, even if you try to pass 4 column size to it). Any clue on this?

For some reason I can't get gridster normally work on JSFiddle to show working example, but I can if somebody has working gridster base on any of sandboxes.

Update: Managed to do a JSFiddle example - http://jsfiddle.net/Yc476/2/. Just try to resize right column when it has and has no free space to it's right. Seems like only widgets with free space to the right can be resized.

jianghai commented 10 years ago

http://gridster.net/demos/dynamic-grid-width.html

Kamilius commented 10 years ago

jinghai, read that, but the thing is - I need constant grid width, in my case restricted to 4 columns