blob: 3e684935d79d6eacb1ecb039fdb2fe235d68be80 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
<?php global $isLoggedIn; global $isUserLoggedIn; global $demoHeader; global $pages; global $useNewUI; global $navigation; global $lang; global $pages; ?>
<?php if (!$useNewUI): ?>
<nav class="navbar navbar-expand-<?= $isLoggedIn ? 'xl' : 'lg' ?> bg-dark navbar-dark fixed-top" style="height:60px;">
<div class="container-fluid">
<a class="navbar-brand" href="/"><img src="/assets/logo/newlogo.png" alt="" style="width:32px;vertical-align: middle;margin-right:5px;">
<span style="vertical-align: middle;">Cold Haze</span>
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#collapsibleNavbar">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="collapsibleNavbar">
<ul class="navbar-nav">
<?php foreach ($navigation as $item): if (!$item["admin"] || $isLoggedIn): ?>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" role="button" data-bs-toggle="dropdown">
<img src="<?= $item["icon"] ?>" <?php if ($item["invert"]): ?>class="dropdown-icon"<?php endif; ?> alt="" style="width:24px;vertical-align: middle;">
<span style="vertical-align: middle;"><?= $item["name"] ?></span>
</a>
<ul class="dropdown-menu">
<?php foreach ($item["items"] as $category): ?>
<?php if (isset($category["name"])): ?>
<li><hr class="dropdown-divider"></li>
<li><h5 class="dropdown-header"><?= $category["name"] ?></h5></li>
<?php endif; ?>
<?php foreach ($category["items"] as $link): if (isset($link)): ?>
<li><a class="dropdown-item" href="<?= $link["link"] ?>">
<img src="<?= $link["icon"] ?>" <?php if ($link["invert"]): ?>class="dropdown-icon"<?php endif; ?> alt="" style="width:24px; border-radius: 5px; vertical-align: middle;">
<span style="vertical-align: middle;<?= isset($link["stepped"]) ? "color: $link[stepped];" : "" ?>"><?= isset($link["stepped"]) ? "<b>$link[name]</b>" : $link["name"] ?></span>
</a></li>
<?php endif; endforeach; ?>
<?php endforeach; ?>
</ul>
</li>
<?php endif; endforeach; ?>
<?php if ($isLoggedIn && !$useNewUI): ?>
<li class="nav-item" style="margin-left: auto;">
<a class="nav-link" href="/-/user">
<?php global $_PROFILE; ?>
<span style="vertical-align: middle;">
<?= $_PROFILE["name"] ?>
</span>
<img alt="" src="/assets/icons/shield.svg" style="filter:invert(1);width:24px;vertical-align: middle;">
</a>
</li>
<?php elseif ($isUserLoggedIn && !$useNewUI): ?>
<li class="nav-item" style="margin-left: auto;">
<a class="nav-link" href="/-/user">
<?php global $_PROFILE; ?>
<span style="vertical-align: middle;">
<?= $_PROFILE["name"] ?>
</span>
<img alt="" src="/assets/icons/shield.svg" style="filter:invert(1);width:24px;vertical-align: middle;">
</a>
</li>
<?php elseif (!$isLoggedIn && !$isUserLoggedIn): ?>
<li class="nav-item" style="<?php if (!$useNewUI): ?>margin-left: auto;<?php endif; ?>">
<a class="nav-link" href="/-/login">
<?php global $_PROFILE; ?>
<span style="vertical-align: middle;">
<?= $lang["navitation"]["login"] ?>
</span>
<img alt="" src="/assets/icons/login.svg" style="filter:invert(1);width:24px;vertical-align: middle;">
</a>
</li>
<?php endif; ?>
</ul>
</div>
</div>
</nav>
<?php endif; ?>
|