split common use fun in util file

This commit is contained in:
Pramod Mahajan 2025-05-22 18:18:34 +05:30
parent 0cefb98ac1
commit e372405ac0

View File

@ -1,24 +1,7 @@
import React from 'react'
import Avatar from '../common/Avatar';
import { getEmailIcon,getPhoneIcon } from './DirectoryUtils';
const getEmailIcon = (type) => {
switch (type) {
case 'Work': return "bx bx-briefcase me-1 " ;
case 'Personal': return "bx bx-user me-1";
case 'support': return "bx headphone-mic me-1";
case 'billing': return "bx bx-receipt me-1";
default: return "bx bx-envelope me-1";
}
};
const getPhoneIcon = (type) => {
switch (type) {
case 'Business': return "bx bx-phone me-1 ";
case 'Personal': return "bx bx-mobile me-1 ";
case 'Office': return "bx bx-phone me-1 ";
default: return "bx bx-phone me-1";
}
};
const ListViewDirectory = ({ contact,setSelectedContact,setIsOpenModal,setOpen_contact,setIsOpenModalNote,IsDeleted}) => {
return (