Day 91 of 100DaysOfSpec, the video element, contd. and the audio element
I am reading and taking notes on the HTML specifications for 100 days as part of #The100DayProject. Read the initial intent/backstory. I am a Microsoft employee but all opinions, comments, etc on this site are my own. I do not speak on behalf of my employer, and thus no comments should be taken as representative of Microsoft's official opinion of the spec. Subsections not listed below were read without comment.
Currently reading in 4.7.6 The video element
UAs = user agents = browsers, etc.
4.7.6 The video element, contd.
- UAs have to provide controls for closed captions, audio description tracks, etc. without “interfering” with the way a page would usually render. So, no thinking outside the box. ;]
- Can display the video content fullscreen or in a new window. Controls to enable alternate views also can’t mess with expected page rendering, but the UA can be freer with control placement when the video is in these independent views.
- The UA can “allow video playback to affect system features that could interfere with the user's experience”. The example they give is disabling screensaver that otherwise would have popped up while watching a longish video.
4.7.7 The audio element
“An audio element represents a sound or audio stream.”
Attributes, besides globals:
src
cross origin
: how these requests are handledpreload
: hint at how much buffering neededautoplay
: hint that the UA can autoplay the audiomedia group
: “Groups media elements together with an implicit MediaController”loop
muted
controls
: show the UA controls
More notes:
- If it has a
src
attribute set, can contain 0+track
elements. - If no
src
attribute, 0+source
elements, then 0+track
elements. - After these elements, the
audio
element’s content model is transparent, which means whatever you can put in the element’s parent (or closest ancestor that isn’t also transparent…), you can put inside the element. In this case there is an exception against media elements. - Also this element’s content is not exposed to the user, it’s fallback content for older browsers, not meant for accessibility (just like the fallback content in
video
). - Only allowed ARIA role is
application
.