wix / react-native-navigation

A complete native navigation solution for React Native
https://wix.github.io/react-native-navigation/
MIT License
13.04k stars 2.67k forks source link

Bottom Tab should render customizable component (not just icon properties) #7887

Open techmonsterco opened 3 months ago

techmonsterco commented 3 months ago

Describe your idea

Similar to how reactnavigation.org handles their bottom tab. https://reactnavigation.org/docs/7.x/bottom-tab-navigator/#tabbarbutton

Wix-r-n-n should allow the bottom tab to be any component, not just properties relating to icon.

Motivation

https://github.com/facebook/react-native/issues/23870 and several wix-r-n-n Android specific bugs are related due to View.getGlobalVisibleRect() returning True in cases.

wix e2e detox known related bug due to Android overlays: If I create an Absolute Positioned Component and render it at bottom of screen, Then Android will overdraw. Wix detox e2e tests fail due to saying Android element is on Screen when it is indeed not visible to the user. Example: A with Many Nested , all will appear 'visible' from test perspective. detox failure example: await expect(element(by.id(id))).toBeVisible(); (returns always true) By allowing the Bottom Tab to be customizable, we may avoid this bug.

Even better: Wix, et al. Now have a way to have a 'Component on the bottom of their screen' that can be customizable, and e2e testable from an Android perspective.

Without this: having a 'Component on the bottom of your screen' is NOT testable from an Android e2e perspective (wix/detox)

sidebar: excellent library!

Are you willing to resolve this issue by submitting a Pull Request?

cmdominguez commented 3 months ago

https://github.com/cmdominguez/react-native-custom-bottom-tabs @techmonsterco tal vez esto sirva