Which class will hide the label in form? What is the function of .align-items-stretch?

Question image

Understand the Problem

The question is asking which class among the provided options will hide a label in a form. It also inquires about the function of another CSS property, .align-items-stretch.

Answer

'.sr-only' hides labels; '.align-items-stretch' stretches items in Flexbox.

The class '.sr-only' will hide the label in a form by making it accessible only to screen readers. The function of '.align-items-stretch' is to stretch flex items to fill the container on the cross axis.

Answer for screen readers

The class '.sr-only' will hide the label in a form by making it accessible only to screen readers. The function of '.align-items-stretch' is to stretch flex items to fill the container on the cross axis.

More Information

The '.sr-only' class is useful for ensuring accessibility compliance by hiding elements visually while keeping them accessible to screen readers. '.align-items-stretch' is used in Flexbox layouts to ensure elements take full height of their container.

Tips

A common mistake is confusing the '.sr-only' class with '.d-none'. While '.d-none' hides elements entirely, '.sr-only' keeps them accessible for assistive technologies.

AI-generated content may contain errors. Please verify critical information

Thank you for voting!
Use Quizgecko on...
Browser
Browser