updates AddUserModal to use new validator

This commit is contained in:
Keviin Åberg Kultalahti 2021-05-11 18:03:43 +02:00
parent 46cbba1cc0
commit 2b3c4ee2bc
1 changed files with 5 additions and 2 deletions

View File

@ -1,11 +1,13 @@
<script>
import { Body, Input, Select, ModalContent } from "@budibase/bbui"
import { createValidationStore, emailValidator } from "helpers/validation"
export let options
export let selected
export let email = ""
export let onConfirm
export let disabled
const [email, emailError] = createValidationStore("", emailValidator)
</script>
<ModalContent
@ -30,7 +32,8 @@
/>
<Input
type="email"
bind:value={email}
bind:value={$email}
error={$emailError}
placeholder="john@doe.com"
label="Email"
/>