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

outdated

A textField widget to help display different style pin written in pure dart, no extra dependency.

pub package

pin_input_text_field #

中文版点我 PinInputTextField is a TextField widget to help display different style pin.

Example #

Decoration #

UnderlineDecoration

BoxLooseDecoration

BoxTightDecoration

Installing #

Install the latest version from pub.

Usage #

Attributes #

Customizable attributes for PinInputTextField

Attribute Name Example Value Description
pinLength 6 The max length of pin, the default is 6
onSubmit (String pin){} The callback will execute when user click done, sometimes is not working in Android.
decoration BoxLooseDecoration Decorate the pin, there are 3 inside styles, the default is BoxLooseDecoration
inputFormatters WhitelistingTextInputFormatter.digitsOnly Just like TextField's inputFormatter, the default is WhitelistingTextInputFormatter.digitsOnly
keyboardType TextInputType.phone Just like TextField's keyboardType, the default is TextInputType.phone
pinEditingController PinEditingController Controls the pin being edited. If null, this widget will create its own PinEditingController
autoFocus false Same as TextField's autoFocus, the default is false
focusNode FocusNode Same as TextField's focusNode
textInputAction TextInputAction.done Same as TextField's textInputAction, not working in digit mode.
enabled true Same as TextField's enabled, the default is true

ObscureStyle #

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

Known Issue #

The PinEditingController listener will execute more than once in some situations, you can filter some duplicate values in your code.

139
likes
40
pub points
97%
popularity

Publisher

verified publishertinocheng.app

A textField widget to help display different style pin written in pure dart, no extra dependency.

Repository (GitHub)
View/report issues

License

Apache-2.0 (LICENSE)

Dependencies

flutter

More

Packages that depend on pin_input_text_field