Update Twitch embedding.
This commit is contained in:
parent
a42a211a93
commit
5791268d7c
@ -425,7 +425,7 @@ Embedding =
|
||||
regExp: /^\w+:\/\/(?:www\.|secure\.)?twitch\.tv\/(\w[^#\&\?]*)/
|
||||
el: (a) ->
|
||||
m = a.dataset.uid.match /(\w+)(?:\/v\/(\d+))?/
|
||||
url = "//player.twitch.tv/?#{if m[2] then "video=v#{m[2]}" else "channel=#{m[1]}"}&autoplay=false"
|
||||
url = "//player.twitch.tv/?#{if m[2] then "video=v#{m[2]}" else "channel=#{m[1]}"}&autoplay=false&parent=#{location.hostname}"
|
||||
if (time = a.dataset.href.match /\bt=(\w+)/)
|
||||
url += "&time=#{time[1]}"
|
||||
el = $.el 'iframe',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user