Skip to content

Commit

Permalink
Fix removal of :scope prefix in :has() operator
Browse files Browse the repository at this point in the history
  • Loading branch information
gorhill committed Sep 11, 2023
1 parent d5fb3c0 commit 2571660
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/js/static-filtering-parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -3687,7 +3687,7 @@ class ExtSelectorCompiler {
case 'has': {
let r = this.astCompile(parts, { noaction: true });
if ( typeof r === 'string' ) {
r = { selector: r.replace(/^\s*:scope\s*/, ' ') };
r = { selector: r.replace(/^\s*:scope\s*/, '') };
}
return r;
}
Expand Down

0 comments on commit 2571660

Please sign in to comment.