Documentation
¶
Overview ¶
Package timer provides a simple timeout component.
Index ¶
- Constants
- type Model
- func (m Model) Active() bool
- func (m Model) ID() int
- func (m Model) Idle() bool
- func (m Model) Remaining() time.Duration
- func (m Model) Reset() tea.Cmd
- func (m Model) Start(end time.Time) tea.Cmd
- func (m Model) State() State
- func (m Model) TimedOut() bool
- func (m Model) Update(msg tea.Msg) (Model, tea.Cmd)
- func (m Model) View() string
- type ResetMsg
- type StartMsg
- type State
- type TickMsg
- type TimeoutMsg
Constants ¶
View Source
const ( StateIdle = iota StateActive StateTimedOut )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Model ¶
type Model struct {
// contains filtered or unexported fields
}
type TimeoutMsg ¶
type TimeoutMsg struct {
ID int
}
Click to show internal directories.
Click to hide internal directories.