Add vue stuff to sample styleguide input

This commit is contained in:
Andrew Croce 2018-08-08 10:59:14 -04:00
parent bed396131a
commit f48a878beb

View File

@ -130,24 +130,27 @@
<form>
<textinput inline-template>
<div class='usa-input'>
<textinput inline-template validation='dollars' value='1231231'>
<div v-bind:class="['usa-input usa-input--validation--' + validation, { 'usa-input--error': showError, 'usa-input--success': showValid }]">
<label for='basic-text-1'>
Basic Text Input
Dollars Text Input
<span class='usa-input__help'>
This is some help text to explain what this form field is and why you should fill it out.
</span>
<template v-if='showError'>{{ Icon('alert') }}</template>
<template v-if='showValid'>{{ Icon('ok') }}</template>
</label>
<masked-input
v-on:input='onInput'
v-on:change='onChange'
v-model='value'
id='basic-text-1'
type='text'
placeholder='this is a sample of what you should enter'
ref='input'
placeholder='$'
:guide="true"
:mask="mask">
</masked-input>
<div v-if='showError'>Error</div>
<div v-if='showValid'>Valid</div>
</div>
</textinput>