2022-11-18 08:51:46 -05:00
|
|
|
import * as React from 'react';
|
|
|
|
import { TileLayer } from 'react-leaflet';
|
2022-12-06 03:03:06 -05:00
|
|
|
import { LayerEnablementState } from '../../config/map-config';
|
2022-11-18 11:28:54 -05:00
|
|
|
import { BuildingBaseLayer } from './building-base-layer';
|
2022-12-06 21:44:59 -05:00
|
|
|
import { useDisplayPreferences } from '../../displayPreferences-context';
|
2022-11-18 08:51:46 -05:00
|
|
|
|
2022-12-06 21:44:59 -05:00
|
|
|
export function HistoricDataLayer({}) {
|
|
|
|
const { historicData } = useDisplayPreferences();
|
|
|
|
if(historicData == "enabled") {
|
2022-11-18 11:28:54 -05:00
|
|
|
return <><TileLayer
|
2022-11-18 11:26:35 -05:00
|
|
|
url="https://mapseries-tilesets.s3.amazonaws.com/london_1890s/{z}/{x}/{y}.png"
|
|
|
|
attribution='© CC BY 4.0 - Reproduced with the permission of the <a href="https://maps.nls.uk/">National Library of Scotland</a>'
|
2022-11-18 11:28:54 -05:00
|
|
|
/><BuildingBaseLayer theme="night_outlines" /></>
|
2022-11-18 08:51:46 -05:00
|
|
|
} else {
|
|
|
|
return null;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|