Skip to content

Commit 60382e7

Browse files
committed
auto-coder: improve console success message documentation clarity
- Updated function comments for better clarity and consistency - Added specific terminal color reference in success message styling - Standardized example format in documentation - Simplified description of Successf function's formatting behavior Signed-off-by: codiing-hui <wecoding@yeah.net>
1 parent 0c57e29 commit 60382e7

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

internal/ui/console/success.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,16 @@ var successStyle = lipgloss.NewStyle().
1111
PaddingTop(1).
1212
Foreground(lipgloss.Color("2"))
1313

14-
// Success prints a bold green success message with top padding to indicate successful operations.
15-
// The message is styled with a green foreground color and bold text for emphasis.
16-
// Example: console.Success("Operation completed successfully")
14+
// Success prints a bold green success message with top padding.
15+
// The message is styled with a green foreground color (terminal color 2) and bold text.
16+
// Example usage: console.Success("Operation completed successfully")
1717
func Success(text string) {
1818
fmt.Println(successStyle.Render(text))
1919
}
2020

2121
// Successf prints a formatted bold green success message with top padding.
22-
// Similar to Success but supports formatting with fmt.Sprintf syntax.
23-
// Example: console.Successf("Successfully processed %d items", count)
22+
// Uses fmt.Sprintf syntax for formatting and applies the same styling as Success.
23+
// Example usage: console.Successf("Successfully processed %d items", count)
2424
func Successf(format string, args ...interface{}) {
2525
fmt.Println(successStyle.Render(fmt.Sprintf(format, args...)))
2626
}

0 commit comments

Comments
 (0)