Component
ClarifyForm
Ask only for the one fact that blocks the work, then collapse it.
One question, choice chips, and an optional field. After an answer, the form becomes a summary row.
Do
- Ask the single fact the brief does not already contain.
- Collapse the question into the answer.
- Offer a few chips and room to type something else.
Don't
- Ask for city, date, and budget in one form.
- Leave the empty form sitting under the answer.
- Invent a choice the person did not make.
Props
| Prop | Type | Description |
|---|---|---|
| question | string | The one missing fact, written as a question. |
| detail | string | Why this is the blocker, in one sentence. |
| choices | Choice[] | Short options. Not a menu of everything possible. |
| allowCustom | boolean | Shows an optional field beside the chips. |
| answered | ClarifyAnswer | null | When set with collapsed, the form becomes a row. |
| onSubmit | (answer) => void | The person's answer. |
A2UI message
v0.9.1 envelope. catalogId is latch://catalog/v1. The preview under the message is rendered by the adapter, not hand-built.
JSON
[
{
"version": "v0.9.1",
"createSurface": {
"surfaceId": "budget",
"catalogId": "latch://catalog/v1"
}
},
{
"version": "v0.9.1",
"updateComponents": {
"surfaceId": "budget",
"components": [
{
"id": "root",
"component": "ClarifyForm",
"question": "What budget should this stay under?",
"detail": "City, month, and headcount are already in the brief.",
"answerLabel": "Budget",
"allowCustom": true,
"customLabel": "Other amount",
"choices": [
{
"value": "8000",
"label": "€8,000"
},
{
"value": "15000",
"label": "€15,000"
},
{
"value": "25000",
"label": "€25,000"
}
],
"state": "needs-input",
"action": {
"event": {
"name": "answer_budget"
}
}
}
]
}
}
]