You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[iOS] Block Vidéo with autoplay not working #41573
Hey @gturpin-dev 👋 ! Thanks for reporting the issue 🙇 .
I checked it further and I'm not sure if the behavior you describe is an actual bug. As far as I checked, the video autoplay feature is usually controlled by the browser and is only allowed under certain scenarios. For example, in Chromium browsers, a video is only auto-played if it has the attribute muted. On Safari, on the other hand, it requires to have both muted and playsinline attributes.
I think we can't really expand the logic of the Video block to ensure that the autoplay functionality will be applied since ultimately, this depends on the browser.
So would it be wrong to add playsinline to support safari everytime the muted attribute is added ?
That would be one option but not sure if it should be automatically enabled. The content could be viewed with any browser, not just Safari, so this workaround might be not necessary in all cases. Besides, it might be a bit confusing for the user that changing one of the attributes of the Video block enables other ones at the same time 🤔 .
I'm wondering if we could inform the user and let them decide whether to enable other attributes when setting the autoplay attribute.
I understand what you said about browser but do you think Safari will support it soon ? I think it's also our job to support that kind of things.
Tell me if i'm wrong :)
My gut feeling about the autoplay issue in Safari is that is more related to a user experience enhancement than lack of support. I guess that the purpose of not allowing videos to autoplay with sound is to prevent disturbing the user. Although, I'm not sure why Safari also requires the playsinline.
Activity
fluiddot commentedon Jun 13, 2022
Hey @gturpin-dev 👋 ! Thanks for reporting the issue 🙇 .
I checked it further and I'm not sure if the behavior you describe is an actual bug. As far as I checked, the video autoplay feature is usually controlled by the browser and is only allowed under certain scenarios. For example, in Chromium browsers, a video is only auto-played if it has the attribute
muted. On Safari, on the other hand, it requires to have bothmutedandplaysinlineattributes.I think we can't really expand the logic of the Video block to ensure that the autoplay functionality will be applied since ultimately, this depends on the browser.
gturpin-dev commentedon Jun 13, 2022
Thanks for explanations.
So would it be wrong to add
playsinlineto support safari everytime the muted attribute is added ?I understand what you said about browser but do you think Safari will support it soon ?
I think it's also our job to support that kind of things.
Tell me if i'm wrong :)
fluiddot commentedon Jun 13, 2022
That would be one option but not sure if it should be automatically enabled. The content could be viewed with any browser, not just Safari, so this workaround might be not necessary in all cases. Besides, it might be a bit confusing for the user that changing one of the attributes of the Video block enables other ones at the same time 🤔 .
I'm wondering if we could inform the user and let them decide whether to enable other attributes when setting the
autoplayattribute.My gut feeling about the
autoplayissue in Safari is that is more related to a user experience enhancement than lack of support. I guess that the purpose of not allowing videos to autoplay with sound is to prevent disturbing the user. Although, I'm not sure why Safari also requires theplaysinline.gturpin-dev commentedon Jun 14, 2022
It was an interesting discussion, thanks for your time.
If there is nothing to do, you can close this isssue.