Skip to content

QTI Interactions

QTI Editor ships its interactions as focused packages. Each @qti-editor/interaction-* package adds the schema, commands, serialization, and editor wiring for one QTI interaction type.

These packages are closely coupled to our other open source library, qti-components. In practice, QTI Editor is responsible for authoring behavior and document structure, while qti-components supplies the underlying QTI web components that render and encapsulate the interaction behavior itself. That split keeps the integration framework agnostic while letting each interaction package stay small and explicit.

When you install an interaction package, its matching @qti-components/* dependency is pulled in automatically. You typically install only the interactions your product needs.

Available interactions

InteractionWhat it doesPackage
Choice InteractionSingle- or multiple-choice questions with a prompt and selectable choices@qti-editor/interaction-choice
Inline Choice InteractionDropdown choices embedded directly in a sentence@qti-editor/interaction-inline-choice
Text Entry InteractionShort free-text answers entered inline@qti-editor/interaction-text-entry
Extended Text InteractionLonger free-text answers in a multi-line response area@qti-editor/interaction-extended-text
Match InteractionMatching items across two sets@qti-editor/interaction-match
Order InteractionOrdering a list of choices into the correct sequence@qti-editor/interaction-order
Select Point InteractionClicking a coordinate or hotspot on an image@qti-editor/interaction-select-point

Installing interactions

Install only the packages you need, for example:

Terminal window
pnpm add \
@qti-editor/interaction-choice \
@qti-editor/interaction-inline-choice \
@qti-editor/interaction-text-entry

Each package exports ProseMirror commands and schema pieces that you register into your editor setup. The framework guides and framework guides show complete integration examples.