mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-08-05 02:24:52 +00:00
Don't toggle dropdown on space
Closing the dropdown menu is now possible with ESC. Space will only open the dropdown, but not close it. So now it's possible to type a space into the search field. Fixes: #863
This commit is contained in:
@ -359,7 +359,7 @@ update msg model =
|
|||||||
|
|
||||||
Just Util.Html.ESC ->
|
Just Util.Html.ESC ->
|
||||||
if model.menuOpen then
|
if model.menuOpen then
|
||||||
( model, Cmd.none )
|
update ToggleMenu model
|
||||||
|
|
||||||
else
|
else
|
||||||
case model.selected of
|
case model.selected of
|
||||||
@ -374,7 +374,11 @@ update msg model =
|
|||||||
( model, Cmd.none )
|
( model, Cmd.none )
|
||||||
|
|
||||||
Just Util.Html.Space ->
|
Just Util.Html.Space ->
|
||||||
update ToggleMenu model
|
if model.menuOpen then
|
||||||
|
( model, Cmd.none )
|
||||||
|
|
||||||
|
else
|
||||||
|
update ToggleMenu model
|
||||||
|
|
||||||
Just Util.Html.Enter ->
|
Just Util.Html.Enter ->
|
||||||
let
|
let
|
||||||
|
Reference in New Issue
Block a user