Documentation
¶
Overview ¶
Package components provides reusable UI components for the CLI
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Confirm ¶
type Confirm struct {
// contains filtered or unexported fields
}
Confirm represents a yes/no confirmation prompt
func NewConfirm ¶
NewConfirm creates a new confirmation prompt with the given message
func (*Confirm) WithDefault ¶
WithDefault sets the default value for the confirmation
type Progress ¶
type Progress struct {
// contains filtered or unexported fields
}
Progress represents a progress bar with message
func NewProgress ¶
NewProgress creates a new progress bar with the given total and width
type Prompt ¶
type Prompt struct {
// contains filtered or unexported fields
}
Prompt represents a user input prompt
type Select ¶
type Select struct {
// contains filtered or unexported fields
}
Select represents a selection prompt
func (*Select) WithSelected ¶
WithSelected sets the default selected item
type Spinner ¶
type Spinner struct {
// contains filtered or unexported fields
}
Spinner represents a loading spinner with message
func NewSpinner ¶
NewSpinner creates a new spinner with the given message
func (*Spinner) UpdateMessage ¶
UpdateMessage updates the spinner message
type Table ¶
type Table struct {
// contains filtered or unexported fields
}
Table represents a formatted table for CLI output
func (*Table) RenderToString ¶
RenderToString returns the table as a string
func (*Table) WithStyle ¶
func (t *Table) WithStyle(style TableStyle) *Table
WithStyle sets custom styling for the table
type TableStyle ¶
type TableStyle struct {
HeaderStyle func(string) string
CellStyle func(string) string
BorderStyle func(string) string
ShowBorders bool
ColumnPadding int
}
TableStyle represents the styling options for a table
func DefaultTableStyle ¶
func DefaultTableStyle() TableStyle
DefaultTableStyle returns the default table styling