Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@adactive/arc-carousel-asia

Package Overview
Dependencies
Maintainers
4
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@adactive/arc-carousel-asia - npm Package Compare versions

Comparing version 2.2.5 to 2.3.0

5

package.json
{
"name": "@adactive/arc-carousel-asia",
"version": "2.2.5",
"version": "2.3.0",
"description": "Adsum Carousel Component",
"main": "index.js",
"author": "Stanley Ong <stanley.ong@adactive.com>",
"contributors": [
"Erlanda Zakaria <erlandazakaria@gmail.com>"
],
"license": "UNLISENCED",

@@ -8,0 +11,0 @@ "readmeFilename": "README.md",

8

README.md

@@ -56,3 +56,5 @@ # Carousel component

adaptiveHeight: true,
wrapAround: true
wrapAround: true,
autoSlide: false,
autoSlideInterval: 10000,
}

@@ -75,3 +77,7 @@ };

**autoSlide** -> Slider Looping in Boolean
**autoSlideInterval** -> Slider Looping Interval in ms
## Copy component inside your project src folder

@@ -78,0 +84,0 @@

@@ -53,2 +53,4 @@ // @flow

ButtonModalForImage: null,
autoSlide: false,
autoSlideInterval: 10000,
};

@@ -70,3 +72,5 @@

autoPlayInterval: 10000,
setTimeoutSlide: null,
};
}

@@ -80,3 +84,2 @@

const { autoplay, autoPlayInterval } = this.state;
if (this._videoPlayers[0]) {

@@ -146,6 +149,20 @@ this.playVideo(0);

slideDidChange(id: number | string) {
const { isOpen } = this.props;
const { isOpen, autoSlide, autoSlideInterval } = this.props;
const { setTimeoutSlide } = this.state;
console.log(this.carousel.currentSlide)
if(autoSlide){
if(setTimeoutSlide!==null) {clearTimeout(setTimeoutSlide)};
if(id === (this.carousel.state.slideCount-1)){
this.setState({
setTimeoutSlide: setTimeout(() => { this.carousel.goToSlide(0); }, autoSlideInterval),
})
} else {
this.setState({
setTimeoutSlide: setTimeout(() => { this.carousel.goToSlide(id+1); }, autoSlideInterval),
})
}
}
if (!isOpen) return;

@@ -177,9 +194,2 @@

// goAuto() {
// if(this.carousel.currentSlide < this.carousel.slideCount){
// setTimeout(function(){ this.carousel.goToNextSlide(); }, 3000);
// }
// }
/**

@@ -256,3 +266,2 @@ * Create carousel slides content images or videos

const { autoplay, autoPlayInterval } = this.state;
if (!isOpen) return null;

@@ -274,3 +283,2 @@

{this.generateSlides()}
{/* {this.goAuto()} */}
</Carousel>

@@ -277,0 +285,0 @@ </div>

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc