1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-11-25 22:32:13 +02:00

rename displayString to label for menu items

This commit is contained in:
Jesse Duffield
2022-05-08 14:23:32 +10:00
parent 125e948d82
commit 6f8063217d
23 changed files with 126 additions and 122 deletions

View File

@@ -23,7 +23,7 @@ func (gui *Gui) createMenu(opts types.CreateMenuOptions) error {
if !opts.HideCancel {
// this is mutative but I'm okay with that for now
opts.Items = append(opts.Items, &types.MenuItem{
DisplayStrings: []string{gui.c.Tr.LcCancel},
LabelColumns: []string{gui.c.Tr.LcCancel},
OnPress: func() error {
return nil
},
@@ -31,7 +31,7 @@ func (gui *Gui) createMenu(opts types.CreateMenuOptions) error {
}
for _, item := range opts.Items {
if item.OpensMenu && item.DisplayStrings != nil {
if item.OpensMenu && item.LabelColumns != nil {
return errors.New("Message for the developer of this app: you've set opensMenu with displaystrings on the menu panel. Bad developer!. Apologies, user")
}
}