From 253a93003225ed2fe1d0a7ddec41c17c0f846bd4 Mon Sep 17 00:00:00 2001 From: gemstone Date: Mon, 16 Dec 2024 16:00:59 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20=E4=BF=AE=E5=A4=8DVivo=20?= =?UTF-8?q?playsinline=E5=A4=B1=E8=B4=A5=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/xgplayer/src/mediaProxy.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/xgplayer/src/mediaProxy.js b/packages/xgplayer/src/mediaProxy.js index 4c5b9303b..6d7d55e5d 100644 --- a/packages/xgplayer/src/mediaProxy.js +++ b/packages/xgplayer/src/mediaProxy.js @@ -203,6 +203,11 @@ class MediaProxy extends EventEmitter { this.media.autoplay = true } + // Warning:一些移动端浏览器(Like Vivo)需要直接设置JS属性,否则会导致失效 + if (options.playsinline) { + this.media.playsinline = true + } + /** * @private */