- From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
- Date: Thu, 15 Aug 2024 23:36:54 +0000
- To: public-css-archive@w3.org
The current text is right. Take a calculation like `10px + 50%`, in a context that resolves %s against a length, like the 'width' property: * per [determine the type of a calculation](https://drafts.csswg.org/css-values-4/#determine-the-type-of-a-calculation), the type is `{length -> 1}`, with a percent hint of "length". * per [match a type](https://drafts.css-houdini.org/css-typed-om-1/#cssnumericvalue-match), a type matches "length" if it's only non-zero entry is for "length" (true), and since the context it's used in allows percentages, the percent hint isn't consulted. The "match a type" algo has text for matching `<length-percentage>`/etc that *additionally* allows a `{percent -> 1}` type, tho I think that might now be legacy code and effectively unreachable. I should probably just more explicitly fold it into the plain `<length>` section, as that "If the context in which the value is used does not allow `<percentage>`" text is basically talking about that case (or rather, the inverse). -- GitHub Notification of comment by tabatkins Please view or discuss this issue at https://github.com/w3c/csswg-drafts/pull/10727#issuecomment-2292458729 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 15 August 2024 23:36:55 UTC