_navbar.html.erb 1.67 KB
Newer Older
Zac Wood's avatar
Zac Wood committed
1 2
<div class="container-fluid">
    <div class="row align-left align-sm-center align-md-right" id="navbar">
3
	<div class="col align-center">
Zac Wood's avatar
Zac Wood committed
4
	    <div class="center-vert">
Zac Wood's avatar
Zac Wood committed
5 6 7 8
		<a href="/" id="logo">
		    <i class="fas fa-calendar-alt"></i>
		    Schedules
		</a>
Zac Wood's avatar
Zac Wood committed
9
		&nbsp;&nbsp;
Zac Wood's avatar
Zac Wood committed
10
		<select id="semester-select">
Zac Wood's avatar
Zac Wood committed
11
		    <% Semester.all.each do |semester| %>
Zac Wood's avatar
Zac Wood committed
12 13 14 15
			<option value="<%= semester.id %>" <% if @semester == semester %> selected <% end %> >
			    <%= "#{semester.season} #{semester.year}" %>
			</option>
		    <% end %>
Zac Wood's avatar
Zac Wood committed
16
		</select>
Zac Wood's avatar
Zac Wood committed
17
	    </div>
Zac Wood's avatar
Zac Wood committed
18 19
	</div>

20 21 22 23 24 25 26 27 28 29
	<div class="col-sm align-center order-0 order-sm-1">
	    <a id="cart-button" href="<%= schedule_path %>">
		<h1 style="margin-top:24px">
		    <span class="fa-layers fa-fw" id="schedule-icon">
			<i class="fas fa-shopping-cart"></i>
			<span class="fa-layers fa-fw">
			    <i class="fas fa-circle" data-fa-transform="shrink-3 up-12 right-12" style="color:gray"></i>
			    <span id="course-counter" class="fa-layers-text fa-inverse" data-fa-transform="shrink-10 up-12 right-12" style="font-weight:600">
				<%= @cart.length %>
			    </span>
Zac Wood's avatar
Zac Wood committed
30 31
			</span>
		    </span>
32 33
		</h1>
	    </a>
Zac Wood's avatar
Zac Wood committed
34
	</div>
Zac Wood's avatar
Zac Wood committed
35

36
	<div class="col order-1 order-sm-0">
Zach Perkins's avatar
Zach Perkins committed
37
	    <form action="/search" class="form">
Zac Wood's avatar
Zac Wood committed
38
		<div class="input-group" style="width:100%;">
Zac Wood's avatar
Zac Wood committed
39 40 41 42 43 44
		    <input
			id="searchbar"
			value="<%= params[:query] %>"
			name="query"
			type="text"
			class="form-control"
Zac Wood's avatar
Zac Wood committed
45
			placeholder="Search course or professor..."
Zac Wood's avatar
Zac Wood committed
46 47 48
			aria-describedby="basic-addon2"
			autocomplete="off"
		    >
Zac Wood's avatar
Zac Wood committed
49 50 51 52
		    <div class="input-group-append">
			<button class="btn btn-secondary" type="button">
			    <i class="fas fa-search"></i>
			</button>
Zac Wood's avatar
Zac Wood committed
53
		    </div>
Zac Wood's avatar
Zac Wood committed
54 55 56 57 58
		</div>
	    </form>
	</div>
    </div>
</div>