Skip to content

Conversation

sheikhshaheerimran
Copy link

This PR fix support for optional maxBounds in the pan/zoom calculation logic, allowing users to define stricter movement constraints beyond the existing limitToBounds behavior.

Why This Change
Previously, limitToBounds only used internally calculated bounds and ignored explicitly defined minPositionX, minPositionY, maxPositionX, and maxPositionY. This limited the developer's control over how far the content could pan or zoom.

…ints

Allows users to define max bounds for pan/zoom behavior. This improves control over movement limits when the default limitToBounds is not sufficient. Previously, min and max positions for X and Y were not used to constrain the image bounds.
@sheikhshaheerimran sheikhshaheerimran force-pushed the fix/bounds-min-max-limits branch from 4b4efa1 to 56f4124 Compare June 21, 2025 08:50
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.

1 participant