Skip to content

This package provides the ability to implement OutlineTextField with simple settings.

License

Notifications You must be signed in to change notification settings

Dev-hwang/simple_text_field

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This package provides the ability to implement OutlineTextField with simple settings. It includes all the options provided by TextField, and also includes options to block white space and special characters.

pub package

Getting started

To use this package, add simple_text_field as a dependency in your pubspec.yaml file. For example:

dependencies:
  simple_text_field: ^3.2.0

How to use

To block white space and special characters, use the following:

SimpleTextField(
  allowWhiteSpace: false,
  allowSpecialCharacters: false,
),

Instead of writing repetitive InputBorder to implement border, errorBorder, focusedBorder, focusedErrorBorder, enabledBorder, and disabledBorder, easily create OutlineTextField using the simpleBorder option.

SimpleTextField(
  decoration: SimpleInputDecoration(
    simpleBorder: SimpleInputBorder(
      style: SimpleInputBorderStyle.outline,
      color: Colors.blueAccent,
      errorColor: Colors.redAccent,
      focusedColor: Colors.blue,
      focusedErrorColor: Colors.red,
      disabledColor: Colors.grey,
      width: 1.0,
      focusedWidth: 2.0,
      radius: BorderRadius.circular(8),
    ),
  ),
  allowWhiteSpace: false,
  allowSpecialCharacters: false,
),

Support

If you find any bugs or issues while using the plugin, please register an issues on GitHub. You can also contact us at hwj930513@naver.com.

About

This package provides the ability to implement OutlineTextField with simple settings.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages