can-autoplay icon indicating copy to clipboard operation
can-autoplay copied to clipboard

canAutoPlay.video() opens a fullscreen overlay on iPhone

Open fabianwohlfart opened this issue 4 years ago • 2 comments

Hi, on iOS 14.2 the canAutoPlay.video() opens a fullscreen overlay of the test with 0 seconds. Can we prevent this?

fabianwohlfart avatar Jul 14 '21 08:07 fabianwohlfart

That probably makes sense since the default is inline:false, https://github.com/video-dev/can-autoplay/blob/master/lib/index.js#L8 The quick fix is for you to pass inline: true to .video().

canAutoplay.video({
  inline: true
});

I wonder whether we should default inline to true.

gkatsev avatar Jul 14 '21 23:07 gkatsev

Definitely set inline as true by default, otherwise it's broken on iOS, just ran into this in some code that was in production and it sucked.

mayeaux avatar Jan 06 '22 21:01 mayeaux