Summary: | Expose methods to retrieve a PseudoElement given a PseudoId on Element | ||
---|---|---|---|
Product: | WebKit | Reporter: | Antoine Quint <graouts> |
Component: | CSS | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED WONTFIX | ||
Severity: | Normal | CC: | koivisto, rniwa, simon.fraser, webkit-bug-importer |
Priority: | P2 | Keywords: | InRadar |
Version: | Safari Technology Preview | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Bug Depends on: | |||
Bug Blocks: | 207290 |
Description
Antoine Quint
2020-02-05 13:11:52 PST
PseudoElement class in general is extremely underspec’ed (e.g. lifetime of these objects is completely unspecified or badly specified). So we need to figure out how PseudoElement’s lifecycle is managed. Note that this request is unrelated to exposing PseudoElement, the Web Animations API only exposes an Element/CSSOMString pair. PseudoElement is an implementation detail, not exposed to web in any direct way. It was a bad idea from the start. I think it was originally added to make before/after animatable. The right way to do that would have been to make Element/pseudo pairs animatable rather adding a confusing internal Element subclass. Note that only before/after generate PseudoElements. I deliberately got rid of ensurePseudoElement(PseudoId) functions at some point to reduce confusion and prevent people from writing code that would create PseudoElements in other cases. The right direction here is to eliminate PseudoElement completely. Should be easier when the new animation system is fully in place. |