diff --git a/apps/web/src/components/keyboard-shortcuts-help.tsx b/apps/web/src/components/keyboard-shortcuts-help.tsx
index fd0af837..dd06315d 100644
--- a/apps/web/src/components/keyboard-shortcuts-help.tsx
+++ b/apps/web/src/components/keyboard-shortcuts-help.tsx
@@ -19,96 +19,7 @@ import {
DialogTrigger,
} from "./ui/dialog";
-const ShortcutItem = ({
- shortcut,
- isRecording,
- onStartRecording,
-}: {
- shortcut: KeyboardShortcut;
- isRecording: boolean;
- onStartRecording: (shortcut: KeyboardShortcut) => void;
-}) => {
- // Filter out lowercase duplicates for display - if both "j" and "J" exist, only show "J"
- const displayKeys = shortcut.keys.filter((key: string) => {
- if (
- key.includes("Cmd") &&
- shortcut.keys.includes(key.replace("Cmd", "Ctrl"))
- )
- return false;
-
- return true;
- });
-
- return (
-
-
- {shortcut.icon && (
-
{shortcut.icon}
- )}
-
{shortcut.description}
-
-
- {displayKeys.map((key: string, index: number) => (
-
-
- {key.split("+").map((keyPart: string, partIndex: number) => {
- const keyId = `${shortcut.id}-${index}-${partIndex}`;
- return (
- onStartRecording(shortcut)}
- >
- {keyPart}
-
- );
- })}
-
- {index < displayKeys.length - 1 && (
-
or
- )}
-
- ))}
-
-
- );
-};
-
-const EditableShortcutKey = ({
- children,
- isRecording,
- onStartRecording,
-}: {
- children: React.ReactNode;
- isRecording: boolean;
- onStartRecording: () => void;
-}) => {
- const handleClick = (e: React.MouseEvent) => {
- e.preventDefault();
- e.stopPropagation();
- onStartRecording();
- };
-
- return (
-
- );
-};
-
-export const KeyboardShortcutsHelp = () => {
+export function KeyboardShortcutsHelp() {
const [open, setOpen] = useState(false);
const [recordingShortcut, setRecordingShortcut] =
useState(null);
@@ -237,15 +148,98 @@ export const KeyboardShortcutsHelp = () => {
-
);
-};
+}
+
+function ShortcutItem({
+ shortcut,
+ isRecording,
+ onStartRecording,
+}: {
+ shortcut: KeyboardShortcut;
+ isRecording: boolean;
+ onStartRecording: (shortcut: KeyboardShortcut) => void;
+}) {
+ // Filter out lowercase duplicates for display - if both "j" and "J" exist, only show "J"
+ const displayKeys = shortcut.keys.filter((key: string) => {
+ if (
+ key.includes("Cmd") &&
+ shortcut.keys.includes(key.replace("Cmd", "Ctrl"))
+ )
+ return false;
+
+ return true;
+ });
+
+ return (
+
+
+ {shortcut.icon && (
+
{shortcut.icon}
+ )}
+
{shortcut.description}
+
+
+ {displayKeys.map((key: string, index: number) => (
+
+
+ {key.split("+").map((keyPart: string, partIndex: number) => {
+ const keyId = `${shortcut.id}-${index}-${partIndex}`;
+ return (
+ onStartRecording(shortcut)}
+ >
+ {keyPart}
+
+ );
+ })}
+
+ {index < displayKeys.length - 1 && (
+
or
+ )}
+
+ ))}
+
+
+ );
+}
+
+function EditableShortcutKey({
+ children,
+ isRecording,
+ onStartRecording,
+}: {
+ children: React.ReactNode;
+ isRecording: boolean;
+ onStartRecording: () => void;
+}) {
+ const handleClick = (e: React.MouseEvent) => {
+ e.preventDefault();
+ e.stopPropagation();
+ onStartRecording();
+ };
+
+ return (
+
+ {children}
+
+ );
+}
\ No newline at end of file