Skip to content

Commit

Permalink
feat: allow "Enter" key to complete create new list (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
hoangph271 authored May 23, 2024
1 parent 2b09252 commit 9dceda8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,7 @@ impl Application for App {
widget::text_input("", name.as_str())
.id(self.dialog_text_input.clone())
.on_input(move |name| Message::DialogUpdate(DialogPage::New(name)))
.on_submit(Message::DialogComplete)
.into(),
])
.spacing(spacing.space_xxs),
Expand All @@ -324,6 +325,7 @@ impl Application for App {
.on_input(move |name| {
Message::DialogUpdate(DialogPage::Rename { to: name })
})
.on_submit(Message::DialogComplete)
.into(),
])
.spacing(spacing.space_xxs),
Expand Down

0 comments on commit 9dceda8

Please sign in to comment.