Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

fix: correctly handle command pallete short (fixes on Linux) (#577)

Myles Scolnickf8d987e968e0
diff --git a/frontend/src/components/editor/CommandPalette.tsx b/frontend/src/components/editor/CommandPalette.tsx
index 29a9d15eec..5cd6b6f0a9 100644
--- a/frontend/src/components/editor/CommandPalette.tsx
+++ b/frontend/src/components/editor/CommandPalette.tsx
@@ -18,6 +18,7 @@ import { HOTKEYS, HotkeyAction, isHotkeyAction } from "@/core/hotkeys/hotkeys";
import { atom, useAtom } from "jotai";
import { useNotebookActions } from "./actions/useNotebookActions";
import { Objects } from "@/utils/objects";
+import { parseShortcut } from "@/core/hotkeys/shortcuts";
export const commandPaletteAtom = atom(false);
@@ -38,7 +39,7 @@ export const CommandPalette = () => {
React.useEffect(() => {
const down = (e: KeyboardEvent) => {
- if (e.key === "k" && e.metaKey && !e.shiftKey) {
+ if (parseShortcut(HOTKEYS.getHotkey("global.commandPalette").key)(e)) {
e.preventDefault();
setOpen((open) => !open);
}