Closed Bug 570641 Opened 14 years ago Closed 14 years ago

[HTML5] Fallback content escaping from <audio>/<video> elements

Categories

(Core :: DOM: HTML Parser, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: kinetik, Unassigned)

References

()

Details

When an audio or video element is inside a paragraph and the media element contains fallback content inside a div, the div containing the fallback content escapes from the containing paragraph and is displayed to the user.

The testcase in the URL works as expected (does not display any text) in the latest Minefield nightly with the HTML5 parser disabled and in the latest WebKit nightly.  In the latest Minefield nightly with the HTML5 parser enabled, "FAIL" is displayed.

Originally reported here: https://groups.google.com/a/webmproject.org/group/webm-discuss/msg/affbe97fcc86f5e1
That's the behavior specified in the spec, no?  <video> says:

   If the element has a src attribute: zero or more track elements, then
   transparent, but with no media element descendants.
   If the element does not have a src attribute: one or more source elements,
   then zero or more track elements, then transparent, but with no media element
   descendants.

"transparent" means you can contain the kids your parent can.  Since <div> would normally autoclose <p>, it autocloses both <video> and <p>.

So either you're asking for a spec change here, or it's just a bug in the content.
That makes sense.  I looked at the HTML 5 spec to determine the correct behaviour before filing, but I only looked for the phrase "fallback content".
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
Moreover, as far as parsing behavior goes, the spec bit cited aren't the ones that govern. The parser behaves per spec, because video and audio aren't defined to be scoping.
You need to log in before you can comment on or make changes to this bug.