mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-06 20:10:12 +02:00
Disable action buttons when no song selected
This commit is contained in:
@@ -28,10 +28,13 @@ export const LyricsActions = ({ onRemoveLyric, onSearchOverride }: LyricsActions
|
||||
});
|
||||
};
|
||||
|
||||
const isActionsDisabled = !currentSong;
|
||||
|
||||
return (
|
||||
<>
|
||||
<Button
|
||||
uppercase
|
||||
disabled={isActionsDisabled}
|
||||
variant="subtle"
|
||||
onClick={() =>
|
||||
openLyricSearchModal({
|
||||
@@ -66,6 +69,7 @@ export const LyricsActions = ({ onRemoveLyric, onSearchOverride }: LyricsActions
|
||||
</Button>
|
||||
<Button
|
||||
uppercase
|
||||
disabled={isActionsDisabled}
|
||||
variant="subtle"
|
||||
onClick={onRemoveLyric}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user