Learus / react-material-ui-carousel

A Generic carousel UI component for React using Material UI.
MIT License
550 stars 219 forks source link

CarouselItem.js file to stop console.log numbers. control bar when clicked, not working. #186

Closed janie-lee-developer closed 2 years ago

janie-lee-developer commented 2 years ago

version I'm using: "react-material-ui-carousel": "^3.4.1",

I have 2 issues.

issue 1: See attached pic. CarouselItem.js is console.logging 'divRef.current.offsetHeight'. How can we stop this? I need console.log to test other things and this is pushing up my logs every second.

Screen Shot 2022-05-30 at 4 13 51 PM Screen Shot 2022-05-30 at 4 13 38 PM

issue 2: When I click the other lighter grey buttons to go to a specific slide, it doesn't work. This dots are not clickable. How can I add a function so the slide renders the one that I click on the circle?

Here's my code.

Screen Shot 2022-05-30 at 4 13 59 PM Screen Shot 2022-05-30 at 4 43 46 PM

Thank you in advance!!

Learus commented 2 years ago

console.log issue is fixed, and published in v3.4.2.

As for the indicator issue, they should work properly, given the code you posted. It sometimes happens with CRA apps, but it's not the library's issue. The whole page becomes unclickable or unresponsive to any user input. I'm not sure what causes it, but I do not think it's the carousel's fault.

janie-lee-developer commented 2 years ago

I just updated the version as you recommended and it went away! Thank you!

Ahhh.. issue 2 is unfortunate to hear.. thank you so much!