Progress
A pill track cut into the surface with a raised accent bar riding in it. Counter writes the numbers beside it.


import { Progress } from "@terratcg/ui";
import { View } from "react-native";
export default function ProgressTones() {
return (
<View style={{ width: 280, gap: 16 }}>
<Progress value={0.62} />
<Progress tone="muted" value={1} />
</View>
);
}Import
import { Progress } from "@terratcg/ui";Usage
<Progress value={uploaded / total} />The track is a well cut into the surface, 12 pt tall by default. The bar rides in it as a raised accent face with a key's gloss and shadow, under the groove's lip. value runs from 0 to 1; anything outside is clamped. The track fills its parent's width, so size it with the parent or style. When value changes, the bar springs to it.
Examples
Reach
reach draws a faint second fill under the bar, for progress that counts toward a goal but not the headline.


import { Progress } from "@terratcg/ui";
import { View } from "react-native";
export default function ProgressReach() {
return (
<View style={{ width: 280 }}>
<Progress value={0.35} reach={0.7} />
</View>
);
}With a counter
Counter writes the numbers beside a bar: a bold numerator against a muted total.


import { Counter, Progress } from "@terratcg/ui";
import { View } from "react-native";
export default function ProgressCounter() {
return (
<View style={{ width: 280, gap: 10, alignItems: "flex-start" }}>
<Counter value={142} total={200} size="lg" />
<Progress value={142 / 200} style={{ alignSelf: "stretch" }} />
</View>
);
}To write the numbers beside a bar, use Counter, which has its own page.
Props
Prop
Type
Progress also accepts React Native's View props. It draws no children.
Accessibility
- Role:
progressbar, withaccessibilityValuefrom 0 to 100 holding the rounded percentage ofvalue.reachis not announced: say it in a nearby label if it matters. - Label: give the track an
accessibilityLabelthat says what is progressing, such as "Upload progress". - Reduce Motion: the bar jumps to its new value instead of springing.
Platform differences
- iOS and Android: the same groove and bar. On iOS the bar is rasterized while it rests and redrawn only while it moves.
- Web: Progress renders through react-native-web for these docs, but the web is not a supported target.
Rules
- Show Progress for work with a known end. For a wait without one, use a Spinner.
- Switch
tonetomutedonce the work is done, so a finished bar stops calling for attention. - Use
reachfor a second measure that counts toward a goal, never for a buffer or an estimate.