dashboard

package
v0.0.0-...-bbf37f2 Latest Latest
Warning

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

Go to latest
Published: May 23, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const TimeFormat = "2006/01/02 15:04:05"

Variables

View Source
var YAMLColorPrinter = yamlprinter.Printer{
	String: func() *yamlprinter.Property {
		return &yamlprinter.Property{
			Prefix: "[blue]",
			Suffix: "[white]",
		}
	},
	Number: func() *yamlprinter.Property {
		return &yamlprinter.Property{
			Prefix: "[fuchsia]",
			Suffix: "[white]",
		}
	},
	Bool: func() *yamlprinter.Property {
		return &yamlprinter.Property{
			Prefix: "[teal]",
			Suffix: "[white]",
		}
	},

	MapKey: func() *yamlprinter.Property {
		return &yamlprinter.Property{
			Prefix: "[green]",
			Suffix: "[white]",
		}
	},

	Anchor: func() *yamlprinter.Property {
		return &yamlprinter.Property{
			Prefix: "[red]",
			Suffix: "[white]",
		}
	},
	Alias: func() *yamlprinter.Property {
		return &yamlprinter.Property{
			Prefix: "[yellow]",
			Suffix: "[white]",
		}
	},
}

Functions

func CleanTableRows

func CleanTableRows(table *tview.Table, exists func(row int) bool)

func ContainsPlugin

func ContainsPlugin(pluginIds []client.PluginID, pluginId client.PluginID) bool

func Dashboard

func Dashboard(client *clientpkg.Client, frequency time.Duration, timezone *time.Location) error

func FindDeploymentRow

func FindDeploymentRow(table *tview.Table, deploymentId string) int

func FindPluginRow

func FindPluginRow(table *tview.Table, pluginId client.PluginID) int

func FindSiteRow

func FindSiteRow(table *tview.Table, siteId string) int

func FindTemplateRow

func FindTemplateRow(table *tview.Table, templateId string) int

func GetDeploymentRow

func GetDeploymentRow(table *tview.Table, row int) string

func GetListMinSize

func GetListMinSize(list *tview.List) (int, int)

func GetPluginRow

func GetPluginRow(table *tview.Table, row int) client.PluginID

func GetSiteRow

func GetSiteRow(table *tview.Table, row int) string

func GetTemplateRow

func GetTemplateRow(table *tview.Table, row int) string

func NewBoolTableCell

func NewBoolTableCell(bool_ bool) *tview.TableCell

func NewHeaderTableCell

func NewHeaderTableCell(text string) *tview.TableCell

func PackageToYAML

func PackageToYAML(package_ tkoutil.Package) (string, error)

func SetTableHeader

func SetTableHeader(table *tview.Table, headers ...string)

func ToSliceAny

func ToSliceAny(package_ tkoutil.Package) []any

To force the transcriber to transcribe package as multiple YAML documents

func ToYAML

func ToYAML(content any) (string, error)

Types

type Application

type Application struct {
	Timezone *time.Location
	// contains filtered or unexported fields
}

func NewApplication

func NewApplication(client *clientpkg.Client, frequency time.Duration, timezone *time.Location) *Application

func (*Application) AddTablePage

func (self *Application) AddTablePage(name string, title string, key rune, updateTable UpdateTableFunc)

func (*Application) AddTextPage

func (self *Application) AddTextPage(name string, title string, key rune, updateText UpdateTextFunc)

func (*Application) Error

func (self *Application) Error(err error)

func (*Application) RightClickToESC

func (self *Application) RightClickToESC(box *tview.Box)

func (*Application) SetDeploymentRow

func (self *Application) SetDeploymentRow(table *tview.Table, row int, deploymentInfo *client.DeploymentInfo)

func (*Application) SetPluginRow

func (self *Application) SetPluginRow(table *tview.Table, row int, plugin *client.Plugin)

func (*Application) SetSiteRow

func (self *Application) SetSiteRow(table *tview.Table, row int, siteInfo *client.SiteInfo)

func (*Application) SetTemplateRow

func (self *Application) SetTemplateRow(table *tview.Table, row int, templateInfo *client.TemplateInfo)

func (*Application) SwitchToPage

func (self *Application) SwitchToPage(page string, removePage string)

func (*Application) UpdateAbout

func (self *Application) UpdateAbout(textView *tview.TextView) error

(UpdateTableFunc signature)

func (*Application) UpdateDeployments

func (self *Application) UpdateDeployments(table *tview.Table) error

(UpdateTableFunc signature)

func (*Application) UpdatePlugins

func (self *Application) UpdatePlugins(table *tview.Table) error

(UpdateTableFunc signature)

func (*Application) UpdateSites

func (self *Application) UpdateSites(table *tview.Table) error

(UpdateTableFunc signature)

func (*Application) UpdateTemplates

func (self *Application) UpdateTemplates(table *tview.Table) error

(UpdateTableFunc signature)

type DeploymentDetails

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

func (*DeploymentDetails) GetText

func (self *DeploymentDetails) GetText() (string, error)

(Details interface)

func (*DeploymentDetails) GetTitle

func (self *DeploymentDetails) GetTitle() string

(Details interface)

type Details

type Details interface {
	GetTitle() string
	GetText() (string, error)
}

type PluginDetails

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

func (*PluginDetails) GetText

func (self *PluginDetails) GetText() (string, error)

(Details interface)

func (*PluginDetails) GetTitle

func (self *PluginDetails) GetTitle() string

(Details interface)

type SiteDetails

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

func (*SiteDetails) GetText

func (self *SiteDetails) GetText() (string, error)

(Details interface)

func (*SiteDetails) GetTitle

func (self *SiteDetails) GetTitle() string

(Details interface)

type TemplateDetails

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

func (*TemplateDetails) GetText

func (self *TemplateDetails) GetText() (string, error)

(Details interface)

func (*TemplateDetails) GetTitle

func (self *TemplateDetails) GetTitle() string

(Details interface)

type Ticker

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

func NewTicker

func NewTicker(application *tview.Application, frequency time.Duration, f func()) *Ticker

func (*Ticker) Start

func (self *Ticker) Start()

func (*Ticker) Stop

func (self *Ticker) Stop()

type UpdateTableFunc

type UpdateTableFunc func(table *tview.Table) error

type UpdateTextFunc

type UpdateTextFunc func(textView *tview.TextView) error

Jump to

Keyboard shortcuts

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