email static method
Implementation
static String? email(String? value) {
if (value == null || value.isEmpty) return 'Email is required';
final regex = RegExp(r'^[\w-]+(\.[\w-]+)*@([\w-]+\.)+[a-zA-Z]{2,7}$');
if (!regex.hasMatch(value)) return 'Enter a valid email';
return null;
}