zoom.js

Medium's Image Zoom for jQuery

  • Owner: fat/zoom.js
  • Platform:
  • License:: MIT License
  • Category::
  • Topic:
  • Like:
    0
      Compare:

Github stars Tracking Chart

ZOOM.JS

A simple jQuery plugin for image zooming; as seen on Medium.

Demo

https://fat.github.io/zoom.js

How

  1. Link the zoom.js and zoom.css files to your site or application.
<link href="css/zoom.css" rel="stylesheet">
<script src="js/zoom.js"></script>
  1. zoom.js is dependent on transition.js file from Bootstrap, so make sure to include that as well.
<script src="js/transition.js"></script>
  1. Add a data-action="zoom" attribute to the images you want to make zoomable. For example:
<img src="img/blog_post_featured.png" data-action="zoom">

Why

It's the best way to zoom an image. It transitions/zooms in really smoothly, and then when you're done, scrolls away, [esc] keys away, clicks away… clean af.

If you hold your meta key ( on mac) or (ctrl on windows), it will open in a new tab. wow.

ps. use a data-original attr to link to a separate image. Just for meta-clicking tho.

Where

zoom.js should (in theory) work in all relevant browsers (ie9+). If not, create an issue! Thanks!

Who

Written by @fat, made better by you.

Overview

Name With Ownerfat/zoom.js
Primary LanguageJavaScript
Program languageCSS (Language Count: 3)
Platform
License:MIT License
Release Count1
Last Release Namev0.0.1 (Posted on )
First Release Namev0.0.1 (Posted on )
Created At2013-10-24 05:45:32
Pushed At2023-02-17 23:27:23
Last Commit At2015-08-07 16:15:11
Stargazers Count4k
Watchers Count83
Fork Count332
Commits Count45
Has Issues Enabled
Issues Count68
Issue Open Count30
Pull Requests Count8
Pull Requests Open Count9
Pull Requests Close Count17
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private
To the top