Search packages, repositories and app categories

GitHub repositoryadultcode/Persian-Arabic-number-formatter

Persian-Arabic-number-formatter

adultcode/Persian-Arabic-number-formatter open-source repository details.

Persian-Arabic-number-formatter project cover
Stars
0
Forks
0
Last push (UTC)
Sep 20, 2023
Project status
Active

Original README

English project snapshot. Visit GitHub for the latest content.

The example app running in Android

Persian/Arabic number input formatter

If you use the digitsOnly formatter option on a TextField in Flutter, it only works with English digits, and you can't use Persian/Arabic numbers. However, if you don't use any input formatter, then you can't convert Persian/Arabic digits to an integer

How to use

Add this line to your file

package:persian_input/validator/number_validator.dart

Now simply add PersianNumberValidator class in inputFormatters list.

TextField(
inputFormatters:[
PersianNumberValidator()
],
decoration: const InputDecoration(
hintText: 'With persian formatter'
   ),
 )
Hesam Rasoulian GitHub avatar
GitHub author

Hesam Rasoulian ↗

Mobile Developer - work with Flutter,Kotlin, Java(not any more), Also I do funny things with python and django

LanguagesC++CMakeDartHTMLSwiftCShellObjective-CJavaKotlin

Dependencies used

Dependency list 3 items

  • flutter{"sdk":"flutter"}
  • flutter_testDevelopment{"sdk":"flutter"}
  • flutter_lintsDevelopment^2.0.0

How do I choose a repository?

Start with your use case, compare repository activity, and check the original project before adopting it.

  1. Search by repository name, owner or description, then narrow the results by topic.
  2. Compare stars, forks and recent pushes. Stars show community interest, not a guarantee of quality.
  3. Read the README, license and issues on GitHub before using a project.

Sources and maintenance

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗