gpt4 book ai didi

ios - react native : Keyboard dismiss when changing focus in ScrollView

转载 作者:可可西里 更新时间:2023-11-01 03:36:02 24 4
gpt4 key购买 nike

在我的 React Native 0.22 iOS 应用程序中,我有一个包含多个 TextInput 元素的 ScrollView

我注意到,当我通过点击下一个 TextInput 将焦点从一个 TextInput 切换到另一个 TextInput 时,键盘将关闭并且下一个 TextInput 不会立即获得焦点.它只会在我第二次点击它时得到关注(然后键盘又回来了,非常糟糕的体验)。

此行为仅发生在 ScrollView 中的 TextInput 上,而不发生在 View 上。我想知道是否有任何解决方法?

谢谢!

最佳答案

keyboardShouldPersistTaps={true} 弃用

false, deprecated, use 'never' instead

true, deprecated, use 'always' instead

关于ios - react native : Keyboard dismiss when changing focus in ScrollView,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36545145/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com