]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/app/videos/video-list/video-miniature.component.ts
Alphabetical
[github/Chocobozzz/PeerTube.git] / client / app / videos / video-list / video-miniature.component.ts
index 817636768cfb8ff2d4367a1bfc1af47d8d96ae89..3baa1ddd648a6210063907819232c25857533af7 100644 (file)
@@ -16,28 +16,28 @@ import { User } from '../../users/index';
 export class VideoMiniatureComponent {
   @Output() removed = new EventEmitter<any>();
 
-  @Input() video: Video;
   @Input() user: User;
+  @Input() video: Video;
 
-  hovering: boolean = false;
+  hovering = false;
 
-  constructor(private _videoService: VideoService) {}
+  constructor(private videoService: VideoService) {}
 
-  onHover() {
-    this.hovering = true;
+  displayRemoveIcon() {
+    return this.hovering && this.video.isRemovableBy(this.user);
   }
 
   onBlur() {
     this.hovering = false;
   }
 
-  displayRemoveIcon(): boolean {
-    return this.hovering && this.video.isRemovableBy(this.user);
+  onHover() {
+    this.hovering = true;
   }
 
   removeVideo(id: string) {
     if (confirm('Do you really want to remove this video?')) {
-      this._videoService.removeVideo(id).subscribe(
+      this.videoService.removeVideo(id).subscribe(
         status => this.removed.emit(true),
         error => alert(error)
       );