我有两个场景,登录和主页,两者的背景颜色都设置为黑色。但是在过渡期间,当卸载和安装时,似乎还有另一个背景是白色的。
有没有办法弄清楚背景是什么并将颜色也改为黑色?
这是我的设置:
const RouterWithRedux = connect()(Router)
const store = configureStore()
export default class App extends Component {
render() {
return (
<Provider store={store}>
<RouterWithRedux>
<Scene key='root'>
<Scene component={Login} initial={true} key='login' sceneStyle={{backgroundColor: 'black'}} title='Login'/>
<Scene component={Home} direction='vertical' key='Home' sceneStyle={{backgroundColor: 'black'}} title='Home'/>
</Scene>
</RouterWithRedux>
</Provider>
)
}
}
以及带有白色显示的过渡图像,有点难以看到,但是如果您看到右上角的电池图标,则右侧和顶部的登录场景下降(如从登录到主页,登录在被卸载的过程所以是半透明的黑色):