- From: CSS Meeting Bot via GitHub <sysbot+gh@w3.org>
- Date: Wed, 22 Jan 2025 16:55:00 +0000
- To: public-css-archive@w3.org
The CSS Working Group just discussed `[css-overflow-5] :focus and :focus-within styles with focused scroller pseudo-element`, and agreed to the following: * `RESOLVED: The document.activeElement is the scroll container for a focused ::scroll-marker or ::scroll-button. :focus matches only on the specific focused pseudo-element. :focus-within matches on the ::scroll-marker-group for ::scroll-marker, and the scroll container and all ancestors for both ::scroll-marker and ::scroll-button` <details><summary>The full IRC log of that discussion</summary> <andreubotella> flackr: Scroll markers and scroll buttons are focusable, and we need to have reasonable behavior for the active element and :focus and :focus-within pseudos<br> <andreubotella> flackr: the focus elment has to be an element, or it would break existing content<br> <andreubotella> flackr: similar to shadow dom<br> <andreubotella> flackr: similar to shadow dom where the host is focused, the scrolling container is the host of the pseudoelements<br> <andreubotella> flackr: the :focus and :focus-within pseudos follow the existing behavior, so :focus only matches on the pseudo which is focused, and :focus-within matches on the scroll container and the scroll marker group<br> <andreubotella> flackr: and any ancestor of the scroll container<br> <andreubotella> flackr: if you have a focused element, that's the thing that has focused and the ancestors have :focus-within<br> <andreubotella> flackr: this does the same for pseudos with the requirement that it needs to be an element<br> <flackr> Proposed resolution: The document.activeElement is the scroll container for a focused ::scroll-marker or ::scroll-button. :focus matches only on the specific focused pseudo-element. :focus-within matches on the ::scroll-marker-group for ::scroll-marker, and the scroll container and all ancestors for both ::scroll-marker and ::scroll-button<br> <andreubotella> RESOLVED: The document.activeElement is the scroll container for a focused ::scroll-marker or ::scroll-button. :focus matches only on the specific focused pseudo-element. :focus-within matches on the ::scroll-marker-group for ::scroll-marker, and the scroll container and all ancestors for both ::scroll-marker and ::scroll-button<br> <fantasai> scribenick: fantasai<br> <emilio> It looks reasonable, but flackr is there any way for script to detect whether the scroll container or a marker is focused?<br> </details> -- GitHub Notification of comment by css-meeting-bot Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/11361#issuecomment-2607770396 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 22 January 2025 16:55:01 UTC