CSS Grid 生成器

Grid参考

属性示例描述
grid-template-columnsrepeat(3, 1fr)定义列轨道
grid-template-rows100px auto定义行轨道
grid-column1 / 3元素跨越第1到3列
grid-row2 / 4元素跨越第2到4行
grid-areaheader命名网格区域定位
minmax()minmax(200px, 1fr)轨道尺寸范围
auto-fillrepeat(auto-fill, 200px)尽可能填充轨道
auto-fitrepeat(auto-fit, minmax(200px, 1fr))折叠空轨道