import {ICellEditorAngularComp} from 'ag-grid-angular'; import {AfterViewInit, Component, ElementRef, ViewChild} from '@angular/core'; import {ICellEditorParams} from 'ag-grid-community'; import {IonSelect} from '@ionic/angular'; @Component({ selector: 'cell-editor-multiselect', template: ` {{ option.value }} `, }) export class MultiSelectEditorComponent implements ICellEditorAngularComp, AfterViewInit { public params: ICellEditorParams; public value: string; public options: Array<{value: string}> = []; @ViewChild('select') select: IonSelect; agInit(params: ICellEditorParams): void { this.params = params; this.value = this.params.value; // @ts-ignore this.options = this.params.colDef.additionalData.options; } getValue(): any { return this.value; } ngAfterViewInit(): void { this.select.open(); } }