Skip to content

Consider :has() as a standard pseudo-class if ExtendedCss usage is not forced by #?# rule marker #43

@slavaleleka

Description

@slavaleleka

:has() pseudo-class has native implementation
https://developer.mozilla.org/en-US/docs/Web/CSS/:has

and since ExtendedCss v2 release the rule with ## marker and :has() should not be considered as ExtendedCss

const rule1 = 'example.org##.sponsored:has(.banner)';
expect(rule1.isExtendedCss()).toBeFalsy();

but :has() pseudo-class should be considered as ExtendedCss if the rule marker is #?#

const rule2 = 'example.org#?#.sponsored:has(.banner)';
expect(rule2.isExtendedCss()).toBeTruthy();

https://github.com/AdguardTeam/ExtendedCss#extended-css-has

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions