Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Commit

Permalink
chore: update cesium and resium (#79)
Browse files Browse the repository at this point in the history
  • Loading branch information
rot1024 committed Sep 13, 2021
1 parent 048c4b9 commit c416019
Show file tree
Hide file tree
Showing 4 changed files with 2,602 additions and 2,935 deletions.
8 changes: 4 additions & 4 deletions package.json
Expand Up @@ -161,7 +161,7 @@
"apollo-upload-client": "^14.1.3",
"array-move": "^3.0.1",
"axios": "^0.21.1",
"cesium": "^1.84.0",
"cesium": "^1.85.0",
"core-js": "^3.8.3",
"date-fns": "^2.17.0",
"detect-browser": "^5.2.0",
Expand All @@ -177,12 +177,12 @@
"quickjs-emscripten": "^0.13.0",
"quickjs-emscripten-sync": "^1.1.0",
"rc-slider": "9.7.1",
"react": "^17.0.1",
"react": "^17.0.2",
"react-accessible-accordion": "^3.3.4",
"react-colorful": "^5.3.0",
"react-dnd": "^11.1.3",
"react-dnd-html5-backend": "^11.1.3",
"react-dom": "^17.0.1",
"react-dom": "^17.0.2",
"react-dropzone": "^11.3.0",
"react-ga": "^3.3.0",
"react-intl": "^5.12.2",
Expand All @@ -196,7 +196,7 @@
"react-use": "^17.1.1",
"regenerator-runtime": "^0.13.7",
"remark-gfm": "^1.0.0",
"resium": "^1.13.1",
"resium": "^1.14.2",
"tinycolor2": "^1.4.2",
"ts-easing": "^0.2.0",
"use-callback-ref": "^1.2.5",
Expand Down
4 changes: 2 additions & 2 deletions src/components/molecules/Visualizer/Engine/Cesium/hooks.ts
Expand Up @@ -120,9 +120,9 @@ export default ({
}, [cesium, selectedPrimitiveId]);

const selectViewerEntity = useCallback(
(ev: { position: Cartesian2 }) => {
(ev: { position: Cartesian2 } | { startPosition: Cartesian2; endPosition: Cartesian2 }) => {
const viewer = cesium.current?.cesiumElement;
if (!viewer || viewer.isDestroyed()) return;
if (!viewer || viewer.isDestroyed() || !("position" in ev)) return;

let target = viewer.scene.pick(ev.position);
if (target && target.id instanceof Entity) {
Expand Down
7 changes: 2 additions & 5 deletions src/components/molecules/Visualizer/Engine/Cesium/index.tsx
Expand Up @@ -103,11 +103,8 @@ const Cesium: React.ForwardRefRenderFunction<EngineRef, EngineProps> = (
atmosphereSaturationShift={property?.atmosphere?.surturation_shift}
atmosphereHueShift={property?.atmosphere?.hue_shift}
atmosphereBrightnessShift={property?.atmosphere?.brightness_shift}
{...{
// TODO: update resium
terrainExaggeration: property?.default?.terrainExaggeration,
terrainExaggerationRelativeHeight: property?.default?.terrainExaggerationRelativeHeight,
}}
terrainExaggeration={property?.default?.terrainExaggeration}
terrainExaggerationRelativeHeight={property?.default?.terrainExaggerationRelativeHeight}
/>
{imageryLayers?.map(([id, im, min, max]) => (
<ImageryLayer
Expand Down

0 comments on commit c416019

Please sign in to comment.