@geoql/v-maplibre 1.11.0 → 2.0.1
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/README.md +42 -15
- package/dist/arc-XYgM0NpD.js +2 -0
- package/dist/arc-XYgM0NpD.js.map +1 -0
- package/dist/{arrow-4ecDVUFv.js → arrow-B87Hvf8z.js} +1 -1
- package/dist/{arrow-4ecDVUFv.js.map → arrow-B87Hvf8z.js.map} +1 -1
- package/dist/bitmap-CEQZNyod.js +2 -0
- package/dist/bitmap-CEQZNyod.js.map +1 -0
- package/dist/cog-B3kQFMdO.js +2 -0
- package/dist/cog-B3kQFMdO.js.map +1 -0
- package/dist/column-6Alyevco.js +2 -0
- package/dist/column-6Alyevco.js.map +1 -0
- package/dist/contour-D5irVPeN.js +2 -0
- package/dist/contour-D5irVPeN.js.map +1 -0
- package/dist/deckgl.d.ts +47 -0
- package/dist/deckgl.js +2 -0
- package/dist/deckgl.js.map +1 -0
- package/dist/generic-DXw_QGDp.js +2 -0
- package/dist/generic-DXw_QGDp.js.map +1 -0
- package/dist/geoarrow-path-tBmjWKYC.js +2 -0
- package/dist/{geoarrow-path-B2LJ956d.js.map → geoarrow-path-tBmjWKYC.js.map} +1 -1
- package/dist/geoarrow-polygon-C2sWPrq6.js +2 -0
- package/dist/{geoarrow-polygon-C9mZ7552.js.map → geoarrow-polygon-C2sWPrq6.js.map} +1 -1
- package/dist/geoarrow-scatterplot-BvvHZc7E.js +2 -0
- package/dist/{geoarrow-scatterplot-CM5842q_.js.map → geoarrow-scatterplot-BvvHZc7E.js.map} +1 -1
- package/dist/geoarrow-solid-polygon-DPmDfwoY.js +2 -0
- package/dist/{geoarrow-solid-polygon-DIm9mciL.js.map → geoarrow-solid-polygon-DPmDfwoY.js.map} +1 -1
- package/dist/geoarrow-text-DEFcoF0G.js +2 -0
- package/dist/{geoarrow-text-ClY3q_nR.js.map → geoarrow-text-DEFcoF0G.js.map} +1 -1
- package/dist/geoarrow-trips-C9_EXHnn.js +2 -0
- package/dist/{geoarrow-trips-BqbIoMt8.js.map → geoarrow-trips-C9_EXHnn.js.map} +1 -1
- package/dist/geohash-vWnSK76U.js +2 -0
- package/dist/geohash-vWnSK76U.js.map +1 -0
- package/dist/geojson-CqnyNLW0.js +2 -0
- package/dist/geojson-CqnyNLW0.js.map +1 -0
- package/dist/geotiff.d.ts +50 -0
- package/dist/geotiff.js +2 -0
- package/dist/geotiff.js.map +1 -0
- package/dist/great-circle-Bz8TvCiM.js +2 -0
- package/dist/great-circle-Bz8TvCiM.js.map +1 -0
- package/dist/grid-B_D40N2N.js +2 -0
- package/dist/grid-B_D40N2N.js.map +1 -0
- package/dist/grid-cell-fa_NejcO.js +2 -0
- package/dist/grid-cell-fa_NejcO.js.map +1 -0
- package/dist/h3-cluster-Cg0CEA_m.js +2 -0
- package/dist/h3-cluster-Cg0CEA_m.js.map +1 -0
- package/dist/h3-hexagon-DkIZnQEf.js +2 -0
- package/dist/h3-hexagon-DkIZnQEf.js.map +1 -0
- package/dist/heatmap-D7R9nYug.js +2 -0
- package/dist/heatmap-D7R9nYug.js.map +1 -0
- package/dist/hexagon-Bl_UBlOT.js +2 -0
- package/dist/hexagon-Bl_UBlOT.js.map +1 -0
- package/dist/icon-Dm1fyRNM.js +2 -0
- package/dist/icon-Dm1fyRNM.js.map +1 -0
- package/dist/index-2D1oVTKr.d.ts +37 -0
- package/dist/index.d.ts +98 -477
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/lidar.d.ts +232 -0
- package/dist/lidar.js +2 -0
- package/dist/lidar.js.map +1 -0
- package/dist/line-B77d8tio.js +2 -0
- package/dist/line-B77d8tio.js.map +1 -0
- package/dist/mosaic-Bm1aKa0Q.js +43 -0
- package/dist/mosaic-Bm1aKa0Q.js.map +1 -0
- package/dist/multi-cog-D2ys9o3u.js +2 -0
- package/dist/multi-cog-D2ys9o3u.js.map +1 -0
- package/dist/mvt-BUVHps3s.js +2 -0
- package/dist/mvt-BUVHps3s.js.map +1 -0
- package/dist/path-CvxVK8wm.js +2 -0
- package/dist/path-CvxVK8wm.js.map +1 -0
- package/dist/point-cloud-CSsO2nuJ.js +2 -0
- package/dist/point-cloud-CSsO2nuJ.js.map +1 -0
- package/dist/polygon-DAVE4LXH.js +2 -0
- package/dist/polygon-DAVE4LXH.js.map +1 -0
- package/dist/quadkey-BAnxuF9T.js +2 -0
- package/dist/quadkey-BAnxuF9T.js.map +1 -0
- package/dist/s2-Bv5MIwa9.js +2 -0
- package/dist/s2-Bv5MIwa9.js.map +1 -0
- package/dist/scatterplot-aZig07ZM.js +2 -0
- package/dist/scatterplot-aZig07ZM.js.map +1 -0
- package/dist/scenegraph-WEtd4Tza.js +2 -0
- package/dist/scenegraph-WEtd4Tza.js.map +1 -0
- package/dist/screen-grid-Cp80FMUf.js +2 -0
- package/dist/screen-grid-Cp80FMUf.js.map +1 -0
- package/dist/simple-mesh-DT1BC-Mz.js +2 -0
- package/dist/simple-mesh-DT1BC-Mz.js.map +1 -0
- package/dist/solid-polygon-BxLiMNAC.js +2 -0
- package/dist/solid-polygon-BxLiMNAC.js.map +1 -0
- package/dist/starfield-Djc5vy6K.js +2 -0
- package/dist/starfield-Djc5vy6K.js.map +1 -0
- package/dist/starfield.d.ts +7 -0
- package/dist/starfield.js +2 -0
- package/dist/starfield.js.map +1 -0
- package/dist/symbols-DXKzIgbY.js +2 -0
- package/dist/symbols-DXKzIgbY.js.map +1 -0
- package/dist/terrain-CPKUswLf.js +2 -0
- package/dist/terrain-CPKUswLf.js.map +1 -0
- package/dist/text-Qf7B4QNZ.js +2 -0
- package/dist/text-Qf7B4QNZ.js.map +1 -0
- package/dist/tile-3d-CbQInXbC.js +2 -0
- package/dist/tile-3d-CbQInXbC.js.map +1 -0
- package/dist/tile-BxWRJ8QY.js +2 -0
- package/dist/tile-BxWRJ8QY.js.map +1 -0
- package/dist/trips-CwzuAg1k.js +2 -0
- package/dist/trips-CwzuAg1k.js.map +1 -0
- package/dist/useDeckOverlay-CI56uIKH.js +2 -0
- package/dist/useDeckOverlay-CI56uIKH.js.map +1 -0
- package/dist/useDeckOverlay-JoRzVQ7g.d.ts +43 -0
- package/dist/wind-particle-D3y-A-W4.js +2 -0
- package/dist/wind-particle-D3y-A-W4.js.map +1 -0
- package/dist/wind.d.ts +9 -0
- package/dist/wind.js +2 -0
- package/dist/wind.js.map +1 -0
- package/dist/wms-BEsf7XG6.js +2 -0
- package/dist/wms-BEsf7XG6.js.map +1 -0
- package/dist/zarr-BWbq3Uwq.js +2 -0
- package/dist/zarr-BWbq3Uwq.js.map +1 -0
- package/package.json +37 -17
- package/dist/arc-oPHfD4K7.js +0 -2
- package/dist/arc-oPHfD4K7.js.map +0 -1
- package/dist/bitmap-C04WgKea.js +0 -2
- package/dist/bitmap-C04WgKea.js.map +0 -1
- package/dist/cog-Cq7xvN9B.js +0 -2
- package/dist/cog-Cq7xvN9B.js.map +0 -1
- package/dist/column-Dx4A711w.js +0 -2
- package/dist/column-Dx4A711w.js.map +0 -1
- package/dist/contour-Dgvb_bGm.js +0 -2
- package/dist/contour-Dgvb_bGm.js.map +0 -1
- package/dist/generic-BKvcZn9n.js +0 -2
- package/dist/generic-BKvcZn9n.js.map +0 -1
- package/dist/geoarrow-path-B2LJ956d.js +0 -2
- package/dist/geoarrow-polygon-C9mZ7552.js +0 -2
- package/dist/geoarrow-scatterplot-CM5842q_.js +0 -2
- package/dist/geoarrow-solid-polygon-DIm9mciL.js +0 -2
- package/dist/geoarrow-text-ClY3q_nR.js +0 -2
- package/dist/geoarrow-trips-BqbIoMt8.js +0 -2
- package/dist/geohash-Pq83atW2.js +0 -2
- package/dist/geohash-Pq83atW2.js.map +0 -1
- package/dist/geojson-cOxJcO-8.js +0 -2
- package/dist/geojson-cOxJcO-8.js.map +0 -1
- package/dist/great-circle-C6GDbX1c.js +0 -2
- package/dist/great-circle-C6GDbX1c.js.map +0 -1
- package/dist/grid-BPfXfID8.js +0 -2
- package/dist/grid-BPfXfID8.js.map +0 -1
- package/dist/grid-cell-T0-xdlk_.js +0 -2
- package/dist/grid-cell-T0-xdlk_.js.map +0 -1
- package/dist/h3-cluster-BsvMbaYv.js +0 -2
- package/dist/h3-cluster-BsvMbaYv.js.map +0 -1
- package/dist/h3-hexagon-Cx1qlgKb.js +0 -2
- package/dist/h3-hexagon-Cx1qlgKb.js.map +0 -1
- package/dist/heatmap-ByafStP6.js +0 -2
- package/dist/heatmap-ByafStP6.js.map +0 -1
- package/dist/hexagon-CWRkTkkj.js +0 -2
- package/dist/hexagon-CWRkTkkj.js.map +0 -1
- package/dist/icon-WggKPJv7.js +0 -2
- package/dist/icon-WggKPJv7.js.map +0 -1
- package/dist/line-B5e9w1td.js +0 -2
- package/dist/line-B5e9w1td.js.map +0 -1
- package/dist/mosaic-Cl7rtAXN.js +0 -43
- package/dist/mosaic-Cl7rtAXN.js.map +0 -1
- package/dist/multi-cog-DAJbnElE.js +0 -2
- package/dist/multi-cog-DAJbnElE.js.map +0 -1
- package/dist/mvt-D0GYYs-Z.js +0 -2
- package/dist/mvt-D0GYYs-Z.js.map +0 -1
- package/dist/path-mcVHjyaA.js +0 -2
- package/dist/path-mcVHjyaA.js.map +0 -1
- package/dist/point-cloud-CNpLW-hf.js +0 -2
- package/dist/point-cloud-CNpLW-hf.js.map +0 -1
- package/dist/polygon-B5mGSTte.js +0 -2
- package/dist/polygon-B5mGSTte.js.map +0 -1
- package/dist/quadkey-DGHCEKmx.js +0 -2
- package/dist/quadkey-DGHCEKmx.js.map +0 -1
- package/dist/s2-MuPaEFbo.js +0 -2
- package/dist/s2-MuPaEFbo.js.map +0 -1
- package/dist/scatterplot-BBeJkOdi.js +0 -2
- package/dist/scatterplot-BBeJkOdi.js.map +0 -1
- package/dist/scenegraph-DTM4oQ_J.js +0 -2
- package/dist/scenegraph-DTM4oQ_J.js.map +0 -1
- package/dist/screen-grid-CxlQC4Kb.js +0 -2
- package/dist/screen-grid-CxlQC4Kb.js.map +0 -1
- package/dist/simple-mesh-BxLUvOJK.js +0 -2
- package/dist/simple-mesh-BxLUvOJK.js.map +0 -1
- package/dist/solid-polygon-DwQBLTy0.js +0 -2
- package/dist/solid-polygon-DwQBLTy0.js.map +0 -1
- package/dist/starfield-D0gIX-34.js +0 -2
- package/dist/starfield-D0gIX-34.js.map +0 -1
- package/dist/symbols-CFCXX1_B.js +0 -2
- package/dist/symbols-CFCXX1_B.js.map +0 -1
- package/dist/terrain-f-XAakfL.js +0 -2
- package/dist/terrain-f-XAakfL.js.map +0 -1
- package/dist/text-BOvG9JHc.js +0 -2
- package/dist/text-BOvG9JHc.js.map +0 -1
- package/dist/tile-3d-DG91zS0N.js +0 -2
- package/dist/tile-3d-DG91zS0N.js.map +0 -1
- package/dist/tile-AhmnAg8V.js +0 -2
- package/dist/tile-AhmnAg8V.js.map +0 -1
- package/dist/trips-DwzBmfe0.js +0 -2
- package/dist/trips-DwzBmfe0.js.map +0 -1
- package/dist/wind-particle-DW0nCMls.js +0 -2
- package/dist/wind-particle-DW0nCMls.js.map +0 -1
- package/dist/wms-vy1yMBNb.js +0 -2
- package/dist/wms-vy1yMBNb.js.map +0 -1
- package/dist/zarr-6SNoX07d.js +0 -2
- package/dist/zarr-6SNoX07d.js.map +0 -1
package/dist/{geoarrow-solid-polygon-DIm9mciL.js.map → geoarrow-solid-polygon-DPmDfwoY.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"geoarrow-solid-polygon-
|
|
1
|
+
{"version":3,"file":"geoarrow-solid-polygon-DPmDfwoY.js","names":[],"sources":["../src/layers/deckgl/geoarrow-solid-polygon/VLayerDeckglGeoArrowSolidPolygon.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render extruded (3D) polygons from an Apache Arrow `Table` or\n * `RecordBatch` containing GeoArrow polygon geometries (extension type\n * `geoarrow.polygon` or `geoarrow.multipolygon`).\n *\n * Wraps deck.gl's stock `SolidPolygonLayer`. The wrapper flattens\n * multi-polygons into per-ring arrays extracted from the Arrow column — no\n * GeoJSON parse pass, no `@geoarrow/deck.gl-geoarrow` runtime dependency.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/layers`\n * @requires `@deck.gl/mapbox`\n * @requires `apache-arrow`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers apache-arrow`\n */\n import { onBeforeUnmount, watch, shallowRef, markRaw } from 'vue';\n import type { PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey, requirePeer } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import { useMapReady } from '../_shared/useMapReady';\n import {\n extractPolygons,\n extractMultiPolygons,\n polygonsToRingArrays,\n filterDefined,\n } from '../_shared/arrow';\n import type { ArrowTableLike } from '../_shared/types';\n\n const SOLID_POLYGON_PEER_INSTALL =\n 'pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers apache-arrow';\n\n type Props = {\n id: string;\n data: ArrowTableLike | null | undefined;\n getPolygon?: unknown;\n getFillColor?: unknown;\n getLineColor?: unknown;\n getElevation?: unknown;\n extruded?: boolean;\n wireframe?: boolean;\n filled?: boolean;\n elevationScale?: number;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n metrics?: boolean;\n beforeId?: string;\n };\n\n const props = withDefaults(defineProps<Props>(), {\n visible: true,\n pickable: false,\n autoHighlight: false,\n extruded: false,\n wireframe: false,\n filled: true,\n metrics: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const LayerClass = shallowRef<\n typeof import('@deck.gl/layers').SolidPolygonLayer | null\n >(null);\n\n const EXCLUDE = new Set(['id', 'data', 'getPolygon']);\n\n const createLayer = () => {\n if (!LayerClass.value || !props.data) return null;\n const multi = extractMultiPolygons(props.data);\n const single = multi ? null : extractPolygons(props.data);\n const geom = multi ?? single;\n if (!geom) {\n console.error(\n '[VLayerDeckglGeoArrowSolidPolygon] no GeoArrow polygon / multipolygon column found in data',\n );\n return null;\n }\n const rings = polygonsToRingArrays(geom);\n try {\n const layer = new LayerClass.value({\n ...filterDefined(props as unknown as Record<string, unknown>, EXCLUDE),\n id: props.id,\n data: rings,\n getPolygon: (ring: number[][]) => ring,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n });\n return markRaw(layer);\n } catch (err) {\n console.error(\n '[VLayerDeckglGeoArrowSolidPolygon] failed to construct layer:',\n err,\n );\n return null;\n }\n };\n\n const initializeLayer = async () => {\n const mod = await requirePeer(\n '@deck.gl/layers',\n () => import('@deck.gl/layers'),\n SOLID_POLYGON_PEER_INSTALL,\n );\n LayerClass.value = markRaw(mod.SolidPolygonLayer);\n };\n\n useMapReady(map, initializeLayer);\n\n watch(LayerClass, (cls) => {\n if (!cls || !props.data) return;\n const layer = createLayer();\n if (layer) addLayer(layer);\n });\n\n watch(\n () => props.data,\n () => {\n if (!LayerClass.value || !props.data) return;\n const layer = createLayer();\n if (layer) updateLayer(props.id, layer);\n },\n );\n\n watch(\n () => [\n props.getFillColor,\n props.getLineColor,\n props.getElevation,\n props.extruded,\n props.wireframe,\n props.filled,\n props.elevationScale,\n props.opacity,\n props.visible,\n props.pickable,\n ],\n () => {\n if (!LayerClass.value || !props.data) return;\n const layer = createLayer();\n if (layer) updateLayer(props.id, layer);\n },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"sRA+BE,mdAsBA,IAAM,EAAQ,EAUR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,EAAa,EAEjB,IAAI,EAEA,EAAU,IAAI,IAAI,CAAC,KAAM,OAAQ,YAAY,CAAC,EAE9C,MAAoB,CACxB,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OAAO,KAC7C,IAAM,EAAQ,EAAqB,EAAM,IAAI,EACvC,EAAS,EAAQ,KAAO,EAAgB,EAAM,IAAI,EAClD,EAAO,GAAS,EACtB,GAAI,CAAC,EAIH,OAHA,QAAQ,MACN,4FACF,EACO,KAET,IAAM,EAAQ,EAAqB,CAAI,EACvC,GAAI,CASF,OAAO,EAAQ,IARG,EAAW,MAAM,CACjC,GAAG,EAAc,EAA6C,CAAO,EACrE,GAAI,EAAM,GACV,KAAM,EACN,WAAa,GAAqB,EAClC,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CACe,CAAK,CACtB,OAAS,EAAK,CAKZ,OAJA,QAAQ,MACN,gEACA,CACF,EACO,IACT,CACF,SAWA,EAAY,EAAK,SATmB,CAMlC,EAAW,MAAQ,GAAQ,MALT,EAChB,sBACM,OAAO,mBACb,qEACF,GAC+B,iBAAiB,CAClD,CAEgC,EAEhC,EAAM,EAAa,GAAQ,CACzB,GAAI,CAAC,GAAO,CAAC,EAAM,KAAM,OACzB,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAS,CAAK,CAC3B,CAAC,EAED,MACQ,EAAM,SACN,CACJ,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OACtC,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAY,EAAM,GAAI,CAAK,CACxC,CACF,EAEA,MACQ,CACJ,EAAM,aACN,EAAM,aACN,EAAM,aACN,EAAM,SACN,EAAM,UACN,EAAM,OACN,EAAM,eACN,EAAM,QACN,EAAM,QACN,EAAM,QACR,MACM,CACJ,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OACtC,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAY,EAAM,GAAI,CAAK,CACxC,CACF,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{a as n,i as r}from"./useDeckOverlay-CI56uIKH.js";import{c as i,i as a,o}from"./arrow-B87Hvf8z.js";import{defineComponent as s,markRaw as c,onBeforeUnmount as l,renderSlot as u,shallowRef as d,watch as f}from"vue";const p=s({__name:`VLayerDeckglGeoArrowText`,props:{id:{},data:{},textColumn:{},getPosition:{},getText:{},getColor:{},getSize:{},getAngle:{},getTextAnchor:{},getAlignmentBaseline:{},sizeUnits:{},sizeScale:{},sizeMinPixels:{},sizeMaxPixels:{},billboard:{type:Boolean,default:!0},fontFamily:{},fontWeight:{},characterSet:{},background:{type:Boolean,default:!1},backgroundPadding:{},getBackgroundColor:{},getBorderColor:{},getBorderWidth:{},opacity:{},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!1},autoHighlight:{type:Boolean,default:!1},beforeId:{}},emits:[`click`,`hover`],setup(s,{emit:p}){let m=s,h=p,g=e(t),{addLayer:_,removeLayer:v,updateLayer:y}=r(g),b=d(null),x=new Set([`id`,`data`,`getPosition`,`getText`,`textColumn`]),S=(e,t)=>{let n=a(e);if(!n)return null;let r=e.getChild(t),i=[];if(r){let e=r.toArray?.();if(e)for(let t=0;t<n.length;t++)i.push(String(e[t]??``));else if(r.get)for(let e=0;e<n.length;e++)i.push(String(r.get(e)??``))}let o=[];for(let e=0;e<n.length;e++)o.push({position:[n.positions[e*3]??0,n.positions[e*3+1]??0],label:i[e]??``});return o},C=()=>{if(!b.value||!m.data)return null;let e=S(m.data,m.textColumn??`name`);if(!e)return console.error(`[VLayerDeckglGeoArrowText] no GeoArrow point geometry column found in data`),null;try{return c(new b.value({...o(m,x),id:m.id,data:e,getPosition:e=>e.position,getText:e=>e.label,onClick:e=>h(`click`,e),onHover:e=>h(`hover`,e)}))}catch(e){return console.error(`[VLayerDeckglGeoArrowText] failed to construct layer:`,e),null}};return i(g,async()=>{b.value=c((await n(`@deck.gl/layers`,()=>import(`@deck.gl/layers`),`pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers apache-arrow`)).TextLayer)}),f(b,e=>{if(!e||!m.data)return;let t=C();t&&_(t)}),f(()=>m.data,()=>{if(!b.value||!m.data)return;let e=C();e&&y(m.id,e)}),f(()=>[m.getText,m.getPosition,m.getColor,m.getSize,m.getAngle,m.getTextAnchor,m.getAlignmentBaseline,m.sizeUnits,m.sizeScale,m.sizeMinPixels,m.sizeMaxPixels,m.billboard,m.fontFamily,m.fontWeight,m.background,m.opacity,m.visible,m.pickable],()=>{if(!b.value||!m.data)return;let e=C();e&&y(m.id,e)}),l(()=>v(m.id)),(e,t)=>u(e.$slots,`default`)}});export{p as VLayerDeckglGeoArrowText};
|
|
2
|
+
//# sourceMappingURL=geoarrow-text-DEFcoF0G.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"geoarrow-text-
|
|
1
|
+
{"version":3,"file":"geoarrow-text-DEFcoF0G.js","names":[],"sources":["../src/layers/deckgl/geoarrow-text/VLayerDeckglGeoArrowText.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render text labels at point positions from an Apache Arrow `Table` or\n * `RecordBatch` containing GeoArrow point geometries (extension type\n * `geoarrow.point` or `geoarrow.multipoint`).\n *\n * Wraps deck.gl's stock `TextLayer`. The wrapper extracts XY positions plus\n * a per-row label string from the configured `textColumn` (default `name`).\n * No `@geoarrow/deck.gl-geoarrow` runtime dependency.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/layers`\n * @requires `@deck.gl/mapbox`\n * @requires `apache-arrow`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers apache-arrow`\n */\n import { onBeforeUnmount, watch, shallowRef, markRaw } from 'vue';\n import type { PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey, requirePeer } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import { useMapReady } from '../_shared/useMapReady';\n import { extractPoints, filterDefined } from '../_shared/arrow';\n import type { ArrowTableLike } from '../_shared/types';\n\n const TEXT_PEER_INSTALL =\n 'pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers apache-arrow';\n\n type Props = {\n id: string;\n data: ArrowTableLike | null | undefined;\n textColumn?: string;\n getPosition?: unknown;\n getText?: unknown;\n getColor?: unknown;\n getSize?: unknown;\n getAngle?: unknown;\n getTextAnchor?: unknown;\n getAlignmentBaseline?: unknown;\n sizeUnits?: 'meters' | 'common' | 'pixels';\n sizeScale?: number;\n sizeMinPixels?: number;\n sizeMaxPixels?: number;\n billboard?: boolean;\n fontFamily?: string;\n fontWeight?: number | string;\n characterSet?: 'auto' | string[] | Set<string>;\n background?: boolean;\n backgroundPadding?: [number, number] | [number, number, number, number];\n getBackgroundColor?: unknown;\n getBorderColor?: unknown;\n getBorderWidth?: unknown;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n beforeId?: string;\n };\n\n const props = withDefaults(defineProps<Props>(), {\n visible: true,\n pickable: false,\n autoHighlight: false,\n billboard: true,\n background: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const LayerClass = shallowRef<\n typeof import('@deck.gl/layers').TextLayer | null\n >(null);\n\n const EXCLUDE = new Set([\n 'id',\n 'data',\n 'getPosition',\n 'getText',\n 'textColumn',\n ]);\n\n type ItemWithLabel = { position: [number, number]; label: string };\n\n const buildItems = (\n table: ArrowTableLike,\n textColumn: string,\n ): ItemWithLabel[] | null => {\n const extracted = extractPoints(table);\n if (!extracted) return null;\n const labelColumn = (\n table as unknown as {\n getChild: (\n k: string,\n ) => { toArray?: () => unknown[]; get?: (i: number) => unknown } | null;\n }\n ).getChild(textColumn);\n const labels: string[] = [];\n if (labelColumn) {\n const arr = labelColumn.toArray?.();\n if (arr) {\n for (let i = 0; i < extracted.length; i++) {\n labels.push(String(arr[i] ?? ''));\n }\n } else if (labelColumn.get) {\n for (let i = 0; i < extracted.length; i++) {\n labels.push(String(labelColumn.get(i) ?? ''));\n }\n }\n }\n const items: ItemWithLabel[] = [];\n for (let i = 0; i < extracted.length; i++) {\n items.push({\n position: [\n extracted.positions[i * 3] ?? 0,\n extracted.positions[i * 3 + 1] ?? 0,\n ],\n label: labels[i] ?? '',\n });\n }\n return items;\n };\n\n const createLayer = () => {\n if (!LayerClass.value || !props.data) return null;\n const items = buildItems(props.data, props.textColumn ?? 'name');\n if (!items) {\n console.error(\n '[VLayerDeckglGeoArrowText] no GeoArrow point geometry column found in data',\n );\n return null;\n }\n try {\n return markRaw(\n new LayerClass.value({\n ...filterDefined(\n props as unknown as Record<string, unknown>,\n EXCLUDE,\n ),\n id: props.id,\n data: items,\n getPosition: (d: ItemWithLabel) => d.position,\n getText: (d: ItemWithLabel) => d.label,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n }),\n );\n } catch (err) {\n console.error(\n '[VLayerDeckglGeoArrowText] failed to construct layer:',\n err,\n );\n return null;\n }\n };\n\n const initializeLayer = async () => {\n const mod = await requirePeer(\n '@deck.gl/layers',\n () => import('@deck.gl/layers'),\n TEXT_PEER_INSTALL,\n );\n LayerClass.value = markRaw(mod.TextLayer);\n };\n\n useMapReady(map, initializeLayer);\n\n watch(LayerClass, (cls) => {\n if (!cls || !props.data) return;\n const layer = createLayer();\n if (layer) addLayer(layer);\n });\n\n watch(\n () => props.data,\n () => {\n if (!LayerClass.value || !props.data) return;\n const layer = createLayer();\n if (layer) updateLayer(props.id, layer);\n },\n );\n\n watch(\n () => [\n props.getText,\n props.getPosition,\n props.getColor,\n props.getSize,\n props.getAngle,\n props.getTextAnchor,\n props.getAlignmentBaseline,\n props.sizeUnits,\n props.sizeScale,\n props.sizeMinPixels,\n props.sizeMaxPixels,\n props.billboard,\n props.fontFamily,\n props.fontWeight,\n props.background,\n props.opacity,\n props.visible,\n props.pickable,\n ],\n () => {\n if (!LayerClass.value || !props.data) return;\n const layer = createLayer();\n if (layer) updateLayer(props.id, layer);\n },\n );\n\n onBeforeUnmount(() => removeLayer(props.id));\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"wQA0BE,qmBAkCA,IAAM,EAAQ,EAQR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,EAAa,EAEjB,IAAI,EAEA,EAAU,IAAI,IAAI,CACtB,KACA,OACA,cACA,UACA,YACF,CAAC,EAIK,GACJ,EACA,IAC2B,CAC3B,IAAM,EAAY,EAAc,CAAK,EACrC,GAAI,CAAC,EAAW,OAAO,KACvB,IAAM,EACJ,EAKA,SAAS,CAAU,EACf,EAAmB,CAAC,EAC1B,GAAI,EAAa,CACf,IAAM,EAAM,EAAY,UAAU,EAClC,GAAI,EACF,IAAK,IAAI,EAAI,EAAG,EAAI,EAAU,OAAQ,IACpC,EAAO,KAAK,OAAO,EAAI,IAAM,EAAE,CAAC,OAE7B,GAAI,EAAY,IACrB,IAAK,IAAI,EAAI,EAAG,EAAI,EAAU,OAAQ,IACpC,EAAO,KAAK,OAAO,EAAY,IAAI,CAAC,GAAK,EAAE,CAAC,CAGlD,CACA,IAAM,EAAyB,CAAC,EAChC,IAAK,IAAI,EAAI,EAAG,EAAI,EAAU,OAAQ,IACpC,EAAM,KAAK,CACT,SAAU,CACR,EAAU,UAAU,EAAI,IAAM,EAC9B,EAAU,UAAU,EAAI,EAAI,IAAM,CACpC,EACA,MAAO,EAAO,IAAM,EACtB,CAAC,EAEH,OAAO,CACT,EAEM,MAAoB,CACxB,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OAAO,KAC7C,IAAM,EAAQ,EAAW,EAAM,KAAM,EAAM,YAAc,MAAM,EAC/D,GAAI,CAAC,EAIH,OAHA,QAAQ,MACN,4EACF,EACO,KAET,GAAI,CACF,OAAO,EACL,IAAI,EAAW,MAAM,CACnB,GAAG,EACD,EACA,CACF,EACA,GAAI,EAAM,GACV,KAAM,EACN,YAAc,GAAqB,EAAE,SACrC,QAAU,GAAqB,EAAE,MACjC,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAC,CACH,CACF,OAAS,EAAK,CAKZ,OAJA,QAAQ,MACN,wDACA,CACF,EACO,IACT,CACF,SAWA,EAAY,EAAK,SATmB,CAMlC,EAAW,MAAQ,GAAQ,MALT,EAChB,sBACM,OAAO,mBACb,qEACF,GAC+B,SAAS,CAC1C,CAEgC,EAEhC,EAAM,EAAa,GAAQ,CACzB,GAAI,CAAC,GAAO,CAAC,EAAM,KAAM,OACzB,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAS,CAAK,CAC3B,CAAC,EAED,MACQ,EAAM,SACN,CACJ,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OACtC,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAY,EAAM,GAAI,CAAK,CACxC,CACF,EAEA,MACQ,CACJ,EAAM,QACN,EAAM,YACN,EAAM,SACN,EAAM,QACN,EAAM,SACN,EAAM,cACN,EAAM,qBACN,EAAM,UACN,EAAM,UACN,EAAM,cACN,EAAM,cACN,EAAM,UACN,EAAM,WACN,EAAM,WACN,EAAM,WACN,EAAM,QACN,EAAM,QACN,EAAM,QACR,MACM,CACJ,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OACtC,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAY,EAAM,GAAI,CAAK,CACxC,CACF,EAEA,MAAsB,EAAY,EAAM,EAAE,CAAC,SAI3C,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{a as n,i as r}from"./useDeckOverlay-CI56uIKH.js";import{c as i,o as a,t as o}from"./arrow-B87Hvf8z.js";import{defineComponent as s,markRaw as c,onBeforeUnmount as l,renderSlot as u,shallowRef as d,watch as f}from"vue";const p=s({__name:`VLayerDeckglGeoArrowTrips`,props:{id:{},data:{},timestampsColumn:{},getPath:{},getTimestamps:{},getColor:{},getWidth:{},widthUnits:{},widthScale:{},widthMinPixels:{},widthMaxPixels:{},jointRounded:{type:Boolean,default:!1},capRounded:{type:Boolean,default:!1},miterLimit:{},billboard:{type:Boolean,default:!1},currentTime:{default:0},trailLength:{default:180},fadeTrail:{type:Boolean,default:!0},opacity:{},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!1},autoHighlight:{type:Boolean,default:!1},beforeId:{}},emits:[`click`,`hover`],setup(s,{emit:p}){let m=s,h=p,g=e(t),{addLayer:_,removeLayer:v,updateLayer:y}=r(g),b=d(null),x=new Set([`id`,`data`,`getPath`,`getTimestamps`,`timestampsColumn`]),S=(e,t)=>{let n=o(e);if(!n)return null;let r=e.getChild(t)?.data[0],i=r?.valueOffsets,a=r?.values,s=[];for(let e=0;e<n.length;e++){let t=n.startIndices[e]??0,r=n.startIndices[e+1]??0,o=[];for(let e=t;e<r;e++)o.push([n.positions[e*3]??0,n.positions[e*3+1]??0]);let c=[];if(i&&a){let t=i[e]??0,n=i[e+1]??0;for(let e=t;e<n;e++)c.push(Number(a[e]??0))}s.push({path:o,timestamps:c})}return s},C=()=>{if(!b.value||!m.data)return null;let e=S(m.data,m.timestampsColumn??`timestamps`);if(!e)return console.error(`[VLayerDeckglGeoArrowTrips] no GeoArrow linestring column found in data`),null;try{return c(new b.value({...a(m,x),id:m.id,data:e,getPath:e=>e.path,getTimestamps:e=>e.timestamps,onClick:e=>h(`click`,e),onHover:e=>h(`hover`,e)}))}catch(e){return console.error(`[VLayerDeckglGeoArrowTrips] failed to construct layer:`,e),null}};return i(g,async()=>{b.value=c((await n(`@deck.gl/geo-layers`,()=>import(`@deck.gl/geo-layers`),`pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers @deck.gl/geo-layers apache-arrow`)).TripsLayer)}),f(b,e=>{if(!e||!m.data)return;let t=C();t&&_(t)}),f(()=>[m.data,m.currentTime,m.trailLength,m.fadeTrail,m.getPath,m.getTimestamps,m.getColor,m.getWidth,m.widthUnits,m.widthScale,m.widthMinPixels,m.widthMaxPixels,m.opacity,m.visible,m.pickable],()=>{if(!b.value||!m.data)return;let e=C();e&&y(m.id,e)}),l(()=>v(m.id)),(e,t)=>u(e.$slots,`default`)}});export{p as VLayerDeckglGeoArrowTrips};
|
|
2
|
+
//# sourceMappingURL=geoarrow-trips-C9_EXHnn.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"geoarrow-trips-
|
|
1
|
+
{"version":3,"file":"geoarrow-trips-C9_EXHnn.js","names":[],"sources":["../src/layers/deckgl/geoarrow-trips/VLayerDeckglGeoArrowTrips.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render animated trips from an Apache Arrow `Table` or `RecordBatch`\n * containing GeoArrow linestring geometries (extension type\n * `geoarrow.linestring` or `geoarrow.multilinestring`) with per-vertex\n * timestamps in a parallel `List<float64>` column (default name\n * `timestamps`, overridable via the `timestampsColumn` prop).\n *\n * Wraps deck.gl's stock `TripsLayer` from `@deck.gl/geo-layers`. No\n * `@geoarrow/deck.gl-geoarrow` runtime dependency.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/layers`\n * @requires `@deck.gl/geo-layers`\n * @requires `@deck.gl/mapbox`\n * @requires `apache-arrow`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers @deck.gl/geo-layers apache-arrow`\n */\n import { onBeforeUnmount, watch, shallowRef, markRaw } from 'vue';\n import type { PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey, requirePeer } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import { useMapReady } from '../_shared/useMapReady';\n import { extractLineStrings, filterDefined } from '../_shared/arrow';\n import type { ArrowTableLike } from '../_shared/types';\n\n const TRIPS_PEER_INSTALL =\n 'pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers @deck.gl/geo-layers apache-arrow';\n\n type Props = {\n id: string;\n data: ArrowTableLike | null | undefined;\n timestampsColumn?: string;\n getPath?: unknown;\n getTimestamps?: unknown;\n getColor?: unknown;\n getWidth?: unknown;\n widthUnits?: 'meters' | 'common' | 'pixels';\n widthScale?: number;\n widthMinPixels?: number;\n widthMaxPixels?: number;\n jointRounded?: boolean;\n capRounded?: boolean;\n miterLimit?: number;\n billboard?: boolean;\n currentTime?: number;\n trailLength?: number;\n fadeTrail?: boolean;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n beforeId?: string;\n };\n\n const props = withDefaults(defineProps<Props>(), {\n visible: true,\n pickable: false,\n autoHighlight: false,\n jointRounded: false,\n capRounded: false,\n billboard: false,\n fadeTrail: true,\n trailLength: 180,\n currentTime: 0,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const LayerClass = shallowRef<\n typeof import('@deck.gl/geo-layers').TripsLayer | null\n >(null);\n\n const EXCLUDE = new Set([\n 'id',\n 'data',\n 'getPath',\n 'getTimestamps',\n 'timestampsColumn',\n ]);\n\n type Trip = { path: number[][]; timestamps: number[] };\n\n const buildTrips = (\n table: ArrowTableLike,\n timestampsColumn: string,\n ): Trip[] | null => {\n const extracted = extractLineStrings(table);\n if (!extracted) return null;\n const tsListColumn = (\n table as unknown as {\n getChild: (k: string) => {\n data: { valueOffsets?: Int32Array; values?: ArrayLike<number> }[];\n } | null;\n }\n ).getChild(timestampsColumn);\n const tsList = tsListColumn?.data[0];\n const tsOffsets = tsList?.valueOffsets;\n const tsValues = tsList?.values;\n const trips: Trip[] = [];\n for (let i = 0; i < extracted.length; i++) {\n const start = extracted.startIndices[i] ?? 0;\n const end = extracted.startIndices[i + 1] ?? 0;\n const path: number[][] = [];\n for (let v = start; v < end; v++) {\n path.push([\n extracted.positions[v * 3] ?? 0,\n extracted.positions[v * 3 + 1] ?? 0,\n ]);\n }\n const timestamps: number[] = [];\n if (tsOffsets && tsValues) {\n const tStart = tsOffsets[i] ?? 0;\n const tEnd = tsOffsets[i + 1] ?? 0;\n for (let t = tStart; t < tEnd; t++) {\n timestamps.push(Number(tsValues[t] ?? 0));\n }\n }\n trips.push({ path, timestamps });\n }\n return trips;\n };\n\n const createLayer = () => {\n if (!LayerClass.value || !props.data) return null;\n const trips = buildTrips(\n props.data,\n props.timestampsColumn ?? 'timestamps',\n );\n if (!trips) {\n console.error(\n '[VLayerDeckglGeoArrowTrips] no GeoArrow linestring column found in data',\n );\n return null;\n }\n try {\n return markRaw(\n new LayerClass.value({\n ...filterDefined(\n props as unknown as Record<string, unknown>,\n EXCLUDE,\n ),\n id: props.id,\n data: trips,\n getPath: (d: Trip) => d.path,\n getTimestamps: (d: Trip) => d.timestamps,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n }),\n );\n } catch (err) {\n console.error(\n '[VLayerDeckglGeoArrowTrips] failed to construct layer:',\n err,\n );\n return null;\n }\n };\n\n const initializeLayer = async () => {\n const mod = await requirePeer(\n '@deck.gl/geo-layers',\n () => import('@deck.gl/geo-layers'),\n TRIPS_PEER_INSTALL,\n );\n LayerClass.value = markRaw(mod.TripsLayer);\n };\n\n useMapReady(map, initializeLayer);\n\n watch(LayerClass, (cls) => {\n if (!cls || !props.data) return;\n const layer = createLayer();\n if (layer) addLayer(layer);\n });\n\n watch(\n () => [\n props.data,\n props.currentTime,\n props.trailLength,\n props.fadeTrail,\n props.getPath,\n props.getTimestamps,\n props.getColor,\n props.getWidth,\n props.widthUnits,\n props.widthScale,\n props.widthMinPixels,\n props.widthMaxPixels,\n props.opacity,\n props.visible,\n props.pickable,\n ],\n () => {\n if (!LayerClass.value || !props.data) return;\n const layer = createLayer();\n if (layer) updateLayer(props.id, layer);\n },\n );\n\n onBeforeUnmount(() => removeLayer(props.id));\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"6QA4BE,8kBA6BA,IAAM,EAAQ,EAYR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,EAAa,EAEjB,IAAI,EAEA,EAAU,IAAI,IAAI,CACtB,KACA,OACA,UACA,gBACA,kBACF,CAAC,EAIK,GACJ,EACA,IACkB,CAClB,IAAM,EAAY,EAAmB,CAAK,EAC1C,GAAI,CAAC,EAAW,OAAO,KAQvB,IAAM,EANJ,EAKA,SAAS,CACI,GAAc,KAAK,GAC5B,EAAY,GAAQ,aACpB,EAAW,GAAQ,OACnB,EAAgB,CAAC,EACvB,IAAK,IAAI,EAAI,EAAG,EAAI,EAAU,OAAQ,IAAK,CACzC,IAAM,EAAQ,EAAU,aAAa,IAAM,EACrC,EAAM,EAAU,aAAa,EAAI,IAAM,EACvC,EAAmB,CAAC,EAC1B,IAAK,IAAI,EAAI,EAAO,EAAI,EAAK,IAC3B,EAAK,KAAK,CACR,EAAU,UAAU,EAAI,IAAM,EAC9B,EAAU,UAAU,EAAI,EAAI,IAAM,CACpC,CAAC,EAEH,IAAM,EAAuB,CAAC,EAC9B,GAAI,GAAa,EAAU,CACzB,IAAM,EAAS,EAAU,IAAM,EACzB,EAAO,EAAU,EAAI,IAAM,EACjC,IAAK,IAAI,EAAI,EAAQ,EAAI,EAAM,IAC7B,EAAW,KAAK,OAAO,EAAS,IAAM,CAAC,CAAC,CAE5C,CACA,EAAM,KAAK,CAAE,OAAM,YAAW,CAAC,CACjC,CACA,OAAO,CACT,EAEM,MAAoB,CACxB,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OAAO,KAC7C,IAAM,EAAQ,EACZ,EAAM,KACN,EAAM,kBAAoB,YAC5B,EACA,GAAI,CAAC,EAIH,OAHA,QAAQ,MACN,yEACF,EACO,KAET,GAAI,CACF,OAAO,EACL,IAAI,EAAW,MAAM,CACnB,GAAG,EACD,EACA,CACF,EACA,GAAI,EAAM,GACV,KAAM,EACN,QAAU,GAAY,EAAE,KACxB,cAAgB,GAAY,EAAE,WAC9B,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAC,CACH,CACF,OAAS,EAAK,CAKZ,OAJA,QAAQ,MACN,yDACA,CACF,EACO,IACT,CACF,SAWA,EAAY,EAAK,SATmB,CAMlC,EAAW,MAAQ,GAAQ,MALT,EAChB,0BACM,OAAO,uBACb,yFACF,GAC+B,UAAU,CAC3C,CAEgC,EAEhC,EAAM,EAAa,GAAQ,CACzB,GAAI,CAAC,GAAO,CAAC,EAAM,KAAM,OACzB,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAS,CAAK,CAC3B,CAAC,EAED,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,YACN,EAAM,UACN,EAAM,QACN,EAAM,cACN,EAAM,SACN,EAAM,SACN,EAAM,WACN,EAAM,WACN,EAAM,eACN,EAAM,eACN,EAAM,QACN,EAAM,QACN,EAAM,QACR,MACM,CACJ,GAAI,CAAC,EAAW,OAAS,CAAC,EAAM,KAAM,OACtC,IAAM,EAAQ,EAAY,EACtB,GAAO,EAAY,EAAM,GAAI,CAAK,CACxC,CACF,EAEA,MAAsB,EAAY,EAAM,EAAE,CAAC,SAI3C,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{GeohashLayer as s}from"@deck.gl/geo-layers";const c=r({__name:`VLayerDeckglGeohash`,props:{id:{},data:{},getGeohash:{},getFillColor:{},getLineColor:{},getElevation:{},filled:{type:Boolean,default:!0},stroked:{type:Boolean,default:!0},extruded:{type:Boolean,default:!1},wireframe:{type:Boolean,default:!1},elevationScale:{default:1},lineWidthUnits:{default:`meters`},lineWidthScale:{default:1},lineWidthMinPixels:{default:0},lineWidthMaxPixels:{default:2**53-1},material:{type:[Boolean,Object]},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getGeohash:l.getGeohash,getFillColor:l.getFillColor??[255,0,0,255],getLineColor:l.getLineColor??[0,0,0,255],getElevation:l.getElevation??1e3,filled:l.filled,stroked:l.stroked,extruded:l.extruded,wireframe:l.wireframe,elevationScale:l.elevationScale,lineWidthUnits:l.lineWidthUnits,lineWidthScale:l.lineWidthScale,lineWidthMinPixels:l.lineWidthMinPixels,lineWidthMaxPixels:l.lineWidthMaxPixels,material:l.material,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getGeohash,l.getFillColor,l.getElevation,l.extruded,l.elevationScale,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglGeohash};
|
|
2
|
+
//# sourceMappingURL=geohash-vWnSK76U.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geohash-vWnSK76U.js","names":[],"sources":["../src/layers/deckgl/geohash/VLayerDeckglGeohash.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render Geohash cells as deck.gl polygons.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/geo-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/geo-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { GeohashLayer } from '@deck.gl/geo-layers';\n import type { GeohashLayerProps } from '@deck.gl/geo-layers';\n import type { Color, PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getGeohash: Accessor<D, string>;\n getFillColor?: Accessor<D, Color>;\n getLineColor?: Accessor<D, Color>;\n getElevation?: Accessor<D, number>;\n filled?: boolean;\n stroked?: boolean;\n extruded?: boolean;\n wireframe?: boolean;\n elevationScale?: number;\n lineWidthUnits?: 'meters' | 'common' | 'pixels';\n lineWidthScale?: number;\n lineWidthMinPixels?: number;\n lineWidthMaxPixels?: number;\n material?: boolean | object;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n filled: true,\n stroked: true,\n extruded: false,\n wireframe: false,\n elevationScale: 1,\n lineWidthUnits: 'meters',\n lineWidthScale: 1,\n lineWidthMinPixels: 0,\n lineWidthMaxPixels: Number.MAX_SAFE_INTEGER,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new GeohashLayer({\n id: props.id,\n data: props.data,\n getGeohash: props.getGeohash,\n getFillColor: props.getFillColor ?? [255, 0, 0, 255],\n getLineColor: props.getLineColor ?? [0, 0, 0, 255],\n getElevation: props.getElevation ?? 1000,\n filled: props.filled,\n stroked: props.stroked,\n extruded: props.extruded,\n wireframe: props.wireframe,\n elevationScale: props.elevationScale,\n lineWidthUnits: props.lineWidthUnits,\n lineWidthScale: props.lineWidthScale,\n lineWidthMinPixels: props.lineWidthMinPixels,\n lineWidthMaxPixels: props.lineWidthMaxPixels,\n material: props.material,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as GeohashLayerProps);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getGeohash,\n props.getFillColor,\n props.getElevation,\n props.extruded,\n props.elevationScale,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"k3BA6CE,IAAM,EAAQ,EAgBR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAa,CACtB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,WAAY,EAAM,WAClB,aAAc,EAAM,cAAgB,CAAC,IAAK,EAAG,EAAG,GAAG,EACnD,aAAc,EAAM,cAAgB,CAAC,EAAG,EAAG,EAAG,GAAG,EACjD,aAAc,EAAM,cAAgB,IACpC,OAAQ,EAAM,OACd,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,UAAW,EAAM,UACjB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,mBAAoB,EAAM,mBAC1B,mBAAoB,EAAM,mBAC1B,SAAU,EAAM,SAChB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAsB,EAGlB,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,WACN,EAAM,aACN,EAAM,aACN,EAAM,SACN,EAAM,eACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{GeoJsonLayer as s}from"@deck.gl/layers";const c=r({__name:`VLayerDeckglGeojson`,props:{id:{},data:{},getFillColor:{},getLineColor:{},getLineWidth:{},getPointRadius:{},getElevation:{},getText:{},filled:{type:Boolean,default:!0},stroked:{type:Boolean,default:!0},extruded:{type:Boolean,default:!1},wireframe:{type:Boolean,default:!1},pointType:{default:`circle`},lineWidthUnits:{default:`meters`},lineWidthScale:{default:1},lineWidthMinPixels:{default:0},lineWidthMaxPixels:{default:2**53-1},lineJointRounded:{type:Boolean,default:!1},lineCapRounded:{type:Boolean,default:!1},lineMiterLimit:{default:4},pointRadiusUnits:{default:`meters`},pointRadiusScale:{default:1},pointRadiusMinPixels:{default:0},pointRadiusMaxPixels:{default:2**53-1},elevationScale:{default:1},material:{type:[Boolean,Object]},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getFillColor:l.getFillColor??[200,200,200,200],getLineColor:l.getLineColor??[0,0,0,255],getLineWidth:l.getLineWidth??1,getPointRadius:l.getPointRadius??1,getElevation:l.getElevation??1e3,getText:l.getText,filled:l.filled,stroked:l.stroked,extruded:l.extruded,wireframe:l.wireframe,pointType:l.pointType,lineWidthUnits:l.lineWidthUnits,lineWidthScale:l.lineWidthScale,lineWidthMinPixels:l.lineWidthMinPixels,lineWidthMaxPixels:l.lineWidthMaxPixels,lineJointRounded:l.lineJointRounded,lineCapRounded:l.lineCapRounded,lineMiterLimit:l.lineMiterLimit,pointRadiusUnits:l.pointRadiusUnits,pointRadiusScale:l.pointRadiusScale,pointRadiusMinPixels:l.pointRadiusMinPixels,pointRadiusMaxPixels:l.pointRadiusMaxPixels,elevationScale:l.elevationScale,material:l.material,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getFillColor,l.getLineColor,l.opacity,l.visible,l.extruded],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglGeojson};
|
|
2
|
+
//# sourceMappingURL=geojson-CqnyNLW0.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geojson-CqnyNLW0.js","names":[],"sources":["../src/layers/deckgl/geojson/VLayerDeckglGeojson.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render GeoJSON FeatureCollections as deck.gl points/lines/polygons.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { GeoJsonLayer } from '@deck.gl/layers';\n import type { PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import type { Color } from '../_shared/types';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D | string | Promise<D>;\n getFillColor?: Accessor<D, Color>;\n getLineColor?: Accessor<D, Color>;\n getLineWidth?: Accessor<D, number>;\n getPointRadius?: Accessor<D, number>;\n getElevation?: Accessor<D, number>;\n getText?: Accessor<D, string>;\n filled?: boolean;\n stroked?: boolean;\n extruded?: boolean;\n wireframe?: boolean;\n pointType?: string;\n lineWidthUnits?: 'meters' | 'common' | 'pixels';\n lineWidthScale?: number;\n lineWidthMinPixels?: number;\n lineWidthMaxPixels?: number;\n lineJointRounded?: boolean;\n lineCapRounded?: boolean;\n lineMiterLimit?: number;\n pointRadiusUnits?: 'meters' | 'common' | 'pixels';\n pointRadiusScale?: number;\n pointRadiusMinPixels?: number;\n pointRadiusMaxPixels?: number;\n elevationScale?: number;\n material?: boolean | object;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n filled: true,\n stroked: true,\n extruded: false,\n wireframe: false,\n pointType: 'circle',\n lineWidthUnits: 'meters',\n lineWidthScale: 1,\n lineWidthMinPixels: 0,\n lineWidthMaxPixels: Number.MAX_SAFE_INTEGER,\n lineJointRounded: false,\n lineCapRounded: false,\n lineMiterLimit: 4,\n pointRadiusUnits: 'meters',\n pointRadiusScale: 1,\n pointRadiusMinPixels: 0,\n pointRadiusMaxPixels: Number.MAX_SAFE_INTEGER,\n elevationScale: 1,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new GeoJsonLayer({\n id: props.id,\n data: props.data,\n getFillColor: props.getFillColor ?? [200, 200, 200, 200],\n getLineColor: props.getLineColor ?? [0, 0, 0, 255],\n getLineWidth: props.getLineWidth ?? 1,\n getPointRadius: props.getPointRadius ?? 1,\n getElevation: props.getElevation ?? 1000,\n getText: props.getText,\n filled: props.filled,\n stroked: props.stroked,\n extruded: props.extruded,\n wireframe: props.wireframe,\n pointType: props.pointType,\n lineWidthUnits: props.lineWidthUnits,\n lineWidthScale: props.lineWidthScale,\n lineWidthMinPixels: props.lineWidthMinPixels,\n lineWidthMaxPixels: props.lineWidthMaxPixels,\n lineJointRounded: props.lineJointRounded,\n lineCapRounded: props.lineCapRounded,\n lineMiterLimit: props.lineMiterLimit,\n pointRadiusUnits: props.pointRadiusUnits,\n pointRadiusScale: props.pointRadiusScale,\n pointRadiusMinPixels: props.pointRadiusMinPixels,\n pointRadiusMaxPixels: props.pointRadiusMaxPixels,\n elevationScale: props.elevationScale,\n material: props.material,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as unknown as ConstructorParameters<typeof GeoJsonLayer>[0]);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getFillColor,\n props.getLineColor,\n props.opacity,\n props.visible,\n props.extruded,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"kqCAuDE,IAAM,EAAQ,EAwBR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAa,CACtB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,aAAc,EAAM,cAAgB,CAAC,IAAK,IAAK,IAAK,GAAG,EACvD,aAAc,EAAM,cAAgB,CAAC,EAAG,EAAG,EAAG,GAAG,EACjD,aAAc,EAAM,cAAgB,EACpC,eAAgB,EAAM,gBAAkB,EACxC,aAAc,EAAM,cAAgB,IACpC,QAAS,EAAM,QACf,OAAQ,EAAM,OACd,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,UAAW,EAAM,UACjB,UAAW,EAAM,UACjB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,mBAAoB,EAAM,mBAC1B,mBAAoB,EAAM,mBAC1B,iBAAkB,EAAM,iBACxB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,iBAAkB,EAAM,iBACxB,iBAAkB,EAAM,iBACxB,qBAAsB,EAAM,qBAC5B,qBAAsB,EAAM,qBAC5B,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAA6D,EAGzD,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,aACN,EAAM,aACN,EAAM,QACN,EAAM,QACN,EAAM,QACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { i as useDeckOverlay, n as DeckOverlayKey, r as useDeckLayers, t as DeckLayersKey } from "./useDeckOverlay-JoRzVQ7g.js";
|
|
2
|
+
import { Component } from "vue";
|
|
3
|
+
import { MosaicSource as MosaicSource$1 } from "@developmentseed/deck.gl-geotiff";
|
|
4
|
+
//#region src/layers/deckgl/mosaic/VLayerMosaic.vue.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* A STAC-like item with bounding box and COG asset URL
|
|
7
|
+
* Extends the base MosaicSource from deck.gl-geotiff with asset info
|
|
8
|
+
*/
|
|
9
|
+
interface MosaicSource extends MosaicSource$1 {
|
|
10
|
+
/** Asset containing the COG URL */
|
|
11
|
+
assets: {
|
|
12
|
+
image: {
|
|
13
|
+
href: string;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Render mode for the mosaic layer
|
|
19
|
+
*/
|
|
20
|
+
type MosaicRenderMode = 'trueColor' | 'falseColor' | 'ndvi' | 'custom';
|
|
21
|
+
/**
|
|
22
|
+
* Custom render module for advanced band manipulation
|
|
23
|
+
*/
|
|
24
|
+
interface RenderModule {
|
|
25
|
+
module: {
|
|
26
|
+
name: string;
|
|
27
|
+
inject?: Record<string, string>;
|
|
28
|
+
};
|
|
29
|
+
props?: Record<string, unknown>;
|
|
30
|
+
}
|
|
31
|
+
//#endregion
|
|
32
|
+
//#region src/layers/deckgl/multi-cog/VLayerMultiCog.vue.d.ts
|
|
33
|
+
/**
|
|
34
|
+
* Maps source band names to RGB(A) output channels for the compositing step.
|
|
35
|
+
*/
|
|
36
|
+
interface MultiCogComposite {
|
|
37
|
+
r: string;
|
|
38
|
+
g?: string;
|
|
39
|
+
b?: string;
|
|
40
|
+
a?: string;
|
|
41
|
+
}
|
|
42
|
+
//#endregion
|
|
43
|
+
//#region src/layers/deckgl/geotiff.d.ts
|
|
44
|
+
declare const VLayerCog: Component;
|
|
45
|
+
declare const VLayerMosaic: Component;
|
|
46
|
+
declare const VLayerMultiCog: Component;
|
|
47
|
+
declare const VLayerZarr: Component;
|
|
48
|
+
//#endregion
|
|
49
|
+
export { DeckLayersKey, DeckOverlayKey, type MosaicRenderMode, type MosaicSource, type MultiCogComposite, type RenderModule, VLayerCog, VLayerMosaic, VLayerMultiCog, VLayerZarr, useDeckLayers, useDeckOverlay };
|
|
50
|
+
//# sourceMappingURL=geotiff.d.ts.map
|
package/dist/geotiff.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{i as e,n as t,r as n,t as r}from"./useDeckOverlay-CI56uIKH.js";import{defineAsyncComponent as i}from"vue";const a=i(()=>import(`./cog-B3kQFMdO.js`).then(e=>e.VLayerCog)),o=i(()=>import(`./mosaic-Bm1aKa0Q.js`).then(e=>e.VLayerMosaic)),s=i(()=>import(`./multi-cog-D2ys9o3u.js`).then(e=>e.VLayerMultiCog)),c=i(()=>import(`./zarr-BWbq3Uwq.js`).then(e=>e.VLayerZarr));export{r as DeckLayersKey,t as DeckOverlayKey,a as VLayerCog,o as VLayerMosaic,s as VLayerMultiCog,c as VLayerZarr,n as useDeckLayers,e as useDeckOverlay};
|
|
2
|
+
//# sourceMappingURL=geotiff.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geotiff.js","names":[],"sources":["../src/layers/deckgl/geotiff.ts"],"sourcesContent":["import { defineAsyncComponent, type Component } from 'vue';\n\nexport const VLayerCog: Component = defineAsyncComponent(() =>\n import('./cog').then((m) => m.VLayerCog),\n);\nexport const VLayerMosaic: Component = defineAsyncComponent(() =>\n import('./mosaic').then((m) => m.VLayerMosaic),\n);\nexport type { MosaicSource, MosaicRenderMode, RenderModule } from './mosaic';\nexport const VLayerMultiCog: Component = defineAsyncComponent(() =>\n import('./multi-cog').then((m) => m.VLayerMultiCog),\n);\nexport type { MultiCogComposite } from './multi-cog';\nexport const VLayerZarr: Component = defineAsyncComponent(() =>\n import('./zarr').then((m) => m.VLayerZarr),\n);\n"],"mappings":"iHAEA,MAAa,EAAuB,MAClC,OAAO,qBAAS,KAAM,GAAM,EAAE,SAAS,CACzC,EACa,EAA0B,MACrC,OAAO,wBAAY,KAAM,GAAM,EAAE,YAAY,CAC/C,EAEa,EAA4B,MACvC,OAAO,2BAAe,KAAM,GAAM,EAAE,cAAc,CACpD,EAEa,EAAwB,MACnC,OAAO,sBAAU,KAAM,GAAM,EAAE,UAAU,CAC3C"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{GreatCircleLayer as s}from"@deck.gl/geo-layers";const c=r({__name:`VLayerDeckglGreatCircle`,props:{id:{},data:{},getSourcePosition:{},getTargetPosition:{},getSourceColor:{},getTargetColor:{},getWidth:{},getHeight:{},getTilt:{},numSegments:{default:50},widthUnits:{default:`pixels`},widthScale:{default:1},widthMinPixels:{default:0},widthMaxPixels:{default:2**53-1},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getSourcePosition:l.getSourcePosition,getTargetPosition:l.getTargetPosition,getSourceColor:l.getSourceColor??[0,0,255],getTargetColor:l.getTargetColor??[0,255,0],getWidth:l.getWidth??1,getHeight:l.getHeight??1,getTilt:l.getTilt??0,numSegments:l.numSegments,widthUnits:l.widthUnits,widthScale:l.widthScale,widthMinPixels:l.widthMinPixels,widthMaxPixels:l.widthMaxPixels,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getSourcePosition,l.getTargetPosition,l.getSourceColor,l.getTargetColor,l.getWidth,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglGreatCircle};
|
|
2
|
+
//# sourceMappingURL=great-circle-Bz8TvCiM.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"great-circle-Bz8TvCiM.js","names":[],"sources":["../src/layers/deckgl/great-circle/VLayerDeckglGreatCircle.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render great-circle arcs between coordinate pairs.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/geo-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/geo-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { GreatCircleLayer } from '@deck.gl/geo-layers';\n import type { GreatCircleLayerProps } from '@deck.gl/geo-layers';\n import type { Color, PickingInfo, Position } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getSourcePosition: Accessor<D, Position>;\n getTargetPosition: Accessor<D, Position>;\n getSourceColor?: Accessor<D, Color>;\n getTargetColor?: Accessor<D, Color>;\n getWidth?: Accessor<D, number>;\n getHeight?: Accessor<D, number>;\n getTilt?: Accessor<D, number>;\n numSegments?: number;\n widthUnits?: 'meters' | 'common' | 'pixels';\n widthScale?: number;\n widthMinPixels?: number;\n widthMaxPixels?: number;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n numSegments: 50,\n widthUnits: 'pixels',\n widthScale: 1,\n widthMinPixels: 0,\n widthMaxPixels: Number.MAX_SAFE_INTEGER,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new GreatCircleLayer({\n id: props.id,\n data: props.data,\n getSourcePosition: props.getSourcePosition,\n getTargetPosition: props.getTargetPosition,\n getSourceColor: props.getSourceColor ?? [0, 0, 255],\n getTargetColor: props.getTargetColor ?? [0, 255, 0],\n getWidth: props.getWidth ?? 1,\n getHeight: props.getHeight ?? 1,\n getTilt: props.getTilt ?? 0,\n numSegments: props.numSegments,\n widthUnits: props.widthUnits,\n widthScale: props.widthScale,\n widthMinPixels: props.widthMinPixels,\n widthMaxPixels: props.widthMaxPixels,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as GreatCircleLayerProps);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getSourcePosition,\n props.getTargetPosition,\n props.getSourceColor,\n props.getTargetColor,\n props.getWidth,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"ivBA2CE,IAAM,EAAQ,EAYR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAiB,CAC1B,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,kBAAmB,EAAM,kBACzB,kBAAmB,EAAM,kBACzB,eAAgB,EAAM,gBAAkB,CAAC,EAAG,EAAG,GAAG,EAClD,eAAgB,EAAM,gBAAkB,CAAC,EAAG,IAAK,CAAC,EAClD,SAAU,EAAM,UAAY,EAC5B,UAAW,EAAM,WAAa,EAC9B,QAAS,EAAM,SAAW,EAC1B,YAAa,EAAM,YACnB,WAAY,EAAM,WAClB,WAAY,EAAM,WAClB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAA0B,EAGtB,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,kBACN,EAAM,kBACN,EAAM,eACN,EAAM,eACN,EAAM,SACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{GridLayer as s}from"@deck.gl/aggregation-layers";const c=r({__name:`VLayerDeckglGrid`,props:{id:{},data:{},getPosition:{},getColorWeight:{},getElevationWeight:{},cellSize:{default:1e3},colorRange:{},coverage:{default:1},elevationDomain:{},elevationRange:{},elevationScale:{default:1},extruded:{type:Boolean,default:!1},upperPercentile:{default:100},lowerPercentile:{default:0},elevationUpperPercentile:{default:100},elevationLowerPercentile:{default:0},colorScaleType:{default:`quantize`},colorAggregation:{default:`SUM`},elevationAggregation:{default:`SUM`},gpuAggregation:{type:Boolean,default:!1},material:{type:[Boolean,Object]},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getPosition:l.getPosition,getColorWeight:l.getColorWeight??1,getElevationWeight:l.getElevationWeight??1,cellSize:l.cellSize,colorRange:l.colorRange,coverage:l.coverage,elevationDomain:l.elevationDomain,elevationRange:l.elevationRange,elevationScale:l.elevationScale,extruded:l.extruded,upperPercentile:l.upperPercentile,lowerPercentile:l.lowerPercentile,elevationUpperPercentile:l.elevationUpperPercentile,elevationLowerPercentile:l.elevationLowerPercentile,colorScaleType:l.colorScaleType,colorAggregation:l.colorAggregation,elevationAggregation:l.elevationAggregation,gpuAggregation:l.gpuAggregation,material:l.material,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getPosition,l.cellSize,l.colorRange,l.elevationScale,l.extruded,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglGrid};
|
|
2
|
+
//# sourceMappingURL=grid-B_D40N2N.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-B_D40N2N.js","names":[],"sources":["../src/layers/deckgl/grid/VLayerDeckglGrid.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Aggregate points into a regular square grid (GPU or CPU).\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/aggregation-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/aggregation-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { GridLayer } from '@deck.gl/aggregation-layers';\n import type { Color, PickingInfo, Position } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getPosition: Accessor<D, Position>;\n getColorWeight?: Accessor<D, number>;\n getElevationWeight?: Accessor<D, number>;\n cellSize?: number;\n colorRange?: Color[];\n coverage?: number;\n elevationDomain?: [number, number];\n elevationRange?: [number, number];\n elevationScale?: number;\n extruded?: boolean;\n upperPercentile?: number;\n lowerPercentile?: number;\n elevationUpperPercentile?: number;\n elevationLowerPercentile?: number;\n colorScaleType?: 'quantize' | 'linear' | 'quantile' | 'ordinal';\n colorAggregation?: 'SUM' | 'MEAN' | 'MIN' | 'MAX';\n elevationAggregation?: 'SUM' | 'MEAN' | 'MIN' | 'MAX';\n gpuAggregation?: boolean;\n material?: boolean | object;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n cellSize: 1000,\n coverage: 1,\n elevationScale: 1,\n extruded: false,\n upperPercentile: 100,\n lowerPercentile: 0,\n elevationUpperPercentile: 100,\n elevationLowerPercentile: 0,\n colorScaleType: 'quantize',\n colorAggregation: 'SUM',\n elevationAggregation: 'SUM',\n gpuAggregation: false,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new GridLayer({\n id: props.id,\n data: props.data,\n getPosition: props.getPosition,\n getColorWeight: props.getColorWeight ?? 1,\n getElevationWeight: props.getElevationWeight ?? 1,\n cellSize: props.cellSize,\n colorRange: props.colorRange,\n coverage: props.coverage,\n elevationDomain: props.elevationDomain,\n elevationRange: props.elevationRange,\n elevationScale: props.elevationScale,\n extruded: props.extruded,\n upperPercentile: props.upperPercentile,\n lowerPercentile: props.lowerPercentile,\n elevationUpperPercentile: props.elevationUpperPercentile,\n elevationLowerPercentile: props.elevationLowerPercentile,\n colorScaleType: props.colorScaleType,\n colorAggregation: props.colorAggregation,\n elevationAggregation: props.elevationAggregation,\n gpuAggregation: props.gpuAggregation,\n material: props.material,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as unknown as ConstructorParameters<typeof GridLayer>[0]);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getPosition,\n props.cellSize,\n props.colorRange,\n props.elevationScale,\n props.extruded,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"6/BAiDE,IAAM,EAAQ,EAmBR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAU,CACnB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,YAAa,EAAM,YACnB,eAAgB,EAAM,gBAAkB,EACxC,mBAAoB,EAAM,oBAAsB,EAChD,SAAU,EAAM,SAChB,WAAY,EAAM,WAClB,SAAU,EAAM,SAChB,gBAAiB,EAAM,gBACvB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,gBAAiB,EAAM,gBACvB,gBAAiB,EAAM,gBACvB,yBAA0B,EAAM,yBAChC,yBAA0B,EAAM,yBAChC,eAAgB,EAAM,eACtB,iBAAkB,EAAM,iBACxB,qBAAsB,EAAM,qBAC5B,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAA0D,EAGtD,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,SACN,EAAM,WACN,EAAM,eACN,EAAM,SACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{GridCellLayer as s}from"@deck.gl/layers";const c=r({__name:`VLayerDeckglGridCell`,props:{id:{},data:{},getPosition:{},getFillColor:{},getElevation:{},cellSize:{default:1e3},coverage:{default:1},elevationScale:{default:1},extruded:{type:Boolean,default:!0},material:{type:[Boolean,Object]},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getPosition:l.getPosition,getFillColor:l.getFillColor??[255,0,0,255],getElevation:l.getElevation??1e3,cellSize:l.cellSize,coverage:l.coverage,elevationScale:l.elevationScale,extruded:l.extruded,material:l.material,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getPosition,l.getFillColor,l.getElevation,l.cellSize,l.elevationScale,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglGridCell};
|
|
2
|
+
//# sourceMappingURL=grid-cell-fa_NejcO.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-cell-fa_NejcO.js","names":[],"sources":["../src/layers/deckgl/grid-cell/VLayerDeckglGridCell.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render arbitrary axis-aligned grid cells with extrusion.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { GridCellLayer } from '@deck.gl/layers';\n import type { GridCellLayerProps } from '@deck.gl/layers';\n import type { Color, PickingInfo, Position } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getPosition: Accessor<D, Position>;\n getFillColor?: Accessor<D, Color>;\n getElevation?: Accessor<D, number>;\n cellSize?: number;\n coverage?: number;\n elevationScale?: number;\n extruded?: boolean;\n material?: boolean | object;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n cellSize: 1000,\n coverage: 1,\n elevationScale: 1,\n extruded: true,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new GridCellLayer({\n id: props.id,\n data: props.data,\n getPosition: props.getPosition,\n getFillColor: props.getFillColor ?? [255, 0, 0, 255],\n getElevation: props.getElevation ?? 1000,\n cellSize: props.cellSize,\n coverage: props.coverage,\n elevationScale: props.elevationScale,\n extruded: props.extruded,\n material: props.material,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as GridCellLayerProps);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getPosition,\n props.getFillColor,\n props.getElevation,\n props.cellSize,\n props.elevationScale,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"qqBAuCE,IAAM,EAAQ,EAWR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAc,CACvB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,YAAa,EAAM,YACnB,aAAc,EAAM,cAAgB,CAAC,IAAK,EAAG,EAAG,GAAG,EACnD,aAAc,EAAM,cAAgB,IACpC,SAAU,EAAM,SAChB,SAAU,EAAM,SAChB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,SAAU,EAAM,SAChB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAuB,EAGnB,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,aACN,EAAM,aACN,EAAM,SACN,EAAM,eACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{H3ClusterLayer as s}from"@deck.gl/geo-layers";const c=r({__name:`VLayerDeckglH3Cluster`,props:{id:{},data:{},getHexagons:{},getFillColor:{},getLineColor:{},getElevation:{},filled:{type:Boolean,default:!0},stroked:{type:Boolean,default:!0},extruded:{type:Boolean,default:!1},wireframe:{type:Boolean,default:!1},elevationScale:{default:1},lineWidthUnits:{default:`meters`},lineWidthScale:{default:1},lineWidthMinPixels:{default:0},lineWidthMaxPixels:{default:2**53-1},material:{type:[Boolean,Object]},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getHexagons:l.getHexagons,getFillColor:l.getFillColor??[255,0,0,255],getLineColor:l.getLineColor??[0,0,0,255],getElevation:l.getElevation??1e3,filled:l.filled,stroked:l.stroked,extruded:l.extruded,wireframe:l.wireframe,elevationScale:l.elevationScale,lineWidthUnits:l.lineWidthUnits,lineWidthScale:l.lineWidthScale,lineWidthMinPixels:l.lineWidthMinPixels,lineWidthMaxPixels:l.lineWidthMaxPixels,material:l.material,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getHexagons,l.getFillColor,l.getElevation,l.extruded,l.elevationScale,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglH3Cluster};
|
|
2
|
+
//# sourceMappingURL=h3-cluster-Cg0CEA_m.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"h3-cluster-Cg0CEA_m.js","names":[],"sources":["../src/layers/deckgl/h3-cluster/VLayerDeckglH3Cluster.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render groups of contiguous H3 cells as merged polygons.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/geo-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/geo-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { H3ClusterLayer } from '@deck.gl/geo-layers';\n import type { H3ClusterLayerProps } from '@deck.gl/geo-layers';\n import type { Color, PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getHexagons: Accessor<D, string[]>;\n getFillColor?: Accessor<D, Color>;\n getLineColor?: Accessor<D, Color>;\n getElevation?: Accessor<D, number>;\n filled?: boolean;\n stroked?: boolean;\n extruded?: boolean;\n wireframe?: boolean;\n elevationScale?: number;\n lineWidthUnits?: 'meters' | 'common' | 'pixels';\n lineWidthScale?: number;\n lineWidthMinPixels?: number;\n lineWidthMaxPixels?: number;\n material?: boolean | object;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n filled: true,\n stroked: true,\n extruded: false,\n wireframe: false,\n elevationScale: 1,\n lineWidthUnits: 'meters',\n lineWidthScale: 1,\n lineWidthMinPixels: 0,\n lineWidthMaxPixels: Number.MAX_SAFE_INTEGER,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new H3ClusterLayer({\n id: props.id,\n data: props.data,\n getHexagons: props.getHexagons,\n getFillColor: props.getFillColor ?? [255, 0, 0, 255],\n getLineColor: props.getLineColor ?? [0, 0, 0, 255],\n getElevation: props.getElevation ?? 1000,\n filled: props.filled,\n stroked: props.stroked,\n extruded: props.extruded,\n wireframe: props.wireframe,\n elevationScale: props.elevationScale,\n lineWidthUnits: props.lineWidthUnits,\n lineWidthScale: props.lineWidthScale,\n lineWidthMinPixels: props.lineWidthMinPixels,\n lineWidthMaxPixels: props.lineWidthMaxPixels,\n material: props.material,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as H3ClusterLayerProps);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getHexagons,\n props.getFillColor,\n props.getElevation,\n props.extruded,\n props.elevationScale,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"u3BA6CE,IAAM,EAAQ,EAgBR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAe,CACxB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,YAAa,EAAM,YACnB,aAAc,EAAM,cAAgB,CAAC,IAAK,EAAG,EAAG,GAAG,EACnD,aAAc,EAAM,cAAgB,CAAC,EAAG,EAAG,EAAG,GAAG,EACjD,aAAc,EAAM,cAAgB,IACpC,OAAQ,EAAM,OACd,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,UAAW,EAAM,UACjB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,mBAAoB,EAAM,mBAC1B,mBAAoB,EAAM,mBAC1B,SAAU,EAAM,SAChB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAwB,EAGpB,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,aACN,EAAM,aACN,EAAM,SACN,EAAM,eACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{H3HexagonLayer as s}from"@deck.gl/geo-layers";const c=r({__name:`VLayerDeckglH3Hexagon`,props:{id:{},data:{},getHexagon:{},getFillColor:{},getLineColor:{},getElevation:{},highPrecision:{type:[Boolean,String],default:`auto`},coverage:{default:1},elevationScale:{default:1},filled:{type:Boolean,default:!0},stroked:{type:Boolean,default:!0},extruded:{type:Boolean,default:!1},wireframe:{type:Boolean,default:!1},lineWidthUnits:{default:`meters`},lineWidthScale:{default:1},lineWidthMinPixels:{default:0},lineWidthMaxPixels:{default:2**53-1},material:{type:[Boolean,Object]},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getHexagon:l.getHexagon,getFillColor:l.getFillColor??[255,0,0,255],getLineColor:l.getLineColor??[0,0,0,255],getElevation:l.getElevation??1e3,highPrecision:l.highPrecision,coverage:l.coverage,elevationScale:l.elevationScale,filled:l.filled,stroked:l.stroked,extruded:l.extruded,wireframe:l.wireframe,lineWidthUnits:l.lineWidthUnits,lineWidthScale:l.lineWidthScale,lineWidthMinPixels:l.lineWidthMinPixels,lineWidthMaxPixels:l.lineWidthMaxPixels,material:l.material,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getHexagon,l.getFillColor,l.getElevation,l.extruded,l.elevationScale,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglH3Hexagon};
|
|
2
|
+
//# sourceMappingURL=h3-hexagon-DkIZnQEf.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"h3-hexagon-DkIZnQEf.js","names":[],"sources":["../src/layers/deckgl/h3-hexagon/VLayerDeckglH3Hexagon.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Render Uber H3 hexagons as individual filled cells.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/geo-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/geo-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { H3HexagonLayer } from '@deck.gl/geo-layers';\n import type { H3HexagonLayerProps } from '@deck.gl/geo-layers';\n import type { Color, PickingInfo } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getHexagon: Accessor<D, string>;\n getFillColor?: Accessor<D, Color>;\n getLineColor?: Accessor<D, Color>;\n getElevation?: Accessor<D, number>;\n highPrecision?: boolean | 'auto';\n coverage?: number;\n elevationScale?: number;\n filled?: boolean;\n stroked?: boolean;\n extruded?: boolean;\n wireframe?: boolean;\n lineWidthUnits?: 'meters' | 'common' | 'pixels';\n lineWidthScale?: number;\n lineWidthMinPixels?: number;\n lineWidthMaxPixels?: number;\n material?: boolean | object;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n highPrecision: 'auto',\n coverage: 1,\n elevationScale: 1,\n filled: true,\n stroked: true,\n extruded: false,\n wireframe: false,\n lineWidthUnits: 'meters',\n lineWidthScale: 1,\n lineWidthMinPixels: 0,\n lineWidthMaxPixels: Number.MAX_SAFE_INTEGER,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new H3HexagonLayer({\n id: props.id,\n data: props.data,\n getHexagon: props.getHexagon,\n getFillColor: props.getFillColor ?? [255, 0, 0, 255],\n getLineColor: props.getLineColor ?? [0, 0, 0, 255],\n getElevation: props.getElevation ?? 1000,\n highPrecision: props.highPrecision,\n coverage: props.coverage,\n elevationScale: props.elevationScale,\n filled: props.filled,\n stroked: props.stroked,\n extruded: props.extruded,\n wireframe: props.wireframe,\n lineWidthUnits: props.lineWidthUnits,\n lineWidthScale: props.lineWidthScale,\n lineWidthMinPixels: props.lineWidthMinPixels,\n lineWidthMaxPixels: props.lineWidthMaxPixels,\n material: props.material,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as H3HexagonLayerProps);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getHexagon,\n props.getFillColor,\n props.getElevation,\n props.extruded,\n props.elevationScale,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"g8BA+CE,IAAM,EAAQ,EAkBR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAe,CACxB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,WAAY,EAAM,WAClB,aAAc,EAAM,cAAgB,CAAC,IAAK,EAAG,EAAG,GAAG,EACnD,aAAc,EAAM,cAAgB,CAAC,EAAG,EAAG,EAAG,GAAG,EACjD,aAAc,EAAM,cAAgB,IACpC,cAAe,EAAM,cACrB,SAAU,EAAM,SAChB,eAAgB,EAAM,eACtB,OAAQ,EAAM,OACd,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,UAAW,EAAM,UACjB,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,mBAAoB,EAAM,mBAC1B,mBAAoB,EAAM,mBAC1B,SAAU,EAAM,SAChB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAwB,EAGpB,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,WACN,EAAM,aACN,EAAM,aACN,EAAM,SACN,EAAM,eACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{HeatmapLayer as s}from"@deck.gl/aggregation-layers";const c=r({__name:`VLayerDeckglHeatmap`,props:{id:{},data:{},getPosition:{},getWeight:{},intensity:{default:1},radiusPixels:{default:30},colorRange:{},threshold:{default:.05},colorDomain:{},aggregation:{default:`SUM`},weightsTextureSize:{default:2048},debounceTimeout:{default:500},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!1},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getPosition:l.getPosition,getWeight:l.getWeight??1,intensity:l.intensity,radiusPixels:l.radiusPixels,colorRange:l.colorRange,threshold:l.threshold,colorDomain:l.colorDomain,aggregation:l.aggregation,weightsTextureSize:l.weightsTextureSize,debounceTimeout:l.debounceTimeout,opacity:l.opacity,visible:l.visible,pickable:l.pickable,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getPosition,l.getWeight,l.intensity,l.radiusPixels,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglHeatmap};
|
|
2
|
+
//# sourceMappingURL=heatmap-D7R9nYug.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"heatmap-D7R9nYug.js","names":[],"sources":["../src/layers/deckgl/heatmap/VLayerDeckglHeatmap.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Gaussian-kernel heatmap from point data, GPU-aggregated.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/aggregation-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/aggregation-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { HeatmapLayer } from '@deck.gl/aggregation-layers';\n import type { PickingInfo, Position } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import type { Color } from '../_shared/types';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getPosition: Accessor<D, Position>;\n getWeight?: Accessor<D, number>;\n intensity?: number;\n radiusPixels?: number;\n colorRange?: Color[];\n threshold?: number;\n colorDomain?: [number, number];\n aggregation?: 'SUM' | 'MEAN';\n weightsTextureSize?: number;\n debounceTimeout?: number;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n intensity: 1,\n radiusPixels: 30,\n threshold: 0.05,\n aggregation: 'SUM',\n weightsTextureSize: 2048,\n debounceTimeout: 500,\n opacity: 1,\n visible: true,\n pickable: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new HeatmapLayer({\n id: props.id,\n data: props.data,\n getPosition: props.getPosition,\n getWeight: props.getWeight ?? 1,\n intensity: props.intensity,\n radiusPixels: props.radiusPixels,\n colorRange: props.colorRange,\n threshold: props.threshold,\n colorDomain: props.colorDomain,\n aggregation: props.aggregation,\n weightsTextureSize: props.weightsTextureSize,\n debounceTimeout: props.debounceTimeout,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as unknown as ConstructorParameters<typeof HeatmapLayer>[0]);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getPosition,\n props.getWeight,\n props.intensity,\n props.radiusPixels,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"wpBAuCE,IAAM,EAAQ,EAYR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAa,CACtB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,YAAa,EAAM,YACnB,UAAW,EAAM,WAAa,EAC9B,UAAW,EAAM,UACjB,aAAc,EAAM,aACpB,WAAY,EAAM,WAClB,UAAW,EAAM,UACjB,YAAa,EAAM,YACnB,YAAa,EAAM,YACnB,mBAAoB,EAAM,mBAC1B,gBAAiB,EAAM,gBACvB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAA6D,EAGzD,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,UACN,EAAM,UACN,EAAM,aACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{HexagonLayer as s}from"@deck.gl/aggregation-layers";const c=r({__name:`VLayerDeckglHexagon`,props:{id:{},data:{},getPosition:{},getColorWeight:{},getElevationWeight:{},gpuAggregation:{type:Boolean,default:!1},radius:{default:1e3},elevationScale:{default:1},elevationRange:{},colorRange:{},colorDomain:{},coverage:{default:1},extruded:{type:Boolean,default:!1},upperPercentile:{default:100},lowerPercentile:{default:0},elevationUpperPercentile:{default:100},elevationLowerPercentile:{default:0},colorScaleType:{default:`quantize`},material:{type:[Boolean,Object]},colorAggregation:{default:`SUM`},elevationAggregation:{default:`SUM`},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getPosition:l.getPosition,getColorWeight:l.getColorWeight??(()=>1),getElevationWeight:l.getElevationWeight??(()=>1),gpuAggregation:l.gpuAggregation,radius:l.radius,elevationScale:l.elevationScale,elevationRange:l.elevationRange,colorRange:l.colorRange,colorDomain:l.colorDomain,coverage:l.coverage,extruded:l.extruded,upperPercentile:l.upperPercentile,lowerPercentile:l.lowerPercentile,elevationUpperPercentile:l.elevationUpperPercentile,elevationLowerPercentile:l.elevationLowerPercentile,colorScaleType:l.colorScaleType,material:l.material,colorAggregation:l.colorAggregation,elevationAggregation:l.elevationAggregation,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getPosition,l.radius,l.elevationScale,l.opacity,l.visible,l.extruded],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglHexagon};
|
|
2
|
+
//# sourceMappingURL=hexagon-Bl_UBlOT.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hexagon-Bl_UBlOT.js","names":[],"sources":["../src/layers/deckgl/hexagon/VLayerDeckglHexagon.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Aggregate points into screen-resolved hexagons with extrusion.\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/aggregation-layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/aggregation-layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { HexagonLayer } from '@deck.gl/aggregation-layers';\n import type { PickingInfo, Position } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import type { Color } from '../_shared/types';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getPosition: Accessor<D, Position>;\n getColorWeight?: Accessor<D, number>;\n getElevationWeight?: Accessor<D, number>;\n gpuAggregation?: boolean;\n radius?: number;\n elevationScale?: number;\n elevationRange?: [number, number];\n colorRange?: Color[];\n colorDomain?: [number, number];\n coverage?: number;\n extruded?: boolean;\n upperPercentile?: number;\n lowerPercentile?: number;\n elevationUpperPercentile?: number;\n elevationLowerPercentile?: number;\n colorScaleType?: 'quantize' | 'linear' | 'quantile' | 'ordinal';\n material?: boolean | object;\n colorAggregation?: 'SUM' | 'MEAN' | 'MIN' | 'MAX' | 'COUNT';\n elevationAggregation?: 'SUM' | 'MEAN' | 'MIN' | 'MAX' | 'COUNT';\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n gpuAggregation: false,\n radius: 1000,\n elevationScale: 1,\n coverage: 1,\n extruded: false,\n upperPercentile: 100,\n lowerPercentile: 0,\n elevationUpperPercentile: 100,\n elevationLowerPercentile: 0,\n colorScaleType: 'quantize',\n colorAggregation: 'SUM',\n elevationAggregation: 'SUM',\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new HexagonLayer({\n id: props.id,\n data: props.data,\n getPosition: props.getPosition,\n getColorWeight: props.getColorWeight ?? (() => 1),\n getElevationWeight: props.getElevationWeight ?? (() => 1),\n gpuAggregation: props.gpuAggregation,\n radius: props.radius,\n elevationScale: props.elevationScale,\n elevationRange: props.elevationRange,\n colorRange: props.colorRange,\n colorDomain: props.colorDomain,\n coverage: props.coverage,\n extruded: props.extruded,\n upperPercentile: props.upperPercentile,\n lowerPercentile: props.lowerPercentile,\n elevationUpperPercentile: props.elevationUpperPercentile,\n elevationLowerPercentile: props.elevationLowerPercentile,\n colorScaleType: props.colorScaleType,\n material: props.material,\n colorAggregation: props.colorAggregation,\n elevationAggregation: props.elevationAggregation,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as unknown as ConstructorParameters<typeof HexagonLayer>[0]);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getPosition,\n props.radius,\n props.elevationScale,\n props.opacity,\n props.visible,\n props.extruded,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"6/BAkDE,IAAM,EAAQ,EAmBR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAa,CACtB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,YAAa,EAAM,YACnB,eAAgB,EAAM,qBAAyB,GAC/C,mBAAoB,EAAM,yBAA6B,GACvD,eAAgB,EAAM,eACtB,OAAQ,EAAM,OACd,eAAgB,EAAM,eACtB,eAAgB,EAAM,eACtB,WAAY,EAAM,WAClB,YAAa,EAAM,YACnB,SAAU,EAAM,SAChB,SAAU,EAAM,SAChB,gBAAiB,EAAM,gBACvB,gBAAiB,EAAM,gBACvB,yBAA0B,EAAM,yBAChC,yBAA0B,EAAM,yBAChC,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,iBAAkB,EAAM,iBACxB,qBAAsB,EAAM,qBAC5B,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAA6D,EAGzD,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,OACN,EAAM,eACN,EAAM,QACN,EAAM,QACN,EAAM,QACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,t}from"./symbols-DXKzIgbY.js";import{i as n}from"./useDeckOverlay-CI56uIKH.js";import{defineComponent as r,onBeforeUnmount as i,renderSlot as a,watch as o}from"vue";import{IconLayer as s}from"@deck.gl/layers";const c=r({__name:`VLayerDeckglIcon`,props:{id:{},data:{},getPosition:{},getIcon:{},getSize:{},getColor:{},getAngle:{},iconAtlas:{},iconMapping:{},sizeScale:{default:1},sizeUnits:{default:`pixels`},sizeMinPixels:{default:0},sizeMaxPixels:{default:2**53-1},billboard:{type:Boolean,default:!0},alphaCutoff:{default:.05},opacity:{default:1},visible:{type:Boolean,default:!0},pickable:{type:Boolean,default:!0},autoHighlight:{type:Boolean,default:!1},highlightColor:{},beforeId:{}},emits:[`click`,`hover`],setup(r,{emit:c}){let l=r,u=c,d=e(t),{addLayer:f,removeLayer:p,updateLayer:m}=n(d),h=()=>new s({id:l.id,data:l.data,getPosition:l.getPosition,getIcon:l.getIcon??`marker`,getSize:l.getSize??1,getColor:l.getColor??[255,255,255,255],getAngle:l.getAngle??0,iconAtlas:l.iconAtlas,iconMapping:l.iconMapping,sizeScale:l.sizeScale,sizeUnits:l.sizeUnits,sizeMinPixels:l.sizeMinPixels,sizeMaxPixels:l.sizeMaxPixels,billboard:l.billboard,alphaCutoff:l.alphaCutoff,opacity:l.opacity,visible:l.visible,pickable:l.pickable,autoHighlight:l.autoHighlight,highlightColor:l.highlightColor,beforeId:l.beforeId,onClick:e=>u(`click`,e),onHover:e=>u(`hover`,e)}),g=()=>{f(h())};return o(d,e=>{e&&g()},{immediate:!0}),o(()=>[l.data,l.getPosition,l.getIcon,l.getSize,l.getColor,l.opacity,l.visible],()=>m(l.id,h()),{deep:!0}),i(()=>{p(l.id)}),(e,t)=>a(e.$slots,`default`)}});export{c as VLayerDeckglIcon};
|
|
2
|
+
//# sourceMappingURL=icon-Dm1fyRNM.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"icon-Dm1fyRNM.js","names":[],"sources":["../src/layers/deckgl/icon/VLayerDeckglIcon.vue"],"sourcesContent":["<script setup lang=\"ts\">\n /**\n * Sprite-sheet icon layer for many marker-like points (cheaper than DOM markers).\n *\n * @requires `@deck.gl/core`\n * @requires `@deck.gl/mapbox`\n * @requires `@deck.gl/layers`\n *\n * Install with:\n * `pnpm add @deck.gl/core @deck.gl/mapbox @deck.gl/layers`\n */\n import { onBeforeUnmount, watch } from 'vue';\n import { IconLayer } from '@deck.gl/layers';\n import type { IconLayerProps } from '@deck.gl/layers';\n import type { PickingInfo, Position } from '@deck.gl/core';\n import { injectStrict, MapKey } from '../../../utils';\n import { useDeckOverlay } from '../_shared/useDeckOverlay';\n import type { Color } from '../_shared/types';\n\n type Accessor<In, Out> = Out | ((object: In) => Out);\n\n interface IconMapping {\n [key: string]: {\n x: number;\n y: number;\n width: number;\n height: number;\n anchorX?: number;\n anchorY?: number;\n mask?: boolean;\n };\n }\n\n interface Props<D = unknown> {\n id: string;\n data: D[] | string | Promise<D[]>;\n getPosition: Accessor<D, Position>;\n getIcon?: Accessor<D, string | object>;\n getSize?: Accessor<D, number>;\n getColor?: Accessor<D, Color>;\n getAngle?: Accessor<D, number>;\n iconAtlas?: string;\n iconMapping?: IconMapping | string;\n sizeScale?: number;\n sizeUnits?: 'meters' | 'common' | 'pixels';\n sizeMinPixels?: number;\n sizeMaxPixels?: number;\n billboard?: boolean;\n alphaCutoff?: number;\n opacity?: number;\n visible?: boolean;\n pickable?: boolean;\n autoHighlight?: boolean;\n highlightColor?: Color;\n beforeId?: string;\n }\n\n const props = withDefaults(defineProps<Props>(), {\n sizeScale: 1,\n sizeUnits: 'pixels',\n sizeMinPixels: 0,\n sizeMaxPixels: Number.MAX_SAFE_INTEGER,\n billboard: true,\n alphaCutoff: 0.05,\n opacity: 1,\n visible: true,\n pickable: true,\n autoHighlight: false,\n });\n\n const emit = defineEmits<{\n click: [info: PickingInfo];\n hover: [info: PickingInfo];\n }>();\n\n const map = injectStrict(MapKey);\n const { addLayer, removeLayer, updateLayer } = useDeckOverlay(map);\n\n const createLayer = () => {\n return new IconLayer({\n id: props.id,\n data: props.data,\n getPosition: props.getPosition,\n getIcon: props.getIcon ?? 'marker',\n getSize: props.getSize ?? 1,\n getColor: props.getColor ?? [255, 255, 255, 255],\n getAngle: props.getAngle ?? 0,\n iconAtlas: props.iconAtlas,\n iconMapping: props.iconMapping,\n sizeScale: props.sizeScale,\n sizeUnits: props.sizeUnits,\n sizeMinPixels: props.sizeMinPixels,\n sizeMaxPixels: props.sizeMaxPixels,\n billboard: props.billboard,\n alphaCutoff: props.alphaCutoff,\n opacity: props.opacity,\n visible: props.visible,\n pickable: props.pickable,\n autoHighlight: props.autoHighlight,\n highlightColor: props.highlightColor,\n beforeId: props.beforeId,\n onClick: (info: PickingInfo) => emit('click', info),\n onHover: (info: PickingInfo) => emit('hover', info),\n } as IconLayerProps);\n };\n\n const initializeLayer = () => {\n addLayer(createLayer());\n };\n\n watch(\n map,\n (mapInstance) => {\n if (!mapInstance) return;\n // Register unconditionally once the map exists. addLayer() routes through\n // useDeckOverlay's initOverlay(), which robustly waits for style.load via\n // its own once-listener + polling. Gating here on isStyleLoaded() was racy:\n // if style.load already fired before this watch ran, the one-shot\n // .once('style.load') never fired and the layer was never registered.\n initializeLayer();\n },\n { immediate: true },\n );\n\n watch(\n () => [\n props.data,\n props.getPosition,\n props.getIcon,\n props.getSize,\n props.getColor,\n props.opacity,\n props.visible,\n ],\n () => updateLayer(props.id, createLayer()),\n { deep: true },\n );\n\n onBeforeUnmount(() => {\n removeLayer(props.id);\n });\n</script>\n\n<template>\n <slot></slot>\n</template>\n"],"mappings":"uuBAyDE,IAAM,EAAQ,EAaR,EAAO,EAKP,EAAM,EAAa,CAAM,EACzB,CAAE,WAAU,cAAa,eAAgB,EAAe,CAAG,EAE3D,MACG,IAAI,EAAU,CACnB,GAAI,EAAM,GACV,KAAM,EAAM,KACZ,YAAa,EAAM,YACnB,QAAS,EAAM,SAAW,SAC1B,QAAS,EAAM,SAAW,EAC1B,SAAU,EAAM,UAAY,CAAC,IAAK,IAAK,IAAK,GAAG,EAC/C,SAAU,EAAM,UAAY,EAC5B,UAAW,EAAM,UACjB,YAAa,EAAM,YACnB,UAAW,EAAM,UACjB,UAAW,EAAM,UACjB,cAAe,EAAM,cACrB,cAAe,EAAM,cACrB,UAAW,EAAM,UACjB,YAAa,EAAM,YACnB,QAAS,EAAM,QACf,QAAS,EAAM,QACf,SAAU,EAAM,SAChB,cAAe,EAAM,cACrB,eAAgB,EAAM,eACtB,SAAU,EAAM,SAChB,QAAU,GAAsB,EAAK,QAAS,CAAI,EAClD,QAAU,GAAsB,EAAK,QAAS,CAAI,CACpD,CAAmB,EAGf,MAAwB,CAC5B,EAAS,EAAY,CAAC,CACxB,SAEA,EACE,EACC,GAAgB,CACV,GAML,EAAgB,CAClB,EACA,CAAE,UAAW,EAAK,CACpB,EAEA,MACQ,CACJ,EAAM,KACN,EAAM,YACN,EAAM,QACN,EAAM,QACN,EAAM,SACN,EAAM,QACN,EAAM,OACR,MACM,EAAY,EAAM,GAAI,EAAY,CAAC,EACzC,CAAE,KAAM,EAAK,CACf,EAEA,MAAsB,CACpB,EAAY,EAAM,EAAE,CACtB,CAAC,SAID,EAAa,EAAA,OAAA,SAAA"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { Ref } from "vue";
|
|
2
|
+
import { Map } from "maplibre-gl";
|
|
3
|
+
|
|
4
|
+
//#region src/layers/deckgl/_shared/types.d.ts
|
|
5
|
+
type Color = [number, number, number] | [number, number, number, number];
|
|
6
|
+
type Position = [number, number] | [number, number, number];
|
|
7
|
+
type Accessor<In, Out> = Out | ((object: In, objectInfo?: {
|
|
8
|
+
index: number;
|
|
9
|
+
data: unknown;
|
|
10
|
+
target: number[];
|
|
11
|
+
}) => Out);
|
|
12
|
+
type ColorAccessor<D> = Accessor<D, Color>;
|
|
13
|
+
type NumberAccessor<D> = Accessor<D, number>;
|
|
14
|
+
type PositionAccessor<D> = Accessor<D, Position>;
|
|
15
|
+
type StringAccessor<D> = Accessor<D, string>;
|
|
16
|
+
interface BaseDeckLayerProps {
|
|
17
|
+
id: string;
|
|
18
|
+
visible?: boolean;
|
|
19
|
+
opacity?: number;
|
|
20
|
+
pickable?: boolean;
|
|
21
|
+
autoHighlight?: boolean;
|
|
22
|
+
highlightColor?: Color;
|
|
23
|
+
beforeId?: string;
|
|
24
|
+
}
|
|
25
|
+
interface DeckLayerEvent<D = unknown> {
|
|
26
|
+
object?: D;
|
|
27
|
+
index: number;
|
|
28
|
+
x: number;
|
|
29
|
+
y: number;
|
|
30
|
+
coordinate?: [number, number];
|
|
31
|
+
layer?: unknown;
|
|
32
|
+
viewport?: unknown;
|
|
33
|
+
}
|
|
34
|
+
type ArrowTableLike = import('apache-arrow').Table | import('apache-arrow').RecordBatch;
|
|
35
|
+
//#endregion
|
|
36
|
+
export { ColorAccessor as a, Position as c, Color as i, PositionAccessor as l, ArrowTableLike as n, DeckLayerEvent as o, BaseDeckLayerProps as r, NumberAccessor as s, Accessor as t, StringAccessor as u };
|
|
37
|
+
//# sourceMappingURL=index-2D1oVTKr.d.ts.map
|