|Summary:||Transition CSS added to DOM element uses previously removed class|
|Product:||WebKit||Reporter:||Dan Ackroyd <Danack>|
|Component:||New Bugs||Assignee:||Nobody <webkit-unassigned>|
|Version:||528+ (Nightly build)|
Description Dan Ackroyd 2013-03-07 05:58:51 PST
Comment 1 Simon Fraser (smfr) 2013-03-07 16:06:09 PST
This is expected behavior, and allowed by the transitions spec. CSS doesn't actually describe how and when styles are resolved, and most browsers batch style changes. That means that the removeClass('active') and addClass('all-transition') basically happen at the same time. If you don't want this, you can force a layout between them (e.g. via body.offsetWidth), or put the second line inside a setTimeout(, 0).