indeterminate animates the bar without a percentage. The animation slows under reduced motion.
vue
Waiting for the server
Loading
For a server that reports no percentage. Under reduced motion the bar is slowed rather than stopped: a motionless loader no longer says that anything is happening, which is the one thing it exists to say.
<script setup lang="ts">
import { VProgressLinear, VTypography } from 'vectis-ui'
</script>
<template>
<div class="column">
<VProgressLinear indeterminate label="Waiting for the server" />
<VProgressLinear indeterminate tone="neutral" size="md" label="Loading" />
<VTypography variant="body-sm" tone="muted">
For a server that reports no percentage. Under reduced motion the bar is slowed rather than
stopped: a motionless loader no longer says that anything is happening, which is the one thing
it exists to say.
</VTypography>
</div>
</template>
<style scoped>
.column {
display: grid;
gap: var(--vectis-space-5);
max-inline-size: 28rem;
}
</style>
showValue displays the percentage. valuePosition writes it after the label or inside the bar, which needs size="xl". The default slot receives value, max and percent. Inside the bar it renders twice: use non-interactive content without side effects.
vue
valuePosition header55%
valuePosition start
55%55%
valuePosition center
55%55%
valuePosition end
55%55%
A slot of your own7 of 12 files
<script setup lang="ts">
import { VProgressLinear, type ProgressLinearValuePosition } from 'vectis-ui'
const POSITIONS: ProgressLinearValuePosition[] = ['header', 'start', 'center', 'end']
</script>
<template>
<div class="column">
<!-- Inside the bar the slot renders twice; keep it non-interactive and free of side effects. -->
<VProgressLinear
v-for="position in POSITIONS"
:key="position"
:value="55"
:size="position === 'header' ? 'sm' : 'xl'"
show-value
:value-position="position"
:label="`valuePosition ${position}`"
/>
<VProgressLinear :value="7" :max="12" label="A slot of your own">
<template #default="{ value, max }">{{ value }} of {{ max }} files</template>
</VProgressLinear>
</div>
</template>
<style scoped>
.column {
display: grid;
gap: var(--vectis-space-5);
max-inline-size: 28rem;
}
</style>
Orientation
orientation="vertical" fills from bottom to top. Set a height to control the bar’s length.
Content replacing the percentage. Receives value, max and percent. Renders twice inside the bar; keep content non-interactive and free of side effects.
Types
Types used in the API tables. Import exported types from vectis-ui.
export interface ProgressLinearSlotProps {
value: number
max: number
percent: number
}