Re: [csswg-drafts] [css-borders] Allow multiple borders by listifying them (#13044)

> > Otherwise there is no way to specify things like "N borders, all the same width" without also specifying their width
> 
> Is that really a problem worth solving? 

Good question. My gut feeling is that listing the widths you want is the more common need than picking a width for what they should all add up to. But I'm not against also having 1D image borders, e.g. `stripes()`, as a complementary option in addition to having multiple true borders, to solve that use case. It does seem more niche to me, but could be kind of cool, especially with `linear-gradient` as another way to create glows and non-offset pseudo shadows (that take up space, alas). 

> If so, maybe we can reuse grid's `repeat()` function?

Sure, that could work. 

> > or to specify relative widths (e.g. "1px, 1fr, 1px")
> 
> I don't understand what `1fr` means here; what excess space is there to divide?

It would be a way to stripe a single border-width. This isn't my preferred method, but I believe it would be some variation of this sort of thing:

```
border: 5px solid;
border-color: stripes(1px black, 1fr transparent, 1px black)

```
...and then in this example, no matter what you change the `border-width` to, you'd get a 1px stripe of black on the inside edge of the border, another on the outside edge, and transparency between them (3px of transparency for a 5px `border-width`).


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


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

Received on Monday, 19 January 2026 06:58:55 UTC