Hello I'm using react-grid-layout, and having some trouble on achieving this :
==================================
|| || ||
|| xxxxxxx || xxxxxxx ||
|| x x || x x ||
|| x A x || x B x ||
|| x x || x x ||
|| xxxxxxx || xxxxxxx ||
|| || ||
==================================
When I drag A to B, I want switch B's position to A.
what I want to happened:
==================================
|| || ||
|| xxxxxxx || xxxxxxx ||
|| x x || x x ||
|| x B x || x A x ||
|| x x || x x ||
|| xxxxxxx || xxxxxxx ||
|| || ||
==================================
what actually happened:
==================================
|| || ||
|| || xxxxxxx ||
|| || x x ||
|| || x A x ||
|| || x x ||
|| || xxxxxxx ||
|| || ||
|| || ||
|| || xxxxxxx ||
|| || x x ||
|| || x B x ||
|| || x x ||
|| || xxxxxxx ||
|| || ||
==================================
I don't want the container to expand more than 1 grid's h.
Is there a way to limit its height?
I think by adding height or maxHeight props will help a lot.
Thankyou
I'm having the same issue. I did try the autoSize property:
// If true, the container height swells and contracts to fit contents
autoSize: ?boolean = true,
and setting it to false does keep the containing element from expanding and collapsing but it doesn鈥檛 prevent the items from infinitely stacking and falling off the screen
it would be great!, if there was a property of the maxHeight or height
I'd also find this extremely useful!
i set autoSize to false but i found it dosn't work like it thought,i just didn't want the container box change when resizing the item.
You can maxRows to config ReactGridLayout
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this issue will be closed in 7 days
Most helpful comment
it would be great!, if there was a property of the maxHeight or height