Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

mobile: fix keyboard does not open with autoFocus

Ammar Ahmedc0f79be78cb7
diff --git a/apps/mobile/app/components/auth/two-factor.js b/apps/mobile/app/components/auth/two-factor.js
index e0f67d24b..9dbc246ee 100644
--- a/apps/mobile/app/components/auth/two-factor.js
+++ b/apps/mobile/app/components/auth/two-factor.js
@@ -136,6 +136,11 @@ const TwoFactorVerification = ({ onMfaLogin, mfaInfo, onCancel }) => {
backgroundColor: colors.primary.background,
paddingTop: 60
}}
+ onLayout={() => {
+ setTimeout(() => {
+ inputRef.current?.focus();
+ }, 500);
+ }}
>
<View
style={{