Skip to main content
Version: Next

Progress Bar

The ProgressBar component is a visual indicator of a progress. It displays a progress bar with a color that can be customized. The progress bar will animate and fill up based on the progress passed in as a percentage value.

Import

import { ProgressBar } from '@tra-tech/react-native-kitra';

Usage

import { ProgressBar } from '@tra-tech/react-native-kitra';
import { View, StyleSheet } from 'react-native';

const App = () => (
<View style={style.container}>
<ProgressBar progress={50} barColor="#EDEAF8" progressColor="#8973CD" />
<ProgressBar progress={25} />
</View>
);

const style = StyleSheet.create({
container: { flex: 1, justifyContent: 'center', rowGap: 50 },
});

export default App;

Props

Prop NameTypeRequiredDescription
progressnumberNoThe progress value as a percentage. Default value: 0.
barColorstringNoThe background color of the progress bar.
progressColorstringNoThe color of the progress bar.
progressStyleStyleProp<ViewStyle>NoStyle object to be applied to the progress bar.
themeUIThemeNoThe theme to use for the component.