UI

Textarea

One or more line input that allows writing large texts.

Import Textarea

Tremor exports one component for Textarea.

import { Textarea } from '@tremor/react';

Usage example

The example below shows text input examples with a Card, Textarea and a Button component.

API Reference: Textarea

client component
defaultValue
string
The default of Textarea when it is initially rendered. Use when you do not need to control its state.
value
string
The controlled state of Textarea. Must be used in conjunction with onChange.
onValueChange
(value: string) => void
Event handler called when the state of the input changes.
placeholder
string
Sets the placehoder text
error
boolean
If true, the text input is labeled as invalid.
errorMessage
string
Text to be displayed if the error prop is set to `true`.
disabled
boolean
If true, the text input will be disabled.

Theming

Text Input

Roundness
borderRadiustremor-default
Shadow
boxShadowtremor-input
Font size
fontSizetremor-default
Border color
colorstremor-border-DEFAULT
Border color focus
colorstremor-brand-subtle
Ring color focus
colorstremor-brand-muted
Background color
colorstremor-background-DEFAULT
Background color disabled
colorstremor-background-subtle
Background color hover
colorstremor-background-muted
Text color placeholder
colorstremor-content-DEFAULT
Text color input
colorstremor-content-emphasis
Text color disabled
colorstremor-content-muted