Mirror to Gitea / mirror (push) Skipped
Astro + React islands + MDX with a theme system (terminal, concrete, nostromo, overgrowth), USMT Dash case study, work/log/sound/models/about/ contact pages, RSS, self-hosted contact form over SMTP, /media proxy to Nextcloud, Dockerfile for Coolify, and a GitHub Action that mirrors main to Gitea.
75 lines
1.9 KiB
Plaintext
75 lines
1.9 KiB
Plaintext
---
|
|
import { getCollection } from 'astro:content';
|
|
import Base from '../layouts/Base.astro';
|
|
import AudioPlayer from '../components/AudioPlayer';
|
|
import { media } from '../lib/media';
|
|
|
|
const tracks = (await getCollection('sound')).sort((a, b) => +b.data.date - +a.data.date);
|
|
---
|
|
|
|
<Base title="Sound" description="Guitar and original music by Johan Sandoval." theme="nostromo">
|
|
<section class="wrap section">
|
|
<p class="label label--accent">// 03 — Audio logs</p>
|
|
<h1 class="glow">Sound</h1>
|
|
<p class="muted intro">Guitar, recordings and experiments. Self-hosted, no streaming service in the middle.</p>
|
|
|
|
<ol class="tracks">
|
|
{
|
|
tracks.map((t, i) => (
|
|
<li class="panel" data-tab={`Track ${String(i + 1).padStart(2, '0')}`}>
|
|
<div class="info">
|
|
<h2>{t.data.title}</h2>
|
|
<p class="label">
|
|
{t.data.date.toISOString().slice(0, 10)}
|
|
{t.data.gear.length > 0 && ` · ${t.data.gear.join(' · ')}`}
|
|
</p>
|
|
{t.data.notes && <p class="muted">{t.data.notes}</p>}
|
|
</div>
|
|
<AudioPlayer client:visible src={media(t.data.file)} title={t.data.title} />
|
|
</li>
|
|
))
|
|
}
|
|
</ol>
|
|
</section>
|
|
</Base>
|
|
|
|
<style>
|
|
h1 {
|
|
margin-block: var(--space-3);
|
|
}
|
|
.intro {
|
|
margin-bottom: var(--space-8);
|
|
}
|
|
.tracks {
|
|
display: grid;
|
|
gap: var(--space-8);
|
|
list-style: none;
|
|
padding: 0;
|
|
}
|
|
.info {
|
|
margin-bottom: var(--space-4);
|
|
}
|
|
h2 {
|
|
font-size: var(--step-2);
|
|
}
|
|
.tracks :global(.player) {
|
|
display: grid;
|
|
grid-template-columns: auto 1fr auto;
|
|
align-items: center;
|
|
gap: var(--space-4);
|
|
}
|
|
.tracks :global(.play) {
|
|
width: 3.25rem;
|
|
height: 3.25rem;
|
|
justify-content: center;
|
|
padding: 0;
|
|
font-size: 1rem;
|
|
}
|
|
.tracks :global(.wave) {
|
|
min-height: 64px;
|
|
display: grid;
|
|
align-items: center;
|
|
border-block: 1px dashed var(--line);
|
|
}
|
|
</style>
|