4

On the video component when I input a YouTube video, the share, watch later, video title and up next sections are visible, but are not clickable, is there a solution to this?

5

The video component is handled by mediaelement.js, you'll need to edit the JavaScript file for this service in order to fix this issue.

If you go to /sitecore/media library/Base Themes/Core Libraries/scripts/mediaelement-and-player and scroll down to the "media" section, download the mediaelement-and-player.jsmediaelement-and-player.js file there.

Copy this file somewhere to make a backup.

In order to make the default YouTube controls usable you need to turn off the "big play button" and stop the Iframe layer from being created, as it's putting divs in that cover the entire screen, preventing you from being able to click on the desired elements.

Comment out the following lines in the mediaelement-and-player.js file

  1. t.createIframeLayer();
  2. bigPlay.className = t.options.classPrefix + 'overlay ' + t.options.classPrefix + 'layer ' + t.options.classPrefix + 'overlay-play';
  3. bigPlay.innerHTML = '<div class="' + t.options.classPrefix + 'overlay-button" role="button" tabindex="0" ' + ('aria-label="' + _i18n2.default.t('mejs.play') + '" aria-pressed="false"></div>');

Upload this file back to /sitecore/media library/Base Themes/Core Libraries/scripts/mediaelement-and-player and your video player elements will will now be clickable.

| improve this answer | |
  • Thank you Jack for sharing. Do you have a confirmed support ticket number so this gets addressed in a future release? – Michael West Jun 12 '19 at 15:45
  • No problem. I haven't raised a ticket with Sitecore support, this is a solution that I'd figured out when I ran into this issue. I don't have a certification yet so unfortunately I cannot raise tickets, I'd be happy to get a member of my team to do so if it would be useful, though! – Jack Hayward Jun 12 '19 at 15:48
  • The SXA has been really great about acknowledging reported defects and making sure they are fixed before new features. Submitting a ticket would be really helpful and including your solution will give them a great head start. – Michael West Jun 12 '19 at 15:58
  • 1
    Perfect, I'll get a ticket submitted first thing tomorrow then! Thanks, Michael. – Jack Hayward Jun 12 '19 at 16:55
  • 1
    I've logged a support ticket containing the issue and solution, here's the ticket number: 533864 – Jack Hayward Jun 13 '19 at 8:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.