Files
fn_registry/frontend/functions/ui/textarea.md
T
egutierrez 35bcb63300 feat: nuevos componentes UI — accordion, avatar, breadcrumb, checkbox, command, dropdown, pagination, popover, radio, sheet, select, switch, textarea, toast
Componentes React accesibles basados en Radix UI con soporte de temas via CSS variables. Incluye barrel export en index.ts.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 03:23:32 +02:00

1.7 KiB

name, kind, lang, domain, version, purity, signature, description, tags, uses_functions, uses_types, returns, returns_optional, error_type, imports, tested, tests, test_file_path, file_path, props, emits, has_state, framework, variant
name kind lang domain version purity signature description tags uses_functions uses_types returns returns_optional error_type imports tested tests test_file_path file_path props emits has_state framework variant
textarea component ts ui 1.0.0 impure Textarea(props: TextareaProps): JSX.Element Input multilinea accesible con auto-resize opcional. Patron identico a Input para consistencia de estilos.
textarea
component
ui
interactive
form
cn_ts_core
false
false
frontend/functions/ui/textarea.tsx
name type required description
autoResize boolean false Ajusta la altura automaticamente al contenido (default: false)
name type required description
placeholder string false Texto placeholder
name type required description
disabled boolean false Deshabilita el textarea
name type required description
rows number false Numero de filas visibles iniciales
name type required description
className string false Clases CSS adicionales
onChange
onFocus
onBlur
true react

Ejemplo

// Basico
<Textarea placeholder="Escribe aqui..." rows={4} />

// Con auto-resize
<Textarea autoResize placeholder="Crece automaticamente..." />

// Controlado
<Textarea value={text} onChange={(e) => setText(e.target.value)} />

// Con validacion
<Textarea aria-invalid={!!error} />

Notas

Usa forwardRef para compatibilidad con form libraries. El auto-resize ajusta style.height en cada cambio — por eso requiere has_state: true. Aplica las mismas clases de foco y validacion que Input para consistencia visual.