+13
-11
appview/pages/templates/layouts/topbar.html
+13
-11
appview/pages/templates/layouts/topbar.html
···
1
1
{{ define "layouts/topbar" }}
2
2
{{ $linkstyle := "text-gray-400 hover:text-gray-900 no-underline" }}
3
-
<nav class="flex justify-between px-6 space-x-4 mb-4 py-2 border-b border-black">
4
-
<div id="left-items">
5
-
<a href="/" hx-boost="true" class="{{ $linkstyle }} flex gap-2">
6
-
<i class="w-6 h-6" data-lucide="tangent"></i>
7
-
tangled.sh
8
-
</a>
9
-
</div>
10
-
<div id="right-items" class="flex gap-2">
11
-
{{ with .LoggedInUser }}
3
+
<nav class="space-x-4 mb-4 py-2 border-b border-black">
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 }}
12
13
<a href="/repo/new" hx-boost="true" class="{{ $linkstyle }}">
13
14
<i class="w-6 h-6" data-lucide="plus"></i>
14
15
</a>
···
18
19
<a href="/logout"class="{{ $linkstyle }}">
19
20
(logout)
20
21
</a>
21
-
{{ else }}
22
+
{{ else }}
22
23
<a href="/login" hx-boost="true" class="{{ $linkstyle }}">
23
24
login
24
25
</a>
25
-
{{ end }}
26
+
{{ end }}
27
+
</div>
26
28
</div>
27
29
</nav>
28
30
{{ end }}
-3
appview/resolver.go
-3
appview/resolver.go
···
31
31
results := make([]*identity.Identity, len(idents))
32
32
var wg sync.WaitGroup
33
33
34
-
// Create a channel to handle context cancellation
35
34
done := make(chan struct{})
36
35
defer close(done)
37
36
38
-
// Start a goroutine for each identifier
39
37
for idx, ident := range idents {
40
38
wg.Add(1)
41
39
go func(index int, id string) {
···
47
45
case <-done:
48
46
results[index] = nil
49
47
default:
50
-
// Resolve the identifier - if error, identity will be nil
51
48
identity, _ := r.ResolveIdent(ctx, id)
52
49
results[index] = identity
53
50
}