Thank You 2020: Difference between revisions
Jump to navigation
Jump to search
Content deleted Content added
Seddon (WMF) (talk | contribs) No edit summary |
Seddon (WMF) (talk | contribs) No edit summary |
||
Line 1,126: | Line 1,126: | ||
var testVideo = document.createElement('video'); |
var testVideo = document.createElement('video'); |
||
var testResult = testVideo.canPlayType('video/webm; codecs="vp8, vorbis"'); |
|||
var vidFrame; |
var vidFrame; |
||
if ( |
if ( testResult === 'probably' ) { |
||
vidFrame = '<iframe src="https://commons.wikimedia.org/wiki/File:Wikipedia_-_Edit_2019.webm?embedplayer=yes" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" frameborder="0"></iframe>'; |
vidFrame = '<iframe src="https://commons.wikimedia.org/wiki/File:Wikipedia_-_Edit_2019.webm?embedplayer=yes" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" frameborder="0"></iframe>'; |
||
} else { |
} else { |
||
Line 1,133: | Line 1,134: | ||
} |
} |
||
$('.video-container').html( vidFrame ); |
$('.video-container').html( vidFrame ); |
||
if ( |
if ( testResult !== 'probably' ) { |
||
$('.video-container').insertAfter('<div class="frb-inline-disclaimer"> This video is hosted by YouTube, LLC, a third-party service; please see their <a class="cta" href="https://policies.google.com/privacy" title=" privacy policy" target="_blank">privacy policy</a> and <a class="cta" href="https://policies.google.com/terms" title="Terms of Service" target="_blank">terms of service</a>. </div>'); |
$('.video-container').insertAfter('<div class="frb-inline-disclaimer"> This video is hosted by YouTube, LLC, a third-party service; please see their <a class="cta" href="https://policies.google.com/privacy" title=" privacy policy" target="_blank">privacy policy</a> and <a class="cta" href="https://policies.google.com/terms" title="Terms of Service" target="_blank">terms of service</a>. </div>'); |
||
} |
} |