[csswg-drafts] [css-ui-4] Be more precise about event dispatching of pointer events on the ellipsis

frivoal has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-ui-4] Be more precise about event dispatching of pointer events on the ellipsis ==
In the section about `text-overflow`, [CSS-UI](https://drafts.csswg.org/css-ui-3/#text-overflow) states that
> Ellipsing only affects rendering and must not affect [...] dispatching of pointer events

This phrasing isn't super clear, and makes me (and @fantasai) [wonder](https://github.com/w3c/web-platform-tests/pull/5285#discussion_r125208034) if the behavior is fully defined.

If there is only a block element with textual content, then there is no ambiguity and events should go to that element.

However, if there are `<span>s` or other inline elements in the block element, and that the elided content belonged to them, then it does not seem clear whether the pointer events should be dispatched the (inline) element whose content was elided, or to the block element to which the ellipsis is attached.

My initial reading of the spec made me think it may have intended the events to be dispatched to the element whose content was elided, but the wording does look somewhat ambiguous to me, and current implementations differ: only Firefox dispatches the events to the elided inline element, while Chrome, Safari, and Edge dispatch the events to the block element to which the ellipsis is attached.

My suggestion is to:
* leave the ambiguous phrasing in level 3, only test that events get dispatched (without checking if they go to the to the inline with elided content first and bubble up to the block or if they get dispatched to the block directly), and accept both the Firefox and the Chrome/Edge/Safari behaviors as conformant for now.
* decide one way or the other in level 4, clarify, add tests accordingly, and file bugs on the relevant browsers.



Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1637 using your GitHub account

Received on Friday, 21 July 2017 07:34:00 UTC