修复加载时白屏的问题
如果不传入 option.backgroundColor,背景为透明色 如果传入 option.backgroundColor,背景为传入的颜色 (option.backgroundColor 是 ECharts 的 背景色配置项)
This commit is contained in:
parent
eeeaead411
commit
472e6ff816
|
|
@ -21,6 +21,7 @@ export default class App extends Component {
|
||||||
height: this.props.height || 400,
|
height: this.props.height || 400,
|
||||||
}}
|
}}
|
||||||
source={require('./tpl.html')}
|
source={require('./tpl.html')}
|
||||||
|
style={{backgroundColor: this.props.option.backgroundColor || 'rgba(0, 0, 0, 0)'}}
|
||||||
onMessage={event => this.props.onPress ? this.props.onPress(JSON.parse(event.nativeEvent.data)) : null}
|
onMessage={event => this.props.onPress ? this.props.onPress(JSON.parse(event.nativeEvent.data)) : null}
|
||||||
/>
|
/>
|
||||||
</View>
|
</View>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue