All Projects → davidecalignano → Mediumlightbox

davidecalignano / Mediumlightbox

Licence: mit
Nice and elegant way to add zooming functionality for images, inspired by medium.com

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Mediumlightbox

Amplify
A tiny script allowing inline image zoom
Stars: ✭ 458 (-31.74%)
Mutual labels:  image, zoom, lightbox
Basiclightbox
The lightest lightbox ever made.
Stars: ✭ 299 (-55.44%)
Mutual labels:  image, modal, lightbox
Ngx Gallery
Angular Gallery, Carousel and Lightbox
Stars: ✭ 417 (-37.85%)
Mutual labels:  image, modal, lightbox
React Modal Image
A tiny React component providing modal image Lightbox.
Stars: ✭ 97 (-85.54%)
Mutual labels:  image, modal, lightbox
React Native Image View
Modal component to view images with zoom
Stars: ✭ 273 (-59.31%)
Mutual labels:  modal, zoom
react-gallery-carousel
Mobile-friendly gallery carousel 🎠 with server side rendering, lazy loading, fullscreen, thumbnails, touch, mouse emulation, RTL, keyboard navigation and customisations.
Stars: ✭ 178 (-73.47%)
Mutual labels:  modal, lightbox
Body Scroll Lock
Body scroll locking that just works with everything 😏
Stars: ✭ 3,357 (+400.3%)
Mutual labels:  modal, lightbox
Flutter photo manager
Provide flutter with the ability to manage photos.
Stars: ✭ 294 (-56.18%)
Mutual labels:  plugin, image
body-scroll-freezer
↕️ Dependency-free JS module to freeze body scroll when opening modal box
Stars: ✭ 22 (-96.72%)
Mutual labels:  modal, lightbox
Flutter photo
Pick image/video from album by flutter. Support ios and android. UI by flutter, no native.
Stars: ✭ 285 (-57.53%)
Mutual labels:  plugin, image
Zoomove
🔍 🎆 Enlarges the image with the mouse hover and move
Stars: ✭ 339 (-49.48%)
Mutual labels:  plugin, zoom
react-layer-stack
Layering system for React. Useful for popover/modals/tooltip/dnd application
Stars: ✭ 158 (-76.45%)
Mutual labels:  modal, lightbox
MultiDialog
MultiDialog utilizes jQuery UI Dialog Widget for a full featured Modalbox / Lightbox application.
Stars: ✭ 23 (-96.57%)
Mutual labels:  modal, lightbox
Flutter advanced networkimage
flutter advanced network image provider
Stars: ✭ 282 (-57.97%)
Mutual labels:  image, zoom
fancybox
jQuery lightbox script for displaying images, videos and more. Touch enabled, responsive and fully customizable.
Stars: ✭ 7,261 (+982.12%)
Mutual labels:  modal, lightbox
Chartjs Plugin Zoom
Zoom and pan plugin for Chart.js
Stars: ✭ 404 (-39.79%)
Mutual labels:  plugin, zoom
Lightcase
The smart and flexible Lightbox Plugin.
Stars: ✭ 413 (-38.45%)
Mutual labels:  modal, lightbox
Flutter image editor
Flutter plugin, support android/ios.Support crop, flip, rotate, color martix, mix image, add text. merge multi images.
Stars: ✭ 181 (-73.03%)
Mutual labels:  plugin, image
Photofilters
photofilters library for flutter
Stars: ✭ 229 (-65.87%)
Mutual labels:  plugin, image
React Image Magnify
A responsive image zoom component designed for shopping sites.
Stars: ✭ 391 (-41.73%)
Mutual labels:  image, zoom

MediumLightbox

Nice and elegant way to add zooming functionality for images, inspired by medium.com

This plugin reproduce exactly the same code that use Medium to add the smooth transition effect clicking over the images, with some improvement.

Key features

Written in pure javascript for better performance, lightweight and simple. View demo.

Use

Include

<link href="style.css" rel="stylesheet">
<script src="mediumLightbox.js" ></script>

Style.css has some extra style for demo purposes. Pick just what you need.

html

<figure class="half left zoom-effect">
    <div class="aspectRatioPlaceholder" >
        <div class="aspect-ratio-fill" style="padding-bottom: 50%;"></div>
        <img class="img" data-width="900" data-height="450" src="image.jpg">
    </div>
</figure>

To do some calculations some attributes are necessary:

  • data-width: the real width of the image.
  • data-height: the real height of the image.
  • To the div with aspect-ratio-fill class is applied a padding-bottom that is the aspect ratio of the image. The aspect ratio percentage is found with [(height/width)*100] formula.

Initialize plugin

MediumLightbox('figure.zoom-effect');

Option

MediumLightbox('figure.zoom-effect', {
    margin:40
});
  • Margin - default: 20 - Margin in px applied to the image in zoomed view.

Preview | Live demo

alt text

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].