You have to use dynamic components, set the origin of the panels to the center of the button, add a animate attribute, a rotation attribute and set the values. It’s kind of hard to explain how to do it on a comment, right now I’m not on my computer but I’ll try to make a video if no one has in a few hours.
You can also check YouTube, there are tons of videos about dynamic components out there.