1- import React from "react" ;
1+ import * as React from "react" ;
22
33type RenderArrowProps = {
44 type : "PREV" | "NEXT" ;
@@ -27,6 +27,7 @@ type Breakpoint = {
2727
2828export interface ReactElasticCarouselProps {
2929 className ?: string ;
30+ // Defaults to 1
3031 itemsToShow ?: number ;
3132 // Defaults to false
3233 verticalMode ?: boolean ;
@@ -42,10 +43,11 @@ export interface ReactElasticCarouselProps {
4243 enableTilt ?: boolean ;
4344 // Defaults to 1
4445 itemsToScroll ?: number ;
46+ // Collection of objects with a width, itemsToShow and itemsToScroll
4547 breakPoints ?: {
4648 width : number ;
47- itemsToShow : number ;
48- itemsToScroll : number ;
49+ itemsToShow ? : number ;
50+ itemsToScroll ? : number ;
4951 } [ ] ;
5052 // Defaults to 0
5153 initialFirstItem ?: number ;
@@ -62,7 +64,7 @@ export interface ReactElasticCarouselProps {
6264 // Defaults to "CENTER"
6365 itemPosition ?: "START" | "CENTER" | "END" ;
6466 // A padding for each element - Defaults to [0,0,0,0]
65- itemPadding : number [ ] ;
67+ itemPadding ? : number [ ] ;
6668 // Enable or disable swipe - Defaults to true
6769 enableSwipe ?: boolean ;
6870 /** Enable or disable mouse swipe */
@@ -76,6 +78,7 @@ export interface ReactElasticCarouselProps {
7678 enableAutoPlay ?: boolean ;
7779 /** Set auto play speed (ms) - Defaults to 2000 */
7880 autoPlaySpeed ?: number ;
81+ // A callback for the change of an item
7982 onChange ?: ( currentItemObject : ItemObject , currentPageIndex : number ) => void ;
8083 // A callback for the beginning of the next transition
8184 onNextStart ?: (
0 commit comments