diff options
author | Chocobozzz <me@florianbigard.com> | 2020-11-10 16:47:25 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-11-10 16:47:25 +0100 |
commit | b9da21bd5a3ad00f44997930391e3316182a07db (patch) | |
tree | 7c56d4c2ad2956568b1b0c6622a18636aa9963e8 /client/src | |
parent | 2af337c83905c420b2d9022ee6fd3d6ef5fd1e42 (diff) | |
download | PeerTube-b9da21bd5a3ad00f44997930391e3316182a07db.tar.gz PeerTube-b9da21bd5a3ad00f44997930391e3316182a07db.tar.zst PeerTube-b9da21bd5a3ad00f44997930391e3316182a07db.zip |
Hide dock if there are no title/description
Diffstat (limited to 'client/src')
-rw-r--r-- | client/src/standalone/videos/embed.ts | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/client/src/standalone/videos/embed.ts b/client/src/standalone/videos/embed.ts index 66033158b..115d37ced 100644 --- a/client/src/standalone/videos/embed.ts +++ b/client/src/standalone/videos/embed.ts | |||
@@ -558,9 +558,9 @@ export class PeerTubeEmbed { | |||
558 | 558 | ||
559 | Object.assign(options, { | 559 | Object.assign(options, { |
560 | p2pMediaLoader: { | 560 | p2pMediaLoader: { |
561 | playlistUrl: 'http://localhost:9000/live/toto/master.m3u8', | 561 | playlistUrl: hlsPlaylist.playlistUrl, |
562 | segmentsSha256Url: hlsPlaylist.segmentsSha256Url, | 562 | segmentsSha256Url: hlsPlaylist.segmentsSha256Url, |
563 | redundancyBaseUrls: [], | 563 | redundancyBaseUrls: hlsPlaylist.redundancies.map(r => r.baseUrl), |
564 | trackerAnnounce: videoInfo.trackerUrls, | 564 | trackerAnnounce: videoInfo.trackerUrls, |
565 | videoFiles: hlsPlaylist.files | 565 | videoFiles: hlsPlaylist.files |
566 | } as P2PMediaLoaderOptions | 566 | } as P2PMediaLoaderOptions |
@@ -663,10 +663,12 @@ export class PeerTubeEmbed { | |||
663 | ? '<span class="text">' + peertubeTranslate('Watching this video may reveal your IP address to others.') + '</span>' | 663 | ? '<span class="text">' + peertubeTranslate('Watching this video may reveal your IP address to others.') + '</span>' |
664 | : undefined | 664 | : undefined |
665 | 665 | ||
666 | this.player.dock({ | 666 | if (title || description) { |
667 | title, | 667 | this.player.dock({ |
668 | description | 668 | title, |
669 | }) | 669 | description |
670 | }) | ||
671 | } | ||
670 | } | 672 | } |
671 | 673 | ||
672 | private buildCSS () { | 674 | private buildCSS () { |