web/src/pages/search/index.astro
55 lines · 1128 bytes
1---
2
3import Layout from '@layouts/Layout.astro';
4import { fetchData } from '@utils/fetch-data';
5
6import Search from '@components/things/Search.svelte';
7
8const categories = (await fetchData())?.categories;
9
10---
11
12<Layout title="Search | Awesome Privacy">
13 <section>
14 <h1>Search</h1>
15 <Search client:visible data={categories} />
16 <p class="sitemap-link">Or, view all pages in the <a href="/sitemap">Sitemap</a></p>
17 </section>
18</Layout>
19
20
21<style lang="scss">
22
23section {
24 display: flex;
25 flex-direction: column;
26 padding: 1rem;
27 box-shadow: 4px 4px 0 var(--foreground);
28 background: var(--accent-fg);
29 border: 2px solid var(--foreground);
30 border-radius: var(--curve-sm);
31 margin: 2rem auto;
32 padding: 1rem;
33 width: calc(100% - 5rem);
34 max-width: 1100px;
35 min-height: 80vh;
36
37 h1 {
38 font-size: 3rem;
39 color: var(--accent-3);
40 font-family: "Lekton", sans-serif;
41 text-align: center;
42 margin: 1rem 0;
43 }
44 .sitemap-link {
45 opacity: 0.6;
46 text-align: center;
47 font-size: 0.8rem;
48 margin: 2rem auto;
49 transition: all 0.2s ease-in-out;
50 &:hover {
51 opacity: 0.8;
52 }
53 }
54}
55</style>