import {Component, Input, OnInit} from '@angular/core';
import {PopoverController} from '@ionic/angular';
import {NodeTypeIcons} from '../../../structures/node-types';

@Component({
  selector: 'editor-node-picker',
  templateUrl: './node-picker.component.html',
  styleUrls: ['./node-picker.component.scss'],
})
export class NodePickerComponent implements OnInit {
  @Input() formMode = true;

  public typeIcons = NodeTypeIcons;

  constructor(
      private popover: PopoverController,
  ) { }

  ngOnInit() {}

  onSelect(value: string) {
    this.popover.dismiss(value).then(() => {});
  }

}
