Skip to content

Commit

Permalink
fix(admin-ui): Prevent list filter hotkey F firing from input elements
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelbromley committed Jul 12, 2023
1 parent 46a4b74 commit c426f8d
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@ export class DataTableFiltersComponent implements AfterViewInit {

@HostListener('window:keydown.f', ['$event'])
onFKeyPress(event: KeyboardEvent) {
if (event.target instanceof HTMLElement) {
if (event.target.tagName === 'INPUT' || event.target.tagName === 'TEXTAREA') {
return;
}
}
if (!this.dropdown.isOpen && this.state === 'new') {
this.dropdown.toggleOpen();
}
Expand Down

0 comments on commit c426f8d

Please sign in to comment.