docs.page icon indicating copy to clipboard operation
docs.page copied to clipboard

zoom property of Image component causes image to be stretched

Open jenshor opened this issue 2 years ago • 3 comments

I'm using the Image component as documented in Components - Image

This is the code <Image src="/assets/Screenshot.jpg" zoom />

When activating the image zoom, the image gets enlarged to the maximum canvas size of the browser. However, the zoom effect somehow distorts the image. In my case the fonts within the image look a bit off.

Unzoomed: image

Zoomed: image

For this example image it looks like the aspect ratio is different in the zoomed state.

Let me know, if I can provide additional information.

I love the zoom feature and would love to see it improved further 👍🏻

jenshor avatar May 20 '22 11:05 jenshor

Had a look into this today, we use react-meium-image-zoom to implement zooming, and im not sure the best way to fix this, I might have to refactor Image when i get a chance.

cabljac avatar May 23 '22 10:05 cabljac

Thanks @cabljac for looking into this. It's not something that is too much of an issue just something I noticed.

jenshor avatar May 23 '22 11:05 jenshor

Thanks for raising it! Appreciate it

cabljac avatar May 23 '22 12:05 cabljac

I think this should be fixed now in the update. Please let me know if it still seems off to you.

Ehesp avatar Jan 10 '23 10:01 Ehesp