I've got an element, when it's parent's class changes, gets different display
and width
properties.
I would like to transition just the width
property, but the transition doesn't get applied if the display property changes - even though the display property isn't being transitioned.
JSFiddle here: http://jsfiddle.net/B6k3j/.
You can see .none-content
doesn't get any properties transitioned (I've also transitioned background-color
for visual effect) because it is changing from display:none
to display:inline-block
. The .ib-content
element however, whose display
property doesn't change, transitions fine.
To be clear: I'm not trying to transition the display property, the display property just happens to be changing at the same time I want the transition to apply.
Sidenote: I have an example using animations, but it has odd behaviour & I'd like to support IE9 if possible: http://jsfiddle.net/VeAy2/1/