A focused prompt surface with growing input, composable actions, and submission state.
Ready to send
Copy the command below and run it in your terminal.
Bind the prompt value and handle submission on the root. The component awaits async handlers and shows its submitting state automatically.
By default, Enter submits and Shift + Enter inserts a
new line. Set submitOnEnter=false on Input when Enter should
always create a new line.
Use explicit states when submission is managed outside the component.
PromptComposer.Root - Manages prompt submission.
PromptComposer.Input - Accepts the prompt text.
PromptComposer.Toolbar - Groups composer controls.
PromptComposer.Actions - Groups composer actions.
PromptComposer.Submit - Submits or stops the prompt.