Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
61287a16
Unverified
Commit
61287a16
authored
Jun 02, 2024
by
Timothy Jaeryang Baek
Committed by
GitHub
Jun 02, 2024
Browse files
Merge pull request #2752 from open-webui/dev
fix: #2751
parents
4b459e37
16e72b2f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
6 deletions
+12
-6
src/lib/components/chat/MessageInput.svelte
src/lib/components/chat/MessageInput.svelte
+12
-6
No files found.
src/lib/components/chat/MessageInput.svelte
View file @
61287a16
...
@@ -828,13 +828,19 @@
...
@@ -828,13 +828,19 @@
e.preventDefault();
e.preventDefault();
}
}
if (e.key === 'Enter' && !e.shiftKey && prompt !== '') {
const commandOptionButton = [
submitPrompt(prompt, user);
...document.getElementsByClassName('selected-command-option-button')
return;
]?.at(-1);
}
if (e.key === 'Enter' && e.shiftKey && prompt !== '') {
if (!commandOptionButton) {
return;
if (e.key === 'Enter' && !e.shiftKey && prompt !== '' && selected) {
submitPrompt(prompt, user);
return;
}
if (e.key === 'Enter' && e.shiftKey && prompt !== '') {
return;
}
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment