Re: [csswg-drafts] [css-overflow-4] line-clamp "max-lines" - support auto value to fit container (#9368)

If I am not mistaken, this use case is already covered by [`continue: discard;`](https://drafts.csswg.org/css-overflow-4/#propdef-continue) in combination with [`block-ellipsis: auto;`](https://drafts.csswg.org/css-overflow-4/#propdef-block-ellipsis).

Though it looks like this can't be set via the shorthand `line-clamp` yet. So I suggest to change its syntax so setting the [`max-lines`](https://drafts.csswg.org/css-overflow-4/#max-lines) value is not required.
I think it is not necessary to add direct control over `continue` but instead set it to `discard` in case a block ellipsis is set.

So I suggest to change the syntax to

```ebnf
none | [ <integer [1,∞]>? <'block-ellipsis'>? ]!
```

With that change, one could write `line-clamp: auto` (with `auto` standing for the `block-ellipsis` value) to achieve the above.

Sebastian

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


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

Received on Sunday, 17 September 2023 19:11:10 UTC