From ca02fe9e30b821c0ab76d44890acb422e01b3afe Mon Sep 17 00:00:00 2001 From: Robin Schanbacher Date: Mon, 27 Jul 2026 15:10:59 +0200 Subject: [PATCH] style: allow props to the songs screen --- app/admin/page.tsx | 1 + components/DatabaseOverview.tsx | 12 ++++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/app/admin/page.tsx b/app/admin/page.tsx index 93983ab..9872fbd 100644 --- a/app/admin/page.tsx +++ b/app/admin/page.tsx @@ -232,6 +232,7 @@ export default function AdminPage() { console.log(song)} + className="w-[600px]" /> diff --git a/components/DatabaseOverview.tsx b/components/DatabaseOverview.tsx index 808f350..43561ca 100644 --- a/components/DatabaseOverview.tsx +++ b/components/DatabaseOverview.tsx @@ -1,9 +1,9 @@ -import { useState, useEffect } from "react"; +import { useState, useEffect, ComponentPropsWithoutRef } from "react"; import Card from "./Card" import { Input } from "./FormElements" -interface SongsProps { +interface SongsProps extends Omit, "title" | "children"> { onSelectSong?: (song: Song) => void; } @@ -20,7 +20,7 @@ interface Songbook { language: string; } -function Songs({onSelectSong}: SongsProps) { +function Songs({ onSelectSong, className = "", ...props }: SongsProps) { const [song_search_name, setSongSearchName] = useState(""); const [searchResults, setSearchResults] = useState([]); const [allSongs, setAllSongs] = useState([]); @@ -72,7 +72,11 @@ function Songs({onSelectSong}: SongsProps) { }, []); return ( - +