Centre aligned grid?

I presume it would be a monster of a thing to code, but I would love to see a centre aligned grid.
For example, on desktop -

  • a 4 cell grid set to display 3 to a row would have cell 4 appear below cells 2
  • a 5 cell grid set to display three to a row would have the centre of cells 4 and 5 aligned with the gutter between the cells above

I know I can achieve this look with Columns and playing around with offsets but having Grid do it automatically would be neat.

I don’t think Foundry Grid has any align options, but maybe someone knows of a Grid stack which does.
Thanks

Hi @Phloque – Hope your weekend is going well.

This isn’t quite as easy as it might sound on the surface. The grid uses inline floated elements, which aren’t geared toward being centered.

It is something to think about for the future, but might be better suited for a grid-like stack based around flexbox instead.

Thanks Adam appreciate the feedback

No problem. I’ve got a bunch of updates in the works. Some more longterm than others. I will note this as something to look at though. Like I said, it might mean a different stack altogether, but we’ll see.

2 Likes

I am using the Foundry grid very often. To center align on desktop breakpoints I am adding left margins as a workaround, not ideal; but would also appreciate the option to center align the grid. Thanks @elixirgraphics.