0

I am working on a Next.js project that faced this problem. I have a logo that loses its quality when I open the website on my iPhone but not on other devices. Did anyone face this problem? How can I solve it?

My code:

<div className="flex items-center">
   <Link href="/" className="flex items-center">
     <img
        src="/assets/img/navbar_logo.svg"
        alt="logo"
        className="md:w-[115px] md:h-[65px] w-[90px] h-[44px]"
     />
   </Link>
 </div>

The website

Note: I used the HTML <img> tag instead of the Next.js Image component to show the real quality of the image. I know the Next.js Image component has some properties like quality for this, but it was not showing the real quality.

These are images that were taken on a Samsung phone and a iPhone. Samsung iPhone

knittl
  • 246,190
  • 53
  • 318
  • 364
Zia Yamin
  • 942
  • 2
  • 10
  • 34

1 Answers1

2

Your svg file has a png file embedded in it. You would be much better off adding the logo as a png as it appears by embedding the file inside a svg it is losing quality.

This is the image extracted from the svg and it is high resolution: Extracted Image

Mayank Kumar Chaudhari
  • 16,027
  • 10
  • 55
  • 122
stickyuser
  • 2,552
  • 15
  • 15