Skip to content

Commit

Permalink
better css
Browse files Browse the repository at this point in the history
  • Loading branch information
airled committed Apr 15, 2016
1 parent 052b833 commit 2327a68
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 16 deletions.
10 changes: 10 additions & 0 deletions app/assets/stylesheets/application.css
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,13 @@ hr {
.pagination, .pagination-sm{
margin-top: 0px;
}
ul {
margin: 0px;
}
.navbar {
margin-bottom: 0px;
}
.navbar-form {
border-top: 0px;
border-bottom: 0px;
}
2 changes: 1 addition & 1 deletion app/assets/stylesheets/bootstrap_and_overrides.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
Use Font Awesome icons (default)
To use Glyphicons sprites instead of Font Awesome, replace with "require twitter-bootstrap-static/sprites"
=require twitter-bootstrap-static/fontawesome
*/
*/
27 changes: 12 additions & 15 deletions app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
</head>
<body>

<!-- <div class="navbar navbar-default navbar-static-top"> -->
<div class="navbar navbar-default navbar-fixed-top">
<div class="navbar navbar-default 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">
<span class="icon-bar"></span>
Expand All @@ -48,23 +48,20 @@
</button>
<a class="navbar-brand" href="/">Railiner</a>

<div class="navbar-collapse collapse navbar-responsive-collapse">
<%= form_for :form, url: find_path, method: :get, :html => {"class" => 'navbar-form navbar-left form-inline'} do |f| %>
<div class="form-group">
<%= f.autocomplete_field :product, autocomplete_product_name_path, placeholder: "Найти продукт", class: "form-control" %>
</div>
<%= f.submit 'Найти', class: "btn btn-primary" %>
<%= f.check_box 'out' %> + не в продаже
<% end %>

<div class="navbar-collapse collapse navbar-responsive-collapse">
<ul class="nav navbar-nav">

<li><%= link_to "Группы", "/groups" %></li>
<li><%= link_to "Категории", "/categories" %></li>
<% if user_signed_in? && current_user.admin? %>
<li><%= link_to "Информация", "/info" %></li>
<% end %>
<%= form_for :form, url: find_path, method: :get, :html => {"class" => 'navbar-form navbar-left'} do |f| %>
<div class="form-group">
<%= f.autocomplete_field :product, autocomplete_product_name_path, placeholder: "Найти продукт", class: "form-control" %>
<%= f.submit 'Найти', class: "btn btn-primary" %>
<%= f.check_box 'out' %> + не в продаже
</div>
<% end %>
<li><%= link_to "Информация", "/info" if user_signed_in? && current_user.admin? %></li>

<% if user_signed_in? %>
<li><%= link_to current_user.email, users_profile_path %></li>
Expand All @@ -79,7 +76,7 @@
</div>
</div>

<div class="container" style="padding-top: 50px">
<div class="container">
<div class="row">
<div class="col-lg-12">
<%= bootstrap_flash %>
Expand Down

0 comments on commit 2327a68

Please sign in to comment.