Re: [csswg-drafts] [css-values-5] Add `spread()` to CSS (#8391)

@Loirooriol Thanks! Yes, I mistakenly used `,` ;P

I think a comma would be a reasonable default for most properties, and this spec could support other delimiters like the `;` used in `random()` using either of these:

### Example A: custom non-comma delimiter

```css
* {
  --multiple-items: (1; 2; 3; 4; 5);
  --single-item: 6;
  some-prop: random-item(var(--ident); spread(--multiple-items, ';'); var(--multiple-items));
}
```

### Example B: delimiter conversion

```css
* {
  --multiple-items: 1, 2, 3, 4, 5;
  --single-item: 6;
  some-prop: random-item(var(--ident); spread(--multiple-items, ',', ';'); var(--multiple-items));
}
```

---

This way, any set of values stored in a variable can be used regardless of what delimiter is used in it, and then converted to match the format needed for its new context.

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


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

Received on Thursday, 2 February 2023 17:15:23 UTC