CSS background image hacks
nicolasgallagher.com
nicolasgallagher.com
Is there anything stopping me from animating the background rotation with jQuery? That would add to the accordion effect if it works.
Because the pseudo-elements aren't part of the DOM, you can't use jQuery to animate the rotation. At the moment, CSS animations and transitions can't be applied to CSS pseudo-elements either.
data:text/html,<style>div::before { color: green; content: "text"; } div:hover::before { color: red; -moz-transition-duration: 5s; }</style><div>
It does look like Webkit doesn't support this, though. Which is a bug, per the current spec draft. All the transition stuff is specced to apply to ::before and ::after.