Forms

A combination of form styles and the grid means you can do almost anything. Listed below are styles for individual form components as well as various layout guidelines.

NM Material Design Forms

An example form:

EXAMPLE

Show Code

<form>
    <div class="row">
        <div class="large-12 columns md-text-field with-floating-label">
            <input type="text" id="input_1" required>
            <label for="input_1">Floating Label Text</label>
        </div>
    </div>
    <div class="row">
        <div class="large-12 columns md-text-field with-floating-label">
            <input type="password" id="input_15" required>
            <label for="input_15">Floating Label Password</label>
        </div>
    </div>
    <div class="row">
        <div class="large-4 columns md-text-field with-floating-label">
            <input type="text" id="input_2" required>
            <label for="input_2">large-4.columns</label>
        </div>
        <div class="large-4 columns md-text-field with-floating-label">
            <input type="text" id="input_3" required>
            <label for="input_3">large-4.columns</label>
        </div>
        <div class="large-4 columns md-text-field with-floating-label">
            <input type="text" id="input_4" required>
            <label for="input_4">large-4.columns</label>
        </div>
    </div>
    <div class="row">
        <div class="large-12 columns">
            <div class="uitk-select md-text-field with-floating-label">
                <input type="text" class="select-input" readonly="true" value="Select an Option" required>
                <span class="select-arrow"></span>
                <ul class="select-dropdown">
                    <li class="disabled"><span>Select an Option</span></li>
                    <li>Option 1</li>
                    <li>Option 2</li>
                    <li>Option 3</li>
                </ul>
                <label>Select Box Label</label>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="small-12 columns">
            <div class="row collapse">
                <label>Prefix Select Box</label>
                <div class="small-3 large-2 columns md-text-field with-floating-label">
                    <div class="uitk-select">
                        <input type="text" class="select-input" readonly="true" value="Husker" required>
                        <span class="select-arrow"></span>
                        <ul class="select-dropdown">
                            <li>Husker</li>
                            <li>Starbuck</li>
                            <li>Hot Dog</li>
                            <li>Apollo</li>
                        </ul>
                    </div>
                </div>
                <div class="small-9 large-10 columns md-text-field with-floating-label">
                    <input type="text" id="input_5" required>
                    <label for="input_5">Enter your URL...</label>
                </div>
            </div>
        </div>
        <div class="large-12 columns">
        </div>
    </div>
    <div class="row">
        <div class="large-6 columns md-multi-ctrl-field">
            <label>Choose Your Favorite</label>
            <input id="pokemonRed" name="pokemon" type="radio" value="Red">
            <label for="pokemonRed">Red</label>
            <input id="pokemonBlue" name="pokemon" type="radio" value="Blue">
            <label for="pokemonBlue">Blue</label>
        </div>
        <div class="large-6 columns md-multi-ctrl-field">
            <label>Check these out</label>
            <input id="checkbox1" type="checkbox">
            <label for="checkbox1">Checkbox 1</label>
            <input id="checkbox2" type="checkbox">
            <label for="checkbox2">Checkbox 2</label>
        </div>
    </div>
    <div class="row">
        <div class="large-12 columns">
            <div class="md-textarea-field with-floating-label">
                <textarea type="text" id="input_6" rows="3" required></textarea>
                <label for="input_6">Standard Textarea Field</label>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="large-12 columns">
            <div class="md-textarea-field with-floating-label md-textarea--autoresize">
                <textarea data-autoresize="" rows="1" type="text" id="input_7" required></textarea>
                <label for="input_7">Multi-line Expanding Text Field</label>
            </div>
        </div>
    </div>
</form>
  • Select an Option
  • Option 1
  • Option 2
  • Option 3
  • Husker
  • Starbuck
  • Hot Dog
  • Apollo

LV Forms

Done correctly, you can put together a form like this one:

EXAMPLE

Show Code

<form>
    <div class="row">
        <div class="large-12 columns">
            <label>Input Label</label>
            <input type="text" placeholder="Your placeholder">
        </div>
    </div>
    <div class="row">
        <div class="large-4 columns">
            <label>Input Label</label>
            <input placeholder="large-4.columns" type="text">
        </div>
        <div class="large-4 columns">
            <label>Input Label</label>
            <input placeholder="large-4.columns" type="text">
        </div>
        <div class="large-4 columns">
            <div class="row collapse">
                <label>Input Label</label>
                <div class="small-9 columns">
                    <input class="with-postfix" placeholder="small-9.columns" type="text">
                </div>
                <div class="small-3 columns">
                    <span class="postfix">.com</span>
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="large-12 columns">
            <label>Select Box</label>
            <select>
                <option value="husker">
                    Husker
                </option>
                <option value="starbuck">
                    Starbuck
                </option>
                <option value="hotdog">
                    Hot Dog
                </option>
                <option value="apollo">
                    Apollo
                </option>
            </select>
        </div>
    </div>
    <div class="row">
        <div class="small-12 columns">
            <div class="row collapse">
                <label>Prefix Select Box</label>
                <div class="small-3 large-2 columns">

                    <select class="prefix">
                        <option value="husker">
                            Husker
                        </option>
                        <option value="starbuck">
                            Starbuck
                        </option>
                        <option value="hotdog">
                            Hot Dog
                        </option>
                        <option value="apollo">
                            Apollo
                        </option>
                    </select>
                </div>
                <div class="small-9 large-10 columns">
                    <input class="with-prefix" type="text" placeholder="Enter your URL...">
                </div>
            </div>
        </div>
        <div class="large-12 columns">
        </div>
    </div>
    <div class="row">
        <div class="large-6 columns">
            <label>Choose Your Favorite</label>
            <input id="pokemonRed" name="pokemon" type="radio" value="Red">
            <label for="pokemonRed">Red</label>
            <input id="pokemonBlue" name="pokemon" type="radio" value="Blue">
            <label for="pokemonBlue">Blue</label>
        </div>
        <div class="large-6 columns">
            <label>Check these out</label>
            <input id="checkbox1" type="checkbox">
            <label for="checkbox1">Checkbox 1</label>
            <input id="checkbox2" type="checkbox">
            <label for="checkbox2">Checkbox 2</label>
        </div>
    </div>
    <div class="row">
        <div class="large-12 columns">
            <label>Textarea Label</label>
            <textarea placeholder="small-12.columns"></textarea>
        </div>
    </div>
</form>
.com

Inputs

NM Text Inputs

Below is the basic <input> element with class .md-text-field. On focus the underline changes to the active color.

EXAMPLE

Show Code

<!-- Example input -->
<div class="md-text-field">
    <input type="text" placeholder="Placeholder Text">
</div>

LV Text Inputs

Below is the basic <input> element. On hover, its border color darkens.

EXAMPLE

Show Code

<!-- Example input -->
<input type="text" placeholder="Your placeholder">

NM Disabled state

To disable your button and add disabled styles, add the [disabled] attribute as seen below.

EXAMPLE

Show Code

<!-- Disabled input -->
<div class="md-text-field">
    <input type="text" placeholder="Placeholder Text" disabled>
</div>

LV Disabled state

To disable your button (thus adding disabled styles), simply add the [disabled] attribute as seen below.

EXAMPLE

Show Code

<!-- Disabled input -->
<input type="text" placeholder="Your placeholder" disabled>

NM Floating Labels

Field labels should follow the material design floating label component. There are a few requirements to make the labels work.

  1. Add class .with-floating-label to the .md-text-field wrapper. Then create a <label> element directly below <input>.
  2. The <input> must also contain an id attribute that matches the for attribute on it's associated <label> element.
  3. The required attribute is needed for CSS recognize when the input is focused. If the input is not required you can manually add the class .has-focus onClick.
  4. As long as the field is not empty (:valid) the label will remain floating. If form validation is being done on the field you can use the class .has-success after the checking the value to keep the label floating.

Helper text can also be placed below the field line for additional text to help the user correctly complete the form. Add <span> or <label> element last in the .md-text-field container with the class .info. (Note, the <label> element should only be used for helper text if a primary label is already provided.)

EXAMPLE

Show Code

<!-- With required attribute -->
<div class="md-text-field with-floating-label">
    <input type="text" id="input_8" required>
    <label for="input_8">Floating Label Text</label>
</div>

<!-- With has-focus classes -->
<div class="md-text-field with-floating-label">
    <input type="text" id="input_9" class="has-focus">
    <label for="input_9">Floating Label Text</label>
</div>

<!-- With helper text classes -->
<div class="md-text-field with-floating-label">
    <input type="text" id="input_16" required>
    <label for="input_16">Floating Label Text</label>
    <span class="info">Helper text</span>
</div>
Helper text

LV Field Labels

To add a label to your <input>, use a <label> element and supply label text as follows.

EXAMPLE

Show Code

<label>Input Label</label>
<input type="text" placeholder="Your placeholder">

NM Error State

To add an error state to your text-input <input>, add the .has-error class. Similar to the helper text, error messages can be placed in <span> or <label> last in the .md-text-field container with the class .error. (Note, the <label> element should only be used for error text if a primary label is already provided.)

EXAMPLE

Show Code

<!-- Text-level input error state applied directly -->
<div class="md-text-field with-floating-label">
    <input type="text" id="input_10" class="has-error" value="Field Input Text" required>
    <label for="input_10">Floating Label Text</label>
    <span class="error">Invalid entry</span>
</div>
Invalid entry

LV Error State

To add an error state to your text-level <input>, add the .error class.

Alternatively, you can add the .error class to a parent of your <input>. For example, below the .error class is added to parent <div>.

EXAMPLE

Show Code

<!-- Text-level input error state applied directly -->
<input type="text" class="error" placeholder="Your placeholder">
<small class="error">Invalid entry</small>

<!-- Text-level input error state applied to parent -->
<div class="error">
    <label class="error">Input Label</label>
    <input type="text" placeholder="Your placeholder">
    <small class="error">Invalid entry</small>
</div>
Invalid entry
Invalid entry

Selects

NM Select Box

Material Design select dropdowns are essentially menus. An input will hold the selected value, while an ul will hold the options. There is a jQuery example in the code area that for controlling the select box.

If you already have select elements, you can write a plugin to hide the <select> element and rewrite it with the input and ul or simply replace any <select> element in your code with the markup shown below.

EXAMPLE

Show Code

<!-- Example select dropdown -->
<div class="uitk-select md-text-field with-floating-label">
    <input type="text" class="select-input" readonly="true" value="Select an Option" required>
    <span class="select-arrow"></span>
    <ul class="select-dropdown">
        <li class="disabled"><span>Select an Option</span></li>
        <li>Option 1</li>
        <li>Option 2</li>
        <li>Option 3</li>
    </ul>
    <label>Select Box Label</label>
</div>

<!-- jQuery Example select dropdown -->
<script src="">
// Open dropdown when input clicked
$('.select-input').click(function() {
    $(this).parents('.uitk-select').toggleClass('is-open');
});

// If dropdown li not disabled set to active and add text to input
$('.select-dropdown > li:not(.disabled)').click(function() {
    var $selectParent = $(this).parents('.uitk-select');
    var $liCheckbox;
    var checkedValues = '';
    $(this).toggleClass('active');

    if ($selectParent.hasClass('multiple')) {
        $liCheckbox = $(this).find('input[type="checkbox"]');
        $liCheckbox.prop('checked', !$liCheckbox.prop('checked'));
        checkedValues = $selectParent.find('input:checkbox:checked').map(function() {
            return $(this).siblings('span').text();
        }).get().join(', ');
        $selectParent.find('.select-input').val(checkedValues);
    } else {
        checkedValues = $(this).text();
        $selectParent.find('.select-input').val(checkedValues);
        $(this).siblings().removeClass('active');
        $selectParent.removeClass('is-open');
    }
});

// Checkbox in multiple selects will be checked by clicking on the li
$('.select-dropdown > li input[type="checkbox"]').click(function(e){
    e.stopPropagation();
});

// Close dropdowns if clicked outside uitk-select
$(document).click(function (e) {
    e.stopPropagation();
    if ($(".uitk-select").has(e.target).length === 0) {
        $(".uitk-select").removeClass('is-open');
    }
});
</script>
  • Select an Option
  • Option 1
  • Option 2
  • Option 3

NM Select Box Native

For accessibility reason, some apps may need to keep the native OS HTML select. Instead of using the <input> + <ul> dropdown, the regular <select> element is still available. While not open the element will look the similar to the fully styled select box. While open it will use the OS native styling which cannot be changed with CSS.

EXAMPLE

Show Code

<div class="uitk-select md-text-field with-floating-label">
    <select class="os-default">
        <option disabled selected value="">Select an Option</option>
        <option value="option 1">Option 1</option>
        <option value="option 2">Option 2</option>
        <option value="option 3">Option 3</option>
    </select>
    <span class="select-arrow"></span>
    <label>Select Box Label</label>
</div>

LV Select Box

Below is the basic <select> element, which appears very similarly to the <input> above.

EXAMPLE

Show Code

<!-- Example select -->
<select>
    <option value="Lorem ipsum">Lorem ipsum</option>
    <option value="Dolor sit amet">Dolor sit amet</option>
    <option value="Eu est tamquam">Eu est tamquam</option>
    <option value="Meliore">Meliore</option>
</select>

NM Multiple

You may apply the .multiple class your .uitk-select wrapper to allow more than one option to be selected.

EXAMPLE

Show Code

<!-- Multiple select -->
<div class="uitk-select multiple md-text-field with-floating-label">
    <input type="text" class="select-input" readonly="true" value="Select an Option" required>
    <span class="select-arrow"></span>
    <ul class="select-dropdown md-multi-ctrl-field">
        <li class="disabled"><span>Select an Option</span></li>
        <li><input name="multiple-select-checkbox" type="checkbox"><span>Option 1</span></li>
        <li><input name="multiple-select-checkbox" type="checkbox"><span>Option 2</span></li>
        <li><input name="multiple-select-checkbox" type="checkbox"><span>Option 3</span></li>
    </ul>
    <label>Select Box Label</label>
</div>
  • Select an Option
  • Option 1
  • Option 2
  • Option 3

LV Multiple

You may apply the multiple attribute your select to allow more than one option to be selected. Hold down the Ctrl (windows) / Command (Mac) button to select multiple options.

EXAMPLE

Show Code

<!-- Multiple select -->
<select multiple>
    <option value="Lorem ipsum">Lorem ipsum</option>
    <option value="Dolor sit amet">Dolor sit amet</option>
    <option value="Eu est tamquam">Eu est tamquam</option>
    <option value="Meliore">Meliore</option>
</select>

NM Disabled state

You may disable the select dropdown by adding the [disabled] attribute to the .select-input <input> element.

EXAMPLE

Show Code

<!-- Disabled select dropdown -->
<div class="uitk-select md-text-field with-floating-label">
    <input type="text" class="select-input" readonly="true" value="Select an Option" disabled>
    <span class="select-arrow"></span>
    <ul class="select-dropdown">
        <li class="disabled"><span>Select an Option</span></li>
        <li>Option 1</li>
        <li>Option 2</li>
        <li>Option 3</li>
    </ul>
    <label>Select Box Label</label>
</div>
  • Select an Option
  • Option 1
  • Option 2
  • Option 3

LV Disabled state

You may disable your select as you disable a text-level input with the [disabled] attribute.

EXAMPLE

Show Code

<!-- Disabled select -->
<select disabled>
    <option value="Lorem ipsum">Lorem ipsum</option>
    <option value="Dolor sit amet">Dolor sit amet</option>
    <option value="Eu est tamquam">Eu est tamquam</option>
    <option value="Meliore">Meliore</option>
</select>

NM Error state

You may apply an error-state to the <input> just as you would a text-level <input> by adding the .has-error class.

EXAMPLE

Show Code

<!-- Select error state applied directly -->
<div class="uitk-select md-text-field with-floating-label">
    <input type="text" class="has-error select-input" readonly="true" value="Select an Option">
    <span class="select-arrow"></span>
    <ul class="select-dropdown">
        <li class="disabled"><span>Select an Option</span></li>
        <li>Option 1</li>
        <li>Option 2</li>
        <li>Option 3</li>
    </ul>
    <label>Select Box Label</label>
    <span class="error">Invalid entry</span>
</div>
  • Select an Option
  • Option 1
  • Option 2
  • Option 3
Invalid entry

LV Error state

You may apply an error-state to your <select> just as you would a text-level <input> - either by adding the .error class to the <select> ...or by adding the .error class to a parent of the <select>. (In the case below, a <label>.)

EXAMPLE

Show Code

<!-- Select error state applied directly -->
<select class="error">
    <option value="Lorem ipsum">Lorem ipsum</option>
    <option value="Dolor sit amet">Dolor sit amet</option>
    <option value="Eu est tamquam">Eu est tamquam</option>
    <option value="Meliore">Meliore</option>
</select>
<small class="error">Invalid entry</small>

<!-- Select error state applied to parent -->
<label class="error">Select Label</label>
<select>
    <option value="Lorem ipsum">Lorem ipsum</option>
    <option value="Dolor sit amet">Dolor sit amet</option>
    <option value="Eu est tamquam">Eu est tamquam</option>
    <option value="Meliore">Meliore</option>
</select>
<small class="error">Invalid entry</small>
Invalid entry Invalid entry

Textareas

NM Textarea

<textarea> inputs should be wrapped in the .md-textarea-field .with-floating-label classes. There are two types of <textarea> elements available. The standard <textarea> is contained by a box border and wrap overflow text onto a new line. They scroll vertically when the cursor reaches the bottom of the field.

EXAMPLE

Show Code

<!-- Example textarea -->
<div class="md-textarea-field with-floating-label">
    <textarea type="text" id="input_11" rows="2" required></textarea>
    <label for="input_11">Textarea Floating Label</label>
</div>

NM Expanding Multi-line Textarea

The expanding multi-line <textarea> looks like a regular text <input> but the bottom will drop down when a new line is needed. Styles are provided for the expanding textarea by adding the class .md-textarea--autoresize to the .md-textarea-field wrapper.

There is a jQuery example in the code area that looks for a [data-autoresize] attribute on the <textarea> to bind the autoresize method to it.

EXAMPLE

Show Code

<!-- Example expanding multi-line textarea -->
<div class="md-textarea-field with-floating-label md-textarea--autoresize">
    <textarea data-autoresize="" rows="1" type="text" id="input_12" required></textarea>
    <label for="input_12">Textarea Floating Label</label>
</div>

<!-- jQuery Example expanding multi-line textarea -->
<script src="">
// jQuery Example: Control Multi-line text areas
$.each($('.md-textarea-field textarea[data-autoresize]'), function() {
    var offset = this.offsetHeight - this.clientHeight;

    var resizeTextarea = function(el) {
        $(el).css('height', 'auto').css('height', el.scrollHeight + offset);
    };
    $(this).on('keyup input', function() {
        resizeTextarea(this);
    }).removeAttr('data-autoresize');
});
</script>

LV Textarea

The <textarea> element will inherit the same theme-properties as the text-level input.

EXAMPLE

Show Code

<!-- Example textarea -->
<textarea placeholder="Example placeholder"></textarea>

NM Disabled State

You may add a disabled state to a <textarea> just as you would to a text-level <input> by applying the [disabled] attribute.

EXAMPLE

Show Code

<!-- Disabled textarea -->
<div class="md-textarea-field with-floating-label">
    <textarea type="text" id="input_13" rows="2" disabled></textarea>
    <label for="input_13">Textarea Label</label>
</div>

LV Disabled State

You may add a disabled state to a <textarea> just as you would to a text-level <input> by applying the [disabled] attribute.

EXAMPLE

Show Code

<!-- Disabled textarea -->
<textarea disabled placeholder="Example placeholder"></textarea>

NM Error State

You may add an error state to your <textarea> just as you would to a text-level input, by applying the .has-error class.

EXAMPLE

Show Code

<!-- Textarea error applied directly -->
<div class="md-textarea-field with-floating-label">
    <textarea type="text" id="input_14" class="has-error" rows="2" required></textarea>
    <label for="input_14">Textarea Label</label>
</div>

LV Error State

You may add an error state to your <textarea> just as you would to a text-level input, either by applying the .error class directly or by applying the .error class to a parent of the <textarea>.

EXAMPLE

Show Code

<!-- Textarea error applied directly -->
<textarea class="error" placeholder="Example placeholder"></textarea>

<!-- Textarea error applied to parent -->
<label class="error">Textarea label</label>
<textarea placeholder="Example placeholder"></textarea>

Multi Control Elements

NOTE: Styled radio buttons and checkboxes are custom to LV-Foundation - please do not seek documentation on the Foundation website.

Radio buttons have been styled for you! Check it out!

EXAMPLE

Show Code

<!-- Example radio-button set -->
<div class="md-multi-ctrl-field">
<input name="radio-example" id="radio-example-1" type="radio">
<label for="radio-example-1">Example Radio 1</label>
<input name="radio-example" id="radio-example-2" type="radio">
<label for="radio-example-2">Example Radio 2</label>
<input name="radio-example" id="radio-example-3" type="radio">
<label for="radio-example-3">Example Radio 3</label>
</div>

So have checkboxes!

EXAMPLE

Show Code

<!-- Example checkbox set -->
<div class="md-multi-ctrl-field">
<input name="checkbox-example" id="checkbox-example-1a" type="checkbox">
<label for="checkbox-example-1a">Example Checkbox 1</label>
<input name="checkbox-example" id="checkbox-example-2a" type="checkbox">
<label for="checkbox-example-2a">Example Checkbox 2</label>
<input name="checkbox-example" id="checkbox-example-3a" type="checkbox">
<label for="checkbox-example-3a">Example Checkbox 3</label>
</div>

Field Labels

You may add a form-field label to a multi-control set just as you would to any other form element with a <label> element.

EXAMPLE

Show Code

<!-- Example checkbox set with label -->
<label>Example checkbox labels</label>
<input name="checkbox-example" id="checkbox-example-1b" type="checkbox">
<label for="checkbox-example-1b">Example Checkbox 1</label>
<input name="checkbox-example" id="checkbox-example-2b" type="checkbox">
<label for="checkbox-example-2b">Example Checkbox 2</label>
<input name="checkbox-example" id="checkbox-example-3b" type="checkbox">
<label for="checkbox-example-3b">Example Checkbox 3</label>

Error Messages

While the multi-controls themselves do not have error states, you may supply an error message just as you would to any other form element with a <small> element with the .error class.

EXAMPLE

Show Code

<!-- Example checkbox set with error message-->
<div class="md-multi-ctrl-field">
<input name="checkbox-example" id="checkbox-example-1" type="checkbox">
<label for="checkbox-example-1">Example checkbox 1</label>
<input name="checkbox-example" id="checkbox-example-2" type="checkbox">
<label for="checkbox-example-2">Example Radio 2</label>
<input name="checkbox-example" id="checkbox-example-3" type="checkbox">
<label for="checkbox-example-3">Example Radio 3</label>
<small class="error">Please select at least one option.</small>
</div>
Please select at least one option.

Prefix-Postfix Labels & Actions

Prefix-Postfix Labels are coming soon for new Material Design forms. You can use the Select Box as a prefix without any additional classes as shown in the example at the top of this page.

LV Prefix Label

Below is an example of serving a label alongside a text-input.

This is achieved by using the .prefix class on the label to denote its position relative to the input it is labeling. Note that the input itself also has the .with-prefix class. In addition, the label and the input are displayed within a Foundation sub-grid, used to determine the size of the label relative to the input.

EXAMPLE

Show Code

<!-- Example label prefix -->
<div class="row collapse">
    <div class="small-3 large-2 columns">
        <span class="prefix">http://</span>
    </div>
    <div class="small-9 large-10 columns">
        <input class="with-prefix" type="text" placeholder="Enter your URL...">
    </div>
</div>
http://

LV Postfix Label

While the .prefix class is used to denote a label that prefixes the input, the .postfix class can be used to a similar effect for postfixing an input with a label.

EXAMPLE

Show Code

<!-- Example label postfix -->
<div class="row collapse">
    <div class="small-9 large-10 columns">
        <input class="with-postfix" type="text" placeholder="Your placeholder">
    </div>
    <div class="small-3 large-2 columns">
        <span class="postfix">Label</span>
    </div>
</div>
Label

LV Pre/Postfix Inputs

NOTE: The .with-prefix and .with-postfix classes are specific to LV-Foundation. As such, this documentation will differ from that which you will find on the Foundation website.

Selects may also be labeled as .prefix and .postfix classes. They can be used most commonly alongside text inputs as shown in this example.

EXAMPLE

Show Code

<!-- Example label postfix -->
<div class="row">
    <div class="small-12 columns">
        <div class="row collapse">
            <label>Prefix Select Box</label>
            <div class="small-3 large-2 columns">
                <select class="prefix">
                    <option value="husker">
                        Husker
                    </option>
                    <option value="starbuck">
                        Starbuck
                    </option>
                    <option value="hotdog">
                        Hot Dog
                    </option>
                    <option value="apollo">
                        Apollo
                    </option>
                </select>
            </div>
            <div class="small-9 large-10 columns">
                <input class="with-prefix" type="text" placeholder="Enter your URL...">
            </div>
        </div>
    </div>
    <div class="large-12 columns">
    </div>
</div>
NOTE: The .with-prefix and .with-postfix classes are specific to LV-Foundation. As such, this documentation will differ from that which you will find on the Foundation website.

LV Error States

You may add an error state to your text-level input with a pre/postfix label by adding the .error class to a parent of both the input and the label.

EXAMPLE

Show Code

<!-- Example label prefix -->
<div class="row collapse error">
    <div class="small-3 large-2 columns">
        <span class="prefix">http://</span>
    </div>
    <div class="small-9 large-10 columns">
        <input class="with-prefix" type="text" placeholder="Enter your URL...">
        <small class="error">Your url is invalid.</small>
    </div>
</div>
http://
Your url is invalid.

LV Pre/Postfix Actions

If you wish to tie a form-field to a specific action, you may want to prefix or postfix your input with a button rather than a standard label.

EXAMPLE

Show Code

<!-- Example Action prefix -->
<div class="row collapse">
    <div class="small-3 large-2 columns">
        <a href="#" class="prefix button">Go</a>
    </div>
    <div class="small-9 large-10 columns">
        <input class="with-prefix" type="text" placeholder="Value">
    </div>
</div>

<!-- Example Action postfix -->
<div class="row collapse">
    <div class="small-9 large-10 columns">
        <input class="with-postfix" type="text" placeholder="Value">
    </div>
    <div class="small-3 large-2 columns">
        <a href="#" class="postfix button">Go</a>
    </div>
</div>
Go
Go

LV Pre/Postfix Buttons

If you would like your button to assist with showing an error state, feel free to use the error button!

EXAMPLE

Show Code

<!-- Example label prefix -->
<div class="row collapse error">
    <div class="small-3 large-2 columns">
        <a href="#" class="prefix button alert">Go</a>
    </div>
    <div class="small-9 large-10 columns">
        <input class="with-prefix" type="text" placeholder="Value">
    </div>
</div>
Go