弹性布局常用属性

2022-09-13 19:15:04
flex-direction:row //左起排序 flex-direction:row-reverse //右起排序 flex-direction:column //上起排序 flex-direction:column-reverse //下起排序 justify-content:flex-start //左对齐 justify-content:flex-end //右对齐 justify-content:center //居中 justify-content:space-between //两端对齐 justify-content:space-around //每个项目两侧的间隔相等 align-items:flex-start //顶点对齐 align-items:flex-end //底部对齐 align-items:center //中线对齐 align-items:baseline //文本对齐 align-items:stretch //默认,无高度则占满 flex-wrap:nowrap //不换行 flex-wrap:wrap //换行 flex-wrap:wrap-reverse //换行,第一行在下方