1.0.8 • Published 2 years ago

react-simple-minimal-carousel v1.0.8

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

react-simple-minimal-carousel.

A lightweight and fully customizable carousel component for React

DEMO

https://neon010.github.io/react-simple-minimal-carousel-demo/

Installing as a package

npm install react-simple-minimal-carousel
yarn add react-simple-minimal-carousel

Usage

import {Carousel} from "react-simple-minimal-carousel"

function App() {
  return (
    <div className="App">
      <Carousel 
      images={
        [
          'https://images.unsplash.com/photo-1544005313-94ddf0286df2?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxzZWFyY2h8Mnx8cG9ydHJhaXR8ZW58MHx8MHx8&auto=format&fit=crop&w=500&q=60', 
          'https://images.unsplash.com/photo-1616776005756-4dca36124bf9?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxzZWFyY2h8MTN8fHBvcnRhaXR8ZW58MHx8MHx8&auto=format&fit=crop&w=500&q=60',
          'https://images.unsplash.com/photo-1611451444023-7fe9d86fe1d0?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxzZWFyY2h8MXx8cG9ydHJhaXQlMjB3b21hbnxlbnwwfHwwfHw%3D&auto=format&fit=crop&w=500&q=60',
          'https://images.unsplash.com/photo-1494790108377-be9c29b29330?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxzZWFyY2h8NHx8Z2lybHxlbnwwfHwwfHw%3D&auto=format&fit=crop&w=500&q=60'
        ]}
      width={650}
      height={500}
      showDots={true}
      leftArrowLabel={"left"}
      rightArrowLabel={"right"}
      arrowStyle={{padding:"5px", background:"black", color:"#fff", border:'none'}}
      />
    </div>
  );
}

export default App;

Props

NameValueDescription
widthnumberSet the width of image.
heightnumberSet the height of image
imagesarraySet the image
showDotsboolean default trueenable dots at the bottom of slide
currentImageDotsColorstring default #1e293bcolor of current image dots
otherDotColorstring defaults #e5e7ebcolor of of other dots
leftArrowLabelstring or JSXSet the label for left button
rightArrowLabelstring or JSXSet the label for right button
arrowStyleobjectStyle object for left and right button
showCurrentSlideNumberboolean default truecurrent slide number at the left top
1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago