keyboard stuff, styling things

This commit is contained in:
2023-09-25 18:12:34 +02:00
parent c93246ee8c
commit d8f0679233
20 changed files with 247 additions and 236 deletions

View File

@@ -1,5 +1,6 @@
<script>
import {page} from "$app/stores"
import {action} from "$lib/title"
import LL from "../i18n/i18n-svelte"
$: paths = [
@@ -10,8 +11,8 @@
</script>
<nav>
{#each paths as { href, title, icon }}
<a {href} class:active={$page.url.pathname.startsWith(href)}>
{#each paths as { href, title, icon }, i}
<a {href} class:active={$page.url.pathname.startsWith(href)} use:action={{shortcut: `shift+${i + 1}`}}>
<span class="icon">{icon}</span>
{title}
</a>
@@ -27,30 +28,13 @@
padding: 8px;
color: var(--md-sys-color-on-surface-variant);
background: var(--md-sys-color-surface-variant);
border: none;
border-radius: 32px;
}
a {
display: flex;
gap: 4px;
align-items: center;
justify-content: center;
margin: 0;
padding: 8px;
padding-inline: 16px;
font-weight: 600;
color: var(--md-sys-color-on-surface-variant);
text-decoration: none;
border-radius: 24px;
transition: all 250ms ease;
}
a.active {
--icon-fill: 1;