CSS Layout - Most popular layouts and patterns that can be built with CSS | Product Hunt Embed
.home
~
.explore

Input add-on

<!-- Add-on prepended -->
<div style="
    display: flex;

    /* Take full size */
    width: 100%;
">
    <!-- Add-on -->
    <div style="
        /* Center the content */
        align-items: center;
        display: flex;
        justify-content: center;
    ">
        ...
    </div>

    <!-- Input -->
    <input type="text" style="
        /* Take the remaining width */
        flex: 1;
    " />
</div>

<!-- Add-on appended -->
<div style="
    display: flex;

    /* Take full size */
    width: 100%;
">
    <!-- Input -->
    <input type="text" style="
        /* Take the remaining width */
        flex: 1;
    " />

    <!-- Add-on -->
    <div style="
        /* Center the content */
        align-items: center;
        display: flex;
        justify-content: center;
    ">
        ...
    </div>
</div>

<!-- Appended and prepended add-ons -->
<div style="
    display: flex;

    /* Take full size */
    width: 100%;
">
    <!-- Add-on -->
    <div style="
        /* Center the content */
        align-items: center;
        display: flex;
        justify-content: center;
    ">
        ...
    </div>

    <!-- Input -->
    <input type="text" style="
        /* Take the remaining width */
        flex: 1;
    " />

    <!-- Add-on -->
    <div style="
        /* Center the content */
        align-items: center;
        display: flex;
        justify-content: center;
    ">
        ...
    </div>
</div>
Subscribe to the newsletter for the latest layouts or patterns. No spam. Ever!