refactor: Update video element resizing logic in Artplayer and artplayer-proxy-webav

This commit is contained in:
Harvey Zack committed 2024-08-23 10:43:09 +08:00
1 parent b2e54d6969
commit 3a2e7addd9
6 files changed
+9 -14

No files matched your search

@@ -230,10 +230,6 @@ export default function artplayerProxyWebAV(opt = {}) {
art.emit('video:canplaythrough', { type: 'canplaythrough' });
}
def(canvas, 'textTracks', {
get: () => [],
});
def(canvas, 'duration', {
get: () => state.duration,
});
+1 -1
View File
@@ -42,7 +42,7 @@ export default class Subtitle extends Component {
}
get textTrack() {
return this.art.template.$video.textTracks[0];
return this.art.template.$video?.textTracks?.[0];
}
get activeCue() {