summaryrefslogtreecommitdiff
path: root/extension/react-app/src/pages
diff options
context:
space:
mode:
authorNate Sesti <sestinj@gmail.com>2023-07-15 14:30:11 -0700
committerNate Sesti <sestinj@gmail.com>2023-07-15 14:30:11 -0700
commit925c3e0ef45d9eb01a8f6c1efd239fa011492bd2 (patch)
treecd07a7b0acee3ffbaa3570483bd713032e0de341 /extension/react-app/src/pages
parent6b3d20c943c0c1417b437ad475019bae729103ed (diff)
downloadsncontinue-925c3e0ef45d9eb01a8f6c1efd239fa011492bd2.tar.gz
sncontinue-925c3e0ef45d9eb01a8f6c1efd239fa011492bd2.tar.bz2
sncontinue-925c3e0ef45d9eb01a8f6c1efd239fa011492bd2.zip
ctrl shortcuts on windows, load models immediately
Diffstat (limited to 'extension/react-app/src/pages')
-rw-r--r--extension/react-app/src/pages/gui.tsx6
1 files changed, 3 insertions, 3 deletions
diff --git a/extension/react-app/src/pages/gui.tsx b/extension/react-app/src/pages/gui.tsx
index 57cebac3..cb0404ab 100644
--- a/extension/react-app/src/pages/gui.tsx
+++ b/extension/react-app/src/pages/gui.tsx
@@ -137,12 +137,12 @@ function GUI(props: GUIProps) {
useEffect(() => {
const listener = (e: any) => {
// Cmd + i to toggle fast model
- if (e.key === "i" && e.metaKey && e.shiftKey) {
+ if (e.key === "i" && isMetaEquivalentKeyPressed(e) && e.shiftKey) {
setUsingFastModel((prev) => !prev);
// Cmd + backspace to stop currently running step
} else if (
e.key === "Backspace" &&
- e.metaKey &&
+ isMetaEquivalentKeyPressed(e) &&
typeof history?.current_index !== "undefined" &&
history.timeline[history.current_index]?.active
) {
@@ -220,7 +220,7 @@ function GUI(props: GUIProps) {
if (mainTextInputRef.current) {
let input = (mainTextInputRef.current as any).inputValue;
// cmd+enter to /edit
- if (event?.metaKey) {
+ if (isMetaEquivalentKeyPressed(event)) {
input = `/edit ${input}`;
}
(mainTextInputRef.current as any).setInputValue("");