Skip to content

fix(button): hitslop passed to touchable #4678

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

TechWilk
Copy link

Motivation

Fix hitslop on the Button component which was previously being passed to the wrong child component

Related issue

#4677

Test plan

  1. Create a button
  2. Apply a large value with the hitslop prop
  3. Observe that you can press outside of the button which triggers both the animation and onPress action

e.g.

<Button
          mode="contained"
          onPress={() => console.log("pressed")}
          hitSlop={300}
>
          Press me
</Button>

@callstack-bot
Copy link

Hey @TechWilk, thank you for your pull request 🤗. The documentation from this branch can be viewed here.

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

Successfully merging this pull request may close these issues.

2 participants