Open zcorpan opened 9 years ago
https://zcorpan.github.io/live-webvtt-viewer/#vtt=WEBVTT%0A%0A00%3A00%3A00.000+--%3E+00%3A00%3A10.000%0A%3Cc.foo%26amp%3Bbar%3Eclass%3C%2Fc%3E%0A&style=%3A%3Acue(.foo%5C%26amp%5C%3Bbar)+%7B%0Abackground%3Ared%0A%7D%0A%3A%3Acue(.foo%5C%26bar)+%7B%0Acolor%3Alime%0A%7D (background is red in webkit/blink/presto)
Depends on: #253
Depends on: #266
Maybe not change this if we do #270
https://w3c.github.io/webvtt/#webvtt-start-tag-class-state
Should we support character escapes in classes?
The class name above is parsed to
foo&bar
, notfoo&bar
. i.e. the Selector to match it would be::cue(.foo\&\;bar)
and not::cue(.foo\&bar)
. I think this is a surprising and unnecessary, I don't see any problem with supporting escapes here as well as in the annotation (which is already supported).The syntax disallows "&" in classes (so the above is not valid):
https://w3c.github.io/webvtt/#webvtt-cue-span-start-tag