Skip to content

Commit

Permalink
fix(ui): use localSoundState.loaded as criteria for visual active f…
Browse files Browse the repository at this point in the history
…eedback
  • Loading branch information
mateusfg7 committed Oct 25, 2023
1 parent a59e85e commit 84e9d11
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/sound/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ export const SoundButton: React.FC<SoundButtonProps> = ({ sound }) => {
<button
data-umami-event={sound.title}
className={soundButton({
active: localSoundState.active,
active: localSoundState.active && localSoundState.loaded,
isLoaded: localSoundState.loaded,
theme
})}
Expand All @@ -158,7 +158,7 @@ export const SoundButton: React.FC<SoundButtonProps> = ({ sound }) => {
<Icon className={icon()} />
</button>
<VolumeController
isActive={localSoundState.active}
isActive={localSoundState.active && localSoundState.loaded}
soundName={sound.title}
soundId={sound.id}
handleSoundVolume={volume => {
Expand Down

0 comments on commit 84e9d11

Please sign in to comment.