mirror of
https://github.com/immich-app/immich.git
synced 2025-05-31 04:05:39 -04:00
chore: rounded map corner when needed (#18163)
This commit is contained in:
parent
8db666bc38
commit
bb7010b2bb
@ -131,6 +131,7 @@
|
|||||||
bind:mapMarkers
|
bind:mapMarkers
|
||||||
onSelect={onViewAssets}
|
onSelect={onViewAssets}
|
||||||
showSettings={false}
|
showSettings={false}
|
||||||
|
rounded
|
||||||
/>
|
/>
|
||||||
{/await}
|
{/await}
|
||||||
</div>
|
</div>
|
||||||
|
@ -191,6 +191,7 @@
|
|||||||
clickable={true}
|
clickable={true}
|
||||||
onClickPoint={(selected) => (point = selected)}
|
onClickPoint={(selected) => (point = selected)}
|
||||||
showSettings={false}
|
showSettings={false}
|
||||||
|
rounded
|
||||||
/>
|
/>
|
||||||
{/await}
|
{/await}
|
||||||
</div>
|
</div>
|
||||||
|
@ -53,6 +53,7 @@
|
|||||||
onSelect?: (assetIds: string[]) => void;
|
onSelect?: (assetIds: string[]) => void;
|
||||||
onClickPoint?: ({ lat, lng }: { lat: number; lng: number }) => void;
|
onClickPoint?: ({ lat, lng }: { lat: number; lng: number }) => void;
|
||||||
popup?: import('svelte').Snippet<[{ marker: MapMarkerResponseDto }]>;
|
popup?: import('svelte').Snippet<[{ marker: MapMarkerResponseDto }]>;
|
||||||
|
rounded?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
let {
|
let {
|
||||||
@ -68,6 +69,7 @@
|
|||||||
onSelect = () => {},
|
onSelect = () => {},
|
||||||
onClickPoint = () => {},
|
onClickPoint = () => {},
|
||||||
popup,
|
popup,
|
||||||
|
rounded = false,
|
||||||
}: Props = $props();
|
}: Props = $props();
|
||||||
|
|
||||||
let map: maplibregl.Map | undefined = $state();
|
let map: maplibregl.Map | undefined = $state();
|
||||||
@ -247,7 +249,7 @@
|
|||||||
<MapLibre
|
<MapLibre
|
||||||
{hash}
|
{hash}
|
||||||
style=""
|
style=""
|
||||||
class="h-full rounded-2xl"
|
class="h-full {rounded ? 'rounded-2xl' : 'rounded-none'}"
|
||||||
{center}
|
{center}
|
||||||
{zoom}
|
{zoom}
|
||||||
attributionControl={false}
|
attributionControl={false}
|
||||||
@ -274,7 +276,9 @@
|
|||||||
{#if showSettings}
|
{#if showSettings}
|
||||||
<Control>
|
<Control>
|
||||||
<ControlGroup>
|
<ControlGroup>
|
||||||
<ControlButton onclick={handleSettingsClick}><Icon path={mdiCog} size="100%" /></ControlButton>
|
<ControlButton onclick={handleSettingsClick}
|
||||||
|
><Icon path={mdiCog} size="100%" class="text-black/80" /></ControlButton
|
||||||
|
>
|
||||||
</ControlGroup>
|
</ControlGroup>
|
||||||
</Control>
|
</Control>
|
||||||
{/if}
|
{/if}
|
||||||
@ -283,7 +287,7 @@
|
|||||||
<Control position="top-right">
|
<Control position="top-right">
|
||||||
<ControlGroup>
|
<ControlGroup>
|
||||||
<ControlButton onclick={() => onOpenInMapView()}>
|
<ControlButton onclick={() => onOpenInMapView()}>
|
||||||
<Icon title={$t('open_in_map_view')} path={mdiMap} size="100%" />
|
<Icon title={$t('open_in_map_view')} path={mdiMap} size="100%" class="text-black/80" />
|
||||||
</ControlButton>
|
</ControlButton>
|
||||||
</ControlGroup>
|
</ControlGroup>
|
||||||
</Control>
|
</Control>
|
||||||
|
@ -72,7 +72,7 @@
|
|||||||
{#if $featureFlags.loaded && $featureFlags.map}
|
{#if $featureFlags.loaded && $featureFlags.map}
|
||||||
<UserPageLayout title={data.meta.title}>
|
<UserPageLayout title={data.meta.title}>
|
||||||
<div class="isolate h-full w-full">
|
<div class="isolate h-full w-full">
|
||||||
<Map hash onSelect={onViewAssets} />
|
<Map hash onSelect={onViewAssets} rounded />
|
||||||
</div>
|
</div>
|
||||||
</UserPageLayout>
|
</UserPageLayout>
|
||||||
<Portal target="body">
|
<Portal target="body">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user