diff --git a/Demo Project/ResponsiveTextFieldDemo.xcodeproj/project.pbxproj b/Demo Project/ResponsiveTextFieldDemo.xcodeproj/project.pbxproj index 44c3f18..3c34cb6 100644 --- a/Demo Project/ResponsiveTextFieldDemo.xcodeproj/project.pbxproj +++ b/Demo Project/ResponsiveTextFieldDemo.xcodeproj/project.pbxproj @@ -281,7 +281,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_STYLE = Automatic; - DEVELOPMENT_TEAM = ZZVQ8B5T69; + DEVELOPMENT_TEAM = Y4FPFWU22N; ENABLE_PREVIEWS = YES; INFOPLIST_FILE = ResponsiveTextFieldDemo/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 14.0; @@ -302,7 +302,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_STYLE = Automatic; - DEVELOPMENT_TEAM = ZZVQ8B5T69; + DEVELOPMENT_TEAM = Y4FPFWU22N; ENABLE_PREVIEWS = YES; INFOPLIST_FILE = ResponsiveTextFieldDemo/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 14.0; diff --git a/Sources/ResponsiveTextField/ResponsiveTextField.swift b/Sources/ResponsiveTextField/ResponsiveTextField.swift index 7a61ea9..30fb01f 100644 --- a/Sources/ResponsiveTextField/ResponsiveTextField.swift +++ b/Sources/ResponsiveTextField/ResponsiveTextField.swift @@ -344,9 +344,9 @@ extension ResponsiveTextField: UIViewRepresentable { switch (uiView.isFirstResponder, firstResponderDemand?.wrappedValue) { case (true, .shouldResignFirstResponder): - uiView.resignFirstResponder() + RunLoop.main.schedule { uiView.resignFirstResponder() } case (false, .shouldBecomeFirstResponder): - uiView.becomeFirstResponder() + RunLoop.main.schedule { uiView.becomeFirstResponder() } case (_, nil): // If there is no demand then there's nothing to do. break