更多选择器

更多伪类选择器
1.first-child:选中第一个子元素
2.first-of-type()选中子元素中第一个指定类型的元素
3.last-child:选中最后一个子元素
4.last-of-type():选中最后一个指定类型的子元素
5.nth-child()选中第几个子元素
6.nth-of-type() 选中子元素中第几个指定类型的元素

更多伪元素选择器
first-letter:选中元素内容中第一个字母
first-line:选中元素中内容那个中的第一行
selection:选中被用户框选的元素内容

猜你喜欢

转载自www.cnblogs.com/fhzm/p/13374291.html