mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-07-05 00:59:19 +02:00
Double the duration of error toasts
This gives users more time to read them.
This commit is contained in:
@ -60,7 +60,8 @@ func (self *StatusManager) AddToastStatus(message string, kind types.ToastKind)
|
|||||||
id := self.addStatus(message, "toast", kind)
|
id := self.addStatus(message, "toast", kind)
|
||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
time.Sleep(time.Second * 2)
|
delay := lo.Ternary(kind == types.ToastKindError, time.Second*4, time.Second*2)
|
||||||
|
time.Sleep(delay)
|
||||||
|
|
||||||
self.removeStatus(id)
|
self.removeStatus(id)
|
||||||
}()
|
}()
|
||||||
|
Reference in New Issue
Block a user