import {
  Component,
  Input,
  ViewEncapsulation,
  EventEmitter,
  Output
} from '@angular/core';
import { CallbackModel } from '../../models/callback-model';
import { DropdownValues } from '../../interfaces/dropdown-interface';

@Component({
  selector: 'app-dropdown',
  templateUrl: './dropdown.component.html',
  styleUrls: ['./dropdown.component.scss']
})
export class DropdownComponent {
  @Input() dropdownValues: DropdownValues[];
  @Output() methodToExecute: EventEmitter<CallbackModel> = new EventEmitter<
    CallbackModel
  >();
  dropdownClick(obj: CallbackModel) {
    this.methodToExecute.emit(obj);
  }
  constructor() {
    console.log('dropdown!');
  }
}
