interactive

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: May 22, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunInteractiveMode

func RunInteractiveMode(options *calendar.Options) bool

RunInteractiveMode runs the interactive mode using bubbletea Returns true if the user completed the interactive mode, false if they exited early

func RunMultiStepMode

func RunMultiStepMode(options *calendar.Options) bool

RunMultiStepMode runs the multi-step interactive mode Returns true if the user completed the interactive mode, false if they exited early

Types

type Model

type Model struct {
	// contains filtered or unexported fields
}

Model represents the state of the interactive form

func Initialize

func Initialize(options *calendar.Options) Model

Initialize creates a new model with default values

func (Model) Init

func (m Model) Init() tea.Cmd

Init initializes the model

func (Model) Update

func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles user input and updates the model

func (Model) View

func (m Model) View() string

View renders the UI

type MultiStepModel

type MultiStepModel struct {
	// contains filtered or unexported fields
}

MultiStepModel represents the state of the multi-step UI flow

func InitializeMultiStep

func InitializeMultiStep(options *calendar.Options) MultiStepModel

InitializeMultiStep creates a new multi-step model

func (MultiStepModel) Init

func (m MultiStepModel) Init() tea.Cmd

Init initializes the model

func (MultiStepModel) Update

func (m MultiStepModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles user input and updates the model

func (MultiStepModel) View

func (m MultiStepModel) View() string

View renders the UI

type Step

type Step int

Step represents the current step in the multi-step UI flow

const (
	SelectionStep Step = iota
	DateInputStep
	LayoutOptionsStep
)

Jump to

Keyboard shortcuts

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