Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
Johanna

MorphSVG menu icons help please

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

Hi all,

 

I'm trying to make a menu with SVG icons that morph into Xs and back on click. So far I can get them to morph and morph back as the menu closes but I'm stuck on trying to get one icon to revert back to its original shape when I click the other icon. Where am I going wrong? 

 

See the Pen yRejRY by davidrogers (@davidrogers) on CodePen

Link to comment
Share on other sites

I don't know if I'm misunderstanding the question here, but that looks like it's working correctly to me. I clicked the hamburger while the file folder is open and vice versa. All items seems to morph back as they should. Am I missing something?

 

Happy tweening.

:)

 

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×