- Prop
value- Type
number | undefined- Default
0- Requirement
- optional
- Description
- Current value.
Docs Components Feedback
Progress
React example follows below.
Vue example follows below.
Angular example follows below.
Svelte example follows below.
Solid example follows below.
- parts
- —
- nodes
- —
- size
- —
- part
- —
ts
const progressFixture = { id: "progress", value: 64, max: 100, label: "Upload progress", indeterminateLabel: "Loading",} satisfies { id: string; value: number; max: number; label: string; indeterminateLabel: string;}; import { Progress } from "@grassroot/ui-react"; export default function ProgressDemo() { return ( <div className="flex w-full max-w-[420px] flex-col gap-3.5"> <Progress value={progressFixture.value} max={progressFixture.max} label={progressFixture.label} /> <Progress indeterminate label={progressFixture.indeterminateLabel} /> </div> );}- parts
- —
- nodes
- —
- size
- —
- part
- —
ts
<script setup lang="ts">const progressFixture = { id: "progress", value: 64, max: 100, label: "Upload progress", indeterminateLabel: "Loading",} satisfies { id: string; value: number; max: number; label: string; indeterminateLabel: string;}; import { Progress } from "@grassroot/ui-vue";</script> <template> <div class="flex w-full max-w-[420px] flex-col gap-3.5"> <Progress :value="progressFixture.value" :max="progressFixture.max" :label="progressFixture.label" /> <Progress indeterminate :label="progressFixture.indeterminateLabel" /> </div></template>- parts
- —
- nodes
- —
- size
- —
- part
- —
ts
import { Component } from "@angular/core";const progressFixture = { id: "progress", value: 64, max: 100, label: "Upload progress", indeterminateLabel: "Loading",} satisfies { id: string; value: number; max: number; label: string; indeterminateLabel: string;}; import { GrassrootProgress } from "@grassroot/ui-angular"; @Component({ selector: "app-progress-demo", standalone: true, imports: [GrassrootProgress], host: { style: "display: contents" }, template: ` <div class="flex w-full max-w-[420px] flex-col gap-3.5"> <grassroot-progress [value]="fixture.value" [max]="fixture.max" [label]="fixture.label" /> <grassroot-progress [indeterminate]="true" [label]="fixture.indeterminateLabel" /> </div> `,})export class ProgressDemoComponent { protected readonly fixture = progressFixture;} export default ProgressDemoComponent;- parts
- —
- nodes
- —
- size
- —
- part
- —
ts
<script lang="ts"> import { Progress } from "@grassroot/ui-svelte"; const progressFixture = { id: "progress", value: 64, max: 100, label: "Upload progress", indeterminateLabel: "Loading", } satisfies { id: string; value: number; max: number; label: string; indeterminateLabel: string; }; </script> <div class="flex w-full max-w-[420px] flex-col gap-3.5"> <Progress value={progressFixture.value} max={progressFixture.max} label={progressFixture.label} /> <Progress indeterminate label={progressFixture.indeterminateLabel} /></div>- parts
- —
- nodes
- —
- size
- —
- part
- —
ts
/** @jsxImportSource solid-js */import { Progress } from "@grassroot/ui-solid";const progressFixture = { id: "progress", value: 64, max: 100, label: "Upload progress", indeterminateLabel: "Loading",} satisfies { id: string; value: number; max: number; label: string; indeterminateLabel: string;}; export default function ProgressDemo() { return ( <div class="flex w-full max-w-[420px] flex-col gap-3.5"> <Progress value={progressFixture.value} max={progressFixture.max} label={progressFixture.label} /> <Progress indeterminate label={progressFixture.indeterminateLabel} /> </div> );}Installation
API Reference
Import
import { Progress } from "@grassroot/ui-react";
Props
Prop
Type
Default
Requirement
Description
valuenumber | undefined0optional
Current value.
maxnumber | undefined100optional
—
indeterminateboolean | undefinedfalseoptional
Unbounded loading state — no value reported.
labelstring | undefined—
optional
Accessible label for the bar.
"aria-label"string | undefined—
optional
Accessible label for the bar.
toneTone | undefined"accent"optional
Brand colour of the bar.
- Prop
max- Type
number | undefined- Default
100- Requirement
- optional
- Description
- —
- Prop
indeterminate- Type
boolean | undefined- Default
false- Requirement
- optional
- Description
- Unbounded loading state — no value reported.
- Prop
label- Type
string | undefined- Default
- —
- Requirement
- optional
- Description
- Accessible label for the bar.
- Prop
"aria-label"- Type
string | undefined- Default
- —
- Requirement
- optional
- Description
- Accessible label for the bar.
- Prop
tone- Type
Tone | undefined- Default
"accent"- Requirement
- optional
- Description
- Brand colour of the bar.
Native attributes
Standard DOM and ARIA attributes not listed above spread onto the root element.
Import
import { Progress } from "@grassroot/ui-vue";
Props
Prop
Type
Default
Requirement
valuenumber | undefined0optional
maxnumber | undefined100optional
labelstring | undefined—
optional
aria-labelstring | undefined—
optional
indeterminateboolean | undefinedfalseoptional
tone"accent" | "amber" | "teal" | "indigo" | undefined"accent"optional
- Prop
value- Type
number | undefined- Default
0- Requirement
- optional
- Prop
max- Type
number | undefined- Default
100- Requirement
- optional
- Prop
label- Type
string | undefined- Default
- —
- Requirement
- optional
- Prop
aria-label- Type
string | undefined- Default
- —
- Requirement
- optional
- Prop
indeterminate- Type
boolean | undefined- Default
false- Requirement
- optional
- Prop
tone- Type
"accent" | "amber" | "teal" | "indigo" | undefined- Default
"accent"- Requirement
- optional
Import
import { Component } from "@angular/core";
import { GrassrootProgress } from "@grassroot/ui-angular";
Props
Prop
Type
Default
Requirement
valuenumber0optional
maxnumber100optional
labelstring—
optional
"aria-label"string | undefinedundefinedoptional
indeterminatebooleanfalseoptional
tone"accent" | "amber" | "teal" | "indigo""accent"optional
- Prop
value- Type
number- Default
0- Requirement
- optional
- Prop
max- Type
number- Default
100- Requirement
- optional
- Prop
label- Type
string- Default
- —
- Requirement
- optional
- Prop
"aria-label"- Type
string | undefined- Default
undefined- Requirement
- optional
- Prop
indeterminate- Type
boolean- Default
false- Requirement
- optional
- Prop
tone- Type
"accent" | "amber" | "teal" | "indigo"- Default
"accent"- Requirement
- optional
Import
import { Progress } from "@grassroot/ui-svelte";
Props
Prop
Type
Default
Requirement
valuenumber0optional
maxnumber100optional
labelstring—
optional
aria-labelstring—
optional
indeterminatebooleanfalseoptional
tone"accent" | "amber" | "teal" | "indigo""accent"optional
classNamestring—
optional
- Prop
value- Type
number- Default
0- Requirement
- optional
- Prop
max- Type
number- Default
100- Requirement
- optional
- Prop
label- Type
string- Default
- —
- Requirement
- optional
- Prop
aria-label- Type
string- Default
- —
- Requirement
- optional
- Prop
indeterminate- Type
boolean- Default
false- Requirement
- optional
- Prop
tone- Type
"accent" | "amber" | "teal" | "indigo"- Default
"accent"- Requirement
- optional
- Prop
className- Type
string- Default
- —
- Requirement
- optional
Import
import { Progress } from "@grassroot/ui-solid";
Props
Prop
Type
Default
Requirement
valuenumber0optional
maxnumber100optional
labelstring—
optional
aria-labelstring—
optional
indeterminatebooleanfalseoptional
tone"accent" | "amber" | "teal" | "indigo""accent"optional
classNamestring—
optional
- Prop
value- Type
number- Default
0- Requirement
- optional
- Prop
max- Type
number- Default
100- Requirement
- optional
- Prop
label- Type
string- Default
- —
- Requirement
- optional
- Prop
aria-label- Type
string- Default
- —
- Requirement
- optional
- Prop
indeterminate- Type
boolean- Default
false- Requirement
- optional
- Prop
tone- Type
"accent" | "amber" | "teal" | "indigo"- Default
"accent"- Requirement
- optional
- Prop
className- Type
string- Default
- —
- Requirement
- optional