Hotkey labels

This commit is contained in:
Gregory Schier
2024-01-08 15:57:21 -08:00
parent 793bff9f27
commit d5855c45a6
5 changed files with 42 additions and 30 deletions

View File

@@ -0,0 +1,11 @@
import type { HotkeyAction } from '../../hooks/useHotkey';
import { useHotKeyLabel } from '../../hooks/useHotkey';
interface Props {
action: HotkeyAction | null;
}
export function HotKeyLabel({ action }: Props) {
const label = useHotKeyLabel(action);
return <span>{label}</span>;
}