Image Lightbox

Peter Teal

AuthorPeter TealPlugin TypeCommunity PluginPriceFreeVersionvlatestLicenseMIT
NativePHP^3.0PHP^8.2iOSanyAndroidany

Display images (jpg, jpeg, png, heic) in a full-screen native lightbox overlay above the running app UI, with pinch-to-zoom, pan, and optional action buttons.

Features

  • Native full-screen modal on iOS and Android
  • Pinch-to-zoom (up to 5×) and pan after zooming
  • Loads local file paths and remote URLs
  • WebView session cookie injection for authenticated endpoints
  • Optional Edit, Markup, Share, and Delete toolbar buttons
  • Native share sheet for local files and remote images
  • Safe-area aware controls with dismiss animation
  • Graceful error states (invalid URL, missing file, decode failure)

Installation

composer require pteal79/plugin-image-lightbox
php artisan vendor:publish --tag=nativephp-plugins-provider
php artisan native:plugin:register pteal79/plugin-image-lightbox

Usage

use Pteal79\PluginImageLightbox\Facades\ImageLightbox;

ImageLightbox::show('/path/to/image.jpg');
ImageLightbox::show('https://example.com/photo.png');

Events

  • EditPressed — user tapped the Edit button; includes imageId
  • MarkupPressed — user tapped the Markup button; includes imageId
  • DeletePressed — user tapped the Delete button; includes imageId
  • ClosePressed — user dismissed the lightbox; includes imageId