CSS 速查表
逛逛主站
浏览器版本
不限
IE11
IE10
IE9
IE8
IE7
IE6
无效样式
删除线
隐藏
移除
元素选择符
Element Selectors
*
E
#id
.class
.class.class
关系选择符
Relationship Selectors
E F
E > F
E + F
E ~ F
属性选择符
Attribute Selectors
[att]
[att="val"]
[att^="val"]
[att$="val"]
[att*="val"]
[att~="val"]
[att|="val"]
伪对象选择符
Pseudo-Element Selectors
:first-letter
::first-letter
:first-line
::first-line
:before
::before
:after
::after
::selection
伪类选择符
Pseudo-Classes Selectors
:link
:visited
:hover
:active
:focus
:lang()
:not()
:root
:first-child
:last-child
:only-child
:nth-child(n)
:nth-last-child(n)
:first-of-type
:last-of-type
:only-of-type
:nth-of-type(n)
:nth-last-of-type(n)
:empty
:checked
:enabled
:disabled
:target
@page:first
@page:left
@page:right
布局
Layout
clear
display
float
overflow
overflow-x
overflow-y
visibility
定位
Positioning
position
top
right
bottom
left
z-index
clip
伸缩盒(新)
Flexible Box
flex
flex-grow
flex-shrink
flex-basis
flex-flow
flex-direction
flex-wrap
align-content
align-items
align-self
justify-content
order
伸缩盒(旧)
Flexible Box
box-orient
box-pack
box-align
box-flex
box-flex-group
box-ordinal-group
box-direction
box-lines
多列
Multi-column
columns
column-width
column-count
column-gap
column-rule
column-rule-width
column-rule-style
column-rule-color
column-span
column-fill
column-break-before
column-break-after
column-break-inside
尺寸
Dimension
width
min-width
max-width
height
min-height
max-height
外边距
Margin
margin
margin-top
margin-right
margin-bottom
margin-left
内边距
Padding
padding
padding-top
padding-right
padding-bottom
padding-left
边框
Border
border
border-width
border-style
border-color
border-top
border-top-width
border-top-style
border-top-color
border-right
border-right-width
border-right-style
border-right-color
border-bottom
border-bottom-width
border-bottom-style
border-bottom-color
border-left
border-left-width
border-left-style
border-left-color
border-radius
border-top-left-radius
border-top-right-radius
border-bottom-right-radius
border-bottom-left-radius
border-shadow
border-image
border-image-source
border-image-slice
border-image-width
border-image-outset
border-image-repeat
背景
Background
background
background-color
background-image
background-repeat
background-attachment
background-position
background-origin
background-clip
background-size
颜色
Color
color
opacity
字体
Font
font
font-style
font-variant
font-weight
font-size
font-family
font-stretch
文本
Text
line-height
letter-spacing
text-align
text-align-last
text-indent
text-justify
text-transform
tab-size
vertical-align
white-space
word-break
word-spacing
word-wrap
overflow-wrap
文本装饰
Text Decoration
text-decoration
text-decoration-line
text-decoration-style
text-decoration-color
text-shadow
书写模式
Writing Modes
direction
unicode-bidi
writing-mode
列表
List
list-style
list-style-image
list-style-position
list-style-type
表格
Table
table-layout
border-collapse
border-spacing
caption-side
empty-cells
内容
Content
content
counter-increment
counter-reset
quotes
用户界面
User Interface
box-sizing
nav-index
nav-up
nav-right
nav-down
nav-left
outline
outline-width
outline-style
outline-color
outline-offset
text-overflow
ime-mode
cursor
zoom
resize
user-select
变换
Transform
transform
transform-origin
过渡
Transition
transition
transition-property
transition-duration
transition-timing-function
transition-delay
动画
Animation
animation
animation-name
animation-duration
animation-timing-function
animation-delay
animation-iteration-count
animation-direction
animation-play-state
animation-fill-mode
打印
Printing
page
page-break-before
page-break-after
page-break-inside
语法与规则
Rules
!important
/*comments*/
@charset
@import
@media
@font-face
@page
@keyframes
颜色值
Values
Color Name
HEX
RGB
RGBA
HSL
HSLA
transparent
文本值
Textual
<string>
<url>
<identifier>
函数值
Functional
counter()
attr()
calc()
cycle()
图像值
Image
linear-gradient()
radial-gradient()
repeating-linear-gradient()
repeating-radial-gradient()
数字值
Numeric
<integer>
<number>
其它类型值
Other
<length>
<percentage>
<angle>
<time>
<frequency>
长度单位
Length
em
ex
ch
rem
vw
vh
vm
cm
mm
in
pt
pc
px
角度单位
Angle
deg
grad
rad
turn
时间单位
Time
s
ms
频率单位
Frequency
Hz
kHz