Author SHA1 Message Date
YvvandClaude Opus 4.6 9cc51da807 Affiche le mot de passe admin sous la saisie en mode dev
Endpoint /api/admin/auth/hint (dev-only, 404 en prod via import.meta.dev).
Le hint est aussi éliminé côté client au build grâce à import.meta.dev.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 14:50:39 +01:00
YvvandClaude Opus 4.6 e48ed00f3f Ajout CLAUDE.md : conventions projet et ports dev
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 14:49:02 +01:00
YvvandClaude Opus 4.6 f4b7a092d3 Fix ports dev : librodrome→3000, grateWizard→3001
Évite les conflits de ports entre projets :
- nuxt.config.ts : devServer.port fixé à 3000
- app.config.ts : URL dev grateWizard corrigée 3009→3001

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-23 22:43:35 +01:00
17 changed files with 134 additions and 350 deletions

No files matched your search

+72
View File
@@ -0,0 +1,72 @@
# Librodrome
Site vitrine du projet Le Librodrome — livre + chansons sur l'économie du don.
## Stack
- **Nuxt 4** (Vue 3, TypeScript, Nitro)
- **Modules** : Nuxt Content, Pinia, UnoCSS, VueUse, Nuxt Image
- **Icônes** : Lucide + Phosphor (via @iconify-json)
- **Package manager** : pnpm
- **Déploiement** : Docker + Traefik, CI via Woodpecker
## Structure
```
app/
pages/ # Routes : index, lire/, ecouter/, autonomie, evenement, gratewizard, a-propos, admin/
components/ # admin, book, content, home, layout, player, song, ui
composables/ # useAudioPlayer, useBookData, useGrateWizard, usePlaylist, usePageContent, useSiteContent...
assets/css/ # main.css (UnoCSS)
data/
pages/ # Contenu YAML par page (home, lire, ecouter, autonomie, evenement...)
site.yml # Config globale du site
server/
api/ # Endpoints API (admin, health)
middleware/ # Auth middleware
docker/
Dockerfile # Build multi-stage (dev + prod)
docker-compose.yml # Production (Traefik)
docker-compose.dev.yml # Dev Docker
```
## Ports dev (CRITIQUE)
Chaque projet a un port fixe pour éviter les conflits Nuxt auto-increment :
| Projet | Port | Config |
|--------|------|--------|
| **librodrome** | **3000** | `nuxt.config.ts` → `devServer.port: 3000` |
| **GrateWizard** | **3001** | `package.json` → `next dev --port 3001` |
| **SejeteralO frontend** | **3009** | `frontend/nuxt.config.ts` → `devServer.port: 3009` |
| **SejeteralO backend** | **8000** | Makefile → `uvicorn --port 8000` |
Script de gestion : `/home/yvv/Documents/PROD/DEV/dev-ports.sh` (status/kill/clean/start)
**Ne jamais changer ces ports.** Si un port est occupé, tuer le process parasite plutôt que laisser Nuxt auto-incrémenter.
## Intégration GrateWizard
- URL dev configurée dans `app/app.config.ts` → `localhost:3001`
- URL prod : `https://gratewizard.ml`
- Ouverture en popup via `composables/useGrateWizard.ts`
- GrateWizard est un projet Next.js séparé (`/home/yvv/Documents/PROD/DEV/GrateWizard`)
## Contenu
Le contenu des pages est dans `data/pages/*.yml` et chargé via `composables/usePageContent.ts`. Le contenu riche (articles) utilise Nuxt Content avec des fichiers Markdown.
## Commandes
```bash
pnpm dev # Dev server sur :3000
pnpm build # Build production
pnpm generate # Génération statique
```
## Conventions
- Langue du site : français
- Commits en français, style concis
- CSS via UnoCSS (utility-first), pas de framework CSS externe
- Composants Vue SFC avec `<script setup lang="ts">`
+1 -1
View File
@@ -21,7 +21,7 @@ export default defineAppConfig({
], ],
}, },
gratewizard: { gratewizard: {
url: import.meta.dev ? 'http://localhost:3009' : 'https://gratewizard.ml', url: import.meta.dev ? 'http://localhost:3001' : 'https://gratewizard.ml',
popup: { popup: {
width: 420, width: 420,
height: 720, height: 720,
+1 -1
View File
@@ -22,7 +22,7 @@ useHead({
return title ? `${title} — Le Librodrome` : 'Le librodrome' return title ? `${title} — Le Librodrome` : 'Le librodrome'
}, },
meta: [ meta: [
{ name: 'description', content: 'Une économie du don — enfin concevable. Un livre et des chansons, lecture guidée et écoute libre.' }, { name: 'description', content: 'Une économie du don — enfin concevable. Un livre et 9 chansons, lecture guidée et écoute libre.' },
], ],
}) })
</script> </script>
-51
View File
@@ -29,40 +29,6 @@
<circle cx="185" cy="42" r="12" fill="currentColor" opacity="0.2"/> <circle cx="185" cy="42" r="12" fill="currentColor" opacity="0.2"/>
</svg> </svg>
<!-- Shadok menuisier: character with plane and plank -->
<svg class="shadok-menuisier" viewBox="0 0 240 300" fill="none" aria-hidden="true">
<!-- Body -->
<ellipse cx="120" cy="155" rx="40" ry="48" fill="currentColor" opacity="0.85"/>
<!-- Head -->
<circle cx="120" cy="92" r="25" fill="currentColor" opacity="0.8"/>
<!-- Carpenter cap -->
<path d="M98 82 Q120 68 142 82" fill="currentColor" opacity="0.35"/>
<rect x="100" y="80" width="40" height="5" rx="1" fill="currentColor" opacity="0.3"/>
<!-- Eyes (focused) -->
<circle cx="112" cy="90" r="4" fill="currentColor" opacity="0.2"/>
<circle cx="130" cy="90" r="4" fill="currentColor" opacity="0.2"/>
<circle cx="113" cy="89" r="1.8" fill="currentColor" opacity="0.5"/>
<circle cx="131" cy="89" r="1.8" fill="currentColor" opacity="0.5"/>
<!-- Concentrated mouth -->
<line x1="114" y1="103" x2="126" y2="103" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" opacity="0.3"/>
<!-- Arm with plane tool -->
<line x1="160" y1="145" x2="195" y2="160" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Plane tool -->
<rect x="190" y="155" width="30" height="12" rx="2" fill="currentColor" opacity="0.4"/>
<rect x="200" y="150" width="8" height="8" rx="1" fill="currentColor" opacity="0.35"/>
<!-- Other arm -->
<line x1="80" y1="148" x2="50" y2="168" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Legs -->
<line x1="105" y1="200" x2="95" y2="258" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<line x1="135" y1="200" x2="145" y2="258" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Wood plank (workbench) -->
<rect x="35" y="170" width="80" height="8" rx="1" fill="currentColor" opacity="0.3"/>
<!-- Wood shavings -->
<path d="M60 168 Q55 162 62 160" stroke="currentColor" stroke-width="1" stroke-linecap="round" fill="none" opacity="0.2"/>
<path d="M80 166 Q76 158 83 157" stroke="currentColor" stroke-width="1" stroke-linecap="round" fill="none" opacity="0.18"/>
<path d="M95 167 Q92 160 98 159" stroke="currentColor" stroke-width="1" stroke-linecap="round" fill="none" opacity="0.15"/>
</svg>
<div class="container-content"> <div class="container-content">
<div class="grid items-center gap-12 md:grid-cols-2"> <div class="grid items-center gap-12 md:grid-cols-2">
<!-- Book cover --> <!-- Book cover -->
@@ -169,24 +135,7 @@ const { data: content } = await usePageContent('home')
50% { transform: translateY(-8px); } 50% { transform: translateY(-8px); }
} }
.shadok-menuisier {
position: absolute;
left: 2%;
top: 5%;
width: clamp(100px, 13vw, 190px);
opacity: 0.25;
pointer-events: none;
color: hsl(var(--color-primary));
animation: shadok-float-menuisier 10s ease-in-out infinite;
}
@keyframes shadok-float-menuisier {
0%, 100% { transform: translateY(0); }
50% { transform: translateY(-9px); }
}
@media (max-width: 768px) { @media (max-width: 768px) {
.shadok-thinker { display: none; } .shadok-thinker { display: none; }
.shadok-menuisier { display: none; }
} }
</style> </style>
-48
View File
@@ -23,36 +23,6 @@
<path d="M48 105 Q25 102 12 100" stroke="currentColor" stroke-width="3" stroke-linecap="round" opacity="0.3" fill="none"/> <path d="M48 105 Q25 102 12 100" stroke="currentColor" stroke-width="3" stroke-linecap="round" opacity="0.3" fill="none"/>
</svg> </svg>
<!-- Shadok boulanger: character with oven and bread -->
<svg class="shadok-boulanger" viewBox="0 0 240 300" fill="none" aria-hidden="true">
<!-- Body -->
<ellipse cx="120" cy="155" rx="40" ry="48" fill="currentColor" opacity="0.85"/>
<!-- Head -->
<circle cx="120" cy="92" r="25" fill="currentColor" opacity="0.8"/>
<!-- Baker hat (toque) -->
<ellipse cx="120" cy="68" rx="18" ry="22" fill="currentColor" opacity="0.35"/>
<rect x="105" y="78" width="30" height="5" rx="1" fill="currentColor" opacity="0.4"/>
<!-- Eyes (happy) -->
<path d="M110 88 Q114 84 118 88" stroke="currentColor" stroke-width="2" stroke-linecap="round" fill="none" opacity="0.4"/>
<path d="M124 88 Q128 84 132 88" stroke="currentColor" stroke-width="2" stroke-linecap="round" fill="none" opacity="0.4"/>
<!-- Smile -->
<path d="M112 102 Q120 108 128 102" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" fill="none" opacity="0.35"/>
<!-- Arm holding bread -->
<line x1="160" y1="145" x2="190" y2="135" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Baguette -->
<rect x="185" y="125" width="40" height="10" rx="5" fill="currentColor" opacity="0.4" transform="rotate(-15 205 130)"/>
<!-- Other arm -->
<line x1="80" y1="148" x2="55" y2="175" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Legs -->
<line x1="105" y1="200" x2="95" y2="258" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<line x1="135" y1="200" x2="145" y2="258" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Oven (behind) -->
<rect x="30" y="180" width="50" height="40" rx="4" fill="currentColor" opacity="0.25"/>
<rect x="35" y="185" width="40" height="20" rx="2" fill="currentColor" opacity="0.15"/>
<!-- Oven glow -->
<ellipse cx="55" cy="195" rx="12" ry="6" fill="currentColor" opacity="0.12"/>
</svg>
<!-- Content --> <!-- Content -->
<div class="container-content relative z-10 px-4"> <div class="container-content relative z-10 px-4">
<div class="mx-auto max-w-3xl text-center"> <div class="mx-auto max-w-3xl text-center">
@@ -121,25 +91,7 @@ const { data: content } = await usePageContent('home')
50% { transform: translateY(-12px); } 50% { transform: translateY(-12px); }
} }
.shadok-boulanger {
position: absolute;
left: 3%;
bottom: 8%;
width: clamp(100px, 13vw, 190px);
opacity: 0.25;
pointer-events: none;
color: hsl(var(--color-accent));
animation: shadok-float-boulanger 9s ease-in-out infinite;
z-index: 1;
}
@keyframes shadok-float-boulanger {
0%, 100% { transform: translateY(0); }
50% { transform: translateY(-8px); }
}
@media (max-width: 768px) { @media (max-width: 768px) {
.shadok-bird { display: none; } .shadok-bird { display: none; }
.shadok-boulanger { display: none; }
} }
</style> </style>
-56
View File
@@ -1,5 +1,4 @@
<template> <template>
<div class="song-item-wrapper">
<div <div
class="card-surface flex cursor-pointer items-center gap-4" class="card-surface flex cursor-pointer items-center gap-4"
:class="{ 'border-primary/40! shadow-primary/10!': isCurrent }" :class="{ 'border-primary/40! shadow-primary/10!': isCurrent }"
@@ -30,30 +29,11 @@
</p> </p>
</div> </div>
<!-- Lyrics toggle -->
<button
v-if="song.lyrics"
class="flex-shrink-0 p-1.5 rounded transition-colors text-white/30 hover:text-white/60"
:class="{ 'text-primary/60!': showLyrics }"
@click.stop="showLyrics = !showLyrics"
aria-label="Afficher les paroles"
>
<div class="i-lucide-text h-4 w-4" />
</button>
<!-- Duration --> <!-- Duration -->
<span class="font-mono text-xs text-white/30 flex-shrink-0"> <span class="font-mono text-xs text-white/30 flex-shrink-0">
{{ formatDuration(song.duration) }} {{ formatDuration(song.duration) }}
</span> </span>
</div> </div>
<!-- Lyrics panel -->
<Transition name="lyrics-slide">
<div v-if="showLyrics && song.lyrics" class="lyrics-panel">
<pre class="lyrics-text">{{ song.lyrics }}</pre>
</div>
</Transition>
</div>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
@@ -67,7 +47,6 @@ const store = usePlayerStore()
const { loadAndPlay, togglePlayPause } = useAudioPlayer() const { loadAndPlay, togglePlayPause } = useAudioPlayer()
const isCurrent = computed(() => store.currentSong?.id === props.song.id) const isCurrent = computed(() => store.currentSong?.id === props.song.id)
const showLyrics = ref(false)
function handlePlay() { function handlePlay() {
if (isCurrent.value) { if (isCurrent.value) {
@@ -84,38 +63,3 @@ function formatDuration(seconds: number): string {
return `${mins}:${secs.toString().padStart(2, '0')}` return `${mins}:${secs.toString().padStart(2, '0')}`
} }
</script> </script>
<style scoped>
.lyrics-panel {
margin-top: 0.25rem;
padding: 1rem 1.25rem;
border-radius: 0.75rem;
background: hsl(var(--color-surface));
border: 1px solid hsl(var(--color-text) / 0.08);
max-height: 24rem;
overflow-y: auto;
}
.lyrics-text {
white-space: pre-wrap;
font-family: inherit;
font-size: 0.875rem;
line-height: 1.7;
color: hsl(var(--color-text) / 0.6);
}
.lyrics-slide-enter-active,
.lyrics-slide-leave-active {
transition: all 0.3s ease;
overflow: hidden;
}
.lyrics-slide-enter-from,
.lyrics-slide-leave-to {
max-height: 0;
opacity: 0;
padding-top: 0;
padding-bottom: 0;
margin-top: 0;
}
</style>
+2 -2
View File
@@ -12,7 +12,7 @@
</button> </button>
<Transition name="lyrics-expand"> <Transition name="lyrics-expand">
<div v-if="isOpen" class="mt-4 max-h-96 overflow-y-auto"> <div v-if="isOpen" class="mt-4">
<pre class="whitespace-pre-wrap font-sans text-sm leading-relaxed text-white/60">{{ song.lyrics }}</pre> <pre class="whitespace-pre-wrap font-sans text-sm leading-relaxed text-white/60">{{ song.lyrics }}</pre>
</div> </div>
</Transition> </Transition>
@@ -44,7 +44,7 @@ const isOpen = ref(false)
.lyrics-expand-enter-to, .lyrics-expand-enter-to,
.lyrics-expand-leave-from { .lyrics-expand-leave-from {
max-height: 600px; max-height: 500px;
opacity: 1; opacity: 1;
} }
</style> </style>
+25
View File
@@ -22,6 +22,10 @@
<div v-if="loading" class="i-lucide-loader-2 h-4 w-4 animate-spin" /> <div v-if="loading" class="i-lucide-loader-2 h-4 w-4 animate-spin" />
Se connecter Se connecter
</button> </button>
<p v-if="devHint" class="dev-hint">
Dev : <code>{{ devHint }}</code>
</p>
</form> </form>
</div> </div>
</template> </template>
@@ -34,6 +38,13 @@ definePageMeta({
const password = ref('') const password = ref('')
const error = ref('') const error = ref('')
const loading = ref(false) const loading = ref(false)
const devHint = ref('')
if (import.meta.dev) {
$fetch('/api/admin/auth/hint').then((res: any) => {
devHint.value = res.password
}).catch(() => {})
}
async function login() { async function login() {
error.value = '' error.value = ''
@@ -131,4 +142,18 @@ async function login() {
opacity: 0.7; opacity: 0.7;
cursor: wait; cursor: wait;
} }
.dev-hint {
margin-top: 1rem;
text-align: center;
font-size: 0.75rem;
color: hsl(20 8% 40%);
}
.dev-hint code {
color: hsl(12 76% 60%);
background: hsl(20 8% 10%);
padding: 0.125rem 0.375rem;
border-radius: 0.25rem;
}
</style> </style>
+5 -115
View File
@@ -1,35 +1,5 @@
<template> <template>
<div class="relative overflow-hidden section-padding"> <div class="relative overflow-hidden section-padding">
<!-- Shadok danseur: character dancing with music notes -->
<svg class="shadok-danseur" viewBox="0 0 240 300" fill="none" aria-hidden="true">
<!-- Body (dynamic pose, leaning) -->
<ellipse cx="120" cy="155" rx="38" ry="46" fill="currentColor" opacity="0.85"/>
<!-- Head (tilted with joy) -->
<ellipse cx="125" cy="92" rx="24" ry="23" fill="currentColor" opacity="0.8"/>
<!-- Eyes (happy, squinted) -->
<path d="M114 88 Q118 84 122 88" stroke="currentColor" stroke-width="2" stroke-linecap="round" fill="none" opacity="0.4"/>
<path d="M130 88 Q134 84 138 88" stroke="currentColor" stroke-width="2" stroke-linecap="round" fill="none" opacity="0.4"/>
<!-- Big smile -->
<path d="M116 100 Q125 108 134 100" stroke="currentColor" stroke-width="2" stroke-linecap="round" fill="none" opacity="0.35"/>
<!-- Arms thrown up (dancing) -->
<line x1="85" y1="140" x2="50" y2="100" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<line x1="155" y1="140" x2="190" y2="105" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Hands -->
<circle cx="50" cy="98" r="4" fill="currentColor" opacity="0.4"/>
<circle cx="190" cy="103" r="4" fill="currentColor" opacity="0.4"/>
<!-- Legs (one kicked up) -->
<line x1="105" y1="198" x2="80" y2="255" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<line x1="135" y1="198" x2="170" y2="240" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Feet -->
<path d="M80 255 L68 258 M80 255 L75 261" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" opacity="0.5"/>
<path d="M170 240 L180 238 M170 240 L175 246" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" opacity="0.5"/>
<!-- Music notes floating around -->
<text x="42" y="82" fill="currentColor" opacity="0.3" font-size="18">&#9834;</text>
<text x="195" y="88" fill="currentColor" opacity="0.25" font-size="16">&#9835;</text>
<text x="60" y="65" fill="currentColor" opacity="0.2" font-size="14">&#9833;</text>
<text x="180" y="72" fill="currentColor" opacity="0.2" font-size="20">&#9834;</text>
</svg>
<!-- Shadok DJ: character with headphones behind a turntable --> <!-- Shadok DJ: character with headphones behind a turntable -->
<svg class="shadok-dj" viewBox="0 0 260 300" fill="none" aria-hidden="true"> <svg class="shadok-dj" viewBox="0 0 260 300" fill="none" aria-hidden="true">
<!-- Body --> <!-- Body -->
@@ -53,7 +23,7 @@
<line x1="170" y1="150" x2="205" y2="195" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/> <line x1="170" y1="150" x2="205" y2="195" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Turntable body --> <!-- Turntable body -->
<rect x="30" y="200" width="200" height="18" rx="4" fill="currentColor" opacity="0.4"/> <rect x="30" y="200" width="200" height="18" rx="4" fill="currentColor" opacity="0.4"/>
<!-- Turntable platter --> <!-- Turntable platter (ellipse for perspective) -->
<ellipse cx="130" cy="200" rx="55" ry="15" fill="currentColor" opacity="0.25"/> <ellipse cx="130" cy="200" rx="55" ry="15" fill="currentColor" opacity="0.25"/>
<ellipse cx="130" cy="200" rx="55" ry="15" stroke="currentColor" stroke-width="1.5" fill="none" opacity="0.35"/> <ellipse cx="130" cy="200" rx="55" ry="15" stroke="currentColor" stroke-width="1.5" fill="none" opacity="0.35"/>
<!-- Record center --> <!-- Record center -->
@@ -67,38 +37,15 @@
</svg> </svg>
<div class="container-content"> <div class="container-content">
<!-- Hero section with book cover --> <header class="mb-12 text-center">
<div class="mb-12 grid items-center gap-8 md:grid-cols-2">
<div class="book-cover-wrapper">
<div class="book-cover-3d">
<img
:src="homeContent?.book.coverImage"
:alt="homeContent?.book.coverAlt"
class="book-cover-img"
/>
</div>
</div>
<div class="text-center md:text-left">
<p class="mb-2 font-mono text-sm tracking-widest text-accent uppercase">{{ content?.kicker }}</p> <p class="mb-2 font-mono text-sm tracking-widest text-accent uppercase">{{ content?.kicker }}</p>
<h1 class="page-title font-display font-bold tracking-tight text-white"> <h1 class="page-title font-display font-bold tracking-tight text-white">
{{ content?.title }} {{ content?.title }}
</h1> </h1>
<p class="mt-4 text-white/60"> <p class="mt-4 mx-auto max-w-2xl text-white/60">
{{ content?.description }} {{ content?.description }}
</p> </p>
<div class="mt-6 flex flex-col gap-3 sm:flex-row sm:gap-4 justify-center md:justify-start"> </header>
<UiBaseButton @click="showBookPlayer = true">
<div class="i-lucide-play mr-2 h-5 w-5" />
Présentation musicale
</UiBaseButton>
<UiBaseButton variant="accent" @click="showPdfReader = true">
<div class="i-lucide-book-open mr-2 h-5 w-5" />
Lire le livre
</UiBaseButton>
</div>
</div>
</div>
<!-- Search + view toggle --> <!-- Search + view toggle -->
<div class="mb-6 flex items-center justify-between gap-4"> <div class="mb-6 flex items-center justify-between gap-4">
@@ -152,9 +99,6 @@
{{ content?.noResults }} {{ content?.noResults }}
</p> </p>
</div> </div>
<BookPlayer v-model="showBookPlayer" />
<BookPdfReader v-model="showPdfReader" />
</div> </div>
</template> </template>
@@ -164,10 +108,9 @@ definePageMeta({
}) })
const { data: content } = await usePageContent('ecouter') const { data: content } = await usePageContent('ecouter')
const { data: homeContent } = await usePageContent('home')
useHead({ useHead({
title: content.value?.meta?.title ?? 'En musique', title: content.value?.meta?.title ?? 'Écouter',
}) })
const store = usePlayerStore() const store = usePlayerStore()
@@ -182,8 +125,6 @@ await loadFullPlaylist()
const search = ref('') const search = ref('')
const viewMode = ref<'list' | 'grid'>('list') const viewMode = ref<'list' | 'grid'>('list')
const showBookPlayer = ref(false)
const showPdfReader = ref(false)
const filteredSongs = computed(() => { const filteredSongs = computed(() => {
const songs = bookData.getSongs() const songs = bookData.getSongs()
@@ -203,50 +144,6 @@ const filteredSongs = computed(() => {
font-size: clamp(2rem, 5vw, 2.75rem); font-size: clamp(2rem, 5vw, 2.75rem);
} }
.book-cover-wrapper {
perspective: 800px;
display: flex;
justify-content: center;
}
.book-cover-3d {
aspect-ratio: 3 / 4;
border-radius: 0.75rem;
overflow: hidden;
border: 1px solid hsl(var(--color-text) / 0.1);
box-shadow:
0 12px 40px hsl(var(--color-text) / 0.15),
0 0 0 1px hsl(var(--color-text) / 0.08);
transition: transform 0.5s cubic-bezier(0.645, 0.045, 0.355, 1),
box-shadow 0.5s ease;
max-width: 280px;
}
.book-cover-3d:hover {
transform: rotateY(-8deg) rotateX(3deg) scale(1.02);
box-shadow:
12px 16px 48px hsl(var(--color-text) / 0.2),
0 0 0 1px hsl(var(--color-primary) / 0.2);
}
.book-cover-img {
width: 200%;
height: 100%;
object-fit: cover;
transform: translateX(-50%);
}
.shadok-danseur {
position: absolute;
left: 2%;
top: 3%;
width: clamp(100px, 14vw, 200px);
opacity: 0.28;
pointer-events: none;
color: hsl(var(--color-primary));
animation: shadok-float-danseur 7s ease-in-out infinite;
}
.shadok-dj { .shadok-dj {
position: absolute; position: absolute;
right: 2%; right: 2%;
@@ -258,19 +155,12 @@ const filteredSongs = computed(() => {
animation: shadok-float-dj 8s ease-in-out infinite; animation: shadok-float-dj 8s ease-in-out infinite;
} }
@keyframes shadok-float-danseur {
0%, 100% { transform: translateY(0) rotate(0deg); }
25% { transform: translateY(-8px) rotate(2deg); }
75% { transform: translateY(-4px) rotate(-2deg); }
}
@keyframes shadok-float-dj { @keyframes shadok-float-dj {
0%, 100% { transform: translateY(0); } 0%, 100% { transform: translateY(0); }
50% { transform: translateY(-10px); } 50% { transform: translateY(-10px); }
} }
@media (max-width: 768px) { @media (max-width: 768px) {
.shadok-danseur { display: none; }
.shadok-dj { display: none; } .shadok-dj { display: none; }
} }
</style> </style>
-55
View File
@@ -49,43 +49,6 @@
<circle cx="87" cy="29" r="1.5" fill="currentColor" opacity="0.3"/> <circle cx="87" cy="29" r="1.5" fill="currentColor" opacity="0.3"/>
</svg> </svg>
<!-- Shadok scribe: character with quill and inkwell -->
<svg class="shadok-scribe" viewBox="0 0 240 280" fill="none" aria-hidden="true">
<!-- Body (seated) -->
<ellipse cx="120" cy="155" rx="40" ry="48" fill="currentColor" opacity="0.85"/>
<!-- Head -->
<circle cx="120" cy="92" r="25" fill="currentColor" opacity="0.8"/>
<!-- Small beret -->
<ellipse cx="120" cy="72" rx="20" ry="8" fill="currentColor" opacity="0.35"/>
<!-- Eyes (focused on writing) -->
<circle cx="112" cy="90" r="4" fill="currentColor" opacity="0.2"/>
<circle cx="130" cy="90" r="4" fill="currentColor" opacity="0.2"/>
<circle cx="113" cy="91" r="1.8" fill="currentColor" opacity="0.5"/>
<circle cx="131" cy="91" r="1.8" fill="currentColor" opacity="0.5"/>
<!-- Tongue out (concentrating) -->
<path d="M118 104 Q120 108 122 104" fill="currentColor" opacity="0.3"/>
<!-- Arm with quill -->
<line x1="160" y1="140" x2="190" y2="170" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Quill -->
<line x1="190" y1="170" x2="210" y2="145" stroke="currentColor" stroke-width="2" stroke-linecap="round" opacity="0.45"/>
<path d="M210 145 Q215 140 212 135 Q208 138 210 145" fill="currentColor" opacity="0.3"/>
<!-- Other arm -->
<line x1="80" y1="148" x2="55" y2="180" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" opacity="0.6"/>
<!-- Legs (seated) -->
<path d="M100 200 Q90 230 95 250" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" fill="none" opacity="0.6"/>
<path d="M140 200 Q150 230 145 250" stroke="currentColor" stroke-width="3.5" stroke-linecap="round" fill="none" opacity="0.6"/>
<!-- Inkwell -->
<rect x="45" y="185" width="20" height="18" rx="3" fill="currentColor" opacity="0.35"/>
<ellipse cx="55" cy="185" rx="12" ry="4" fill="currentColor" opacity="0.3"/>
<!-- Ink splash -->
<circle cx="50" cy="182" r="2" fill="currentColor" opacity="0.2"/>
<!-- Scroll/paper -->
<rect x="170" y="175" width="40" height="50" rx="2" fill="currentColor" opacity="0.2"/>
<line x1="178" y1="188" x2="202" y2="188" stroke="currentColor" stroke-width="1" opacity="0.15"/>
<line x1="178" y1="195" x2="200" y2="195" stroke="currentColor" stroke-width="1" opacity="0.15"/>
<line x1="178" y1="202" x2="198" y2="202" stroke="currentColor" stroke-width="1" opacity="0.15"/>
</svg>
<div class="container-content"> <div class="container-content">
<header class="mb-12 text-center"> <header class="mb-12 text-center">
<p class="mb-2 font-mono text-sm tracking-widest text-primary uppercase">{{ content?.kicker }}</p> <p class="mb-2 font-mono text-sm tracking-widest text-primary uppercase">{{ content?.kicker }}</p>
@@ -187,26 +150,8 @@ const { data: chapters } = await useAsyncData('book-toc', () =>
50% { transform: translateY(-8px) rotate(-2deg); } 50% { transform: translateY(-8px) rotate(-2deg); }
} }
.shadok-scribe {
position: absolute;
left: 50%;
bottom: 3%;
transform: translateX(-50%);
width: clamp(100px, 13vw, 180px);
opacity: 0.25;
pointer-events: none;
color: hsl(var(--color-primary));
animation: shadok-float-scribe 10s ease-in-out infinite;
}
@keyframes shadok-float-scribe {
0%, 100% { transform: translateX(-50%) translateY(0); }
50% { transform: translateX(-50%) translateY(-8px); }
}
@media (max-width: 768px) { @media (max-width: 768px) {
.shadok-reader { display: none; } .shadok-reader { display: none; }
.shadok-stack { display: none; } .shadok-stack { display: none; }
.shadok-scribe { display: none; }
} }
</style> </style>
+4 -4
View File
@@ -1,7 +1,7 @@
kicker: Le livre en musique kicker: Écoute libre
title: Des chansons qui racontent le livre title: Les 9 chansons
description: Chaque chanson est un prolongement musical d'un ou deux chapitres. description: Ecoutez librement les chansons qui racontent le livre.
searchPlaceholder: Rechercher une chanson... searchPlaceholder: Rechercher une chanson...
noResults: Aucune chanson ne correspond à votre recherche. noResults: Aucune chanson ne correspond à votre recherche.
meta: meta:
title: En musique title: Écouter
+1 -1
View File
@@ -30,7 +30,7 @@ bookPresentation:
to: /lire to: /lire
songs: songs:
kicker: Les chansons kicker: Les chansons
title: Des chansons qui racontent le livre title: 9 chansons qui racontent le livre
description: Chaque chanson est un prolongement musical d'un ou deux chapitres. description: Chaque chanson est un prolongement musical d'un ou deux chapitres.
cta: cta:
label: Voir toutes les chansons label: Voir toutes les chansons
+2 -2
View File
@@ -1,6 +1,6 @@
kicker: Le livre kicker: Le livre
title: Un modèle économique title: Table des matières
description: Quelques chapitres pour explorer les fondements d'une économie du don, accompagnés de chansons qui le description: Quelques chapitres pour explorer les fondements d'une économie du don, accompagnés de chansons qui le
racontent autrement. racontent autrement.
meta: meta:
title: Un modèle économique title: Table des matières
+5 -7
View File
@@ -1,16 +1,14 @@
identity: identity:
name: Le Librodrome name: Le Librodrome
description: Une économie du don — enfin concevable. Un livre et des chansons, lecture accompagnée et écoute libre. description: Une économie du don — enfin concevable. Un livre et 9 chansons, lecture accompagnée et écoute libre.
url: https://librodrome.org url: https://librodrome.org
navigation: navigation:
- label: Autonomie - label: Accueil
to: /autonomie to: /
- label: Modèle éco - label: Lire
to: /lire to: /lire
- label: En musique - label: Écouter
to: /ecouter to: /ecouter
- label: Évènement
to: /evenement
- label: À propos - label: À propos
to: /a-propos to: /a-propos
footer: footer:
+4 -7
View File
@@ -11,15 +11,13 @@ WORKDIR /src
# Build # Build
FROM base AS build FROM base AS build
RUN corepack enable
COPY package.json pnpm-lock.yaml ./ COPY package.json pnpm-lock.yaml ./
RUN pnpm install --frozen-lockfile RUN npm install
RUN pnpm rebuild sharp RUN npm rebuild sharp
COPY . . COPY . .
RUN pnpm run build RUN npm run build
# Production # Production
FROM base AS production FROM base AS production
@@ -39,5 +37,4 @@ CMD [ "node", ".output/server/index.mjs" ]
FROM base AS development FROM base AS development
WORKDIR /app WORKDIR /app
RUN corepack enable ENTRYPOINT [ "npm", "run", "dev" ]
ENTRYPOINT [ "pnpm", "run", "dev" ]
+4
View File
@@ -4,6 +4,10 @@ export default defineNuxtConfig({
devtools: { enabled: true }, devtools: { enabled: true },
devServer: {
port: 3000,
},
modules: [ modules: [
'@nuxt/content', '@nuxt/content',
'@pinia/nuxt', '@pinia/nuxt',
+8
View File
@@ -0,0 +1,8 @@
export default defineEventHandler(() => {
if (!import.meta.dev) {
throw createError({ statusCode: 404, statusMessage: 'Not found' })
}
const config = useRuntimeConfig()
return { password: config.adminPassword }
})