Looking for documentation on gluestack-ui v2 with NativeWind? Refer to this link.
This is an illustration of a Themed Progress component with default configuration.
size
<Progress value={40} w={300} size="md">
<ProgressFilledTrack />
</Progress>

API Reference

Import

To use this component in your project, include the following import statement in your file.
import { Progress, ProgressFilledTrack } from "@gluestack-ui/themed"

Anatomy

The structure provided below can help you identify and understand a Progress component's various parts.
export default () => (
<Progress>
<ProgressFilledTrack />
</Progress>
)

Component Props

This section provides a comprehensive reference list for the component props, detailing descriptions, properties, types, and default behavior for easy project integration.

Progress

It inherits all the properties of React Native's View component.
Prop
Type
Default
Description
value
number
-
It is used to set the progress of the progress bar
Descendants Styling Props Props to style child components.
Sx Prop
Description
_filledTrack
Prop to style ProgressFilledTrack Component

ProgressFilledTrack

It also inherits all the properties of React Native's View component.

Accessibility

We have outlined the various features that ensure the Fab component is accessible to all users, including those with disabilities. These features help ensure that your application is inclusive and meets accessibility standards. Adheres to the WAI-ARIA design pattern.

Keyboard

  • Tab: Moves focus to the next focusable element.

Screen Reader

  • VoiceOver: When the Progress is focused, the screen reader will announce it's a progress and it's current progress indicator.

Themed

The themed version of the component is a pre-styled version of the component, which allows you to quickly integrate the component into your project. The component's design and functionality are fully defined, allowing you to focus on the more important aspects of your project. To know more about Themed Library please visit this link.

Props

Progress component is created using View component from react-native. It extends all the props supported by React Native View, utility props and the props mentioned below.

Progress

Name
Value
Default
size
xs | sm | md | lg | xl | 2xl
md
Note: These props are exclusively applicable when utilizing the default configuration of gluestack-ui/config. If you are using a custom theme, these props may not be available.

Examples

The Examples section provides visual representations of the different variants of the component, allowing you to quickly and easily determine which one best fits your needs. Simply copy the code and integrate it into your project.

Value

Progress component with value
<VStack space="lg">
<Text size="lg">Downloading 55%</Text>
<Progress value={55} w="$80" h="$1">
<ProgressFilledTrack h="$1" />
</Progress>
</VStack>

Color

You can add track color to progress bar as per our needs.
<VStack space="3xl">
<Progress value={46} w="$96" h="$2" size="sm">
<ProgressFilledTrack bg="$emerald600" />
</Progress>
<Progress value={46} w="$96" h="$2" size="sm">
<ProgressFilledTrack bg="$amber600" />
</Progress>
<Progress value={46} w="$96" h="$2" size="sm">
<ProgressFilledTrack bg="$fuchsia600" />
</Progress>
<Progress value={46} w="$96" h="$2" size="sm">
<ProgressFilledTrack bg="$cyan600" />
</Progress>
</VStack>

Custom

You can customize the progress bar. Below is the example where we have change the theme of progress bar.
<VStack space="lg">
<Heading>Internal Storage</Heading>
<Progress value={46} w={410} h={8} bg="$lime100">
<ProgressFilledTrack h={8} bg="$lime500" />
</Progress>
<Text size="md">14GB</Text>
</VStack>

Unstyled

All the components in gluestack-ui are unstyled by default. To customize your UI using the extendedTheme, please refer to this link. The import names of components serve as keys to customize each component.

Spec Doc

Explore the comprehensive details of the Progress in this document, including its implementation details, checklist, and potential future additions. Dive into the thought process behind the component and gain insights into its development journey.