Skip to content

fix: preserve original image size when the editor opens - #10066

Open
gezerui888 wants to merge 1 commit into
HumanSignal:developfrom
gezerui888:fix/original-image-zoom
Open

gezerui888 wants to merge 1 commit into
HumanSignal:developfrom
gezerui888:fix/original-image-zoom

Conversation

@gezerui888

Copy link
Copy Markdown

Fixes #9699.

With defaultZoom="original", the editor fitted my 1,200 × 800 image to the viewport. I changed the initial load to select actual size and kept that size when the toolbar narrows the viewport. A 100-pixel square now measures 100 CSS pixels after layout. It measured 44 before.

Before After
Original mode scales the grid to fit Original mode shows each square at its natural size

To verify in Chrome, load the same image with original, fit and auto. After the toolbar appears, original should show each square at 100 CSS pixels. Fit and auto should scale the grid to the viewport. I checked all three modes. The regression test also covers manual zoom. Selecting actual size with Shift+2 now keeps that size on resize. Rotation still uses the existing zoom behavior.

The production editor built. All 3,934 editor tests passed, with seven more skipped. The full frontend suite had the same three failures and one error on develop and this branch.

cc @farioas

@netlify

netlify Bot commented Nov 26, 2026

Copy link
Copy Markdown

👷 Deploy request for label-studio-storybook pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 1a2c4d0

@netlify

netlify Bot commented Nov 26, 2026

Copy link
Copy Markdown

👷 Deploy request for heartex-docs pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 1a2c4d0

@netlify

netlify Bot commented Nov 26, 2026

Copy link
Copy Markdown

👷 Deploy request for label-studio-docs-new-theme pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 1a2c4d0

@netlify

netlify Bot commented Nov 26, 2026

Copy link
Copy Markdown

👷 Deploy request for label-studio-playground pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 1a2c4d0

@github-actions github-actions Bot added the fix label Nov 26, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

<Image> defaultZoom attribute value "original" and "auto" same effect???

1 participant