react-navigation / react-navigation/react-navigation.github.io
Docs: `overrideScrollViewContentInsetAdjustmentBehavior` option missing from Native Bottom Tab Navigator page
還沒有人認領這個 Issue。
- 主要語言
- JavaScript
- 星號
- 324
- 分支
- 2k
- PR 合併指標
- 30 天內沒有已合併 PR
描述
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
contentInsetAdjustmentBehaviorof the firstScrollViewin the first descendant chain from the tab screen.By default,
react-native'sScrollViewhascontentInsetAdjustmentBehaviorset toneverinstead of UIKit-default (which isautomatic). This prevents ScrollViews from respecting navigation bar insets. When this prop is set totrue,automaticbehavior is reverted.To disable this behavior for specific screens, set this option to
false.Only supported with
nativeimplementation.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.
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
開啟 docs/native-bottom-tab-navigator.md,閱讀 tabBarStyle 和 tabBarMinimizeBehavior 附近的 Options 區段。檢查 packages/bottom-tabs/src/unstable/types.tsx 中該選項的 JSDoc,然後記錄其預設值、iOS-only 和 native-only 限制,以及透明標頭出現空白間隙的現象。當讀者可以在 Native Bottom Tab Navigator 頁面上找到並理解此選項時,即表示完成。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- react-native
- 領域
- documentation
- Issue 類型
- 文件
- 難度
- 1/5
- 預估耗時
- 1 小時以內
- 活躍度
- 冷清
- 描述清晰度
- 描述清楚
- 新手友好度
- 90/100