Info displays an info message If no message is given, the text of the SpinnerPrinter will be reused as the default message.
(message ...any)
| 218 | // Info displays an info message |
| 219 | // If no message is given, the text of the SpinnerPrinter will be reused as the default message. |
| 220 | func (s *SpinnerPrinter) Info(message ...any) { |
| 221 | if s.InfoPrinter == nil { |
| 222 | s.InfoPrinter = &Info |
| 223 | } |
| 224 | |
| 225 | if len(message) == 0 { |
| 226 | message = []any{s.Text} |
| 227 | } |
| 228 | |
| 229 | fClearLine(s.Writer) |
| 230 | |
| 231 | Fprinto(s.Writer, s.InfoPrinter.Sprint(message...)) |
| 232 | _ = s.Stop() |
| 233 | } |
| 234 | |
| 235 | // Success displays the success printer. |
| 236 | // If no message is given, the text of the SpinnerPrinter will be reused as the default message. |