Open zwigglers opened 8 months ago
In this update, we've enhanced the DropDown
component in our application. We've introduced a new optional prop keyboardShouldPersistTaps
to the DropDownPropsInterface
interface. This prop has been integrated into the ScrollView
component, allowing for more flexible keyboard interactions.
File | Summary |
---|---|
src/DropDown.tsx |
Introduced a new optional prop keyboardShouldPersistTaps to the DropDownPropsInterface interface. This prop is now part of the ScrollView component, enhancing keyboard interaction. |
🍂 As November winds blow, we code and grow, 🐇
With each key tap, our DropDown adapts, 🍁
Celebrating changes, as the season rearranges, 🎉
Inclusivity in our code, a globally shared ode. 🌍
So here's to the joy of autumn's hue, 🍂
And to the changes we continue to pursue. 🛠️
I encountered a problem when there is Dropdown and TextInput on the same screen.
Scenario: TextInput is focused and keyboard is open.
Action -- tap on Dropdown, the dropdown menu opens as expected Next, ton a menu option.
Expected: The option should be selected
Actual: Instead, the keyboard is dismissed, and the menu remains open. An additional tap on the menu option is needed to select it
Solution: set keyboardShouldPersistTaps='handled' or 'always' to the ScrollView inside the menu prevents the keyboard from being dismissed and the tap going through to the menu option.
I have exposed this prop as a prop of Dropdown
Summary by CodeRabbit
New Features:
keyboardShouldPersistTaps
. This allows users to control whether the keyboard should stay visible after a tap. This feature improves user interaction with the component, especially in scenarios where continuous typing is required.