0

I have setup a grid with a right and left column:

.grid-container {
  display: grid;
  grid-gap: 16px;
  grid-template-columns: 2fr 1fr;
  grid-template-areas: "left right";
  grid-auto-flow: column;
}

.left-item {
  grid-column: left;
}
.right-item {
  grid-column: right;
}

grid

And I am wondering how do you make the items fill up the blank vertical space.

I am using CSS grid and not two separate divs because I need to do this only on desktop, on mobile the order of the items is different.

I have setup a basic codepen: you can see the breakpoint by dragging the window:

https://codepen.io/marco_fugaro/pen/eYPexYg?editors=1100

Pontiacks
  • 1,118
  • 2
  • 13
  • 23

0 Answers0