import { Component, OnInit } from '@angular/core'; import {Router} from '@angular/router'; import {ApiService} from '../../service/api.service'; @Component({ selector: 'app-option-picker', templateUrl: './option-picker.component.html', styleUrls: ['./option-picker.component.scss'], }) export class OptionPickerComponent implements OnInit { constructor( protected api: ApiService ) { } ngOnInit() {} onSelect(key) { if ( key === 'html_export' ) { window.open(this.api._build_url('/data/export/html'), '_blank'); } } }