web-platform-tests / web-platform-tests/interop
CSSPseudoElement
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 524
- Forks
- 35
- Avg merge
- 1d 4h
- Merged PRs (30d)
- 10
Description
Description
A very good and detailed explainer for CSSPseudoElement can be found here.
For Interop 2027, it would be great to have this available cross-engine. It is currently only available in Chromium and behind a flag in Firefox.
My primary motivation is for the ::backdrop pseudo element. Currently to detect backdrop clicks, it requires elaborative hacky workarounds such as event.target, getBoundingClientRect(), extra divs etc. They shouldn't be needed.
Example
dialog.addEventListener('click', (event) => {
if (event.pseudoTarget?.type === '::backdrop') {
dialog.close();
}
});
- https://github.com/danielsakhapov/CSSPseudoElementDoc
- https://developer.mozilla.org/en-US/docs/Web/API/CSSPseudoElement
- https://github.com/w3c/uievents/pull/413
- https://github.com/w3c/csswg-drafts/issues/13804
Specification
W3C
web-feature
https://github.com/web-platform-dx/web-features/issues/4306
Test Links
- https://wpt.fyi/results/css/css-pseudo/backdrop-pseudo-element-click.tentative.html?label=master&label=experimental&aligned&q=backdrop
- https://wpt.fyi/results/css/css-pseudo?label=master&label=experimental&aligned&q=CSSPseudoElement
Additional Signals
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the CSSPseudoElement explainer, the MDN page, and the linked W3C UI Events and CSSWG discussions. Run the linked WPT results for CSSPseudoElement and backdrop-pseudo-element-click.tentative.html, then use the standards-position links to understand cross-engine status; done means the feature is available across the relevant engines and the backdrop-click test passes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css, javascript
- Domain
- testing-qa, web-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100