component

Textarea

props · 36 shown · 36 total

TextareaRoot

Appearance

  • "transparent" "surface.peak" "surface.hill" "surface.base" "surface.valley" "surface.ground"
    default surface.ground

    Background surface variant for the textarea.

  • "none" "default" "bold" "muted" "accent"
    default default

    Border variant for the textarea wrapper.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Corner radius override. Without it the corner follows the size tier (`control.<size>`). `inner` renders a concentric corner computed from the nearest parent panel (parent radius − parent padding, floored at `2xs`).

  • "lg" "md" "sm" "xs"
    default "md"

    Size variant. All sizes share the same height system as inputs and buttons (`xs`, `sm`, `md`, `lg`); it sets the minimum (single-row) height.

  • "inherit" "cyan" "danger" "dynamic" "mauve" "neutral" "pink" "primary" "sage" "slate" "stone" "success" "teal" "violet" "warning"
    default "neutral"

    Semantic tone color scheme used to indicate validation state or context. `neutral` is the default, `primary` uses the primary color, `success` green, `danger` red, and `warning` orange.

Layout

  • boolean

    When true, the textarea stretches to fill the available width of its container.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the bottom-left and bottom-right corners.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the top-left and bottom-left corners.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the top-right and bottom-right corners.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the top-left and top-right corners. Overrides `radius` on those corners only (flush-edge chains).

Advanced

  • Pick<TextareaPassThrough<RootElementAttributes>, "root">

    Per-slot escape hatch for custom styling and props on the wrapper.

  • boolean
    default false

    Astro / vanilla: serialize the props into `data-textarea-config` so the client runtime hydrates this instance and `getPindoba(el, "textarea")` can `update()` it. Frameworks with their own reactivity don't need it.

TextareaField

Behavior

  • boolean
    default false

    When true, the textarea auto-grows to fit its content (the framework wires a small resize behavior keyed on `data-auto-resize`). Pair with `resize="none"` so the drag handle doesn't fight the auto height.

  • "none" "both" "horizontal" "vertical"
    default "vertical"

    Which directions the native drag-resize handle allows.

  • number

    Number of visible text rows — sets the initial height of the `<textarea>`.

Advanced

  • { root?: TextareaSlotPassThrough<TextareaElementAttributes> }

    Per-slot escape hatch for custom styling and props on the `<textarea>`.

  • boolean
    default false

    Astro / vanilla: serialize the props into `data-textarea-field-config` so the client runtime hydrates this instance and `getPindoba(el, "textarea-field")` can `update()` it. Frameworks with their own reactivity don't need it.

Textarea

State

  • value svelte
    string

    Bindable current value of the textarea.

Appearance

  • "transparent" "surface.peak" "surface.hill" "surface.base" "surface.valley" "surface.ground"
    default surface.ground

    Background surface variant for the textarea.

  • "none" "default" "bold" "muted" "accent"
    default default

    Border variant for the textarea wrapper.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Corner radius override. Without it the corner follows the size tier (`control.<size>`). `inner` renders a concentric corner computed from the nearest parent panel (parent radius − parent padding, floored at `2xs`).

  • "lg" "md" "sm" "xs"
    default "md"

    Size variant. All sizes share the same height system as inputs and buttons (`xs`, `sm`, `md`, `lg`); it sets the minimum (single-row) height.

  • "inherit" "cyan" "danger" "dynamic" "mauve" "neutral" "pink" "primary" "sage" "slate" "stone" "success" "teal" "violet" "warning"
    default "neutral"

    Semantic tone color scheme used to indicate validation state or context. `neutral` is the default, `primary` uses the primary color, `success` green, `danger` red, and `warning` orange.

Layout

  • boolean

    When true, the textarea stretches to fill the available width of its container.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the bottom-left and bottom-right corners.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the top-left and bottom-left corners.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the top-right and bottom-right corners.

  • "inherit" "lg" "md" "sm" "xs" "none" "2xl" "xl" "inner" "2xs" "3xl" "4xl" "5xl" "6xl" "full"

    Border radius for the top-left and top-right corners. Overrides `radius` on those corners only (flush-edge chains).

Behavior

  • boolean
    default false

    When true, the textarea auto-grows to fit its content.

  • "none" "both" "horizontal" "vertical"
    default "vertical"

    Which directions the native drag-resize handle allows.

  • number

    Number of visible text rows — sets the initial height of the `<textarea>`.

Slots

  • leading slot svelte
    Snippet

    Leading addon content (icon/badge), rendered inside an affix box the Control Var Contract aligns. Pass a `<Stamp emphasis="ghost">` for icons; style the box via `passThrough.leading`.

  • trailing slot svelte
    Snippet

    Trailing addon content, rendered inside an end-pinned affix box.

Advanced

  • element binding svelte
    HTMLTextAreaElement null

    Bound reference to the inner `<textarea>` element (`bind:this`).

  • TextareaPassThrough< RootElementAttributes, TextareaElementAttributes >

    Per-slot escape hatch for custom styling and props. Each slot accepts a Panda CSS `style` object and a `props` bag of arbitrary HTML attributes.

  • boolean
    default false

    Astro / vanilla: serialize the props into `data-textarea-config` so the client runtime hydrates this instance and `getPindoba(el, "textarea")` can `update()` it. Frameworks with their own reactivity don't need it.

Plus all standard <textarea> HTML attributes.

Type

  • Components
  • Blocks