decompress vector tile preview correctly

This commit is contained in:
Brandon Liu
2022-07-06 23:52:53 +08:00
parent 12aa521b46
commit 419ae06a6e
2 changed files with 19 additions and 5 deletions

View File

@@ -116,7 +116,7 @@ function MaplibreMap(props: { file: PMTiles }) {
let initStyle = async () => {
if (map) {
let metadata = await props.file.metadata();
let bounds = metadata.bounds.split(',');
let bounds = metadata.bounds.split(",");
map.fitBounds([
[+bounds[0], +bounds[1]],
[+bounds[2], +bounds[3]],