Top 20 MCQ Questions On CSS3 Element Selectors

This set of multiple choice question includes collection of top 20 MCQ questions on CSS3 form element focused selectors outside the core selector, CSS3 measurement units and values along with CSS3 media queries and values.

 
1. A CSS3 selector ………………. selectors the interactive element out of a group that is the default choice.
A) :set
B) :default
C) :default-option
D) :default-choice

2. A CSS3 selector ………………….. is used to select interactive elements whose values are found within a range specified by the HTML5 min and max attributes.
A) :within-range
B) :range
C) :in-range
D) :value-range

3. ………………. selector applies styles to elements that are invalid per HTML5 validations set by the pattern or implied by the type attributes for the form control.
A) :valid
B) :invalid
C) :validation
D) :control

4. ………………… selector applies styles to elements that are not required to be addressed before submission.
A) :required
B) :optional
C) :not-required
D) :default

5. A CSS3 selector …………………… is used to select interactive elements whose values are outside the range specified by the HTML5 min and max attributes.
A) :range
B) :out-range
C) :out-of-range
D) :outside-range

6. In CSS3 measurement unit, ………………… is a font-related length that is equivalent to the width of the character 0 in the current font.
A) dpcm
B) ch
C) vh
D) vm

7. A CSS3 measurement unit, ………………. is either the view-port’s height or its width, whichever is smaller.
A) vm
B) vw
C) vh
D) ch

8. In CSS3 measurement unit, …………………… is the font size of the document’s root element.
A) ms
B) rad
C) rem
D) ch

9. In CSS3 media query, ……………….. is the ratio of width to the height of the media.
A) actual-ratio
B) device-ratio
C) measurement-ratio
D) aspect-ratio


10. …………………… is the CSS3 media query, which describes the number of bits of color the device supports or 0 if no color is supported.
A) color-index
B) color-bits
C) color
D) bit-index

11. A CSS3 media query ……………….. describes number of entries in the color lookup table of the output device or 0 if color is not supported.
A) color-index
B) color-bits
C) color
D) bit-index

12. ………………… is the ratio of the device width to the device height of the media.
A) device-aspect-ratio
B) device-ratio
C) aspect-ratio
D) width-height-ratio

13. ……………… is the CSS3 media query, which returns output style portrait of height is greater than or equal to width, landscape if the opposite.
A) position
B) portrait
C) orientation
D) landscape

14. A CSS code ……………………. makes outline of the paragraph red which are possible to read and write.
A) p: read-write {outline: red solid 5px;}
B) p: rw {outline: red solid 5px;}
C) p: readwrite {outline: red solid 5px;}
D) p: writable {outline: red solid 5px;}

15. ……………….. makes all the required fields with gray color and * symbol indicator.
A) :required :add {content: “(*)”; color:gray;}
B) :required :after {content: “(*)”; color:gray;}
C) :required :after {add-content: “(*)”; color:gray;}
D) :after :required {content: “(*)”; color:gray;}

16. …………………. makes all the default submit button to green.
A) [type=”submit”] :default {color:green;}
B) submit :default {color:green;}
C) input [type=”submit”] :default {color:green;}
D) input [submit] :default {color:green;}

17. When applied to form elements, ………………. selector would select fields with the read-only attribute set.
A) readonly
B) read-only
C) read
D) not-writtable

18. …………………….. selector applies styles to elements that must be addressed before submission.
A) :must
B) :required
C) :must-be
D) :addressed

Answers

1. B) :default
2. C) :in-range
3. B) :invalid
4. B) :optional
5. C) :out-of-range
6. B) ch
7. A) vm
8. C) rem
9. D) aspect-ratio
10. C) color
11. A) color-index
12. A) device-aspect-ratio
13. C) orientation
14. A) p: read-write {outline: red solid 5px;}
15. B) :required :after {content: “(*)”; color:gray;}
16. C) input [type=”submit”] :default …..
17. B) read-only
18. B) :required

Read Next:Multiple Choice Questions On CSS3 Properties Part-1