import { Component, Input, ViewChild } from '@angular/core'
-
import { ModalDirective } from 'ngx-bootstrap/modal'
-
-import { Video } from '../shared'
+import { VideoDetails } from '../../shared/video/video-details.model'
@Component({
selector: 'my-video-share',
templateUrl: './video-share.component.html'
})
export class VideoShareComponent {
- @Input() video: Video = null
+ @Input() video: VideoDetails = null
@ViewChild('modal') modal: ModalDirective
getVideoIframeCode () {
return '<iframe width="560" height="315" ' +
- 'src="' + window.location.origin + '/videos/embed/' + this.video.uuid + '" ' +
+ 'src="' + this.video.embedUrl + '" ' +
'frameborder="0" allowfullscreen>' +
'</iframe>'
}