Posted 24 June 2024, 1:27 pm EST
hi,
we added a combobox inside the flexgrid’s ‘topLeft’, something like
<wj-flex-grid #grid [itemsSource]=“data” [allowSorting]=“false” [autoSizeMode]=“‘Both’” [allowResizing]=“‘Both’”
[deferResizing]=“true”>
<ng-template wjFlexGridCellTemplate [cellType]=“‘TopLeft’” *ngIf=“customTopLeft”>
<wj-combo-box [itemsSource]=“[‘item1’, ‘item2’, ‘item3’, ‘item4’]” [minLength]=1 [showDropDownButton]=true >
But when we click the dropdown array of the combobox, it selects the while grid sometimes instead of showing up the list of items in the combobox.
to reproduce this issue, u can use the wijmo demo sample at https://developer.mescius.com/wijmo/demos/Grid/CustomCells/CellTemplates/Overview/angular
- insert the following code into the ng template ‘[cellType]=“‘TopLeft’”’
<wj-combo-box [itemsSource]=“[‘item1’, ‘item2’, ‘item3’, ‘item4’]” [showDropDownButton]=true >
-
increase the width of the column header
-
make sure the grid is not in ‘select all’ state
-
click the dropdown several times
we tried the work-around like this
grid.hostElement.addEventListener('mousedown', (e: any) => { const ht = grid.hitTest(e); if (ht.cellType == wjcGrid.CellType.TopLeft) { console.log('prevent'); e.preventDefault(); e.stopImmediatePropagation(); } });
but it does not seem to help.