Last active
January 21, 2016 23:15
-
-
Save peterqliu/7024d2e97c34125c64c8 to your computer and use it in GitHub Desktop.
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset='utf-8' /> | |
<title></title> | |
<link href='https://www.mapbox.com/base/latest/base.css' rel='stylesheet' /> | |
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no' /> | |
<script src='https://api.tiles.mapbox.com/mapbox-gl-js/v0.12.3/mapbox-gl.js'></script> | |
<link href='https://api.tiles.mapbox.com/mapbox-gl-js/v0.12.3/mapbox-gl.css' rel='stylesheet' /> | |
<style> | |
body { margin:0; padding:0; } | |
#map { position:absolute; top:0; bottom:0; width:100%; } | |
#bubble {position:absolute;background:white;padding:10px; border:1px solid #ccc; border-radius:5px;} | |
</style> | |
</head> | |
<body> | |
<div id='map'></div> | |
<div id='bubble'> | |
<h3 class='name'></h3> | |
<div class='address'></div> | |
<div class='phone'></div> | |
</div> | |
<script> | |
mapboxgl.accessToken = 'pk.eyJ1IjoicGV0ZXJxbGl1IiwiYSI6ImpvZmV0UEEifQ._D4bRmVcGfJvo1wjuOpA1g'; | |
var map = new mapboxgl.Map({ | |
container: 'map', // container id | |
style: 'mapbox://styles/peterqliu/cijoufskf00058zkq18olzs17', //stylesheet location | |
center: [-122.41481152024853, 37.78489101975296], // starting position | |
zoom: 16 // starting zoom | |
}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment