tui

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var App = &Application{}
View Source
var IsReadOnly = false

Functions

func NewHelpView

func NewHelpView(screen tcell.Screen) views.Widget

func NewHomeView

func NewHomeView(screen tcell.Screen) views.Widget

func NewListView

func NewListView(screen tcell.Screen) views.Widget

func Run

func Run(state State) error

Types

type Application

type Application struct {
	LastFocused components.Focusable
	State       State

	views.Application
	// contains filtered or unexported fields
}

func (*Application) Confirm

func (a *Application) Confirm(msg string, onAccept func(), onReject func())

func (*Application) NavigateTo

func (a *Application) NavigateTo(newView func(tcell.Screen) views.Widget)

func (*Application) Notify

func (a *Application) Notify(msg string)

func (*Application) Quit

func (a *Application) Quit()

func (*Application) SetTitle

func (a *Application) SetTitle(title string)

type HomeView

type HomeView struct {
	components.Container
	// contains filtered or unexported fields
}

func (*HomeView) HandleEvent

func (v *HomeView) HandleEvent(ev tcell.Event) bool

type Layout

type Layout struct {
	Status *components.Status
	Title  *components.Title

	Screen tcell.Screen

	views.Panel
}

func NewLayout

func NewLayout(screen tcell.Screen) *Layout

Returns a Layout component responsible for the shell of the application and of the routing in between pages

func (*Layout) HandleEvent

func (v *Layout) HandleEvent(ev tcell.Event) bool

type ListView

type ListView struct {
	components.Container
}

type State

type State struct {
	Entry             *kdbx.Entry
	Database          *kdbx.Database
	Reference         string
	HasUnsavedChanges bool
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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