2021年9月28日

flex子项属性使用(flex/align-self)

摘要: flex`属性定义子项分配剩余空间,用flex来表示占多少份数。 .item { flex:<number>; /* default0 默认0 */ } section { display: flex; width: 60%; height: 150px; background-color: pin 阅读全文

posted @ 2021-09-28 19:23 tallish 阅读(253) 评论(0) 推荐(0)

flex布局(flex-warp 设置子元素是否换行 align-items设置侧轴上的子元素排列方式(单行) align-content(多行)flex-flow是flex-direction和flex-wrap的复合写法)

摘要: flex-wrap`设置子元素是否换行 ​ nowrap默认不换行,如果撞不开缩小子元素宽度。 ​ wrap换行 div { display: flex; /* 默认不换行 */ flex-wrap: nowrap; /* 换行 */ flex-wrap: wrap; width: 500px; h 阅读全文

posted @ 2021-09-28 17:43 tallish 阅读(1832) 评论(0) 推荐(0)

导航