Skip to content

Commit e4768ac

Browse files
committed
Drop redundant string cast on style.zoom read
1 parent 3a7269d commit e4768ac

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

frontend/src/lib/components/editor/WallpaperHero.svelte

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,7 @@
105105
106106
// CSS `zoom` on <html> scales getBoundingClientRect() but not e.clientX/Y
107107
// on webkit2gtk — normalize rect into the same space as the mouse coords.
108-
const zoom =
109-
parseFloat(document.documentElement.style.zoom as string) || 1;
108+
const zoom = parseFloat(document.documentElement.style.zoom) || 1;
110109
const rectLeft = rect.left / zoom;
111110
const rectTop = rect.top / zoom;
112111
const rectWidth = rect.width / zoom;

0 commit comments

Comments
 (0)