Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

lightbox-package

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lightbox-package

A lightweight lightbox with zero dependencies

  • 1.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
6
increased by200%
Maintainers
1
Weekly downloads
 
Created
Source

lightbox-fs

A simple lightbox for your image gallery. This lightbox doesn't have any dependencies and can be used with any webpage.

Here's a preview

fs-lightbox in action

https://cdn.jsdelivr.net/gh/FaisalST32/fs-lightbox@latest/src/js/fs-lightbox.min.js
https://cdn.jsdelivr.net/gh/FaisalST32/fs-lightbox@latest/src/css/fs-lightbox.min.css

NPM

npm i lightbox-fs

https://www.npmjs.com/package/lightbox-fs

Usage:

  • To use the lightbox you can simply add a reference to the .js file at the end of the body of your html and the .css file in the head of your html page.

  • In the img tag of the image that you want to be a part of the lightbox, add a class fs-lightbox.
    For example, "<img src="image.png" class="fs-lightbox" />"

  • That's it. When you click on the image, a lightbox preview of the image will appear.

Methods:

The plugin exposes some methods that you can use:

  • fsLightbox.next() - This will display the next picture in the lightbox

  • fsLightbox.prev() - This will display the previous picture in the lightbox

  • fsLightbox.hideLightbox() - This will hide the Lightbox

Keywords

FAQs

Package last updated on 21 Nov 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc