From 549b9ba3457942f9dd627ff888b3ff5c4e58299c Mon Sep 17 00:00:00 2001 From: spencerwooo Date: Mon, 30 Aug 2021 14:44:50 +0100 Subject: [PATCH] password submit on enter --- components/Auth.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/components/Auth.tsx b/components/Auth.tsx index 1d4dfbb..ea226b5 100644 --- a/components/Auth.tsx +++ b/components/Auth.tsx @@ -33,6 +33,11 @@ const Auth: FunctionComponent<{ redirect: string }> = ({ redirect }) => { onChange={e => { setToken(e.target.value) }} + onKeyPress={e => { + if (e.key === 'Enter' || e.key === 'NumpadEnter') { + router.reload() + } + }} />