add debug logging

This commit is contained in:
Michael Peters 2024-01-27 18:29:46 -08:00
parent a079b9b35b
commit c187a8625f

View File

@ -111,6 +111,10 @@ function useKeyPress(
) {
useEffect(() => {
const listener = (eventRaw: Event) => {
console.log('eventRaw', eventRaw);
console.log('callback', callback);
console.log('key', key);
console.log('ctrlKey', ctrlKey);
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const event = eventRaw as any as KeyboardEvent;
if (event.key === key && event.ctrlKey === ctrlKey) {