pin_input_text_field 0.2.0 copy "pin_input_text_field: ^0.2.0" to clipboard
pin_input_text_field: ^0.2.0 copied to clipboard

outdated

A textField widget to help display different style pin

pin_input_text_field #

A textField widget to help display different style pin

Example #

Decoration #

UnderlineDecoration

BoxLooseDecoration

BoxTightDecoration

ObscureStyle #

/// Determine whether replace [obscureText] with number.
final bool isTextObscure;
/// The display text when [isTextObscure] is true
final String obscureText;

Installing #

Install the latest version from pub.

Usage #

PinEditingController _pinEditingController = PinEditingController();
PinDecoration _pinDecoration = UnderlineDecoration(textStyle: _textStyle);
static final TextStyle _textStyle = TextStyle(
  color: Colors.black,
  fontSize: 24,
 );
bool _obscureEnable = false;
PinEntryType _pinEntryType = PinEntryType.underline;

PinInputTextField(
                pinLength: 4,                                   /// The length of the pin.
                decoration: _pinDecoration,                     /// Control the display of text and border.
                pinEditingController: _pinEditingController,    /// Control pin and observe pin.
                autoFocus: true,    
                onSubmit: (pin) {
                    /// Add action to handle submit.
                    debugPrint('submit pin:$pin');
                },
              ),
139
likes
0
pub points
97%
popularity

Publisher

verified publishertinocheng.app

A textField widget to help display different style pin

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on pin_input_text_field