# Text Input & Textarea
URL: /components/text-input
Source: https://github.com/daangn/seed-design/blob/dev/docs/content/components/text-input.mdx
A component that receives text input from users.
## Text Input
A component that receives single-line text input.
You can use Text Input within Field to utilize it as a Text Field.
### Anatomy
![Text Input Anatomy image. Composed of input field, Container, Clear Button, and Prefix/Suffix Slot.]()
Text Input is composed of an input field, a Container that wraps it, an optional Clear Button, and Prefix/Suffix Slots.
### Properties
#### State
![Text Input State - Enabled, Focused, Error, Error Focused, Disabled, Read Only, AI Loading]()
Text Input has Enabled, Focused, Error, Error Focused, Disabled, Read Only, and AI Loading (Figma Only) states.
#### Has Value Property
![Text Input Has Value Property]()
You can use Has Value Property when Text Input has a value.
#### Clear Button Property
![Text Input Clear Button Property]()
When Text Input has a value, you can display a Clear Button that deletes the value at once.
#### Variant
![Text Input Variant - Outline, Underline]()
Text Input provides two styles: Outline and Underline.
![Example of using Underline Variant for the only Text Input on screen]()
It is recommended to use Underline when there is only one Input on the screen.
### Custom Input
![Example of Text Input Custom Input]()
Text Input's input area is composed of Slots.
When special formatting or masking functions are needed, you can define and use the format and behavior directly.
### Composing Text Input in 2 Columns
When there is much content to input on one screen, Input can be composed in a 2-column layout.
{/*
*/}
It is recommended to use this only when labels and input values are short. Ensure sufficient spacing between layouts so users do not accidentally select the adjacent Input.
For input formats with a fixed format, such as resident registration numbers or phone numbers, do not divide Inputs. Instead, automatically apply the format to the value so input can be done at once without additional interaction.
***
## Textarea
A component that can receive multiple lines of text input and supports auto-resize.
You can use Textarea within Field to utilize it as a Textarea Field.
### Anatomy
![Textarea Anatomy image. Composed of input field and Container.]()
Textarea is composed of an input field and a Container that wraps it.
### Properties
#### State
![Textarea State - Enabled, Focused, Error, Error Focused, Disabled, Read Only, AI Loading]()
Textarea has Enabled, Focused, Error, Error Focused, Disabled, Read Only, and AI Loading (Figma Only) states.
#### Has Value Property
![Textarea Has Value Property]()
You can use Has Value Property when Textarea has a value.
#### Auto Size
![Textarea Auto Size option - automatic height adjustment]()
When using the Auto Size option, the Textarea height automatically expands based on the number of characters entered. In this case, the minimum height of Textarea should be maintained at 3 lines (95px). Maximum height has no limit by default, and can be specified separately if needed.
![Textarea scroll behavior when Auto Size is disabled]()
When Auto Size is disabled, the minimum height should be 2 lines (70px). In this case, a maximum height value must be specified, and if the content exceeds the maximum height, scrolling is created within the Input area.
## Specification
Component spec (JSON): /rootage/components/text-input.json