diff --git a/src/scripts/components/globe/globe.tsx b/src/scripts/components/globe/globe.tsx index 51d97e649..cf12c36ea 100644 --- a/src/scripts/components/globe/globe.tsx +++ b/src/scripts/components/globe/globe.tsx @@ -1,14 +1,4 @@ import React, {FunctionComponent, useRef, useEffect, useState} from 'react'; - -import { - getGlobeView, - setGlobeView, - flyToGlobeView -} from '../../libs/get-globe-view'; - -import {GlobeView} from '../../types/globe-view'; -import {GlobeProjection} from '../../types/globe-projection'; - import 'cesium/Build/Cesium/Widgets/widgets.css'; import { Viewer, @@ -18,18 +8,28 @@ import { TileMapServiceImageryProvider, UrlTemplateImageryProvider, TextureMinificationFilter, - TextureMagnificationFilter, - buildModuleUrl + TextureMagnificationFilter } from 'cesium'; +import { + getGlobeView, + setGlobeView, + flyToGlobeView +} from '../../libs/get-globe-view'; + +import {GlobeView} from '../../types/globe-view'; +import {GlobeProjection} from '../../types/globe-projection'; +import config from '../../config/main'; + import {GlobeProjectionState} from '../../types/globe-projection-state'; import styles from './globe.styl'; // create default imagery provider -const tileUrl = buildModuleUrl('Assets/Textures/NaturalEarthII'); const imageryProvider = new TileMapServiceImageryProvider({ - url: tileUrl + url: config.basemapTilesUrl, + fileExtension: 'png', + maximumLevel: 4 }); const cesiumOptions = { diff --git a/src/scripts/config/main.ts b/src/scripts/config/main.ts index dbb6d0185..ddab869bc 100644 --- a/src/scripts/config/main.ts +++ b/src/scripts/config/main.ts @@ -36,6 +36,8 @@ export default { stories: `https://storage.googleapis.com/esa-cfs-storage/${version}/stories/stories-{lang}.json`, story: `https://storage.googleapis.com/esa-cfs-storage/${version}/stories/{id}/{id}-{lang}.json` }, + basemapTilesUrl: + 'https://storage.googleapis.com/esa-cfs-tiles/0.5.1/basemap/', globe: globeState, share: { facebook: