--- title: "Prompt Input" slug: prompt-input category: component type: overview version: 20.0.0 tokens: 509 source: https://ovh.github.io/design-system/v20.0.0/llms/react-components-prompt-input.txt --- # Prompt Input _The **Prompt Input** component is a composable text input with a submit button, designed for conversational and AI-driven interfaces._ ## Props | Property | Type | Required | Default | Description | |---|---|---|---|---| | `defaultValue` | `string` | No | undefined | The initial textarea value. Use when you don't need to control the value of the textarea. | | `disabled` | `boolean` | No | undefined | Whether the component is disabled. | | `fileCollection` | `File[]` | No | undefined | Array of the files associated with the prompt input. | | `i18n` | `Partial` | No | undefined | Internal translations override. | | `loading` | `boolean` | No | undefined | Whether the component is in loading state. | | `locale` | `'de' | 'en' | 'es' | 'fr' | 'it' | 'nl' | 'pl' | 'pt'` | No | undefined | The locale used for the translation of the internal elements. | | `name` | `string` | No | undefined | The name of the textarea form element. Useful for form submission. | | `onFileChange` | `(detail: PromptInputFileChangeDetails) => void` | No | undefined | Callback fired when a file change is triggered on the file-upload button. | | `onInputSubmit` | `(detail: PromptInputInputSubmitDetails) => void` | No | undefined | Callback fired when the prompt input is submitted. | | `onValueChange` | `(detail: PromptInputValueChangeDetails) => void` | No | undefined | Callback fired when the prompt input text value changes. | | `readOnly` | `boolean` | No | undefined | Whether the component is readonly. | | `value` | `string` | No | undefined | The controlled textarea value. | ## Examples - Default - Disabled - Read Only - Loading - With Files - In Form Field - Accessibility Aria Label - Accessibility Buttons Labels - Accessibility I18n - Accessibility Loading State ## Documentation pages - [Documentation](./react-components-prompt-input--documentation.txt) - [Technical Information](./react-components-prompt-input--technical-information.txt) - [Examples](./react-components-prompt-input--examples.txt)