forked from MapComplete/MapComplete
refactoring(maplibre): add RasterLayer info, add background switch, add default global layers
This commit is contained in:
parent
703d561324
commit
4f2bbf4b54
14 changed files with 1103 additions and 472 deletions
18
UI/Map/RasterLayerPicker.svelte
Normal file
18
UI/Map/RasterLayerPicker.svelte
Normal file
|
@ -0,0 +1,18 @@
|
|||
<script lang="ts">
|
||||
import type { Readable, Writable } from "svelte/store";
|
||||
import type { RasterLayerPolygon } from "../../Models/RasterLayers";
|
||||
|
||||
/***
|
||||
* Chooses a background-layer out of available options
|
||||
*/
|
||||
export let availableLayers: Readable<RasterLayerPolygon[]>
|
||||
export let value: Writable<RasterLayerPolygon>
|
||||
</script>
|
||||
|
||||
<select bind:value={$value}>
|
||||
{#each $availableLayers as availableLayer }
|
||||
<option value={availableLayer}>
|
||||
{availableLayer.properties.name}
|
||||
</option>
|
||||
{/each}
|
||||
</select>
|
Loading…
Add table
Add a link
Reference in a new issue