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.04k stars 1.2k forks source link

Keep the rows in their positions using Gridster #526

Open nunon opened 8 years ago

nunon commented 8 years ago

This is my HTML, being converted into a grid using Gridster.

I want each of the li in its respective row and column without changing.

  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Objetivo 2
  • Objetivo 3
  • Objetivo 4
  • Objetivo 5
  • Objetivo 6
  • Objetivo 7
  • Objetivo 8
  • Objetivo 9
  • Objetivo 10
  • Objetivo 11
  • Objetivo 12

So I'm using:

var gridster = $('.gridster ul').gridster({ widget_base_dimensions: [100,100], widget_margins: [10, 20]
}).data('gridster');

gridster.disable(); And the list above becomes:

  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Text
  • Objetivo 2
  • Objetivo 3
  • Objetivo 4
  • Objetivo 5
  • Objetivo 6
  • Objetivo 7
  • Objetivo 8
  • Objetivo 9
  • Objetivo 10
  • Objetivo 11
  • Objetivo 12

Why are the rows positions changing dinamically after the script is run and how can I force them into their positions?