Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cover block with video not playing automatically in iOS #39148

Closed
renatho opened this issue Aug 29, 2024 · 2 comments
Closed

Cover block with video not playing automatically in iOS #39148

renatho opened this issue Aug 29, 2024 · 2 comments
Labels
Customer Report Issues or PRs that were reported via Happiness. aka "Happiness Request", or "User Report" [Feature] VideoPress A feature to help you upload and insert videos on your site. [Platform] Simple [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] VideoPress A standalone plugin to add high-quality VideoPress videos to your site. [Pri] Low [Status] Priority Review Triggered The guild in charge of triage has been notified of this issue in Slack Triaged [Type] Bug When a feature is broken and / or not performing as intended

Comments

@renatho
Copy link
Contributor

renatho commented Aug 29, 2024

Impacted plugin

Jetpack, VideoPress

Quick summary

In this ticket (8579784-zd-a8c), a user reports that their cover blocks with videos are not playing in iOS.

I could see the issue in their site, and I could also reproduce it one time in a test site in wordpress.com, but when I moved it to atomic the issue stopped (the cover I added started playing automatically as expected). I tried to reproduce more times, but I wasn't able to because for some reason I started having some issues with the cover block in new test sites (not being able to apply the video, or the editor breaking).

Steps to reproduce

You need an iPhone or an iPhone simulator to test it. I used the iPhone simulator from the Xcode to reproduce it.

  1. Open the Safari in your iOS.
  2. Navigate to the site https://digitalreplica3d.com/
  3. See that the cover is static.
Screen.Recording.2024-08-29.at.18.28.25.mp4

A clear and concise description of what you expected to happen.

The video of the cover should play automatically.

What actually happened

The video is static.

Impact

Some (< 50%)

Available workarounds?

No and the platform is unusable

If the above answer is "Yes...", outline the workaround.

I started writing the following snippet to fix the issue that worked when running from the console (debugging through Safari), but after that I noticed that the user has a Premium plan, where we can't inject scripts. So it wasn't possible to test it.

And in my test, when I migrated my site to atomic the issue didn't happen anymore.

const videosWorkaround = ( originalElement ) => {
  let newElementHtml = originalElement.outerHTML;
  newElementHtml = newElementHtml.replace(
    /^<(\w+)/,
    `<$1 playsinline autoplay`
  );

  originalElement.insertAdjacentHTML('beforebegin', newElementHtml);

  const nextElement = originalElement.nextElementSibling;
  if (nextElement && nextElement.classList.contains('vjs-poster')) {
    nextElement.remove();
  }

  originalElement.remove();
}

document.querySelectorAll( '.vjs-tech' ).forEach( videosWorkaround );

Platform (Simple and/or Atomic)

Simple

Logs or notes

  • Tested in Safari using a simulator with iPhone 15 Pro Max.
@renatho renatho added [Type] Bug When a feature is broken and / or not performing as intended [Feature] VideoPress A feature to help you upload and insert videos on your site. [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ Needs triage Ticket needs to be triaged labels Aug 29, 2024
@github-actions github-actions bot added [Status] Priority Review Triggered The guild in charge of triage has been notified of this issue in Slack [Plugin] VideoPress A standalone plugin to add high-quality VideoPress videos to your site. [Platform] Simple labels Aug 29, 2024
Copy link
Contributor

Support References

This comment is automatically generated. Please do not edit it.

  • 8579784-zen

@github-actions github-actions bot added [Pri] BLOCKER Customer Report Issues or PRs that were reported via Happiness. aka "Happiness Request", or "User Report" labels Aug 29, 2024
@jeherve jeherve added [Pri] Low Triaged and removed [Pri] BLOCKER Needs triage Ticket needs to be triaged labels Aug 30, 2024
@jeherve jeherve moved this from Needs Triage to Triaged in Automattic Prioritization: The One Board ™ Aug 30, 2024
@dsas
Copy link
Contributor

dsas commented Oct 8, 2024

Closing in favour of Automattic/wp-calypso#92856

@dsas dsas closed this as not planned Won't fix, can't repro, duplicate, stale Oct 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Customer Report Issues or PRs that were reported via Happiness. aka "Happiness Request", or "User Report" [Feature] VideoPress A feature to help you upload and insert videos on your site. [Platform] Simple [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] VideoPress A standalone plugin to add high-quality VideoPress videos to your site. [Pri] Low [Status] Priority Review Triggered The guild in charge of triage has been notified of this issue in Slack Triaged [Type] Bug When a feature is broken and / or not performing as intended
Development

No branches or pull requests

3 participants