Horizontal Label
Labels positioned on the left side for compact forms
Horizontal Label
by FreeCsStyles Dev's
CompactCSS
🌐HTML/CSS
#horizontal#compact#labels
Embed this component
Paste this snippet into any site — the design renders in a sandboxed iframe served from /embed/horizontal-label.
<iframe src="/embed/horizontal-label" sandbox="allow-scripts" loading="lazy" title="Horizontal Label" style="border:0;width:100%;height:480px;overflow:hidden"></iframe>Implementation code
Copy the HTML and CSS for Horizontal Label. The HTML and CSS variants are self-contained; framework variants assume that framework's project setup.
HTML
<form class="form-horizontal">
<div class="horizontal-item">
<label>Company</label>
<input type="text" placeholder="Acme Inc.">
</div>
</form>CSS
.form-horizontal {
background: #ffffff;
padding: 2rem;
border-radius: 16px;
}
.horizontal-item {
display: flex;
align-items: center;
gap: 1rem;
padding: 0.8rem 0;
border-bottom: 1px solid #f5f5f5;
}
.horizontal-label {
min-width: 130px;
font-weight: 500;
}Topics
- #horizontal
- #compact
- #labels