Commit fdfe1635b519db7a857ce661fa5a50d6577a3820

Authored by Renan Costa
Committed by Rafael Manzo
1 parent bf82d2bc

Sign In change of view, changing the div to display: block to display: inline

and the arrangement of components for better viewing of the content.

Signed off by: Renan Costa Filgueiras <renan2727@hotmail.com>
app/assets/stylesheets/boilerplate/main.css
@@ -94,10 +94,14 @@ textarea { @@ -94,10 +94,14 @@ textarea {
94 ========================================================================== */ 94 ========================================================================== */
95 95
96 96
  97 +.inline_div label{
  98 + display: inline-block;
  99 + margin-bottom: 0 20px;
  100 +}
97 101
98 -  
99 -  
100 - 102 +.inline_div input[type='checkbox']{
  103 + margin:0;
  104 +}
101 105
102 106
103 107
app/views/devise/sessions/new.html.erb
1 <div class="page-header"> 1 <div class="page-header">
2 - <h1>Sign In</h1> 2 + <h1>Log in to Mezuro</h1>
3 </div> 3 </div>
4 4
5 <%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %> 5 <%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %>
6 - <div><%= f.label :email %><br />  
7 - <%= f.email_field :email, :autofocus => true %></div> 6 + <div class="inline_div"><%= f.label :email %><br />
  7 + <%= f.email_field :email, :autofocus => true %><p></div>
8 8
9 - <div><%= f.label :password %><br /> 9 + <div class="inline_div"><%= f.label :password %> <a href="/users/password/new">(forgot password)</a> <br />
10 <%= f.password_field :password %></div> 10 <%= f.password_field :password %></div>
11 11
12 <% if devise_mapping.rememberable? -%> 12 <% if devise_mapping.rememberable? -%>
13 - <div><%= f.check_box :remember_me %> <%= f.label :remember_me %></div> 13 + <div class="inline_div"><%= f.check_box :remember_me %>&nbsp<%= f.label :remember_me %></div>
14 <% end -%> 14 <% end -%>
  15 +
  16 + <div><%= f.submit "Sign In", class: 'btn btn-primary' %>
  17 + <%= render "devise/shared/links" %> </div>
15 18
16 - <div><%= f.submit "Sign In", class: 'btn btn-primary' %></div>  
17 -<% end %>  
18 -  
19 -<%= render "devise/shared/links" %> 19 +<% end %>
20 \ No newline at end of file 20 \ No newline at end of file
app/views/devise/shared/_links.erb
@@ -6,9 +6,9 @@ @@ -6,9 +6,9 @@
6 <%= link_to "Sign Up", new_registration_path(resource_name), class: 'btn btn-info' %> 6 <%= link_to "Sign Up", new_registration_path(resource_name), class: 'btn btn-info' %>
7 <% end -%> 7 <% end -%>
8 8
9 -<%- if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations' %> 9 +<!-- <%- if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations' %>
10 <%= link_to "Forgot your password?", new_password_path(resource_name), class: 'btn btn-info' %> 10 <%= link_to "Forgot your password?", new_password_path(resource_name), class: 'btn btn-info' %>
11 -<% end -%> 11 +<% end -%> -->
12 12
13 <%- if devise_mapping.confirmable? && controller_name != 'confirmations' %> 13 <%- if devise_mapping.confirmable? && controller_name != 'confirmations' %>
14 <%= link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name), class: 'btn btn-info' %> 14 <%= link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name), class: 'btn btn-info' %>