mirror of
https://github.com/vichan-devel/vichan.git
synced 2025-02-21 21:19:36 +01:00
youtube.js: format
This commit is contained in:
parent
b822a76b23
commit
023e59d88f
@ -22,13 +22,12 @@
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
onready(function(){
|
||||
var do_embed_yt = function(tag) {
|
||||
onready(function() {
|
||||
let do_embed_yt = function(tag) {
|
||||
$('div.video-container a', tag).click(function() {
|
||||
var videoID = $(this.parentNode).data('video');
|
||||
let videoID = $(this.parentNode).data('video');
|
||||
|
||||
$(this.parentNode).html('<iframe style="float:left;margin: 10px 20px" type="text/html" '+
|
||||
$(this.parentNode).html('<iframe style="float:left;margin: 10px 20px" type="text/html" ' +
|
||||
'width="360" height="270" src="//www.youtube.com/embed/' + videoID +
|
||||
'?autoplay=1&html5=1" allowfullscreen frameborder="0"/>');
|
||||
|
||||
@ -42,4 +41,3 @@ onready(function(){
|
||||
do_embed_yt(post);
|
||||
});
|
||||
});
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user