Skip to content
View Markdown

TextField ​

A field for editing a line of text.

tsx
import { TextField } from '@satinhq/kit'

Example ​

Click the Name field and type. Try the system keyboard on a device.

Bind the text ​

Keep the text in React state. Pass the string to value and its setter to onChange.

Name the field ​

Use label for its accessible name. A prompt supplies placeholder text when the field is empty.

Choose keyboard and Return behavior ​

Set kind to describe the value, such as name, email or decimal. submitLabel supplies the Return-key hint; onSubmit handles Return in a single-line field.

API ​

Scroll horizontally to read every column.

PropTypeDescription
labelstringThe accessible name.
valuestringThe current text.
onChange(value: string) => voidReceives edited text.
promptstringOptional placeholder.
kindTextFieldKindKeyboard and autofill intent.
submitLabelSubmitLabelReturn-key hint.
onSubmit() => voidSingle-line Return action.

Related: Quick start, List, Screen.

:::

Satin runs on the Lumen rendering engine and is open source under the MIT License.