Browse docsTextarea

ControlsNew

Glass Textarea

A recessed glass field for longer text that can grow as you type.

pnpm dlx shadcn@4.14.1 add @glassyui/glass-textarea

Preview

Grows as you type, up to five rows.

Demos ready. Update 0.

Installation

First add the exact @glassyui mapping to components.json as shown in Getting Started. Then run the pinned item command:

Install Glass Textarea

pnpm dlx shadcn@4.14.1 add @glassyui/glass-textarea
What this installs6 files, 1 package

Direct registry declarations

These values belong to @glassyui/glass-textarea itself in registry.json.

Package dependencies

  • clsx

Registry dependencies

  • @glassyui/glass-provider

File targets

  • components/glassyui/glass-textarea.tsx
  • components/glassyui/lib/merge-refs.ts

Complete installed closure

This follows every namespaced registry dependency recursively and de-duplicates the packages and target files installed with this item.

Package dependencies

  • clsx

Installed files

  • components/glassyui/glass-textarea.tsx
  • components/glassyui/lib/merge-refs.ts
  • components/glassyui/glass-provider.tsx
  • components/glassyui/liquid-filters.tsx
  • components/glassyui/lib/preferences.ts
  • components/glassyui/styles/liquid.css

Usage

Usage

import { GlassTextarea } from "@/components/glassyui/glass-textarea";

export function MessageDemo() {
  return <GlassTextarea autoResize label="Message" hint="Grows as you type." placeholder="Say hello…" />;
}

Examples

Limit the growth

<GlassTextarea autoResize maxRows={5} label="Notes" />
Fixed height with a resize handle

<GlassTextarea rows={6} label="Bio" />

API

GlassTextarea

Forward-ref native textarea styled like GlassInput.

GlassTextareaProps

Native textarea props plus label, hint, autoResize and maxRows.

label

Optional visible label rendered above the field.

hint

Optional helper text rendered below the field.

autoResize

Grows with its text, up to maxRows, then scrolls.

maxRows

The most rows an auto-resizing textarea grows to. Defaults to 8.

Notes

Rewrapping

An auto-resizing field fits again when its width changes and the text rewraps.

Accessibility

Keep the Radix-backed semantics intact and preserve visible labels, focus states, and keyboard operation when copying the source.

Performance

Use provider quality preferences for dense app screens. Reserve strong refraction for hero or showcase surfaces.