mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-03-17 21:58:22 +03:00
fix: preserve other cameras' volume when adjusting one
setVolumeStates was replacing the entire state object instead of merging, so changing one camera's volume reset all others to default. Uses the functional update pattern to preserve existing state, matching how toggleAudio already works.
This commit is contained in:
parent
722ef6a1fe
commit
1cef9ebb08
@ -570,9 +570,10 @@ export default function LiveDashboardView({
|
||||
toggleStats={() => toggleStats(camera.name)}
|
||||
volumeState={volumeStates[camera.name] ?? 1}
|
||||
setVolumeState={(value) =>
|
||||
setVolumeStates({
|
||||
setVolumeStates((prev) => ({
|
||||
...prev,
|
||||
[camera.name]: value,
|
||||
})
|
||||
}))
|
||||
}
|
||||
muteAll={muteAll}
|
||||
unmuteAll={unmuteAll}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user