malsup / cycle2

2nd gen cycling
899 stars 236 forks source link

Use visibility:hidden/inherit instead of visibility:hidden/visible #705

Open DolphRoger opened 9 years ago

DolphRoger commented 9 years ago

Hello,

while implementing this plugin in a website which uses to work with containers that are switched with visiblity (not display, that wouldn't work that way, display:none has 0 width and height) I found that the cycle-images still remained visible. The way to fix it was to change all visibility:"visible" with visibility:"inherit" within the cycle2 code. This works flawlessly now. I'd suggest to add it to the standard, so cycles can be hidden with visibility:hidden on the container.

jceddy commented 4 years ago

Thank you so much for creating this issue...had the same problem in my page. Needed a slideshow inside an element that has visibility 'visible' or 'hidden' based on HOVER on another element.

DolphRoger commented 4 years ago

Glad it saved you some time - 4 years later. Still think it should be in the standard, as visibility:inherit instead of visibility:visible would have any negative effect while fixing this odd behaviour.