Read page as text

NIB / PLAYGROUND

Input and textarea playground — NibComponents

Try input and textarea in Flutter. Edit a value, validate it, and keep the cursor where the user left it.

Open interactive view

Edit a value, validate it, and keep the cursor where the user left it.

Read the full component guide and API

Public widgets and APIs

  • NibInput
  • NibTextarea
  • NibValidator
  • NibValidators

Example Dart code

import 'package:flutter/material.dart';
import 'package:nib_components/nib_components.dart';

NibInput(
  label: 'Display name',
  placeholder: 'Ada Lovelace',
  clearable: true,
  validator: NibValidators.required('Enter a name.'),
  onChanged: (value) { /* Update application state. */ },
)

Playground controls

ControlTypeOptions or rangeHelp
Field typechoicesingle-line, multilineSwitches between the public NibInput and NibTextarea widgets.
Current texttextAn explicit text edit replaces the field value. Style controls preserve selection.
Maximum charactersnumber12.0–280.0maxLength limits typing. A validator also checks programmatic values.
Disabledtoggle
Animate helper and error texttogglePackage default is off. This example starts with animation enabled. Uses the package’s NibMotion footer transition.
Corner radiusnumber0.0–24.0

Local candidate 0.2.2 includes controller synchronization and listener cleanup repairs; hosted older versions may differ.

NibTextarea counter uses String.length (UTF-16 code units), not a grapheme count.

Widget tests do not establish physical-device or screen-reader behavior.