v1.3.0 28

Progress

Displays an indicator showing the completion progress of a task.

Interactive Requires: veritheme.js JS init: automatic

Default

Progress bars at various fill percentages.

html

0%

25%

50%

75%

100%

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">0%</p>
  <div class="vt-progress" data-vt-progress="0">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">25%</p>
  <div class="vt-progress" data-vt-progress="25">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">50%</p>
  <div class="vt-progress" data-vt-progress="50">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">75%</p>
  <div class="vt-progress" data-vt-progress="75">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">100%</p>
  <div class="vt-progress" data-vt-progress="100">
    <div class="vt-progress-bar"></div>
  </div>
</div>

With Label

Progress bar displaying the current percentage.

html
Loading... 33%
Uploading... 67%
Complete 100%
<div>
  <div class="vt-flex vt-justify-between vt-items-center vt-mb-2">
    <span class="vt-label-md">Loading...</span>
    <span class="vt-body-sm vt-text-foreground-muted">33%</span>
  </div>
  <div class="vt-progress" data-vt-progress="33">
    <div class="vt-progress-bar"></div>
  </div>
</div>
<div>
  <div class="vt-flex vt-justify-between vt-items-center vt-mb-2">
    <span class="vt-label-md">Uploading...</span>
    <span class="vt-body-sm vt-text-foreground-muted">67%</span>
  </div>
  <div class="vt-progress" data-vt-progress="67">
    <div class="vt-progress-bar"></div>
  </div>
</div>
<div>
  <div class="vt-flex vt-justify-between vt-items-center vt-mb-2">
    <span class="vt-label-md">Complete</span>
    <span class="vt-body-sm vt-text-foreground-muted">100%</span>
  </div>
  <div class="vt-progress" data-vt-progress="100">
    <div class="vt-progress-bar"></div>
  </div>
</div>

Sizes

Small (4px), medium (8px), and large (12px) height variants.

html

Small (4px)

Medium (8px)

Large (12px)

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Small (4px)</p>
  <div class="vt-progress vt-progress-sm" data-vt-progress="60">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Medium (8px)</p>
  <div class="vt-progress" data-vt-progress="60">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Large (12px)</p>
  <div class="vt-progress vt-progress-lg" data-vt-progress="60">
    <div class="vt-progress-bar"></div>
  </div>
</div>

Colors

Brand by default. Color by meaning when the value is a state: success, warning, danger.

html

Brand

Success

Warning

Danger

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Brand</p>
  <div class="vt-progress" data-vt-progress="70">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Success</p>
  <div class="vt-progress vt-progress-success" data-vt-progress="70">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Warning</p>
  <div class="vt-progress vt-progress-warning" data-vt-progress="70">
    <div class="vt-progress-bar"></div>
  </div>
</div>

<div>
  <p class="vt-caption vt-text-foreground-muted vt-mb-2">Danger</p>
  <div class="vt-progress vt-progress-danger" data-vt-progress="40">
    <div class="vt-progress-bar"></div>
  </div>
</div>

In Context

File upload progress example.

html

Uploading Files

3 of 5 files uploaded

design-mockup.fig 100%
icon-set.svg 100%
photo-hero.jpg 100%
presentation.pdf 62%
video-demo.mp4 Queued
<div class="vt-card vt-max-w-md">
  <div class="vt-card-header">
    <h3 class="vt-card-title">Uploading Files</h3>
    <p class="vt-card-description">3 of 5 files uploaded</p>
  </div>
  <div class="vt-card-body">
    <!-- File 1 - Complete -->
    <div class="vt-flex vt-items-center vt-gap-3">
      <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-w-4 vt-h-4 vt-shrink-0 vt-text-success-fill" aria-hidden="true">
        <path d="M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 12.5L10 14.5L15.5 9.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
      </svg>
      <div class="vt-flex-1 vt-min-w-0">
        <div class="vt-flex vt-justify-between vt-items-center vt-mb-1">
          <span class="vt-label-md vt-truncate">design-mockup.fig</span>
          <span class="vt-caption vt-text-foreground-muted">100%</span>
        </div>
        <div class="vt-progress vt-progress-sm vt-progress-success" data-vt-progress="100">
          <div class="vt-progress-bar"></div>
        </div>
      </div>
    </div>
    <!-- File 2 - Complete -->
    <div class="vt-flex vt-items-center vt-gap-3">
      <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-w-4 vt-h-4 vt-shrink-0 vt-text-success-fill" aria-hidden="true">
        <path d="M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 12.5L10 14.5L15.5 9.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
      </svg>
      <div class="vt-flex-1 vt-min-w-0">
        <div class="vt-flex vt-justify-between vt-items-center vt-mb-1">
          <span class="vt-label-md vt-truncate">icon-set.svg</span>
          <span class="vt-caption vt-text-foreground-muted">100%</span>
        </div>
        <div class="vt-progress vt-progress-sm vt-progress-success" data-vt-progress="100">
          <div class="vt-progress-bar"></div>
        </div>
      </div>
    </div>
    <!-- File 3 - Complete -->
    <div class="vt-flex vt-items-center vt-gap-3">
      <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-w-4 vt-h-4 vt-shrink-0 vt-text-success-fill" aria-hidden="true">
        <path d="M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path><path d="M8 12.5L10 14.5L15.5 9.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
      </svg>
      <div class="vt-flex-1 vt-min-w-0">
        <div class="vt-flex vt-justify-between vt-items-center vt-mb-1">
          <span class="vt-label-md vt-truncate">photo-hero.jpg</span>
          <span class="vt-caption vt-text-foreground-muted">100%</span>
        </div>
        <div class="vt-progress vt-progress-sm vt-progress-success" data-vt-progress="100">
          <div class="vt-progress-bar"></div>
        </div>
      </div>
    </div>
    <!-- File 4 - In progress -->
    <div class="vt-flex vt-items-center vt-gap-3">
      <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-w-4 vt-h-4 vt-shrink-0 vt-text-brand-fill vt-animate-spin" aria-hidden="true">
        <path d="M21.9961 12C21.9961 17.5228 17.5189 22 11.9961 22C6.47325 22 1.99609 17.5228 1.99609 12C1.99609 6.47715 6.47325 2 11.9961 2" stroke="currentColor" stroke-linecap="round" stroke-width="1.5"></path>
      </svg>
      <div class="vt-flex-1 vt-min-w-0">
        <div class="vt-flex vt-justify-between vt-items-center vt-mb-1">
          <span class="vt-label-md vt-truncate">presentation.pdf</span>
          <span class="vt-caption vt-text-foreground-muted">62%</span>
        </div>
        <div class="vt-progress vt-progress-sm" data-vt-progress="62">
          <div class="vt-progress-bar"></div>
        </div>
      </div>
    </div>
    <!-- File 5 - Pending -->
    <div class="vt-flex vt-items-center vt-gap-3">
      <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" class="vt-w-4 vt-h-4 vt-shrink-0 vt-text-foreground-muted" aria-hidden="true">
        <circle cx="12" cy="12" r="10" stroke="currentColor" stroke-width="1.5"></circle><path d="M12 8V12L14 14" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5"></path>
      </svg>
      <div class="vt-flex-1 vt-min-w-0">
        <div class="vt-flex vt-justify-between vt-items-center vt-mb-1">
          <span class="vt-label-md vt-truncate vt-text-foreground-muted">video-demo.mp4</span>
          <span class="vt-caption vt-text-foreground-muted">Queued</span>
        </div>
        <div class="vt-progress vt-progress-sm" data-vt-progress="0">
          <div class="vt-progress-bar"></div>
        </div>
      </div>
    </div>
  </div>
</div>

Guidelines

Uploading... 67%
Do Pair the bar with a label and percentage so progress is legible.
Loading... ?%
Don't Don't use a determinate bar for unknown-length loading — use a skeleton.

API Reference

Class Type Description
vt-progress Base Track container — full width, muted background, pill shape
vt-progress-bar Fill The fill — brand by default; its width is the value
vt-progress-success Color Success fill — done, healthy (an upload finished, a goal reached)
vt-progress-warning Color Warning fill — close to a limit (storage almost full)
vt-progress-danger Color Danger fill — over a limit or failed (quota exceeded)
vt-progress-sm Size Small track (4px) — dense lists, per-file rows
vt-progress-lg Size Large track (12px)
vt-flexvt-justify-betweenvt-items-center Layout Label row above the progress bar
vt-text-smvt-font-medium Typography Progress label text
vt-text-smvt-text-foreground-muted Typography Percentage value text

Accessibility

Feature Details
Role Use role="progressbar" with aria-valuenow, aria-valuemin, aria-valuemax
Label Add aria-label or aria-labelledby describing what is progressing
Updates Dynamic progress changes should be announced via aria-live on the container
Indeterminate For unknown progress, omit aria-valuenow to indicate indeterminate state