Skip to content

Commit

Permalink
change style
Browse files Browse the repository at this point in the history
  • Loading branch information
airled committed Apr 15, 2016
1 parent 58d6696 commit b212271
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 30 deletions.
38 changes: 20 additions & 18 deletions app/views/devise/registrations/new.html.erb
Original file line number Diff line number Diff line change
@@ -1,31 +1,33 @@
<h2>Регистрация</h2>

<%= form_for(resource, as: resource_name, url: registration_path(resource_name), :html => {:class => "form-inline"}) do |f| %>
<%= form_for(resource, as: resource_name, url: registration_path(resource_name), :html => {:class => "form-horizontal"}) do |f| %>
<%= devise_error_messages! %>

<div class="field">
<%= f.label :email %><br />
<%= f.email_field :email, autofocus: true %>
<div class="form-group">
<div class="col-lg-8">
<%= f.label 'Почта' %><br />
<%= f.email_field :email, autofocus: true, class: "form-control" %>
</div>
</div>

<div class="field">
<%= f.label :password %>
<% if @minimum_password_length %>
<em>(<%= @minimum_password_length %> characters minimum)</em>
<% end %><br />
<%= f.password_field :password, autocomplete: "off" %>
<div class="form-group">
<div class="col-lg-8">
<%= f.label 'Пароль' %>
<% if @minimum_password_length %>
<em>(<%= @minimum_password_length %> characters minimum)</em>
<% end %><br />
<%= f.password_field :password, autocomplete: "off", class: "form-control" %>
</div>
</div>

<div class="field">
<%= f.label :password_confirmation %><br />
<%= f.password_field :password_confirmation, autocomplete: "off" %>
<div class="form-group">
<div class="col-lg-8">
<%= f.label 'Подтвердите пароль' %><br />
<%= f.password_field :password_confirmation, autocomplete: "off", class: "form-control" %>
</div>
</div>

<div class="actions">
<%= f.submit "Sign up" %>
<%= f.submit "Зарегистрироваться", class: "btn btn-primary" %>
</div>
<% end %>

<!--
<%= render "devise/shared/links" %>
-->
22 changes: 11 additions & 11 deletions app/views/devise/sessions/new.html.erb
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
<h2>Войти</h2>

<%= form_for(resource, as: resource_name, url: session_path(resource_name), :html => {:class => "form-inline"}) do |f| %>
<%= form_for(resource, as: resource_name, url: session_path(resource_name), :html => {:class => "form-horizontal"}) do |f| %>

<div class="form-group">
<%= f.label "Почта" %>
<%= f.email_field :email, autofocus: true, class: "form-control", placeholder: "почта" %>
<div class="col-lg-8">
<%= f.label "Почта" %>
<%= f.email_field :email, autofocus: true, class: "form-control", placeholder: "почта" %>
</div>
</div>

<div class="form-group">
<%= f.label "Пароль" %>
<%= f.password_field :password, autocomplete: "off", class: "form-control", placeholder: "пароль" %>
<div class="col-lg-8">
<%= f.label "Пароль" %>
<%= f.password_field :password, autocomplete: "off", class: "form-control", placeholder: "пароль" %>
</div>
</div>

<%= f.submit "Войти", class: "btn btn-primary" %>
<% if devise_mapping.rememberable? -%>
<div class="form-group">
<%= f.check_box :remember_me %>
<%= f.label :remember_me %>
</div>
<% end %>
<% end %>
<%= f.submit "Войти", class: "btn btn-primary" %>
<!--
<%= render "devise/shared/links" %>
-->
<% end %>
2 changes: 1 addition & 1 deletion app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
</head>
<body>

<div class="navbar navbar-default navbar-static-top">
<div class="navbar navbar-invert navbar-static-top">
<!-- <div class="navbar navbar-default navbar-fixed-top"> -->
<div class="container">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-responsive-collapse">
Expand Down

0 comments on commit b212271

Please sign in to comment.