I created a tabs containing separate videos, but they don't stop playing when switching

I’m hoping to get some wisdom on this from anybody:

I’ve created five tabs that all show a video. However, once you click play on any of the clips, and you then switch to another tab, the video keeps playing in the background.

This is of course because the tab block doesn’t actually remove the videos, it just hides them.

How do I ensure the video stops playing once you click to another tab?


Scroll down after the first header image, then there’s the tab block with 5 pictures all leading to a different video showed above.

This should be pretty easy to achieve, just requires a couple of lines of JS.
Would recommend a code block instead of an (custom) interaction.

I can also see here a native integration via block options, it’s actually pretty useful.
Should be the default behaviour, when using a video block.

hi Marius, thank you for your reply. I unfortunately don’t understand what you are saying in both paragraphs?

  • It’s currently not possible, but it can be achieved via custom code
  • It could be implemented as default behaviour, like in a future update

This is probably not going to fix but if what you targeted is visibility (show / hidden) then maybe try to target display (block / none) or (flex/none).
Both visibility and display are css properties.
Hope this works.

1 Like

Hi there @boris,

As @Marius pointed out, this isn’t currently possible with the Tabs block and Video block.
However, we have implemented this in the Modal block so this definitely should be ported here as well as on the Accordion block.

Thanks for bringing this up, I’ll try to and get this added as soon as possible :+1:

1 Like

Ok Louis, thank you and the team

This has now been implemented as default behaviour in for:
Accordion block, Tab block, Popover and Modal

Thanks for taking the time to bring this up.



amazing! Thank you so much

hi Louis: I have noticed a bug with this update: when I switch tabs while a video is playing, indeed the video stops, but it starts playing again once I then scroll down

apparently this only occurs for videos that have auto-play on