Skip to content

Commit

Permalink
fix(carousel-arrows): right arrow disabled on rendering last slide
Browse files Browse the repository at this point in the history
  • Loading branch information
udaypydi committed Feb 4, 2020
1 parent 6ce4a9d commit a2f6e80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/Carousel.js
Original file line number Diff line number Diff line change
Expand Up @@ -640,7 +640,7 @@ export default class Carousel extends Component {
renderArrowRight = () => {
const slides = this.getChildren();
const value = this.getCurrentValue();
const lastSlideIndex = slides.length;
const lastSlideIndex = slides.length - 1;

if (this.getProp('arrowRight')) {
return this.renderArrowWithAddedHandler(this.getProp('arrowRight'), this.nextSlide, 'arrowRight');
Expand Down

0 comments on commit a2f6e80

Please sign in to comment.