1.0.4 • Published 6 years ago

nico-zoom v1.0.4

Weekly downloads
1
License
ISC
Repository
github
Last release
6 years ago

image-zoom

a medium like image zoom plugin

Features

  • Small

  • No other deps

Installation

$ npm install --save nico-zoom

Getting started

  <script src="./dist/NZoom.min.js"></script>
  <script>
    window.onload = function() {
      var container = document.querySelector('.content')
      new NZoom(container, {
          gutter: 30,
          scrollOffset: 10,
          overlayBg: '#ffffff',
          scaleFactor: 1,
          beforeZoomIn: () => {},
          afterZoomIn: () => {},
          beforeZoomOut: () => {},
          afterZoomOut: () => {}
      })
    }
  </script>
import NZoom from 'nico-zoom'

new NZoom(document.querySelector('.content'), {
  gutter: 30,
  scrollOffset: 10,
  overlayBg: '#ffffff',
  scaleFactor: 1,
  beforeZoomIn: () => {},
  afterZoomIn: () => {},
  beforeZoomOut: () => {},
  afterZoomOut: () => {}
})
1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago