Skip to content

Commit

Permalink
assort
Browse files Browse the repository at this point in the history
  • Loading branch information
Sup2point0 committed Jul 12, 2024
1 parent 9fd6eaf commit 6d5c705
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .site/src/modules/stores/nav.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ export class NavData {
}


const nav = persisted("assort-nav", new NavData());
const nav = persisted<NavData>("assort-nav", new NavData());
export default nav;
4 changes: 2 additions & 2 deletions .site/src/parts/core/Nav.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { base } from "$app/paths";
import NavLink from "#parts/core/NavLink.svelte";
import NavButton from "#parts/ext/NavButton.svelte";
import navOpen from "#modules/stores/nav";
import nav from "#modules/stores/nav";
function redirectRandomPage() {
Expand All @@ -18,7 +18,7 @@ function redirectRandomPage() {
</script>


{#if $navOpen}
{#if $nav.open}
<nav>
<section id="top">
<img alt="Assort" src="{base}/assort-block.png">
Expand Down
5 changes: 3 additions & 2 deletions .site/src/parts/ext/NavButton.svelte
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
<script lang="ts">
import navOpen from "#modules/stores/nav";
import nav from "#modules/stores/nav";
export let action: "open" | "close" | "top";
const callbacks = {
open: () => navOpen.set(val => true),
open: () => nav.update(data => {data.open = true; return data}),
close: () => nav.update(data => {data.open = false; return data}),
}
const icons = {
Expand Down
5 changes: 0 additions & 5 deletions .site/src/styles/mixins/~interact.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,6 @@
background-color: $col-back-hover;
cursor: pointer;
}

&:focus {
background-color: $col-back-hover;
cursor: pointer;
}

&:active {
background-color: $col-back-active;
Expand Down
27 changes: 23 additions & 4 deletions .site/src/styles/pages/default.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
@use './src/styles/~nova' as *;
@use './src/styles/~variables' as *;
@use './src/styles/mixins/~fonts' as *;
@use './src/styles/mixins/~anim' as *;
@use './src/styles/mixins/~interact' as *;
@use './src/styles/mixins/~decorate' as *;
@use './src/styles/links' as *;
Expand Down Expand Up @@ -29,7 +30,7 @@ h2 {
}

h3 {
margin: 1.5em 0 1em;
margin: 1.5em 0 0.75em;
font-weight: 350;
font-size: 150%;
color: $blue-deep;
Expand All @@ -42,6 +43,7 @@ p {
margin: 1em 0;
@include font-body;
font-weight: 400;
color: $col-text;
line-height: 150%;
}

Expand All @@ -63,6 +65,7 @@ ul {
li {
@include font-body;
line-height: 150%;
color: $col-text;
}

table {
Expand All @@ -84,6 +87,7 @@ th {
td {
@include font-body;
font-weight: 400;
color: $col-text;
}

th {
Expand All @@ -95,24 +99,39 @@ th {
blockquote {
margin: 0;
padding-left: 1em;
color: $col-text-deut;
border-left: 2px solid $col-line;
}

details[open] {
p {
color: $col-text-deut;
}
}

details > :not(summary) {
opacity: 0;
transition: opacity 0.5s ease-out;
}
details[open] > :not(summary) {
opacity: 1;
transition: opacity 0.5s ease-out;
}

summary {
max-width: 10em;
margin-top: 1rem;
padding: 0.25em 0.5em;
vertical-align: middle;
border-radius: 0.5em;
@include interactive;

&::marker {
margin: 0;
padding: 0;
font-size: 75%;
}

> p, b {
padding-left: 0.5em;
}
}


Expand Down

0 comments on commit 6d5c705

Please sign in to comment.