Comparing version 0.3.0 to 1.0.0
{ | ||
"name": "scoochjs", | ||
"version": "0.3.0", | ||
"version": "1.0.0", | ||
"description": "A really lightweight, customisable vanilla Javascript carousel", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
# Scooch | ||
Scooch makes slideshows easy. You bring your own content and styling. It's super lightweight, around 1.5kb gzipped and easy to customise. | ||
Scooch makes slideshows easy. You bring your own content and styling (aside from some functional styles to make Scooch work). It's super lightweight, around 1.5kb gzipped and easy to customise. | ||
@@ -51,4 +51,2 @@ ## Installation | ||
💡 Tip: Hover over the left bottom corner of the `index.html` demo page to see keyboard controls. | ||
## Roadmap | ||
@@ -55,0 +53,0 @@ |
@@ -31,3 +31,3 @@ const Scooch = function (node, options = {}) { | ||
// Setup the first slide | ||
this.firstSlide.style.opacity = 1; | ||
this.firstSlide.setAttribute('aria-current', true); | ||
@@ -43,3 +43,2 @@ // Register it as the current and previous slides | ||
if ( this.options.swipeToChange ) { | ||
console.log('Swipe enabled'); | ||
this.node.addEventListener('touchstart', this.handleStartSwipe.bind(this), false); | ||
@@ -82,7 +81,7 @@ this.node.addEventListener('touchmove', this.handleSwipe.bind(this), false); | ||
// Hide the currentSlide | ||
this.currentSlide.style.opacity = 0; | ||
this.currentSlide.removeAttribute('aria-current'); | ||
// Set new slide | ||
this.currentSlide = slide; | ||
this.currentSlide.style.opacity = 1; | ||
this.currentSlide.setAttribute('aria-current', true); | ||
}; | ||
@@ -89,0 +88,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
10614
159
55