Skip to content

Commit d4ce9b0

Browse files
zakster12satya164
authored andcommitted
Changed View to Animated.View for TabBarBottom (react-navigation#1360)
1 parent b8dbbe9 commit d4ce9b0

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

src/views/TabView/TabBarBottom.js

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,7 @@
11
/* @flow */
22

33
import React, { PureComponent } from 'react';
4-
import {
5-
Animated,
6-
View,
7-
TouchableWithoutFeedback,
8-
StyleSheet,
9-
} from 'react-native';
4+
import { Animated, TouchableWithoutFeedback, StyleSheet } from 'react-native';
105
import TabBarIcon from './TabBarIcon';
116

127
import type {
@@ -135,7 +130,7 @@ export default class TabBarBottom
135130
// Prepend '-1', so there are always at least 2 items in inputRange
136131
const inputRange = [-1, ...routes.map((x: *, i: number) => i)];
137132
return (
138-
<View style={[styles.tabBar, style]}>
133+
<Animated.View style={[styles.tabBar, style]}>
139134
{routes.map((route: NavigationRoute, index: number) => {
140135
const focused = index === navigation.state.index;
141136
const scene = { route, index, focused };
@@ -164,7 +159,7 @@ export default class TabBarBottom
164159
</TouchableWithoutFeedback>
165160
);
166161
})}
167-
</View>
162+
</Animated.View>
168163
);
169164
}
170165
}

0 commit comments

Comments
 (0)