Fine-tune light, shadows, borders, neumorphic
Light and shadows
Borders
Neumorphic
Forms Form-associated

Textarea <pm-textarea>

Multi-line text input that grows with content (between rows and max-rows). show-count adds a live character counter (announced politely near the limit). Ctrl/⌘+Enter submits the form.

Full screen

Props

<script type="module"> import '@prismora/css'; import '@prismora/elements/textarea'; </script> <pm-textarea label="Message" rows="3" max-rows="8" maxlength="280" show-count placeholder="Say hello… (Ctrl+Enter sends)"></pm-textarea>

Sizes

Set with the size attribute; controls keep touch-sized targets on phones.

size="xs"
size="sm"
size="md"
size="lg"
size="xl"

States

Each state is one attribute.

Disabled
Read-only
Required
Error
With a hint

Attributes

AttributeTypeDefaultDescription
placeholderstring—Hint text shown while empty (not a replacement for label).
rowsnumber—Visible lines before it starts to grow.
maxlengthnumber—Maximum number of characters.
max-rows
prop: maxRows
number—Stop growing after this many lines (then scroll).
show-count
prop: showCount
booleanfalseShow "n / max" under the field.
autocompletestring—Browser autofill hint (the HTML autocomplete token).
namestring—Form field name: the value is submitted under it.
valuestring—Current value (submitted with the form).
labelstring—Visible label (required for accessibility; use hide-label to visually hide it).
hintstring—Help text under the field, linked to it for screen readers.
errorstring—Custom error message. Setting it marks the control invalid.
size'xs' | 'sm' | 'md' | 'lg' | 'xl'—Control size.
requiredbooleanfalseThe form cannot be submitted until this has a value.
disabledbooleanfalseNot interactive and not submitted.
readonlybooleanfalseFocusable and submitted, but not editable.
hide-label
prop: hideLabel
booleanfalseHide the label visually; it stays the accessible name.

Also accepts the contextual attributes tone, surface, radius, density, motion, elevation. They are inherited from ancestors' data-* attributes.

Events

EventReact / Svelte propDescription
pm-inputonPmInputOn every value change while editing.
pm-changeonPmChangeWhen the value is committed.

Methods

checkValidity(), reportValidity(), validate(), focus()

Used in templates

Customer 360InboxProject boardTeam and rolesUser profileAccount settingsProduct pageContactAppointment bookingFeedback survey