components

package
v0.0.0-...-2bde531 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildModal

func BuildModal(p tview.Primitive, width, height int) tview.Primitive

BuildModal builds simple modal.

func BuildYesNoModal

func BuildYesNoModal(
	title string,
	text string,
	no func(),
	yes func(),
	focus func(tview.Primitive)) tview.Primitive

BuildYesNoModal builds a simple "no / yes" modal.

Types

type TreeCpnt

type TreeCpnt struct {
	App    *tview.Application
	AppCtx *models.AppCtx

	RootPrmt *tview.Flex
	// contains filtered or unexported fields
}

TreeCpnt represents the tree primitive which list the API(s)

func NewTreeCpnt

func NewTreeCpnt(app *tview.Application, ctx *models.AppCtx) *TreeCpnt

NewTreeCpnt returns a new TreeCpnt struct

func (*TreeCpnt) Make

func (cpnt *TreeCpnt) Make(refreshMDRView func(it models.MakeRequestData), switchToPage func(page string)) *tview.Flex

Make makes the tree (home made) component

func (*TreeCpnt) Refresh

func (cpnt *TreeCpnt) Refresh()

Refresh refreshes the tree data

func (*TreeCpnt) RefreshWithPattern

func (cpnt *TreeCpnt) RefreshWithPattern(pattern string, output models.Output)

RefreshWithPattern refreshes the tree data with specific pattern

func (*TreeCpnt) UpdateTitle

func (cpnt *TreeCpnt) UpdateTitle(title string)

UpdateTitle updates tree title

type TreeCpntNode

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

TreeCpntNode contains data for tree cpnt

func NewTreeCpntNode

func NewTreeCpntNode(prmt *tview.TextView, label string, method types.Method, url types.URL) TreeCpntNode

NewTreeCpntNode creates new TreeCpntNode struct

Jump to

Keyboard shortcuts

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