Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upHover color transition does not work with incremental layout #17667
Comments
|
Hi @jdm I'd like to take a look at this one. Do you have any advice on where to start? |
|
For bugs in incremental layout, my first step is to check that the correct "restyle damage" is inserted when an element's style changes. For CSS transitions, the style change happens in update_style_for_animation. I notice this method's doc comment talks about a It looks like it's now up to the caller of The restyle damage is calculated based on the differences between "old" and "new" styles (i.e. the computed values before and after the change is applied). Glancing at this code, I'm suspicious that this is taking a snapshot of the "old" values after the animation has been applied to them. |
|
This was fixed by #26407. I believe the reason this was failing was that the fragment that contained the text was inheriting the style from its containing box. The code that updated the style for transitions in the layout thread didn't descend into children when updating transitioning inherited properties. Now that animations update style during restyle, inheritance should work properly. |
When run with
-i, the color changes to red (with no intervening interpolated colors). Without-i, the text never changes color.