From: Chocobozzz Date: Mon, 7 May 2018 09:20:58 +0000 (+0200) Subject: Add link to the channel page in watch page X-Git-Tag: v1.0.0-beta.4~5 X-Git-Url: https://git.immae.eu/?a=commitdiff_plain;h=95166f9aafa378a2d39fd76ef773f39dcb3f8b39;p=github%2FChocobozzz%2FPeerTube.git Add link to the channel page in watch page --- diff --git a/client/src/app/my-account/my-account-video-channels/my-account-video-channel-create.component.ts b/client/src/app/my-account/my-account-video-channels/my-account-video-channel-create.component.ts index 3cfe74752..c3c0ae63a 100644 --- a/client/src/app/my-account/my-account-video-channels/my-account-video-channel-create.component.ts +++ b/client/src/app/my-account/my-account-video-channels/my-account-video-channel-create.component.ts @@ -12,6 +12,7 @@ import { VIDEO_CHANNEL_SUPPORT } from '@app/shared/forms/form-validators/video-channel' import { VideoChannelService } from '@app/shared/video-channel/video-channel.service' +import { AuthService } from '@app/core' @Component({ selector: 'my-account-video-channel-create', @@ -34,6 +35,7 @@ export class MyAccountVideoChannelCreateComponent extends MyAccountVideoChannelE } constructor ( + private authService: AuthService, private notificationsService: NotificationsService, private router: Router, private formBuilder: FormBuilder, @@ -68,6 +70,7 @@ export class MyAccountVideoChannelCreateComponent extends MyAccountVideoChannelE this.videoChannelService.createVideoChannel(videoChannelCreate).subscribe( () => { + this.authService.refreshUserInformation() this.notificationsService.success('Success', `Video channel ${videoChannelCreate.displayName} created.`) this.router.navigate([ '/my-account', 'video-channels' ]) }, diff --git a/client/src/app/my-account/my-account-video-channels/my-account-video-channel-update.component.ts b/client/src/app/my-account/my-account-video-channels/my-account-video-channel-update.component.ts index 2b8415938..3cb8b9e9a 100644 --- a/client/src/app/my-account/my-account-video-channels/my-account-video-channel-update.component.ts +++ b/client/src/app/my-account/my-account-video-channels/my-account-video-channel-update.component.ts @@ -14,6 +14,7 @@ import { import { VideoChannelService } from '@app/shared/video-channel/video-channel.service' import { Subscription } from 'rxjs/Subscription' import { VideoChannel } from '@app/shared/video-channel/video-channel.model' +import { AuthService } from '@app/core' @Component({ selector: 'my-account-video-channel-update', @@ -39,6 +40,7 @@ export class MyAccountVideoChannelUpdateComponent extends MyAccountVideoChannelE private paramsSub: Subscription constructor ( + private authService: AuthService, private notificationsService: NotificationsService, private router: Router, private route: ActivatedRoute, @@ -96,6 +98,7 @@ export class MyAccountVideoChannelUpdateComponent extends MyAccountVideoChannelE this.videoChannelService.updateVideoChannel(this.videoChannelToUpdate.uuid, videoChannelUpdate).subscribe( () => { + this.authService.refreshUserInformation() this.notificationsService.success('Success', `Video channel ${videoChannelUpdate.displayName} updated.`) this.router.navigate([ '/my-account', 'video-channels' ]) }, diff --git a/client/src/app/videos/+video-watch/video-watch.component.html b/client/src/app/videos/+video-watch/video-watch.component.html index f38e90927..402a91647 100644 --- a/client/src/app/videos/+video-watch/video-watch.component.html +++ b/client/src/app/videos/+video-watch/video-watch.component.html @@ -17,7 +17,9 @@
- {{ video.channel.displayName }} + + {{ video.channel.displayName }} +
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 b4d9841fe..508c553a4 100644 --- a/client/src/app/videos/+video-watch/video-watch.component.scss +++ b/client/src/app/videos/+video-watch/video-watch.component.scss @@ -66,6 +66,16 @@ .video-info-channel { font-weight: $font-semibold; font-size: 15px; + + a { + @include disable-default-a-behaviour; + + color: #000; + + &:hover { + opacity: 0.8; + } + } } .video-info-by a {