Is there a way to toggle animations in Widget Blueprints?

So when I press the shift key a stamina progress bar should fade in and when I release the key it should fade out. My question is if there is a way to toggle the animation so that it is reverse and fades out seamlessly, when you stop pressing the key

Thanks to everyone who responds

This should work:

You just need to provide Play Mode - the Forward / Reverse.

That was exactly what I was looking for thanks!