feat(webui): Enter sends, Shift+Enter inserts a newline
Composer previously required Ctrl/Cmd+Enter to send. Plain Enter now sends (still yielding to the command-menu's own Enter handling when it's open); Shift+Enter is left unhandled so the textarea's default newline behavior applies. Updated the visible hint to match.
This commit is contained in:
1 parent
dafbcb0f5c
commit
b56f07fe73
3 files changed
+4
-4
No files matched your search
@@ -53,7 +53,7 @@
|
||||
<textarea class="chat-composer" data-chat-ref="composer" rows="3" placeholder="Message Archie… (commands like /status and /new work here)" aria-label="Message Archie"></textarea>
|
||||
<div class="chat-command-menu" data-chat-ref="commandMenu" hidden role="listbox" aria-label="Commands"></div>
|
||||
<div class="chat-compose-actions">
|
||||
<span class="chat-hint">⌘/Ctrl + Enter to send</span>
|
||||
<span class="chat-hint">Enter to send · Shift+Enter for a new line</span>
|
||||
<button class="btn" data-chat-ref="stop" type="button" disabled>Stop</button>
|
||||
<button class="btn btn-primary" data-chat-ref="send" type="button">Send</button>
|
||||
</div>
|
||||
|
||||
+1
-1
@@ -319,7 +319,7 @@ export function chatPage() {
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (event.key === "Enter" && (event.metaKey || event.ctrlKey)) {
|
||||
if (event.key === "Enter" && !event.shiftKey) {
|
||||
event.preventDefault();
|
||||
sendMessage();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user