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

add_widget doesn't call add_faux_rows with the right argument #293

Open msvanvertloo opened 10 years ago

msvanvertloo commented 10 years ago

add_widget calls add_faux_rows(pos.size_y). pos.size_y is always undefined if the row and/or column for the new widget are specified. This causes the stylesheet to only increase by one row. When adding widgets to (1,1) that are bigger than 1 grid space, eventually, the generated stylesheet doesn't have a row entry for the tiles that get moved down, so they appear at "top: 0".