first commit
Some checks failed
Build Images and Deploy / Update-PROD-Stack (push) Failing after 14s
Some checks failed
Build Images and Deploy / Update-PROD-Stack (push) Failing after 14s
This commit is contained in:
30
src/views/partials/header.ejs
Normal file
30
src/views/partials/header.ejs
Normal file
@@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title><%= typeof title !== 'undefined' ? title + ' | Loot Hunt' : 'Loot Hunt' %></title>
|
||||
<link rel="stylesheet" href="/css/style.css">
|
||||
</head>
|
||||
<body>
|
||||
<nav class="navbar">
|
||||
<a href="/" class="navbar-brand">🎯 Loot Hunt</a>
|
||||
<ul class="navbar-nav">
|
||||
<li><a href="/hunts">Hunts</a></li>
|
||||
<li><a href="/leaderboard">Leaderboard</a></li>
|
||||
<% if (currentUser) { %>
|
||||
<% if (currentUser.isAdmin) { %>
|
||||
<li><a href="/admin">Admin</a></li>
|
||||
<% } %>
|
||||
<li><a href="/auth/logout">Logout (<%= currentUser.username %>)</a></li>
|
||||
<% } else { %>
|
||||
<li><a href="/auth/login">Login</a></li>
|
||||
<li><a href="/auth/register">Register</a></li>
|
||||
<% } %>
|
||||
</ul>
|
||||
</nav>
|
||||
<% if (typeof flash !== 'undefined' && flash) { %>
|
||||
<div class="container">
|
||||
<div class="alert alert-<%= flash.type %>"><%= flash.message %></div>
|
||||
</div>
|
||||
<% } %>
|
||||
Reference in New Issue
Block a user