Components Library Operations MediaLightboxPro
MediaLightboxPro
Dependency-free media proof gallery with modal viewing and wraparound navigation.
Live demo
01Media viewer
Media lightbox pro
Implementation
02 MediaLightboxPro.svelte
<script lang="ts">
import MediaLightboxPro from '$lib/components/MediaLightboxPro.svelte';
</script>
β
<MediaLightboxPro {items} />MediaLightboxPro is a dependency-free proof gallery. It wraps thumbnails into a dialog with next/previous navigation and reusable index helpers for predictable media browsing.
Logic explainer
03What Does It Do? (Plain English)
MediaLightboxPro renders a thumbnail gallery and modal viewer for screenshot or media proof. It is intentionally dependency-free so teams can copy it into component docs or QA dashboards.
How It Works (Pseudo-Code)
receive media items
render thumbnail grid
open selected item in dialog
previous/next controls wrap through items
show counter and captionProps Reference
| Prop | Type | Default | Description |
|---|---|---|---|
items |
MediaLightboxItem[] |
Required | Media items with title, src, alt, and optional caption. |
title |
string |
"Media lightbox pro" |
Heading above the gallery. |
Dependencies
No external dependencies.
API
04| Prop | Type | Description |
|---|---|---|
items | MediaLightboxItem[] | Media rows with src, alt, title, and optional caption. |
title | string | Gallery heading. |