The send button is disabled while generation is in progress
Why it matters
An always-enabled send button during generation lets users submit multiple messages in rapid succession, producing race conditions where two in-flight completions interleave in the UI, one overwrites the other's state, or both consume tokens against the same conversation. This also hides the current app state from the user, who has no visual signal that a generation is already in progress and assumes their first click did not register.
Severity rationale
Low because the damage is mostly wasted tokens and occasional UI glitches rather than data loss or security impact.
Remediation
In src/components/chat/ChatInput.tsx, bind the button's disabled attribute to the loading state and add visible disabled styling (reduced opacity, not-allowed cursor) so the state change is obvious. Optionally disable the textarea itself during generation.
<Button type="submit" disabled={isLoading} className="disabled:opacity-50 disabled:cursor-not-allowed">
Send
</Button>
DetectionPro
The detection method for this pattern is part of AuditBuffet Pro.
The full method (what to look for, pass and fail conditions, and how results get reported) ships inside the AI Chat Visibility Audit. The pattern definition, severity rationale, and remediation remain openly licensed under CC-BY-4.0.
Taxons
History
- 2026-04-18·v1.0.0·Initial import from ai-chat-visibility·automated