]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/shared/shared-video-playlist/video-playlist-miniature.component.ts
Reorganize left menu and account menu
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-video-playlist / video-playlist-miniature.component.ts
CommitLineData
830b4faf 1import { Component, Input } from '@angular/core'
67ed6552 2import { VideoPlaylist } from './video-playlist.model'
830b4faf
C
3
4@Component({
5 selector: 'my-video-playlist-miniature',
6 styleUrls: [ './video-playlist-miniature.component.scss' ],
7 templateUrl: './video-playlist-miniature.component.html'
8})
9export class VideoPlaylistMiniatureComponent {
10 @Input() playlist: VideoPlaylist
f0a39880 11 @Input() toManage = false
bce47964
C
12 @Input() displayChannel = false
13 @Input() displayDescription = false
14 @Input() displayPrivacy = false
f0a39880
C
15
16 getPlaylistUrl () {
17119e4a 17 if (this.toManage) return [ '/my-library/video-playlists', this.playlist.uuid ]
f0a39880
C
18 if (this.playlist.videosLength === 0) return null
19
20 return [ '/videos/watch/playlist', this.playlist.uuid ]
21 }
830b4faf 22}