From a0c7d4e3b5644a7faa3935d331641c09c703a652 Mon Sep 17 00:00:00 2001 From: Satindar Dhillon Date: Tue, 2 Aug 2022 19:43:47 -0700 Subject: [PATCH] call focused field as first modifier --- .../Registration/EmailAuth/EmailSignupFormView.swift | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/apple/OmnivoreKit/Sources/App/Views/Registration/EmailAuth/EmailSignupFormView.swift b/apple/OmnivoreKit/Sources/App/Views/Registration/EmailAuth/EmailSignupFormView.swift index abd5786dc..4c25b8305 100644 --- a/apple/OmnivoreKit/Sources/App/Views/Registration/EmailAuth/EmailSignupFormView.swift +++ b/apple/OmnivoreKit/Sources/App/Views/Registration/EmailAuth/EmailSignupFormView.swift @@ -95,11 +95,11 @@ struct EmailSignupFormView: View { .font(.appFootnote) .foregroundColor(.appGrayText) TextField("", text: $email) + .focused($focusedField, equals: .email) .textContentType(.emailAddress) .keyboardType(.emailAddress) .textInputAutocapitalization(.never) .disableAutocorrection(true) - .focused($focusedField, equals: .email) .submitLabel(.next) } .padding(.bottom, 8) @@ -110,10 +110,10 @@ struct EmailSignupFormView: View { .font(.appFootnote) .foregroundColor(.appGrayText) SecureField("", text: $password) + .focused($focusedField, equals: .password) .textContentType(.newPassword) .textInputAutocapitalization(.never) .disableAutocorrection(true) - .focused($focusedField, equals: .password) .submitLabel(.next) } .padding(.bottom, 8) @@ -124,10 +124,10 @@ struct EmailSignupFormView: View { .font(.appFootnote) .foregroundColor(.appGrayText) TextField("", text: $name) + .focused($focusedField, equals: .fullName) .textContentType(.name) .keyboardType(.alphabet) .disableAutocorrection(true) - .focused($focusedField, equals: .fullName) .submitLabel(.next) } .padding(.bottom, 8) @@ -140,11 +140,11 @@ struct EmailSignupFormView: View { .font(.appFootnote) .foregroundColor(.appGrayText) TextField("", text: $viewModel.potentialUsername) + .focused($focusedField, equals: .username) .textInputAutocapitalization(.never) .textContentType(.username) .disableAutocorrection(true) .keyboardType(.alphabet) - .focused($focusedField, equals: .username) .submitLabel(.done) }