I'm new to ruby and css. I want to create a navbar in my rails project where the links are going horizontally in a row. Right now they are listed vertically. In the materialize documentation, it showed that all I had to do was enter "right hide-on-med-and-down" for the class in <ul>
. However, that doesn't seem to be working for me.
What am I doing wrong? Any advice would be greatly appreciated.
Here is my application.html.erb file.
<!DOCTYPE html>
<html>
<head>
<title>PlacesToGo</title>
<%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true %>
<%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
<%= csrf_meta_tags %>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.98.1/css/materialize.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.98.1/js/materialize.min.js"></script>
</head>
<body>
<header>
<div class="navbar-wrapper">
<div class="container">
<a class="brand-logo" href="<%= root_url %>"/><h2>Places To Go</h2></a>
<ul id="nav-mobile" class="right hide-on-med-and-down">
<% if current_user %>
<li><%= link_to "Home", user_path(current_user)%></li>
<li><%= link_to "Sites", sites_path %></li>
<li><%= link_to "Restaurants", restaurants_path %></li>
<li><%= link_to "Hotels", hotels_path %></li>
<li><%= link_to "Log Out", logout_path %></li>
<br />
<%= form_tag(users_path, :method => "get", id: "search-form") do %>
<%= text_field_tag :search, params[:search], placeholder: "Search Users" %>
<%= submit_tag "Search", :name => nil %>
<% end %>
<% else %>
<li><%= link_to "Sign Up", new_user_path %></li>
<li><%= link_to "Sign In", signin_path %></li>
<% end %>
</ul>
</div>
</div>
</header>
</body>
</html>