-
-
Notifications
You must be signed in to change notification settings - Fork 802
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Keyboard gets closed when typing #2091
Comments
I've got the same issue when I'm adding TextInput to |
I tried but than keyboard is not getting avoided. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
Any solutions? |
fixed your issue how? |
Version
v5
Reanimated Version
v3
Gesture Handler Version
v2
Platforms
iOS, Android
What happened?
When typing keyboard gets closed
Reproduction steps
const [comment, setComment] = useState<string | undefined>(undefined);
const renderFooter = useCallback(
props => {
return (
<BottomSheetFooter style={styles.footerContainer} {...props}>
{reply && (
<View
style={[
commonStyles.flexContainer,
{marginBottom: theme.spacing?.sm, marginLeft: 45},
]}>
<Typography
isLight
style={{
color: theme.COLORS?.PRIMARY,
width: '91%',
}}>
Replying to {reply?.userId}
<TouchableOpacity
onPress={() => {
setReply(undefined);
setComment(undefined);
}}>
)}
<View
style={[commonStyles.flexContainer, {gap: theme.spacing?.sm}]}>
<Avatar
rounded
source={{
uri: user?.profilePicture!,
}}
/>
<View
style={[commonStyles.flexContainer, styles.footerInputSubView]}>
<BottomSheetTextInput
ref={inputRef}
style={styles.footerTextInput}
placeholder="Add comment"
placeholderTextColor={theme.COLORS?.TEXT_GRAY}
value={comment}
onChangeText={value => {
if (reply) {
const temp = reply?.userId?.replace(' ', '');
if (extractUserId(value) !== temp) {
setReply(undefined);
}
}
setComment(value);
}}
/>
{!postCommentLoading ? (
<TouchableOpacity
style={{marginTop: 8}}
disabled={comment ? false : true}
onPress={postComment}
// onPress={cleanComment}
>
) : (
<ActivityIndicator
color={theme.COLORS?.PRIMARY}
size={'small'}
/>
)}
);
},
[comment, postCommentLoading, reply, user],
);
Reproduction sample
https://snack.expo.dev/@abdulpropelius/bottom-sheet---issue-reproduction-template
Relevant log output
The text was updated successfully, but these errors were encountered: