globe.gl 2.45.2 → 2.46.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/dist/globe.gl.js +97 -182
- package/dist/globe.gl.js.map +1 -1
- package/dist/globe.gl.min.js +2 -2
- package/dist/globe.gl.mjs +9 -2
- package/package.json +3 -3
package/dist/globe.gl.mjs
CHANGED
|
@@ -411,6 +411,11 @@ var globe = Kapsule({
|
|
|
411
411
|
return finalGeoCoords[p] = +finalGeoCoords[p];
|
|
412
412
|
}); // coerce coords to number
|
|
413
413
|
|
|
414
|
+
if (state.povTween) {
|
|
415
|
+
// cancel any ongoing pov animation
|
|
416
|
+
state.povTween.end();
|
|
417
|
+
state.povTween = undefined;
|
|
418
|
+
}
|
|
414
419
|
if (!transitionDuration) {
|
|
415
420
|
// no animation
|
|
416
421
|
setCameraPos(finalGeoCoords);
|
|
@@ -418,7 +423,8 @@ var globe = Kapsule({
|
|
|
418
423
|
// Avoid rotating more than 180deg longitude
|
|
419
424
|
while (curGeoCoords.lng - finalGeoCoords.lng > 180) curGeoCoords.lng -= 360;
|
|
420
425
|
while (curGeoCoords.lng - finalGeoCoords.lng < -180) curGeoCoords.lng += 360;
|
|
421
|
-
state.tweenGroup.add(new Tween(curGeoCoords).to(finalGeoCoords, transitionDuration).easing(Easing.Cubic.InOut).onUpdate(setCameraPos).onComplete(function () {
|
|
426
|
+
state.tweenGroup.add(state.povTween = new Tween(curGeoCoords).to(finalGeoCoords, transitionDuration).easing(Easing.Cubic.InOut).onUpdate(setCameraPos).onComplete(function () {
|
|
427
|
+
state.povTween = undefined;
|
|
422
428
|
state.tweenGroup.remove(this);
|
|
423
429
|
}).start());
|
|
424
430
|
}
|
|
@@ -477,7 +483,6 @@ var globe = Kapsule({
|
|
|
477
483
|
},
|
|
478
484
|
// Expose controls
|
|
479
485
|
_destructor: function _destructor(state) {
|
|
480
|
-
state.globe._destructor();
|
|
481
486
|
this.pauseAnimation();
|
|
482
487
|
this.pointsData([]);
|
|
483
488
|
this.arcsData([]);
|
|
@@ -492,6 +497,8 @@ var globe = Kapsule({
|
|
|
492
497
|
this.htmlElementsData([]);
|
|
493
498
|
this.objectsData([]);
|
|
494
499
|
this.customLayerData([]);
|
|
500
|
+
state.globe._destructor();
|
|
501
|
+
state.renderObjs._destructor();
|
|
495
502
|
}
|
|
496
503
|
}, linkedGlobeMethods), linkedRenderObjsMethods),
|
|
497
504
|
stateInit: function stateInit(_ref6) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "globe.gl",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.46.0",
|
|
4
4
|
"description": "UI component for Globe Data Visualization using ThreeJS/WebGL",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"unpkg": "dist/globe.gl.min.js",
|
|
@@ -51,9 +51,9 @@
|
|
|
51
51
|
"@tweenjs/tween.js": "18 - 25",
|
|
52
52
|
"accessor-fn": "1",
|
|
53
53
|
"kapsule": "^1.16",
|
|
54
|
-
"three": ">=0.
|
|
54
|
+
"three": ">=0.179 <1",
|
|
55
55
|
"three-globe": "^2.45",
|
|
56
|
-
"three-render-objects": "^1.
|
|
56
|
+
"three-render-objects": "^1.41"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
59
|
"@babel/core": "^7.29.0",
|