fix(deps): update module github.com/vbauerster/mpb/v8 to v8.5.2

Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
renovate[bot]
2023-07-16 19:44:13 +00:00
committed by GitHub
parent 49a924cf39
commit 7fb17ae786
4 changed files with 7 additions and 8 deletions

View File

@ -1,7 +1,6 @@
package mpb
import (
"fmt"
"io"
"strings"
@ -75,15 +74,15 @@ func (s spinnerStyle) Build() BarFiller {
switch s.position {
case positionLeft:
sf.position = func(frame string, padWidth int) string {
return fmt.Sprint(frame, strings.Repeat(" ", padWidth))
return frame + strings.Repeat(" ", padWidth)
}
case positionRight:
sf.position = func(frame string, padWidth int) string {
return fmt.Sprint(strings.Repeat(" ", padWidth), frame)
return strings.Repeat(" ", padWidth) + frame
}
default:
sf.position = func(frame string, padWidth int) string {
return fmt.Sprint(strings.Repeat(" ", padWidth/2), frame, strings.Repeat(" ", padWidth/2+padWidth%2))
return strings.Repeat(" ", padWidth/2) + frame + strings.Repeat(" ", padWidth/2+padWidth%2)
}
}
return sf