React native参考手册
Components: ProgressBarAndroid
ProgressBarAndroid
React组件仅包含Android ProgressBar
。此组件用于指示该应用程序正在加载,或者该应用程序中有某些活动。
例:
render: function() {
var progressBar =
<View style={styles.container}>
<ProgressBar styleAttr="Inverse" />
</View>;
return (
<MyLoadingComponent
componentView={componentView}
loadingView={progressBar}
style={styles.loadingComponent}
/>
);
},
道具
ViewPropTypes道具...
color?: color
进度条的颜色。
indeterminate?: indeterminateType
如果进度条会显示不确定的进度。请注意,如果styleAttr是水平的,这只能是false。
progress?: number
进度值(0到1之间)。
styleAttr?: enum('Horizontal', 'Normal', 'Small', 'Large', 'Inverse', 'SmallInverse', 'LargeInverse')
ProgressBar的风格。之一:
- 横
- 正常(默认)
- 小
- 大
- 逆
- SmallInverse
- LargeInverse
testID?: string
用于在端到端测试中定位此视图。
Components: ProgressBarAndroid相关
React Native 是一个 JavaScript 的框架,用来撰写实时的、可原生呈现 iOS 和 Android 的应用。
主页 | https://facebook.github.io/react-native/ |
源码 | https://github.com/facebook/react-native |
发布版本 | 0.49 |