import type { ReactNode } from 'react'; export type Question = string | { q: ReactNode; options?: string[]; recommend?: string }; /** * Open questions block — only ever at the BOTTOM of a document. Lists * decisions still needed before implementation, with optional options and a * recommended default. */ export function QuestionForm({ questions, title = 'Open questions' }: { questions: Question[]; title?: string }) { if (!questions.length) return null; return (
{title}
    {questions.map((raw, i) => { const it = typeof raw === 'string' ? { q: raw } : raw; return (
  1. {it.q}
    {it.options?.length ? (
    {it.options.map((o) => ( {o}{o === it.recommend ? ' ★' : ''} ))}
    ) : null}
  2. ); })}
); }