aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+videos/+video-watch
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-05-27 16:12:41 +0200
committerChocobozzz <me@florianbigard.com>2021-05-27 16:12:41 +0200
commit8f608a4cb22ab232cfab20665050764b38bac9c7 (patch)
tree6a6785aae79bf5939ad7b7a50a1bd8031268d2b4 /client/src/app/+videos/+video-watch
parent030ccfce59a8cb8f2fee6ea8dd363ba635c5c5c2 (diff)
parentc215e627b575d2c4085ccb222f4ca8d0237b7552 (diff)
downloadPeerTube-8f608a4cb22ab232cfab20665050764b38bac9c7.tar.gz
PeerTube-8f608a4cb22ab232cfab20665050764b38bac9c7.tar.zst
PeerTube-8f608a4cb22ab232cfab20665050764b38bac9c7.zip
Merge branch 'develop' into shorter-URLs-channels-accounts
Diffstat (limited to 'client/src/app/+videos/+video-watch')
-rw-r--r--client/src/app/+videos/+video-watch/comment/video-comment.component.ts2
-rw-r--r--client/src/app/+videos/+video-watch/video-watch-routing.module.ts7
-rw-r--r--client/src/app/+videos/+video-watch/video-watch.component.scss3
-rw-r--r--client/src/app/+videos/+video-watch/video-watch.component.ts6
4 files changed, 9 insertions, 9 deletions
diff --git a/client/src/app/+videos/+video-watch/comment/video-comment.component.ts b/client/src/app/+videos/+video-watch/comment/video-comment.component.ts
index fd379e80e..04f8f0d58 100644
--- a/client/src/app/+videos/+video-watch/comment/video-comment.component.ts
+++ b/client/src/app/+videos/+video-watch/comment/video-comment.component.ts
@@ -161,7 +161,7 @@ export class VideoCommentComponent implements OnInit, OnChanges {
161 // Before HTML rendering restore line feed for markdown list compatibility 161 // Before HTML rendering restore line feed for markdown list compatibility
162 const commentText = this.comment.text.replace(/<br.?\/?>/g, '\r\n') 162 const commentText = this.comment.text.replace(/<br.?\/?>/g, '\r\n')
163 const html = await this.markdownService.textMarkdownToHTML(commentText, true, true) 163 const html = await this.markdownService.textMarkdownToHTML(commentText, true, true)
164 this.sanitizedCommentHTML = await this.markdownService.processVideoTimestamps(html) 164 this.sanitizedCommentHTML = this.markdownService.processVideoTimestamps(html)
165 this.newParentComments = this.parentComments.concat([ this.comment ]) 165 this.newParentComments = this.parentComments.concat([ this.comment ])
166 166
167 if (this.comment.account) { 167 if (this.comment.account) {
diff --git a/client/src/app/+videos/+video-watch/video-watch-routing.module.ts b/client/src/app/+videos/+video-watch/video-watch-routing.module.ts
index d8fecb87d..cb77685c0 100644
--- a/client/src/app/+videos/+video-watch/video-watch-routing.module.ts
+++ b/client/src/app/+videos/+video-watch/video-watch-routing.module.ts
@@ -1,13 +1,11 @@
1import { NgModule } from '@angular/core' 1import { NgModule } from '@angular/core'
2import { RouterModule, Routes } from '@angular/router' 2import { RouterModule, Routes } from '@angular/router'
3import { MetaGuard } from '@ngx-meta/core'
4import { VideoWatchComponent } from './video-watch.component' 3import { VideoWatchComponent } from './video-watch.component'
5 4
6const videoWatchRoutes: Routes = [ 5const videoWatchRoutes: Routes = [
7 { 6 {
8 path: 'playlist/:playlistId', 7 path: 'playlist/:playlistId',
9 component: VideoWatchComponent, 8 component: VideoWatchComponent
10 canActivate: [ MetaGuard ]
11 }, 9 },
12 { 10 {
13 path: ':videoId/comments/:commentId', 11 path: ':videoId/comments/:commentId',
@@ -15,8 +13,7 @@ const videoWatchRoutes: Routes = [
15 }, 13 },
16 { 14 {
17 path: ':videoId', 15 path: ':videoId',
18 component: VideoWatchComponent, 16 component: VideoWatchComponent
19 canActivate: [ MetaGuard ]
20 } 17 }
21] 18]
22 19
diff --git a/client/src/app/+videos/+video-watch/video-watch.component.scss b/client/src/app/+videos/+video-watch/video-watch.component.scss
index 301762695..6124090c9 100644
--- a/client/src/app/+videos/+video-watch/video-watch.component.scss
+++ b/client/src/app/+videos/+video-watch/video-watch.component.scss
@@ -146,6 +146,8 @@ $video-info-margin-left: 44px;
146 } 146 }
147 147
148 .video-info-name { 148 .video-info-name {
149 @include peertube-word-wrap;
150
149 margin-right: 30px; 151 margin-right: 30px;
150 min-height: 40px; // Align with the action buttons 152 min-height: 40px; // Align with the action buttons
151 font-size: 27px; 153 font-size: 27px;
@@ -173,6 +175,7 @@ $video-info-margin-left: 44px;
173 175
174 a { 176 a {
175 @include disable-default-a-behaviour; 177 @include disable-default-a-behaviour;
178 @include peertube-word-wrap;
176 179
177 color: pvar(--mainForegroundColor); 180 color: pvar(--mainForegroundColor);
178 181
diff --git a/client/src/app/+videos/+video-watch/video-watch.component.ts b/client/src/app/+videos/+video-watch/video-watch.component.ts
index 1c510d6b0..88c5cef52 100644
--- a/client/src/app/+videos/+video-watch/video-watch.component.ts
+++ b/client/src/app/+videos/+video-watch/video-watch.component.ts
@@ -9,6 +9,7 @@ import {
9 AuthUser, 9 AuthUser,
10 ConfirmService, 10 ConfirmService,
11 MarkdownService, 11 MarkdownService,
12 MetaService,
12 Notifier, 13 Notifier,
13 PeerTubeSocket, 14 PeerTubeSocket,
14 RestExtractor, 15 RestExtractor,
@@ -25,7 +26,6 @@ import { SupportModalComponent } from '@app/shared/shared-support-modal'
25import { SubscribeButtonComponent } from '@app/shared/shared-user-subscription' 26import { SubscribeButtonComponent } from '@app/shared/shared-user-subscription'
26import { VideoActionsDisplayType, VideoDownloadComponent } from '@app/shared/shared-video-miniature' 27import { VideoActionsDisplayType, VideoDownloadComponent } from '@app/shared/shared-video-miniature'
27import { VideoPlaylist, VideoPlaylistService } from '@app/shared/shared-video-playlist' 28import { VideoPlaylist, VideoPlaylistService } from '@app/shared/shared-video-playlist'
28import { MetaService } from '@ngx-meta/core'
29import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage' 29import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
30import { HttpStatusCode } from '@shared/core-utils/miscs/http-error-codes' 30import { HttpStatusCode } from '@shared/core-utils/miscs/http-error-codes'
31import { ServerConfig, ServerErrorCode, UserVideoRateType, VideoCaption, VideoPrivacy, VideoState } from '@shared/models' 31import { ServerConfig, ServerErrorCode, UserVideoRateType, VideoCaption, VideoPrivacy, VideoState } from '@shared/models'
@@ -509,7 +509,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
509 509
510 private async setVideoDescriptionHTML () { 510 private async setVideoDescriptionHTML () {
511 const html = await this.markdownService.textMarkdownToHTML(this.video.description) 511 const html = await this.markdownService.textMarkdownToHTML(this.video.description)
512 this.videoHTMLDescription = await this.markdownService.processVideoTimestamps(html) 512 this.videoHTMLDescription = this.markdownService.processVideoTimestamps(html)
513 } 513 }
514 514
515 private setVideoLikesBarTooltipText () { 515 private setVideoLikesBarTooltipText () {
@@ -674,7 +674,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
674 674
675 this.player.one('ended', () => { 675 this.player.one('ended', () => {
676 if (this.video.isLive) { 676 if (this.video.isLive) {
677 this.video.state.id = VideoState.LIVE_ENDED 677 this.zone.run(() => this.video.state.id = VideoState.LIVE_ENDED)
678 } 678 }
679 }) 679 })
680 680