ProgressLinear

Feedback & Status
stable

Horizontal progress bar with determinate, indeterminate, buffer, stream and clickable modes.

Preview

Rendering the live preview…

determinate 40%

Rendering the live preview…

indeterminate

Rendering the live preview…

buffer

Rendering the live preview…

rounded

Rendering the live preview…

thick

Structure

Anatomy

Visual breakdown of the component's internal structure with BEM class call-outs.

Anatomy of OrigamProgressLinearSchematic of the ProgressLinear component with 5 numbered internal parts. 1 2 3 4 5 ① root wrapper (div.origam-progress--linear) ② div.origam-progress__background (track) ③ div.origam-progress__loader > __bar ④ div.origam-progress__stream (buffer dots) ⑤ div.origam-progress__content (slot)
Anatomy of <origam-progress-linear> — 5 internal parts: root ①, background track ②, foreground bar ③, stream indicator ④ (buffer mode only), and content slot ⑤.
1.origam-progress--linear
Root element. overflow: hidden; position: relative; width: 100%. Height set inline from thickness prop.
2.origam-progress__background
Background track — absolute, full-width until buffer narrows it. Color from bgColor prop via useTextColor, opacity 0.5.
3.origam-progress__loader > .origam-progress__bar
Foreground loader container + bar(s). In indeterminate mode two bars (--long and --short) animate simultaneously. Width driven by normalised value in determinate mode.
4.origam-progress__stream
Animated dot-stream rendered only when stream=true. Positioned after the buffer zone. Opacity: 0.3.
5.origam-progress__content
Absolute overlay for the #default slot. Rendered only when hasContent is true.

API

Props

All props accepted by this component, with their type, default value and description.

bufferValue
number | string
Secondary progress value (0-max). Shows a buffer zone when stream=true.
clickable
boolean
false
Allows the user to click the bar to set the value. Maps the click X position to a normalised value.
reverse
boolean
false
Reverses the fill direction. Combined with RTL direction via useRtl.
stream
boolean
false
Renders an animated dot-stream beyond the buffer zone. Requires bufferValue.
indeterminate
boolean
false
Activates the continuous bar animation. Overrides modelValue display.
modelValue
string | number
0
Current progress value between 0 and max. Ignored in indeterminate mode.
thickness
string | number
4
Bar height in pixels. Sets both height and line-height inline.
active
boolean
true
When false, pauses animations (animation-play-state: paused).
absolute
boolean
false
Positions the bar absolutely (position: absolute; left: 0).
max
number | string
100
Maximum value used to normalise modelValue into a 0-100 percentage.
striped
boolean
false
Adds a stripe pattern to the foreground bar.
label
string
'Loading'
Accessible label (aria-label) for the progress bar.
tag
string
'div'
Root HTML element.
id
string
class
string | Array<string> | object
style
string | Array<string> | object | StyleValue
color
Foreground bar color. Accepts intent tokens or a CSS color.
bgColor
Background track color. Defaults to currentColor at 50% opacity.
padding
boolean | number | string
paddingTop
boolean | number | string
paddingLeft
boolean | number | string
paddingBottom
boolean | number | string
paddingRight
boolean | number | string
paddingBlock
boolean | number | string
paddingInline
boolean | number | string
paddingInlineStart
boolean | number | string
paddingInlineEnd
boolean | number | string
paddingBlockStart
boolean | number | string
paddingBlockEnd
boolean | number | string
margin
boolean | number | string
marginTop
boolean | number | string
marginLeft
boolean | number | string
marginBottom
boolean | number | string
marginRight
boolean | number | string
marginBlock
boolean | number | string
marginInline
boolean | number | string
marginInlineStart
boolean | number | string
marginInlineEnd
boolean | number | string
marginBlockStart
boolean | number | string
marginBlockEnd
boolean | number | string
Applies pill-shaped border-radius ({radius.full}) to the bar and loader.
roundedTopRight
boolean | number | string
roundedTopLeft
boolean | number | string
roundedBottomLeft
boolean | number | string
roundedBottomRight
boolean | number | string
roundedStartStart
boolean | number | string
roundedStartEnd
boolean | number | string
roundedEndStart
boolean | number | string
roundedEndEnd
boolean | number | string
location
Positional anchor: top or bottom. Sets top:0 or bottom:0 when absolute/fixed.

API

Slots

Content slots exposed by this component.

#default
Content overlaid on the bar (e.g. a label). Slot props: normalised value (0-100) and normalised buffer value.

API

Emits

Events emitted by this component.

@update:modelValue
any

API

Exposed members

Properties and methods accessible via template ref (defineExpose). Use them for programmatic control.

<T extends object>(props: T, exclude?: string[]) => Partial<T>
Utility to forward a filtered subset of props.
Ref<string>
Reactive CSS string generated by useStyle.
string
Unique style-sheet ID for this instance.
() => void
Injects the computed style sheet.
() => void
Removes the injected style sheet.
Ref<boolean>
True once the style sheet has been injected.

Customisation

CSS variables

CSS custom properties exposed by this component. Override them to customise the component without losing theme compatibility.

Background track color. Inherits from bgColor prop via useTextColor.
Background track opacity.
Foreground bar color. Inherits from color prop via useTextColor.

Inclusion

Accessibility

ARIA roles, keyboard navigation and focus management. Sourced from the real component template.

ARIA roles

progressbar

Notes

  • role="progressbar" is applied by the progress composable along with aria-valuenow, aria-valuemin (0) and aria-valuemax.
  • Pass the label prop with a localised string to set aria-label. Defaults to "Loading".
  • When clickable=true, the bar is interactive. Ensure an aria-label describes what clicking does (e.g. "Seek video").
  • Under prefers-reduced-motion: reduce, indeterminate bars are frozen at 50% width and streams stop animating.

Foundation

Design tokens

Excerpt from this component's token declarations — the --origam-<component>---<property> variables, declared in its hand-maintained token sheet with no build step.

Source
dimension
100%
Bar always fills its container width.
dimension
var(--origam-radius---full)
Border radius used when rounded=true.
duration
var(--origam-motion__duration---medium)
Duration of width transitions in determinate mode.
duration
2200ms
Duration of the indeterminate bar CSS animations.

Interactive

Playground

Edit props live and see the component update in real time. The generated code snippet updates as you change values.

Rendering the live preview…

Usage

Examples

Ready-to-paste code snippets for your templates.

Determinate

vue

Indeterminate

vue

Buffer + stream

vue

Ecosystem

Family

Components from the same folder that share conventions and often compose together.