{"id":32304652,"url":"https://github.com/nerdy-pro/flutter_number_editing_controller","last_synced_at":"2026-03-17T02:10:25.385Z","repository":{"id":165328536,"uuid":"640676325","full_name":"nerdy-pro/flutter_number_editing_controller","owner":"nerdy-pro","description":null,"archived":false,"fork":false,"pushed_at":"2025-06-07T14:58:00.000Z","size":428,"stargazers_count":3,"open_issues_count":1,"forks_count":5,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-07T15:30:56.088Z","etag":null,"topics":["dart","flutter","pubdev"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/number_editing_controller","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nerdy-pro.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-05-14T21:28:18.000Z","updated_at":"2025-06-07T14:57:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"ceffa54c-f256-4f30-8b81-5dd7798fa377","html_url":"https://github.com/nerdy-pro/flutter_number_editing_controller","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/nerdy-pro/flutter_number_editing_controller","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nerdy-pro%2Fflutter_number_editing_controller","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nerdy-pro%2Fflutter_number_editing_controller/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nerdy-pro%2Fflutter_number_editing_controller/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nerdy-pro%2Fflutter_number_editing_controller/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nerdy-pro","download_url":"https://codeload.github.com/nerdy-pro/flutter_number_editing_controller/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nerdy-pro%2Fflutter_number_editing_controller/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29777880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-24T04:54:30.205Z","status":"ssl_error","status_checked_at":"2026-02-24T04:53:58.628Z","response_time":75,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dart","flutter","pubdev"],"created_at":"2025-10-23T06:35:40.441Z","updated_at":"2026-03-17T02:10:25.378Z","avatar_url":"https://github.com/nerdy-pro.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# number_editing_controller\n\n[![Pub Version](https://img.shields.io/pub/v/number_editing_controller)](https://pub.dev/packages/number_editing_controller)\n[![License](https://img.shields.io/github/license/nerdy-pro/flutter_number_editing_controller)](https://github.com/nerdy-pro/flutter_number_editing_controller/blob/main/LICENSE)\n\nA Flutter `TextEditingController` that automatically formats numbers, decimals, and currencies as the user types. Built with full locale support.\n\nDeveloped by [nerdy.pro](https://nerdy.pro).\n\n## Features\n\n- **As-you-type formatting** for integers, decimals, and currency amounts\n- **Locale-aware** grouping and decimal separators (e.g. `1,234.56` in English, `1.234,56` in German)\n- **Currency support** with automatic symbol placement based on locale\n- **Extracts the numeric value** via `controller.number`\n- **Negative number support** with optional `allowNegative` flag\n- **Custom separators** for decimal and grouping characters\n\n![number_editing_controller demo](https://raw.githubusercontent.com/nerdy-pro/flutter_number_editing_controller/main/img/screenshot.gif)\n\n## Getting started\n\nInstall the package:\n\n```shell\nflutter pub add number_editing_controller\n```\n\n## Usage\n\nCreate a controller and assign it to a `TextField`:\n\n```dart\nfinal controller = NumberEditingTextController.currency(currencyName: 'USD');\n\nTextField(\n  controller: controller,\n  keyboardType: TextInputType.numberWithOptions(decimal: true, signed: true),\n)\n```\n\nRead the numeric value at any time:\n\n```dart\nfinal value = controller.number; // e.g. 1234.56\n```\n\n### Integer input\n\n```dart\nfinal controller = NumberEditingTextController.integer();\n```\n\n### Decimal input\n\n```dart\nfinal controller = NumberEditingTextController.decimal();\n```\n\n### Currency input\n\n```dart\nfinal controller = NumberEditingTextController.currency(currencyName: 'EUR');\n```\n\n### Configuration options\n\nAll constructors accept the following parameters:\n\n| Parameter | Description |\n|-----------|-------------|\n| `locale` | Locale for number formatting (e.g. `'en'`, `'de'`, `'ja'`). Defaults to the current locale. |\n| `allowNegative` | Whether to allow negative numbers. Defaults to `true`. |\n| `groupSeparator` | Custom digit grouping symbol (e.g. `','`, `'.'`, `' '`). |\n| `value` | Initial numeric value. |\n\nThe `currency()` constructor also accepts:\n\n| Parameter | Description |\n|-----------|-------------|\n| `currencyName` | ISO 4217 currency code (e.g. `'USD'`, `'EUR'`, `'JPY'`). |\n| `currencySymbol` | Custom currency symbol (e.g. `'$'`, `'€'`, `'₺'`). |\n| `decimalSeparator` | Custom decimal separator symbol. |\n\nThe `decimal()` constructor also accepts:\n\n| Parameter | Description |\n|-----------|-------------|\n| `minimalFractionDigits` | Minimum number of decimal digits to display. |\n| `maximumFractionDigits` | Maximum number of decimal digits allowed. |\n| `decimalSeparator` | Custom decimal separator symbol. |\n\n### Examples\n\n```dart\n// US Dollar with locale\nfinal usd = NumberEditingTextController.currency(\n  currencyName: 'USD',\n  locale: 'en',\n);\n\n// Euro in German locale\nfinal eur = NumberEditingTextController.currency(\n  currencyName: 'EUR',\n  locale: 'de',\n);\n\n// Positive-only integer\nfinal positive = NumberEditingTextController.integer(\n  allowNegative: false,\n);\n\n// Decimal with precision control\nfinal precise = NumberEditingTextController.decimal(\n  minimalFractionDigits: 2,\n  maximumFractionDigits: 4,\n  locale: 'en',\n);\n```\n\nA working example app is available in the [example](https://github.com/nerdy-pro/flutter_number_editing_controller/tree/main/example) directory.\n\n### Disposing the controller\n\nLike any `TextEditingController`, dispose of it when it is no longer needed:\n\n```dart\n@override\nvoid dispose() {\n  controller.dispose();\n  super.dispose();\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnerdy-pro%2Fflutter_number_editing_controller","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnerdy-pro%2Fflutter_number_editing_controller","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnerdy-pro%2Fflutter_number_editing_controller/lists"}