第4天 CSS选择器有哪些?哪些属性可以继承?
Activity
yxkhaha commentedon Apr 20, 2019
选择器
可以继承的属性
hbl045 commentedon May 5, 2019
属性继承好像只要有inherit属性都可以继承,详情自查
tiyunchen commentedon May 28, 2019
text-indent:文本缩进
text-align:文本水平对齐
text-shadow:设置文本阴影
line-height:行高
word-spacing:增加或减少单词间的空白(即字间隔)
letter-spacing:增加或减少字符间的空白(字符间距)
text-transform:控制文本大小写direction:规定文本的书写方向
AricZhu commentedon Jun 18, 2019
能继承的属性:
字体系列
font-size
font-weight
font-family
font-style
...
文本系列
text-align
text-indent
text-shadow
line-height
color
...
其他
visibility
cursor
...
poporeki commentedon Jul 4, 2019
选择器
id选择器
#header
class选择器
.container
伪类选择器
::after
属性选择器
[type='input']
兄弟选择器
+
后代选择器
>
通配符
*
继承
这个还真没记过
font-size
font-family
text-align
color
Lianfeiru commentedon Jul 30, 2019
https://blog.csdn.net/sjinsa/article/details/70768483这个比较全面
wsb260 commentedon Jul 31, 2019
选择器:
通配符,id,class,标签,后代选择器,子选择器,兄弟选择器,属性选择器,伪类选择器,伪元素选择器
可继承的属性:
字体属性:font-size,font-weight,font-style,font-family
文本属性:text-indent,text-align,line-height,word-spacing,letter-spacing,color,direction,text-transform
元素可见性:visibility,opacity
光标属性:cursor
weizhanzhan commentedon Sep 9, 2019
选择器
继承
censek commentedon Sep 27, 2019
元素。
元素。
元素。
元素。
元素。
元素的首字母。
元素的首行。
元素。
元素的内容之前插入内容。
元素的内容之后插入内容。
元素。
元素的每个
元素。
元素的每个
元素。
元素的每个
元素。
元素的每个
元素。
元素。
元素。
元素的每个
元素。
元素。
元素(包括文本节点)。
元素的每个元素。
css有哪些属性可以继承?
rennzhang commentedon Mar 11, 2020
CSS 的选择器
这里不做统计了,可以参考速查文档
那些属性可以继承
1. 所有元素都可以继承
visibility
和cursor
2. 内联元素可以继承
letter-spacing
:字符之间的间隙word-spacing
:单词之间的间隙white-space
:换行方式line-height
:行高color
:颜色font
:字体设置font-family
:字体名称font-size
:字体大小font-style
:字体样式font-variant
:是否为小型的大写字母font-weight
:文本字体的粗细text- decoration
:复合属性。文本的装饰。text-transform
:文本的大小写direction
:文本流的方向3. 块级元素可以继承
text-indent
:文本缩进text-align
:文本对齐方式4. 列表元素可以继承
list-style
:复合属性。设置列表项目相关内容list-style-type
:列表项所使用的预设标记list-style-position
:列表项标记如何根据文本排列list-style-image
:列表项标记的图像5. 表格元素嗯昆虫继承
border-collapse
:表格的行和单元格的边是合并还是独立6. 不可继承的元素
display
、margin
、border
、padding
、background
、height
、min-height
、max- height
、width
、min-width
、max-width
、overflow
、position
、left
、right
、top
、bottom
、z-index
、float
、clear
、table-layout
、vertical-align
、page-break-after
、page-bread-before和unicode-bid
blueRoach commentedon May 18, 2020
CSS选择器:
通配符
元素选择器
class选择器
id选择器
属性选择器
伪类
可继承属性:
font-
text-
visibility
giggleCYT commentedon May 29, 2020
选择器
通配符、id、class、元素选择器、子代选择器、兄弟选择器、属性选择器、伪类、伪元素
可继承属性
color、font-(size、style、family...)、text-(transform、align...)、list-style-(type、position...)
huoyuhao commentedon Jan 28, 2021
16 remaining items