Simal UI
Components

TextField

Import

import { TextField } from '@simal/ui/nativewindui';

Props

PropValuesDefaultDescription
label"Field label"Floating label on Material, leading label on iOS. Not a placeholder — it stays visible once the field has a value.
placeholder"Placeholder text"Hint shown while the field is empty. On Material it is hidden until the label has floated, so it never overlaps.
errorMessageAny non-empty string switches the field to its error styling and renders below it. Presence is the trigger; there is no separate hasError.
editablebooleantrueFalse renders a read-only field that still looks like a field. Use it for values a user can see but not change.
materialVariantoutlined · filled"outlined"Material styling only; ignored on iOS, which has one field style.
materialClearAccessibilityLabel"Clear field value"Accessible name for the Material clear button. Override when the field needs more context, such as “Clear company name”.
leftViewNode inside the field, before the input — a currency prefix or icon. Add your own padding; the field adds none.
rightViewNode inside the field, after the input. Replaces the built-in clear button when present.
valueMakes the field controlled. Pair with onChangeText, or the field will not accept typing.

Examples

Variants

With Error

With Adornments

Read Only

On this page