Feature: first working version of inspecting 360° images

This commit is contained in:
Pieter Vander Vennet 2025-03-30 03:10:29 +02:00
parent 7d104b4266
commit 01ba98a820
24 changed files with 330 additions and 436 deletions

View file

@ -3,6 +3,8 @@
* Shows an image with attribution
*/
import ImageAttribution from "./ImageAttribution.svelte"
import { Store } from "../../Logic/UIEventSource"
import type { ProvidedImage } from "../../Logic/ImageProviders/ImageProvider"
import { Mapillary } from "../../Logic/ImageProviders/Mapillary"
import { UIEventSource } from "../../Logic/UIEventSource"
@ -32,6 +34,8 @@
export let attributionFormat: "minimal" | "medium" | "large" = "medium"
let previewedImage: UIEventSource<Partial<ProvidedImage>> = MenuState.previewedImage
export let canZoom = previewedImage !== undefined
export let nearbyFeatures: Feature[] | Store<Feature[]> = []
let loaded = false
let showBigPreview = new UIEventSource(false)
onDestroy(
@ -74,9 +78,8 @@
</script>
<Popup shown={showBigPreview} bodyPadding="p-0" dismissable={true}>
<div slot="close" />
<div style="height: 80vh">
<ImageOperations {image}>
<ImageOperations {image} {nearbyFeatures}>
<slot name="preview-action" />
<slot name="dot-menu-actions" slot="dot-menu-actions" />
</ImageOperations>