HTML5 - 7.4.2 Focus management

Hi,
Trying to find some answers for my questions regarding
"contenteditable='true' and focus management", I went through the
documentation and couldn't find anything about it.
I saw that elements with the "draggable" attribute become focusable.
But what about "contenteditable"?
My main questions/suggestions are:
 - Should the contenteditable element be focusable?
 - And its children elements?
 - How about events (like onChange) for the editable element and/or
for its children?

Here is a simple HTML example:
<ol contenteditable='true'>
    <li>Item 1</li>
    <li>Item 2</li>
    <li>Item 3</li>
</ol>

By default none of this elements are focusable, correct?
If I bind an onFocus/onBlur event handlers on the OL element, both get
triggered when I click on it and off it... Which means that it became
focusable due to the contenteditable attribute!
Going further, if I turn the LI elements focusable by adding the
"tabindex='-1'" attribute and also bind onFocus/onBlue event handlers
on them, when I click any LI item, here is what is currently
happening:
 - In Chrome (can't remeber version), this is the event order: LI's
onFocus -> LI's onBlur -> OL's onFocus;
 - In Firefox (can't remeber version), the only event triggered is LI's onFocus;

This is more like a big forum question, but it would be nice to have
some specification around this behavior. :-)

Hope to hear back from you!

Thank you,
Guilherme Johansson Tramontina
Consultant Developer at ThoughtWorks Brazil

Received on Friday, 24 September 2010 15:55:22 UTC