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

magnific-popup

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

magnific-popup

Lightbox and modal dialog plugin. Can display inline HTML, iframes (YouTube video, Vimeo, Google Maps), or an image gallery. Animation effects are added with CSS3 transitions. For jQuery or Zepto.

  • 1.2.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
61K
decreased by-6.42%
Maintainers
1
Weekly downloads
 
Created

What is magnific-popup?

Magnific Popup is a responsive lightbox & dialog script with focus on performance and providing best experience for user with any device.

What are magnific-popup's main functionalities?

Image Lightbox

This feature allows you to open images in a lightbox. The code sample demonstrates how to initialize a magnificPopup for elements with the class 'image-link' to display images in a popup.

$(document).ready(function() {
  $('.image-link').magnificPopup({type:'image'});
});

Gallery Lightbox

This feature enables a gallery of images to be displayed in a lightbox with navigation controls. The code sample shows how to set up a gallery using magnificPopup by delegating 'a' elements within a '.gallery' container.

$(document).ready(function() {
  $('.gallery').magnificPopup({
    delegate: 'a',
    type: 'image',
    gallery: {enabled: true}
  });
});

Inline Content

This feature allows you to display inline HTML content in a popup. The code sample demonstrates how to open inline content using magnificPopup for elements with the class 'inline-popup'.

$(document).ready(function() {
  $('.inline-popup').magnificPopup({
    type: 'inline',
    midClick: true
  });
});

Ajax Content

This feature allows you to load content via AJAX and display it in a popup. The code sample shows how to initialize magnificPopup for elements with the class 'ajax-popup' to load content asynchronously.

$(document).ready(function() {
  $('.ajax-popup').magnificPopup({
    type: 'ajax'
  });
});

Other packages similar to magnific-popup

Keywords

FAQs

Package last updated on 08 Jun 2024

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