globe.gl 2.31.0 → 2.32.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/dist/globe.gl.d.ts +3 -1
- package/dist/globe.gl.js +36 -25
- package/dist/globe.gl.js.map +1 -1
- package/dist/globe.gl.min.js +2 -2
- package/dist/globe.gl.mjs +4 -5
- package/example/custom-globe-styling/index.html +2 -4
- package/package.json +2 -2
package/dist/globe.gl.mjs
CHANGED
|
@@ -191,7 +191,7 @@ var bindRenderObjs = linkKapsule('renderObjs', ThreeRenderObjects);
|
|
|
191
191
|
var linkedRenderObjsProps = Object.assign.apply(Object, _toConsumableArray(['width', 'height', 'backgroundColor', 'backgroundImageUrl', 'enablePointerInteraction'].map(function (p) {
|
|
192
192
|
return _defineProperty({}, p, bindRenderObjs.linkProp(p));
|
|
193
193
|
})));
|
|
194
|
-
var linkedRenderObjsMethods = Object.assign.apply(Object, _toConsumableArray(['postProcessingComposer'].map(function (p) {
|
|
194
|
+
var linkedRenderObjsMethods = Object.assign.apply(Object, _toConsumableArray(['lights', 'postProcessingComposer'].map(function (p) {
|
|
195
195
|
return _defineProperty({}, p, bindRenderObjs.linkMethod(p));
|
|
196
196
|
})));
|
|
197
197
|
|
|
@@ -495,7 +495,8 @@ var globe = Kapsule({
|
|
|
495
495
|
rendererConfig: rendererConfig,
|
|
496
496
|
waitForLoadComplete: waitForGlobeReady,
|
|
497
497
|
extraRenderers: [new THREE.CSS2DRenderer()] // Used in HTML elements layer
|
|
498
|
-
}).skyRadius(globe.getGlobeRadius() * 500).showNavInfo(false)
|
|
498
|
+
}).skyRadius(globe.getGlobeRadius() * 500).showNavInfo(false).objects([globe]) // Populate scene
|
|
499
|
+
.lights([new THREE.AmbientLight(0xcccccc, Math.PI), new THREE.DirectionalLight(0xffffff, 0.6 * Math.PI)])
|
|
499
500
|
};
|
|
500
501
|
},
|
|
501
502
|
init: function init(domNode, state) {
|
|
@@ -586,9 +587,7 @@ var globe = Kapsule({
|
|
|
586
587
|
}
|
|
587
588
|
};
|
|
588
589
|
state.renderObjs.renderer().useLegacyLights = false; // force behavior of three < 155
|
|
589
|
-
state.renderObjs.
|
|
590
|
-
// Populate scene
|
|
591
|
-
new THREE.AmbientLight(0xcccccc, Math.PI), new THREE.DirectionalLight(0xffffff, 0.6 * Math.PI), state.globe]).hoverOrderComparator(function (a, b) {
|
|
590
|
+
state.renderObjs.hoverOrderComparator(function (a, b) {
|
|
592
591
|
var aObj = getGlobeObj(a);
|
|
593
592
|
var bObj = getGlobeObj(b);
|
|
594
593
|
|
|
@@ -27,9 +27,7 @@
|
|
|
27
27
|
globeMaterial.shininess = 15;
|
|
28
28
|
});
|
|
29
29
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
directionalLight && directionalLight.position.set(1, 1, 1); // change light position to see the specularMap's effect
|
|
33
|
-
});
|
|
30
|
+
const directionalLight = world.lights().find(light => light.type === 'DirectionalLight');
|
|
31
|
+
directionalLight && directionalLight.position.set(1, 1, 1); // change light position to see the specularMap's effect
|
|
34
32
|
</script>
|
|
35
33
|
</body>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "globe.gl",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.32.1",
|
|
4
4
|
"description": "UI component for Globe Data Visualization using ThreeJS/WebGL",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"unpkg": "dist/globe.gl.min.js",
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
"kapsule": "1",
|
|
54
54
|
"three": ">=0.118 <1",
|
|
55
55
|
"three-globe": "^2.30",
|
|
56
|
-
"three-render-objects": "^1.
|
|
56
|
+
"three-render-objects": "^1.29"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
59
|
"@babel/core": "^7.23.2",
|