mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 16:22:20 +00:00
Draw local infrastructure on either globe from one retained dataset
This commit is contained in:
1 parent
868d061856
commit
c1d829ef51
12 files changed
+900
-6
No files matched your search
@@ -6,10 +6,10 @@ import { INFRASTRUCTURE_DATA_URLS } from '../sources/infrastructureData.js';
|
||||
* @param {object} services Caller-owned context, overlay and render operations.
|
||||
* @returns {object[]} Datacenters then dams, with stable standalone identities.
|
||||
*/
|
||||
export function createInfrastructureLayers(services) {
|
||||
export function createInfrastructureLayers(services, createLayer = createLocalGeoJsonLayer) {
|
||||
const datacentersUrl = INFRASTRUCTURE_DATA_URLS['local-datacenters'];
|
||||
const damsUrl = INFRASTRUCTURE_DATA_URLS['local-dams'];
|
||||
const datacenters = createLocalGeoJsonLayer(
|
||||
const datacenters = createLayer(
|
||||
{
|
||||
id: 'local-datacenters',
|
||||
url: datacentersUrl,
|
||||
@@ -25,7 +25,7 @@ export function createInfrastructureLayers(services) {
|
||||
services,
|
||||
);
|
||||
|
||||
const dams = createLocalGeoJsonLayer(
|
||||
const dams = createLayer(
|
||||
{
|
||||
id: 'local-dams',
|
||||
url: damsUrl,
|
||||
|
||||
Reference in new issue
Block a user