diff --git a/opentrons-ai-client/src/organisms/PromptButton/index.tsx b/opentrons-ai-client/src/organisms/PromptButton/index.tsx index f5f735cfda1..452a615e67b 100644 --- a/opentrons-ai-client/src/organisms/PromptButton/index.tsx +++ b/opentrons-ai-client/src/organisms/PromptButton/index.tsx @@ -34,10 +34,14 @@ export function PromptButton({ buttonText }: PromptButtonProps): JSX.Element { React.useContext(setPromptContext) const setPrompt = usePromptSetValue() - const handleClick = useCallback(() => { - const { prompt } = PROMPT_BY_NAME[buttonText] - setPrompt(prompt) - }, [setPrompt, buttonText]) + const handleClick = useCallback( + (event: React.MouseEvent) => { + const { prompt } = PROMPT_BY_NAME[buttonText] + setPrompt(prompt) + event.currentTarget.blur() + }, + [setPrompt, buttonText] + ) return {buttonText} }