fix: more z-index issue (#18493)

This commit is contained in:
Alex 2025-05-22 15:17:14 -05:00 committed by GitHub
parent 15877ddf1f
commit 065f7c7d5d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 16 additions and 11 deletions

View file

@ -54,6 +54,7 @@
onClickPoint?: ({ lat, lng }: { lat: number; lng: number }) => void;
popup?: import('svelte').Snippet<[{ marker: MapMarkerResponseDto }]>;
rounded?: boolean;
showSimpleControls?: boolean;
}
let {
@ -70,6 +71,7 @@
onClickPoint = () => {},
popup,
rounded = false,
showSimpleControls = true,
}: Props = $props();
let map: maplibregl.Map | undefined = $state();
@ -266,13 +268,15 @@
bind:map
>
{#snippet children({ map }: { map: maplibregl.Map })}
<NavigationControl position="top-left" showCompass={!simplified} />
{#if showSimpleControls}
<NavigationControl position="top-left" showCompass={!simplified} />
{#if !simplified}
<GeolocateControl position="top-left" />
<FullscreenControl position="top-left" />
<ScaleControl />
<AttributionControl compact={false} />
{#if !simplified}
<GeolocateControl position="top-left" />
<FullscreenControl position="top-left" />
<ScaleControl />
<AttributionControl compact={false} />
{/if}
{/if}
{#if showSettings}
@ -285,7 +289,7 @@
</Control>
{/if}
{#if onOpenInMapView}
{#if onOpenInMapView && showSimpleControls}
<Control position="top-right">
<ControlGroup>
<ControlButton onclick={() => onOpenInMapView()}>