mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-27 13:47:58 +01:00
validate that emails look like emails
This commit is contained in:
parent
a5966ae287
commit
45048d5015
3 changed files with 5 additions and 5 deletions
|
@ -35,7 +35,7 @@ p
|
|||
|
||||
h3 Email address
|
||||
.field
|
||||
= text_input f, :email, class: "input", placeholder: "Email", required: true
|
||||
= text_input f, :email, class: "input", placeholder: "Email", required: true, pattern: ".*@.*"
|
||||
= error_tag f, :email
|
||||
|
||||
h3 Change Password
|
||||
|
@ -60,4 +60,4 @@ p
|
|||
.fieldlabel
|
||||
' We need your current password to confirm all of these changes
|
||||
|
||||
= submit "Save Account", class: "button"
|
||||
= submit "Save Account", class: "button"
|
||||
|
|
|
@ -16,7 +16,7 @@ h1 Register
|
|||
' You'll use your email address to log in, and we'll use this to get in
|
||||
' touch if we need to. Don't worry, we won't share this or spam you.
|
||||
.field
|
||||
= text_input f, :email, class: "input", placeholder: "Email", required: true
|
||||
= text_input f, :email, class: "input", placeholder: "Email", required: true, pattern: ".*@.*"
|
||||
= error_tag f, :email
|
||||
|
||||
.fieldlabel
|
||||
|
@ -47,4 +47,4 @@ h1 Register
|
|||
|
||||
br
|
||||
|
||||
= submit "Sign Up", class: "button"
|
||||
= submit "Sign Up", class: "button"
|
||||
|
|
|
@ -8,7 +8,7 @@ h1 Sign in
|
|||
p = link "Forgot your password?", to: Routes.pow_reset_password_reset_password_path(@conn, :new)
|
||||
|
||||
.field
|
||||
= text_input f, :email, class: "input", required: true, placeholder: "Email", autofocus: true
|
||||
= text_input f, :email, class: "input", required: true, placeholder: "Email", autofocus: true, pattern: ".*@.*"
|
||||
= error_tag f, :email
|
||||
|
||||
.field
|
||||
|
|
Loading…
Reference in a new issue