Currently brewing — dede is in beta: a first set of components, with more to come. The API may still change.

Textarea

A box for several lines of text.

import { Textarea } from "@dede-style/ui/textarea", then <Textarea value={v} onChange={setV} />. It is controlled: pass the text in value, and onChange gives you the new text as a string. Put it in a Field to give it a label.

PropDescriptionDefaultControl
valuethe text. Controlled: pass it with onChange
rowsthe height in lines: 2, 3 (default), 4, 5, 6 or 8. It is also the smallest the box can be dragged to2345683
  • 2
  • 3
  • 4
  • 5
  • 6
  • 8
resizevertical (default) lets the person drag the box taller; none removes the drag handle. Never sidewaysverticalnonevertical
autoSizegrows the box as the person types, from rows up. Works in Chrome and Edge 123+, Safari 26.2+ and Firefox 152+; older browsers keep the rows height and the drag handlefalse
variantframe (default) draws the box; plain has no box, only the focus ringframeplainframe
sizethe text size and padding of a TextInput of this size (32, 40 or 48px), so the two line up in a form. The height comes from rows8101210
  • 8
  • 10
  • 12
placeholderan example of what to write, shown until something is typed. Not a label
requiredrequires a value before the form submits. No asterisk is shown; mark optional fields in their labelfalse
disableddisables the field and dims it. Prefer readOnly when the text should still be read or copiedfalse
readOnlythe text can be read, selected and copied, and is submitted, but not editedfalse
maxLengththe most characters allowed. There is no counter

Tokens

What a theme can move, where the props above are what an instance can move.

TokenDescriptionValue
--text-input-radiusthe corner. It is TextInput’s token, because a Textarea uses TextInput’s box. Changing it changes the corners of TextInput, Select and Textarea together, so they match in a form--radius-4

A token appears here only when the value is not already reachable. Anything that resolves through a foundation token or a role needs none, because overriding that already moves it — and a second dial wired to the same value would let this one component drift from everything sharing the role. What is left is the values with no other lever at all.

These are public and overridable — there is no private custom property, because anything on :root is reachable by any stylesheet. What replaces privacy is a stability contract: primitives may move, roles are the guarantee, and these are the per-component escape from both.