Main #21

Merged
robin merged 37 commits from main into feat-dashboard 2026-07-29 10:48:35 +00:00
3 changed files with 6 additions and 3 deletions
Showing only changes of commit 1892314610 - Show all commits

No files matched your search

+2 -1
View File
@@ -231,8 +231,9 @@ export default function AdminPage() {
</Card>
</div>
<Screens.Songs
actionName="Auswählen"
onSelectSong={(song) => console.log(song)}
className="w-[600px]"
className="w-min"
/>
</div>
</div>
+1
View File
@@ -90,6 +90,7 @@ export default function SenderPage() {
return (
<Screens.Songs
actionName="Anzeigen"
onSelectSong={(song) => sendID(String(song.song_id), String(song.songbook_id))}
/>
);
+3 -2
View File
@@ -5,6 +5,7 @@ import { Input } from "./FormElements"
interface SongsProps extends Omit<ComponentPropsWithoutRef<typeof Card>, "title" | "children"> {
onSelectSong?: (song: Song) => void;
actionName?: string;
}
interface Song {
@@ -20,7 +21,7 @@ interface Songbook {
language: string;
}
function Songs({ onSelectSong, className = "", ...props }: SongsProps) {
function Songs({ actionName, onSelectSong, className = "", ...props }: SongsProps) {
const [song_search_name, setSongSearchName] = useState("");
const [searchResults, setSearchResults] = useState<Song[]>([]);
const [allSongs, setAllSongs] = useState<Song[]>([]);
@@ -123,7 +124,7 @@ function Songs({ onSelectSong, className = "", ...props }: SongsProps) {
onClick={() => onSelectSong?.(song)}
className="bg-white dark:bg-black hover:bg-blue-600 dark:hover:bg-blue-600 border border-neutral-300 dark:border-neutral-700 hover:border-blue-600 dark:hover:border-blue-500 hover:text-white font-medium rounded-md px-3 py-1.5 transition text-xs"
>
Anzeigen
{actionName}
</Input.Button>
</td>
</tr>