-
Notifications
You must be signed in to change notification settings - Fork 165
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
Issue with customRenderTabBar #33
Comments
Hi @alexpchin thanks, I hope you had a nice time too :) If you log the |
@PedroBern When first loading, without scrolling |
What if we do: customRenderTabBar({
...props,
...tabBarProps,
isGliding,
preventTabPressOnGliding
}) Why do we pass the |
If we pass the whole ref, then we will need to use the Can you test and send a PR? If you can't, I probably will see it only later this week |
@PedroBern I'll take a look now |
Hi @PedroBern I've made a PR #34 Please take a look! |
BREAKING CHANGE: pass isGliding ref instead of isGliding.current Migration: use isGliding.current instead of isGliding inside your custom renderTabBar function Fixes #33
BREAKING CHANGE: pass isGliding ref instead of isGliding.current Migration: use isGliding.current instead of isGliding inside your custom renderTabBar function Fixes #33
BREAKING CHANGE: pass isGliding ref instead of isGliding.current Migration: use isGliding.current instead of isGliding inside your custom renderTabBar function Fixes #33
@alexpchin thanks for the PR, v2 is out 🚀 |
@alexpchin I did some modifications to the example after updating the types 👍 |
@PedroBern Thanks for merging so quiickly. My Typescript is a bit rusty... I thought you might have to do that! |
the problem was with the |
Now it's possible to pass the custom tab bar props type into the CollapsibleTabView and tabBarProps and renderTabBar will recognize the props <CollapsibleTabView<Route, CustomTabBarProps> ... tabBarProps={{... typedProps ...}} ... /> |
Hi @PedroBern I hope you had a nice Christmas and New Year.
I'm just looking into an issue when you use a custom tab bar. Everything works when you don't render a custom tab bar, however, when using a custom tab bar it seems like the preventDefault does not prevent clicking on the tab when the user is scrolling. Is this perhaps because the
isGliding.current
is being passed instead ofisGliding
?Basically it becomes gittery.
The code below:
Within my custom TabBar, I'm using (shortened version):
This is a video showing it working with no custom tab bar:
This is a video showing it not working with a custom tab bar:
The text was updated successfully, but these errors were encountered: