2017-06-16 08:32:15 -04:00
|
|
|
import { Component, Input, ViewChild } from '@angular/core'
|
2016-11-20 10:09:38 -05:00
|
|
|
|
2017-06-16 08:32:15 -04:00
|
|
|
import { ModalDirective } from 'ngx-bootstrap/modal'
|
2016-11-20 10:09:38 -05:00
|
|
|
|
2017-06-16 08:32:15 -04:00
|
|
|
import { Video } from '../shared'
|
2016-11-20 10:09:38 -05:00
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'my-video-magnet',
|
|
|
|
templateUrl: './video-magnet.component.html'
|
|
|
|
})
|
|
|
|
export class VideoMagnetComponent {
|
2017-06-16 08:32:15 -04:00
|
|
|
@Input() video: Video = null
|
2016-11-20 10:09:38 -05:00
|
|
|
|
2017-06-16 08:32:15 -04:00
|
|
|
@ViewChild('modal') modal: ModalDirective
|
2016-11-20 10:09:38 -05:00
|
|
|
|
2017-06-16 08:32:15 -04:00
|
|
|
constructor () {
|
2016-11-20 10:09:38 -05:00
|
|
|
// empty
|
|
|
|
}
|
|
|
|
|
2017-06-16 08:32:15 -04:00
|
|
|
show () {
|
|
|
|
this.modal.show()
|
2016-11-20 10:09:38 -05:00
|
|
|
}
|
|
|
|
|
2017-06-16 08:32:15 -04:00
|
|
|
hide () {
|
|
|
|
this.modal.hide()
|
2016-11-20 10:09:38 -05:00
|
|
|
}
|
|
|
|
}
|