Skip to content

Commit

Permalink
perf: 优化登录页 (#1168)
Browse files Browse the repository at this point in the history
  • Loading branch information
warmthsea authored Jun 27, 2024
1 parent 13e7a13 commit 775d7a2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/views/login/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,11 @@ const immediateDebounce: any = debounce(
);
useEventListener(document, "keypress", ({ code }) => {
if (code === "Enter" && !disabled.value && !loading.value)
if (
["Enter", "NumpadEnter"].includes(code) &&
!disabled.value &&
!loading.value
)
immediateDebounce(ruleFormRef.value);
});
Expand Down

0 comments on commit 775d7a2

Please sign in to comment.