From ab690bf36f6abd71a59447e50dd9db65c3a69384 Mon Sep 17 00:00:00 2001
From: Kevin
Date: Tue, 28 Sep 2010 06:12:30 +0800
Subject: [PATCH] Use Rails 3 email_field helper instead of text_field for
email
---
app/views/devise/confirmations/new.html.erb | 2 +-
app/views/devise/passwords/new.html.erb | 2 +-
app/views/devise/registrations/edit.html.erb | 2 +-
app/views/devise/registrations/new.html.erb | 2 +-
app/views/devise/sessions/new.html.erb | 2 +-
app/views/devise/unlocks/new.html.erb | 2 +-
6 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/app/views/devise/confirmations/new.html.erb b/app/views/devise/confirmations/new.html.erb
index 2dd5a7e6..da93af2b 100644
--- a/app/views/devise/confirmations/new.html.erb
+++ b/app/views/devise/confirmations/new.html.erb
@@ -4,7 +4,7 @@
<%= devise_error_messages! %>
<%= f.label :email %>
- <%= f.text_field :email %>
+ <%= f.email_field :email %>
<%= f.submit "Resend confirmation instructions" %>
<% end %>
diff --git a/app/views/devise/passwords/new.html.erb b/app/views/devise/passwords/new.html.erb
index b8819f15..42f3e64b 100644
--- a/app/views/devise/passwords/new.html.erb
+++ b/app/views/devise/passwords/new.html.erb
@@ -4,7 +4,7 @@
<%= devise_error_messages! %>
<%= f.label :email %>
- <%= f.text_field :email %>
+ <%= f.email_field :email %>
<%= f.submit "Send me reset password instructions" %>
<% end %>
diff --git a/app/views/devise/registrations/edit.html.erb b/app/views/devise/registrations/edit.html.erb
index 0f98acb8..7e192289 100644
--- a/app/views/devise/registrations/edit.html.erb
+++ b/app/views/devise/registrations/edit.html.erb
@@ -4,7 +4,7 @@
<%= devise_error_messages! %>
<%= f.label :email %>
- <%= f.text_field :email %>
+ <%= f.email_field :email %>
<%= f.label :password %> (leave blank if you don't want to change it)
<%= f.password_field :password %>
diff --git a/app/views/devise/registrations/new.html.erb b/app/views/devise/registrations/new.html.erb
index ae12ee75..46516e5f 100644
--- a/app/views/devise/registrations/new.html.erb
+++ b/app/views/devise/registrations/new.html.erb
@@ -4,7 +4,7 @@
<%= devise_error_messages! %>
<%= f.label :email %>
- <%= f.text_field :email %>
+ <%= f.email_field :email %>
<%= f.label :password %>
<%= f.password_field :password %>
diff --git a/app/views/devise/sessions/new.html.erb b/app/views/devise/sessions/new.html.erb
index 13902a52..d03def8e 100644
--- a/app/views/devise/sessions/new.html.erb
+++ b/app/views/devise/sessions/new.html.erb
@@ -2,7 +2,7 @@
<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %>
<%= f.label :email %>
- <%= f.text_field :email %>
+ <%= f.email_field :email %>
<%= f.label :password %>
<%= f.password_field :password %>
diff --git a/app/views/devise/unlocks/new.html.erb b/app/views/devise/unlocks/new.html.erb
index a7be7e44..905a3932 100644
--- a/app/views/devise/unlocks/new.html.erb
+++ b/app/views/devise/unlocks/new.html.erb
@@ -4,7 +4,7 @@
<%= devise_error_messages! %>
<%= f.label :email %>
- <%= f.text_field :email %>
+ <%= f.email_field :email %>
<%= f.submit "Resend unlock instructions" %>
<% end %>