@maplibre/mlt-wasm 0.1.30 → 0.1.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/geojson.d.ts +9 -0
- package/dist/geojson.d.ts.map +1 -0
- package/dist/geojson.js +11 -0
- package/dist/geojson.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/wasm.d.ts +1 -1
- package/dist/wasm.d.ts.map +1 -1
- package/dist/wasm.js +1 -1
- package/dist/wasm.js.map +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { FeatureCollection } from "geojson";
|
|
2
|
+
/**
|
|
3
|
+
* Decode a raw MLT tile blob into `GeoJSON`.
|
|
4
|
+
*
|
|
5
|
+
* Every feature carries `_layer` and `_extent`, and a v2 tile's vertex-scoped columns ride
|
|
6
|
+
* along as `m:`-prefixed arrays, one value per vertex.
|
|
7
|
+
*/
|
|
8
|
+
export declare function tileGeoJson(data: Uint8Array): FeatureCollection;
|
|
9
|
+
//# sourceMappingURL=geojson.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geojson.d.ts","sourceRoot":"","sources":["../js/geojson.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAGjD;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,UAAU,GAAG,iBAAiB,CAE/D"}
|
package/dist/geojson.js
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { wasmTileGeoJson } from "./wasm";
|
|
2
|
+
/**
|
|
3
|
+
* Decode a raw MLT tile blob into `GeoJSON`.
|
|
4
|
+
*
|
|
5
|
+
* Every feature carries `_layer` and `_extent`, and a v2 tile's vertex-scoped columns ride
|
|
6
|
+
* along as `m:`-prefixed arrays, one value per vertex.
|
|
7
|
+
*/
|
|
8
|
+
export function tileGeoJson(data) {
|
|
9
|
+
return JSON.parse(wasmTileGeoJson(data));
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=geojson.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geojson.js","sourceRoot":"","sources":["../js/geojson.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,QAAQ,CAAC;AAEzC;;;;;GAKG;AACH,MAAM,UAAU,WAAW,CAAC,IAAgB;IAC1C,OAAO,IAAI,CAAC,KAAK,CAAC,eAAe,CAAC,IAAI,CAAC,CAAsB,CAAC;AAChE,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export type { VectorTileFeatureLike, VectorTileLayerLike, VectorTileLike, } from "@maplibre/vt-pbf";
|
|
2
2
|
export type { AnnotatedTile, BitField, BlobInfo, DecodedBlob, DecodeHint, DumpTree, Region, } from "./annotate";
|
|
3
3
|
export { annotateTile } from "./annotate";
|
|
4
|
+
export { tileGeoJson } from "./geojson";
|
|
4
5
|
export { decodeTile } from "./vectorTile";
|
|
5
6
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../js/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,qBAAqB,EACrB,mBAAmB,EACnB,cAAc,GACf,MAAM,kBAAkB,CAAC;AAC1B,YAAY,EACV,aAAa,EACb,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,UAAU,EACV,QAAQ,EACR,MAAM,GACP,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../js/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,qBAAqB,EACrB,mBAAmB,EACnB,cAAc,GACf,MAAM,kBAAkB,CAAC;AAC1B,YAAY,EACV,aAAa,EACb,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,UAAU,EACV,QAAQ,EACR,MAAM,GACP,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC"}
|
package/dist/index.js
CHANGED
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../js/index.ts"],"names":[],"mappings":"AAcA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../js/index.ts"],"names":[],"mappings":"AAcA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC"}
|
package/dist/wasm.d.ts
CHANGED
|
@@ -4,5 +4,5 @@
|
|
|
4
4
|
* Safari 15-26 cannot have two modules import the same top-level-await module, so every
|
|
5
5
|
* other module imports the already-initialised bindings from here.
|
|
6
6
|
*/
|
|
7
|
-
export { annotateTile as wasmAnnotateTile, decode_tile as wasmDecodeTile, } from "../pkg/mlt_wasm.js";
|
|
7
|
+
export { annotateTile as wasmAnnotateTile, decode_tile as wasmDecodeTile, tileGeoJson as wasmTileGeoJson, } from "../pkg/mlt_wasm.js";
|
|
8
8
|
//# sourceMappingURL=wasm.d.ts.map
|
package/dist/wasm.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wasm.d.ts","sourceRoot":"","sources":["../js/wasm.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EACL,YAAY,IAAI,gBAAgB,EAChC,WAAW,IAAI,cAAc,
|
|
1
|
+
{"version":3,"file":"wasm.d.ts","sourceRoot":"","sources":["../js/wasm.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EACL,YAAY,IAAI,gBAAgB,EAChC,WAAW,IAAI,cAAc,EAC7B,WAAW,IAAI,eAAe,GAC/B,MAAM,oBAAoB,CAAC"}
|
package/dist/wasm.js
CHANGED
|
@@ -4,5 +4,5 @@
|
|
|
4
4
|
* Safari 15-26 cannot have two modules import the same top-level-await module, so every
|
|
5
5
|
* other module imports the already-initialised bindings from here.
|
|
6
6
|
*/
|
|
7
|
-
export { annotateTile as wasmAnnotateTile, decode_tile as wasmDecodeTile, } from "../pkg/mlt_wasm.js";
|
|
7
|
+
export { annotateTile as wasmAnnotateTile, decode_tile as wasmDecodeTile, tileGeoJson as wasmTileGeoJson, } from "../pkg/mlt_wasm.js";
|
|
8
8
|
//# sourceMappingURL=wasm.js.map
|
package/dist/wasm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wasm.js","sourceRoot":"","sources":["../js/wasm.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EACL,YAAY,IAAI,gBAAgB,EAChC,WAAW,IAAI,cAAc,
|
|
1
|
+
{"version":3,"file":"wasm.js","sourceRoot":"","sources":["../js/wasm.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EACL,YAAY,IAAI,gBAAgB,EAChC,WAAW,IAAI,cAAc,EAC7B,WAAW,IAAI,eAAe,GAC/B,MAAM,oBAAoB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@maplibre/mlt-wasm",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.31",
|
|
4
4
|
"description": "WebAssembly-backed MapLibre Tile (MLT) decoder",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@maplibre/vt-pbf": "4.3.0",
|
|
45
|
+
"@types/geojson": "^7946.0.16",
|
|
45
46
|
"@types/node": "^24.10.2",
|
|
46
47
|
"@vitest/coverage-v8": "^4.0.1",
|
|
47
48
|
"@vitest/ui": "^4.0.18",
|