improve menus

This commit is contained in:
David 2021-07-28 21:50:09 -04:00
parent 2ea148bec3
commit 4ec1a85139

View File

@ -111,7 +111,7 @@ func main() {
l := ui.NewList(Titles(state.Get("library").([]book.Book)), 0)
menu := ui.NewBox(
"library",
[]string{"(n)ew", "(i)mport", "(q)uit"},
[]string{"˄˅ select", "⏎ edit", "(n)ew", "(i)mport", "(q)uit"},
ui.Contents{{
Offsets: ui.Offsets{Top: 1, Left: 2, Bottom: -2, Right: -2},
Container: l,
@ -126,7 +126,7 @@ func main() {
// book display (right column)
activeBook := ui.NewBox(
"book",
nil,
[]string{"˄˅ select", "⏎ edit", "(esc) close"},
ui.Contents{{
Offsets: ui.Offsets{Top: 1, Left: 2, Bottom: 0, Right: 0},
Container: book,
@ -145,7 +145,7 @@ func main() {
)
// import pop-up
popup := ui.NewBox("import", nil, nil, ui.StyleActive, false)
popup := ui.NewBox("import", []string{"⏎ submit", "(esc)close"}, nil, ui.StyleActive, false)
popup.SetVisible(false)
// init