import { Component, OnInit, Input, ViewChild, ElementRef } from '@angular/core';
import { dataUrl } from 'angular-file/file-upload/fileTools';

@Component({
  selector: 'app-document-upload',
  templateUrl: './document-upload.component.html',
  styleUrls: ['./document-upload.component.scss']
})
export class DocumentUploadComponent implements OnInit {
  @ViewChild('tref') tref: ElementRef;
  validDrag: any = false;
  invalidDrag: any = false;
  files: File[] = [];

  @Input() public data;

  constructor() {}

  ngOnInit() {
  }

  openfileDialog() {
    this.tref.nativeElement.click();
  }

}
