mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 04:29:28 +01:00
Et2SelectEmail: Fix keyboard navigation in search results
This commit is contained in:
parent
ca20d73eac
commit
e0e074a4b1
@ -115,6 +115,24 @@ export class Et2SelectEmail extends Et2Select
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Handle keypresses inside the search input
|
||||||
|
* Overridden from parent to also skip the hidden selected options, which other selects do not do
|
||||||
|
*
|
||||||
|
* @param {KeyboardEvent} event
|
||||||
|
* @protected
|
||||||
|
*/
|
||||||
|
protected _handleSearchKeyDown(event : KeyboardEvent)
|
||||||
|
{
|
||||||
|
// Pass off some keys to select
|
||||||
|
if(['ArrowDown', 'ArrowUp', 'Home', 'End'].includes(event.key))
|
||||||
|
{
|
||||||
|
// Strip out hidden non-matching selected so key navigation works
|
||||||
|
this.menuItems = this.menuItems.filter(i => !i.checked);
|
||||||
|
}
|
||||||
|
return super._handleSearchKeyDown(event);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Actually query the server.
|
* Actually query the server.
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user