akiran / react-slick

React carousel component
http://react-slick.neostack.com/
MIT License
11.72k stars 2.1k forks source link

Force arrows to show (even in a disabled state) #1474

Open tbehunin opened 5 years ago

tbehunin commented 5 years ago

When the width of the track can fit all the slides, the arrows disappear. I'd like to be able to force the arrows to be visible always, whether disabled or not.

Here's a demo that has one slide and the arrows are missing: https://codesandbox.io/s/zljkw3x09x

If I add more slides, the arrows show up. My goal is to always display the arrows (they would be disabled if they can't navigate left and/or right). How can I do that?

Romcol commented 4 years ago

Hi,

It's actually pretty easy. You need to override css for "slick-disabled" class. Or you can define custom arrows with your own CSS (https://react-slick.neostack.com/docs/example/custom-arrows) :wink:

PathFinder5196 commented 3 years ago

@Romcol This solution is not working

aamin21 commented 3 years ago

The arrows are not even rendered, so can't use slick-disabled.