PhoneValidationOptions constructor

const PhoneValidationOptions({
  1. List<PhoneValidationRule> rules = const [PhoneValidationRule.checkFormat, PhoneValidationRule.checkMinLength, PhoneValidationRule.checkMaxLength],
  2. int minLength = 8,
  3. int maxLength = 15,
  4. List<CountryCode>? allowedCountryCodes,
  5. bool allowSpecialCharacters = true,
  6. bool checkCountryCode = false,
})

Implementation

const PhoneValidationOptions({
  this.rules = const [
    PhoneValidationRule.checkFormat,
    PhoneValidationRule.checkMinLength,
    PhoneValidationRule.checkMaxLength,
  ],
  this.minLength = 8,
  this.maxLength = 15,
  this.allowedCountryCodes,
  this.allowSpecialCharacters = true,
  this.checkCountryCode = false, // New property for country code validation
});