[Bug 27222] [Shadow]: "title" attribute should inherit in shadow DOM

https://www.w3.org/Bugs/Public/show_bug.cgi?id=27222

--- Comment #5 from Hayato Ito <hayato@chromium.org> ---
(In reply to Koji Ishii from comment #4)
> (In reply to Hayato Ito from comment #3)
> > I don't think this issue should depend on bug 23887.
> 
> Agreed.
> 
> I acknowledge an issue here, though in a slightly different view.
> 
> The HTML spec says:
> > If this attribute is omitted from an element, then it implies
> > that the title attribute of the nearest ancestor HTML element
> > with a title attribute set is also relevant to this element.
> 
> The issue is that "the nearest ancestor HTML element" here is
> ambiguous and the behavior at the shadow boundaries needs to be
> defined.

I think that's well defined in the DOM standard.
https://dom.spec.whatwg.org/#concept-tree-ancestor

There is no ancestor/descendant relationship between two nodes if they don't
participate in the same node tree.


> 
> The same issue exists in the "lang" attribute and :lang()
> selector.
> 
> "dir" should not affect shadow trees, and we probably should set
> the CSS 'unicode-bidi' property to 'isolate' (though it may be
> automatically implied in actual implementations.)
> 
> "contenteditable" is already defined in the spec that it must
> not propagate to shadow trees, so that's good.
> 
> "role"/ARIA, I need to look into further.
> 
> So, my preferred approach to this bug is that, first we go
> through all attributes and come up with how each should
> traverse ancestors.
> 
> With that done, all attributes can categorized into:
> 1. No propagation (e.g., id, class, style, etc.)
> 2. Traversal is only within a tree, stop at the shadow boundaries.
> 3. Traversal occurs in the composed tree.
> 4. Traverse using the event path.
> 5. Maybe more options?

I'm not a fan of using 'event path' here. An event path should not be abused. 
Using the ancestor chain in the composed tree should be enough, shouldn't it?
Assuming that we don't want attributes of insertion points (or shadow roots) to
have any effects on 'inheritance'.




> 
> If any attributes turned out to follow the event path, we could
> simply say "this and that attribute follow event path" and we can
> resolve this bug, though implementations of such attributes need
> to wait for the bug to be resolved.
> 
> Note that I'm new in this area, sorry in advance if some of these
> were already discussed elsewhere.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Wednesday, 17 December 2014 08:13:40 UTC