Can grid-row-gap / grip-column-gap be overridden for a single gutter?

后端 未结 1 1505
终归单人心
终归单人心 2021-01-01 12:21

Is there a way to set a single grid-row-gap to specific size that is different from the rest of the grid?

Use case: the top row of the grid should have

相关标签:
1条回答
  • 2021-01-01 12:46

    The grid-row-gap and grid-column-gap properties apply to the entire grid (spec reference).

    However, you can use negative margins on the second row grid items to adjust their position.

    Another option would be to remove the top row (headers) from the current grid and place it in a different container directly above the data. This would eliminate the grid-gap problem.

    0 讨论(0)
提交回复
热议问题