Re: [csswg-drafts] [css-transitions] Transition to height (or width) "auto" (#626)

> it's not immediately apparent to me why this should be desired behavior

Not necessarily desired, just a corollary of using computed values. If you are at midway between `100%` and `200px`, that's `50% + 100px`. If the `50%` was resolving to `0px`, then we had `0px + 100px = 100px`. But if something changes and `50%` now resolves to `25px`, then we have `25px + 100px = 125px`. And this is a sudden visual change because we are interpolating computed values, and the computed value is not affected, it's still `50% + 100px`.

In some cases you may not desire this, that's why I said we could add a new way to interpolate used values instead of computed values, which would cover these usecases, and also `auto`.

It seems you are also thinking in terms of a used value interpolation. So rather than trying to interpolate `auto` by internally switching to a used-value interpolation with various hacks to make it seem closer to a computed value interpolation, I would prefer to explicitly add a way for authors to request a used-value interpolation without hacks.

> B) is doable without having to support `auto` in `calc`

Sure, if interpolating used values, but that's a new thing that would need to be properly designed and defined.

But keeping the current model based on computed values, then we need `a*(1-t) + b*t` with `auto`, and if we can do that it should be trivial to fully allow `auto` in `calc()`.

-- 
GitHub Notification of comment by Loirooriol
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/626#issuecomment-1054403849 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 28 February 2022 15:59:47 UTC