We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When opening a bottom sheet and closing it quickly before the open animation is finished causes the app to crash
This is how I use the sheet isolated into it's own component
`export default function Sheet ({ onClose, children }) { const initialSnapPoints = useMemo(() => ['CONTENT_HEIGHT'], []);
const { animatedHandleHeight, animatedSnapPoints, animatedContentHeight, handleContentLayout, } = useBottomSheetDynamicSnapPoints(initialSnapPoints); // ref const bottomSheetRef = useRef(null); // callbacks const handleSheetChanges = useCallback((index) => { if (index === -1) { onClose() } }, []); return ( <Portal> <View style={{ flex: 1 }}> <BottomSheet ref={bottomSheetRef} index={0} onChange={handleSheetChanges} keyboardBehavior="fillParent" snapPoints={animatedSnapPoints} handleHeight={animatedHandleHeight} contentHeight={animatedContentHeight} enablePanDownToClose={true} backdropComponent={(props) => <BottomSheetBackdrop {...props} opacity={0.8} appearsOnIndex={0} disappearsOnIndex={-1} />} backgroundStyle={{ backgroundColor: colors.mono6 }}> <BottomSheetScrollView onLayout={handleContentLayout} contentContainerStyle={styles.scrollView} style={{ maxHeight: Dimensions.get('window').height - 160, }}> <View> </View> </BottomSheetScrollView> </BottomSheet> </View> </Portal> )
}`
The text was updated successfully, but these errors were encountered:
Trying to create a snack to reproduce the error, but can't quite get it to work: https://snack.expo.dev/@lewitje/bottom-sheet-v4-reproducible-issue-template?platform=web
Sorry, something went wrong.
#1367 This pr might fix it, waiting for merge
Just tested, this doesn't fix the issue
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.
This issue was closed because it has been stalled for 5 days with no activity.
No branches or pull requests
Bug
When opening a bottom sheet and closing it quickly before the open animation is finished causes the app to crash
Environment info
Steps To Reproduce
Reproducible sample code
This is how I use the sheet isolated into it's own component
`export default function Sheet ({ onClose, children }) {
const initialSnapPoints = useMemo(() => ['CONTENT_HEIGHT'], []);
}`
The text was updated successfully, but these errors were encountered: