Components / ProgressBar

ProgressBar

Horizontal progress bar, with a label, a percentage and a detail.

Example

The component itself, running in WebAssembly, beside its code in a playground. Try it.

Code

use ravenrs::prelude::*;

fn progress_bar() -> impl View {
    VStack::new((
        ProgressBar::new(0.25),
        ProgressBar::new(0.9).tone(Tone::Success),
        ProgressBar::new(0.4).label("Copying").percent().detail("12 of 30 photos").height(4.0),
    ))
    .spacing(16.0)
    .align(Align::Stretch)
}

Open in the playground, with every example →

Full API of ProgressBar →