Layout
In Kelp, the <label>
, <input>
, <textarea>
, <select>
, <fieldset>
, and <legend>
elements all have a width of 100%
.
You can use Kelp’s various layout classes to control the structure of your form elements on the page.
For example, you might use the .grid-m
class to create a two-column form on larger viewports.
<form>
<div class="grid-m">
<div class="item-half margin-end-2xs">
<label for="fname">First Name</label>
<input type="text" id="fname" name="fname">
</div>
<div class="item-half margin-end-2xs">
<label for="lname">Last Name</label>
<input type="text" id="lname" name="lname">
</div>
</div>
<button class="primary">Submit</button>
</form>