Skip to content

Instantly share code, notes, and snippets.

@brunopulis
Created April 29, 2014 19:56
Show Gist options
  • Save brunopulis/9b5c209048155bb21862 to your computer and use it in GitHub Desktop.
Save brunopulis/9b5c209048155bb21862 to your computer and use it in GitHub Desktop.
Marker Video
/*
Funcao que marca o video que esta
sendo assistido como uma mascara
de "Assistindo agora"
*/
$(function() {
var thumb = $('.video-item a');
var mask = $( '.video-item a .mask' ).hide();
thumb.on('click', function(e) {
e.preventDefault();
var data_video = $(this).data('video');
$('iframe').attr('src', data_video);
// Toggle Mask
mask.hide();
$(this).find('.mask').show();
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment