Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set min/maxNativeZoom in tileLayer instead of min/maxZoom #1015

Merged
merged 1 commit into from
Oct 31, 2024

Conversation

hrodmn
Copy link
Contributor

@hrodmn hrodmn commented Oct 30, 2024

The minZoom and maxZoom parameters in the tileLayer class just control which zoom levels on which tiles from the layer will be displayed. Setting minNativeZoom and maxNativeZoom to the tilejson minzoom and maxzoom makes more sense and allows us to show tiles from layers where the default maxzoom is very low (e.g. 0) which can happen for very low-resolution datasets.

maxNativeZoom: Maximum zoom number the tile source has available. If it is specified, the tiles on all zoom levels higher than maxNativeZoom will be loaded from maxNativeZoom level and auto-scaled.

leaflet API docs

@hrodmn hrodmn force-pushed the patch/leaflet-tile-zoom branch from cc67eb6 to fe40fa1 Compare October 30, 2024 15:53
@hrodmn hrodmn force-pushed the patch/leaflet-tile-zoom branch from fe40fa1 to 477e366 Compare October 30, 2024 15:53
@hrodmn hrodmn requested a review from vincentsarago October 30, 2024 15:54
Copy link
Member

@vincentsarago vincentsarago left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙏

@vincentsarago vincentsarago merged commit dc56ddc into main Oct 31, 2024
10 checks passed
@vincentsarago vincentsarago deleted the patch/leaflet-tile-zoom branch October 31, 2024 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants