-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correct the condition for using interpZoomTransitioned in StyleTransi…
…tion Fixes #2762
- Loading branch information
1 parent
5c8d47b
commit 6d720be
Showing
3 changed files
with
65 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<title>Mapbox GL JS debug page</title> | ||
<meta charset='utf-8'> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
|
||
<link rel='stylesheet' href='../../dist/mapbox-gl.css' /> | ||
<style> | ||
body { margin: 0; padding: 0; } | ||
html, body, #map { height: 100%; } | ||
</style> | ||
</head> | ||
|
||
<body> | ||
<div id='map'></div> | ||
<script src='../../dist/mapbox-gl-dev.js'></script> | ||
<script> | ||
var map = new mapboxgl.Map({ | ||
container: 'map', | ||
style: { | ||
"version": 8, | ||
"sources": { | ||
"geojson": { | ||
"type": "geojson", | ||
"data": { | ||
"type": "Point", | ||
"coordinates": [ | ||
0, | ||
0 | ||
] | ||
} | ||
} | ||
}, | ||
"transition": { | ||
"duration": 1000 | ||
}, | ||
"layers": [ | ||
{ | ||
"id": "circle", | ||
"type": "circle", | ||
"source": "geojson", | ||
"paint": { | ||
"circle-translate": [ | ||
-50, | ||
-50 | ||
] | ||
} | ||
} | ||
] | ||
} | ||
}); | ||
|
||
map.on('click', function(e) { | ||
map.setPaintProperty("circle", "circle-color", "red"); | ||
map.setPaintProperty("circle", "circle-translate", [50, 50]); | ||
}); | ||
</script> | ||
</body> | ||
</html> |