Re: [csswg-drafts] [css-backgrounds-4][css-values-4] Align logical values for <position> with the ones defined in CSS Logical Properties (#549)

It is slowly getting a liiittle complicated to comprehend and keep up with everything. 😅

The split into different productions helps to grasp the changes. And thank you for adding the optional offset to `start`/`end`!

I think it would help to give the data types more expressive names like `<position-one-axis>`, `<position-two-axes>`, `<position-two-axes-with-offsets>`, and `<position-two-axes-with-one-offset>`, or so.
Was there a reason not to allow combinations of logical keywords and `<length-percentage>`? I.e. I am missing a

```ebnf
  [ block-start | center | block-end | <<length-percentage>> ]
  [ inline-start | center | inline-end | <<length-percentage>> ]
```

Regarding the positioning origin, I think authors would want the coordinate information to be preserved. I.e. the coordinate information should be inferred from the given keyword when possible and fall back to top left otherwise. By inferred I mean the origin is the `*-start` value of the axis perpendicular to the given one for logical keywords and the top left corner for physical keywords.

So, for example, for a value of `10% y-start`, the origin for the percentage is then interpreted as `x-start` value.
When the value is `block-start 100px`, the offset refers to the inline-start axis.

When interpolating, the coordinate information could also be preserved in case axes of the start and end value coincide. That means, animating from `0 y-start` to `100% y-end` results in an interpolation from the x-start/y-start point to the x-end/y-end` point.
Though, I guess it doesn't matter much to authors whether the coordinate information is preserved or converted to the top/left coordinate system as long as the visual result is the same.

Sebastian

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


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

Received on Friday, 24 November 2023 23:43:16 UTC