Hello!
I’ve spent a long time combing the forums looking for an answer but haven’t been able to find something that I think fits the problem.
I have a navbar with a custom hamburger button that has some animation for hover and click. I am having trouble understanding having two timelines that must operate in sequence.
Some detail:
1. When the user tabs to the button or hovers, the bars should slide to a full-width hamburger.
2. When the user clicks or hits enter/space to activate the button, it should finish the hover animation regardless of its position and then activate the click timeline which slides out a nav (in the simple demo it just changes a box color and text for ease).
3. When the user clicks the X, it should reverse the animation.
4. When the user mouses out or blurs, the hover should reverse.
I feel I am close but continue to get odd results. Hover animations firing when exiting but only going halfway, quick bounces on mouseout, etc.
I know with the version upgrade to 3, class manipulation was removed, but I was trying to use .set() or functions to manipulate classes. Is there a smarter way to do these kind of multiple interactions? Conditionals in lifecycle methods like onComplete()? Should they be one timeline that only goes halfway on hover and then continues on click? .progress()?
Any assistance would be great. Thank you!