Yeah, the relevant spec quote here is:
> When a style change event occurs, implementations must start transitions based on the computed values that changed in that event.
In this case, when the `:active` CSS rule starts applying, it adds additional styles for `font-size` and `padding`. And this style-change *does* result in the computed style of `font-size` changing, but it does not result in the computed style of `padding` changing.
So, per spec, we play a transition for `font-size` **but not for `padding`**. The padding is the same pixel value before and after the style change. (This is a bit easier to see if you specify your font-size in pixel units.)
Since `padding` happens to be specified in terms of `em` units, it does end up changing during the transition due to the fact that the `font-size` is being transitioned which influences its resolution of `em` units. But `padding` itself is not directly transitioned, since its computed value (the pixel value) is the same before and after the restyle is applied.
(emilio / hiro / boris, let me know if I'm missing anything here; otherwise I think this is not-a-Firefox-bug since we [and Chrome] are following the spec.)
Bug 1774014 Comment 4 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
Yeah, the relevant spec quote here is in https://www.w3.org/TR/css-transitions-1/#starting : > When a style change event occurs, implementations must start transitions based on the computed values that changed in that event. [EDIT: sorry, I initially forgot to include a spec link; I've added the link now.] In this case, when the `:active` CSS rule starts applying, it adds additional styles for `font-size` and `padding`. And this style-change *does* result in the computed style of `font-size` changing, but it does not result in the computed style of `padding` changing. So, per spec, we play a transition for `font-size` **but not for `padding`**. The padding is the same pixel value before and after the style change. (This is a bit easier to see if you specify your font-size in pixel units.) Since `padding` happens to be specified in terms of `em` units, it does end up changing during the transition due to the fact that the `font-size` is being transitioned which influences its resolution of `em` units. But `padding` itself is not directly transitioned, since its computed value (the pixel value) is the same before and after the restyle is applied. (emilio / hiro / boris, let me know if I'm missing anything here; otherwise I think this is not-a-Firefox-bug since we [and Chrome] are following the spec.)
Yeah, the relevant spec quote here is in https://www.w3.org/TR/css-transitions-1/#starting : > When a style change event occurs, implementations must start transitions based on the computed values that changed in that event. [EDIT: sorry, I initially forgot to include a spec link; I've added the link now.] In the reporter's JSFiddle, when the `:active` CSS rule starts applying, it adds new styles for `font-size` and `padding`. And this style-change *does* result in the computed style of `font-size` changing, but it does not result in the computed style of `padding` changing. So, per spec, we play a transition for `font-size` **but not for `padding`**. The padding is the same pixel value before and after the style change. (This is a bit easier to see if you specify your font-size in pixel units.) Since `padding` happens to be specified in terms of `em` units, it does end up changing during the transition due to the fact that the `font-size` is being transitioned which influences its resolution of `em` units. But `padding` itself is not directly transitioned, since its computed value (the pixel value) is the same before and after the restyle is applied. (emilio / hiro / boris, let me know if I'm missing anything here; otherwise I think this is not-a-Firefox-bug since we [and Chrome] are following the spec.)
Yeah, the relevant spec quote here is in https://www.w3.org/TR/css-transitions-1/#starting : > When a style change event occurs, implementations must start transitions based on the computed values that changed in that event. [EDIT: sorry, I initially forgot to include a spec link; I've added the link now.] In the reporter's JSFiddle, when the `:active` CSS rule starts applying, it adds new styles for `font-size` and `padding`. And this style-change *does* result in the computed style of `font-size` changing, but it does not result in the computed style of `padding` changing. So, per spec, we play a transition for `font-size` **but not for `padding`**. The padding is the same pixel value before and after the style change. (This is a bit easier to see if you specify your font-size in pixel units.) Since `padding` happens to be specified in terms of `em` units, it does end up changing **during the font-size transition** due to the fact that the `font-size` is being transitioned which influences its resolution of `em` units. But `padding` itself is not directly transitioned, since its computed value (the pixel value) is the same before and after the restyle is applied. (emilio / hiro / boris, let me know if I'm missing anything here; otherwise I think this is not-a-Firefox-bug since we [and Chrome] are following the spec.)
Yeah, the relevant spec quote here is in https://www.w3.org/TR/css-transitions-1/#starting : > When a style change event occurs, implementations must start transitions based on the computed values that changed in that event. [EDIT: sorry, I initially forgot to include a spec link; I've added the link now.] In the reporter's JSFiddle, when the `:active` CSS rule starts applying, it adds new styles for `font-size` and `padding`. And this style-change *does* result in the computed style of `font-size` changing, but it does not result in the computed style of `padding` changing. So, per spec, we play a transition for `font-size` **but not for `padding`**. The padding is the same pixel value before and after the style change. (This is a bit easier to see if you specify your font-size in pixel units.) Since `padding` happens to be specified in terms of `em` units, it does end up changing **during the font-size transition** due to the fact that the intermediate `font-size` produce a new resolution oft padding's `em` units. But `padding` itself is not directly transitioned, since its computed value (the pixel value) is the same before and after the restyle as-a-whole is applied. (emilio / hiro / boris, let me know if I'm missing anything here; otherwise I think this is not-a-Firefox-bug since we [and Chrome] are following the spec.)