[webvtt] Proper conventions when converting to XML

AliceWonderMiscreations has just created a new issue for https://github.com/w3c/webvtt:

== Proper conventions when converting to XML ==
If there is a user list for this, please inform me. I looked for one and feel a user e-mail list would be better for this, but I did not find one. Due to autism I do not always do well in real time communication so irc isn't something I like to use.

-=-

There is a live demo for what I am doing but some of the content is not suitable for all audiences and I do not feel comfortable linking to it on this kind of a resource.

Anyway, I'm creating an html5 jukebox player for audio that supports captions, subtitles, and chapters.

For captions/subtitles I am taking the WebVTT cue strings and converting them to valid HTML5 but that creates some inconsistencies as far as CSS is concerned.

For example I turn [lt]v The Amazing Spiderman[gt]some stuff[lt]/v[gt] into [lt]span data-voice="The Amazing Spiderman"[gt]some stuff[lt]/span[gt]

That changes the CSS pseudo-selectors needed to stylize what Peter Parker says.

Is that still considered valid thing to do when rendering a WebVTT string or do I need to find another way?

Second thing, my understanding is the WebVTT allows some HTML entitles that are not allowed in XML and I'm an XML junkie that serves my content as application/xhtml+xml and so any WebVTT strings that include entitles have to be converted to what XML accepts.

Is the list of entities identical to HTML or are there additions? Also I have seen some WebVTT files in the wild that use U+nnnn - is that valid? e.g. do I need to look for those and convert them to [amp]#x; style entities or can I ignore them?

Thank you for suggestions.

Please view or discuss this issue at https://github.com/w3c/webvtt/issues/366 using your GitHub account

Received on Sunday, 24 September 2017 18:26:34 UTC