ui

package
v0.4.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 13, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Box

func Box(title string, content string)

Box renders text in a bordered box

func ClearScreen

func ClearScreen()

ClearScreen clears the terminal screen without flickering Uses ANSI escape codes to move cursor to top instead of full clear

func Confirm

func Confirm(prompt string, defaultYes bool) bool

Confirm shows a simple confirmation prompt (keeping backwards compatibility) Now uses Bubble Tea instead of Gum

func ConfirmWithBubbles

func ConfirmWithBubbles(opts ConfirmOptions) bool

ConfirmWithBubbles shows a Bubble Tea confirmation prompt Uses Huh for a native Bubble Tea experience without external dependencies

func Error

func Error(text string)

Error renders an error message

func Header(text string)

Header renders a styled header with border

func HeaderBold

func HeaderBold(text string)

HeaderBold renders a bold header with underline

func HeaderGradient

func HeaderGradient(text string)

HeaderGradient renders a header with multi-color gradient effect

func HeaderMinimal

func HeaderMinimal(text string)

HeaderMinimal renders a clean header with top/bottom borders only

func Info

func Info(text string)

Info renders an info message

func List

func List(items []string, header string)

List renders a list of items

func ServiceStatus

func ServiceStatus(name string, status string, port int, latency string)

ServiceStatus renders a service status line

func Spin

func Spin(title string, command string, args ...string) error

Spin runs a command with a spinner

func SpinWithBubbles

func SpinWithBubbles(message string, command string, args ...string) error

SpinWithBubbles runs a command with a beautiful Bubbles spinner Falls back to Gum if no TTY is available

func Style

func Style(text string, opts ...string)

Style renders styled text using Gum

func Success

func Success(text string)

Success renders a success message

func Table

func Table(headers []string, rows [][]string)

Table renders data in a simple table format using Gum

func Warning

func Warning(text string)

Warning renders a warning message

Types

type ConfirmOptions

type ConfirmOptions struct {
	Title       string
	Description string
	Affirmative string
	Negative    string
	Inline      bool
}

ConfirmOptions configures the confirmation prompt

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL