Use the fieldset component to group related form inputs.
When to use this component
Use the fieldset component when you need to show a relationship between multiple form inputs.
You can use the legend-
class to adjust the size of the <legend>
. Available sizes are:
legend-xl
legend-lg
legend-md
legend-sm
Formatted example
HTML code
<fieldset id="fieldset-group-name" aria-describedby="fieldset-group-title">
<legend id="fieldset-group-title" class="legend-lg">
Fieldset legend
</legend>
<!-- form fields go here -->
</fieldset>