【发布时间】:2015-11-02 23:31:16
【问题描述】:
TouchableHighlight 如何在点击时处理文本的颜色。我已经使用 underLayColor 在 backgroundColor 上完成了它。这是我的代码:
<TouchableHighlight
style={{ borderRadius: 5}}
underlayColor="#ffffff"
onPress={this.onLoadPress}>
<View style={[styles.buttonBox, styles.btnEditProfile]}>
<Text style={styles.btnEditProfileText}>
Edit Profile
</Text>
</View>
</TouchableHighlight>
【问题讨论】:
-
据我所知,你只能改变你提到的underlayColor。但是,我认为您可以使用动画获得想要的效果。不过我没时间帮你解决,抱歉……facebook.github.io/react-native/docs/animated.html#content
标签: javascript ios reactjs react-native