css::first-child设置首个子对象的样式
1、新建HTML文件

2、创建p和ul ,li标签

3、预览效果如图

4、设置p元素的首个对象样式p:first-child { font-size:40px;}

5、预览效果如图

6、设置li元素的首个对象样式li:first-child { text-decoration:line-through;}

7、预览效果如图

阅读量:67
阅读量:25
阅读量:20
阅读量:50
阅读量:175
1、新建HTML文件

2、创建p和ul ,li标签

3、预览效果如图

4、设置p元素的首个对象样式p:first-child { font-size:40px;}

5、预览效果如图

6、设置li元素的首个对象样式li:first-child { text-decoration:line-through;}

7、预览效果如图
