Is there a way to create a textbox that scrolls on hover only if the text is longer than the textbox itself? Check out my attempt here: https://jsfiddle.net/SynapticError/wqh4ts3n/35/
- The text should scroll on hover if it's longer than the textbox.
- If the text is shorter, no scrolling effect should occur.
In pseudo code, the solution might look like this:
IF scrollcontent.width > navbes.width
{ add css <style type="text/css">navbes:hover .scrollcontent {left: -100px; transition-duration:3s;}</style> }
I've tried several methods, but none seem to work. Can anyone provide some guidance on how to achieve this effect successfully?