From 43b17d589c2e9d1f363eb114909f26396ae29a4c Mon Sep 17 00:00:00 2001 From: Renan Costa Date: Thu, 23 Jan 2014 11:37:08 -0200 Subject: [PATCH] Changing classes created "inline" to the corresponding classes of Bootstrap --- app/assets/stylesheets/boilerplate/main.css | 10 ---------- app/views/devise/sessions/new.html.erb | 39 +++++++++++++++++++++++++++++---------- app/views/devise/shared/_links.erb | 2 +- 3 files changed, 30 insertions(+), 21 deletions(-) diff --git a/app/assets/stylesheets/boilerplate/main.css b/app/assets/stylesheets/boilerplate/main.css index 3fa40ca..93798ae 100644 --- a/app/assets/stylesheets/boilerplate/main.css +++ b/app/assets/stylesheets/boilerplate/main.css @@ -94,16 +94,6 @@ textarea { ========================================================================== */ -.inline_div label{ - display: inline-block; - margin-bottom: 0 20px; -} - -.inline_div input[type='checkbox']{ - margin:0; -} - - diff --git a/app/views/devise/sessions/new.html.erb b/app/views/devise/sessions/new.html.erb index 944d57d..fd29160 100644 --- a/app/views/devise/sessions/new.html.erb +++ b/app/views/devise/sessions/new.html.erb @@ -2,18 +2,37 @@

Log in to Mezuro

-<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %> -
<%= f.label :email %>
- <%= f.email_field :email, :autofocus => true %>

-
<%= f.label :password %> (forgot password)
- <%= f.password_field :password %>
+<%= form_for(resource, :as => resource_name, :url => session_path(resource_name),:html => { :class => "form-inline" }) do |f| %> +
+ <%= f.label :email, :class => "control-label" %> +
+ <%= f.email_field :email, :autofocus => true%> +
+
+ +
+ <%= f.label :password, :class => "control-label" %> (forgot password) +
+ <%= f.password_field :password %> +
+
<% if devise_mapping.rememberable? -%> -
<%= f.check_box :remember_me %> <%= f.label :remember_me %>
+
+
+ +
+
<% end -%> - -
<%= f.submit "Sign In", class: 'btn btn-primary' %> - <%= render "devise/shared/links" %>
-<% end %> \ No newline at end of file +
+
+ <%= f.submit "Sign In", class: 'btn btn-primary span6' %> + <%= render "devise/shared/links" %> +
+
+ +<% end %> diff --git a/app/views/devise/shared/_links.erb b/app/views/devise/shared/_links.erb index 6971bc1..866394c 100644 --- a/app/views/devise/shared/_links.erb +++ b/app/views/devise/shared/_links.erb @@ -3,7 +3,7 @@ <% end -%> <%- if devise_mapping.registerable? && controller_name != 'registrations' %> - <%= link_to "Sign Up", new_registration_path(resource_name), class: 'btn btn-info' %> + <%= link_to "Sign Up", new_registration_path(resource_name), class: 'btn btn-info span6' %> <% end -%>