Skip to content

Commit

Permalink
chore(typescript): export "TabBarIconProps" and "TabBarLabelProps" (r…
Browse files Browse the repository at this point in the history
  • Loading branch information
itsjgf authored and brentvatne committed Mar 20, 2019
1 parent bd09153 commit dbf165d
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [Unreleased]

- Export TabBarIconProps and TabBarLabelProps

## [3.5.1] - [2019-03-19](https://github.com/react-navigation/react-navigation/releases/tag/3.5.1)

## Added
Expand Down
23 changes: 14 additions & 9 deletions typescript/react-navigation.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -560,23 +560,28 @@ declare module 'react-navigation' {
index: number;
tintColor?: string;
}

export interface TabBarIconProps {
tintColor: string | null;
focused: boolean;
horizontal: boolean;
}

export interface TabBarLabelProps {
tintColor: string | null;
focused: boolean;
}

// tslint:disable-next-line:strict-export-declare-modifiers
interface NavigationTabScreenOptionsBase {
title?: string;
tabBarIcon?:
| React.ReactElement<any>
| ((options: {
tintColor: string | null;
focused: boolean;
horizontal: boolean;
}) => React.ReactElement<any> | null);
| ((options: TabBarIconProps) => React.ReactElement<any> | null);
tabBarLabel?:
| string
| React.ReactElement<any>
| ((options: {
tintColor: string | null;
focused: boolean;
}) => React.ReactElement<any> | string | null);
| ((options: TabBarLabelProps) => React.ReactElement<any> | string | null);
tabBarVisible?: boolean;
tabBarTestIDProps?: { testID?: string; accessibilityLabel?: string };
}
Expand Down

0 comments on commit dbf165d

Please sign in to comment.