@dxos/react-ui-geo 0.7.5-labs.ea4b4c2 → 0.7.5-labs.f400bbc

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.
Files changed (38) hide show
  1. package/dist/lib/browser/index.mjs +113 -48
  2. package/dist/lib/browser/index.mjs.map +3 -3
  3. package/dist/lib/browser/meta.json +1 -1
  4. package/dist/lib/node/index.cjs +111 -46
  5. package/dist/lib/node/index.cjs.map +3 -3
  6. package/dist/lib/node/meta.json +1 -1
  7. package/dist/lib/node-esm/index.mjs +113 -48
  8. package/dist/lib/node-esm/index.mjs.map +3 -3
  9. package/dist/lib/node-esm/meta.json +1 -1
  10. package/dist/types/src/components/Globe/Globe.d.ts +5 -5
  11. package/dist/types/src/components/Globe/Globe.d.ts.map +1 -1
  12. package/dist/types/src/components/Globe/Globe.stories.d.ts +9 -10
  13. package/dist/types/src/components/Globe/Globe.stories.d.ts.map +1 -1
  14. package/dist/types/src/components/Map/Map.d.ts +7 -7
  15. package/dist/types/src/components/Map/Map.d.ts.map +1 -1
  16. package/dist/types/src/components/Map/Map.stories.d.ts +6 -2
  17. package/dist/types/src/components/Map/Map.stories.d.ts.map +1 -1
  18. package/dist/types/src/components/Toolbar/Controls.d.ts +2 -3
  19. package/dist/types/src/components/Toolbar/Controls.d.ts.map +1 -1
  20. package/dist/types/src/components/types.d.ts +2 -1
  21. package/dist/types/src/components/types.d.ts.map +1 -1
  22. package/dist/types/src/hooks/context.d.ts +2 -2
  23. package/dist/types/src/hooks/context.d.ts.map +1 -1
  24. package/dist/types/src/hooks/useTour.d.ts +8 -3
  25. package/dist/types/src/hooks/useTour.d.ts.map +1 -1
  26. package/dist/types/src/util/debug.d.ts.map +1 -1
  27. package/dist/types/src/util/render.d.ts +2 -2
  28. package/dist/types/src/util/render.d.ts.map +1 -1
  29. package/package.json +12 -10
  30. package/src/components/Globe/Globe.stories.tsx +8 -11
  31. package/src/components/Globe/Globe.tsx +56 -32
  32. package/src/components/Map/Map.stories.tsx +28 -6
  33. package/src/components/Map/Map.tsx +93 -82
  34. package/src/components/types.ts +2 -1
  35. package/src/hooks/useDrag.ts +1 -1
  36. package/src/hooks/useTour.ts +31 -19
  37. package/src/util/debug.ts +1 -0
  38. package/src/util/render.ts +18 -4
@@ -1 +1 @@
1
- {"inputs":{"packages/ui/react-ui-geo/data/countries-110m.ts":{"bytes":1352295,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/data.ts":{"bytes":914,"imports":[{"path":"packages/ui/react-ui-geo/data/countries-110m.ts","kind":"dynamic-import","original":"../data/countries-110m.ts"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/types.ts":{"bytes":951,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/context.tsx":{"bytes":5204,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/util/debug.ts":{"bytes":1506,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/util/inertia.ts":{"bytes":21992,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/util/path.ts":{"bytes":5846,"imports":[{"path":"d3","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/util/render.ts":{"bytes":11848,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"topojson-client","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/util/path.ts","kind":"import-statement","original":"./path"}],"format":"esm"},"packages/ui/react-ui-geo/src/util/index.ts":{"bytes":747,"imports":[{"path":"packages/ui/react-ui-geo/src/util/debug.ts","kind":"import-statement","original":"./debug"},{"path":"packages/ui/react-ui-geo/src/util/inertia.ts","kind":"import-statement","original":"./inertia"},{"path":"packages/ui/react-ui-geo/src/util/path.ts","kind":"import-statement","original":"./path"},{"path":"packages/ui/react-ui-geo/src/util/render.ts","kind":"import-statement","original":"./render"}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useDrag.ts":{"bytes":4603,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useGlobeZoomHandler.ts":{"bytes":2396,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useMapZoomHandler.ts":{"bytes":2362,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useSpinner.ts":{"bytes":5331,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useTour.ts":{"bytes":14072,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/index.ts":{"bytes":997,"imports":[{"path":"packages/ui/react-ui-geo/src/hooks/context.tsx","kind":"import-statement","original":"./context"},{"path":"packages/ui/react-ui-geo/src/hooks/useDrag.ts","kind":"import-statement","original":"./useDrag"},{"path":"packages/ui/react-ui-geo/src/hooks/useGlobeZoomHandler.ts","kind":"import-statement","original":"./useGlobeZoomHandler"},{"path":"packages/ui/react-ui-geo/src/hooks/useMapZoomHandler.ts","kind":"import-statement","original":"./useMapZoomHandler"},{"path":"packages/ui/react-ui-geo/src/hooks/useSpinner.ts","kind":"import-statement","original":"./useSpinner"},{"path":"packages/ui/react-ui-geo/src/hooks/useTour.ts","kind":"import-statement","original":"./useTour"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Toolbar/Controls.tsx":{"bytes":5932,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Toolbar/index.ts":{"bytes":515,"imports":[{"path":"packages/ui/react-ui-geo/src/components/Toolbar/Controls.tsx","kind":"import-statement","original":"./Controls"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Globe/Globe.tsx":{"bytes":24734,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/hooks/index.ts","kind":"import-statement","original":"../../hooks"},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"../../util"},{"path":"packages/ui/react-ui-geo/src/components/Toolbar/index.ts","kind":"import-statement","original":"../Toolbar"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Globe/index.ts":{"bytes":506,"imports":[{"path":"packages/ui/react-ui-geo/src/components/Globe/Globe.tsx","kind":"import-statement","original":"./Globe"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Map/Map.tsx":{"bytes":19049,"imports":[{"path":"leaflet/dist/leaflet.css","kind":"import-statement","external":true},{"path":"leaflet","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"react-leaflet","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/components/Toolbar/index.ts","kind":"import-statement","original":"../Toolbar"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Map/index.ts":{"bytes":498,"imports":[{"path":"packages/ui/react-ui-geo/src/components/Map/Map.tsx","kind":"import-statement","original":"./Map"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/index.ts":{"bytes":751,"imports":[{"path":"packages/ui/react-ui-geo/src/components/types.ts","kind":"import-statement","original":"./types"},{"path":"packages/ui/react-ui-geo/src/components/Globe/index.ts","kind":"import-statement","original":"./Globe"},{"path":"packages/ui/react-ui-geo/src/components/Map/index.ts","kind":"import-statement","original":"./Map"},{"path":"packages/ui/react-ui-geo/src/components/Toolbar/index.ts","kind":"import-statement","original":"./Toolbar"}],"format":"esm"},"packages/ui/react-ui-geo/src/types.ts":{"bytes":624,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/index.ts":{"bytes":824,"imports":[{"path":"packages/ui/react-ui-geo/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/ui/react-ui-geo/src/data.ts","kind":"import-statement","original":"./data"},{"path":"packages/ui/react-ui-geo/src/hooks/index.ts","kind":"import-statement","original":"./hooks"},{"path":"packages/ui/react-ui-geo/src/types.ts","kind":"import-statement","original":"./types"},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"./util"}],"format":"esm"}},"outputs":{"packages/ui/react-ui-geo/dist/lib/node-esm/data.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/ui/react-ui-geo/dist/lib/node-esm/data.mjs":{"imports":[{"path":"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs","kind":"import-statement"}],"exports":["loadTopology"],"entryPoint":"packages/ui/react-ui-geo/src/data.ts","inputs":{},"bytes":208},"packages/ui/react-ui-geo/dist/lib/node-esm/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":62928},"packages/ui/react-ui-geo/dist/lib/node-esm/index.mjs":{"imports":[{"path":"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs","kind":"import-statement"},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"topojson-client","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"leaflet/dist/leaflet.css","kind":"import-statement","external":true},{"path":"leaflet","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"react-leaflet","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["ActionControls","Globe","GlobeContextProvider","Map","ZoomControls","closestPoint","controlPositions","createLayers","geoCircle","geoInertiaDrag","geoLine","geoPoint","geoToPosition","getDistance","loadTopology","positionToRotation","renderLayers","restrictAxis","timer","useDrag","useGlobeContext","useGlobeZoomHandler","useMapZoomHandler","useSpinner","useTour"],"entryPoint":"packages/ui/react-ui-geo/src/index.ts","inputs":{"packages/ui/react-ui-geo/src/components/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/components/Globe/Globe.tsx":{"bytesInOutput":5288},"packages/ui/react-ui-geo/src/hooks/context.tsx":{"bytesInOutput":960},"packages/ui/react-ui-geo/src/hooks/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/hooks/useDrag.ts":{"bytesInOutput":839},"packages/ui/react-ui-geo/src/util/debug.ts":{"bytesInOutput":211},"packages/ui/react-ui-geo/src/util/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/util/inertia.ts":{"bytesInOutput":4544},"packages/ui/react-ui-geo/src/util/path.ts":{"bytesInOutput":1051},"packages/ui/react-ui-geo/src/util/render.ts":{"bytesInOutput":2320},"packages/ui/react-ui-geo/src/hooks/useGlobeZoomHandler.ts":{"bytesInOutput":417},"packages/ui/react-ui-geo/src/hooks/useMapZoomHandler.ts":{"bytesInOutput":426},"packages/ui/react-ui-geo/src/hooks/useSpinner.ts":{"bytesInOutput":1141},"packages/ui/react-ui-geo/src/hooks/useTour.ts":{"bytesInOutput":3137},"packages/ui/react-ui-geo/src/components/Toolbar/Controls.tsx":{"bytesInOutput":1521},"packages/ui/react-ui-geo/src/components/Toolbar/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/components/Globe/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/components/Map/Map.tsx":{"bytesInOutput":4258},"packages/ui/react-ui-geo/src/components/Map/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/index.ts":{"bytesInOutput":0}},"bytes":27517},"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":432},"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs":{"imports":[{"path":"packages/ui/react-ui-geo/dist/lib/node-esm/countries-110m-DQ4XRC4B.mjs","kind":"dynamic-import"}],"exports":["loadTopology"],"inputs":{"packages/ui/react-ui-geo/src/data.ts":{"bytesInOutput":102}},"bytes":307},"packages/ui/react-ui-geo/dist/lib/node-esm/countries-110m-DQ4XRC4B.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":352621},"packages/ui/react-ui-geo/dist/lib/node-esm/countries-110m-DQ4XRC4B.mjs":{"imports":[],"exports":["default"],"entryPoint":"packages/ui/react-ui-geo/data/countries-110m.ts","inputs":{"packages/ui/react-ui-geo/data/countries-110m.ts":{"bytesInOutput":420420}},"bytes":420665}}}
1
+ {"inputs":{"packages/ui/react-ui-geo/data/countries-110m.ts":{"bytes":1352295,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/data.ts":{"bytes":914,"imports":[{"path":"packages/ui/react-ui-geo/data/countries-110m.ts","kind":"dynamic-import","original":"../data/countries-110m.ts"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/types.ts":{"bytes":983,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/context.tsx":{"bytes":5204,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/util/debug.ts":{"bytes":1506,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/util/inertia.ts":{"bytes":21992,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/util/path.ts":{"bytes":5846,"imports":[{"path":"d3","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/util/render.ts":{"bytes":12455,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"topojson-client","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/util/path.ts","kind":"import-statement","original":"./path"}],"format":"esm"},"packages/ui/react-ui-geo/src/util/index.ts":{"bytes":747,"imports":[{"path":"packages/ui/react-ui-geo/src/util/debug.ts","kind":"import-statement","original":"./debug"},{"path":"packages/ui/react-ui-geo/src/util/inertia.ts","kind":"import-statement","original":"./inertia"},{"path":"packages/ui/react-ui-geo/src/util/path.ts","kind":"import-statement","original":"./path"},{"path":"packages/ui/react-ui-geo/src/util/render.ts","kind":"import-statement","original":"./render"}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useDrag.ts":{"bytes":4691,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useGlobeZoomHandler.ts":{"bytes":2396,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useMapZoomHandler.ts":{"bytes":2362,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useSpinner.ts":{"bytes":5331,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/useTour.ts":{"bytes":15403,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-geo/src/hooks/index.ts":{"bytes":997,"imports":[{"path":"packages/ui/react-ui-geo/src/hooks/context.tsx","kind":"import-statement","original":"./context"},{"path":"packages/ui/react-ui-geo/src/hooks/useDrag.ts","kind":"import-statement","original":"./useDrag"},{"path":"packages/ui/react-ui-geo/src/hooks/useGlobeZoomHandler.ts","kind":"import-statement","original":"./useGlobeZoomHandler"},{"path":"packages/ui/react-ui-geo/src/hooks/useMapZoomHandler.ts","kind":"import-statement","original":"./useMapZoomHandler"},{"path":"packages/ui/react-ui-geo/src/hooks/useSpinner.ts","kind":"import-statement","original":"./useSpinner"},{"path":"packages/ui/react-ui-geo/src/hooks/useTour.ts","kind":"import-statement","original":"./useTour"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Toolbar/Controls.tsx":{"bytes":5932,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Toolbar/index.ts":{"bytes":515,"imports":[{"path":"packages/ui/react-ui-geo/src/components/Toolbar/Controls.tsx","kind":"import-statement","original":"./Controls"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Globe/Globe.tsx":{"bytes":26472,"imports":[{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/hooks/index.ts","kind":"import-statement","original":"../../hooks"},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"../../util"},{"path":"packages/ui/react-ui-geo/src/components/Toolbar/index.ts","kind":"import-statement","original":"../Toolbar"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Globe/index.ts":{"bytes":506,"imports":[{"path":"packages/ui/react-ui-geo/src/components/Globe/Globe.tsx","kind":"import-statement","original":"./Globe"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Map/Map.tsx":{"bytes":20610,"imports":[{"path":"leaflet/dist/leaflet.css","kind":"import-statement","external":true},{"path":"leaflet","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"react-leaflet","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-geo/src/components/Toolbar/index.ts","kind":"import-statement","original":"../Toolbar"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/Map/index.ts":{"bytes":498,"imports":[{"path":"packages/ui/react-ui-geo/src/components/Map/Map.tsx","kind":"import-statement","original":"./Map"}],"format":"esm"},"packages/ui/react-ui-geo/src/components/index.ts":{"bytes":751,"imports":[{"path":"packages/ui/react-ui-geo/src/components/types.ts","kind":"import-statement","original":"./types"},{"path":"packages/ui/react-ui-geo/src/components/Globe/index.ts","kind":"import-statement","original":"./Globe"},{"path":"packages/ui/react-ui-geo/src/components/Map/index.ts","kind":"import-statement","original":"./Map"},{"path":"packages/ui/react-ui-geo/src/components/Toolbar/index.ts","kind":"import-statement","original":"./Toolbar"}],"format":"esm"},"packages/ui/react-ui-geo/src/types.ts":{"bytes":624,"imports":[],"format":"esm"},"packages/ui/react-ui-geo/src/index.ts":{"bytes":824,"imports":[{"path":"packages/ui/react-ui-geo/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/ui/react-ui-geo/src/data.ts","kind":"import-statement","original":"./data"},{"path":"packages/ui/react-ui-geo/src/hooks/index.ts","kind":"import-statement","original":"./hooks"},{"path":"packages/ui/react-ui-geo/src/types.ts","kind":"import-statement","original":"./types"},{"path":"packages/ui/react-ui-geo/src/util/index.ts","kind":"import-statement","original":"./util"}],"format":"esm"}},"outputs":{"packages/ui/react-ui-geo/dist/lib/node-esm/data.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/ui/react-ui-geo/dist/lib/node-esm/data.mjs":{"imports":[{"path":"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs","kind":"import-statement"}],"exports":["loadTopology"],"entryPoint":"packages/ui/react-ui-geo/src/data.ts","inputs":{},"bytes":208},"packages/ui/react-ui-geo/dist/lib/node-esm/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":65339},"packages/ui/react-ui-geo/dist/lib/node-esm/index.mjs":{"imports":[{"path":"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs","kind":"import-statement"},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"topojson-client","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"d3","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"versor","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"leaflet/dist/leaflet.css","kind":"import-statement","external":true},{"path":"leaflet","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"react-leaflet","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["ActionControls","Globe","GlobeContextProvider","Map","ZoomControls","closestPoint","controlPositions","createLayers","geoCircle","geoInertiaDrag","geoLine","geoPoint","geoToPosition","getDistance","loadTopology","positionToRotation","renderLayers","restrictAxis","timer","useDrag","useGlobeContext","useGlobeZoomHandler","useMapZoomHandler","useSpinner","useTour"],"entryPoint":"packages/ui/react-ui-geo/src/index.ts","inputs":{"packages/ui/react-ui-geo/src/components/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/components/Globe/Globe.tsx":{"bytesInOutput":5742},"packages/ui/react-ui-geo/src/hooks/context.tsx":{"bytesInOutput":960},"packages/ui/react-ui-geo/src/hooks/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/hooks/useDrag.ts":{"bytesInOutput":855},"packages/ui/react-ui-geo/src/util/debug.ts":{"bytesInOutput":211},"packages/ui/react-ui-geo/src/util/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/util/inertia.ts":{"bytesInOutput":4544},"packages/ui/react-ui-geo/src/util/path.ts":{"bytesInOutput":1051},"packages/ui/react-ui-geo/src/util/render.ts":{"bytesInOutput":2479},"packages/ui/react-ui-geo/src/hooks/useGlobeZoomHandler.ts":{"bytesInOutput":417},"packages/ui/react-ui-geo/src/hooks/useMapZoomHandler.ts":{"bytesInOutput":426},"packages/ui/react-ui-geo/src/hooks/useSpinner.ts":{"bytesInOutput":1141},"packages/ui/react-ui-geo/src/hooks/useTour.ts":{"bytesInOutput":3589},"packages/ui/react-ui-geo/src/components/Toolbar/Controls.tsx":{"bytesInOutput":1521},"packages/ui/react-ui-geo/src/components/Toolbar/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/components/Globe/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/components/Map/Map.tsx":{"bytesInOutput":4837},"packages/ui/react-ui-geo/src/components/Map/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-geo/src/index.ts":{"bytesInOutput":0}},"bytes":29177},"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":432},"packages/ui/react-ui-geo/dist/lib/node-esm/chunk-PIIEDZEU.mjs":{"imports":[{"path":"packages/ui/react-ui-geo/dist/lib/node-esm/countries-110m-DQ4XRC4B.mjs","kind":"dynamic-import"}],"exports":["loadTopology"],"inputs":{"packages/ui/react-ui-geo/src/data.ts":{"bytesInOutput":102}},"bytes":307},"packages/ui/react-ui-geo/dist/lib/node-esm/countries-110m-DQ4XRC4B.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":352621},"packages/ui/react-ui-geo/dist/lib/node-esm/countries-110m-DQ4XRC4B.mjs":{"imports":[],"exports":["default"],"entryPoint":"packages/ui/react-ui-geo/data/countries-110m.ts","inputs":{"packages/ui/react-ui-geo/data/countries-110m.ts":{"bytesInOutput":420420}},"bytes":420665}}}
@@ -22,16 +22,16 @@ type GlobeControlProps = {
22
22
  position?: ControlPosition;
23
23
  } & Pick<ControlProps, 'onAction'>;
24
24
  export declare const Globe: {
25
- Root: ({ classNames, children, ...props }: GlobeRootProps) => React.JSX.Element;
25
+ Root: ({ classNames, children, ...props }: GlobeRootProps) => import("react/jsx-runtime").JSX.Element;
26
26
  Canvas: React.ForwardRefExoticComponent<GlobeCanvasProps & React.RefAttributes<GlobeController>>;
27
- Zoom: ({ onAction, position, ...props }: GlobeControlProps) => React.JSX.Element;
28
- Action: ({ onAction, position, ...props }: GlobeControlProps) => React.JSX.Element;
27
+ Zoom: ({ onAction, position, ...props }: GlobeControlProps) => import("react/jsx-runtime").JSX.Element;
28
+ Action: ({ onAction, position, ...props }: GlobeControlProps) => import("react/jsx-runtime").JSX.Element;
29
29
  Debug: ({ position }: {
30
30
  position?: ControlPosition;
31
- }) => React.JSX.Element;
31
+ }) => import("react/jsx-runtime").JSX.Element;
32
32
  Panel: ({ position, classNames, children, }: ThemedClassName<PropsWithChildren & {
33
33
  position?: ControlPosition;
34
- }>) => React.JSX.Element;
34
+ }>) => import("react/jsx-runtime").JSX.Element;
35
35
  };
36
36
  export type { GlobeRootProps, GlobeCanvasProps };
37
37
  //# sourceMappingURL=Globe.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Globe.d.ts","sourceRoot":"","sources":["../../../../../src/components/Globe/Globe.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,IAAI,CAAC;AACxC,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,KAAK,EAAE,EACZ,KAAK,iBAAiB,EAOvB,MAAM,OAAO,CAAC;AAEf,OAAO,EAAE,KAAK,Q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,QAAQ,CAAC,EAAE,eAAe,CAAA;CAAE,GAAG,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;AAEzF,eAAO,MAAM,KAAK;+CA3JqC,cAAc;;6CA8JX,iBAAiB;+CAKd,iBAAiB;0BAtChC;QAAE,QAAQ,CAAC,EAAE,eAAe,CAAA;KAAE;iDAoBzE,eAAe,CAAC,iBAAiB,GAAG;QAAE,QAAQ,CAAC,EAAE,eAAe,CAAA;KAAE,CAAC;CAyBrE,CAAC;AAEF,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,CAAC"}
@@ -1,15 +1,14 @@
1
1
  import '@dxos-theme';
2
2
  import { type Meta } from '@storybook/react';
3
- import React from 'react';
4
3
  declare const meta: Meta;
5
4
  export default meta;
6
- export declare const Earth1: () => React.JSX.Element;
7
- export declare const Earth2: () => React.JSX.Element;
8
- export declare const Mercator: () => React.JSX.Element;
9
- export declare const Globe1: () => React.JSX.Element;
10
- export declare const Globe2: () => React.JSX.Element;
11
- export declare const Globe3: () => React.JSX.Element;
12
- export declare const Globe4: () => React.JSX.Element;
13
- export declare const Globe5: () => React.JSX.Element;
14
- export declare const Globe6: () => React.JSX.Element;
5
+ export declare const Earth1: () => import("react/jsx-runtime").JSX.Element;
6
+ export declare const Earth2: () => import("react/jsx-runtime").JSX.Element;
7
+ export declare const Mercator: () => import("react/jsx-runtime").JSX.Element;
8
+ export declare const Globe1: () => import("react/jsx-runtime").JSX.Element;
9
+ export declare const Globe2: () => import("react/jsx-runtime").JSX.Element;
10
+ export declare const Globe3: () => import("react/jsx-runtime").JSX.Element;
11
+ export declare const Globe4: () => import("react/jsx-runtime").JSX.Element;
12
+ export declare const Globe5: () => import("react/jsx-runtime").JSX.Element;
13
+ export declare const Globe6: () => import("react/jsx-runtime").JSX.Element;
15
14
  //# sourceMappingURL=Globe.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Globe.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Globe/Globe.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAG7C,OAAO,KAAoC,MAAM,OAAO,CAAC;AAuNzD,QAAA,MAAM,IAAI,EAAE,IAIX,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,MAAM,yBAYlB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAclB,CAAC;AAqBF,eAAO,MAAM,QAAQ,yBAYpB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAElB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAElB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAElB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAElB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAElB,CAAC;AAEF,eAAO,MAAM,MAAM,yBAElB,CAAC"}
1
+ {"version":3,"file":"Globe.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Globe/Globe.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAuN7C,QAAA,MAAM,IAAI,EAAE,IAIX,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,MAAM,+CAYlB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAclB,CAAC;AAqBF,eAAO,MAAM,QAAQ,+CAYpB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAElB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAElB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAElB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAElB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAElB,CAAC;AAEF,eAAO,MAAM,MAAM,+CAElB,CAAC"}
@@ -1,8 +1,7 @@
1
1
  import 'leaflet/dist/leaflet.css';
2
- import type L from 'leaflet';
3
- import { type ControlPosition, type LatLngExpression } from 'leaflet';
2
+ import L, { type ControlPosition, type LatLngExpression } from 'leaflet';
4
3
  import React from 'react';
5
- import { type MapContainerProps } from 'react-leaflet/lib/MapContainer';
4
+ import type { MapContainerProps } from 'react-leaflet';
6
5
  import { type ThemedClassName } from '@dxos/react-ui';
7
6
  import { type ControlProps } from '../Toolbar';
8
7
  import { type MapCanvasProps } from '../types';
@@ -15,9 +14,10 @@ type MapControlProps = {
15
14
  position?: ControlPosition;
16
15
  } & Pick<ControlProps, 'onAction'>;
17
16
  export declare const Map: {
18
- Root: ({ classNames, center, zoom, ...props }: MapRootProps) => React.JSX.Element;
17
+ Root: ({ classNames, center, zoom, ...props }: MapRootProps) => import("react/jsx-runtime").JSX.Element;
19
18
  Canvas: React.ForwardRefExoticComponent<Omit<{
20
19
  markers?: import("../..").MapMarker[];
20
+ selected?: string[];
21
21
  zoom?: number;
22
22
  center?: L.LatLngLiteral;
23
23
  onChange?: (ev: {
@@ -25,10 +25,10 @@ export declare const Map: {
25
25
  zoom: number;
26
26
  }) => void;
27
27
  }, "className"> & {
28
- classNames?: import("@dxos/react-ui").ClassNameValue;
28
+ classNames?: import("@dxos/react-ui-types").ClassNameValue;
29
29
  } & React.RefAttributes<MapController>>;
30
- Zoom: ({ onAction, position, ...props }: MapControlProps) => React.JSX.Element;
31
- Action: ({ onAction, position, ...props }: MapControlProps) => React.JSX.Element;
30
+ Zoom: ({ onAction, position, ...props }: MapControlProps) => import("react/jsx-runtime").JSX.Element;
31
+ Action: ({ onAction, position, ...props }: MapControlProps) => import("react/jsx-runtime").JSX.Element;
32
32
  };
33
33
  export { type MapCanvasProps, type MapController };
34
34
  //# sourceMappingURL=Map.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Map.d.ts","sourceRoot":"","sources":["../../../../../src/components/Map/Map.tsx"],"names":[],"mappings":"AAKA,OAAO,0BAA0B,CAAC;AAElC,OAAO,KAAK,CAAC,MAAM,SAAS,CAAC;AAC7B,OAAO,EAAE,KAAK,eAAe,EA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AAkD,KAAK,YAAY,EAAE,MAAM,YAAY,CAAC;AAC/F,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAe/C,KAAK,YAAY,GAAG,eAAe,CAAC,iBAAiB,CAAC,CAAC;AAuBvD,KAAK,aAAa,GAAG;IACnB,SAAS,EAAE,CAAC,MAAM,EAAE,gBAAgB,EAAE,IAAI,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7D,OAAO,EAAE,CAAC,EAAE,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,KAAK,IAAI,CAAC;CACjD,CAAC;AAoIF,KAAK,eAAe,GAAG;IAAE,QAAQ,CAAC,EAAE,eAAe,CAAA;CAAE,GAAG,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;AAMvF,eAAO,MAAM,GAAG;mDAjK2E,YAAY;;;;;;;;;;;;;6CAoK7C,eAAe;+CAKZ,eAAe;CAK3E,CAAC;AAEF,OAAO,EAAE,KAAK,cAAc,EAAE,KAAK,aAAa,EAAE,CAAC"}
@@ -1,7 +1,11 @@
1
1
  import '@dxos-theme';
2
2
  import { type StoryObj, type Meta } from '@storybook/react';
3
- declare const meta: Meta;
3
+ declare const Render: ({ markers }: {
4
+ markers: any;
5
+ }) => import("react/jsx-runtime").JSX.Element;
6
+ declare const meta: Meta<typeof Render>;
4
7
  export default meta;
5
- type Story = StoryObj;
8
+ type Story = StoryObj<typeof Render>;
6
9
  export declare const Default: Story;
10
+ export declare const WithMarkers: Story;
7
11
  //# sourceMappingURL=Map.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Map.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Map/Map.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAqB5D,QAAA,MAAM,IAAI,EAAE,IAKX,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC;AAEtB,eAAO,MAAM,OAAO,EAAE,KAAU,CAAC"}
1
+ {"version":3,"file":"Map.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Map/Map.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAS5D,QAAA,MAAM,MAAM;;6CAWX,CAAC;AAEF,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,MAAM,CAI7B,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,MAAM,CAAC,CAAC;AAErC,eAAO,MAAM,OAAO,EAAE,KAAU,CAAC;AAEjC,eAAO,MAAM,WAAW,EAAE,KAoBzB,CAAC"}
@@ -1,11 +1,10 @@
1
1
  import { type ControlPosition } from 'leaflet';
2
- import React from 'react';
3
2
  import { type ThemedClassName } from '@dxos/react-ui';
4
3
  export type ControlAction = 'toggle' | 'start' | 'zoom-in' | 'zoom-out';
5
4
  export type ControlProps = ThemedClassName<{
6
5
  onAction?: (action: ControlAction) => void;
7
6
  }>;
8
7
  export declare const controlPositions: Record<ControlPosition, string>;
9
- export declare const ZoomControls: ({ classNames, onAction }: ControlProps) => React.JSX.Element;
10
- export declare const ActionControls: ({ classNames, onAction }: ControlProps) => React.JSX.Element;
8
+ export declare const ZoomControls: ({ classNames, onAction }: ControlProps) => import("react/jsx-runtime").JSX.Element;
9
+ export declare const ActionControls: ({ classNames, onAction }: ControlProps) => import("react/jsx-runtime").JSX.Element;
11
10
  //# sourceMappingURL=Controls.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Controls.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Controls.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAc,KAAK,eAAe,EAAW,MAAM,gBAAgB,CAAC;AAE3E,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,GAAG,UAAU,CAAC;AAExE,MAAM,MAAM,YAAY,GAAG,eAAe,CAAC;IACzC,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,aAAa,KAAK,IAAI,CAAC;CAC5C,CAAC,CAAC;AAEH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,eAAe,EAAE,MAAM,CAK5D,CAAC;AAEF,eAAO,MAAM,YAAY,6BAA8B,YAAY,sBAuBlE,CAAC;AAEF,eAAO,MAAM,cAAc,6BAA8B,YAAY,sBAuBpE,CAAC"}
1
+ {"version":3,"file":"Controls.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Controls.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,SAAS,CAAC;AAG/C,OAAO,EAAc,KAAK,eAAe,EAAW,MAAM,gBAAgB,CAAC;AAE3E,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,GAAG,UAAU,CAAC;AAExE,MAAM,MAAM,YAAY,GAAG,eAAe,CAAC;IACzC,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,aAAa,KAAK,IAAI,CAAC;CAC5C,CAAC,CAAC;AAEH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,eAAe,EAAE,MAAM,CAK5D,CAAC;AAEF,eAAO,MAAM,YAAY,6BAA8B,YAAY,4CAuBlE,CAAC;AAEF,eAAO,MAAM,cAAc,6BAA8B,YAAY,4CAuBpE,CAAC"}
@@ -1,9 +1,10 @@
1
1
  import { type LatLngLiteral } from 'leaflet';
2
2
  import { type ThemedClassName } from '@dxos/react-ui';
3
3
  import { type MapMarker } from '../types';
4
- export type { LatLngLiteral };
4
+ export { type LatLngLiteral };
5
5
  export type MapCanvasProps = ThemedClassName<{
6
6
  markers?: MapMarker[];
7
+ selected?: string[];
7
8
  zoom?: number;
8
9
  center?: LatLngLiteral;
9
10
  onChange?: (ev: {
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/types.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,SAAS,CAAC;AAE7C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEtD,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,UAAU,CAAC;AAE1C,YAAY,EAAE,aAAa,EAAE,CAAC;AAE9B,MAAM,MAAM,cAAc,GAAG,eAAe,CAAC;IAC3C,OAAO,CAAC,EAAE,SAAS,EAAE,CAAC;IACtB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,aAAa,CAAC;IACvB,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE;QAAE,MAAM,EAAE,aAAa,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAC;CAClE,CAAC,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/types.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,SAAS,CAAC;AAE7C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEtD,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,UAAU,CAAC;AAE1C,OAAO,EAAE,KAAK,aAAa,EAAE,CAAC;AAE9B,MAAM,MAAM,cAAc,GAAG,eAAe,CAAC;IAC3C,OAAO,CAAC,EAAE,SAAS,EAAE,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,aAAa,CAAC;IACvB,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE;QAAE,MAAM,EAAE,aAAa,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAC;CAClE,CAAC,CAAC"}
@@ -1,4 +1,4 @@
1
- import React, { type Dispatch, type PropsWithChildren, type SetStateAction } from 'react';
1
+ import { type Dispatch, type PropsWithChildren, type SetStateAction } from 'react';
2
2
  import { type LatLng } from '../util';
3
3
  export type Size = {
4
4
  width: number;
@@ -21,6 +21,6 @@ export type GlobeContextType = {
21
21
  setRotation: Dispatch<SetStateAction<Vector>>;
22
22
  };
23
23
  export type GlobeContextProviderProps = PropsWithChildren<Partial<Pick<GlobeContextType, 'size' | 'center' | 'scale' | 'translation' | 'rotation'>>>;
24
- export declare const GlobeContextProvider: ({ children, size, center: _center, scale: _scale, translation: _translation, rotation: _rotation, }: GlobeContextProviderProps) => React.JSX.Element;
24
+ export declare const GlobeContextProvider: ({ children, size, center: _center, scale: _scale, translation: _translation, rotation: _rotation, }: GlobeContextProviderProps) => import("react/jsx-runtime").JSX.Element;
25
25
  export declare const useGlobeContext: () => GlobeContextType;
26
26
  //# sourceMappingURL=context.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/hooks/context.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAiB,KAAK,QAAQ,EAAE,KAAK,iBAAiB,EAAE,KAAK,cAAc,EAAc,MAAM,OAAO,CAAC;AAKrH,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,SAAS,CAAC;AAGtC,MAAM,MAAM,IAAI,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AACrD,MAAM,MAAM,KAAK,GAAG;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAC7C,MAAM,MAAM,MAAM,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CA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AE,MAAM,CAAC,CAAC;AAE9C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,EAAE,IAAI,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,KAAK,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;IAC5C,QAAQ,EAAE,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;IAC3C,cAAc,EAAE,QAAQ,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,CAAC;IAChD,WAAW,EAAE,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;CAC/C,CAAC;AAIF,MAAM,MAAM,yBAAyB,GAAG,iBAAiB,CACvD,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,aAAa,GAAG,UAAU,CAAC,CAAC,CAC1F,CAAC;AAEF,eAAO,MAAM,oBAAoB,wGAO9B,yBAAyB,4CAa3B,CAAC;AAEF,eAAO,MAAM,eAAe,wBAE3B,CAAC"}
@@ -1,13 +1,18 @@
1
+ import { type Dispatch, type SetStateAction } from 'react';
1
2
  import type { GlobeController } from '../components';
2
- import { type Features, type StyleSet } from '../util';
3
+ import { type LatLng, type StyleSet } from '../util';
3
4
  export type TourOptions = {
5
+ running?: boolean;
4
6
  disabled?: boolean;
5
- styles?: StyleSet;
6
7
  duration?: number;
8
+ loop?: boolean;
9
+ tilt?: number;
10
+ autoRotate?: boolean;
11
+ styles?: StyleSet;
7
12
  };
8
13
  /**
9
14
  * Iterates between points.
10
15
  * Inspired by: https://observablehq.com/@mbostock/top-100-cities
11
16
  */
12
- export declare const useTour: (controller?: GlobeController | null, features?: Features, options?: TourOptions) => (() => void)[];
17
+ export declare const useTour: (controller?: GlobeController | null, points?: LatLng[], options?: TourOptions) => [boolean, Dispatch<SetStateAction<boolean>>];
13
18
  //# sourceMappingURL=useTour.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useTour.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useTour.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAE,KAAK,QAAQ,EAAkD,KAAK,QAAQ,EAAE,MAAM,SAAS,CAAC;AAMvG,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,QAAQ,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,OAAO,gBAAiB,eAAe,GAAG,IAAI,aAAa,QAAQ,YAAW,WAAW,mBAwFrG,CAAC"}
1
+ {"version":3,"file":"useTour.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useTour.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,cAAc,EAAuB,MAAM,OAAO,CAAC;AAKhF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAiB,KAAK,MAAM,EAAsB,KAAK,QAAQ,EAAE,MAAM,SAAS,CAAC;AAMxF,MAAM,MAAM,WAAW,GAAG;IACxB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,MAAM,CAAC,EAAE,QAAQ,CAAC;CACnB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,OAAO,gBACL,eAAe,GAAG,IAAI,WAC1B,MAAM,EAAE,YACR,WAAW,KACnB,CAAC,OAAO,EAAE,QAAQ,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CA0F7C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../../../src/util/debug.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,KAAK,GAAI,CAAC,aAAa,MAAM,CAAC,KAAG,CAS7C,CAAC"}
1
+ {"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../../../src/util/debug.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,KAAK,GAAI,CAAC,aAAa,MAAM,CAAC,KAAG,CAU7C,CAAC"}
@@ -2,7 +2,7 @@ import { type GeoPath, type GeoPermissibleObjects } from 'd3';
2
2
  import { type Topology } from 'topojson-specification';
3
3
  import { type LatLng } from './path';
4
4
  export type Styles = Record<string, any>;
5
- export type Style = 'water' | 'graticule' | 'land' | 'border' | 'dots' | 'point' | 'line' | 'cursor' | 'arc';
5
+ export type Style = 'background' | 'water' | 'graticule' | 'land' | 'border' | 'dots' | 'point' | 'line' | 'cursor' | 'arc';
6
6
  export type StyleSet = Partial<Record<Style, Styles>>;
7
7
  export type Features = {
8
8
  points?: LatLng[];
@@ -22,5 +22,5 @@ export declare const createLayers: (topology: Topology, features: Features, styl
22
22
  /**
23
23
  * Render layers created above.
24
24
  */
25
- export declare const renderLayers: (generator: GeoPath, layers: Layer[], scale: number) => CanvasRenderingContext2D;
25
+ export declare const renderLayers: (generator: GeoPath, layers: Layer[], scale: number, styles: StyleSet) => CanvasRenderingContext2D;
26
26
  //# sourceMappingURL=render.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"render.d.ts","sourceRoot":"","sources":["../../../../src/util/render.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,qBAAqB,EAAE,MAAM,IAAI,CAAC;AAE9D,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAEvD,OAAO,EAAE,KAAK,MAAM,EAAqB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AQ,GACR,MAAM,GACN,OAAO,GACP,MAAM,GACN,QAAQ,GACR,KAAK,CAAC;AAEV,MAAM,MAAM,QAAQ,GAAG,OAAO,CAAC,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AAEtD,MAAM,MAAM,QAAQ,GAAG;IACrB,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;IAClB,KAAK,CAAC,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CAC9C,CAAC;AAEF,MAAM,MAAM,KAAK,GAAG;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,qBAAqB,CAAC;CAC7B,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,YAAY,aAAc,QAAQ,YAAY,QAAQ,UAAU,QAAQ,KAAG,KAAK,EA2E5F,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,YAAY,cAAe,OAAO,UAAU,KAAK,EAAE,SAAc,MAAM,UAAU,QAAQ,6BA0CrG,CAAC"}
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@dxos/react-ui-geo",
3
- "version": "0.7.5-labs.ea4b4c2",
3
+ "version": "0.7.5-labs.f400bbc",
4
4
  "description": "Geo components.",
5
5
  "homepage": "https://github.com/dxos",
6
6
  "bugs": "https://github.com/dxos/issues",
7
7
  "license": "MIT",
8
8
  "author": "DXOS.org",
9
9
  "sideEffects": true,
10
+ "type": "module",
10
11
  "exports": {
11
12
  "./data": {
12
13
  "types": "./dist/types/src/data.d.ts",
@@ -44,10 +45,11 @@
44
45
  "topojson-client": "^3.1.0",
45
46
  "topojson-simplify": "^3.0.3",
46
47
  "versor": "^0.2.0",
47
- "@dxos/async": "0.7.5-labs.ea4b4c2",
48
- "@dxos/util": "0.7.5-labs.ea4b4c2",
49
- "@dxos/debug": "0.7.5-labs.ea4b4c2",
50
- "@dxos/node-std": "0.7.5-labs.ea4b4c2"
48
+ "@dxos/async": "0.7.5-labs.f400bbc",
49
+ "@dxos/debug": "0.7.5-labs.f400bbc",
50
+ "@dxos/log": "0.7.5-labs.f400bbc",
51
+ "@dxos/node-std": "0.7.5-labs.f400bbc",
52
+ "@dxos/util": "0.7.5-labs.f400bbc"
51
53
  },
52
54
  "devDependencies": {
53
55
  "@react-three/drei": "^9.99.0",
@@ -67,15 +69,15 @@
67
69
  "react": "~18.2.0",
68
70
  "react-dom": "~18.2.0",
69
71
  "three": "0.165.0",
70
- "@dxos/react-ui": "0.7.5-labs.ea4b4c2",
71
- "@dxos/react-ui-theme": "0.7.5-labs.ea4b4c2",
72
- "@dxos/storybook-utils": "0.7.5-labs.ea4b4c2"
72
+ "@dxos/react-ui": "0.7.5-labs.f400bbc",
73
+ "@dxos/react-ui-theme": "0.7.5-labs.f400bbc",
74
+ "@dxos/storybook-utils": "0.7.5-labs.f400bbc"
73
75
  },
74
76
  "peerDependencies": {
75
77
  "react": "~18.2.0",
76
78
  "react-dom": "~18.2.0",
77
- "@dxos/react-ui": "0.7.5-labs.ea4b4c2",
78
- "@dxos/react-ui-theme": "0.7.5-labs.ea4b4c2"
79
+ "@dxos/react-ui": "0.7.5-labs.f400bbc",
80
+ "@dxos/react-ui-theme": "0.7.5-labs.f400bbc"
79
81
  },
80
82
  "publishConfig": {
81
83
  "access": "public"
@@ -138,7 +138,7 @@ const Story = ({
138
138
  translation,
139
139
  rotation = [0, 0, 0],
140
140
  projection,
141
- styles = defaultStyles,
141
+ styles,
142
142
  drag = false,
143
143
  spin = false,
144
144
  tour = false,
@@ -160,10 +160,7 @@ const Story = ({
160
160
 
161
161
  // Control hooks.
162
162
  const [startSpinner, stopSpinner] = useSpinner(controller.current, { disabled: !spin });
163
- const [startTour, stopTour] = useTour(controller.current, features, {
164
- disabled: !tour,
165
- styles,
166
- });
163
+ const [_running, setRunning] = useTour(controller.current, features?.points, { disabled: !tour, styles });
167
164
  useDrag(controller.current, {
168
165
  xAxis,
169
166
  disabled: !drag,
@@ -171,7 +168,7 @@ const Story = ({
171
168
  switch (event.type) {
172
169
  case 'start': {
173
170
  stopSpinner();
174
- stopTour();
171
+ setRunning(false);
175
172
  break;
176
173
  }
177
174
  }
@@ -186,7 +183,7 @@ const Story = ({
186
183
  startSpinner();
187
184
  }
188
185
  if (tour) {
189
- startTour();
186
+ setRunning(true);
190
187
  }
191
188
  break;
192
189
  }
@@ -205,7 +202,7 @@ const Story = ({
205
202
  <Globe.Root classNames='absolute inset-0' scale={_scale} translation={translation} rotation={rotation}>
206
203
  <Globe.Canvas
207
204
  ref={controller}
208
- topology={styles.dots ? dots : topology}
205
+ topology={styles?.dots ? dots : topology}
209
206
  projection={projection}
210
207
  styles={styles}
211
208
  features={tour ? { points: features?.points ?? [] } : features}
@@ -298,15 +295,15 @@ export const Globe1 = () => {
298
295
  };
299
296
 
300
297
  export const Globe2 = () => {
301
- return <Story drag projection='transverse-mercator' scale={0.8} rotation={initialRotation} />;
298
+ return <Story drag projection='transverse-mercator' scale={0.8} rotation={initialRotation} styles={defaultStyles} />;
302
299
  };
303
300
 
304
301
  export const Globe3 = () => {
305
- return <Story drag spin scale={1.5} rotation={initialRotation} />;
302
+ return <Story drag spin scale={1.5} rotation={initialRotation} styles={defaultStyles} />;
306
303
  };
307
304
 
308
305
  export const Globe4 = () => {
309
- return <Story drag tour scale={2} rotation={initialRotation} />;
306
+ return <Story drag tour scale={2} rotation={initialRotation} styles={defaultStyles} />;
310
307
  };
311
308
 
312
309
  export const Globe5 = () => {
@@ -17,7 +17,7 @@ import React, {
17
17
  import { useResizeDetector } from 'react-resize-detector';
18
18
  import { type Topology } from 'topojson-specification';
19
19
 
20
- import { type ThemedClassName, useDynamicRef } from '@dxos/react-ui';
20
+ import { type ThemedClassName, type ThemeMode, useDynamicRef, useThemeContext } from '@dxos/react-ui';
21
21
  import { mx } from '@dxos/react-ui-theme';
22
22
 
23
23
  import {
@@ -28,7 +28,6 @@ import {
28
28
  } from '../../hooks';
29
29
  import {
30
30
  type Features,
31
- type Styles,
32
31
  type StyleSet,
33
32
  createLayers,
34
33
  geoToPosition,
@@ -38,35 +37,57 @@ import {
38
37
  } from '../../util';
39
38
  import { ZoomControls, ActionControls, type ControlProps, controlPositions } from '../Toolbar';
40
39
 
41
- // https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute
42
- const defaultStyles: Styles = {
43
- background: {
44
- fillStyle: '#111111',
45
- },
46
-
47
- water: {
48
- fillStyle: '#123E6A',
49
- },
50
-
51
- hex: {
52
- strokeStyle: 'green',
53
- fillStyle: 'gray',
54
- pointRadius: 1,
55
- },
56
-
57
- land: {
58
- fillStyle: '#032153',
59
- },
60
-
61
- line: {
62
- strokeStyle: '#111111',
40
+ /**
41
+ * https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute
42
+ */
43
+ const defaultStyles: Record<ThemeMode, StyleSet> = {
44
+ light: {
45
+ background: {
46
+ fillStyle: '#EEE',
47
+ },
48
+
49
+ water: {
50
+ fillStyle: '#555',
51
+ },
52
+
53
+ land: {
54
+ fillStyle: '#999',
55
+ },
56
+
57
+ line: {
58
+ strokeStyle: 'darkred',
59
+ },
60
+
61
+ point: {
62
+ fillStyle: '#111111',
63
+ strokeStyle: '#111111',
64
+ strokeWidth: 1,
65
+ pointRadius: 0.5,
66
+ },
63
67
  },
64
-
65
- point: {
66
- fillStyle: '#111111',
67
- strokeStyle: '#111111',
68
- strokeWidth: 1,
69
- pointRadius: 0.5,
68
+ dark: {
69
+ background: {
70
+ fillStyle: '#111111',
71
+ },
72
+
73
+ water: {
74
+ fillStyle: '#123E6A',
75
+ },
76
+
77
+ land: {
78
+ fillStyle: '#032153',
79
+ },
80
+
81
+ line: {
82
+ strokeStyle: '#111111',
83
+ },
84
+
85
+ point: {
86
+ fillStyle: '#111111',
87
+ strokeStyle: '#111111',
88
+ strokeWidth: 1,
89
+ pointRadius: 0.5,
90
+ },
70
91
  },
71
92
  };
72
93
 
@@ -125,7 +146,10 @@ type GlobeCanvasProps = {
125
146
  * https://github.com/topojson/world-atlas
126
147
  */
127
148
  const GlobeCanvas = forwardRef<GlobeController, GlobeCanvasProps>(
128
- ({ projection: _projection, topology, features, styles = defaultStyles }, forwardRef) => {
149
+ ({ projection: _projection, topology, features, styles: _styles }, forwardRef) => {
150
+ const { themeMode } = useThemeContext();
151
+ const styles = useMemo(() => _styles ?? defaultStyles[themeMode], [_styles, themeMode]);
152
+
129
153
  // Canvas.
130
154
  const [canvas, setCanvas] = useState<HTMLCanvasElement>(null);
131
155
  const canvasRef = (canvas: HTMLCanvasElement) => setCanvas(canvas);
@@ -207,7 +231,7 @@ const GlobeCanvas = forwardRef<GlobeController, GlobeCanvasProps>(
207
231
  .translate([size.width / 2 + (translation?.x ?? 0), size.height / 2 + (translation?.y ?? 0)])
208
232
  .rotate(rotation ?? [0, 0, 0]);
209
233
 
210
- renderLayers(generator, layers, scale);
234
+ renderLayers(generator, layers, scale, styles);
211
235
  });
212
236
  }
213
237
  }, [generator, size, scale, translation, rotation, layers]);