I am trying to embed a hubspot video on a CMS page and I have an issue with the video auto-pausing when the tab changes, and when the video doesn’t automatically resume play when I return to the video tab. Is there any walk around to this?
Hey, @Uzo101
Thanks for your question.
This pausing behaviour is expected as it is part of how browsers handle resource management. There isn’t a setting or switch to override this. If you have a developer or developer resources, you could look at leveraging the visibilitychange event — Document: visibilitychange event.
I hope this helps get you moving forward! — Jaycee
So hubspot autopauses the video once the user switches the tab.
you can add a custom module to your theme with these,
This is the fields.json you can use
[ {"name" : "add_video_link","label" : "Link","required" : false,"locked" : false,"supported_types" : [ "FILE" ],"type" : "link","default" : {"url" : {"content_id" : null,"type" : "EXTERNAL","href" : "" },"open_in_new_tab" : false,"no_follow" : false } }]
And this html
<div class="video-module"><video muted loop autoplay><source src="{{ module.add_video_link.url.href }}" type="video/mp4"></video></div>