JSFiddle - React, Tailwind, and code Playground
HTML
<form action="/echo/html/" method="post">
<legend>Grouped elements</legend>
<div>
<label for="element">Name</label>
<input type="text" id="element" required />
</div>
<hr />
<div class="group">
<div>
<input type="checkbox" id="option1" name="checkboxes" />
<label for="option1">Option 1</label>
</div>
<div>
<input type="checkbox" id="option2" name="checkboxes" />
<label for="option2">Option 2</label>
</div>
<div>
<input type="checkbox" id="option3" name="checkboxes" />
<label for="option3">Option 3</label>
</div>
</div>
<button type="submit">Submit form</button>
</form>