cleaned up and rewrote theme.js. functional but still need to get "animation-direction" working