mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-02 01:08:48 +00:00
LibWeb: Implement TextTrack.id
This commit is contained in:
parent
ab91a616b8
commit
ba8e77df16
Notes:
sideshowbarker
2024-07-17 18:46:57 +09:00
Author: https://github.com/jamierocks
Commit: ba8e77df16
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/447
Reviewed-by: https://github.com/awesomekling
4 changed files with 23 additions and 1 deletions
|
@ -48,6 +48,12 @@ void HTMLTrackElement::attribute_changed(FlyString const& name, Optional<String>
|
|||
} else if (name.equals_ignoring_ascii_case("srclang"sv)) {
|
||||
m_track->set_language(value.value_or({}));
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/media.html#dom-texttrack-id
|
||||
// For tracks that correspond to track elements, the track's identifier is the value of the element's id attribute, if any.
|
||||
if (name.equals_ignoring_ascii_case("id"sv)) {
|
||||
m_track->set_id(value.value_or({}));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue