globe.gl 2.41.1 → 2.41.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/globe.gl.d.ts +2 -1
- package/dist/globe.gl.js +150 -64
- package/dist/globe.gl.js.map +1 -1
- package/dist/globe.gl.min.js +2 -2
- package/example/airline-routes/highlight-links.html +2 -2
- package/example/airline-routes/us-international-outbound.html +2 -2
- package/example/basic/index.html +2 -2
- package/example/choropleth-countries/index.html +3 -3
- package/example/clouds/index.html +3 -3
- package/example/countries-population/index.html +2 -2
- package/example/custom-globe-styling/index.html +5 -5
- package/example/custom-layer/index.html +3 -3
- package/example/day-night-cycle/index.html +4 -3
- package/example/earth-shield/index.html +2 -2
- package/example/earthquakes/index.html +2 -2
- package/example/emit-arcs-on-click/index.html +2 -2
- package/example/heatmap/index.html +2 -2
- package/example/hexed-polygons/index.html +2 -2
- package/example/hollow-globe/index.html +2 -2
- package/example/html-markers/index.html +2 -2
- package/example/moon-landing-sites/index.html +2 -2
- package/example/population-heatmap/index.html +2 -2
- package/example/random-arcs/index.html +2 -2
- package/example/random-paths/index.html +3 -3
- package/example/random-rings/index.html +2 -2
- package/example/satellites/index.html +2 -2
- package/example/solar-terminator/index.html +2 -2
- package/example/submarine-cables/index.html +4 -4
- package/example/tile-engine/index.html +1 -1
- package/example/tiles/index.html +1 -1
- package/example/volcanoes/index.html +3 -3
- package/example/volcanoes-heatmap/index.html +2 -2
- package/example/world-cities/index.html +3 -3
- package/example/world-population/index.html +4 -4
- package/package.json +6 -6
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
const OPACITY = 0.3;
|
|
18
18
|
|
|
19
19
|
const myGlobe = new Globe(document.getElementById('globeViz'))
|
|
20
|
-
.globeImageUrl('//
|
|
20
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
21
21
|
|
|
22
22
|
.arcLabel(d => `${d.airline}: ${d.srcIata} → ${d.dstIata}`)
|
|
23
23
|
.arcStartLat(d => d.srcAirport.lat)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
|
|
18
18
|
const myGlobe = new Globe(document.getElementById('globeViz'))
|
|
19
19
|
|
|
20
|
-
.globeImageUrl('//
|
|
20
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
21
21
|
.pointOfView({ lat: 39.6, lng: -98.5, altitude: 2 }) // aim at continental US centroid
|
|
22
22
|
|
|
23
23
|
.arcLabel(d => `${d.airline}: ${d.srcIata} → ${d.dstIata}`)
|
package/example/basic/index.html
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
}));
|
|
20
20
|
|
|
21
21
|
new Globe(document.getElementById('globeViz'))
|
|
22
|
-
.globeImageUrl('//
|
|
22
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
23
23
|
.pointsData(gData)
|
|
24
24
|
.pointAltitude('size')
|
|
25
25
|
.pointColor('color');
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
colorScale.domain([0, maxVal]);
|
|
24
24
|
|
|
25
25
|
const world = new Globe(document.getElementById('globeViz'))
|
|
26
|
-
.globeImageUrl('//
|
|
27
|
-
.backgroundImageUrl('//
|
|
26
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
27
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png')
|
|
28
28
|
.lineHoverPrecision(0)
|
|
29
29
|
.polygonsData(countries.features.filter(d => d.properties.ISO_A2 !== 'AQ'))
|
|
30
30
|
.polygonAltitude(0.06)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
import * as THREE from 'https://esm.sh/three';
|
|
13
13
|
|
|
14
14
|
const world = new Globe(document.getElementById('globeViz'), { animateIn: false })
|
|
15
|
-
.globeImageUrl('//
|
|
16
|
-
.bumpImageUrl('//
|
|
15
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-blue-marble.jpg')
|
|
16
|
+
.bumpImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-topology.png');
|
|
17
17
|
|
|
18
18
|
// Auto-rotate
|
|
19
19
|
world.controls().autoRotate = true;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<script>
|
|
12
12
|
const world = new Globe(document.getElementById('globeViz'))
|
|
13
|
-
.globeImageUrl('//
|
|
13
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
14
14
|
.pointOfView({ altitude: 4 }, 5000)
|
|
15
15
|
.polygonCapColor(feat => 'rgba(200, 0, 0, 0.6)')
|
|
16
16
|
.polygonSideColor(() => 'rgba(0, 100, 0, 0.05)')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -12,14 +12,14 @@
|
|
|
12
12
|
import * as THREE from 'https://esm.sh/three';
|
|
13
13
|
|
|
14
14
|
const world = new Globe(document.getElementById('globeViz'))
|
|
15
|
-
.globeImageUrl('//
|
|
16
|
-
.bumpImageUrl('//
|
|
17
|
-
.backgroundImageUrl('//
|
|
15
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-blue-marble.jpg')
|
|
16
|
+
.bumpImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-topology.png')
|
|
17
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png');
|
|
18
18
|
|
|
19
19
|
// custom globe material
|
|
20
20
|
const globeMaterial = world.globeMaterial();
|
|
21
21
|
globeMaterial.bumpScale = 10;
|
|
22
|
-
new THREE.TextureLoader().load('//
|
|
22
|
+
new THREE.TextureLoader().load('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-water.png', texture => {
|
|
23
23
|
globeMaterial.specularMap = texture;
|
|
24
24
|
globeMaterial.specular = new THREE.Color('grey');
|
|
25
25
|
globeMaterial.shininess = 15;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
}));
|
|
23
23
|
|
|
24
24
|
const world = new Globe(document.getElementById('globeViz'))
|
|
25
|
-
.globeImageUrl('//
|
|
26
|
-
.bumpImageUrl('//
|
|
25
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-blue-marble.jpg')
|
|
26
|
+
.bumpImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-topology.png')
|
|
27
27
|
.pointOfView({ altitude: 3.5 })
|
|
28
28
|
.customLayerData(gData)
|
|
29
29
|
.customThreeObject(d => new THREE.Mesh(
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
}
|
|
12
12
|
</style>
|
|
13
13
|
|
|
14
|
-
<script src="//
|
|
14
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
15
15
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
16
16
|
</head>
|
|
17
17
|
|
|
@@ -95,8 +95,8 @@
|
|
|
95
95
|
const world = new Globe(document.getElementById('globeViz'));
|
|
96
96
|
|
|
97
97
|
Promise.all([
|
|
98
|
-
new TextureLoader().loadAsync('//
|
|
99
|
-
new TextureLoader().loadAsync('//
|
|
98
|
+
new TextureLoader().loadAsync('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-day.jpg'),
|
|
99
|
+
new TextureLoader().loadAsync('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
100
100
|
]).then(([dayTexture, nightTexture]) => {
|
|
101
101
|
const material = new ShaderMaterial({
|
|
102
102
|
uniforms: {
|
|
@@ -110,6 +110,7 @@
|
|
|
110
110
|
});
|
|
111
111
|
|
|
112
112
|
world.globeMaterial(material)
|
|
113
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png')
|
|
113
114
|
// Update globe rotation on shader
|
|
114
115
|
.onZoom(({ lng, lat }) => material.uniforms.globeRotation.value.set(lng, lat));
|
|
115
116
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
const shieldRing = { lat: 90, lng: 0 };
|
|
13
13
|
|
|
14
14
|
const globe = new Globe(document.getElementById('globeViz'))
|
|
15
|
-
.globeImageUrl('//
|
|
15
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
16
16
|
.ringsData([shieldRing])
|
|
17
17
|
.ringAltitude(0.25)
|
|
18
18
|
.ringColor(() => 'lightblue')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
.clamp(true);
|
|
18
18
|
|
|
19
19
|
const myGlobe = new Globe(document.getElementById('globeViz'))
|
|
20
|
-
.globeImageUrl('//
|
|
20
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
21
21
|
.hexBinPointLat(d => d.geometry.coordinates[1])
|
|
22
22
|
.hexBinPointLng(d => d.geometry.coordinates[0])
|
|
23
23
|
.hexBinPointWeight(d => d.properties.mag)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
const RING_PROPAGATION_SPEED = 5; // deg/sec
|
|
17
17
|
|
|
18
18
|
const globe = new Globe(document.getElementById('globeViz'))
|
|
19
|
-
.globeImageUrl('//
|
|
19
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
20
20
|
.arcColor(() => 'darkOrange')
|
|
21
21
|
.onGlobeClick(emitArc)
|
|
22
22
|
.arcDashLength(ARC_REL_LEN)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
}));
|
|
19
19
|
|
|
20
20
|
const world = new Globe(document.getElementById('globeViz'))
|
|
21
|
-
.globeImageUrl('//
|
|
21
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
22
22
|
.heatmapsData([gData])
|
|
23
23
|
.heatmapPointLat('lat')
|
|
24
24
|
.heatmapPointLng('lng')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
fetch('../datasets/ne_110m_admin_0_countries.geojson').then(res => res.json()).then(countries =>
|
|
13
13
|
{
|
|
14
14
|
const world = new Globe(document.getElementById('globeViz'))
|
|
15
|
-
.globeImageUrl('//
|
|
15
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
16
16
|
.hexPolygonsData(countries.features)
|
|
17
17
|
.hexPolygonResolution(3)
|
|
18
18
|
.hexPolygonMargin(0.3)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
.showGlobe(false)
|
|
18
18
|
.showAtmosphere(false);
|
|
19
19
|
|
|
20
|
-
fetch('//
|
|
20
|
+
fetch('//cdn.jsdelivr.net/npm/world-atlas/land-110m.json').then(res => res.json())
|
|
21
21
|
.then(landTopo => {
|
|
22
22
|
world
|
|
23
23
|
.polygonsData(topojson.feature(landTopo, landTopo.objects.land).features)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
}));
|
|
25
25
|
|
|
26
26
|
new Globe(document.getElementById('globeViz'))
|
|
27
|
-
.globeImageUrl('//
|
|
27
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
28
28
|
.htmlElementsData(gData)
|
|
29
29
|
.htmlElement(d => {
|
|
30
30
|
const el = document.createElement('div');
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
const moon = new Globe(document.getElementById('globeViz'))
|
|
19
19
|
.globeImageUrl('./lunar_surface.jpg')
|
|
20
20
|
.bumpImageUrl('./lunar_bumpmap.jpg')
|
|
21
|
-
.backgroundImageUrl('//
|
|
21
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png')
|
|
22
22
|
.showGraticules(true)
|
|
23
23
|
.showAtmosphere(false) // moon has no atmosphere
|
|
24
24
|
.labelText('label')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
import { csvParse } from 'https://esm.sh/d3-dsv';
|
|
13
13
|
|
|
14
14
|
const world = new Globe(document.getElementById('globeViz'))
|
|
15
|
-
.globeImageUrl('//
|
|
15
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
16
16
|
.heatmapPointLat('lat')
|
|
17
17
|
.heatmapPointLng('lng')
|
|
18
18
|
.heatmapPointWeight('pop')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
}));
|
|
21
21
|
|
|
22
22
|
new Globe(document.getElementById('globeViz'))
|
|
23
|
-
.globeImageUrl('//
|
|
23
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
24
24
|
.arcsData(arcsData)
|
|
25
25
|
.arcColor('color')
|
|
26
26
|
.arcDashLength(() => Math.random())
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
});
|
|
31
31
|
|
|
32
32
|
const globe = new Globe(document.getElementById('globeViz'))
|
|
33
|
-
.globeImageUrl('//
|
|
34
|
-
.bumpImageUrl('//
|
|
33
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
34
|
+
.bumpImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-topology.png')
|
|
35
35
|
.pathsData(gData)
|
|
36
36
|
.pathColor(() => ['rgba(0,0,255,0.6)', 'rgba(255,0,0,0.6)'])
|
|
37
37
|
.pathDashLength(0.01)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
const colorInterpolator = t => `rgba(255,100,50,${Math.sqrt(1-t)})`;
|
|
23
23
|
|
|
24
24
|
const globe = new Globe(document.getElementById('globeViz'))
|
|
25
|
-
.globeImageUrl('//
|
|
25
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
26
26
|
.ringsData(gData)
|
|
27
27
|
.ringColor(() => colorInterpolator)
|
|
28
28
|
.ringMaxRadius('maxR')
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
}
|
|
16
16
|
</style>
|
|
17
17
|
|
|
18
|
-
<script src="//
|
|
18
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
19
19
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
20
20
|
</head>
|
|
21
21
|
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
const timeLogger = document.getElementById('time-log');
|
|
33
33
|
|
|
34
34
|
const world = new Globe(document.getElementById('chart'))
|
|
35
|
-
.globeImageUrl('//
|
|
35
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-blue-marble.jpg')
|
|
36
36
|
.particleLat('lat')
|
|
37
37
|
.particleLng('lng')
|
|
38
38
|
.particleAltitude('alt')
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
}
|
|
12
12
|
</style>
|
|
13
13
|
|
|
14
|
-
<script src="//
|
|
14
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
15
15
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
16
16
|
</head>
|
|
17
17
|
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
const timeEl = document.getElementById('time');
|
|
38
38
|
|
|
39
39
|
const world = new Globe(document.getElementById('globeViz'))
|
|
40
|
-
.globeImageUrl('//
|
|
40
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
41
41
|
.tilesData([solarTile])
|
|
42
42
|
.tileLng(d => d.pos[0])
|
|
43
43
|
.tileLat(d => d.pos[1])
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
|
|
11
11
|
<script>
|
|
12
12
|
const globe = new Globe(document.getElementById('globeViz'))
|
|
13
|
-
.globeImageUrl('//
|
|
14
|
-
.bumpImageUrl('//
|
|
15
|
-
.backgroundImageUrl('//
|
|
13
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-dark.jpg')
|
|
14
|
+
.bumpImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-topology.png')
|
|
15
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png');
|
|
16
16
|
|
|
17
17
|
// from https://www.submarinecablemap.com
|
|
18
18
|
fetch('//http-proxy.vastur.com?url=https://www.submarinecablemap.com/api/v3/cable/cable-geo.json')
|
package/example/tiles/index.html
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
`;
|
|
27
27
|
|
|
28
28
|
const myGlobe = new Globe(document.getElementById('globeViz'))
|
|
29
|
-
.globeImageUrl('//
|
|
30
|
-
.backgroundImageUrl('//
|
|
29
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
30
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png')
|
|
31
31
|
.pointLat('lat')
|
|
32
32
|
.pointLng('lon')
|
|
33
33
|
.pointAltitude(getAlt)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!-- <script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<script>
|
|
12
12
|
const world = new Globe(document.getElementById('globeViz'))
|
|
13
|
-
.globeImageUrl('//
|
|
13
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-blue-marble.jpg')
|
|
14
14
|
.heatmapPointLat('lat')
|
|
15
15
|
.heatmapPointLng('lon')
|
|
16
16
|
.heatmapPointWeight(d => d.elevation * 5e-5)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
<script>
|
|
12
12
|
fetch('../datasets/ne_110m_populated_places_simple.geojson').then(res => res.json()).then(places => {
|
|
13
13
|
new Globe(document.getElementById('globeViz'))
|
|
14
|
-
.globeImageUrl('//
|
|
15
|
-
.backgroundImageUrl('//
|
|
14
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
15
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png')
|
|
16
16
|
.labelsData(places.features)
|
|
17
17
|
.labelLat(d => d.properties.latitude)
|
|
18
18
|
.labelLng(d => d.properties.longitude)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<head>
|
|
2
2
|
<style> body { margin: 0; } </style>
|
|
3
3
|
|
|
4
|
-
<script src="//
|
|
4
|
+
<script src="//cdn.jsdelivr.net/npm/globe.gl"></script>
|
|
5
5
|
<!--<script src="../../dist/globe.gl.js"></script>-->
|
|
6
6
|
</head>
|
|
7
7
|
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
.domain([0, 1e7]);
|
|
18
18
|
|
|
19
19
|
const world = new Globe(document.getElementById('globeViz'))
|
|
20
|
-
.globeImageUrl('//
|
|
21
|
-
.bumpImageUrl('//
|
|
22
|
-
.backgroundImageUrl('//
|
|
20
|
+
.globeImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-night.jpg')
|
|
21
|
+
.bumpImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/earth-topology.png')
|
|
22
|
+
.backgroundImageUrl('//cdn.jsdelivr.net/npm/three-globe/example/img/night-sky.png')
|
|
23
23
|
.hexBinPointWeight('pop')
|
|
24
24
|
.hexAltitude(d => d.sumWeight * 6e-8)
|
|
25
25
|
.hexBinResolution(4)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "globe.gl",
|
|
3
|
-
"version": "2.41.
|
|
3
|
+
"version": "2.41.3",
|
|
4
4
|
"description": "UI component for Globe Data Visualization using ThreeJS/WebGL",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"unpkg": "dist/globe.gl.min.js",
|
|
@@ -56,16 +56,16 @@
|
|
|
56
56
|
"three-render-objects": "^1.39"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
-
"@babel/core": "^7.26.
|
|
59
|
+
"@babel/core": "^7.26.10",
|
|
60
60
|
"@babel/preset-env": "^7.26.9",
|
|
61
61
|
"@rollup/plugin-babel": "^6.0.4",
|
|
62
|
-
"@rollup/plugin-commonjs": "^28.0.
|
|
63
|
-
"@rollup/plugin-node-resolve": "^16.0.
|
|
62
|
+
"@rollup/plugin-commonjs": "^28.0.3",
|
|
63
|
+
"@rollup/plugin-node-resolve": "^16.0.1",
|
|
64
64
|
"@rollup/plugin-terser": "^0.4.4",
|
|
65
65
|
"postcss": "^8.5.3",
|
|
66
66
|
"rimraf": "^6.0.1",
|
|
67
|
-
"rollup": "^4.
|
|
68
|
-
"rollup-plugin-dts": "^6.
|
|
67
|
+
"rollup": "^4.37.0",
|
|
68
|
+
"rollup-plugin-dts": "^6.2.1",
|
|
69
69
|
"rollup-plugin-postcss": "^4.0.2",
|
|
70
70
|
"typescript": "^5.8.2"
|
|
71
71
|
},
|