Is there any way to use the same transition on the same element at two different times?
I was hoping that this would work but it doesn't seem to be possible unless I am just doing it wrong. I have discovered other work-arounds such as using .style.left for one transition and .style.transform for the other transition and separating them with a comma. I can also use animations and a 3rd way is to add more divs so that I can have more IDs and then do the transitions on them. It is part of a larger project that I am working on for practice and every time that I want to animate the same element, I have to use one of those other methods to do it. It just seems like it would have have been so much easier if I could use a function with arguments to use the same transition on the same element at different times. As you can see in the code, you can only do one or the other. If both are used, only the close function works. If you comment out the close function, then the open function works... 🤔 https://code.sololearn.com/W5qa9NT4dsiu/?ref=app