form validationMessage
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<label :for="name" v-if="label">{{ label }}</label>
|
||||
<div class="input_description" v-if="description">{{ description }}</div>
|
||||
</div>
|
||||
|
||||
|
||||
<input type="text" v-if="type == 'text'"
|
||||
v-model="currentValue"
|
||||
:name="name"
|
||||
@@ -21,6 +21,8 @@
|
||||
@change="() => $emit('change', currentValue)"
|
||||
:class="{invalid}"
|
||||
>
|
||||
|
||||
<div v-if="invalid && validatorMessage">{{ validatorMessage }}</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -42,7 +44,8 @@ export default {
|
||||
'placeholder',
|
||||
'type',
|
||||
'value',
|
||||
'invalid'
|
||||
'invalid',
|
||||
'validatorMessage'
|
||||
],
|
||||
data() {
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user