Open tegola opened 2 years ago
This was also reported couple of years ago #5199 A solution/workaround was given on SO
Solved the issue by disabling pointer events while resizing using a CSS class or style
<th
[ngStyle]="{'pointer-events': resizing ? 'none' : 'inherit'}"
(nzResizeStart)="resizing = true"
(nzResizeEnd)="resizing = false"
>
` @Directive({ selector: 'nz-resize-handle', }) export class ElementDefaultDirective { @HostListener('click', ['$event']) onmousedown(event: { stopPropagation: () => void; preventDefault: () => void }) { event.stopPropagation(); event.preventDefault(); } }
`
Reproduction link
https://stackblitz.com/edit/ng-zorro-antd-ivy-bjgjxj
Steps to reproduce
What is expected?
The column should resize and the column sorting should stay the same.
What is actually happening?
The column sorting is changing due to the mouse click on the resize handle, which cannot be prevented/stopped.