diff --git a/src/modules/geoportal/v2/basemap-switcher.tsx b/src/modules/geoportal/v2/basemap-switcher.tsx index 79df8ef..3e1c5f3 100644 --- a/src/modules/geoportal/v2/basemap-switcher.tsx +++ b/src/modules/geoportal/v2/basemap-switcher.tsx @@ -8,8 +8,15 @@ import { latestWaybackRelease, type WaybackRelease, } from "./wayback-catalog"; +import { SENTINEL_YEARS, type SentinelYear } from "./sentinel-catalog"; -export type BasemapId = "liberty" | "dark" | "satellite" | "google" | "wayback"; +export type BasemapId = + | "liberty" + | "dark" + | "satellite" + | "google" + | "wayback" + | "sentinel"; const OPTIONS: Array<{ id: BasemapId; label: string }> = [ { id: "liberty", label: "Liberty" }, @@ -17,6 +24,7 @@ const OPTIONS: Array<{ id: BasemapId; label: string }> = [ { id: "satellite", label: "Satelit" }, { id: "google", label: "Google" }, { id: "wayback", label: "Istoric" }, + { id: "sentinel", label: "S2" }, ]; interface Props { @@ -26,6 +34,10 @@ interface Props { waybackReleaseId?: string | null; /** Fired when the user picks a different Wayback date. */ onWaybackReleaseChange?: (release: WaybackRelease) => void; + /** Selected Sentinel-2 cloudless year (only meaningful when value=sentinel). */ + sentinelYear?: string | null; + /** Fired when the user picks a different Sentinel-2 year. */ + onSentinelYearChange?: (year: SentinelYear) => void; } export function BasemapSwitcher({ @@ -33,6 +45,8 @@ export function BasemapSwitcher({ onChange, waybackReleaseId, onWaybackReleaseChange, + sentinelYear, + onSentinelYearChange, }: Props) { const [releases, setReleases] = useState(null); const [loading, setLoading] = useState(false); @@ -80,6 +94,36 @@ export function BasemapSwitcher({ + {value === "sentinel" && ( +
+ + +

+ Mozaic anual cloud-free Sentinel-2 (rezoluție ~10 m). Bun + pentru schimbări rurale large-scale (defrișări, hale, + sere). Nu vezi case sau detalii fine. © EOX / Copernicus. + Uz comercial: cloudless.eox.at. +

+
+ )} + {value === "wayback" && (