Hotkeys: Navigate to search page if input is not available
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
4541e497ac
commit
b03256b53b
1 changed files with 2 additions and 0 deletions
|
@ -70,6 +70,8 @@ const GlobalHotkeys: React.FC<IGlobalHotkeys> = ({ children, node }) => {
|
|||
|
||||
if (element) {
|
||||
element.focus();
|
||||
} else {
|
||||
history.push('/search');
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue