[csswg-drafts] [css-writing-modes] `glyph-orientation-vertical` is defined with invalid basic syntax (#8032)

cdoublev has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-writing-modes] `glyph-orientation-vertical` is defined with invalid basic syntax ==
The value of [`glyph-orientation-vertical`](https://drafts.csswg.org/css-writing-modes-4/#propdef-glyph-orientation-vertical) is defined with `auto | 0deg | 90deg | 0 | 90`.

Obviously, the numerical values are not keywords but `<angle>`s or `<integer>`s of the corresponding value in degrees. But [CSS Values](https://drafts.csswg.org/css-values-4/#component-types) does not define the type to which the numeric values correspond, ie. it does not allow solution 3 below.

I see a few solutions:

  1. define `glyph-orientation-vertical` with `auto | <angle [0,0]> | <angle [90deg,90deg]> | <integer [90,90]>`, with numeric values being restricted in prose to degrees or unitless values (`<angle>` allows unitless value)
  2. extend/change the syntax of the bracketed range notation to `[lower-upper]` and `[x,y,z]`, or something else
  3. extend the definition of CSS basic data types in CSS Values to allow writing numeric types literally

Solution 1 is a quick fix. Because `glyph-orientation-vertical` is obsolete, no solution may be worth it. But the CSS Properties and Values API may take advantage of solution 2 or 3, eg.:

```css
@property --boolean {
  syntax: 0 | 1, /* Or <integer [0,1]> */
}
```

The bracketed range has proven to be [problematic with dimensions](https://github.com/w3c/csswg-drafts/issues/7584). So my preference is solution 3 but it makes parsing `syntax` a bit more complex.

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8032 using your GitHub account


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

Received on Monday, 7 November 2022 08:02:06 UTC