feat: add support for youtube lives previews (#468)
This commit is contained in:
parent
b8b9c976f6
commit
fdc5757c63
3 changed files with 5 additions and 2 deletions
|
|
@ -94,7 +94,8 @@ function parseYoutubeUrl(url: string) {
|
|||
const patterns = [
|
||||
/(?:youtube\.com\/watch\?v=|youtu\.be\/|youtube\.com\/embed\/)([^&\n?#]+)/,
|
||||
/youtube\.com\/watch\?.*v=([^&\n?#]+)/,
|
||||
/youtube\.com\/shorts\/([^&\n?#]+)/
|
||||
/youtube\.com\/shorts\/([^&\n?#]+)/,
|
||||
/youtube\.com\/live\/([^&\n?#]+)/
|
||||
]
|
||||
|
||||
let videoId: string | null = null
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue