CSS餐厅练习题

CSS餐厅练习题

选择跳动的元素
1-----plate 类型选择器

2-----bento 类型选择器

3-----#fancy ID选择器

4-----plate>apple 后代选择器

5-----#fancy pickle 结合后代和ID选择器

6-----.small 类选择器

7-----orange.small 结合类选择器

8-----bento>orange

9-----plate,bento 逗号组合器

10---- * 通用选择器

11---- plate * 结合通用选择器

12----plate + apple 相邻兄弟选择器

13----bento~pickle 通用兄弟选择器

14----plate > apple 儿童选择器

15----orange:first-child 第一个孩子伪选择器

16----plate>apple,plate>pickle 独生子伪选择器

17-----.small:last-child 最后一个孩子伪选择器

18-----plate:nth-child(3) 第N个儿童伪选择器

19-----bento:nth-of-type(1) 第N个最后一个孩子选择器

20-----apple:first-of-type 第一类选择器

21-----plate:nth-of-type(2n) 类型选择器的第N个

22-----plate:nth-of-type(2n+3) 具有公式的第N个选择器

23-----plate apple:only-of-type 仅类型选择器

24-----orange.small:last-of-type,apple.small:last-of-type 最后一个类型选择器

25-----bento:empty 空选择器

26-----apple:not(.small) 否定伪类