0.0.0 • Published 4 years ago

@ronashdkl/kod-product-images v0.0.0

Weekly downloads
1
License
MIT
Repository
-
Last release
4 years ago

kodProduct Images Plugin

By Ronash Dhakal. Version 0.0.0

Todo

  • Image zoom
  1. download the repository
  2. cd into the project
  3. npm install it and run it by
  4. npm start
  5. to build your project npm build:prod
  • Link style and script in html file from dist folder.
  • copy assets directory to your project directory.
  • copy and paste following code inside html body
 <div class="kod_product_image">
        <div id="kod_thumbs_wrapper">
          <img src="/assets/n_p.png" class="kod_arrow up" alt="">
          <div id="kod_thumbs"></div>
          <img src="/assets/n_p.png" class="kod_arrow down" alt="">
        </div>
        <div id="kod_image"></div>
        <div id="kod_zoom"></div>
 </div>
  • call KodProductImage()  inside script tag in html or create new custom.js and call it.

KodProductImage(image:array) require images array. i.e url of image

KodProductImage([
    '/assets/images/1.jpg',
    '/assets/images/2.jpg',
    '/assets/images/3.jpg',
    '/assets/images/4.jpg',
    '/assets/images/5.jpg',
    '/assets/images/6.jpg',
])();

Screenshot

image

0.0.0

4 years ago