forked from Mirrors/bubbletea
Fix ineffectual assignment in spinner example
This commit is contained in:
parent
b6c7f93d9a
commit
f981b991c0
|
@ -86,13 +86,14 @@ func (m *model) resetSpinner() {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (m model) View() (s string) {
|
func (m model) View() (s string) {
|
||||||
gap := " "
|
var gap string
|
||||||
switch m.index {
|
switch m.index {
|
||||||
case 1:
|
case 1:
|
||||||
gap = ""
|
gap = ""
|
||||||
default:
|
default:
|
||||||
gap = " "
|
gap = " "
|
||||||
}
|
}
|
||||||
|
|
||||||
s += fmt.Sprintf("\n %s%s%s\n\n", m.spinner.View(), gap, textStyle("Spinning..."))
|
s += fmt.Sprintf("\n %s%s%s\n\n", m.spinner.View(), gap, textStyle("Spinning..."))
|
||||||
s += helpStyle("h/l, ←/→: change spinner • q: exit\n")
|
s += helpStyle("h/l, ←/→: change spinner • q: exit\n")
|
||||||
return
|
return
|
||||||
|
|
Loading…
Reference in New Issue