Skip to content
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

Allow panel to 'persist' when clicking on an active backdrop #195

Open
andrewtrac-gigeco opened this issue Dec 2, 2020 · 0 comments
Open

Comments

@andrewtrac-gigeco
Copy link

andrewtrac-gigeco commented Dec 2, 2020

Issue Description

Currently by default, the hide() method is triggered if you click on an active backdrop. As per the documentation: "this method is triggered if you touch the backdrop (If it's visible)."

Is there any solution/workaround to allow the panel to 'persist' on show while the user clicks on an active backdrop? Meaning that the panel should only trigger hide() method by directly calling the method, and nothing else.

This feature would be helpful as users navigate the backdrop from clicking one item to the next.


  <SlidingUpPanel
        ref={c => this._panel = c}
        snappingPoints={[360]}
        height={240}
        friction={0.5}
        backdropOpacity={0}
        draggableRange={{ top, bottom }}
      >
        <View style={styles.swipePanel}>
          <View style={styles.panelHeader}>
            <Text>Content Header and Filters</Text>
          </View>
        </View>
      </SlidingUpPanel>

const styles = StyleSheet.create({
  container: {
    flex: 1,
  },
  loadingIndicator: {
    position: "absolute",
    top: "50%",
    alignSelf: "center",
  },
  swipePanel: {
    flex: 1,
    backgroundColor: "white",
  },
  panelHeader: {
    height: 70,
    backgroundColor: Colors.backgroundColor,
    justifyContent: "flex-end",
    padding: 24,
  },
});


  • Version: 2.4.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant