Вопрос

I'm using gridster to create dynamic grids with 5 pixel margin space between widgets.
but it creates 10 pixel margins! (see this)
actually it adds margin for both neighbor widgets (left & right widgets)
How can i make gridster to collapse margins so the gap between two neighbor widgets be 5 pixel?

Thanks

Это было полезно?

Решение

http://jsfiddle.net/fresheyeball/d6BWD/

  gridster = $(".gridster > ul").gridster({
      widget_margins: [2.5, 2.5],
      widget_base_dimensions: [100, 100]
  }).data('gridster');

5 + 5 = 10

2.5 + 2.5 = 5

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top