Progress
Progress indicator family: linear bar (determinate, indeterminate, buffered, stream, striped, clickable) and circular spinner (determinate, indeterminate, rotate). Dispatched via the type prop.
Aperçu
Rendu de l’aperçu en cours…
linear defaultRendu de l’aperçu en cours…
linear indeterminateRendu de l’aperçu en cours…
linear stripedRendu de l’aperçu en cours…
circularRendu de l’aperçu en cours…
circular indeterminateStructure
Anatomie
Décomposition visuelle de la structure interne du composant avec les appels de classes BEM.
<origam-progress> — Linear: fill bar (①) + buffer track (②). Circular: SVG underlay ring (③) + overlay arc (④) + content slot (⑤).- 1.origam-progress__bar
- Linear: foreground fill bar. Width = normalized value %. In indeterminate mode, two bars (--long and --short) animate in loop.
- 2.origam-progress__stream / background track
- Linear: background track (opacity 50% of fill color) and optional stream dots. Buffer renders a secondary transparent track at bufferValue.
- 3SVG underlay circle
- Circular: background ring (stroke = {color.surface.disabled}, opacity 50%). Always visible.
- 4SVG overlay circle
- Circular: foreground arc. stroke-dashoffset driven by normalized value. Animated by CSS in indeterminate mode.
- 5.origam-progress__content
- Shared content zone. Circular: absolutely centered inside the ring. Linear: overlaid on the bar. Visible only when #default slot has content.
API
Props
Toutes les props acceptées par ce composant, avec leur type, valeur par défaut et description.
- typeTProgressType'linear'
- Determines which sub-component to render: "linear" → OrigamProgressLinear, "circular" → OrigamProgressCircular.
- bufferValuenumber | string
- Linear only. Buffer value (e.g. media buffered percentage). Renders a secondary track from 0 to bufferValue.
- clickablebooleanfalse
- Linear only. Makes the bar interactive — click sets modelValue to the clicked position. Used internally by OrigamMediaController.
- reversebooleanfalse
- Linear only. Reverses the bar direction (fills right to left).
- streambooleanfalse
- Linear only. Adds a streaming dots animation ahead of the progress bar (live media pattern).
- indeterminatebooleanfalse
- Animates continuously without a determinate value. Sets aria-valuenow to undefined.
- modelValuestring | number0
- Current progress value (0 to max). Used in determinate mode. Ignored when indeterminate=true.
- thicknessstring | number
- Thickness of the linear bar (height) or circular stroke width.
- activebooleantrue
- Controls visibility. When false, the progress bar is hidden (aria-hidden="true").
- absolutebooleanfalse
- Positions the progress bar absolutely relative to its nearest positioned ancestor.
- maxnumber | string100
- Maximum value. Normalized value = modelValue / max * 100.
- stripedbooleanfalse
- Adds animated diagonal stripes to the progress bar (linear only).
- labelstring'Loading'
- Accessible label (aria-label) on the progress bar. Pass a translated string.
- tagstring'div'
- Root HTML tag.
- idstring
- classstring | Array<string> | object
- stylestring | Array<string> | object | StyleValue
- color
- Intent or custom color applied to the progress fill and spinner stroke.
- bgColorTColor
- paddingboolean | number | string
- paddingTopboolean | number | string
- paddingLeftboolean | number | string
- paddingBottomboolean | number | string
- paddingRightboolean | number | string
- paddingBlockboolean | number | string
- paddingInlineboolean | number | string
- paddingInlineStartboolean | number | string
- paddingInlineEndboolean | number | string
- paddingBlockStartboolean | number | string
- paddingBlockEndboolean | number | string
- marginboolean | number | string
- marginTopboolean | number | string
- marginLeftboolean | number | string
- marginBottomboolean | number | string
- marginRightboolean | number | string
- marginBlockboolean | number | string
- marginInlineboolean | number | string
- marginInlineStartboolean | number | string
- marginInlineEndboolean | number | string
- marginBlockStartboolean | number | string
- marginBlockEndboolean | number | string
- Linear only. Border-radius of the bar ends. true → {radius.full}.
- roundedTopRightboolean | number | string
- roundedTopLeftboolean | number | string
- roundedBottomLeftboolean | number | string
- roundedBottomRightboolean | number | string
- roundedStartStartboolean | number | string
- roundedStartEndboolean | number | string
- roundedEndStartboolean | number | string
- roundedEndEndboolean | number | string
- locationTAnchor'top'
- Linear only. Absolute position on the screen when absolute=true: top | bottom.
- rotatestring | number0
- Circular only. Rotation offset of the SVG circle start point in degrees.
- Circular only. Overall size of the spinner. Accepts size tokens (xs → xl) or a px number.
API
Slots
Emplacements de contenu exposés par ce composant.
- #default
- Content rendered inside the progress indicator. Circular: inside the ring. Linear: overlaid on the bar. Receives normalized value (0-100) and optional buffer.
API
Emits
Événements émis par ce composant.
- @update:modelValuenumber
- Linear only, clickable=true. Fired when the user clicks the bar — payload is the new value (0 to max).
Personnalisation
Variables CSS
Propriétés CSS personnalisées exposées par ce composant. Surchargez-les pour personnaliser sans perdre la compatibilité avec le thème.
- Transition duration for the fill bar width change.
- Duration of the indeterminate bar animation cycle.
- Border-radius applied when rounded=true.
- Circular size for size="x-small".
- Circular size for size="x-large".
- Duration of the indeterminate circular spin animation.
- Color of the background ring (underlay circle).
Inclusion
Accessibilité
Rôles ARIA, navigation clavier et gestion du focus. Sourcé depuis le template réel du composant.
Rôles ARIA
Notes
- Both ProgressLinear and ProgressCircular have role="progressbar". They bind aria-valuemin="0", aria-valuemax, and aria-valuenow (undefined in indeterminate mode). aria-label comes from the label prop (defaults to "Loading").
- When active=false, the component sets aria-hidden="true" to remove it from the accessibility tree without removing it from the DOM.
- Indeterminate animations are paused under prefers-reduced-motion: reduce.
Fondation
Design tokens
Extrait des tokens de ce composant — les variables --origam-<composant>---<propriété>, déclarées dans sa feuille de tokens tenue à la main, sans étape de build.
- durationvar(--origam-motion__duration---medium)
- Linear fill bar transition duration.
- duration2200ms
- Indeterminate animation duration for the linear bar.
- dimension32px
- Default (medium) circular spinner size.
- duration1400ms
- Spin animation duration for the indeterminate circular variant.
- numbervar(--origam-opacity---50)
- Opacity of the background ring.
Interactif
Playground
Modifiez les props en direct et observez le composant se mettre à jour. Le snippet de code généré suit vos changements.
Rendu de l’aperçu en cours…
Usage
Exemples
Extraits de code prêts à coller dans vos templates.
Linear determinate
Indeterminate
Circular with value slot
Écosystème
Famille
Composants du même dossier qui partagent les conventions et se composent souvent ensemble.