react-navigation / react-navigation/react-navigation.github.io

Docs: `overrideScrollViewContentInsetAdjustmentBehavior` option missing from Native Bottom Tab Navigator page

Ouverte Adaptée aux débutants
#1,491 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Langage dominant
JavaScript
Étoiles
324
Forks
2k
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

The Tab.Screen option overrideScrollViewContentInsetAdjustmentBehavior is implemented and exposed in @react-navigation/bottom-tabs/unstable but not listed on the Native Bottom Tab Navigator docs page.

It's an iOS-only option with non-obvious default behaviour, and it's the only escape hatch for a fairly common visible bug — a blank gap appearing above content in a native-stack screen with headerTransparent: true nested inside a NativeTabs tab. The bug was reported in #12946 and the fix is exactly this option, but a reader hitting the symptom has no way to discover it from the docs.

JSDoc from the source

Whether to override the contentInsetAdjustmentBehavior of the first ScrollView in the first descendant chain from the tab screen.

By default, react-native's ScrollView has contentInsetAdjustmentBehavior set to never instead of UIKit-default (which is automatic). This prevents ScrollViews from respecting navigation bar insets. When this prop is set to true, automatic behavior is reverted.

To disable this behavior for specific screens, set this option to false.

Only supported with native implementation.

Defaults to true. iOS-only.

Suggested doc placement

Under "Options" on docs/native-bottom-tab-navigator.md, next to tabBarStyle / tabBarMinimizeBehavior (other iOS-flavoured presentation options). A brief mention of the symptom it fixes ("blank gap above content in a nested transparent-header screen on iOS") would help a lot.

Happy to PR if useful — just want to flag the gap before the next person hits it.

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Piste de recherche

Ouvrez docs/native-bottom-tab-navigator.md et lisez la section Options autour de tabBarStyle et tabBarMinimizeBehavior. Vérifiez le JSDoc de l’option dans packages/bottom-tabs/src/unstable/types.tsx, puis documentez sa valeur par défaut, ses limites iOS-only et native-only, ainsi que le symptôme d’un espace vide avec un en-tête transparent. La tâche est terminée lorsque les lecteurs peuvent trouver et comprendre cette option sur la page Native Bottom Tab Navigator.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
react-native
Domaine
documentation
Type d'issue
Documentation
Difficulté
1/5
Temps estimé
Moins d'une heure
Activité
Calme
Clarté
Clairement spécifiée
Accessibilité débutants
90/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.