【发布时间】:2018-03-26 14:42:22
【问题描述】:
我在我的应用程序中使用 React-Native。我使用overflow 来显示主视图之外的视图。它在 iOS 上运行良好,但在 Android 上却不行。
这是我的代码:
<View style={Style.parentStyle}>
<View
style={[
{
height: barHeight,
backgroundColor: color,
overflow: "visible"
},
Style.mainStyle
]}
>
<View
style={[
{
borderRadius: shadowHeight,
top: -borderRadiusBar,
borderWidth: 1.0,
borderColor: borderColor,
backgroundColor: color,
overflow: "visible"
},
Style.roundStyle
]}
>
<Text style={Style.otherstyle}>{player value}</Text>
</View>
</View>
<Text style={Style.textStyle}>{name}</Text>
</View>;
风格:
parentStyle: {
flex: 1,
backgroundColor: 'transparent',
marginLeft: 1,
marginRight: 2,
justifyContent: 'flex-end',
overflow: 'visible',
},
mainStyle: {
justifyContent: 'flex-start',
alignItems: 'center',
borderRadius: 0,
overflow: 'visible',
},
【问题讨论】:
标签: android react-native overflow