Skip to content

Commit aa14d56

Browse files
Merge pull request #193 from microsoft/PSL-BUG-13861
fix: Disable Send/Submit Button by Default in Chat Section
2 parents 9f4973b + 57f78d7 commit aa14d56

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

App/frontend-app/src/components/chat/chatRoom.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,9 @@ export function ChatRoom({ searchResultDocuments, selectedDocuments, chatWithDoc
289289
};
290290

291291
function handleSend(ev: TextareaSubmitEvents, data: TextareaValueData) {
292-
makeApiRequest(data.value);
292+
if (data.value.trim() !='') {
293+
makeApiRequest(data.value);
294+
}
293295
}
294296

295297
// const handleOpenReference = async (referenceId: string, chunkTexts: string[]) => {

0 commit comments

Comments
 (0)