wip introduce shortcut to raise hand

This commit is contained in:
lebaudantoine
2025-06-02 18:36:17 +02:00
parent 7b61defe3c
commit f89bd8401c
@@ -9,6 +9,7 @@ import {
closeLowerHandToasts,
showLowerHandToast,
} from '@/features/notifications/utils'
import { useRegisterKeyboardShortcut } from '@/features/shortcuts/useRegisterKeyboardShortcut'
const SPEAKING_DETECTION_DELAY = 3000
@@ -24,6 +25,12 @@ export const HandToggle = () => {
const speakingTimerRef = useRef<NodeJS.Timeout | null>(null)
const [hasShownToast, setHasShownToast] = useState(false)
const shortcut = {
key: 'h',
ctrlKey: true,
}
useRegisterKeyboardShortcut({ shortcut, handler: toggleRaisedHand })
const resetToastState = () => {
setHasShownToast(false)
}