fix(context-menu): update all checkbox call sites to reactive subscribe+getChecked

This commit is contained in:
Jannis Braun
2026-03-24 21:48:26 +01:00
parent 7a25a2df7b
commit 0d91df166a
5 changed files with 10 additions and 10 deletions
@@ -492,12 +492,12 @@ export function MobileSpacesScreen() {
items.push({ key: 'mod-end-sep', type: 'separator' });
}
const isUserMuted = useVoiceStore.getState().participantMutes.get(userId) ?? false;
items.push({
key: 'mute-user',
type: 'checkbox',
label: 'Mute User',
checked: isUserMuted,
subscribe: useVoiceStore.subscribe,
getChecked: () => useVoiceStore.getState().participantMutes.get(userId) ?? false,
onChange: (checked) => useVoiceStore.getState().setParticipantMute(userId, checked),
});
@@ -123,12 +123,12 @@ export function MobileVoiceFullScreen() {
}
// Local mute checkbox
const isUserMuted = useVoiceStore.getState().participantMutes.get(userId) ?? false;
items.push({
key: 'mute-user',
type: 'checkbox',
label: 'Mute User',
checked: isUserMuted,
subscribe: useVoiceStore.subscribe,
getChecked: () => useVoiceStore.getState().participantMutes.get(userId) ?? false,
onChange: (checked) => useVoiceStore.getState().setParticipantMute(userId, checked),
});