Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Column ¶
Column is a column to show in the table. It also contains a function to extract the value from the data source.
type RefreshingDataTable ¶ added in v0.14.1
type RefreshingDataTable[T any] struct { RefreshingDataTableParams[T] // contains filtered or unexported fields }
RefreshingDataTable is a table, that loads its data from an Actor with periodic updates, or on demand.
func NewRefreshingDataTable ¶ added in v0.14.1
func NewRefreshingDataTable[T any](params RefreshingDataTableParams[T]) (*RefreshingDataTable[T], error)
NewRefreshingDataTable creates a new RefreshingDataTable.
func (*RefreshingDataTable[T]) Focus ¶ added in v0.14.1
func (t *RefreshingDataTable[T]) Focus()
Focus focuses the table.
func (*RefreshingDataTable[T]) Init ¶ added in v0.14.1
func (t *RefreshingDataTable[T]) Init() tea.Cmd
Init does nothing.
func (*RefreshingDataTable[T]) View ¶ added in v0.14.1
func (t *RefreshingDataTable[T]) View() string
View renders the table.
type RefreshingDataTableParams ¶ added in v0.14.1
type RefreshingDataTableParams[T any] struct { Columns []Column[T] Actor Actor[T] PollInterval time.Duration BorrowedHeight int // table will cut off these lines from the top at render }
RefreshingDataTableParams are the parameters to initialize a RefreshingDataTable.
Click to show internal directories.
Click to hide internal directories.