Apply direction aware hover animation to images or other elements