| Name | Message | Date |
|---|---|---|
| 📁 map | 1 month ago | |
| 📄 +layout.svelte | 1 month ago | |
| 📄 +page.svelte | 1 month ago |
📄
src/routes/history/+layout.svelte
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
73
74
75
76
77
78
79
80
81
82
<script lang="ts">
import { resolve } from "$app/paths";
import { page } from "$app/stores";
let { children } = $props();
</script>
{@render children()}
<nav class="sub">
<a
href={resolve("/history")}
aria-label="Detection log"
aria-current={$page.url.pathname === "/history" ? "page" : undefined}
>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true">
<rect x="2" y="5" width="20" height="3" rx="1.5" />
<rect x="2" y="11" width="20" height="3" rx="1.5" />
<rect x="2" y="17" width="14" height="3" rx="1.5" />
</svg>
</a>
<a
href={resolve("/history/map")}
aria-label="Sightings map"
aria-current={$page.url.pathname.startsWith("/history/map") ? "page" : undefined}
>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true">
<circle cx="12" cy="9" r="8" />
<polygon points="5,14 12,23 19,14" />
<circle cx="12" cy="9" r="3.5" fill="var(--bg-deep)" />
</svg>
</a>
</nav>
<style>
.sub {
position: fixed;
bottom: calc(var(--nav-height) + env(safe-area-inset-bottom));
left: 0;
right: 0;
height: 3rem;
background: var(--bg-deep);
border-top: 1px solid rgba(255, 244, 214, 0.08);
display: flex;
align-items: center;
justify-content: center;
gap: 3rem;
a {
position: relative;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
color: var(--bg-cream);
opacity: 0.5;
text-decoration: none;
padding: 0.25rem 0.5rem;
gap: 0.2rem;
transition: opacity 0.18s ease-out;
svg {
width: 1.25rem;
height: 1.25rem;
}
&:hover,
&:focus-visible,
&[aria-current="page"] {
opacity: 1;
}
&[aria-current="page"]::after {
content: "";
width: 0.3rem;
height: 0.3rem;
border-radius: 50%;
background: var(--brand-red);
}
}
}
</style>