strivor
(Info)
October 23, 2018, 1:50pm
1
Hi,
Have some problems with custom filtering. The Filter inputbox looses focus instantly when entering it.
Seems to be a bug/change in 6.1.x, works in 6.0.0.
How to reproduce:
Go to the doc page (https://handsontable.com/docs/6.1.1/demo-filtering.html ), scroll down to “Custom implementations” and then the section “Filter as you type”.
Now try to enter a filter-value in any of the column-filters.
Try doing the same in 6.0.0 (https://handsontable.com/docs/6.0.0/demo-filtering.html ) and it works!
strivor
(Info)
October 23, 2018, 2:37pm
2
I’ve narrowed down to an event that is triggered on div.wtHolder .
Removing this event solves the issue, but I guess will cause other ones.
Adding a “event.stopPropagation();” on the input’s solved the issue.
var addEventListeners = function (input, colIndex) {
input.addEventListener('keydown', function (event) {
debounceFn(colIndex, event);
});
input.addEventListener('mouseup', function(event) {
event.stopPropagation();
});
};