ac_phone_util library

A Flutter utility library for phone number parsing, validation, formatting and country detection.

Provides ACPhoneUtil for phone number operations, ACPhoneCountry for country metadata, ACPhoneCountries for the registry of supported countries, ACPhoneData for parsed results, ACPhoneMasked for mask application, and ACPhoneCountryLocalizations for localized country names.

Classes

ACNationalPhoneEditingController
A TextEditingController for entering the national part of a phone number under an optional ACPhoneCountry mask.
ACPhoneCountries
Singleton registry of all phone countries with hashed lookup by phone code.
ACPhoneCountry
Represents a phone country with its code, mask and metadata.
ACPhoneCountryLocalizations
Provides localized country names based on a given Locale.
ACPhoneData
Contains parsed phone number data with the matched country.
ACPhoneEditingController
A TextEditingController that automatically parses phone numbers using ACPhoneUtil whenever the text changes.
ACPhoneInputFormatter
A TextInputFormatter that formats phone number input by applying a fixed mask and filtering out every non-digit character typed or pasted by the user.
ACPhoneMasked
Applies a mask pattern to a raw phone number string.
ACPhoneUtil
Main utility class for phone number parsing, validation and formatting.