]>
Commit | Line | Data |
---|---|---|
830b4faf | 1 | import { Component, Input } from '@angular/core' |
67ed6552 | 2 | import { 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 | }) | |
9 | export 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 | |
0f7407d9 | 15 | @Input() displayAsRow = false |
f0a39880 C |
16 | |
17 | getPlaylistUrl () { | |
17119e4a | 18 | if (this.toManage) return [ '/my-library/video-playlists', this.playlist.uuid ] |
f0a39880 C |
19 | if (this.playlist.videosLength === 0) return null |
20 | ||
a1eda903 | 21 | return [ '/w/p', this.playlist.uuid ] |
f0a39880 | 22 | } |
830b4faf | 23 | } |