Re: Select element if next sibling

> On Jul 28, 2017, at 22:43, Sebastian Zartner <sebastianzartner@gmail.com> wrote:
> 
> On 27 July 2017 at 06:23, Sebastian Malton <sebastian@malton.name> wrote:
>> Something like `label+div` selects all divs directly following a label. I
>> propose `label ->div` which selects all labels that are followed by a div
>> 
>> Sebastian
> 
> That's already covered by the :has() pseudo-class defined in
> https://drafts.csswg.org/selectors/#relational.

Right, except that :has() is excluded from the dynamic profile (i.e. selectors you can use in regular CSS). Regardless of syntax, this previous sibling selector should be possible to implement in the dynamic profile.

—Florian

Received on Saturday, 29 July 2017 14:05:05 UTC