Auto merge of #22563 - dlrobertson:htmltextelement, r=ferjm

script: Implement the HTMLTrackElement API

Implement the basics of the HTMLTrackElement and update the wpt tests.

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] There are tests for these changes

Fixes: https://github.com/servo/servo/issues/22313

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/22563)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2019-01-08 09:15:21 -05:00 committed by GitHub
commit 7c8de38572
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 152 additions and 382 deletions

View file

@ -5,22 +5,22 @@
// https://html.spec.whatwg.org/multipage/#htmltrackelement
[HTMLConstructor]
interface HTMLTrackElement : HTMLElement {
// [CEReactions]
// attribute DOMString kind;
// [CEReactions]
// attribute DOMString src;
// [CEReactions]
// attribute DOMString srclang;
// [CEReactions]
// attribute DOMString label;
// [CEReactions]
// attribute boolean default;
[CEReactions]
attribute DOMString kind;
[CEReactions]
attribute USVString src;
[CEReactions]
attribute DOMString srclang;
[CEReactions]
attribute DOMString label;
[CEReactions]
attribute boolean default;
// const unsigned short NONE = 0;
// const unsigned short LOADING = 1;
// const unsigned short LOADED = 2;
// const unsigned short ERROR = 3;
// readonly attribute unsigned short readyState;
const unsigned short NONE = 0;
const unsigned short LOADING = 1;
const unsigned short LOADED = 2;
const unsigned short ERROR = 3;
readonly attribute unsigned short readyState;
// readonly attribute TextTrack track;
readonly attribute TextTrack track;
};