initiation librodrome

This commit is contained in:
Yvv
2026-02-20 12:55:10 +01:00
commit 35e2897a73
208 changed files with 18951 additions and 0 deletions

24
app/types/book.ts Normal file
View File

@@ -0,0 +1,24 @@
export interface ChapterMeta {
slug: string
title: string
description?: string
order: number
readingTime?: string
}
export interface ChapterSongLink {
chapterSlug: string
songId: string
primary: boolean
}
export interface BookConfig {
title: string
author: string
description: string
coverImage?: string
chapters: ChapterMeta[]
songs: import('./song').Song[]
chapterSongs: ChapterSongLink[]
defaultPlaylistOrder: string[]
}

18
app/types/player.ts Normal file
View File

@@ -0,0 +1,18 @@
import type { Song } from './song'
export type PlayerMode = 'guided' | 'free'
export type RepeatMode = 'none' | 'one' | 'all'
export interface PlayerState {
isPlaying: boolean
currentSong: Song | null
currentTime: number
duration: number
volume: number
mode: PlayerMode
repeatMode: RepeatMode
isShuffled: boolean
playlist: Song[]
queue: Song[]
isExpanded: boolean
}

10
app/types/song.ts Normal file
View File

@@ -0,0 +1,10 @@
export interface Song {
id: string
title: string
artist: string
file: string
duration: number // seconds
coverImage?: string
lyrics?: string
tags: string[]
}