This question already has an answer here:
Many metals form compounds with s-block elements that are essentially entirely ionic. However, elements like silver, copper, lithium and so on, can form bonds that are significantly covalent in character. What are the factors that govern whether a particular metal will bond with significant covalent character? Is this linked to hardness and softness?