View as markdown

Quiz

A quiz block lets a slide pose a question and capture the visitor's answer. Common uses: pre-qualifying leads, gating slide advancement on correct answers (corporate training), and personalizing follow-up.

Authoring a quiz

In the slide editor, click Quiz in the top toolbar to insert a quiz element. The right-pane inspector exposes:

  • Question — the prompt shown to the visitor
  • Options — up to 8 answer options. Each has a Label field and a Correct toggle. Multiple options can be marked correct when "Allow multiple selections" is on.
  • Allow multiple selections — let the visitor pick more than one option (renders as checkboxes instead of radios)
  • Feedback when correct — text shown after a correct answer
  • Feedback when incorrect — text shown after an incorrect answer

The agent receives the visitor's answer as a structured event and can branch its script accordingly (e.g., "Great, you picked Quality — let me show you our premium tier").

Display modes

json
{
  "type": "quiz",
  "display": "expanded",
  "question": "Which is more important to you?",
  "options": [
    { "id": "speed",   "label": "Speed" },
    { "id": "quality", "label": "Quality", "correct": true }
  ]
}

The schema supports two display modes:

  • expanded (default) — full question + options render inline at the slide's authored position. The mode you'll use 99% of the time.
  • collapsible — compact "QUIZ · N questions" card that expands on click. Useful when the slide already has a primary visual and you don't want the quiz to dominate.

collapsible is set via JSON only today. The schema and runtime support it (PR #94 shipped the renderer), but the inspector doesn't expose a toggle yet — you can flip it via PPTX import or by editing the slide's raw schema. A UI toggle is on the roadmap.

Quiz badge

When a slide carries a quiz, the published view surfaces a small "Quiz" badge in the top-right of the content card to give visitors a heads-up. The badge is suppressed on V2 slides where the quiz renders at its authored position inside the canvas (the badge would visually overlap the quiz itself).

Schema reference

NameTypeDescription
type*"quiz"Discriminator
question*stringThe prompt shown to the visitor
options*Array<{ id: string; label: string; correct?: boolean }>2–8 options. `correct: true` marks the right answer(s).
multiSelectbooleanAllow multiple selections (default: false)
feedbackOnCorrectstringText shown after a correct answer
feedbackOnIncorrectstringText shown after an incorrect answer
display"expanded" | "collapsible"Render as full block (default) or collapsible card. UI toggle pending.