mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-02-25 18:55:32 -06:00
Force videojs to not recreate <video>
Happens with HLS playlist on iOS breaking our event listener on the former <video> element in embed api
This commit is contained in:
parent
30b123257d
commit
32f44a017c
@ -66,6 +66,9 @@ class P2pMediaLoaderPlugin extends Plugin {
|
|||||||
player.ready(() => player.error(error))
|
player.ready(() => player.error(error))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Workaround to force video.js to not re create a video element
|
||||||
|
(this.player as any).playerElIngest_ = this.player.el().parentNode
|
||||||
} else {
|
} else {
|
||||||
// FIXME: typings https://github.com/Microsoft/TypeScript/issues/14080
|
// FIXME: typings https://github.com/Microsoft/TypeScript/issues/14080
|
||||||
(videojs as any).Html5Hlsjs.addHook('beforeinitialize', (videojsPlayer: any, hlsjs: any) => {
|
(videojs as any).Html5Hlsjs.addHook('beforeinitialize', (videojsPlayer: any, hlsjs: any) => {
|
||||||
|
Loading…
Reference in New Issue
Block a user