Calm motion: animations on this site only fade, with no movement
Questionnaire
Multi-step single/multiple/freeform
A short survey, one question at a time: onboarding questions, feedback, a quiz. For a form people fill in at once, use Form with Fields.
It handles the step header, the input for each question type, required answers, skipping and the progress bar. Answers collect into one object bound with v-model. For a wizard with arbitrary panels, Stepper.
Basic
{}- Questions are
single,multipleorfreeform.required(default) blocks Next with a message. On each step focus moves to the new question, so it is read. - With
shortcuts, 1–9 pick choices (Ctrl / ⌘ / Alt + digit stay with the browser).
Usage
ts
import { BlessQuestionnaire } from "blessing-ui";API
Props
| Name | Type | Default | Description |
|---|---|---|---|
questions* | BlessQuestion[] | — | |
shortcuts | boolean | true | 1-based shortcut keys for choices |
labels | Partial<{ next: string; previous: string; skip: string; submit: string; required: string; }> | — | |
modelValue | BlessAnswers | {} | |
step | number | 0 |
Events
| Name | Payload | Description |
|---|---|---|
update:modelValue | [value: BlessAnswers] | |
submit | [answers: BlessAnswers] | |
skip | [question: BlessQuestion] | |
update:step | [value: number] |