Merge pull request #6 from jjm2473/patch-1

fix: 防止中文输入法输入英文时触发提交
main
Redon 2 years ago committed by GitHub
commit ddec57f562
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -104,7 +104,7 @@ function addMessage(message: string, reversal = false) {
</main> </main>
<footer class="p-4"> <footer class="p-4">
<div class="flex items-center justify-between space-x-2"> <div class="flex items-center justify-between space-x-2">
<NInput v-model:value="value" :disabled="loading" placeholder="Type a message..." @keyup="handleEnter" /> <NInput v-model:value="value" :disabled="loading" placeholder="Type a message..." @keypress="handleEnter" />
<NButton type="primary" :loading="loading" @click="handleSubmit"> <NButton type="primary" :loading="loading" @click="handleSubmit">
<template #icon> <template #icon>
<Icon icon="ri:send-plane-fill" /> <Icon icon="ri:send-plane-fill" />

Loading…
Cancel
Save