CSS参考手册
多列布局 | Multi-column Layout
列跨度 | column-span
该column-span
CSS特性使得我们可以为元素在所有列时,其值设置为跨越all
。跨越多个列的元素称为生成元素。
/* Keyword values */
column-span: none;
column-span: all;
/* Global values */
column-span: inherit;
column-span: initial;
column-span: unset;
初始值 |
没有 |
---|---|
适用于 |
流入块级元素 |
遗传 |
没有 |
媒体 |
visual |
计算值 |
作为指定 |
动画类型 |
离散的 |
规范的顺序 |
逐个语法 |
语法
值
none
该元素不跨越多个列。
all
元素横跨所有列。元素出现之前,出现在元素之前的正常流中的内容在所有列之间自动平衡。该元素建立一个新的块格式上下文。
形式语法
none | all
实例
h1, h2 {
column-span: all;
}
规范
Specification |
Status |
Comment |
---|---|---|
CSS Multi-column Layout ModuleThe definition of 'column-width' in that specification. |
Candidate Recommendation |
Initial definition |
浏览器兼容性
Feature |
Chrome |
Edge |
Firefox (Gecko) |
Internet Explorer |
Opera |
Safari (WebKit) |
---|---|---|---|---|---|---|
Basic support |
(Yes)-webkit 50.0 |
(Yes)-webkit (Yes) |
No support1 |
10 |
11.10 |
(Yes) -webkit |
Feature |
Android |
Android Webview |
Edge |
Firefox Mobile (Gecko) |
IE Mobile |
Opera Mobile |
Safari Mobile |
Chrome for Android |
---|---|---|---|---|---|---|---|---|
Basic support |
(Yes)-webkit |
? 50.0 |
(Yes)-webkit (Yes) |
No support1 |
? |
11.10 |
(Yes)-webkit |
(Yes)-webkit 50.0 |
多列布局 | Multi-column Layout相关
层叠样式表( Cascading Style Sheets )是一种用来表现 HTML 或 XML 等文件样式的计算机语言。CSS 不仅可以静态地修饰网页,还可以配合各种脚本语言动态地对网页各元素进行格式化。