gecko-dev/dom/media/webvtt
alwu c2ca57258b Bug 1305732 - part5 : set CSS properties directly on '::cue'. r=heycam,emilio
According to the spec [1], we have to set those CSS properties on the root node, and then this root node would have a child node, background box [2], which would contain all other child nodes.

In our case, the background box is `cueDiv` [3].

In theory, all those properties set on the root node should be inherited by the background box. However, when the background box is a pseudo element `::cue`, they won't be directly inherit from the the background box's parent, inherited styles would acutally come from video instead.

Therefore, we have to directly set these properties on the pseudo element and mark them as `!important` to avoid being overrided by user style script.

[1] https://www.w3.org/TR/webvtt1/#ref-for-list-of-webvtt-node-objects-9
[2] https://www.w3.org/TR/webvtt1/#webvtt-cue-background-box
[3] https://searchfox.org/mozilla-central/rev/11712bd3ce7454923e5931fa92eaf9c01ef35a0a/dom/media/webvtt/vtt.jsm#533-534

Differential Revision: https://phabricator.services.mozilla.com/D35694

--HG--
extra : moz-landing-system : lando
2019-07-09 01:42:45 +00:00
..
tests Bug 1514594: Part 3 - Change ChromeUtils.import API. 2019-01-17 10:18:31 -08:00
components.conf Bug 1524688: Part 52 - Convert WebVTT components to static registration. r=heycam 2019-01-30 11:31:25 -08:00
moz.build Bug 1524688: Part 52 - Convert WebVTT components to static registration. r=heycam 2019-01-30 11:31:25 -08:00
nsIWebVTTListener.idl
nsIWebVTTParserWrapper.idl Bug 1562021 - part3 : cancel old VTT listener when we start a new load. r=jya,baku 2019-07-03 23:23:29 +00:00
package.json
update-webvtt.js
vtt.jsm Bug 1305732 - part5 : set CSS properties directly on '::cue'. r=heycam,emilio 2019-07-09 01:42:45 +00:00
WebVTTParserWrapper.jsm Bug 1562021 - part3 : cancel old VTT listener when we start a new load. r=jya,baku 2019-07-03 23:23:29 +00:00