question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Swipe to dismiss not working

See original GitHub issue

I’m unable to get the swipe to dismiss feature to work at all. Here’s my code:

  render() {
    return (
      <Modal
        isVisible={this.props.visible}
        onSwipe={() => this.props.onShouldClose()}
        swipeDirection="left"
      >
        {this.renderCard()}
      </Modal>
    );
  }

Pretty sure I’ve followed the instructions correctly but swiping does not work at all, any help would be appreciated 😃

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:4
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
theohdvcommented, May 18, 2018

In your onSwipe method you need to set showModal to false in order to hide the modal.

1reaction
MyGuySicommented, Jan 26, 2018

That’ll probably be the reason 😄 sorry I should have posted versions with the OP, my bad.

Thanks

Read more comments on GitHub >

github_iconTop Results From Across the Web

couldn't dismiss the swipe down ge… | Apple Developer Forums
i have tried dismissing the swipe down gesture in AVPlayerViewController that closes the controller, but no luck. i think am missing out somthing...
Read more >
Support swipe to dismiss for UIViewControllerRepresentable ...
It seems if you use UIViewControllerRepresentable to implement a view controller in your SwiftUI app, when you present it via sheet you cannot ......
Read more >
Swipe to dismiss - Android Developers
SwipeToDismissBox is a composable that can be dismissed by swiping right. To use SwipeToDismissBox , you must first create a state. The state...
Read more >
Swipe to dismiss not working · Issue #108 · react-native-modal ...
I'm unable to get the swipe to dismiss feature to work at all. Here's my code: render() { return ( this.props.
Read more >
How to prevent a sheet from being dismissed with a swipe
SwiftUI provides the interactiveDismissDisabled() modifier to control whether the user can swipe downwards to dismiss a sheet.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found