mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-13 03:29:49 +00:00
LibWeb/CSS: Test css shadow host selector matching
Add a test that verifies selectors inside a shadow root can only match their host element through :host pseudo-class. Tests both simple selectors (#id, .class) and complex selectors (:not, :where) to ensure they are blocked from matching the host element directly. Fixes issue #2319
This commit is contained in:
parent
3ff8c5c8f1
commit
be979a1e65
Notes:
github-actions[bot]
2024-12-04 16:20:23 +00:00
Author: https://github.com/ycarmon
Commit: be979a1e65
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2552
Reviewed-by: https://github.com/AtkinsSJ ✅
Reviewed-by: https://github.com/awesomekling
2 changed files with 94 additions and 0 deletions
|
@ -0,0 +1,8 @@
|
|||
1. "Fast match #host selector matches: No"
|
||||
2. "Fast match .host-class selector matches: No"
|
||||
3. "Fast match div selector matches: No"
|
||||
4. "Fast match :host selector matches: Yes"
|
||||
5. "Complex match #host:not(.other) matches: No"
|
||||
6. "Complex match .host-class:where(.exists) matches: No"
|
||||
7. "Complex match div:has(span) matches: No"
|
||||
8. "Complex match :host(.host-class) matches: Yes"
|
Loading…
Add table
Add a link
Reference in a new issue