volumesview

package
v2.2.2 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2026 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const ViewName = "volumes"

Variables

View Source
var PollInterval = 5 * time.Second

PollInterval is how often the view re-reads its resource. It is a var, not a const, so tests can shrink it: a tea.Tick cmd invoked synchronously blocks for the full interval, so a test that runs one to see what it scheduled would otherwise sit here for five seconds.

Functions

func GetVolumesHelpContent

func GetVolumesHelpContent() []helpview.HelpCategory

GetVolumesHelpContent returns categorized help for the volumes view.

Types

type Model

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

func New

func New(width, height int) *Model

func (*Model) ApplySearchQuery

func (m *Model) ApplySearchQuery(query string)

ApplySearchQuery sets the filter query on the volumes list (app-level "/").

func (*Model) CapturesInput

func (m *Model) CapturesInput() bool

CapturesInput reports whether the view is currently capturing all input.

func (*Model) ClearSearchQuery

func (m *Model) ClearSearchQuery()

ClearSearchQuery clears the active filter.

func (*Model) ClickRow added in v2.2.0

func (m *Model) ClickRow(line int) bool

ClickRow selects the volume drawn on the given content line (view.RowClicker), with the same reset the arrow keys do when the cursor moves. A click on the loading placeholder selects nothing: the list is still empty.

func (*Model) FrameContent

func (m *Model) FrameContent() string

func (*Model) FrameFooter

func (m *Model) FrameFooter() string

func (*Model) FrameHeader

func (m *Model) FrameHeader() string

func (*Model) FrameTitle

func (m *Model) FrameTitle() string

func (*Model) HasActiveFilter

func (m *Model) HasActiveFilter() bool

HasActiveFilter reports whether a filter query is active.

func (*Model) HasErrors

func (m *Model) HasErrors() bool

func (*Model) HelpContent

func (m *Model) HelpContent() []helpview.HelpCategory

HelpContent implements the app's optional help-screen contract: "?" is handled centrally, and a view carrying its own screen supplies it here.

func (*Model) Init

func (m *Model) Init() tea.Cmd

func (*Model) Name

func (m *Model) Name() string

func (*Model) OnEnter

func (m *Model) OnEnter() tea.Cmd

func (*Model) OnExit

func (m *Model) OnExit() tea.Cmd

func (*Model) SetSize

func (m *Model) SetSize(width, height int)

func (*Model) SetVisible

func (m *Model) SetVisible(visible bool)

func (*Model) ShortHelpItems

func (m *Model) ShortHelpItems() []helpbar.HelpEntry

func (*Model) Update

func (m *Model) Update(msg tea.Msg) tea.Cmd

func (*Model) View

func (m *Model) View() string

type PollRetryMsg

type PollRetryMsg struct{}

PollRetryMsg signals that polling found no changes; the Update handler should schedule the next tick.

type SortField

type SortField int
const (
	SortByName SortField = iota
	SortByStack
	SortByDriver
	SortByCreated
	SortByHost
)

type SpinnerTickMsg

type SpinnerTickMsg time.Time

type TickMsg

type TickMsg struct{ Gen uint64 }

type VolumesLoadedMsg

type VolumesLoadedMsg struct {
	Volumes []volumeItem
	Err     error
	// Warn is a non-fatal banner message. Set when ListVolumes reports a
	// docker.PartialListError: the data is usable but some nodes were
	// unreachable. Empty on a fully successful load (which clears the banner).
	Warn string
}

Jump to

Keyboard shortcuts

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