@brickslab./ui-webQuiz
Dynamic renderer that dispatches to the correct input UI based on question.type. Supports single, multi, scale, NPS, rating, and text types natively; remaining types (matrix, rank, range, date, file) are fulfilled by Family 2 components.
Single choice
Multi choice (inline)
Scale / Likert
NPS (0–10)
Free text
Props
| Prop | Type | Défaut | Requis | Description |
|---|---|---|---|---|
question | Question | — | ✓ | Question schema object including type, options, and config. |
value | Answer | — | ✓ | Current answer value (controlled). |
onChange | (answer: Answer) => void | — | ✓ | Called with the new answer on user interaction. |
disabled | boolean | false | — | Disables all interaction. |
showValidation | boolean | false | — | Triggers validation state display. |
layout | "stack" | "inline" | "grid" | "stack" | — | Controls option arrangement for choice questions. |
Override rapide
Tous les paramètres listés dans cette table sont overrideables via les props. Utilisez ce squelette comme point de départ.
<MyComponent
question={...}
value={...}
onChange={...}
disabled={false}
showValidation={false}
layout="stack"
/>questionvalueonChangedisabledshowValidationlayout