From a96aed15188174c50885dda0df3164a67295e11f Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 19 Oct 2017 14:58:28 +0200 Subject: Add ability to download a video from direct link or torrent file --- .../+video-watch/video-download.component.ts | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 client/src/app/videos/+video-watch/video-download.component.ts (limited to 'client/src/app/videos/+video-watch/video-download.component.ts') diff --git a/client/src/app/videos/+video-watch/video-download.component.ts b/client/src/app/videos/+video-watch/video-download.component.ts new file mode 100644 index 000000000..22149aa6b --- /dev/null +++ b/client/src/app/videos/+video-watch/video-download.component.ts @@ -0,0 +1,28 @@ +import { Component, Input, ViewChild } from '@angular/core' + +import { ModalDirective } from 'ngx-bootstrap/modal' + +import { Video } from '../shared' + +@Component({ + selector: 'my-video-download', + templateUrl: './video-download.component.html', + styles: [ '.resolution-block { margin-top: 20px; }' ] +}) +export class VideoDownloadComponent { + @Input() video: Video = null + + @ViewChild('modal') modal: ModalDirective + + constructor () { + // empty + } + + show () { + this.modal.show() + } + + hide () { + this.modal.hide() + } +} -- cgit v1.2.3