mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-22 21:31:20 -08:00
refactor: Update video element resizing logic in Artplayer and artplayer-proxy-webav
This commit is contained in:
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,
|
||||
});
|
||||
|
||||
@@ -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() {
|
||||
|
||||
Reference in new issue
Block a user