this repo has no description
1{{ define "layouts/topbar" }}
2 {{ $linkstyle := "text-gray-400 hover:text-gray-900 no-underline" }}
3 <nav class="space-x-4 mb-4 py-2 border-b border-gray-200">
4 <div class="container flex justify-between p-0">
5 <div id="left-items">
6 <a href="/" hx-boost="true" class="{{ $linkstyle }} flex gap-2">
7 <i class="w-6 h-6" data-lucide="tangent"></i>
8 tangled.sh
9 </a>
10 </div>
11 <div id="right-items" class="flex gap-2">
12 {{ with .LoggedInUser }}
13 <a href="/repo/new" hx-boost="true" class="{{ $linkstyle }}">
14 <i class="w-6 h-6" data-lucide="plus"></i>
15 </a>
16 <details class="relative inline-block text-left">
17 <summary class="{{ $linkstyle }} cursor-pointer list-none">
18 {{ didOrHandle .Did .Handle }}
19 </summary>
20 <div class="absolute flex flex-col right-0 mt-4 p-2 w-48 bg-white border border-gray-200 z-50">
21 <a href="/{{ didOrHandle .Did .Handle }}"class="{{ $linkstyle }}">profile</a>
22 <a href="/knots"class="{{ $linkstyle }}">knots</a>
23 <a href="/settings"class="{{ $linkstyle }}">settings</a>
24 <a href="/logout" class="text-red-400 hover:text-red-700 no-underline">logout</a>
25 </div>
26 </details>
27 {{ else }}
28 <a href="/login" class="{{ $linkstyle }}">
29 login
30 </a>
31 {{ end }}
32 </div>
33 </div>
34 </nav>
35{{ end }}