CSS3 Online Test Questions part 4

19. Elements with gradients look better when zoomed, because the gradient is generated by the browser.

a. True
b. False

Answer: a. True

Explanation: The above statement is true. Elements with gradients look better when zoomed, because the gradient is generated by the browser.


20. In CSS3, you can add more than one shadow to the text.

a. True
b. False

Answer: a. True

Explanation: Yes, in CSS3, you can add more than one shadow to the text.


21. HSLA color values are an extension of HSL color values with an alpha channel - which specifies the opacity for a color.

a. True
b. False

Answer: a. True

Explanation: The above statement is true. HSLA color values are an extension of HSL color values with an alpha channel - which specifies the opacity for a color.


22. Which of the following property is used to create rounded images?

a. border
b. opacity
c. border-radius
d. filter

Answer: c. border-radius

Explanation: The border-radius property is used to create rounded images. It is a shorthand property for setting the four border-*-radius properties. If you specify only one value for the border-radius property, this radius will be applied to all 4 corners. However, you can specify each corner separately if you wish.


23. Which of the following property is used to create thumbnail images?

a. border
b. opacity
c. border-radius
d. filter

Answer: a. border

Explanation: The border property is used to create thumbnail images.


24. The CSS3 object-fit property can have the following values:

a. contain
b. cover
c. fill
d. All of the above

Answer: d. All of the above
Explanation: The object-fit CSS property specifies how a replaced element, such as an <img> or <video>, should be resized to fit its container. Following are the values of object-fit property,

fill - This is default. This property means that the replaced content is sized to fill the element's content box. If necessary, the object will be stretched or squished to fit .

contain - This property means that the replaced content is scaled to maintain its aspect ratio while fitting within the element's content box .

cover - This property means that the replaced content is sized to maintain its aspect ratio while filling the element's entire content box. The object will be clipped to fit .

none - This property means that the replaced content is not resized .

scale-down - This property means that the content is sized as if none or contain were specified (would result in a smaller concrete object size).