feat: implement dynamic contact info and availability mapping from field values, and enhance phone number masking.
This commit is contained in:
@@ -18,7 +18,8 @@ function maskEmail(email: string): string {
|
||||
|
||||
// Helper function to mask phone
|
||||
function maskPhone(phone: string): string {
|
||||
if (phone.length <= 4) return '********';
|
||||
if (!phone || phone.trim() === '') return '-';
|
||||
if (phone.length <= 4) return '****' + phone;
|
||||
return phone.slice(0, -4).replace(/./g, '*') + phone.slice(-4);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user