1.0.1 • Published 3 years ago

vue-hover-zoom v1.0.1

Weekly downloads
3
License
MIT
Repository
github
Last release
3 years ago

Vue Hover Zoom

Easy to use package for zoom image when hover on it with the mouse cursor

Getting started

  1. Install the package:
npm install vue-hover-zoom
  1. Import component:
import  VueHoverZoom  from  'vue-hover-zoom'
  1. Add component to components:
components: {  
  VueHoverZoom  
}
  1. Use component in template
<vue-hover-zoom imageUrl="https://test.com/img.png"></vue-hover-zoom>

✅ Config

You can config VueHoverZoom Component with props.

⚙ imageUrl:
❗ Required

⚙ imageAlt:
🔹 default: null

⚙ zoomPercent:
🔹 default: 200

⚙ zoomCursor:
🔹 default: true

⚙ animation:
🔹 default: fade
🔸 options: fade, shrink, growup, slidedown, slideup
You Can use multiple animations like: fade shrink

⚙ showWhenImageLoaded:
🔹 default: false
If you enable this, image shows when fully loaded

📌 Note

You can select the element in css and set image width.
default class: hover-zoom-image

1.0.1

3 years ago

1.0.0

3 years ago