CSS Gird布局教程指南

2020-04-27 07:13:15易采站长站整理

}

 


.item-a {
justify-self: stretch;
}

 align-self

沿列轴对齐网格内的内容,此值适用与单个网格项目内的内容 值

start: 将内容对齐到网格空间的顶部

end: 将内容对齐到网格空间的底部

center: 将网格空间中心的内容对齐

stretch: 填充网格空间的整个高度


.item {
align-self: start | end | center | stretch;
}

例子:


.item-a {
align-self: start;
}

 


.item-a {
align-self: end;
}


.item-a {
align-self: center;
}


.item-a {
align-self: stretch;
}