flutter_pin_text_field 2.0.0
flutter_pin_text_field: ^2.0.0 copied to clipboard
A highly customizable PIN input widget for Flutter with extensive styling options, multiple border types, and reliable input handling.
Changelog #
All notable changes to this project will be documented in this file.
2.0.0 - 2025-10-04 #
✨ Features #
- Complete rewrite: Rebuilt the entire PIN input component from scratch
- Configurable PIN length: Support for any number of PIN digits (not limited to 6)
- Comprehensive styling system: New
PinStyleclass with extensive customization options - Multiple border types: Support for
underline,outline, andnoneborder styles - Background color support: Configurable background colors for normal and focused states
- Auto-focus management: Automatic focus transition between input fields
- Reliable deletion logic: Improved backspace handling with
KeyboardListener - Input validation: Built-in support for numeric-only input with
FilteringTextInputFormatter
🎨 Styling Options #
- Configurable width, height, and spacing
- Custom font size and colors
- Border customization (color, width, radius)
- Background color support
- Cursor color customization
🔧 API Changes #
- BREAKING: Replaced old
PinTextFieldconstructor parameters withPinStyleconfiguration - BREAKING: Changed callback signature from
onFinishedtoonCompleted - NEW: Added
onChangedcallback for real-time input tracking - NEW: Added
autoFocus,enabled, andkeyboardTypeproperties
🚀 Improvements #
- Better performance with optimized state management
- Cleaner and more maintainable codebase
- Type-safe API with proper enums
- Enhanced example app with multiple style demonstrations
- Improved documentation and code comments
🐛 Bug Fixes #
- Fixed deletion logic issues where backspace would stop working
- Resolved focus management problems
- Fixed state synchronization between input fields