Documentation ¶
Overview ¶
Package models holds the ui model
Package models holds the ui model
Index ¶
Constants ¶
View Source
const ( View mode = iota Filter Input )
Application Modes
Variables ¶
This section is empty.
Functions ¶
func ReceiveAppEvent ¶
func ReceiveAppEvent(event v1alpha1.ApplicationWatchEvent) tea.Cmd
ReceiveAppEvent wraps app events received from argocd
Types ¶
type AppEvent ¶
type AppEvent struct {
Event v1alpha1.ApplicationWatchEvent
}
AppEvent corresponds to an argocd application event
type AppListItem ¶
AppListItem is used as bubbletea list.Items
func (AppListItem) Description ¶
func (a AppListItem) Description() string
Description returns the ItemDescription
func (AppListItem) FilterValue ¶
func (a AppListItem) FilterValue() string
FilterValue returns the string to filter on
type ArTUIModel ¶
type ArTUIModel struct { Cluster string Ready bool Activity mode Applications v1alpha1.ApplicationList List list.Model Viewport viewport.Model Textinput textinput.Model Glamour *glamour.TermRenderer Templates *template.Template WindowHeight int WindowWidth int LastAppRefresh time.Time RefreshDuration time.Duration AppEventChan <-chan AppEvent AppWorkerChan chan<- WorkerCmd DarkMode bool }
ArTUIModel is the bubbletea app model
func (*ArTUIModel) UpdateApplications ¶
func (m *ArTUIModel) UpdateApplications(updateApp v1alpha1.Application)
UpdateApplications updates the model application list
type WorkerCmd ¶
type WorkerCmd struct { Cmd WorkerCommand App v1alpha1.Application }
WorkerCmd corresponds to an argocd application event
type WorkerCommand ¶
type WorkerCommand int
WorkerCommand differenciates possible commands
const ( Refresh WorkerCommand = iota HardRefresh Sync )
Possible Commands
Click to show internal directories.
Click to hide internal directories.