Moved the navbar into a partial

This commit is contained in:
Gregory Ballantine 2022-12-10 01:10:28 -05:00
parent 4d76c0c072
commit f3e970ab1b
2 changed files with 9 additions and 8 deletions

View File

@ -11,14 +11,7 @@
</head> </head>
<body> <body>
<!-- Main navigation --> <!-- Main navigation -->
<nav id="main-nav"> <%= erb :'layout/navbar' %>
<h3>Raven</h3>
<ul>
<li><a href="/">Dashboard</a></li>
<li><a href="/item/list">Items</a></li>
<li><a href="/license/list">Licenses</a></li>
</ul>
</nav>
<div id="main-wrapper" class="container"> <div id="main-wrapper" class="container">
<%= yield %> <%= yield %>

8
views/layout/navbar.erb Normal file
View File

@ -0,0 +1,8 @@
<nav id="main-nav">
<h3>Raven</h3>
<ul>
<li><a href="/">Dashboard</a></li>
<li><a href="/item/list">Items</a></li>
<li><a href="/license/list">Licenses</a></li>
</ul>
</nav>