@accelint/map-toolkit 0.5.0 → 1.0.0
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/CHANGELOG.md +82 -0
- package/catalog-info.yaml +6 -3
- package/dist/camera/index.d.ts +2 -2
- package/dist/camera/index.js +2 -2
- package/dist/camera/store.d.ts +120 -0
- package/dist/camera/store.js +279 -0
- package/dist/camera/store.js.map +1 -0
- package/dist/deckgl/base-map/constants.d.ts +9 -7
- package/dist/deckgl/base-map/constants.js +9 -7
- package/dist/deckgl/base-map/constants.js.map +1 -1
- package/dist/deckgl/base-map/controls.js +2 -0
- package/dist/deckgl/base-map/controls.js.map +1 -1
- package/dist/deckgl/base-map/index.d.ts +2 -0
- package/dist/deckgl/base-map/index.js +14 -16
- package/dist/deckgl/base-map/index.js.map +1 -1
- package/dist/deckgl/base-map/provider.js +1 -1
- package/dist/deckgl/base-map/types.d.ts +6 -1
- package/dist/deckgl/index.d.ts +8 -2
- package/dist/deckgl/index.js +6 -2
- package/dist/deckgl/saved-viewports/index.d.ts +1 -1
- package/dist/deckgl/saved-viewports/index.js +1 -2
- package/dist/deckgl/saved-viewports/index.js.map +1 -1
- package/dist/deckgl/saved-viewports/storage.js +10 -2
- package/dist/deckgl/saved-viewports/storage.js.map +1 -1
- package/dist/deckgl/shapes/display-shape-layer/constants.js +58 -0
- package/dist/deckgl/shapes/display-shape-layer/constants.js.map +1 -0
- package/dist/{node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/assert.js → deckgl/shapes/display-shape-layer/fiber.d.ts} +11 -7
- package/dist/{packages/hotkey-manager/dist/lib/is-client/index.js → deckgl/shapes/display-shape-layer/fiber.js} +6 -7
- package/dist/deckgl/shapes/display-shape-layer/fiber.js.map +1 -0
- package/dist/deckgl/shapes/display-shape-layer/index.d.ts +210 -0
- package/dist/deckgl/shapes/display-shape-layer/index.js +449 -0
- package/dist/deckgl/shapes/display-shape-layer/index.js.map +1 -0
- package/dist/deckgl/shapes/display-shape-layer/shape-label-layer.js +102 -0
- package/dist/deckgl/shapes/display-shape-layer/shape-label-layer.js.map +1 -0
- package/dist/deckgl/shapes/display-shape-layer/store.js +102 -0
- package/dist/deckgl/shapes/display-shape-layer/store.js.map +1 -0
- package/dist/deckgl/shapes/display-shape-layer/types.d.ts +126 -0
- package/dist/{node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/layer.js → deckgl/shapes/display-shape-layer/types.js} +0 -3
- package/dist/deckgl/shapes/display-shape-layer/use-select-shape.d.ts +89 -0
- package/dist/deckgl/shapes/display-shape-layer/use-select-shape.js +88 -0
- package/dist/deckgl/shapes/display-shape-layer/use-select-shape.js.map +1 -0
- package/dist/deckgl/shapes/display-shape-layer/utils/display-style.js +50 -0
- package/dist/deckgl/shapes/display-shape-layer/utils/display-style.js.map +1 -0
- package/dist/deckgl/shapes/display-shape-layer/utils/labels.d.ts +133 -0
- package/dist/deckgl/shapes/display-shape-layer/utils/labels.js +250 -0
- package/dist/deckgl/shapes/display-shape-layer/utils/labels.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/constants.js +46 -0
- package/dist/deckgl/shapes/draw-shape-layer/constants.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/events.d.ts +92 -0
- package/dist/deckgl/shapes/draw-shape-layer/events.js +56 -0
- package/dist/deckgl/shapes/draw-shape-layer/events.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/fiber.d.ts +11 -0
- package/dist/{node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/get-bounds.js → deckgl/shapes/draw-shape-layer/fiber.js} +5 -4
- package/dist/deckgl/shapes/draw-shape-layer/fiber.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/index.d.ts +53 -0
- package/dist/deckgl/shapes/draw-shape-layer/index.js +95 -0
- package/dist/deckgl/shapes/draw-shape-layer/index.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-circle-mode-with-tooltip.js +51 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-circle-mode-with-tooltip.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-ellipse-mode-with-tooltip.js +73 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-ellipse-mode-with-tooltip.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-line-string-mode-with-tooltip.js +87 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-line-string-mode-with-tooltip.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-polygon-mode-with-tooltip.js +88 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-polygon-mode-with-tooltip.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-rectangle-mode-with-tooltip.js +77 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/draw-rectangle-mode-with-tooltip.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/index.js +64 -0
- package/dist/deckgl/shapes/draw-shape-layer/modes/index.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/store.js +175 -0
- package/dist/deckgl/shapes/draw-shape-layer/store.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/types.d.ts +86 -0
- package/dist/{node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/fly-to-viewport.js → deckgl/shapes/draw-shape-layer/types.js} +1 -1
- package/dist/deckgl/shapes/draw-shape-layer/use-draw-shape.d.ts +82 -0
- package/dist/deckgl/shapes/draw-shape-layer/use-draw-shape.js +112 -0
- package/dist/deckgl/shapes/draw-shape-layer/use-draw-shape.js.map +1 -0
- package/dist/deckgl/shapes/draw-shape-layer/utils/feature-conversion.js +147 -0
- package/dist/deckgl/shapes/draw-shape-layer/utils/feature-conversion.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/constants.js +41 -0
- package/dist/deckgl/shapes/edit-shape-layer/constants.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/events.d.ts +92 -0
- package/dist/deckgl/shapes/edit-shape-layer/events.js +56 -0
- package/dist/deckgl/shapes/edit-shape-layer/events.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/fiber.d.ts +13 -0
- package/dist/{node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/web-mercator-viewport.js → deckgl/shapes/edit-shape-layer/fiber.js} +1 -3
- package/dist/deckgl/shapes/edit-shape-layer/index.d.ts +63 -0
- package/dist/deckgl/shapes/edit-shape-layer/index.js +162 -0
- package/dist/deckgl/shapes/edit-shape-layer/index.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/base-transform-mode.js +154 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/base-transform-mode.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/bounding-transform-mode.js +147 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/bounding-transform-mode.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/circle-transform-mode.js +87 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/circle-transform-mode.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/index.js +61 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/index.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/rotate-mode-with-snap.js +109 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/rotate-mode-with-snap.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/scale-mode-with-free-transform.js +289 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/scale-mode-with-free-transform.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/vertex-transform-mode.js +121 -0
- package/dist/deckgl/shapes/edit-shape-layer/modes/vertex-transform-mode.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/store.js +194 -0
- package/dist/deckgl/shapes/edit-shape-layer/store.js.map +1 -0
- package/dist/deckgl/shapes/edit-shape-layer/types.d.ts +93 -0
- package/dist/{node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/normalize-viewport-props.js → deckgl/shapes/edit-shape-layer/types.js} +1 -1
- package/dist/deckgl/shapes/edit-shape-layer/use-edit-shape.d.ts +82 -0
- package/dist/deckgl/shapes/edit-shape-layer/use-edit-shape.js +114 -0
- package/dist/deckgl/shapes/edit-shape-layer/use-edit-shape.js.map +1 -0
- package/dist/deckgl/shapes/index.d.ts +29 -0
- package/dist/deckgl/shapes/index.js +27 -0
- package/dist/deckgl/shapes/shared/constants.d.ts +73 -0
- package/dist/deckgl/shapes/shared/constants.js +273 -0
- package/dist/deckgl/shapes/shared/constants.js.map +1 -0
- package/dist/deckgl/shapes/shared/events.d.ts +54 -0
- package/dist/{packages/hotkey-manager/dist/lib/is-mac/index.js → deckgl/shapes/shared/events.js} +10 -6
- package/dist/deckgl/shapes/shared/events.js.map +1 -0
- package/dist/deckgl/shapes/shared/hooks/use-shift-zoom-disable.js +84 -0
- package/dist/deckgl/shapes/shared/hooks/use-shift-zoom-disable.js.map +1 -0
- package/dist/deckgl/shapes/shared/types.d.ts +317 -0
- package/dist/deckgl/shapes/shared/types.js +83 -0
- package/dist/deckgl/shapes/shared/types.js.map +1 -0
- package/dist/deckgl/shapes/shared/utils/geometry-measurements.js +128 -0
- package/dist/deckgl/shapes/shared/utils/geometry-measurements.js.map +1 -0
- package/dist/deckgl/shapes/shared/utils/layer-config.js +50 -0
- package/dist/deckgl/shapes/shared/utils/layer-config.js.map +1 -0
- package/dist/deckgl/shapes/shared/utils/mode-utils.js +113 -0
- package/dist/deckgl/shapes/shared/utils/mode-utils.js.map +1 -0
- package/dist/deckgl/shapes/shared/utils/pick-filtering.js +57 -0
- package/dist/deckgl/shapes/shared/utils/pick-filtering.js.map +1 -0
- package/dist/deckgl/shapes/shared/utils/style-utils.d.ts +64 -0
- package/dist/deckgl/shapes/shared/utils/style-utils.js +101 -0
- package/dist/deckgl/shapes/shared/utils/style-utils.js.map +1 -0
- package/dist/deckgl/symbol-layer/index.d.ts +1 -1
- package/dist/deckgl/text-layer/default-settings.js +4 -24
- package/dist/deckgl/text-layer/default-settings.js.map +1 -1
- package/dist/deckgl/text-settings.d.ts +77 -0
- package/dist/deckgl/text-settings.js +83 -0
- package/dist/deckgl/text-settings.js.map +1 -0
- package/dist/map-cursor/index.d.ts +2 -2
- package/dist/map-cursor/index.js +2 -2
- package/dist/map-cursor/store.d.ts +32 -61
- package/dist/map-cursor/store.js +165 -294
- package/dist/map-cursor/store.js.map +1 -1
- package/dist/map-cursor/use-map-cursor.d.ts +5 -2
- package/dist/map-cursor/use-map-cursor.js +33 -15
- package/dist/map-cursor/use-map-cursor.js.map +1 -1
- package/dist/map-mode/index.d.ts +2 -2
- package/dist/map-mode/index.js +2 -2
- package/dist/map-mode/store.d.ts +36 -37
- package/dist/map-mode/store.js +131 -237
- package/dist/map-mode/store.js.map +1 -1
- package/dist/map-mode/use-map-mode.js +6 -5
- package/dist/map-mode/use-map-mode.js.map +1 -1
- package/dist/maplibre/index.d.ts +2 -2
- package/dist/maplibre/index.js +2 -2
- package/dist/shared/constants.d.ts +19 -0
- package/dist/{maplibre → shared}/constants.js +9 -3
- package/dist/shared/constants.js.map +1 -0
- package/dist/shared/create-map-store.d.ts +202 -0
- package/dist/shared/create-map-store.js +223 -0
- package/dist/shared/create-map-store.js.map +1 -0
- package/dist/shared/units.d.ts +39 -0
- package/dist/shared/units.js +49 -0
- package/dist/shared/units.js.map +1 -0
- package/dist/viewport/index.d.ts +3 -3
- package/dist/viewport/index.js +3 -3
- package/dist/viewport/store.d.ts +69 -0
- package/dist/viewport/store.js +125 -0
- package/dist/viewport/store.js.map +1 -0
- package/dist/viewport/types.d.ts +2 -2
- package/dist/viewport/utils.js +2 -2
- package/dist/viewport/utils.js.map +1 -1
- package/dist/viewport/viewport-size.js +2 -2
- package/dist/viewport/viewport-size.js.map +1 -1
- package/package.json +60 -26
- package/dist/_virtual/rolldown_runtime.js +0 -22
- package/dist/camera/use-camera-state.d.ts +0 -153
- package/dist/camera/use-camera-state.js +0 -419
- package/dist/camera/use-camera-state.js.map +0 -1
- package/dist/decorators/deckgl.d.ts +0 -19
- package/dist/decorators/deckgl.js +0 -32
- package/dist/decorators/deckgl.js.map +0 -1
- package/dist/maplibre/constants.d.ts +0 -13
- package/dist/maplibre/constants.js.map +0 -1
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/assert.js.map +0 -1
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/fit-bounds.js +0 -63
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/fit-bounds.js.map +0 -1
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/get-bounds.js.map +0 -1
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/index.js +0 -19
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/math-utils.js +0 -25
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/math-utils.js.map +0 -1
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/web-mercator-utils.js +0 -59
- package/dist/node_modules/.pnpm/@math.gl_web-mercator@4.1.0/node_modules/@math.gl/web-mercator/dist/web-mercator-utils.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/attribution-control.js +0 -29
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/attribution-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/fullscreen-control.js +0 -29
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/fullscreen-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/geolocate-control.js +0 -54
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/geolocate-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/logo-control.js +0 -29
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/logo-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/map.js +0 -91
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/map.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/marker.js +0 -88
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/marker.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/navigation-control.js +0 -29
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/navigation-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/popup.js +0 -69
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/popup.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/scale-control.js +0 -35
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/scale-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/source.js +0 -15
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/terrain-control.js +0 -29
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/terrain-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/use-control.js +0 -40
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/use-control.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/use-map.js +0 -23
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/components/use-map.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/index.js +0 -27
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/maplibre/create-ref.js +0 -57
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/maplibre/create-ref.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/maplibre/maplibre.js +0 -343
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/maplibre/maplibre.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/apply-react-style.js +0 -28
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/apply-react-style.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/compare-class-names.js +0 -31
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/compare-class-names.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/deep-equal.js +0 -57
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/deep-equal.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/set-globals.js +0 -30
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/set-globals.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/style-utils.js +0 -53
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/style-utils.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/transform.js +0 -52
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/transform.js.map +0 -1
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/use-isomorphic-layout-effect.js +0 -22
- package/dist/node_modules/.pnpm/@vis.gl_react-maplibre@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/@vis.gl/react-maplibre/dist/utils/use-isomorphic-layout-effect.js.map +0 -1
- package/dist/node_modules/.pnpm/immer@10.2.0/node_modules/immer/dist/immer.js +0 -812
- package/dist/node_modules/.pnpm/immer@10.2.0/node_modules/immer/dist/immer.js.map +0 -1
- package/dist/node_modules/.pnpm/radashi@12.7.1/node_modules/radashi/dist/radashi.js +0 -35
- package/dist/node_modules/.pnpm/radashi@12.7.1/node_modules/radashi/dist/radashi.js.map +0 -1
- package/dist/node_modules/.pnpm/react-dom@19.2.3_react@19.2.3/node_modules/react-dom/cjs/react-dom.development.js +0 -195
- package/dist/node_modules/.pnpm/react-dom@19.2.3_react@19.2.3/node_modules/react-dom/cjs/react-dom.development.js.map +0 -1
- package/dist/node_modules/.pnpm/react-dom@19.2.3_react@19.2.3/node_modules/react-dom/cjs/react-dom.production.js +0 -76
- package/dist/node_modules/.pnpm/react-dom@19.2.3_react@19.2.3/node_modules/react-dom/cjs/react-dom.production.js.map +0 -1
- package/dist/node_modules/.pnpm/react-dom@19.2.3_react@19.2.3/node_modules/react-dom/index.js +0 -39
- package/dist/node_modules/.pnpm/react-dom@19.2.3_react@19.2.3/node_modules/react-dom/index.js.map +0 -1
- package/dist/node_modules/.pnpm/react-map-gl@8.1.0_maplibre-gl@5.15.0_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/react-map-gl/dist/maplibre.js +0 -16
- package/dist/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_immer@10.2.0_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/middleware/immer.js +0 -27
- package/dist/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_immer@10.2.0_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/middleware/immer.js.map +0 -1
- package/dist/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_immer@10.2.0_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/vanilla.js +0 -45
- package/dist/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_immer@10.2.0_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/vanilla.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/actions/register-hotkey/index.js +0 -78
- package/dist/packages/hotkey-manager/dist/actions/register-hotkey/index.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/constants.js +0 -47
- package/dist/packages/hotkey-manager/dist/constants.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/enums/keycode.js +0 -130
- package/dist/packages/hotkey-manager/dist/enums/keycode.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/lib/is-client/index.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/lib/is-mac/index.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/lib/key-to-id/index.js +0 -39
- package/dist/packages/hotkey-manager/dist/lib/key-to-id/index.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/lib/key-to-string/index.js +0 -27
- package/dist/packages/hotkey-manager/dist/lib/key-to-string/index.js.map +0 -1
- package/dist/packages/hotkey-manager/dist/stores/hotkey-store/index.js +0 -95
- package/dist/packages/hotkey-manager/dist/stores/hotkey-store/index.js.map +0 -1
- package/dist/viewport/constants.d.ts +0 -11
- package/dist/viewport/constants.js +0 -25
- package/dist/viewport/constants.js.map +0 -1
- package/dist/viewport/use-viewport-state.d.ts +0 -100
- package/dist/viewport/use-viewport-state.js +0 -222
- package/dist/viewport/use-viewport-state.js.map +0 -1
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.
|
|
3
|
+
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
* you may not use this file except in compliance with the License. You may obtain a copy
|
|
5
|
+
* of the License at https://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
+
*
|
|
7
|
+
* Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
+
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
+
* OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
+
* governing permissions and limitations under the License.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
import { MapStore } from "../shared/create-map-store.js";
|
|
14
|
+
import { MapViewportPayload } from "../deckgl/base-map/types.js";
|
|
15
|
+
import { UniqueId } from "@accelint/core";
|
|
16
|
+
|
|
17
|
+
//#region src/viewport/store.d.ts
|
|
18
|
+
/**
|
|
19
|
+
* State shape for viewport - mirrors MapViewportPayload but with
|
|
20
|
+
* a placeholder id that gets replaced per-instance
|
|
21
|
+
*/
|
|
22
|
+
type ViewportState = MapViewportPayload;
|
|
23
|
+
/**
|
|
24
|
+
* No actions needed - viewport state is read-only from bus events
|
|
25
|
+
*/
|
|
26
|
+
type ViewportActions = Record<string, never>;
|
|
27
|
+
/**
|
|
28
|
+
* Viewport store instance.
|
|
29
|
+
*
|
|
30
|
+
* Note: The defaultState uses a placeholder id that gets replaced
|
|
31
|
+
* when instances are created. The actual id comes from the bus event payload.
|
|
32
|
+
*/
|
|
33
|
+
declare const viewportStore: MapStore<MapViewportPayload, ViewportActions>;
|
|
34
|
+
/**
|
|
35
|
+
* Hook to subscribe to viewport state changes for a specific map.
|
|
36
|
+
*
|
|
37
|
+
* @param mapId - Unique identifier for the map instance
|
|
38
|
+
* @returns Current viewport state including bounds, latitude, longitude, zoom, width, height
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```tsx
|
|
42
|
+
* function MapInfo({ mapId }) {
|
|
43
|
+
* const viewport = useMapViewport(mapId);
|
|
44
|
+
* return (
|
|
45
|
+
* <div>
|
|
46
|
+
* Lat: {viewport.latitude?.toFixed(2)}, Lon: {viewport.longitude?.toFixed(2)}, Zoom: {viewport.zoom}
|
|
47
|
+
* </div>
|
|
48
|
+
* );
|
|
49
|
+
* }
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
52
|
+
declare function useMapViewport(mapId: UniqueId): ViewportState;
|
|
53
|
+
/**
|
|
54
|
+
* Get current viewport state (non-reactive, for imperative code).
|
|
55
|
+
*
|
|
56
|
+
* @param mapId - Unique identifier for the map instance
|
|
57
|
+
* @returns Current viewport state
|
|
58
|
+
*/
|
|
59
|
+
declare function getViewport(mapId: UniqueId): ViewportState;
|
|
60
|
+
/**
|
|
61
|
+
* Manually clear viewport state for a specific map instance.
|
|
62
|
+
* This is typically not needed as cleanup happens automatically when all subscribers unmount.
|
|
63
|
+
*
|
|
64
|
+
* @param mapId - The unique identifier for the map instance to clear
|
|
65
|
+
*/
|
|
66
|
+
declare function clearViewportState(mapId: UniqueId): void;
|
|
67
|
+
//#endregion
|
|
68
|
+
export { clearViewportState, getViewport, useMapViewport, viewportStore };
|
|
69
|
+
//# sourceMappingURL=store.d.ts.map
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.
|
|
3
|
+
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
* you may not use this file except in compliance with the License. You may obtain a copy
|
|
5
|
+
* of the License at https://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
+
*
|
|
7
|
+
* Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
+
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
+
* OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
+
* governing permissions and limitations under the License.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
import { createMapStore } from "../shared/create-map-store.js";
|
|
15
|
+
import { MapEvents } from "../deckgl/base-map/events.js";
|
|
16
|
+
import { Broadcast } from "@accelint/bus";
|
|
17
|
+
|
|
18
|
+
//#region src/viewport/store.ts
|
|
19
|
+
/**
|
|
20
|
+
* Viewport Store
|
|
21
|
+
*
|
|
22
|
+
* Manages viewport state (bounds, lat/lon, zoom, dimensions) per map instance.
|
|
23
|
+
* State is updated automatically from MapEvents.viewport bus events.
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* ```tsx
|
|
27
|
+
* import { viewportStore } from '@accelint/map-toolkit/viewport';
|
|
28
|
+
*
|
|
29
|
+
* function MapInfo({ mapId }) {
|
|
30
|
+
* const { state } = viewportStore.use(mapId);
|
|
31
|
+
* return (
|
|
32
|
+
* <div>
|
|
33
|
+
* Lat: {state.latitude.toFixed(2)}, Lon: {state.longitude.toFixed(2)}
|
|
34
|
+
* </div>
|
|
35
|
+
* );
|
|
36
|
+
* }
|
|
37
|
+
* ```
|
|
38
|
+
*/
|
|
39
|
+
const bus = Broadcast.getInstance();
|
|
40
|
+
/**
|
|
41
|
+
* Create default state for a given mapId.
|
|
42
|
+
* Returns uninitialized values that indicate no viewport data yet.
|
|
43
|
+
*/
|
|
44
|
+
function createDefaultState(mapId) {
|
|
45
|
+
return {
|
|
46
|
+
id: mapId,
|
|
47
|
+
bounds: void 0,
|
|
48
|
+
latitude: NaN,
|
|
49
|
+
longitude: NaN,
|
|
50
|
+
zoom: NaN,
|
|
51
|
+
width: 0,
|
|
52
|
+
height: 0
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Viewport store instance.
|
|
57
|
+
*
|
|
58
|
+
* Note: The defaultState uses a placeholder id that gets replaced
|
|
59
|
+
* when instances are created. The actual id comes from the bus event payload.
|
|
60
|
+
*/
|
|
61
|
+
const viewportStore = createMapStore({
|
|
62
|
+
defaultState: {
|
|
63
|
+
id: "",
|
|
64
|
+
bounds: void 0,
|
|
65
|
+
latitude: NaN,
|
|
66
|
+
longitude: NaN,
|
|
67
|
+
zoom: NaN,
|
|
68
|
+
width: 0,
|
|
69
|
+
height: 0
|
|
70
|
+
},
|
|
71
|
+
actions: () => ({}),
|
|
72
|
+
bus: (mapId, { replace }) => {
|
|
73
|
+
return bus.on(MapEvents.viewport, ({ payload }) => {
|
|
74
|
+
if (payload.id === mapId) replace(payload);
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
/**
|
|
79
|
+
* Hook to subscribe to viewport state changes for a specific map.
|
|
80
|
+
*
|
|
81
|
+
* @param mapId - Unique identifier for the map instance
|
|
82
|
+
* @returns Current viewport state including bounds, latitude, longitude, zoom, width, height
|
|
83
|
+
*
|
|
84
|
+
* @example
|
|
85
|
+
* ```tsx
|
|
86
|
+
* function MapInfo({ mapId }) {
|
|
87
|
+
* const viewport = useMapViewport(mapId);
|
|
88
|
+
* return (
|
|
89
|
+
* <div>
|
|
90
|
+
* Lat: {viewport.latitude?.toFixed(2)}, Lon: {viewport.longitude?.toFixed(2)}, Zoom: {viewport.zoom}
|
|
91
|
+
* </div>
|
|
92
|
+
* );
|
|
93
|
+
* }
|
|
94
|
+
* ```
|
|
95
|
+
*/
|
|
96
|
+
function useMapViewport(mapId) {
|
|
97
|
+
return viewportStore.useSelector(mapId, (state) => {
|
|
98
|
+
if (state.id === "") return createDefaultState(mapId);
|
|
99
|
+
return state;
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Get current viewport state (non-reactive, for imperative code).
|
|
104
|
+
*
|
|
105
|
+
* @param mapId - Unique identifier for the map instance
|
|
106
|
+
* @returns Current viewport state
|
|
107
|
+
*/
|
|
108
|
+
function getViewport(mapId) {
|
|
109
|
+
const state = viewportStore.get(mapId);
|
|
110
|
+
if (state.id === "") return createDefaultState(mapId);
|
|
111
|
+
return state;
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Manually clear viewport state for a specific map instance.
|
|
115
|
+
* This is typically not needed as cleanup happens automatically when all subscribers unmount.
|
|
116
|
+
*
|
|
117
|
+
* @param mapId - The unique identifier for the map instance to clear
|
|
118
|
+
*/
|
|
119
|
+
function clearViewportState(mapId) {
|
|
120
|
+
viewportStore.clear(mapId);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
//#endregion
|
|
124
|
+
export { clearViewportState, getViewport, useMapViewport, viewportStore };
|
|
125
|
+
//# sourceMappingURL=store.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"store.js","names":[],"sources":["../../src/viewport/store.ts"],"sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n/**\n * Viewport Store\n *\n * Manages viewport state (bounds, lat/lon, zoom, dimensions) per map instance.\n * State is updated automatically from MapEvents.viewport bus events.\n *\n * @example\n * ```tsx\n * import { viewportStore } from '@accelint/map-toolkit/viewport';\n *\n * function MapInfo({ mapId }) {\n * const { state } = viewportStore.use(mapId);\n * return (\n * <div>\n * Lat: {state.latitude.toFixed(2)}, Lon: {state.longitude.toFixed(2)}\n * </div>\n * );\n * }\n * ```\n */\n\nimport { Broadcast } from '@accelint/bus';\nimport { createMapStore } from '../shared/create-map-store';\nimport { MapEvents } from '../deckgl/base-map/events';\nimport type { UniqueId } from '@accelint/core';\nimport type {\n MapEventType,\n MapViewportPayload,\n} from '../deckgl/base-map/types';\n\nconst bus = Broadcast.getInstance<MapEventType>();\n\n/**\n * State shape for viewport - mirrors MapViewportPayload but with\n * a placeholder id that gets replaced per-instance\n */\ntype ViewportState = MapViewportPayload;\n\n/**\n * No actions needed - viewport state is read-only from bus events\n */\ntype ViewportActions = Record<string, never>;\n\n/**\n * Create default state for a given mapId.\n * Returns uninitialized values that indicate no viewport data yet.\n */\nfunction createDefaultState(mapId: UniqueId): ViewportState {\n return {\n id: mapId,\n bounds: undefined,\n latitude: Number.NaN,\n longitude: Number.NaN,\n zoom: Number.NaN,\n width: 0,\n height: 0,\n };\n}\n\n/**\n * Viewport store instance.\n *\n * Note: The defaultState uses a placeholder id that gets replaced\n * when instances are created. The actual id comes from the bus event payload.\n */\nexport const viewportStore = createMapStore<ViewportState, ViewportActions>({\n // Placeholder default state - actual instances get proper id from bus events\n defaultState: {\n id: '' as UniqueId,\n bounds: undefined,\n latitude: Number.NaN,\n longitude: Number.NaN,\n zoom: Number.NaN,\n width: 0,\n height: 0,\n },\n\n // No actions - state is read-only from bus events\n actions: () => ({}) as ViewportActions,\n\n bus: (mapId, { replace }) => {\n const unsub = bus.on(MapEvents.viewport, ({ payload }) => {\n if (payload.id === mapId) {\n // Replace entire state with the new payload\n replace(payload);\n }\n });\n\n return unsub;\n },\n});\n\n// =============================================================================\n// Convenience exports\n// =============================================================================\n\n/**\n * Hook to subscribe to viewport state changes for a specific map.\n *\n * @param mapId - Unique identifier for the map instance\n * @returns Current viewport state including bounds, latitude, longitude, zoom, width, height\n *\n * @example\n * ```tsx\n * function MapInfo({ mapId }) {\n * const viewport = useMapViewport(mapId);\n * return (\n * <div>\n * Lat: {viewport.latitude?.toFixed(2)}, Lon: {viewport.longitude?.toFixed(2)}, Zoom: {viewport.zoom}\n * </div>\n * );\n * }\n * ```\n */\nexport function useMapViewport(mapId: UniqueId): ViewportState {\n return viewportStore.useSelector(mapId, (state) => {\n // Return proper default state with correct mapId if uninitialized\n if (state.id === '') {\n return createDefaultState(mapId);\n }\n return state;\n });\n}\n\n/**\n * Get current viewport state (non-reactive, for imperative code).\n *\n * @param mapId - Unique identifier for the map instance\n * @returns Current viewport state\n */\nexport function getViewport(mapId: UniqueId): ViewportState {\n const state = viewportStore.get(mapId);\n // Return proper default state with correct mapId if uninitialized\n if (state.id === '') {\n return createDefaultState(mapId);\n }\n return state;\n}\n\n/**\n * Manually clear viewport state for a specific map instance.\n * This is typically not needed as cleanup happens automatically when all subscribers unmount.\n *\n * @param mapId - The unique identifier for the map instance to clear\n */\nexport function clearViewportState(mapId: UniqueId): void {\n viewportStore.clear(mapId);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0CA,MAAM,MAAM,UAAU,aAA2B;;;;;AAiBjD,SAAS,mBAAmB,OAAgC;AAC1D,QAAO;EACL,IAAI;EACJ,QAAQ;EACR,UAAU;EACV,WAAW;EACX,MAAM;EACN,OAAO;EACP,QAAQ;EACT;;;;;;;;AASH,MAAa,gBAAgB,eAA+C;CAE1E,cAAc;EACZ,IAAI;EACJ,QAAQ;EACR,UAAU;EACV,WAAW;EACX,MAAM;EACN,OAAO;EACP,QAAQ;EACT;CAGD,gBAAgB,EAAE;CAElB,MAAM,OAAO,EAAE,cAAc;AAQ3B,SAPc,IAAI,GAAG,UAAU,WAAW,EAAE,cAAc;AACxD,OAAI,QAAQ,OAAO,MAEjB,SAAQ,QAAQ;IAElB;;CAIL,CAAC;;;;;;;;;;;;;;;;;;;AAwBF,SAAgB,eAAe,OAAgC;AAC7D,QAAO,cAAc,YAAY,QAAQ,UAAU;AAEjD,MAAI,MAAM,OAAO,GACf,QAAO,mBAAmB,MAAM;AAElC,SAAO;GACP;;;;;;;;AASJ,SAAgB,YAAY,OAAgC;CAC1D,MAAM,QAAQ,cAAc,IAAI,MAAM;AAEtC,KAAI,MAAM,OAAO,GACf,QAAO,mBAAmB,MAAM;AAElC,QAAO;;;;;;;;AAST,SAAgB,mBAAmB,OAAuB;AACxD,eAAc,MAAM,MAAM"}
|
package/dist/viewport/types.d.ts
CHANGED
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
import { Bounds } from "../deckgl/base-map/types.js";
|
|
14
|
-
import {
|
|
14
|
+
import { DistanceUnitAbbreviation } from "../shared/units.js";
|
|
15
15
|
|
|
16
16
|
//#region src/viewport/types.d.ts
|
|
17
|
-
type SupportedDistanceUnit =
|
|
17
|
+
type SupportedDistanceUnit = DistanceUnitAbbreviation;
|
|
18
18
|
type GetViewportSizeArgs = {
|
|
19
19
|
/** Geographic bounds, undefined if viewport not yet initialized */
|
|
20
20
|
bounds?: Bounds;
|
package/dist/viewport/utils.js
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
import {
|
|
14
|
+
import { getDistanceUnitFromAbbreviation } from "../shared/units.js";
|
|
15
15
|
|
|
16
16
|
//#region src/viewport/utils.ts
|
|
17
17
|
const numberFormatter = Intl.NumberFormat("en-US");
|
|
@@ -65,7 +65,7 @@ function getViewportSize({ bounds, zoom, width: pixelWidth, height: pixelHeight,
|
|
|
65
65
|
const metersPerPixel = METERS_PER_PIXEL_AT_ZOOM_0 * Math.cos(centerLat * Math.PI / 180) / 2 ** zoom;
|
|
66
66
|
const widthMeters = pixelWidth * metersPerPixel;
|
|
67
67
|
const heightMeters = pixelHeight * metersPerPixel;
|
|
68
|
-
const conversionFactor = METERS_TO_UNIT[
|
|
68
|
+
const conversionFactor = METERS_TO_UNIT[getDistanceUnitFromAbbreviation(unit)];
|
|
69
69
|
const widthDistance = Math.round(widthMeters * conversionFactor);
|
|
70
70
|
const heightDistance = Math.round(heightMeters * conversionFactor);
|
|
71
71
|
return `${formatter.format(widthDistance)} x ${formatter.format(heightDistance)} ${unit.toUpperCase()}`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","names":[],"sources":["../../src/viewport/utils.ts"],"sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {
|
|
1
|
+
{"version":3,"file":"utils.js","names":[],"sources":["../../src/viewport/utils.ts"],"sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n type DistanceUnit,\n getDistanceUnitFromAbbreviation,\n} from '../shared/units';\nimport type { GetViewportSizeArgs } from './types';\n\nconst numberFormatter = Intl.NumberFormat('en-US');\n\n/**\n * Web Mercator constant: meters per pixel at zoom 0, equator.\n * This is Earth's circumference (40075016.686m) divided by 256 (tile size).\n */\nconst METERS_PER_PIXEL_AT_ZOOM_0 = 156543.03392;\n\n/**\n * Unit conversion factors from meters.\n */\nconst METERS_TO_UNIT = {\n kilometers: 0.001,\n meters: 1,\n nauticalmiles: 0.000539957,\n miles: 0.000621371,\n feet: 3.28084,\n} as const;\n\n/**\n * Returns a formatted viewport size string i.e. `660 x 1,801 NM`\n *\n * Calculates the geographic distance of the viewport using zoom level and\n * pixel dimensions with the Web Mercator projection formula. This approach\n * provides stable results without the edge cases of bounds-based calculations.\n *\n * @param args - Viewport size calculation arguments\n * @param args.bounds - Geographic bounds [minLon, minLat, maxLon, maxLat]\n * @param args.zoom - Zoom level for meters-per-pixel calculation\n * @param args.width - Viewport width in pixels\n * @param args.height - Viewport height in pixels\n * @param args.unit - Unit of distance measurement: `km | m | nm | mi | ft`. Defaults to `nm`\n * @param args.formatter - Number formatter for localization (defaults to en-US)\n * @returns Formatted string like \"660 x 1,801 NM\" or \"-- x -- NM\" if invalid\n *\n * @example\n * ```typescript\n * getViewportSize({ bounds: [-82, 22, -71, 52], zoom: 5, width: 800, height: 600, unit: 'nm' })\n * // returns \"612 x 459 NM\"\n *\n * getViewportSize({ bounds: [170, 50, -170, 60], zoom: 4, width: 1024, height: 768, unit: 'km' })\n * // returns \"2,050 x 1,538 KM\"\n * ```\n */\nexport function getViewportSize({\n bounds,\n zoom,\n width: pixelWidth,\n height: pixelHeight,\n unit = 'nm',\n formatter = numberFormatter,\n}: GetViewportSizeArgs) {\n const defaultValue = `-- x -- ${unit.toUpperCase()}`;\n\n // Validate inputs\n if (!bounds || bounds.every((b) => Number.isNaN(b))) {\n return defaultValue;\n }\n\n if (Number.isNaN(zoom) || pixelWidth === 0 || pixelHeight === 0) {\n return defaultValue;\n }\n\n const [, minLat, , maxLat] = bounds;\n\n // Validate latitude bounds are within valid geographic ranges\n if (minLat < -90 || minLat > 90 || maxLat < -90 || maxLat > 90) {\n return defaultValue;\n }\n\n // Calculate center latitude for the viewport\n const centerLat = (minLat + maxLat) / 2;\n\n // Web Mercator formula: meters per pixel at given zoom and latitude\n // Resolution = 156543.03392 * cos(latitude * π/180) / 2^zoom\n const metersPerPixel =\n (METERS_PER_PIXEL_AT_ZOOM_0 * Math.cos((centerLat * Math.PI) / 180)) /\n 2 ** zoom;\n\n // Calculate distances in meters\n const widthMeters = pixelWidth * metersPerPixel;\n const heightMeters = pixelHeight * metersPerPixel;\n\n // Convert to requested unit\n const unitKey = getDistanceUnitFromAbbreviation(unit) as DistanceUnit;\n const conversionFactor = METERS_TO_UNIT[unitKey];\n\n const widthDistance = Math.round(widthMeters * conversionFactor);\n const heightDistance = Math.round(heightMeters * conversionFactor);\n\n const width = formatter.format(widthDistance);\n const height = formatter.format(heightDistance);\n\n return `${width} x ${height} ${unit.toUpperCase()}`;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAkBA,MAAM,kBAAkB,KAAK,aAAa,QAAQ;;;;;AAMlD,MAAM,6BAA6B;;;;AAKnC,MAAM,iBAAiB;CACrB,YAAY;CACZ,QAAQ;CACR,eAAe;CACf,OAAO;CACP,MAAM;CACP;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BD,SAAgB,gBAAgB,EAC9B,QACA,MACA,OAAO,YACP,QAAQ,aACR,OAAO,MACP,YAAY,mBACU;CACtB,MAAM,eAAe,WAAW,KAAK,aAAa;AAGlD,KAAI,CAAC,UAAU,OAAO,OAAO,MAAM,OAAO,MAAM,EAAE,CAAC,CACjD,QAAO;AAGT,KAAI,OAAO,MAAM,KAAK,IAAI,eAAe,KAAK,gBAAgB,EAC5D,QAAO;CAGT,MAAM,GAAG,UAAU,UAAU;AAG7B,KAAI,SAAS,OAAO,SAAS,MAAM,SAAS,OAAO,SAAS,GAC1D,QAAO;CAIT,MAAM,aAAa,SAAS,UAAU;CAItC,MAAM,iBACH,6BAA6B,KAAK,IAAK,YAAY,KAAK,KAAM,IAAI,GACnE,KAAK;CAGP,MAAM,cAAc,aAAa;CACjC,MAAM,eAAe,cAAc;CAInC,MAAM,mBAAmB,eADT,gCAAgC,KAAK;CAGrD,MAAM,gBAAgB,KAAK,MAAM,cAAc,iBAAiB;CAChE,MAAM,iBAAiB,KAAK,MAAM,eAAe,iBAAiB;AAKlE,QAAO,GAHO,UAAU,OAAO,cAAc,CAG7B,KAFD,UAAU,OAAO,eAAe,CAEnB,GAAG,KAAK,aAAa"}
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
import {
|
|
14
|
+
import { useMapViewport } from "./store.js";
|
|
15
15
|
import { getViewportSize } from "./utils.js";
|
|
16
16
|
import { jsx } from "react/jsx-runtime";
|
|
17
17
|
|
|
@@ -41,7 +41,7 @@ import { jsx } from "react/jsx-runtime";
|
|
|
41
41
|
* ```
|
|
42
42
|
*/
|
|
43
43
|
function ViewportSize({ instanceId, unit = "nm", ...rest }) {
|
|
44
|
-
const { bounds, zoom, width, height } =
|
|
44
|
+
const { bounds, zoom, width, height } = useMapViewport(instanceId);
|
|
45
45
|
return /* @__PURE__ */ jsx("span", {
|
|
46
46
|
...rest,
|
|
47
47
|
children: getViewportSize({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"viewport-size.js","names":[],"sources":["../../src/viewport/viewport-size.tsx"],"sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {
|
|
1
|
+
{"version":3,"file":"viewport-size.js","names":[],"sources":["../../src/viewport/viewport-size.tsx"],"sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { useMapViewport } from './store';\nimport { getViewportSize } from './utils';\nimport type { UniqueId } from '@accelint/core';\nimport type { ComponentPropsWithRef } from 'react';\nimport type { SupportedDistanceUnit } from './types';\n\nexport type ViewportSizeProps = ComponentPropsWithRef<'span'> & {\n instanceId: UniqueId;\n unit?: SupportedDistanceUnit;\n};\n\n/**\n * A span element displaying the current viewport bounds in the specified unit.\n *\n * Displays the viewport dimensions in a format like `660 x 1,801 NM`.\n * Updates automatically as the viewport changes by subscribing to viewport events.\n *\n * @param props - Extends `<span>` props\n * @param props.instanceId - The id of the view to subscribe to\n * @param props.unit - Measure of distance: `km | m | nm | mi | ft`. Defaults to `nm`\n * @param props.className - CSS classes for styling\n *\n * @example\n * ```tsx\n * // Basic usage with default nautical miles\n * <ViewportSize instanceId=\"some-uuid\" />\n *\n * // With custom unit and styling\n * <ViewportSize\n * instanceId=\"some-uuid\"\n * unit=\"km\"\n * className=\"text-sm text-gray-600\"\n * />\n * ```\n */\nexport function ViewportSize({\n instanceId,\n unit = 'nm',\n ...rest\n}: ViewportSizeProps) {\n const { bounds, zoom, width, height } = useMapViewport(instanceId);\n\n return (\n <span {...rest}>\n {getViewportSize({ bounds, unit, zoom, width, height })}\n </span>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+CA,SAAgB,aAAa,EAC3B,YACA,OAAO,MACP,GAAG,QACiB;CACpB,MAAM,EAAE,QAAQ,MAAM,OAAO,WAAW,eAAe,WAAW;AAElE,QACE,oBAAC;EAAK,GAAI;YACP,gBAAgB;GAAE;GAAQ;GAAM;GAAM;GAAO;GAAQ,CAAC;GAClD"}
|
package/package.json
CHANGED
|
@@ -1,17 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@accelint/map-toolkit",
|
|
3
3
|
"description": "A collection of components and utilities to simplify visualizing and working with geospatial data.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "1.0.0",
|
|
5
5
|
"author": "https://hypergiant.com",
|
|
6
6
|
"$schema": "https://json.schemastore.org/package",
|
|
7
7
|
"devDependencies": {
|
|
8
|
+
"@deck.gl-community/editable-layers": "~9.1",
|
|
8
9
|
"@deck.gl/core": "~9.1",
|
|
9
10
|
"@deck.gl/extensions": "~9.1",
|
|
10
|
-
"@deck.gl/geo-layers": "~9.1",
|
|
11
11
|
"@deck.gl/layers": "~9.1",
|
|
12
|
-
"@deck.gl/mapbox": "~9.1",
|
|
13
|
-
"@deck.gl/mesh-layers": "~9.1",
|
|
14
|
-
"@deck.gl/widgets": "~9.1",
|
|
15
12
|
"@deckgl-fiber-renderer/dom": "^1.4.0",
|
|
16
13
|
"@deckgl-fiber-renderer/shared": "^1.4.0",
|
|
17
14
|
"@deckgl-fiber-renderer/types": "^1.4.0",
|
|
@@ -24,6 +21,9 @@
|
|
|
24
21
|
"@testing-library/jest-dom": "^6.9.1",
|
|
25
22
|
"@testing-library/react": "^16.3.0",
|
|
26
23
|
"@testing-library/user-event": "^14.6.1",
|
|
24
|
+
"@turf/helpers": "^7.2.0",
|
|
25
|
+
"@turf/turf": "^7.2.0",
|
|
26
|
+
"@types/geojson": "^7946.0.14",
|
|
27
27
|
"@types/node": "^22",
|
|
28
28
|
"@types/react": "^19",
|
|
29
29
|
"@types/react-dom": "^19",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"node-fetch": "^2.6.7",
|
|
35
35
|
"react": "^19",
|
|
36
36
|
"react-dom": "^19",
|
|
37
|
+
"remark-gfm": "^4.0.1",
|
|
37
38
|
"storybook": "^9.1.16",
|
|
38
39
|
"tailwindcss": "^4.1.18",
|
|
39
40
|
"tsdown": "^0.18.0",
|
|
@@ -41,15 +42,17 @@
|
|
|
41
42
|
"typescript": "^5.9.3",
|
|
42
43
|
"vite": "^7.2.7",
|
|
43
44
|
"vitest": "^4.0.15",
|
|
44
|
-
"@accelint/biome-config": "1.0
|
|
45
|
+
"@accelint/biome-config": "1.1.0",
|
|
45
46
|
"@accelint/bus": "3.0.2",
|
|
46
47
|
"@accelint/core": "0.5.2",
|
|
47
48
|
"@accelint/design-foundation": "2.0.0",
|
|
48
|
-
"@accelint/design-toolkit": "9.
|
|
49
|
+
"@accelint/design-toolkit": "9.2.0",
|
|
50
|
+
"@accelint/geo": "0.5.0",
|
|
49
51
|
"@accelint/postcss-tailwind-css-modules": "1.0.1",
|
|
52
|
+
"@accelint/logger": "0.1.4",
|
|
53
|
+
"@accelint/smeegl": "0.3.4",
|
|
50
54
|
"@accelint/typescript-config": "0.1.4",
|
|
51
|
-
"@accelint/vitest-config": "0.1.6"
|
|
52
|
-
"@accelint/geo": "0.4.2"
|
|
55
|
+
"@accelint/vitest-config": "0.1.6"
|
|
53
56
|
},
|
|
54
57
|
"engines": {
|
|
55
58
|
"node": ">=22",
|
|
@@ -58,8 +61,8 @@
|
|
|
58
61
|
"exports": {
|
|
59
62
|
"./camera": "./dist/camera/index.js",
|
|
60
63
|
"./camera/events": "./dist/camera/events.js",
|
|
64
|
+
"./camera/store": "./dist/camera/store.js",
|
|
61
65
|
"./camera/types": "./dist/camera/types.js",
|
|
62
|
-
"./camera/use-camera-state": "./dist/camera/use-camera-state.js",
|
|
63
66
|
"./cursor-coordinates": "./dist/cursor-coordinates/index.js",
|
|
64
67
|
"./cursor-coordinates/use-cursor-coordinates": "./dist/cursor-coordinates/use-cursor-coordinates.js",
|
|
65
68
|
"./deckgl": "./dist/deckgl/index.js",
|
|
@@ -71,13 +74,30 @@
|
|
|
71
74
|
"./deckgl/base-map/types": "./dist/deckgl/base-map/types.js",
|
|
72
75
|
"./deckgl/saved-viewports": "./dist/deckgl/saved-viewports/index.js",
|
|
73
76
|
"./deckgl/saved-viewports/storage": "./dist/deckgl/saved-viewports/storage.js",
|
|
77
|
+
"./deckgl/shapes": "./dist/deckgl/shapes/index.js",
|
|
78
|
+
"./deckgl/shapes/display-shape-layer": "./dist/deckgl/shapes/display-shape-layer/index.js",
|
|
79
|
+
"./deckgl/shapes/display-shape-layer/fiber": "./dist/deckgl/shapes/display-shape-layer/fiber.js",
|
|
80
|
+
"./deckgl/shapes/display-shape-layer/types": "./dist/deckgl/shapes/display-shape-layer/types.js",
|
|
81
|
+
"./deckgl/shapes/display-shape-layer/use-select-shape": "./dist/deckgl/shapes/display-shape-layer/use-select-shape.js",
|
|
82
|
+
"./deckgl/shapes/draw-shape-layer": "./dist/deckgl/shapes/draw-shape-layer/index.js",
|
|
83
|
+
"./deckgl/shapes/draw-shape-layer/events": "./dist/deckgl/shapes/draw-shape-layer/events.js",
|
|
84
|
+
"./deckgl/shapes/draw-shape-layer/fiber": "./dist/deckgl/shapes/draw-shape-layer/fiber.js",
|
|
85
|
+
"./deckgl/shapes/draw-shape-layer/types": "./dist/deckgl/shapes/draw-shape-layer/types.js",
|
|
86
|
+
"./deckgl/shapes/draw-shape-layer/use-draw-shape": "./dist/deckgl/shapes/draw-shape-layer/use-draw-shape.js",
|
|
87
|
+
"./deckgl/shapes/edit-shape-layer": "./dist/deckgl/shapes/edit-shape-layer/index.js",
|
|
88
|
+
"./deckgl/shapes/edit-shape-layer/events": "./dist/deckgl/shapes/edit-shape-layer/events.js",
|
|
89
|
+
"./deckgl/shapes/edit-shape-layer/fiber": "./dist/deckgl/shapes/edit-shape-layer/fiber.js",
|
|
90
|
+
"./deckgl/shapes/edit-shape-layer/types": "./dist/deckgl/shapes/edit-shape-layer/types.js",
|
|
91
|
+
"./deckgl/shapes/edit-shape-layer/use-edit-shape": "./dist/deckgl/shapes/edit-shape-layer/use-edit-shape.js",
|
|
92
|
+
"./deckgl/shapes/shared/events": "./dist/deckgl/shapes/shared/events.js",
|
|
93
|
+
"./deckgl/shapes/shared/types": "./dist/deckgl/shapes/shared/types.js",
|
|
74
94
|
"./deckgl/symbol-layer": "./dist/deckgl/symbol-layer/index.js",
|
|
75
95
|
"./deckgl/symbol-layer/fiber": "./dist/deckgl/symbol-layer/fiber.js",
|
|
76
96
|
"./deckgl/text-layer": "./dist/deckgl/text-layer/index.js",
|
|
77
97
|
"./deckgl/text-layer/character-sets": "./dist/deckgl/text-layer/character-sets.js",
|
|
78
98
|
"./deckgl/text-layer/default-settings": "./dist/deckgl/text-layer/default-settings.js",
|
|
79
99
|
"./deckgl/text-layer/fiber": "./dist/deckgl/text-layer/fiber.js",
|
|
80
|
-
"./
|
|
100
|
+
"./deckgl/text-settings": "./dist/deckgl/text-settings.js",
|
|
81
101
|
"./map-cursor": "./dist/map-cursor/index.js",
|
|
82
102
|
"./map-cursor/events": "./dist/map-cursor/events.js",
|
|
83
103
|
"./map-cursor/store": "./dist/map-cursor/store.js",
|
|
@@ -89,12 +109,13 @@
|
|
|
89
109
|
"./map-mode/types": "./dist/map-mode/types.js",
|
|
90
110
|
"./map-mode/use-map-mode": "./dist/map-mode/use-map-mode.js",
|
|
91
111
|
"./maplibre": "./dist/maplibre/index.js",
|
|
92
|
-
"./maplibre/constants": "./dist/maplibre/constants.js",
|
|
93
112
|
"./maplibre/hooks/use-maplibre": "./dist/maplibre/hooks/use-maplibre.js",
|
|
113
|
+
"./shared/constants": "./dist/shared/constants.js",
|
|
114
|
+
"./shared/create-map-store": "./dist/shared/create-map-store.js",
|
|
115
|
+
"./shared/units": "./dist/shared/units.js",
|
|
94
116
|
"./viewport": "./dist/viewport/index.js",
|
|
95
|
-
"./viewport/
|
|
117
|
+
"./viewport/store": "./dist/viewport/store.js",
|
|
96
118
|
"./viewport/types": "./dist/viewport/types.js",
|
|
97
|
-
"./viewport/use-viewport-state": "./dist/viewport/use-viewport-state.js",
|
|
98
119
|
"./viewport/utils": "./dist/viewport/utils.js",
|
|
99
120
|
"./viewport/viewport-size": "./dist/viewport/viewport-size.js",
|
|
100
121
|
"./package.json": "./package.json"
|
|
@@ -114,29 +135,30 @@
|
|
|
114
135
|
],
|
|
115
136
|
"license": "Apache-2.0",
|
|
116
137
|
"optionalDependencies": {
|
|
117
|
-
"@deck.gl/
|
|
118
|
-
"@deck.gl/
|
|
119
|
-
"@deck.gl/
|
|
120
|
-
"@deck.gl/layers": "9.1
|
|
121
|
-
"@
|
|
122
|
-
"@deck.gl/mesh-layers": "9.1.14",
|
|
123
|
-
"@deck.gl/widgets": "9.1.14",
|
|
124
|
-
"@deckgl-fiber-renderer/dom": "1.4.0",
|
|
138
|
+
"@deck.gl-community/editable-layers": "~9.1",
|
|
139
|
+
"@deck.gl/core": "~9.1",
|
|
140
|
+
"@deck.gl/extensions": "~9.1",
|
|
141
|
+
"@deck.gl/layers": "~9.1",
|
|
142
|
+
"@deckgl-fiber-renderer/dom": "^1.4.0",
|
|
125
143
|
"@deckgl-fiber-renderer/shared": "^1.4.0",
|
|
126
144
|
"@deckgl-fiber-renderer/types": "^1.4.0",
|
|
127
145
|
"@math.gl/web-mercator": "^4.1.0",
|
|
146
|
+
"@turf/helpers": "^7.2.0",
|
|
147
|
+
"@turf/turf": "^7.2.0",
|
|
128
148
|
"maplibre-gl": "^5.7.1",
|
|
129
|
-
"milsymbol": "3.0.2",
|
|
149
|
+
"milsymbol": "^3.0.2",
|
|
130
150
|
"mjolnir.js": "^3.0.0",
|
|
131
151
|
"react-map-gl": "^8.1.0",
|
|
132
152
|
"@accelint/hotkey-manager": "0.1.3"
|
|
133
153
|
},
|
|
134
154
|
"owner": "default/pathfinder",
|
|
135
155
|
"peerDependencies": {
|
|
156
|
+
"@types/geojson": "^7946.0.14",
|
|
136
157
|
"react": "^19",
|
|
137
|
-
"@accelint/bus": "3.0.2",
|
|
138
158
|
"@accelint/core": "0.5.2",
|
|
139
|
-
"@accelint/geo": "0.
|
|
159
|
+
"@accelint/geo": "0.5.0",
|
|
160
|
+
"@accelint/logger": "0.1.4",
|
|
161
|
+
"@accelint/bus": "3.0.2"
|
|
140
162
|
},
|
|
141
163
|
"private": false,
|
|
142
164
|
"publishConfig": {
|
|
@@ -146,7 +168,18 @@
|
|
|
146
168
|
"type": "git",
|
|
147
169
|
"url": "https://github.com/gohypergiant/standard-toolkit"
|
|
148
170
|
},
|
|
149
|
-
"sideEffects":
|
|
171
|
+
"sideEffects": [
|
|
172
|
+
"./src/deckgl/shapes/display-shape-layer/fiber.ts",
|
|
173
|
+
"./src/deckgl/shapes/draw-shape-layer/fiber.ts",
|
|
174
|
+
"./src/deckgl/shapes/edit-shape-layer/fiber.ts",
|
|
175
|
+
"./src/deckgl/symbol-layer/fiber.ts",
|
|
176
|
+
"./src/deckgl/text-layer/fiber.ts",
|
|
177
|
+
"./dist/deckgl/shapes/display-shape-layer/fiber.js",
|
|
178
|
+
"./dist/deckgl/shapes/draw-shape-layer/fiber.js",
|
|
179
|
+
"./dist/deckgl/shapes/edit-shape-layer/fiber.js",
|
|
180
|
+
"./dist/deckgl/symbol-layer/fiber.js",
|
|
181
|
+
"./dist/deckgl/text-layer/fiber.js"
|
|
182
|
+
],
|
|
150
183
|
"subPath": "packages/map-toolkit",
|
|
151
184
|
"title": "Accelint Map Toolkit",
|
|
152
185
|
"type": "module",
|
|
@@ -154,6 +187,7 @@
|
|
|
154
187
|
"bench": "pnpm vitest bench --run --dir src",
|
|
155
188
|
"build": "pnpm tsdown",
|
|
156
189
|
"build-storybook": "pnpm storybook build",
|
|
190
|
+
"build:icons": "smeegl --in '.storybook/icons' --out 'src/deckgl/shapes/__fixtures__/atlas'",
|
|
157
191
|
"constellation-tracker": "pnpm exec constellation-tracker",
|
|
158
192
|
"dev": "pnpm tsc --watch",
|
|
159
193
|
"format": "pnpm biome format . --write --verbose",
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.
|
|
3
|
-
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
* you may not use this file except in compliance with the License. You may obtain a copy
|
|
5
|
-
* of the License at https://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
*
|
|
7
|
-
* Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
-
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
-
* OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
-
* governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
//#region rolldown:runtime
|
|
15
|
-
var __commonJSMin = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
16
|
-
var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, { get: (a, b) => (typeof require !== "undefined" ? require : a)[b] }) : x)(function(x) {
|
|
17
|
-
if (typeof require !== "undefined") return require.apply(this, arguments);
|
|
18
|
-
throw Error("Calling `require` for \"" + x + "\" in an environment that doesn't expose the `require` function.");
|
|
19
|
-
});
|
|
20
|
-
|
|
21
|
-
//#endregion
|
|
22
|
-
export { __commonJSMin, __require };
|