aksonov / aksonov/react-native-router-flux
Scene Transitioning wrong direction Intermittently
- Ngôn ngữ chính
- JavaScript
- Star
- 8.9k
- Fork
- 2.1k
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
### Version
Tell us which versions you are using:
- react-native-router-flux v4.0.6
- react v16.4.0
- react-native v0.57.0
- react-navigation v2.18.3
### Expected behaviour
Switching between tab scenes has no transition.
### Actual behaviour
First interaction to a different tab scene works, afterwards tab scenes will intermittently load from bottom to top.
I've been attempting to debug this issue for weeks now, I've read every issue on the repo regarding scene transitions and the related issues on react-navigation and I believe my code is correct. You can see the error on the return to the initial tab scene in the video capture below in the last frame, it slides up instead of just switching to the tab.
### Code
#### Transition
```
const modalTransition = () => ({
screenInterpolator: StackViewStyleInterpolator.forHorizontal,
})
```
#### Routes:
```
}
onBack={Actions.pop} />
}
direction="horizontal" />
}
onBack={Actions.pop} />
}
renderBackButton={() => }
onRight={Actions.manage}
direction="horizontal" />
```
#### Tab Icon (explore)
```
class TabIcon extends Component {
render() {
return (
{this.press()}}>
)
}
press() {
let delta = new Date().getTime() - this.state.lastPress
if(delta < 200) {
Actions.popTo('search')
} else {
Actions.jump('explore')
}
this.setState({
lastPress: new Date().getTime()
})
}
}
export default TabIcon
```

Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.