Skip to content

Conversation

okwasniewski
Copy link
Collaborator

PR Description

CleanShot.2025-06-17.at.20.11.19.mp4

Copy link

changeset-bot bot commented Jun 17, 2025

🦋 Changeset detected

Latest commit: b0a2120

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
react-native-bottom-tabs Patch
@bottom-tabs/expo-template Patch
@bottom-tabs/react-navigation Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@okwasniewski okwasniewski requested a review from Copilot July 6, 2025 14:19
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a new minimizeBehavior prop to enable native iOS 26+ tab bar minimization behaviors.

  • Introduces minimizeBehavior in TS and bridges it through the native layer
  • Implements SwiftUI integration using the new tabBarMinimizeBehavior modifier
  • Updates documentation, example app, and changelog

Reviewed Changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
packages/react-native-bottom-tabs/src/TabViewNativeComponent.ts Add generic minimizeBehavior?: string prop
packages/react-native-bottom-tabs/src/TabView.tsx Define minimizeBehavior as a literal union in TS
packages/react-native-bottom-tabs/ios/TabViewProvider.swift Expose minimizeBehavior to Objective-C
packages/react-native-bottom-tabs/ios/TabViewProps.swift Add MinimizeBehavior enum and prop to Swift props
packages/react-native-bottom-tabs/ios/TabViewImpl.swift Apply .tabBarMinimizeBehavior modifier in SwiftUI
packages/react-native-bottom-tabs/ios/RCTTabViewViewManager.mm Export minimizeBehavior to React Native
packages/react-native-bottom-tabs/ios/Fabric/RCTTabViewComponentView.mm Handle prop updates for minimizeBehavior
docs/docs/docs/guides/usage-with-react-navigation.mdx Document minimizeBehavior prop
docs/docs/docs/guides/standalone-usage.md Add minimizeBehavior to standalone usage guide
apps/example/src/Examples/SFSymbols.tsx Include minimizeBehavior example in demo app
.changeset/ready-paths-train.md Add changeset entry for the feature
Comments suppressed due to low confidence (2)

packages/react-native-bottom-tabs/src/TabViewNativeComponent.ts:55

  • The prop minimizeBehavior is currently typed as a generic string, which permits invalid values. Consider using a union type ('automatic' | 'onScrollDown' | 'onScrollUp' | 'never') to enforce valid options and improve type safety.
  minimizeBehavior?: string;

packages/react-native-bottom-tabs/ios/TabViewImpl.swift:31

  • The new minimizeBehavior integration lacks corresponding tests. Adding unit or snapshot tests for iOS 26+ would help ensure the UI behaves as expected when different values are passed.
    .tabBarMinimizeBehavior(props.minimizeBehavior)


#### `minimizeBehavior` <Badge text="iOS 26+" type="info" />

Controls how the tab bar behaves when content is scrolled.
Copy link
Preview

Copilot AI Jul 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The documentation for minimizeBehavior is duplicated across multiple guides. Consider extracting this into a shared snippet or component to reduce duplication and keep docs in sync.

Copilot uses AI. Check for mistakes.

@okwasniewski okwasniewski force-pushed the feat/minimize-behavior branch from 4d8af70 to b0a2120 Compare July 6, 2025 14:57
@okwasniewski okwasniewski merged commit 89b6a5b into main Jul 6, 2025
8 checks passed
@okwasniewski okwasniewski deleted the feat/minimize-behavior branch July 6, 2025 15:23
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.

1 participant