aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/shared/video
diff options
context:
space:
mode:
authorRigel Kent <sendmemail@rigelk.eu>2020-06-12 09:51:13 +0200
committerRigel Kent <sendmemail@rigelk.eu>2020-06-12 09:51:16 +0200
commit435258ea3c17c10c7c2735075e59122956d45fca (patch)
tree44136d8c9362a5b219f1458a2a53a3c671cadee3 /client/src/app/shared/video
parent8b381422b88a02a971f5e50422b5b4b79b1101e5 (diff)
downloadPeerTube-435258ea3c17c10c7c2735075e59122956d45fca.tar.gz
PeerTube-435258ea3c17c10c7c2735075e59122956d45fca.tar.zst
PeerTube-435258ea3c17c10c7c2735075e59122956d45fca.zip
fix miniature fixed height, add link/title to avatar, remove pr-2 on channels list
Diffstat (limited to 'client/src/app/shared/video')
-rw-r--r--client/src/app/shared/video/video-miniature.component.html8
-rw-r--r--client/src/app/shared/video/video-miniature.component.scss3
-rw-r--r--client/src/app/shared/video/video-miniature.component.ts10
3 files changed, 11 insertions, 10 deletions
diff --git a/client/src/app/shared/video/video-miniature.component.html b/client/src/app/shared/video/video-miniature.component.html
index 992c16585..d3b750da8 100644
--- a/client/src/app/shared/video/video-miniature.component.html
+++ b/client/src/app/shared/video/video-miniature.component.html
@@ -10,10 +10,10 @@
10 <div class="video-bottom"> 10 <div class="video-bottom">
11 <div class="video-miniature-information"> 11 <div class="video-miniature-information">
12 <div class="d-inline-flex video-miniature-meta"> 12 <div class="d-inline-flex video-miniature-meta">
13 <div *ngIf="displayOptions.avatar" class="avatar"> 13 <a *ngIf="displayOptions.avatar" class="avatar" [routerLink]="[ '/video-channels', video.byVideoChannel ]" [title]="channelLinkTitle">
14 <img [src]="getAvatarUrl()" alt="Avatar" /> 14 <img [src]="getAvatarUrl()" alt="" />
15 </div> 15 </a>
16 16
17 <div class="d-flex flex-column"> 17 <div class="d-flex flex-column">
18 <a 18 <a
19 tabindex="-1" 19 tabindex="-1"
diff --git a/client/src/app/shared/video/video-miniature.component.scss b/client/src/app/shared/video/video-miniature.component.scss
index d926c4dec..99bd9c15b 100644
--- a/client/src/app/shared/video/video-miniature.component.scss
+++ b/client/src/app/shared/video/video-miniature.component.scss
@@ -9,7 +9,6 @@ $more-margin-right: 15px;
9 display: inline-flex; 9 display: inline-flex;
10 flex-direction: column; 10 flex-direction: column;
11 padding-bottom: $video-miniature-margin-bottom; 11 padding-bottom: $video-miniature-margin-bottom;
12 height: 195px;
13 vertical-align: top; 12 vertical-align: top;
14 13
15 .video-bottom { 14 .video-bottom {
@@ -119,8 +118,6 @@ $more-margin-right: 15px;
119 118
120 &.fit-width { 119 &.fit-width {
121 width: 100%; 120 width: 100%;
122 height: unset;
123 padding-bottom: $video-miniature-margin-bottom / 2;
124 121
125 .video-bottom { 122 .video-bottom {
126 width: 100% !important; 123 width: 100% !important;
diff --git a/client/src/app/shared/video/video-miniature.component.ts b/client/src/app/shared/video/video-miniature.component.ts
index ccf90af54..36e18d018 100644
--- a/client/src/app/shared/video/video-miniature.component.ts
+++ b/client/src/app/shared/video/video-miniature.component.ts
@@ -78,6 +78,7 @@ export class VideoMiniatureComponent implements OnInit {
78 addToWatchLaterText: string 78 addToWatchLaterText: string
79 addedToWatchLaterText: string 79 addedToWatchLaterText: string
80 inWatchLaterPlaylist: boolean 80 inWatchLaterPlaylist: boolean
81 channelLinkTitle = ''
81 82
82 watchLaterPlaylist: { 83 watchLaterPlaylist: {
83 id: number 84 id: number
@@ -96,9 +97,7 @@ export class VideoMiniatureComponent implements OnInit {
96 private videoPlaylistService: VideoPlaylistService, 97 private videoPlaylistService: VideoPlaylistService,
97 private cd: ChangeDetectorRef, 98 private cd: ChangeDetectorRef,
98 @Inject(LOCALE_ID) private localeId: string 99 @Inject(LOCALE_ID) private localeId: string
99 ) { 100 ) {}
100
101 }
102 101
103 get isVideoBlur () { 102 get isVideoBlur () {
104 return this.video.isVideoNSFWForUser(this.user, this.serverConfig) 103 return this.video.isVideoNSFWForUser(this.user, this.serverConfig)
@@ -114,6 +113,11 @@ export class VideoMiniatureComponent implements OnInit {
114 113
115 this.setUpBy() 114 this.setUpBy()
116 115
116 this.channelLinkTitle = this.i18n(
117 'Go to the channel page of {{name}} ({{handle}})',
118 { name: this.video.channel.name, handle: this.video.byVideoChannel }
119 )
120
117 // We rely on mouseenter to lazy load actions 121 // We rely on mouseenter to lazy load actions
118 if (this.screenService.isInTouchScreen()) { 122 if (this.screenService.isInTouchScreen()) {
119 this.loadActions() 123 this.loadActions()