mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-23 22:01:20 -08:00
update
This commit is contained in:
1 parent
5f6febce42
commit
b2159e7d4d
9 files changed
+64
-61
No files matched your search
+2
-5
@@ -1,4 +1,4 @@
|
||||
import { errorHandle, getExt } from './utils';
|
||||
import { errorHandle, getExt, setStyle } from './utils';
|
||||
|
||||
export default class Subtitle {
|
||||
constructor(art) {
|
||||
@@ -19,10 +19,7 @@ export default class Subtitle {
|
||||
refs: { $video, $subtitle }
|
||||
} = this.art;
|
||||
|
||||
Object.keys(subtitleStyle).forEach(key => {
|
||||
$subtitle.style[key] = subtitleStyle[key];
|
||||
});
|
||||
|
||||
setStyle($subtitle, subtitleStyle);
|
||||
const $track = document.createElement('track');
|
||||
$track.default = true;
|
||||
$track.kind = 'metadata';
|
||||
|
||||
Reference in new issue
Block a user