-
Notifications
You must be signed in to change notification settings - Fork 717
[css-pseudo-4] Other properties that should be included #5700
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
We can't include any properties that affect layout, as they'd reveal precisely how the pseudo-element is nested/split relative to the real elements it crosses. Only the tree-abiding pseudos can take those. So
(That is, if you had markup like |
Ah, makes sense. I assumed it was an independent “overlay” element that was on its own topmost plane. That said, is there a way to handle the High-Contrast use-case you can think of? Maybe I’m missing an obvious answer |
I think I understand the limitation around not affecting layout, but I'm not sure if I completely understand what it means for a style to "reveal where the pseudo-element is split." Would |
https://www.w3.org/TR/css-pseudo-4/#highlight-styling
Thinking about making
::highlight()
work in Contrast-Mode, it seems like the following should be included:outline
and its sub-propertiesborder-width
,-color
,-style
,-radius
, and the assortedborder-image
propertiespadding
to support drawingoutline
/border-*
properties further awaybox-decoration-break
(and I would argue for it to default toclone
)There’s also prior art for this in Electron-based text editors, such as this in VS Code: microsoft/vscode#54074
The text was updated successfully, but these errors were encountered: