From 4590a202c5091f58306c3afa9933b8d386f56135 Mon Sep 17 00:00:00 2001 From: Nayam Amarshe <25067102+NayamAmarshe@users.noreply.github.com> Date: Wed, 7 Feb 2024 07:04:06 +0530 Subject: [PATCH] Fix lens --- renderer/pages/index.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/renderer/pages/index.tsx b/renderer/pages/index.tsx index e0ccc77..e093d62 100644 --- a/renderer/pages/index.tsx +++ b/renderer/pages/index.tsx @@ -696,7 +696,7 @@ const Home = () => { upscaledImagePath && imagePath && (
{ }]`} style={{ clipPath: `circle(${ - lensSize / (parseInt(zoomAmount) / 100) + (lensSize + 2 * (parseInt(zoomAmount) / 100)) / + (parseInt(zoomAmount) / 100) }px at ${cursorPosition.x}px ${cursorPosition.y}px)`, backgroundPosition: "0% 0%", transformOrigin: backgroundPosition, @@ -728,7 +729,7 @@ const Home = () => { src={"file:///" + upscaledImagePath} style={{ clipPath: `circle(${ - (lensSize - parseInt(zoomAmount) / 100) / + (lensSize + parseInt(zoomAmount) / 100) / (parseInt(zoomAmount) / 100) }px at ${cursorPosition.x}px ${cursorPosition.y}px)`, backgroundPosition: backgroundPosition,